@inploi/plugin-kin 2.6.3 → 2.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cdn/index.js +60 -60
- package/dist/components/button.d.ts +2 -2
- package/dist/components/icons.d.ts +3 -0
- package/dist/components/job-cards.d.ts +5 -0
- package/dist/{highlighted-body-B3W2YXNL-1f809bd6.js → highlighted-body-B3W2YXNL-a6ce9d2d.js} +1 -1
- package/dist/{highlighted-body-B3W2YXNL-db86b597.cjs → highlighted-body-B3W2YXNL-d2c84a6f.cjs} +1 -1
- package/dist/{index-aec56a66.cjs → index-c2bd11fc.cjs} +58 -58
- package/dist/{index-c15b35ed.js → index-ff03b071.js} +3515 -3356
- package/dist/kin.client.d.ts +2 -0
- package/dist/kin.state.d.ts +4 -0
- package/dist/{mermaid-3ZIDBTTL-6f144371.cjs → mermaid-3ZIDBTTL-03c52040.cjs} +1 -1
- package/dist/{mermaid-3ZIDBTTL-3d320083.js → mermaid-3ZIDBTTL-de4986b3.js} +1 -1
- package/dist/message-payload.d.ts +24 -0
- package/dist/plugin-kin.cjs +1 -1
- package/dist/plugin-kin.js +1 -1
- package/package.json +3 -3
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
"use strict";var Eh=Object.defineProperty;var Th=(e,t,n)=>t in e?Eh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var ge=(e,t,n)=>(Th(e,typeof t!="symbol"?t+"":t,n),n);const Ii=require("@inploi/sdk");var cr,G,ul,ll,qt,Ds,cl,ta,dl,fn={},hl=[],_h=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,si=Array.isArray;function wt(e,t){for(var n in t)e[n]=t[n];return e}function fl(e){var t=e.parentNode;t&&t.removeChild(e)}function mt(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?cr.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 $n(e,s,r,i,null)}function $n(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??++ul};return i==null&&G.vnode!=null&&G.vnode(a),a}function xe(e){return e.children}function gt(e,t){this.props=e,this.context=t}function zr(e,t){if(t==null)return e.__?zr(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"?zr(e):null}function pl(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 pl(e)}}function na(e){(!e.__d&&(e.__d=!0)&&qt.push(e)&&!$r.__r++||Ds!==G.debounceRendering)&&((Ds=G.debounceRendering)||cl)($r)}function $r(){var e,t,n,r,i,a,s,o,u;for(qt.sort(ta);e=qt.shift();)e.__d&&(t=qt.length,r=void 0,i=void 0,a=void 0,o=(s=(n=e).__v).__e,(u=n.__P)&&(r=[],i=[],(a=wt({},s)).__v=s.__v+1,Oa(u,s,a,n.__n,u.ownerSVGElement!==void 0,s.__h!=null?[o]:null,r,o??zr(s),s.__h,i),El(r,s,i),s.__e!=o&&pl(s)),qt.length>t&&qt.sort(ta));$r.__r=0}function ml(e,t,n,r,i,a,s,o,u,l,h){var d,p,f,m,_,x,k,v,C,R,F=0,S=r&&r.__k||hl,Y=S.length,L=Y,D=t.length;for(n.__k=[],d=0;d<D;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"?$n(null,m,null,null,m):si(m)?$n(xe,{children:m},null,null,null):m.__b>0?$n(m.type,m.props,m.key,m.ref?m.ref:null,m.__v):m)!=null&&(m.__=n,m.__b=n.__b+1,(v=kh(m,S,k=d+F,L))===-1?f=fn:(f=S[v]||fn,S[v]=void 0,L--),Oa(e,m,f,i,a,s,o,u,l,h),_=m.__e,(p=m.ref)&&f.ref!=p&&(f.ref&&Da(f.ref,null,m),h.push(p,m.__c||_,m)),_!=null&&(x==null&&(x=_),R=!(C=f===fn||f.__v===null)&&v===k,C?v==-1&&F--:v!==k&&(v===k+1?(F++,R=!0):v>k?L>D-k?(F+=v-k,R=!0):F--:F=v<k&&v==k-1?v-k:0),k=d+F,R=R||v==d&&!C,typeof m.type!="function"||v===k&&f.__k!==m.__k?typeof m.type=="function"||R?m.__d!==void 0?(u=m.__d,m.__d=void 0):u=_.nextSibling:u=bl(e,_,u):u=gl(m,u,e),typeof n.type=="function"&&(n.__d=u)));for(n.__e=x,d=Y;d--;)S[d]!=null&&(typeof n.type=="function"&&S[d].__e!=null&&S[d].__e==n.__d&&(n.__d=S[d].__e.nextSibling),Tl(S[d],S[d]))}function gl(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"?gl(r,t,n):bl(n,r.__e,t));return t}function Yr(e,t){return t=t||[],e==null||typeof e=="boolean"||(si(e)?e.some(function(n){Yr(n,t)}):t.push(e)),t}function bl(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 kh(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 xh(e,t,n,r,i){var a;for(a in n)a==="children"||a==="key"||a in t||jr(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]||jr(e,a,t[a],n[a],r)}function Ps(e,t,n){t[0]==="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||_h.test(t)?n:n+"px"}function jr(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||Ps(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||Ps(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?Bs:Ms,a):e.removeEventListener(t,a?Bs:Ms,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 Ms(e){return this.l[e.type+!1](G.event?G.event(e):e)}function Bs(e){return this.l[e.type+!0](G.event?G.event(e):e)}function Oa(e,t,n,r,i,a,s,o,u,l){var h,d,p,f,m,_,x,k,v,C,R,F,S,Y,L,D=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]),(h=G.__b)&&h(t);try{e:if(typeof D=="function"){if(k=t.props,v=(h=D.contextType)&&r[h.__c],C=h?v?v.props.value:h.__:r,n.__c?x=(d=t.__c=n.__c).__=d.__E:("prototype"in D&&D.prototype.render?t.__c=d=new D(k,C):(t.__c=d=new gt(k,C),d.constructor=D,d.render=wh),v&&v.sub(d),d.props=k,d.state||(d.state={}),d.context=C,d.__n=r,p=d.__d=!0,d.__h=[],d._sb=[]),d.__s==null&&(d.__s=d.state),D.getDerivedStateFromProps!=null&&(d.__s==d.state&&(d.__s=wt({},d.__s)),wt(d.__s,D.getDerivedStateFromProps(k,d.__s))),f=d.props,m=d.state,d.__v=t,p)D.getDerivedStateFromProps==null&&d.componentWillMount!=null&&d.componentWillMount(),d.componentDidMount!=null&&d.__h.push(d.componentDidMount);else{if(D.getDerivedStateFromProps==null&&k!==f&&d.componentWillReceiveProps!=null&&d.componentWillReceiveProps(k,C),!d.__e&&(d.shouldComponentUpdate!=null&&d.shouldComponentUpdate(k,d.__s,C)===!1||t.__v===n.__v)){for(t.__v!==n.__v&&(d.props=k,d.state=d.__s,d.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.forEach(function(A){A&&(A.__=t)}),R=0;R<d._sb.length;R++)d.__h.push(d._sb[R]);d._sb=[],d.__h.length&&s.push(d);break e}d.componentWillUpdate!=null&&d.componentWillUpdate(k,d.__s,C),d.componentDidUpdate!=null&&d.__h.push(function(){d.componentDidUpdate(f,m,_)})}if(d.context=C,d.props=k,d.__P=e,d.__e=!1,F=G.__r,S=0,"prototype"in D&&D.prototype.render){for(d.state=d.__s,d.__d=!1,F&&F(t),h=d.render(d.props,d.state,d.context),Y=0;Y<d._sb.length;Y++)d.__h.push(d._sb[Y]);d._sb=[]}else do d.__d=!1,F&&F(t),h=d.render(d.props,d.state,d.context),d.state=d.__s;while(d.__d&&++S<25);d.state=d.__s,d.getChildContext!=null&&(r=wt(wt({},r),d.getChildContext())),p||d.getSnapshotBeforeUpdate==null||(_=d.getSnapshotBeforeUpdate(f,m)),ml(e,si(L=h!=null&&h.type===xe&&h.key==null?h.props.children:h)?L:[L],t,n,r,i,a,s,o,u,l),d.base=t.__e,t.__h=null,d.__h.length&&s.push(d),x&&(d.__E=d.__=null)}else a==null&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=yh(n.__e,t,n,r,i,a,s,u,l);(h=G.diffed)&&h(t)}catch(A){t.__v=null,(u||a!=null)&&(t.__e=o,t.__h=!!u,a[a.indexOf(o)]=null),G.__e(A,t,n)}}function El(e,t,n){for(var r=0;r<n.length;r++)Da(n[r],n[++r],n[++r]);G.__c&&G.__c(t,e),e.some(function(i){try{e=i.__h,i.__h=[],e.some(function(a){a.call(i)})}catch(a){G.__e(a,i.__v)}})}function yh(e,t,n,r,i,a,s,o,u){var l,h,d,p=n.props,f=t.props,m=t.type,_=0;if(m==="svg"&&(i=!0),a!=null){for(;_<a.length;_++)if((l=a[_])&&"setAttribute"in l==!!m&&(m?l.localName===m:l.nodeType===3)){e=l,a[_]=null;break}}if(e==null){if(m===null)return document.createTextNode(f);e=i?document.createElementNS("http://www.w3.org/2000/svg",m):document.createElement(m,f.is&&f),a=null,o=!1}if(m===null)p===f||o&&e.data===f||(e.data=f);else{if(a=a&&cr.call(e.childNodes),h=(p=n.props||fn).dangerouslySetInnerHTML,d=f.dangerouslySetInnerHTML,!o){if(a!=null)for(p={},_=0;_<e.attributes.length;_++)p[e.attributes[_].name]=e.attributes[_].value;(d||h)&&(d&&(h&&d.__html==h.__html||d.__html===e.innerHTML)||(e.innerHTML=d&&d.__html||""))}if(xh(e,f,p,i,o),d)t.__k=[];else if(ml(e,si(_=t.props.children)?_:[_],t,n,r,i&&m!=="foreignObject",a,s,a?a[0]:n.__k&&zr(n,0),o,u),a!=null)for(_=a.length;_--;)a[_]!=null&&fl(a[_]);o||("value"in f&&(_=f.value)!==void 0&&(_!==e.value||m==="progress"&&!_||m==="option"&&_!==p.value)&&jr(e,"value",_,p.value,!1),"checked"in f&&(_=f.checked)!==void 0&&_!==e.checked&&jr(e,"checked",_,p.checked,!1))}return e}function Da(e,t,n){try{typeof e=="function"?e(t):e.current=t}catch(r){G.__e(r,n)}}function Tl(e,t,n){var r,i;if(G.unmount&&G.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||Da(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(a){G.__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]&&Tl(r[i],t,n||typeof e.type!="function");n||e.__e==null||fl(e.__e),e.__=e.__e=e.__d=void 0}function wh(e,t,n){return this.constructor(e,n)}function Vr(e,t,n){var r,i,a,s;G.__&&G.__(e,t),i=(r=typeof n=="function")?null:n&&n.__k||t.__k,a=[],s=[],Oa(t,e=(!r&&n||t).__k=mt(xe,null,[e]),i||fn,fn,t.ownerSVGElement!==void 0,!r&&n?[n]:i?null:t.firstChild?cr.call(t.childNodes):null,a,!r&&n?n:i?i.__e:t.firstChild,r,s),El(a,e,s)}function _l(e,t,n){var r,i,a,s,o=wt({},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?cr.call(arguments,2):n),$n(e.type,o,r||e.key,i||e.ref,null)}function oi(e,t){var n={__c:t="__cC"+dl++,__: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,na(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}cr=hl.slice,G={__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}},ul=0,ll=function(e){return e!=null&&e.constructor===void 0},gt.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=wt({},this.state),typeof e=="function"&&(e=e(wt({},n),this.props)),e&&wt(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),na(this))},gt.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),na(this))},gt.prototype.render=xe,qt=[],cl=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,ta=function(e,t){return e.__v.__b-t.__v.__b},$r.__r=0,dl=0;function kl(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=kl(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Ni(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=kl(e))&&(r&&(r+=" "),r+=t);return r}const Fs=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,Ah=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==null?void 0:e.hooks["cx:done"](Ni(a)):typeof(e==null||(u=e.hooks)===null||u===void 0?void 0:u.onComplete)<"u"?e==null?void 0:e.hooks.onComplete(Ni(a)):Ni(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(l=>{let[h]=l;return!["class","className"].includes(h)}));return t(a.map(l=>l(u)),o==null?void 0:o.class,o==null?void 0:o.className)}},cva:i=>a=>{var s;if((i==null?void 0:i.variants)==null)return t(i==null?void 0:i.base,a==null?void 0:a.class,a==null?void 0:a.className);const{variants:o,defaultVariants:u}=i,l=Object.keys(o).map(p=>{const f=a==null?void 0:a[p],m=u==null?void 0:u[p],_=Fs(f)||Fs(m);return o[p][_]}),h={...u,...a&&Object.entries(a).reduce((p,f)=>{let[m,_]=f;return typeof _>"u"?p:{...p,[m]:_}},{})},d=i==null||(s=i.compoundVariants)===null||s===void 0?void 0:s.reduce((p,f)=>{let{class:m,className:_,...x}=f;return Object.entries(x).every(k=>{let[v,C]=k;const R=h[v];return Array.isArray(C)?C.includes(R):R===C})?[...p,m,_]:p},[]);return t(i==null?void 0:i.base,l,d,a==null?void 0:a.class,a==null?void 0:a.className)},cx:t}},{compose:N5,cva:Ft,cx:L5}=Ah();var Pt,ye,Li,Hs,nr=0,xl=[],Dr=[],Us=G.__b,zs=G.__r,$s=G.diffed,Ys=G.__c,js=G.unmount;function _n(e,t){G.__h&&G.__h(ye,e,nr||t),nr=0;var n=ye.__H||(ye.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({__V:Dr}),n.__[e]}function fe(e){return nr=1,Ch(yl,e)}function Ch(e,t,n){var r=_n(Pt++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):yl(void 0,t),function(o){var u=r.__N?r.__N[0]:r.__[0],l=r.t(u,o);u!==l&&(r.__N=[l,r.__[1]],r.__c.setState({}))}],r.__c=ye,!ye.u)){var i=function(o,u,l){if(!r.__c.__H)return!0;var h=r.__c.__H.__.filter(function(p){return p.__c});if(h.every(function(p){return!p.__N}))return!a||a.call(this,o,u,l);var d=!1;return h.forEach(function(p){if(p.__N){var f=p.__[0];p.__=p.__N,p.__N=void 0,f!==p.__[0]&&(d=!0)}}),!(!d&&r.__c.props===o)&&(!a||a.call(this,o,u,l))};ye.u=!0;var a=ye.shouldComponentUpdate,s=ye.componentWillUpdate;ye.componentWillUpdate=function(o,u,l){if(this.__e){var h=a;a=void 0,i(o,u,l),a=h}s&&s.call(this,o,u,l)},ye.shouldComponentUpdate=i}return r.__N||r.__}function Ce(e,t){var n=_n(Pt++,3);!G.__s&&Pa(n.__H,t)&&(n.__=e,n.i=t,ye.__H.__h.push(n))}function Sh(e,t){var n=_n(Pt++,4);!G.__s&&Pa(n.__H,t)&&(n.__=e,n.i=t,ye.__h.push(n))}function ve(e){return nr=5,Ne(function(){return{current:e}},[])}function Ne(e,t){var n=_n(Pt++,7);return Pa(n.__H,t)?(n.__V=e(),n.i=t,n.__h=e,n.__V):n.__}function ze(e,t){return nr=8,Ne(function(){return e},t)}function We(e){var t=ye.context[e.__c],n=_n(Pt++,9);return n.c=e,t?(n.__==null&&(n.__=!0,t.sub(ye)),t.props.value):e.__}function vh(){var e=_n(Pt++,11);if(!e.__){for(var t=ye.__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 Ih(){for(var e;e=xl.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Pr),e.__H.__h.forEach(ra),e.__H.__h=[]}catch(t){e.__H.__h=[],G.__e(t,e.__v)}}G.__b=function(e){ye=null,Us&&Us(e)},G.__r=function(e){zs&&zs(e),Pt=0;var t=(ye=e.__c).__H;t&&(Li===ye?(t.__h=[],ye.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=Dr,n.__N=n.i=void 0})):(t.__h.forEach(Pr),t.__h.forEach(ra),t.__h=[],Pt=0)),Li=ye},G.diffed=function(e){$s&&$s(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(xl.push(t)!==1&&Hs===G.requestAnimationFrame||((Hs=G.requestAnimationFrame)||Nh)(Ih)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==Dr&&(n.__=n.__V),n.i=void 0,n.__V=Dr})),Li=ye=null},G.__c=function(e,t){t.some(function(n){try{n.__h.forEach(Pr),n.__h=n.__h.filter(function(r){return!r.__||ra(r)})}catch(r){t.some(function(i){i.__h&&(i.__h=[])}),t=[],G.__e(r,n.__v)}}),Ys&&Ys(e,t)},G.unmount=function(e){js&&js(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{Pr(r)}catch(i){t=i}}),n.__H=void 0,t&&G.__e(t,n.__v))};var Vs=typeof requestAnimationFrame=="function";function Nh(e){var t,n=function(){clearTimeout(r),Vs&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);Vs&&(t=requestAnimationFrame(n))}function Pr(e){var t=ye,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),ye=t}function ra(e){var t=ye;e.__c=e.__(),ye=t}function Pa(e,t){return!e||e.length!==t.length||t.some(function(n,r){return n!==e[r]})}function yl(e,t){return typeof t=="function"?t(e):t}var Lh=Symbol.for("preact-signals");function Ma(){if(pn>1)pn--;else{for(var e,t=!1;Yn!==void 0;){var n=Yn;for(Yn=void 0,ia++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&Al(n))try{n.c()}catch(i){t||(e=i,t=!0)}n=r}}if(ia=0,pn--,t)throw e}}var Te=void 0,Yn=void 0,pn=0,ia=0,qr=0;function wl(e){if(Te!==void 0){var t=e.n;if(t===void 0||t.t!==Te)return t={i:0,S:e,p:Te.s,n:void 0,t:Te,e:void 0,x:void 0,r:t},Te.s!==void 0&&(Te.s.n=t),Te.s=t,e.n=t,32&Te.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=Te.s,t.n=void 0,Te.s.n=t,Te.s=t),t}}function Me(e){this.v=e,this.i=0,this.n=void 0,this.t=void 0}Me.prototype.brand=Lh;Me.prototype.h=function(){return!0};Me.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)};Me.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)}};Me.prototype.subscribe=function(e){var t=this;return Fa(function(){var n=t.value,r=Te;Te=void 0;try{e(n)}finally{Te=r}})};Me.prototype.valueOf=function(){return this.value};Me.prototype.toString=function(){return this.value+""};Me.prototype.toJSON=function(){return this.value};Me.prototype.peek=function(){var e=Te;Te=void 0;try{return this.value}finally{Te=e}};Object.defineProperty(Me.prototype,"value",{get:function(){var e=wl(this);return e!==void 0&&(e.i=this.i),this.v},set:function(e){if(e!==this.v){if(ia>100)throw new Error("Cycle detected");this.v=e,this.i++,qr++,pn++;try{for(var t=this.t;t!==void 0;t=t.x)t.t.N()}finally{Ma()}}}});function tt(e){return new Me(e)}function Al(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 Cl(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 Sl(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 kn(e){Me.call(this,void 0),this.x=e,this.s=void 0,this.g=qr-1,this.f=4}(kn.prototype=new Me).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===qr))return!0;if(this.g=qr,this.f|=1,this.i>0&&!Al(this))return this.f&=-2,!0;var e=Te;try{Cl(this),Te=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 Te=e,Sl(this),this.f&=-2,!0};kn.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)}Me.prototype.S.call(this,e)};kn.prototype.U=function(e){if(this.t!==void 0&&(Me.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)}};kn.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(kn.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var e=wl(this);if(this.h(),e!==void 0&&(e.i=this.i),16&this.f)throw this.v;return this.v}});function Rh(e){return new kn(e)}function vl(e){var t=e.u;if(e.u=void 0,typeof t=="function"){pn++;var n=Te;Te=void 0;try{t()}catch(r){throw e.f&=-2,e.f|=8,Ba(e),r}finally{Te=n,Ma()}}}function Ba(e){for(var t=e.s;t!==void 0;t=t.n)t.S.U(t);e.x=void 0,e.s=void 0,vl(e)}function Oh(e){if(Te!==this)throw new Error("Out-of-order effect");Sl(this),Te=e,this.f&=-2,8&this.f&&Ba(this),Ma()}function dr(e){this.x=e,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}dr.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()}};dr.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,vl(this),Cl(this),pn++;var e=Te;return Te=this,Oh.bind(this,e)};dr.prototype.N=function(){2&this.f||(this.f|=2,this.o=Yn,Yn=this)};dr.prototype.d=function(){this.f|=8,1&this.f||Ba(this)};function Fa(e){var t=new dr(e);try{t.c()}catch(n){throw t.d(),n}return t.d.bind(t)}var Ri;function xn(e,t){G[e]=t.bind(null,G[e]||function(){})}function Wr(e){Ri&&Ri(),Ri=e&&e.S()}function Il(e){var t=this,n=e.data,r=Ph(n);r.value=n;var i=Ne(function(){for(var a=t.__v;a=a.__;)if(a.__c){a.__c.__$f|=4;break}return t.__$u.c=function(){var s;!ll(i.peek())&&((s=t.base)==null?void 0:s.nodeType)===3?t.base.data=i.peek():(t.__$f|=1,t.setState({}))},Rh(function(){var s=r.value.value;return s===0?0:s===!0?"":s||""})},[]);return i.value}Il.displayName="_st";Object.defineProperties(Me.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:Il},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}});xn("__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 Me&&(n||(t.__np=n={}),n[i]=a,r[i]=a.peek())}}e(t)});xn("__r",function(e,t){Wr();var n,r=t.__c;r&&(r.__$f&=-2,(n=r.__$u)===void 0&&(r.__$u=n=function(i){var a;return Fa(function(){a=this}),a.c=function(){r.__$f|=1,r.setState({})},a}())),Wr(n),e(t)});xn("__e",function(e,t,n,r){Wr(),e(t,n,r)});xn("diffed",function(e,t){Wr();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 l=a[u],h=r[u];l===void 0?(l=Dh(n,u,h,i),a[u]=l):l.o(h,i)}}}e(t)});function Dh(e,t,n,r){var i=t in e&&e.ownerSVGElement===void 0,a=tt(n);return{o:function(s,o){a.value=s,r=o},d:Fa(function(){var s=a.value.value;r[t]!==s&&(r[t]=s,i?e[t]=s:s?e.setAttribute(t,s):e.removeAttribute(t))})}}xn("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)});xn("__h",function(e,t,n,r){(r<3||r===9)&&(t.__$f|=2),e(t,n,r)});gt.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 Ph(e){return Ne(function(){return tt(e)},[])}const Nl=tt(!1),ui=tt(!1),li=tt(null),Xt=tt(null),Ll=tt("idle"),Rl=tt(!1),Ol=tt("idle"),Dl=tt(null),Pl=tt(null),bt=tt([]),Ha=tt([]),Mh=e=>({...e,timestamp:new Date(e.timestamp)}),Ua=e=>({...e,id:crypto.randomUUID(),timestamp:new Date}),At=typeof BroadcastChannel<"u"?new BroadcastChannel("kin-sync"):null;At==null||At.addEventListener("message",e=>{const{type:t,data:n}=e.data;switch(t){case"messages_updated":if(!Array.isArray(n==null?void 0:n.messages))return;bt.value=n.messages.map(Mh);break;case"messages_cleared":bt.value=[];break}});const ci=()=>{At==null||At.postMessage({type:"messages_updated",data:{messages:bt.value}})},Ml=(e,t=!0)=>{bt.value=[...bt.value,e],Ha.value=[],t&&ci()},Bh=e=>{const t=Ua(e);return Ml(t),t},Fh=e=>{bt.value=bt.value.filter(t=>t.id!==e),ci()},Hh=()=>{ui.value=!0,li.value="thinking",Xt.value=Ua({role:"assistant",content:""})},Uh=e=>{if(!e)return;const t=Xt.value;t&&(Xt.value={...t,content:t.content+e})},zh=e=>{const{commit:t=!0,broadcast:n=!0}=e??{},r=Xt.value;Xt.value=null,ui.value=!1,li.value=null,t&&(r!=null&&r.content)&&Ml(r,!1),n&&ci()},za=()=>{Xt.value=null,ui.value=!1,li.value=null},Bl=()=>{bt.value=[],za(),At==null||At.postMessage({type:"messages_cleared"})},$h=e=>{za(),bt.value=e.filter(t=>t.role!=="system").map(Ua),ci()},Fl=(e,t,n)=>{Ol.value=e,Pl.value=t??null,Dl.value=n??null},Yh=()=>{Nl.value=!1,Ll.value="idle",Ha.value=[],Rl.value=!1,Bl(),Fl("idle")},$={isOpen:Nl,isStreaming:ui,assistantStatus:li,liveAssistantMessage:Xt,connectionState:Ll,messages:bt,quickReplies:Ha,uploadState:Ol,uploadError:Dl,uploadFileName:Pl,hasUnreadMessages:Rl,addMessage:Bh,removeMessage:Fh,startAssistantResponse:Hh,appendToLiveAssistantMessage:Uh,finishAssistantResponse:zh,clearAssistantResponse:za,clearMessages:Bl,setMessages:$h,setUploadState:Fl,resetState:Yh},rr=Ft({base:"fr inline-flex shrink-0 items-center corner-smooth justify-center transition-all duration-kin disabled:cursor-not-allowed",variants:{variant:{ghost:"bg-transparent text-n-8 hover:bg-n-3 hover:text-n-11 disabled:text-n-6 active:scale-95",neutral:"bg-n-3 text-n-9 hover:bg-n-4 hover:text-n-11 disabled:opacity-50 active:scale-95",accent:"bg-a-9 text-white hover:bg-a-10 disabled:opacity-50 active:scale-95"},size:{sm:"size-8 sm:size-7 [&_svg]:size-3.5 rounded-kin-xl",md:"size-10 sm:size-8 [&_svg]:size-4 rounded-kin-2xl sm:rounded-kin-xl"}},defaultVariants:{size:"md"}});var jh=0;function g(e,t,n,r,i,a){var s,o,u={};for(o in t)o=="ref"?s=t[o]:u[o]=t[o];var l={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:--jh,__source:i,__self:a};if(typeof e=="function"&&(s=e.defaultProps))for(o in s)u[o]===void 0&&(u[o]=s[o]);return G.vnode&&G.vnode(l),l}function Ge(e){return function(n){return g("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:n.strokeWidth??1.5,strokeLinecap:"round",strokeLinejoin:"round",focusable:"false","aria-hidden":"true",...n,children:e()})}}function Vh({class:e}){return g("svg",{class:e,viewBox:"0 0 32 16",fill:"currentColor","aria-hidden":"true",focusable:"false",children:g("path",{d:"M8.28 12.54c-.76-.34-1.52-1.08-2.88-2.44l-2.02-2.02-.68-.68-.12-.16a.76.76 90 010-.72l.12-.16.68-.68A16.5 16.5 90 015.9 3.36a4.5 4.5 90 014.62 0c.44.26.94.72 2.5 2.32l1.1 1.1 1.54-1.54-1.1-1.1c-1.48-1.44-2.22-2.18-2.98-2.62a6.76 6.76 90 00-6.82 0c-.74.42-1.46 1.16-2.94 2.6-.64.64-.92.94-1.14 1.28a3 3 90 000 2.92c.2.34.52.64 1.14 1.28L4.3 12.1c1.1 1.08 1.64 1.62 2.26 2.02a6 6 90 001.76.72c.72.18 1.5.18 3.04.18h10.9c1.54 0 2.32 0 3.04-.18q.92-.22 1.76-.72c.64-.4 1.16-.94 2.26-2.02l.46-.48c5.8-5.8-2.88-14.48-8.66-8.66L13.98 10.1c-1.52 1.5-2.28 2.28-3.16 2.56a3.76 3.76 90 01-2.16.02l-.4-.16Z"})})}const qh=Ge(()=>g("path",{d:"M6 10c2-4 3.5-7 6-7s4 3 6 7 4 8 2 9-6-2.5-8-2.5S6 20 4 19s0-5 2-9"})),Wh=Ge(()=>g("path",{d:"M18 6 6 18M18 18 6 6"})),Gh=Ge(()=>g(xe,{children:[g("path",{d:"M4.5 5.5l.6 10c.2 2.6.2 3.9.9 4.8.3.4.7.8 1.2 1.1.9.6 2.2.6 4.8.6s3.8 0 4.8-.6c.5-.3.9-.7 1.2-1.1.6-.9.7-2.2.9-4.8l.6-10"}),g("path",{d:"m8.05 5.5.61-1.33c.44-.97.66-1.45 1.06-1.76.09-.07.18-.13.28-.18.44-.23.97-.23 2.04-.23 1.04 0 1.56 0 1.99.22.1.05.19.11.27.17.39.29.62.76 1.07 1.69l.68 1.41m4.94 0h-18"})]})),Qh=Ge(()=>g("path",{d:"M5 14s1.5.5 3.5 4C8.5 18 12 11 19 7"})),Hl=Ge(()=>g("path",{d:"M5.8 12 4.3 10.5C2.6 8.8 2.6 6 4.3 4.3c1.7-1.7 4.5-1.7 6.2 0l9.2 9.2c1.7 1.8 1.7 4.5 0 6.2s-4.4 1.7-6.2 0l-3.4-3.4c-1.1-1.1-1.1-2.9 0-3.9 1-1.1 2.8-1.1 3.8 0l2 1.9"})),Kh=Ge(()=>g("path",{d:"M21 12a9 9 0 11-6.219-8.56"})),qs=Ge(()=>g(xe,{children:[g("path",{d:"M9.6 6.1c.3-.8 1.5-.8 1.8 0l.9 2.3c.6 1.5 1.8 2.7 3.3 3.3l2.3.9c.8.3.8 1.5 0 1.8l-2.3.9c-1.5.6-2.7 1.8-3.3 3.3l-.9 2.3c-.3.8-1.5.8-1.8 0l-.9-2.3c-.6-1.5-1.8-2.7-3.3-3.3l-2.3-.9c-.8-.3-.8-1.5 0-1.8l2.3-.9c1.5-.6 2.7-1.8 3.3-3.3l.9-2.3Z"}),g("path",{d:"M18.16 2.73c.12-.31.56-.31.68 0l.34.87c.22.56.66 1 1.22 1.22l.87.34c.31.12.31.56 0 .68l-.87.34c-.56.22-1 .66-1.22 1.22l-.34.87c-.12.31-.56.31-.68 0l-.34-.87c-.22-.56-.66-1-1.22-1.22l-.87-.34c-.31-.12-.31-.56 0-.68l.87-.34c.56-.22 1-.66 1.22-1.22l.34-.87Z"})]})),Xh=Ge(()=>g(xe,{children:[g("path",{d:"M15 15l1.5 1.5"}),g("path",{d:"M16.93 19.03c-.57-.58-.57-1.52 0-2.1.58-.57 1.52-.57 2.1 0l2.04 2.04c.57.58.57 1.52 0 2.1-.58.57-1.52.57-2.1 0l-2.04-2.04Z"}),g("path",{d:"M16.5 9.5c0-3.9-3.1-7-7-7s-7 3.1-7 7 3.1 7 7 7 7-3.1 7-7Z"})]})),Ws=Ge(()=>g(xe,{children:[g("path",{d:"M21 11c0-2.2-.2-3.5-1.1-4.4-1.1-1.1-2.9-1.1-6.5-1.1H9.6c-3.6 0-5.4 0-6.5 1.1C2 7.8 2 9.6 2 13.3c0 3.6 0 5.4 1.1 6.6C4.2 21 6 21 9.6 21H11"}),g("path",{d:"M20 20l2 2m-.9-4.5c0-1.9-1.6-3.5-3.6-3.5-1.9 0-3.5 1.6-3.5 3.5 0 2 1.6 3.6 3.5 3.6 2 0 3.6-1.6 3.6-3.6Z"}),g("path",{d:"M7 5.5l.1-.3c.5-1.5.7-2.3 1.3-2.8C9 2 9.8 2 11.4 2h.2c1.6 0 2.4 0 3 .4.6.5.8 1.3 1.3 2.8l.1.3"})]})),Gs=Ge(()=>g(xe,{children:[g("path",{d:"M11 21H10c-3.8 0-5.7 0-6.8-1.2C2 18.7 2 16.8 2 13V10C2 6.2 2 4.3 3.2 3.2 4.3 2 6.2 2 10 2h2c3.8 0 5.7 0 6.8 1.2C20 4.3 20 6.2 20 10v.5"}),g("path",{d:"M17.41 14.4c.21-.54.97-.54 1.19 0l.04.09c.52 1.31 1.56 2.35 2.87 2.87l.09.04c.54.21.54.97 0 1.19l-.09.04c-1.31.52-2.35 1.56-2.87 2.87l-.04.09c-.21.54-.97.54-1.19 0l-.04-.09c-.52-1.31-1.56-2.35-2.87-2.87l-.09-.04c-.54-.21-.54-.97 0-1.19l.09-.04c1.31-.52 2.35-1.56 2.87-2.87l.04-.09Z"}),g("path",{d:"M7 7h8M7 11.5h8M7 16h4"})]})),Zh=Ge(()=>g(xe,{children:[g("path",{d:"M5 14v6"}),g("path",{d:"M5 4v7"}),g("path",{d:"M9 8h6"}),g("path",{d:"M2 14H8"}),g("path",{d:"M16 12h6"}),g("path",{d:"M12 8V4"}),g("path",{d:"M12 11v9"}),g("path",{d:"M19 4v8"}),g("path",{d:"M19 15v5"})]})),Jh=Ge(()=>g("path",{d:"M4 18c0 2.3 0 3.5.8 3.9 1.5.8 4.3-1.9 5.6-2.7.8-.5 1.2-.7 1.6-.7s.8.2 1.6.7c1.3.8 4.1 3.5 5.6 2.7.8-.4.8-1.6.8-3.9V9.7c0-3.6 0-5.5-1.2-6.6C17.7 2 15.8 2 12 2S6.3 2 5.2 3.1 4 6.1 4 9.7v8.3Z"})),Qs=Ge(()=>g(xe,{children:[g("path",{d:"m19.4 7.6-3-3m3 3-6.7 6.7c-.5.5-1.1.9-1.8 1L8 16l.7-2.9c.2-.7.5-1.3 1-1.8l6.7-6.7m3 3 1-1c.8-.8.8-2.1 0-3-.8-.8-2.1-.8-3 0l-1 1"}),g("path",{d:"M10.5 5c-3.29 0-4.93 0-6.04.91-.2.17-.39.35-.55.55C3 7.57 3 9.21 3 12.5V13c0 3.77 0 5.66 1.17 6.83C5.34 21 7.23 21 11 21h.5c3.29 0 4.93 0 6.04-.91.2-.17.39-.35.55-.55.91-1.11.91-2.75.91-6.04"})]})),ef=Ge(()=>g("path",{d:"M6 10s3.5 6 6 6 6-6 6-6"}));function tf(e,t){for(var n in t)e[n]=t[n];return e}function aa(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 Ks(e){this.props=e}function be(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:aa(this.props,i)}function r(i){return this.shouldComponentUpdate=n,mt(e,i)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(Ks.prototype=new gt).isPureReactComponent=!0,Ks.prototype.shouldComponentUpdate=function(e,t){return aa(this.props,e)||aa(this.state,t)};var Xs=G.__b;G.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),Xs&&Xs(e)};var nf=G.__e;G.__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)}nf(e,t,n,r)};var Zs=G.unmount;function Ul(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=tf({},e)).__c!=null&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map(function(r){return Ul(r,t,n)})),e}function zl(e,t,n){return e&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(r){return zl(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 jn(){this.__u=0,this.t=null,this.__b=null}function $l(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function Yl(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 mt(n,a)}return i.displayName="Lazy",i.__f=!0,i}function _r(){this.u=null,this.o=null}G.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&e.__h===!0&&(e.type=null),Zs&&Zs(e)},(jn.prototype=new gt).__c=function(e,t){var n=t.__c,r=this;r.t==null&&(r.t=[]),r.t.push(n);var i=$l(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 l=r.state.__a;r.__v.__k[0]=zl(l,l.__c.__P,l.__c.__O)}var h;for(r.setState({__a:r.__b=null});h=r.t.pop();)h.forceUpdate()}},u=t.__h===!0;r.__u++||u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(s,s)},jn.prototype.componentWillUnmount=function(){this.t=[]},jn.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]=Ul(this.__b,n,r.__O=r.__P)}this.__b=null}var i=t.__a&&mt(xe,null,e.fallback);return i&&(i.__h=null),[mt(xe,null,t.__a?null:e.children),i]};var Js=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 rf(e){return this.getChildContext=function(){return e.context},e.children}function af(e){var t=this,n=e.i;t.componentWillUnmount=function(){Vr(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)}}),Vr(mt(rf,{context:t.context},e.__v),t.l)):t.l&&t.componentWillUnmount()}function jl(e,t){var n=mt(af,{__v:e,i:t});return n.containerInfo=t,n}(_r.prototype=new gt).__a=function(e){var t=this,n=$l(t.__v),r=t.o.get(e);return r[0]++,function(i){var a=function(){t.props.revealOrder?(r.push(i),Js(t,e,r)):i()};n?n(a):a()}},_r.prototype.render=function(e){this.u=null,this.o=new Map;var t=Yr(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},_r.prototype.componentDidUpdate=_r.prototype.componentDidMount=function(){var e=this;this.o.forEach(function(t,n){Js(e,n,t)})};var Vl=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]/,of=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,uf=/[A-Z0-9]/g,lf=typeof document<"u",cf=function(e){return(typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(e)};gt.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(gt.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var eo=G.event;function df(){}function hf(){return this.cancelBubble}function ff(){return this.defaultPrevented}G.event=function(e){return eo&&(e=eo(e)),e.persist=df,e.isPropagationStopped=hf,e.isDefaultPrevented=ff,e.nativeEvent=e};var pf={enumerable:!1,configurable:!0,get:function(){return this.class}},to=G.vnode;G.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||lf&&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"||cf(n.type)?o==="onfocus"?a="onfocusin":o==="onblur"?a="onfocusout":of.test(a)?a=o:r.indexOf("-")===-1&&sf.test(a)?a=a.replace(uf,"-$&").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=Yr(n.children).forEach(function(u){u.props.selected=i.value.indexOf(u.props.value)!=-1})),r=="select"&&i.defaultValue!=null&&(i.value=Yr(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=Vl,to&&to(e)};var no=G.__r;G.__r=function(e){no&&no(e)};var ro=G.diffed;G.diffed=function(e){ro&&ro(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 Ot(e){return!!e&&e.$$typeof===Vl}function mf(e){return Ot(e)?_l.apply(null,arguments):e}function gf(e){e()}function bf(){return[!1,gf]}const di=function(e){if(e==null)return kf;if(typeof e=="function")return hi(e);if(typeof e=="object")return Array.isArray(e)?Ef(e):Tf(e);if(typeof e=="string")return _f(e);throw new Error("Expected function, string, or object as test")};function Ef(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=di(e[n]);return hi(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function Tf(e){const t=e;return hi(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function _f(e){return hi(t);function t(n){return n&&n.type===e}}function hi(e){return t;function t(n,r,i){return!!(xf(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function kf(){return!0}function xf(e){return e!==null&&typeof e=="object"&&"type"in e}const ql=[],Fn=!0,sa=!1,dn="skip";function $a(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=di(i),s=r?-1:1;o(e,void 0,[])();function o(u,l,h){const d=u&&typeof u=="object"?u:{};if(typeof d.type=="string"){const f=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0;Object.defineProperty(p,"name",{value:"node ("+(u.type+(f?"<"+f+">":""))+")"})}return p;function p(){let f=ql,m,_,x;if((!t||a(u,l,h[h.length-1]||void 0))&&(f=yf(n(u,h)),f[0]===sa))return f;if("children"in u&&u.children){const k=u;if(k.children&&f[0]!==dn)for(_=(r?k.children.length:-1)+s,x=h.concat(k);_>-1&&_<k.children.length;){const v=k.children[_];if(m=o(v,_,x)(),m[0]===sa)return m;_=typeof m[1]=="number"?m[1]:_+s}}return f}}}function yf(e){return Array.isArray(e)?e:typeof e=="number"?[Fn,e]:e==null?ql:[e]}function Mt(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),$a(e,a,o,i);function o(u,l){const h=l[l.length-1],d=h?h.children.indexOf(u):void 0;return s(u,d,h)}}const bn={indicator:"indicator",textOnly:"text-only",remove:"remove"};function wf({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=bn.indicator,imageBlockPolicy:u=bn.indicator}){const l=t.length&&!t.every(d=>d==="*"),h=n.length&&!n.every(d=>d==="*");if(!e&&(l||h))throw new Error("defaultOrigin is required when allowedLinkPrefixes or allowedImagePrefixes are provided");return d=>{const p=Nf(e,t,n,r,i,a,s,o,u);Wl(d),Mt(d,p)}}function io(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 Af(e){return typeof e!="string"?!1:e.startsWith("/")||e.startsWith("./")||e.startsWith("../")}const Cf=new Set(["https:","http:","irc:","ircs:","mailto:","xmpp:","blob:"]),Sf=new Set(["javascript:","data:","file:","vbscript:"]);function ao(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 h=e.substring(5);if(h&&h.length>0&&h!=="invalid")return e}}catch{return null}return null}const s=io(e,n);if(!s||Sf.has(s.protocol)||!(Cf.has(s.protocol)||a.includes(s.protocol)||a.includes("*")))return null;if(s.protocol==="mailto:"||!s.protocol.match(/^https?:$/))return s.href;const u=Af(e);return s&&t.some(l=>{const h=io(l,n);return!h||h.origin!==s.origin?!1:s.href.startsWith(h.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 Wl(e){if("children"in e&&Array.isArray(e.children)){e.children=e.children.filter(t=>t!=null);for(const t of e.children)Wl(t)}}const Oi=Symbol("node-seen");function vf(e,t,n){return t===bn.remove?{type:"remove"}:t===bn.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 If(e,t,n){if(t===bn.remove)return{type:"remove"};if(t===bn.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 Nf=(e,t,n,r,i,a,s,o,u)=>{const l=(h,d,p)=>{if(h.type!=="element"||h[Oi])return Fn;if(h.tagName==="a"){const f=ao(h.properties.href,t,e,!1,!1,i);if(f===null){if(h[Oi]=!0,Mt(h,l),p&&typeof d=="number"){const m=vf(h,o,s);if(m.type==="remove")return p.children.splice(d,1),[dn,d];p.children[d]=m.element}return dn}else return h.properties.href=f,h.properties.target="_blank",h.properties.rel="noopener noreferrer",Fn}if(h.tagName==="img"){const f=ao(h.properties.src,n,e,r,!0,i);if(f===null){if(h[Oi]=!0,Mt(h,l),p&&typeof d=="number"){const m=If(h,u,a);if(m.type==="remove")return p.children.splice(d,1),[dn,d];p.children[d]=m.element}return dn}else return h.properties.src=f,Fn}return Fn};return l},Gl=-1,fi=0,Vn=1,Gr=2,Ya=3,ja=4,Va=5,qa=6,Ql=7,Kl=8,so=typeof self=="object"?self:globalThis,Lf=(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 fi:case Gl:return n(s,i);case Vn:{const o=n([],i);for(const u of s)o.push(r(u));return o}case Gr:{const o=n({},i);for(const[u,l]of s)o[r(u)]=r(l);return o}case Ya:return n(new Date(s),i);case ja:{const{source:o,flags:u}=s;return n(new RegExp(o,u),i)}case Va:{const o=n(new Map,i);for(const[u,l]of s)o.set(r(u),r(l));return o}case qa:{const o=n(new Set,i);for(const u of s)o.add(r(u));return o}case Ql:{const{name:o,message:u}=s;return n(new so[o](u),i)}case Kl: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 so[a](s),i)};return r},oo=e=>Lf(new Map,e)(0),ln="",{toString:Rf}={},{keys:Of}=Object,Ln=e=>{const t=typeof e;if(t!=="object"||!e)return[fi,t];const n=Rf.call(e).slice(8,-1);switch(n){case"Array":return[Vn,ln];case"Object":return[Gr,ln];case"Date":return[Ya,ln];case"RegExp":return[ja,ln];case"Map":return[Va,ln];case"Set":return[qa,ln];case"DataView":return[Vn,n]}return n.includes("Array")?[Vn,n]:n.includes("Error")?[Ql,n]:[Gr,n]},kr=([e,t])=>e===fi&&(t==="function"||t==="symbol"),Df=(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]=Ln(s);switch(o){case fi:{let h=s;switch(u){case"bigint":o=Kl,h=s.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+u);h=null;break;case"undefined":return i([Gl],s)}return i([o,h],s)}case Vn:{if(u){let p=s;return u==="DataView"?p=new Uint8Array(s.buffer):u==="ArrayBuffer"&&(p=new Uint8Array(s)),i([u,[...p]],s)}const h=[],d=i([o,h],s);for(const p of s)h.push(a(p));return d}case Gr:{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 h=[],d=i([o,h],s);for(const p of Of(s))(e||!kr(Ln(s[p])))&&h.push([a(p),a(s[p])]);return d}case Ya:return i([o,s.toISOString()],s);case ja:{const{source:h,flags:d}=s;return i([o,{source:h,flags:d}],s)}case Va:{const h=[],d=i([o,h],s);for(const[p,f]of s)(e||!(kr(Ln(p))||kr(Ln(f))))&&h.push([a(p),a(f)]);return d}case qa:{const h=[],d=i([o,h],s);for(const p of s)(e||!kr(Ln(p)))&&h.push(a(p));return d}}const{message:l}=s;return i([o,{name:u,message:l}],s)};return a},uo=(e,{json:t,lossy:n}={})=>{const r=[];return Df(!(t||n),!!t,new Map,r)(e),r},Zt=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?oo(uo(e,t)):structuredClone(e):(e,t)=>oo(uo(e,t));class hr{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}}hr.prototype.normal={};hr.prototype.property={};hr.prototype.space=void 0;function Xl(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new hr(n,r,t)}function ir(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 Pf=0;const re=tn(),Re=tn(),oa=tn(),H=tn(),ke=tn(),mn=tn(),Xe=tn();function tn(){return 2**++Pf}const ua=Object.freeze(Object.defineProperty({__proto__:null,boolean:re,booleanish:Re,commaOrSpaceSeparated:Xe,commaSeparated:mn,number:H,overloadedBoolean:oa,spaceSeparated:ke},Symbol.toStringTag,{value:"Module"})),Di=Object.keys(ua);class Wa extends Qe{constructor(t,n,r,i){let a=-1;if(super(t,n),lo(this,"space",i),typeof r=="number")for(;++a<Di.length;){const s=Di[a];lo(this,Di[a],(r&ua[s])===ua[s])}}}Wa.prototype.defined=!0;function lo(e,t,n){n&&(e[t]=n)}function yn(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const a=new Wa(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[ir(r)]=r,n[ir(a.attribute)]=r}return new hr(t,n,e.space)}const Zl=yn({properties:{ariaActiveDescendant:null,ariaAtomic:Re,ariaAutoComplete:null,ariaBusy:Re,ariaChecked:Re,ariaColCount:H,ariaColIndex:H,ariaColSpan:H,ariaControls:ke,ariaCurrent:null,ariaDescribedBy:ke,ariaDetails:null,ariaDisabled:Re,ariaDropEffect:ke,ariaErrorMessage:null,ariaExpanded:Re,ariaFlowTo:ke,ariaGrabbed:Re,ariaHasPopup:null,ariaHidden:Re,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:ke,ariaLevel:H,ariaLive:null,ariaModal:Re,ariaMultiLine:Re,ariaMultiSelectable:Re,ariaOrientation:null,ariaOwns:ke,ariaPlaceholder:null,ariaPosInSet:H,ariaPressed:Re,ariaReadOnly:Re,ariaRelevant:null,ariaRequired:Re,ariaRoleDescription:ke,ariaRowCount:H,ariaRowIndex:H,ariaRowSpan:H,ariaSelected:Re,ariaSetSize:H,ariaSort:null,ariaValueMax:H,ariaValueMin:H,ariaValueNow:H,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function Jl(e,t){return t in e?e[t]:t}function ec(e,t){return Jl(e,t.toLowerCase())}const Mf=yn({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:mn,acceptCharset:ke,accessKey:ke,action:null,allow:null,allowFullScreen:re,allowPaymentRequest:re,allowUserMedia:re,alt:null,as:null,async:re,autoCapitalize:null,autoComplete:ke,autoFocus:re,autoPlay:re,blocking:ke,capture:null,charSet:null,checked:re,cite:null,className:ke,cols:H,colSpan:null,content:null,contentEditable:Re,controls:re,controlsList:ke,coords:H|mn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:re,defer:re,dir:null,dirName:null,disabled:re,download:oa,draggable:Re,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:re,formTarget:null,headers:ke,height:H,hidden:oa,high:H,href:null,hrefLang:null,htmlFor:ke,httpEquiv:ke,id:null,imageSizes:null,imageSrcSet:null,inert:re,inputMode:null,integrity:null,is:null,isMap:re,itemId:null,itemProp:ke,itemRef:ke,itemScope:re,itemType:ke,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:re,low:H,manifest:null,max:null,maxLength:H,media:null,method:null,min:null,minLength:H,multiple:re,muted:re,name:null,nonce:null,noModule:re,noValidate:re,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:re,optimum:H,pattern:null,ping:ke,placeholder:null,playsInline:re,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:re,referrerPolicy:null,rel:ke,required:re,reversed:re,rows:H,rowSpan:H,sandbox:ke,scope:null,scoped:re,seamless:re,selected:re,shadowRootClonable:re,shadowRootDelegatesFocus:re,shadowRootMode:null,shape:null,size:H,sizes:null,slot:null,span:H,spellCheck:Re,src:null,srcDoc:null,srcLang:null,srcSet:null,start:H,step:null,style:null,tabIndex:H,target:null,title:null,translate:null,type:null,typeMustMatch:re,useMap:null,value:Re,width:H,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:ke,axis:null,background:null,bgColor:null,border:H,borderColor:null,bottomMargin:H,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:re,declare:re,event:null,face:null,frame:null,frameBorder:null,hSpace:H,leftMargin:H,link:null,longDesc:null,lowSrc:null,marginHeight:H,marginWidth:H,noResize:re,noHref:re,noShade:re,noWrap:re,object:null,profile:null,prompt:null,rev:null,rightMargin:H,rules:null,scheme:null,scrolling:Re,standby:null,summary:null,text:null,topMargin:H,valueType:null,version:null,vAlign:null,vLink:null,vSpace:H,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:re,disableRemotePlayback:re,prefix:null,property:null,results:H,security:null,unselectable:null},space:"html",transform:ec}),Bf=yn({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:Xe,accentHeight:H,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:H,amplitude:H,arabicForm:null,ascent:H,attributeName:null,attributeType:null,azimuth:H,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:H,by:null,calcMode:null,capHeight:H,className:ke,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:H,diffuseConstant:H,direction:null,display:null,dur:null,divisor:H,dominantBaseline:null,download:re,dx:null,dy:null,edgeMode:null,editable:null,elevation:H,enableBackground:null,end:null,event:null,exponent:H,externalResourcesRequired:null,fill:null,fillOpacity:H,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:mn,g2:mn,glyphName:mn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:H,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:H,horizOriginX:H,horizOriginY:H,id:null,ideographic:H,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:H,k:H,k1:H,k2:H,k3:H,k4:H,kernelMatrix:Xe,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:H,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:H,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:H,overlineThickness:H,paintOrder:null,panose1:null,path:null,pathLength:H,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:ke,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:H,pointsAtY:H,pointsAtZ:H,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Xe,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Xe,rev:Xe,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Xe,requiredFeatures:Xe,requiredFonts:Xe,requiredFormats:Xe,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:H,specularExponent:H,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:H,strikethroughThickness:H,string:null,stroke:null,strokeDashArray:Xe,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:H,strokeOpacity:H,strokeWidth:null,style:null,surfaceScale:H,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Xe,tabIndex:H,tableValues:null,target:null,targetX:H,targetY:H,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Xe,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:H,underlineThickness:H,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:H,values:null,vAlphabetic:H,vMathematical:H,vectorEffect:null,vHanging:H,vIdeographic:H,version:null,vertAdvY:H,vertOriginX:H,vertOriginY:H,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:H,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Jl}),tc=yn({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()}}),nc=yn({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:ec}),rc=yn({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),Ff={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"},Hf=/[A-Z]/g,co=/-[a-z]/g,Uf=/^data[-\w.:]+$/i;function pi(e,t){const n=ir(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"&&Uf.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(co,$f);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!co.test(a)){let s=a.replace(Hf,zf);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}i=Wa}return new i(r,t)}function zf(e){return"-"+e.toLowerCase()}function $f(e){return e.charAt(1).toUpperCase()}const fr=Xl([Zl,Mf,tc,nc,rc],"html"),Ht=Xl([Zl,Bf,tc,nc,rc],"svg");function ho(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 ic(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const fo=/[#.]/g;function Yf(e,t){const n=e||"",r={};let i=0,a,s;for(;i<n.length;){fo.lastIndex=i;const o=fo.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 po(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function ac(e){return e.join(" ").trim()}function sc(e,t,n){const r=n?Wf(n):void 0;function i(a,s,...o){let u;if(a==null){u={type:"root",children:[]};const l=s;o.unshift(l)}else{u=Yf(a,t);const l=u.tagName.toLowerCase(),h=r?r.get(l):void 0;if(u.tagName=h||l,jf(s))o.unshift(s);else for(const[d,p]of Object.entries(s))Vf(e,u.properties,d,p)}for(const l of o)la(u.children,l);return u.type==="element"&&u.tagName==="template"&&(u.content={type:"root",children:u.children},u.children=[]),u}return i}function jf(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 Vf(e,t,n,r){const i=pi(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=po(r):i.commaSeparated?a=ho(r):i.commaOrSpaceSeparated?a=po(ho(r).join(" ")):a=mo(i,i.property,r):Array.isArray(r)?a=[...r]:a=i.property==="style"?qf(r):String(r);if(Array.isArray(a)){const s=[];for(const o of a)s.push(mo(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 mo(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||ir(n)===ir(t)))return!0}return n}function qf(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function Wf(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const Gf=["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"],Qf=sc(fr,"div"),Kf=sc(Ht,"g",Gf);function Xf(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=go(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=go(t,o),l=u===-1?t.length+1:u+1;if(o===l)break;n.push(l)}const s=(a.line>1?n[a.line-2]:0)+a.column-1;if(s<n[a.line-1])return s}}}function go(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/"},oc={}.hasOwnProperty,Zf=Object.prototype;function Jf(e,t){const n=t||{};return Ga({file:n.file||void 0,location:!1,schema:n.space==="svg"?Ht:fr,verbose:n.verbose||!1},e)}function Ga(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Mr(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:uc(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){const a=String(e.file),s=Xf(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"},Mr(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Mr(e,r,n),n}default:return n=ep(e,t),n}}function uc(e,t){let n=-1;const r=[];for(;++n<t.length;){const i=Ga(e,t[n]);r.push(i)}return r}function ep(e,t){const n=e.schema;e.schema=t.namespaceURI===Qt.svg?Ht:fr;let r=-1;const i={};for(;++r<t.attrs.length;){const o=t.attrs[r],u=(o.prefix?o.prefix+":":"")+o.name;oc.call(Zf,u)||(i[u]=o.value)}const s=(e.schema.space==="svg"?Kf:Qf)(t.tagName,i,uc(e,t.childNodes));if(Mr(e,t,s),s.tagName==="template"){const o=t,u=o.sourceCodeLocation,l=u&&u.startTag&&hn(u.startTag),h=u&&u.endTag&&hn(u.endTag),d=Ga(e,o.content);l&&h&&e.file&&(d.position={start:l.end,end:h.start}),s.content=d}return e.schema=n,s}function Mr(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=tp(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function tp(e,t,n){const r=hn(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)oc.call(n.attrs,s)&&(a[pi(e.schema,s).property]=hn(n.attrs[s]));const o=hn(n.startTag),u=n.endTag?hn(n.endTag):void 0,l={opening:o};u&&(l.closing=u),l.properties=a,t.data={position:l}}}return r}function hn(e){const t=bo({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=bo({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function bo(e){return e.line&&e.column?e:void 0}const Eo={}.hasOwnProperty;function lc(e,t){const n=t||{};function r(i,...a){let s=r.invalid;const o=r.handlers;if(i&&Eo.call(i,e)){const u=String(i[e]);s=Eo.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 np={},rp={}.hasOwnProperty,cc=lc("type",{handlers:{root:ap,element:cp,text:up,comment:lp,doctype:op}});function ip(e,t){const r=(t||np).space;return cc(e,r==="svg"?Ht:fr)}function ap(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=Qa(e.children,n,t),wn(e,n),n}function sp(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=Qa(e.children,n,t),wn(e,n),n}function op(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return wn(e,t),t}function up(e){const t={nodeName:"#text",value:e.value,parentNode:null};return wn(e,t),t}function lp(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return wn(e,t),t}function cp(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=Ht);const i=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&rp.call(e.properties,a)){const u=dp(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=Qa(e.children,o,r),wn(e,o),e.tagName==="template"&&e.content&&(o.content=sp(e.content,r)),o}function dp(e,t,n){const r=pi(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?ic(n):ac(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 Qa(e,t,n){let r=-1;const i=[];if(e)for(;++r<e.length;){const a=cc(e[r],n);a.parentNode=t,i.push(a)}return i}function wn(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 hp=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],fp=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]),we="�";var b;(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"})(b||(b={}));const Ve={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function dc(e){return e>=55296&&e<=57343}function pp(e){return e>=56320&&e<=57343}function mp(e,t){return(e-55296)*1024+9216+t}function hc(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function fc(e){return e>=64976&&e<=65007||fp.has(e)}var N;(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"})(N||(N={}));const gp=65536;class bp{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=gp,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(pp(n))return this.pos++,this._addGap(),mp(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,b.EOF;return this._err(N.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,b.EOF;const r=this.html.charCodeAt(n);return r===b.CARRIAGE_RETURN?b.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,b.EOF;let t=this.html.charCodeAt(this.pos);return t===b.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,b.LINE_FEED):t===b.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,dc(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===b.LINE_FEED||t===b.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){hc(t)?this._err(N.controlCharacterInInputStream):fc(t)&&this._err(N.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var ae;(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"})(ae||(ae={}));function pc(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 Ep=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))),Tp=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 _p(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=Tp.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 kp=32;var Dt;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Dt||(Dt={}));function ca(e){return e>=Pe.ZERO&&e<=Pe.NINE}function xp(e){return e>=Pe.UPPER_A&&e<=Pe.UPPER_F||e>=Pe.LOWER_A&&e<=Pe.LOWER_F}function yp(e){return e>=Pe.UPPER_A&&e<=Pe.UPPER_Z||e>=Pe.LOWER_A&&e<=Pe.LOWER_Z||ca(e)}function wp(e){return e===Pe.EQUALS||yp(e)}var De;(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"})(De||(De={}));var yt;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(yt||(yt={}));class Ap{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=De.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=yt.Strict}startEntity(t){this.decodeMode=t,this.state=De.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case De.EntityStart:return t.charCodeAt(n)===Pe.NUM?(this.state=De.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=De.NamedEntity,this.stateNamedEntity(t,n));case De.NumericStart:return this.stateNumericStart(t,n);case De.NumericDecimal:return this.stateNumericDecimal(t,n);case De.NumericHex:return this.stateNumericHex(t,n);case De.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|kp)===Pe.LOWER_X?(this.state=De.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=De.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(ca(i)||xp(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(ca(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===yt.Strict)return 0;return this.emitCodePoint(_p(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&Dt.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const s=t.charCodeAt(n);if(this.treeIndex=Cp(r,i,this.treeIndex+Math.max(1,a),s),this.treeIndex<0)return this.result===0||this.decodeMode===yt.Attribute&&(a===0||wp(s))?0:this.emitNotTerminatedNamedEntity();if(i=r[this.treeIndex],a=(i&Dt.VALUE_LENGTH)>>14,a!==0){if(s===Pe.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==yt.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]&Dt.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]&~Dt.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case De.NamedEntity:return this.result!==0&&(this.decodeMode!==yt.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case De.NumericDecimal:return this.emitNumericEntity(0,2);case De.NumericHex:return this.emitNumericEntity(0,3);case De.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case De.EntityStart:return 0}}}function Cp(e,t,n,r){const i=(t&Dt.BRANCH_LENGTH)>>7,a=t&Dt.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,l=e[u];if(l<r)s=u+1;else if(l>r)o=u-1;else return e[u+i]}return-1}var M;(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/"})(M||(M={}));var Kt;(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"})(Kt||(Kt={}));var it;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(it||(it={}));var I;(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"})(I||(I={}));var c;(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"})(c||(c={}));const Sp=new Map([[I.A,c.A],[I.ADDRESS,c.ADDRESS],[I.ANNOTATION_XML,c.ANNOTATION_XML],[I.APPLET,c.APPLET],[I.AREA,c.AREA],[I.ARTICLE,c.ARTICLE],[I.ASIDE,c.ASIDE],[I.B,c.B],[I.BASE,c.BASE],[I.BASEFONT,c.BASEFONT],[I.BGSOUND,c.BGSOUND],[I.BIG,c.BIG],[I.BLOCKQUOTE,c.BLOCKQUOTE],[I.BODY,c.BODY],[I.BR,c.BR],[I.BUTTON,c.BUTTON],[I.CAPTION,c.CAPTION],[I.CENTER,c.CENTER],[I.CODE,c.CODE],[I.COL,c.COL],[I.COLGROUP,c.COLGROUP],[I.DD,c.DD],[I.DESC,c.DESC],[I.DETAILS,c.DETAILS],[I.DIALOG,c.DIALOG],[I.DIR,c.DIR],[I.DIV,c.DIV],[I.DL,c.DL],[I.DT,c.DT],[I.EM,c.EM],[I.EMBED,c.EMBED],[I.FIELDSET,c.FIELDSET],[I.FIGCAPTION,c.FIGCAPTION],[I.FIGURE,c.FIGURE],[I.FONT,c.FONT],[I.FOOTER,c.FOOTER],[I.FOREIGN_OBJECT,c.FOREIGN_OBJECT],[I.FORM,c.FORM],[I.FRAME,c.FRAME],[I.FRAMESET,c.FRAMESET],[I.H1,c.H1],[I.H2,c.H2],[I.H3,c.H3],[I.H4,c.H4],[I.H5,c.H5],[I.H6,c.H6],[I.HEAD,c.HEAD],[I.HEADER,c.HEADER],[I.HGROUP,c.HGROUP],[I.HR,c.HR],[I.HTML,c.HTML],[I.I,c.I],[I.IMG,c.IMG],[I.IMAGE,c.IMAGE],[I.INPUT,c.INPUT],[I.IFRAME,c.IFRAME],[I.KEYGEN,c.KEYGEN],[I.LABEL,c.LABEL],[I.LI,c.LI],[I.LINK,c.LINK],[I.LISTING,c.LISTING],[I.MAIN,c.MAIN],[I.MALIGNMARK,c.MALIGNMARK],[I.MARQUEE,c.MARQUEE],[I.MATH,c.MATH],[I.MENU,c.MENU],[I.META,c.META],[I.MGLYPH,c.MGLYPH],[I.MI,c.MI],[I.MO,c.MO],[I.MN,c.MN],[I.MS,c.MS],[I.MTEXT,c.MTEXT],[I.NAV,c.NAV],[I.NOBR,c.NOBR],[I.NOFRAMES,c.NOFRAMES],[I.NOEMBED,c.NOEMBED],[I.NOSCRIPT,c.NOSCRIPT],[I.OBJECT,c.OBJECT],[I.OL,c.OL],[I.OPTGROUP,c.OPTGROUP],[I.OPTION,c.OPTION],[I.P,c.P],[I.PARAM,c.PARAM],[I.PLAINTEXT,c.PLAINTEXT],[I.PRE,c.PRE],[I.RB,c.RB],[I.RP,c.RP],[I.RT,c.RT],[I.RTC,c.RTC],[I.RUBY,c.RUBY],[I.S,c.S],[I.SCRIPT,c.SCRIPT],[I.SEARCH,c.SEARCH],[I.SECTION,c.SECTION],[I.SELECT,c.SELECT],[I.SOURCE,c.SOURCE],[I.SMALL,c.SMALL],[I.SPAN,c.SPAN],[I.STRIKE,c.STRIKE],[I.STRONG,c.STRONG],[I.STYLE,c.STYLE],[I.SUB,c.SUB],[I.SUMMARY,c.SUMMARY],[I.SUP,c.SUP],[I.TABLE,c.TABLE],[I.TBODY,c.TBODY],[I.TEMPLATE,c.TEMPLATE],[I.TEXTAREA,c.TEXTAREA],[I.TFOOT,c.TFOOT],[I.TD,c.TD],[I.TH,c.TH],[I.THEAD,c.THEAD],[I.TITLE,c.TITLE],[I.TR,c.TR],[I.TRACK,c.TRACK],[I.TT,c.TT],[I.U,c.U],[I.UL,c.UL],[I.SVG,c.SVG],[I.VAR,c.VAR],[I.WBR,c.WBR],[I.XMP,c.XMP]]);function An(e){var t;return(t=Sp.get(e))!==null&&t!==void 0?t:c.UNKNOWN}const B=c,vp={[M.HTML]:new Set([B.ADDRESS,B.APPLET,B.AREA,B.ARTICLE,B.ASIDE,B.BASE,B.BASEFONT,B.BGSOUND,B.BLOCKQUOTE,B.BODY,B.BR,B.BUTTON,B.CAPTION,B.CENTER,B.COL,B.COLGROUP,B.DD,B.DETAILS,B.DIR,B.DIV,B.DL,B.DT,B.EMBED,B.FIELDSET,B.FIGCAPTION,B.FIGURE,B.FOOTER,B.FORM,B.FRAME,B.FRAMESET,B.H1,B.H2,B.H3,B.H4,B.H5,B.H6,B.HEAD,B.HEADER,B.HGROUP,B.HR,B.HTML,B.IFRAME,B.IMG,B.INPUT,B.LI,B.LINK,B.LISTING,B.MAIN,B.MARQUEE,B.MENU,B.META,B.NAV,B.NOEMBED,B.NOFRAMES,B.NOSCRIPT,B.OBJECT,B.OL,B.P,B.PARAM,B.PLAINTEXT,B.PRE,B.SCRIPT,B.SECTION,B.SELECT,B.SOURCE,B.STYLE,B.SUMMARY,B.TABLE,B.TBODY,B.TD,B.TEMPLATE,B.TEXTAREA,B.TFOOT,B.TH,B.THEAD,B.TITLE,B.TR,B.TRACK,B.UL,B.WBR,B.XMP]),[M.MATHML]:new Set([B.MI,B.MO,B.MN,B.MS,B.MTEXT,B.ANNOTATION_XML]),[M.SVG]:new Set([B.TITLE,B.FOREIGN_OBJECT,B.DESC]),[M.XLINK]:new Set,[M.XML]:new Set,[M.XMLNS]:new Set},da=new Set([B.H1,B.H2,B.H3,B.H4,B.H5,B.H6]);var T;(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"})(T||(T={}));const Le={DATA:T.DATA,RCDATA:T.RCDATA,RAWTEXT:T.RAWTEXT,SCRIPT_DATA:T.SCRIPT_DATA,PLAINTEXT:T.PLAINTEXT,CDATA_SECTION:T.CDATA_SECTION};function Ip(e){return e>=b.DIGIT_0&&e<=b.DIGIT_9}function Hn(e){return e>=b.LATIN_CAPITAL_A&&e<=b.LATIN_CAPITAL_Z}function Np(e){return e>=b.LATIN_SMALL_A&&e<=b.LATIN_SMALL_Z}function Nt(e){return Np(e)||Hn(e)}function To(e){return Nt(e)||Ip(e)}function xr(e){return e+32}function mc(e){return e===b.SPACE||e===b.LINE_FEED||e===b.TABULATION||e===b.FORM_FEED}function _o(e){return mc(e)||e===b.SOLIDUS||e===b.GREATER_THAN_SIGN}function Lp(e){return e===b.NULL?N.nullCharacterReference:e>1114111?N.characterReferenceOutsideUnicodeRange:dc(e)?N.surrogateCharacterReference:fc(e)?N.noncharacterCharacterReference:hc(e)||e===b.CARRIAGE_RETURN?N.controlCharacterReference:null}class Rp{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=T.DATA,this.returnState=T.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new bp(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new Ap(Ep,(r,i)=>{this.preprocessor.pos=this.entityStartPos+i-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(N.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(N.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const i=Lp(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==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||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:ae.START_TAG,tagName:"",tagID:c.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:ae.END_TAG,tagName:"",tagID:c.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:ae.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:ae.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(pc(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(N.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=An(t.tagName),t.type===ae.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(N.endTagWithAttributes),t.selfClosing&&this._err(N.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 ae.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case ae.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case ae.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:ae.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=mc(t)?ae.WHITESPACE_CHARACTER:t===b.NULL?ae.NULL_CHARACTER:ae.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(ae.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=T.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?yt.Attribute:yt.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===T.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===T.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===T.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case T.DATA:{this._stateData(t);break}case T.RCDATA:{this._stateRcdata(t);break}case T.RAWTEXT:{this._stateRawtext(t);break}case T.SCRIPT_DATA:{this._stateScriptData(t);break}case T.PLAINTEXT:{this._statePlaintext(t);break}case T.TAG_OPEN:{this._stateTagOpen(t);break}case T.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case T.TAG_NAME:{this._stateTagName(t);break}case T.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case T.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case T.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case T.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case T.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case T.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case T.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case T.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case T.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case T.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case T.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case T.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case T.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case T.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case T.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case T.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case T.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case T.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case T.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case T.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case T.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case T.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case T.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case T.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case T.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case T.BOGUS_COMMENT:{this._stateBogusComment(t);break}case T.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case T.COMMENT_START:{this._stateCommentStart(t);break}case T.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case T.COMMENT:{this._stateComment(t);break}case T.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case T.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case T.COMMENT_END:{this._stateCommentEnd(t);break}case T.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case T.DOCTYPE:{this._stateDoctype(t);break}case T.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case T.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case T.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case T.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case T.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case T.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case T.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case T.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case T.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case T.CDATA_SECTION:{this._stateCdataSection(t);break}case T.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case T.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case T.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case T.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.TAG_OPEN;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitCodePoint(t);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case b.AMPERSAND:{this._startCharacterReference();break}case b.LESS_THAN_SIGN:{this.state=T.RCDATA_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.RAWTEXT_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Nt(t))this._createStartTagToken(),this.state=T.TAG_NAME,this._stateTagName(t);else switch(t){case b.EXCLAMATION_MARK:{this.state=T.MARKUP_DECLARATION_OPEN;break}case b.SOLIDUS:{this.state=T.END_TAG_OPEN;break}case b.QUESTION_MARK:{this._err(N.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t);break}case b.EOF:{this._err(N.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(N.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=T.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Nt(t))this._createEndTagToken(),this.state=T.TAG_NAME,this._stateTagName(t);else switch(t){case b.GREATER_THAN_SIGN:{this._err(N.missingEndTagName),this.state=T.DATA;break}case b.EOF:{this._err(N.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(N.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.SOLIDUS:{this.state=T.SELF_CLOSING_START_TAG;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentTagToken();break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.tagName+=we;break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(Hn(t)?xr(t):t)}}_stateRcdataLessThanSign(t){t===b.SOLIDUS?this.state=T.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=T.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Nt(t)?(this.state=T.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=T.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 b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=T.BEFORE_ATTRIBUTE_NAME,!1;case b.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=T.SELF_CLOSING_START_TAG,!1;case b.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=T.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===b.SOLIDUS?this.state=T.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Nt(t)?(this.state=T.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case b.SOLIDUS:{this.state=T.SCRIPT_DATA_END_TAG_OPEN;break}case b.EXCLAMATION_MARK:{this.state=T.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=T.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Nt(t)?(this.state=T.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===b.HYPHEN_MINUS?(this.state=T.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===b.HYPHEN_MINUS?(this.state=T.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_ESCAPED,this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case b.HYPHEN_MINUS:{this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.GREATER_THAN_SIGN:{this.state=T.SCRIPT_DATA,this._emitChars(">");break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_ESCAPED,this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===b.SOLIDUS?this.state=T.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Nt(t)?(this._emitChars("<"),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Nt(t)?(this.state=T.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(Ve.SCRIPT,!1)&&_o(this.preprocessor.peek(Ve.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Ve.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case b.HYPHEN_MINUS:{this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.GREATER_THAN_SIGN:{this.state=T.SCRIPT_DATA,this._emitChars(">");break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===b.SOLIDUS?(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(Ve.SCRIPT,!1)&&_o(this.preprocessor.peek(Ve.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Ve.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=T.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.SOLIDUS:case b.GREATER_THAN_SIGN:case b.EOF:{this.state=T.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case b.EQUALS_SIGN:{this._err(N.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=T.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=T.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:case b.SOLIDUS:case b.GREATER_THAN_SIGN:case b.EOF:{this._leaveAttrName(),this.state=T.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case b.EQUALS_SIGN:{this._leaveAttrName(),this.state=T.BEFORE_ATTRIBUTE_VALUE;break}case b.QUOTATION_MARK:case b.APOSTROPHE:case b.LESS_THAN_SIGN:{this._err(N.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.name+=we;break}default:this.currentAttr.name+=String.fromCodePoint(Hn(t)?xr(t):t)}}_stateAfterAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.SOLIDUS:{this.state=T.SELF_CLOSING_START_TAG;break}case b.EQUALS_SIGN:{this.state=T.BEFORE_ATTRIBUTE_VALUE;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=T.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{this.state=T.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this.state=T.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingAttributeValue),this.state=T.DATA,this.emitCurrentTagToken();break}default:this.state=T.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=we;break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case b.APOSTROPHE:{this.state=T.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=we;break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this._leaveAttrValue(),this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=T.DATA,this.emitCurrentTagToken();break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=we;break}case b.QUOTATION_MARK:case b.APOSTROPHE:case b.LESS_THAN_SIGN:case b.EQUALS_SIGN:case b.GRAVE_ACCENT:{this._err(N.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this._leaveAttrValue(),this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.SOLIDUS:{this._leaveAttrValue(),this.state=T.SELF_CLOSING_START_TAG;break}case b.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._err(N.missingWhitespaceBetweenAttributes),this.state=T.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case b.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._err(N.unexpectedSolidusInTag),this.state=T.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.data+=we;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(Ve.DASH_DASH,!0)?(this._createCommentToken(Ve.DASH_DASH.length+1),this.state=T.COMMENT_START):this._consumeSequenceIfMatch(Ve.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(Ve.DOCTYPE.length+1),this.state=T.DOCTYPE):this._consumeSequenceIfMatch(Ve.CDATA_START,!0)?this.inForeignNode?this.state=T.CDATA_SECTION:(this._err(N.cdataInHtmlContent),this._createCommentToken(Ve.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=T.BOGUS_COMMENT):this._ensureHibernation()||(this._err(N.incorrectlyOpenedComment),this._createCommentToken(2),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_START_DASH;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptClosingOfEmptyComment),this.state=T.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=T.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptClosingOfEmptyComment),this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=T.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END_DASH;break}case b.LESS_THAN_SIGN:{n.data+="<",this.state=T.COMMENT_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.data+=we;break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case b.EXCLAMATION_MARK:{n.data+="!",this.state=T.COMMENT_LESS_THAN_SIGN_BANG;break}case b.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=T.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===b.HYPHEN_MINUS?this.state=T.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=T.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===b.HYPHEN_MINUS?this.state=T.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=T.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==b.GREATER_THAN_SIGN&&t!==b.EOF&&this._err(N.nestedComment),this.state=T.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END;break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=T.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentComment(n);break}case b.EXCLAMATION_MARK:{this.state=T.COMMENT_END_BANG;break}case b.HYPHEN_MINUS:{n.data+="-";break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=T.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{n.data+="--!",this.state=T.COMMENT_END_DASH;break}case b.GREATER_THAN_SIGN:{this._err(N.incorrectlyClosedComment),this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=T.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this.state=T.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case b.EOF:{this._err(N.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingWhitespaceBeforeDoctypeName),this.state=T.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(Hn(t))this._createDoctypeToken(String.fromCharCode(xr(t))),this.state=T.DOCTYPE_NAME;else switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.NULL:{this._err(N.unexpectedNullCharacter),this._createDoctypeToken(we),this.state=T.DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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=T.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.AFTER_DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.name+=we;break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(Hn(t)?xr(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(Ve.PUBLIC,!1)?this.state=T.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(Ve.SYSTEM,!1)?this.state=T.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(N.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.QUOTATION_MARK:{this._err(N.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(N.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.publicId+=we;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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 b.APOSTROPHE:{this.state=T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.publicId+=we;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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 b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.QUOTATION_MARK:{this._err(N.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(N.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.QUOTATION_MARK:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.QUOTATION_MARK:{this._err(N.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(N.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.systemId+=we;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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 b.APOSTROPHE:{this.state=T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.systemId+=we;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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 b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.NULL:{this._err(N.unexpectedNullCharacter);break}case b.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case b.RIGHT_SQUARE_BRACKET:{this.state=T.CDATA_SECTION_BRACKET;break}case b.EOF:{this._err(N.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===b.RIGHT_SQUARE_BRACKET?this.state=T.CDATA_SECTION_END:(this._emitChars("]"),this.state=T.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA;break}case b.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=T.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(b.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&To(this.preprocessor.peek(1))?T.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){To(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===b.SEMICOLON&&this._err(N.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const gc=new Set([c.DD,c.DT,c.LI,c.OPTGROUP,c.OPTION,c.P,c.RB,c.RP,c.RT,c.RTC]),ko=new Set([...gc,c.CAPTION,c.COLGROUP,c.TBODY,c.TD,c.TFOOT,c.TH,c.THEAD,c.TR]),Qr=new Set([c.APPLET,c.CAPTION,c.HTML,c.MARQUEE,c.OBJECT,c.TABLE,c.TD,c.TEMPLATE,c.TH]),Op=new Set([...Qr,c.OL,c.UL]),Dp=new Set([...Qr,c.BUTTON]),xo=new Set([c.ANNOTATION_XML,c.MI,c.MN,c.MO,c.MS,c.MTEXT]),yo=new Set([c.DESC,c.FOREIGN_OBJECT,c.TITLE]),Pp=new Set([c.TR,c.TEMPLATE,c.HTML]),Mp=new Set([c.TBODY,c.TFOOT,c.THEAD,c.TEMPLATE,c.HTML]),Bp=new Set([c.TABLE,c.TEMPLATE,c.HTML]),Fp=new Set([c.TD,c.TH]);class Hp{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=c.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===c.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===M.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])!==M.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(da,M.HTML)}popUntilTableCellPopped(){this.popUntilPopped(Fp,M.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(Bp,M.HTML)}clearBackToTableBodyContext(){this.clearBackTo(Mp,M.HTML)}clearBackToTableRowContext(){this.clearBackTo(Pp,M.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]===c.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]===c.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 M.HTML:{if(i===t)return!0;if(n.has(i))return!1;break}case M.SVG:{if(yo.has(i))return!1;break}case M.MATHML:{if(xo.has(i))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Qr)}hasInListItemScope(t){return this.hasInDynamicScope(t,Op)}hasInButtonScope(t){return this.hasInDynamicScope(t,Dp)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case M.HTML:{if(da.has(n))return!0;if(Qr.has(n))return!1;break}case M.SVG:{if(yo.has(n))return!1;break}case M.MATHML:{if(xo.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===M.HTML)switch(this.tagIDs[n]){case t:return!0;case c.TABLE:case c.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===M.HTML)switch(this.tagIDs[t]){case c.TBODY:case c.THEAD:case c.TFOOT:return!0;case c.TABLE:case c.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===M.HTML)switch(this.tagIDs[n]){case t:return!0;case c.OPTION:case c.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&gc.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&ko.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&ko.has(this.currentTagId);)this.pop()}}const Pi=3;var ft;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(ft||(ft={}));const wo={type:ft.Marker};class Up{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===ft.Marker)break;const{element:l}=u;if(this.treeAdapter.getTagName(l)===a&&this.treeAdapter.getNamespaceURI(l)===s){const h=this.treeAdapter.getAttrList(l);h.length===i&&r.push({idx:o,attrs:h})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<Pi)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<Pi)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>=Pi&&this.entries.splice(o.idx,1))}}insertMarker(){this.entries.unshift(wo)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:ft.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:ft.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(wo);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===ft.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===ft.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===ft.Element&&n.element===t)}}const Lt={createDocument(){return{nodeName:"#document",mode:it.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}}},bc="html",zp="about:legacy-compat",$p="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",Ec=["+//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//"],Yp=[...Ec,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],jp=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),Tc=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],Vp=[...Tc,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function Ao(e,t){return t.some(n=>e.startsWith(n))}function qp(e){return e.name===bc&&e.publicId===null&&(e.systemId===null||e.systemId===zp)}function Wp(e){if(e.name!==bc)return it.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===$p)return it.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),jp.has(n))return it.QUIRKS;let r=t===null?Yp:Ec;if(Ao(n,r))return it.QUIRKS;if(r=t===null?Tc:Vp,Ao(n,r))return it.LIMITED_QUIRKS}return it.NO_QUIRKS}const Co={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},Gp="definitionurl",Qp="definitionURL",Kp=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])),Xp=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:M.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:M.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:M.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:M.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:M.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:M.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:M.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:M.XML}],["xml:space",{prefix:"xml",name:"space",namespace:M.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:M.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:M.XMLNS}]]),Zp=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])),Jp=new Set([c.B,c.BIG,c.BLOCKQUOTE,c.BODY,c.BR,c.CENTER,c.CODE,c.DD,c.DIV,c.DL,c.DT,c.EM,c.EMBED,c.H1,c.H2,c.H3,c.H4,c.H5,c.H6,c.HEAD,c.HR,c.I,c.IMG,c.LI,c.LISTING,c.MENU,c.META,c.NOBR,c.OL,c.P,c.PRE,c.RUBY,c.S,c.SMALL,c.SPAN,c.STRONG,c.STRIKE,c.SUB,c.SUP,c.TABLE,c.TT,c.U,c.UL,c.VAR]);function e1(e){const t=e.tagID;return t===c.FONT&&e.attrs.some(({name:r})=>r===Kt.COLOR||r===Kt.SIZE||r===Kt.FACE)||Jp.has(t)}function _c(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===Gp){e.attrs[t].name=Qp;break}}function kc(e){for(let t=0;t<e.attrs.length;t++){const n=Kp.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function Ka(e){for(let t=0;t<e.attrs.length;t++){const n=Xp.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 t1(e){const t=Zp.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=An(e.tagName))}function n1(e,t){return t===M.MATHML&&(e===c.MI||e===c.MO||e===c.MN||e===c.MS||e===c.MTEXT)}function r1(e,t,n){if(t===M.MATHML&&e===c.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Kt.ENCODING){const i=n[r].value.toLowerCase();return i===Co.TEXT_HTML||i===Co.APPLICATION_XML}}return t===M.SVG&&(e===c.FOREIGN_OBJECT||e===c.DESC||e===c.TITLE)}function i1(e,t,n,r){return(!r||r===M.HTML)&&r1(e,t,n)||(!r||r===M.MATHML)&&n1(e,t)}const a1="hidden",s1=8,o1=3;var y;(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"})(y||(y={}));const u1={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},xc=new Set([c.TABLE,c.TBODY,c.TFOOT,c.THEAD,c.TR]),So={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Lt,onParseError:null};class vo{constructor(t,n,r=null,i=null){this.fragmentContext=r,this.scriptHandler=i,this.currentToken=null,this.stopped=!1,this.insertionMode=y.INITIAL,this.originalInsertionMode=y.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={...So,...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 Rp(this.options,this),this.activeFormattingElements=new Up(this.treeAdapter),this.fragmentContextID=r?An(this.treeAdapter.getTagName(r)):c.UNKNOWN,this._setContextModes(r??this.document,this.fragmentContextID),this.openElements=new Hp(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={...So,...n};t??(t=r.treeAdapter.createElement(I.TEMPLATE,M.HTML,[]));const i=r.treeAdapter.createElement("documentmock",M.HTML,[]),a=new this(r,i,t);return a.fragmentContextID===c.TEMPLATE&&a.tmplInsertionModeStack.unshift(y.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:u1,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)===M.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,M.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=y.TEXT}switchToPlaintextParsing(){this.insertionMode=y.TEXT,this.originalInsertionMode=y.IN_BODY,this.tokenizer.state=Le.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)===I.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==M.HTML))switch(this.fragmentContextID){case c.TITLE:case c.TEXTAREA:{this.tokenizer.state=Le.RCDATA;break}case c.STYLE:case c.XMP:case c.IFRAME:case c.NOEMBED:case c.NOFRAMES:case c.NOSCRIPT:{this.tokenizer.state=Le.RAWTEXT;break}case c.SCRIPT:{this.tokenizer.state=Le.SCRIPT_DATA;break}case c.PLAINTEXT:{this.tokenizer.state=Le.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,M.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,M.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(I.HTML,M.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,c.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:l,endOffset:h}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(s,{endLine:u,endCol:l,endOffset:h})}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===ae.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===c.SVG&&this.treeAdapter.getTagName(n)===I.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===M.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===c.MGLYPH||t.tagID===c.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,M.HTML)}_processToken(t){switch(t.type){case ae.CHARACTER:{this.onCharacter(t);break}case ae.NULL_CHARACTER:{this.onNullCharacter(t);break}case ae.COMMENT:{this.onComment(t);break}case ae.DOCTYPE:{this.onDoctype(t);break}case ae.START_TAG:{this._processStartTag(t);break}case ae.END_TAG:{this.onEndTag(t);break}case ae.EOF:{this.onEof(t);break}case ae.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return i1(t,i,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===ft.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=y.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(c.P),this.openElements.popUntilTagNamePopped(c.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case c.TR:{this.insertionMode=y.IN_ROW;return}case c.TBODY:case c.THEAD:case c.TFOOT:{this.insertionMode=y.IN_TABLE_BODY;return}case c.CAPTION:{this.insertionMode=y.IN_CAPTION;return}case c.COLGROUP:{this.insertionMode=y.IN_COLUMN_GROUP;return}case c.TABLE:{this.insertionMode=y.IN_TABLE;return}case c.BODY:{this.insertionMode=y.IN_BODY;return}case c.FRAMESET:{this.insertionMode=y.IN_FRAMESET;return}case c.SELECT:{this._resetInsertionModeForSelect(t);return}case c.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case c.HTML:{this.insertionMode=this.headElement?y.AFTER_HEAD:y.BEFORE_HEAD;return}case c.TD:case c.TH:{if(t>0){this.insertionMode=y.IN_CELL;return}break}case c.HEAD:{if(t>0){this.insertionMode=y.IN_HEAD;return}break}}this.insertionMode=y.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===c.TEMPLATE)break;if(r===c.TABLE){this.insertionMode=y.IN_SELECT_IN_TABLE;return}}this.insertionMode=y.IN_SELECT}_isElementCausesFosterParenting(t){return xc.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 c.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===M.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case c.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 vp[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Fm(this,t);return}switch(this.insertionMode){case y.INITIAL:{Rn(this,t);break}case y.BEFORE_HTML:{qn(this,t);break}case y.BEFORE_HEAD:{Wn(this,t);break}case y.IN_HEAD:{Gn(this,t);break}case y.IN_HEAD_NO_SCRIPT:{Qn(this,t);break}case y.AFTER_HEAD:{Kn(this,t);break}case y.IN_BODY:case y.IN_CAPTION:case y.IN_CELL:case y.IN_TEMPLATE:{wc(this,t);break}case y.TEXT:case y.IN_SELECT:case y.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case y.IN_TABLE:case y.IN_TABLE_BODY:case y.IN_ROW:{Mi(this,t);break}case y.IN_TABLE_TEXT:{Nc(this,t);break}case y.IN_COLUMN_GROUP:{Kr(this,t);break}case y.AFTER_BODY:{Xr(this,t);break}case y.AFTER_AFTER_BODY:{Br(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Bm(this,t);return}switch(this.insertionMode){case y.INITIAL:{Rn(this,t);break}case y.BEFORE_HTML:{qn(this,t);break}case y.BEFORE_HEAD:{Wn(this,t);break}case y.IN_HEAD:{Gn(this,t);break}case y.IN_HEAD_NO_SCRIPT:{Qn(this,t);break}case y.AFTER_HEAD:{Kn(this,t);break}case y.TEXT:{this._insertCharacters(t);break}case y.IN_TABLE:case y.IN_TABLE_BODY:case y.IN_ROW:{Mi(this,t);break}case y.IN_COLUMN_GROUP:{Kr(this,t);break}case y.AFTER_BODY:{Xr(this,t);break}case y.AFTER_AFTER_BODY:{Br(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){ha(this,t);return}switch(this.insertionMode){case y.INITIAL:case y.BEFORE_HTML:case y.BEFORE_HEAD:case y.IN_HEAD:case y.IN_HEAD_NO_SCRIPT:case y.AFTER_HEAD:case y.IN_BODY:case y.IN_TABLE:case y.IN_CAPTION:case y.IN_COLUMN_GROUP:case y.IN_TABLE_BODY:case y.IN_ROW:case y.IN_CELL:case y.IN_SELECT:case y.IN_SELECT_IN_TABLE:case y.IN_TEMPLATE:case y.IN_FRAMESET:case y.AFTER_FRAMESET:{ha(this,t);break}case y.IN_TABLE_TEXT:{On(this,t);break}case y.AFTER_BODY:{m1(this,t);break}case y.AFTER_AFTER_BODY:case y.AFTER_AFTER_FRAMESET:{g1(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case y.INITIAL:{b1(this,t);break}case y.BEFORE_HEAD:case y.IN_HEAD:case y.IN_HEAD_NO_SCRIPT:case y.AFTER_HEAD:{this._err(t,N.misplacedDoctype);break}case y.IN_TABLE_TEXT:{On(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,N.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?Hm(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case y.INITIAL:{Rn(this,t);break}case y.BEFORE_HTML:{E1(this,t);break}case y.BEFORE_HEAD:{_1(this,t);break}case y.IN_HEAD:{ct(this,t);break}case y.IN_HEAD_NO_SCRIPT:{y1(this,t);break}case y.AFTER_HEAD:{A1(this,t);break}case y.IN_BODY:{Fe(this,t);break}case y.IN_TABLE:{En(this,t);break}case y.IN_TABLE_TEXT:{On(this,t);break}case y.IN_CAPTION:{km(this,t);break}case y.IN_COLUMN_GROUP:{Ja(this,t);break}case y.IN_TABLE_BODY:{bi(this,t);break}case y.IN_ROW:{Ei(this,t);break}case y.IN_CELL:{wm(this,t);break}case y.IN_SELECT:{Oc(this,t);break}case y.IN_SELECT_IN_TABLE:{Cm(this,t);break}case y.IN_TEMPLATE:{vm(this,t);break}case y.AFTER_BODY:{Nm(this,t);break}case y.IN_FRAMESET:{Lm(this,t);break}case y.AFTER_FRAMESET:{Om(this,t);break}case y.AFTER_AFTER_BODY:{Pm(this,t);break}case y.AFTER_AFTER_FRAMESET:{Mm(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?Um(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case y.INITIAL:{Rn(this,t);break}case y.BEFORE_HTML:{T1(this,t);break}case y.BEFORE_HEAD:{k1(this,t);break}case y.IN_HEAD:{x1(this,t);break}case y.IN_HEAD_NO_SCRIPT:{w1(this,t);break}case y.AFTER_HEAD:{C1(this,t);break}case y.IN_BODY:{gi(this,t);break}case y.TEXT:{dm(this,t);break}case y.IN_TABLE:{ar(this,t);break}case y.IN_TABLE_TEXT:{On(this,t);break}case y.IN_CAPTION:{xm(this,t);break}case y.IN_COLUMN_GROUP:{ym(this,t);break}case y.IN_TABLE_BODY:{fa(this,t);break}case y.IN_ROW:{Rc(this,t);break}case y.IN_CELL:{Am(this,t);break}case y.IN_SELECT:{Dc(this,t);break}case y.IN_SELECT_IN_TABLE:{Sm(this,t);break}case y.IN_TEMPLATE:{Im(this,t);break}case y.AFTER_BODY:{Mc(this,t);break}case y.IN_FRAMESET:{Rm(this,t);break}case y.AFTER_FRAMESET:{Dm(this,t);break}case y.AFTER_AFTER_BODY:{Br(this,t);break}}}onEof(t){switch(this.insertionMode){case y.INITIAL:{Rn(this,t);break}case y.BEFORE_HTML:{qn(this,t);break}case y.BEFORE_HEAD:{Wn(this,t);break}case y.IN_HEAD:{Gn(this,t);break}case y.IN_HEAD_NO_SCRIPT:{Qn(this,t);break}case y.AFTER_HEAD:{Kn(this,t);break}case y.IN_BODY:case y.IN_TABLE:case y.IN_CAPTION:case y.IN_COLUMN_GROUP:case y.IN_TABLE_BODY:case y.IN_ROW:case y.IN_CELL:case y.IN_SELECT:case y.IN_SELECT_IN_TABLE:{vc(this,t);break}case y.TEXT:{hm(this,t);break}case y.IN_TABLE_TEXT:{On(this,t);break}case y.IN_TEMPLATE:{Pc(this,t);break}case y.AFTER_BODY:case y.IN_FRAMESET:case y.AFTER_FRAMESET:case y.AFTER_AFTER_BODY:case y.AFTER_AFTER_FRAMESET:{Za(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===b.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 y.IN_HEAD:case y.IN_HEAD_NO_SCRIPT:case y.AFTER_HEAD:case y.TEXT:case y.IN_COLUMN_GROUP:case y.IN_SELECT:case y.IN_SELECT_IN_TABLE:case y.IN_FRAMESET:case y.AFTER_FRAMESET:{this._insertCharacters(t);break}case y.IN_BODY:case y.IN_CAPTION:case y.IN_CELL:case y.IN_TEMPLATE:case y.AFTER_BODY:case y.AFTER_AFTER_BODY:case y.AFTER_AFTER_FRAMESET:{yc(this,t);break}case y.IN_TABLE:case y.IN_TABLE_BODY:case y.IN_ROW:{Mi(this,t);break}case y.IN_TABLE_TEXT:{Ic(this,t);break}}}}function l1(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):Sc(e,t),n}function c1(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 d1(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>=o1;!o||u?(u&&e.activeFormattingElements.removeEntry(o),e.openElements.remove(s)):(s=h1(e,o),r===t&&(e.activeFormattingElements.bookmark=o),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(s,r),r=s)}return r}function h1(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 f1(e,t,n){const r=e.treeAdapter.getTagName(t),i=An(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);i===c.TEMPLATE&&a===M.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function p1(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 Xa(e,t){for(let n=0;n<s1;n++){const r=l1(e,t);if(!r)break;const i=c1(e,r);if(!i)break;e.activeFormattingElements.bookmark=r;const a=d1(e,i,r.element),s=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),s&&f1(e,s,a),p1(e,i,r)}}function ha(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function m1(e,t){e._appendCommentNode(t,e.openElements.items[0])}function g1(e,t){e._appendCommentNode(t,e.document)}function Za(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 b1(e,t){e._setDocumentType(t);const n=t.forceQuirks?it.QUIRKS:Wp(t);qp(t)||e._err(t,N.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=y.BEFORE_HTML}function Rn(e,t){e._err(t,N.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,it.QUIRKS),e.insertionMode=y.BEFORE_HTML,e._processToken(t)}function E1(e,t){t.tagID===c.HTML?(e._insertElement(t,M.HTML),e.insertionMode=y.BEFORE_HEAD):qn(e,t)}function T1(e,t){const n=t.tagID;(n===c.HTML||n===c.HEAD||n===c.BODY||n===c.BR)&&qn(e,t)}function qn(e,t){e._insertFakeRootElement(),e.insertionMode=y.BEFORE_HEAD,e._processToken(t)}function _1(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.HEAD:{e._insertElement(t,M.HTML),e.headElement=e.openElements.current,e.insertionMode=y.IN_HEAD;break}default:Wn(e,t)}}function k1(e,t){const n=t.tagID;n===c.HEAD||n===c.BODY||n===c.HTML||n===c.BR?Wn(e,t):e._err(t,N.endTagWithoutMatchingOpenElement)}function Wn(e,t){e._insertFakeElement(I.HEAD,c.HEAD),e.headElement=e.openElements.current,e.insertionMode=y.IN_HEAD,e._processToken(t)}function ct(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.BASE:case c.BASEFONT:case c.BGSOUND:case c.LINK:case c.META:{e._appendElement(t,M.HTML),t.ackSelfClosing=!0;break}case c.TITLE:{e._switchToTextParsing(t,Le.RCDATA);break}case c.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,Le.RAWTEXT):(e._insertElement(t,M.HTML),e.insertionMode=y.IN_HEAD_NO_SCRIPT);break}case c.NOFRAMES:case c.STYLE:{e._switchToTextParsing(t,Le.RAWTEXT);break}case c.SCRIPT:{e._switchToTextParsing(t,Le.SCRIPT_DATA);break}case c.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=y.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(y.IN_TEMPLATE);break}case c.HEAD:{e._err(t,N.misplacedStartTagForHeadElement);break}default:Gn(e,t)}}function x1(e,t){switch(t.tagID){case c.HEAD:{e.openElements.pop(),e.insertionMode=y.AFTER_HEAD;break}case c.BODY:case c.BR:case c.HTML:{Gn(e,t);break}case c.TEMPLATE:{nn(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function nn(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==c.TEMPLATE&&e._err(t,N.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(c.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,N.endTagWithoutMatchingOpenElement)}function Gn(e,t){e.openElements.pop(),e.insertionMode=y.AFTER_HEAD,e._processToken(t)}function y1(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.BASEFONT:case c.BGSOUND:case c.HEAD:case c.LINK:case c.META:case c.NOFRAMES:case c.STYLE:{ct(e,t);break}case c.NOSCRIPT:{e._err(t,N.nestedNoscriptInHead);break}default:Qn(e,t)}}function w1(e,t){switch(t.tagID){case c.NOSCRIPT:{e.openElements.pop(),e.insertionMode=y.IN_HEAD;break}case c.BR:{Qn(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function Qn(e,t){const n=t.type===ae.EOF?N.openElementsLeftAfterEof:N.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=y.IN_HEAD,e._processToken(t)}function A1(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.BODY:{e._insertElement(t,M.HTML),e.framesetOk=!1,e.insertionMode=y.IN_BODY;break}case c.FRAMESET:{e._insertElement(t,M.HTML),e.insertionMode=y.IN_FRAMESET;break}case c.BASE:case c.BASEFONT:case c.BGSOUND:case c.LINK:case c.META:case c.NOFRAMES:case c.SCRIPT:case c.STYLE:case c.TEMPLATE:case c.TITLE:{e._err(t,N.abandonedHeadElementChild),e.openElements.push(e.headElement,c.HEAD),ct(e,t),e.openElements.remove(e.headElement);break}case c.HEAD:{e._err(t,N.misplacedStartTagForHeadElement);break}default:Kn(e,t)}}function C1(e,t){switch(t.tagID){case c.BODY:case c.HTML:case c.BR:{Kn(e,t);break}case c.TEMPLATE:{nn(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function Kn(e,t){e._insertFakeElement(I.BODY,c.BODY),e.insertionMode=y.IN_BODY,mi(e,t)}function mi(e,t){switch(t.type){case ae.CHARACTER:{wc(e,t);break}case ae.WHITESPACE_CHARACTER:{yc(e,t);break}case ae.COMMENT:{ha(e,t);break}case ae.START_TAG:{Fe(e,t);break}case ae.END_TAG:{gi(e,t);break}case ae.EOF:{vc(e,t);break}}}function yc(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function wc(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function S1(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function v1(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function I1(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,M.HTML),e.insertionMode=y.IN_FRAMESET)}function N1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,M.HTML)}function L1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&da.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,M.HTML)}function R1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,M.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function O1(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,M.HTML),n||(e.formElement=e.openElements.current))}function D1(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===c.LI&&i===c.LI||(n===c.DD||n===c.DT)&&(i===c.DD||i===c.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==c.ADDRESS&&i!==c.DIV&&i!==c.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,M.HTML)}function P1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,M.HTML),e.tokenizer.state=Le.PLAINTEXT}function M1(e,t){e.openElements.hasInScope(c.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(c.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,M.HTML),e.framesetOk=!1}function B1(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(I.A);n&&(Xa(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,M.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function F1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,M.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function H1(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(c.NOBR)&&(Xa(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,M.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function U1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,M.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function z1(e,t){e.treeAdapter.getDocumentMode(e.document)!==it.QUIRKS&&e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,M.HTML),e.framesetOk=!1,e.insertionMode=y.IN_TABLE}function Ac(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,M.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Cc(e){const t=pc(e,Kt.TYPE);return t!=null&&t.toLowerCase()===a1}function $1(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,M.HTML),Cc(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function Y1(e,t){e._appendElement(t,M.HTML),t.ackSelfClosing=!0}function j1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._appendElement(t,M.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function V1(e,t){t.tagName=I.IMG,t.tagID=c.IMG,Ac(e,t)}function q1(e,t){e._insertElement(t,M.HTML),e.skipNextNewLine=!0,e.tokenizer.state=Le.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=y.TEXT}function W1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,Le.RAWTEXT)}function G1(e,t){e.framesetOk=!1,e._switchToTextParsing(t,Le.RAWTEXT)}function Io(e,t){e._switchToTextParsing(t,Le.RAWTEXT)}function Q1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,M.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===y.IN_TABLE||e.insertionMode===y.IN_CAPTION||e.insertionMode===y.IN_TABLE_BODY||e.insertionMode===y.IN_ROW||e.insertionMode===y.IN_CELL?y.IN_SELECT_IN_TABLE:y.IN_SELECT}function K1(e,t){e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,M.HTML)}function X1(e,t){e.openElements.hasInScope(c.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,M.HTML)}function Z1(e,t){e.openElements.hasInScope(c.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(c.RTC),e._insertElement(t,M.HTML)}function J1(e,t){e._reconstructActiveFormattingElements(),_c(t),Ka(t),t.selfClosing?e._appendElement(t,M.MATHML):e._insertElement(t,M.MATHML),t.ackSelfClosing=!0}function em(e,t){e._reconstructActiveFormattingElements(),kc(t),Ka(t),t.selfClosing?e._appendElement(t,M.SVG):e._insertElement(t,M.SVG),t.ackSelfClosing=!0}function No(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,M.HTML)}function Fe(e,t){switch(t.tagID){case c.I:case c.S:case c.B:case c.U:case c.EM:case c.TT:case c.BIG:case c.CODE:case c.FONT:case c.SMALL:case c.STRIKE:case c.STRONG:{F1(e,t);break}case c.A:{B1(e,t);break}case c.H1:case c.H2:case c.H3:case c.H4:case c.H5:case c.H6:{L1(e,t);break}case c.P:case c.DL:case c.OL:case c.UL:case c.DIV:case c.DIR:case c.NAV:case c.MAIN:case c.MENU:case c.ASIDE:case c.CENTER:case c.FIGURE:case c.FOOTER:case c.HEADER:case c.HGROUP:case c.DIALOG:case c.DETAILS:case c.ADDRESS:case c.ARTICLE:case c.SEARCH:case c.SECTION:case c.SUMMARY:case c.FIELDSET:case c.BLOCKQUOTE:case c.FIGCAPTION:{N1(e,t);break}case c.LI:case c.DD:case c.DT:{D1(e,t);break}case c.BR:case c.IMG:case c.WBR:case c.AREA:case c.EMBED:case c.KEYGEN:{Ac(e,t);break}case c.HR:{j1(e,t);break}case c.RB:case c.RTC:{X1(e,t);break}case c.RT:case c.RP:{Z1(e,t);break}case c.PRE:case c.LISTING:{R1(e,t);break}case c.XMP:{W1(e,t);break}case c.SVG:{em(e,t);break}case c.HTML:{S1(e,t);break}case c.BASE:case c.LINK:case c.META:case c.STYLE:case c.TITLE:case c.SCRIPT:case c.BGSOUND:case c.BASEFONT:case c.TEMPLATE:{ct(e,t);break}case c.BODY:{v1(e,t);break}case c.FORM:{O1(e,t);break}case c.NOBR:{H1(e,t);break}case c.MATH:{J1(e,t);break}case c.TABLE:{z1(e,t);break}case c.INPUT:{$1(e,t);break}case c.PARAM:case c.TRACK:case c.SOURCE:{Y1(e,t);break}case c.IMAGE:{V1(e,t);break}case c.BUTTON:{M1(e,t);break}case c.APPLET:case c.OBJECT:case c.MARQUEE:{U1(e,t);break}case c.IFRAME:{G1(e,t);break}case c.SELECT:{Q1(e,t);break}case c.OPTION:case c.OPTGROUP:{K1(e,t);break}case c.NOEMBED:case c.NOFRAMES:{Io(e,t);break}case c.FRAMESET:{I1(e,t);break}case c.TEXTAREA:{q1(e,t);break}case c.NOSCRIPT:{e.options.scriptingEnabled?Io(e,t):No(e,t);break}case c.PLAINTEXT:{P1(e,t);break}case c.COL:case c.TH:case c.TD:case c.TR:case c.HEAD:case c.FRAME:case c.TBODY:case c.TFOOT:case c.THEAD:case c.CAPTION:case c.COLGROUP:break;default:No(e,t)}}function tm(e,t){if(e.openElements.hasInScope(c.BODY)&&(e.insertionMode=y.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function nm(e,t){e.openElements.hasInScope(c.BODY)&&(e.insertionMode=y.AFTER_BODY,Mc(e,t))}function rm(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function im(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(c.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(c.FORM):n&&e.openElements.remove(n))}function am(e){e.openElements.hasInButtonScope(c.P)||e._insertFakeElement(I.P,c.P),e._closePElement()}function sm(e){e.openElements.hasInListItemScope(c.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(c.LI),e.openElements.popUntilTagNamePopped(c.LI))}function om(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function um(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function lm(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function cm(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(I.BR,c.BR),e.openElements.pop(),e.framesetOk=!1}function Sc(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!==c.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 gi(e,t){switch(t.tagID){case c.A:case c.B:case c.I:case c.S:case c.U:case c.EM:case c.TT:case c.BIG:case c.CODE:case c.FONT:case c.NOBR:case c.SMALL:case c.STRIKE:case c.STRONG:{Xa(e,t);break}case c.P:{am(e);break}case c.DL:case c.UL:case c.OL:case c.DIR:case c.DIV:case c.NAV:case c.PRE:case c.MAIN:case c.MENU:case c.ASIDE:case c.BUTTON:case c.CENTER:case c.FIGURE:case c.FOOTER:case c.HEADER:case c.HGROUP:case c.DIALOG:case c.ADDRESS:case c.ARTICLE:case c.DETAILS:case c.SEARCH:case c.SECTION:case c.SUMMARY:case c.LISTING:case c.FIELDSET:case c.BLOCKQUOTE:case c.FIGCAPTION:{rm(e,t);break}case c.LI:{sm(e);break}case c.DD:case c.DT:{om(e,t);break}case c.H1:case c.H2:case c.H3:case c.H4:case c.H5:case c.H6:{um(e);break}case c.BR:{cm(e);break}case c.BODY:{tm(e,t);break}case c.HTML:{nm(e,t);break}case c.FORM:{im(e);break}case c.APPLET:case c.OBJECT:case c.MARQUEE:{lm(e,t);break}case c.TEMPLATE:{nn(e,t);break}default:Sc(e,t)}}function vc(e,t){e.tmplInsertionModeStack.length>0?Pc(e,t):Za(e,t)}function dm(e,t){var n;t.tagID===c.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function hm(e,t){e._err(t,N.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Mi(e,t){if(e.openElements.currentTagId!==void 0&&xc.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=y.IN_TABLE_TEXT,t.type){case ae.CHARACTER:{Nc(e,t);break}case ae.WHITESPACE_CHARACTER:{Ic(e,t);break}}else pr(e,t)}function fm(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,M.HTML),e.insertionMode=y.IN_CAPTION}function pm(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,M.HTML),e.insertionMode=y.IN_COLUMN_GROUP}function mm(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(I.COLGROUP,c.COLGROUP),e.insertionMode=y.IN_COLUMN_GROUP,Ja(e,t)}function gm(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,M.HTML),e.insertionMode=y.IN_TABLE_BODY}function bm(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(I.TBODY,c.TBODY),e.insertionMode=y.IN_TABLE_BODY,bi(e,t)}function Em(e,t){e.openElements.hasInTableScope(c.TABLE)&&(e.openElements.popUntilTagNamePopped(c.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function Tm(e,t){Cc(t)?e._appendElement(t,M.HTML):pr(e,t),t.ackSelfClosing=!0}function _m(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,M.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function En(e,t){switch(t.tagID){case c.TD:case c.TH:case c.TR:{bm(e,t);break}case c.STYLE:case c.SCRIPT:case c.TEMPLATE:{ct(e,t);break}case c.COL:{mm(e,t);break}case c.FORM:{_m(e,t);break}case c.TABLE:{Em(e,t);break}case c.TBODY:case c.TFOOT:case c.THEAD:{gm(e,t);break}case c.INPUT:{Tm(e,t);break}case c.CAPTION:{fm(e,t);break}case c.COLGROUP:{pm(e,t);break}default:pr(e,t)}}function ar(e,t){switch(t.tagID){case c.TABLE:{e.openElements.hasInTableScope(c.TABLE)&&(e.openElements.popUntilTagNamePopped(c.TABLE),e._resetInsertionMode());break}case c.TEMPLATE:{nn(e,t);break}case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:case c.TBODY:case c.TD:case c.TFOOT:case c.TH:case c.THEAD:case c.TR:break;default:pr(e,t)}}function pr(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,mi(e,t),e.fosterParentingEnabled=n}function Ic(e,t){e.pendingCharacterTokens.push(t)}function Nc(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function On(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)pr(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const Lc=new Set([c.CAPTION,c.COL,c.COLGROUP,c.TBODY,c.TD,c.TFOOT,c.TH,c.THEAD,c.TR]);function km(e,t){const n=t.tagID;Lc.has(n)?e.openElements.hasInTableScope(c.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(c.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=y.IN_TABLE,En(e,t)):Fe(e,t)}function xm(e,t){const n=t.tagID;switch(n){case c.CAPTION:case c.TABLE:{e.openElements.hasInTableScope(c.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(c.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=y.IN_TABLE,n===c.TABLE&&ar(e,t));break}case c.BODY:case c.COL:case c.COLGROUP:case c.HTML:case c.TBODY:case c.TD:case c.TFOOT:case c.TH:case c.THEAD:case c.TR:break;default:gi(e,t)}}function Ja(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.COL:{e._appendElement(t,M.HTML),t.ackSelfClosing=!0;break}case c.TEMPLATE:{ct(e,t);break}default:Kr(e,t)}}function ym(e,t){switch(t.tagID){case c.COLGROUP:{e.openElements.currentTagId===c.COLGROUP&&(e.openElements.pop(),e.insertionMode=y.IN_TABLE);break}case c.TEMPLATE:{nn(e,t);break}case c.COL:break;default:Kr(e,t)}}function Kr(e,t){e.openElements.currentTagId===c.COLGROUP&&(e.openElements.pop(),e.insertionMode=y.IN_TABLE,e._processToken(t))}function bi(e,t){switch(t.tagID){case c.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,M.HTML),e.insertionMode=y.IN_ROW;break}case c.TH:case c.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(I.TR,c.TR),e.insertionMode=y.IN_ROW,Ei(e,t);break}case c.CAPTION:case c.COL:case c.COLGROUP:case c.TBODY:case c.TFOOT:case c.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE,En(e,t));break}default:En(e,t)}}function fa(e,t){const n=t.tagID;switch(t.tagID){case c.TBODY:case c.TFOOT:case c.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE);break}case c.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE,ar(e,t));break}case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:case c.TD:case c.TH:case c.TR:break;default:ar(e,t)}}function Ei(e,t){switch(t.tagID){case c.TH:case c.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,M.HTML),e.insertionMode=y.IN_CELL,e.activeFormattingElements.insertMarker();break}case c.CAPTION:case c.COL:case c.COLGROUP:case c.TBODY:case c.TFOOT:case c.THEAD:case c.TR:{e.openElements.hasInTableScope(c.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE_BODY,bi(e,t));break}default:En(e,t)}}function Rc(e,t){switch(t.tagID){case c.TR:{e.openElements.hasInTableScope(c.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE_BODY);break}case c.TABLE:{e.openElements.hasInTableScope(c.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE_BODY,fa(e,t));break}case c.TBODY:case c.TFOOT:case c.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(c.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE_BODY,fa(e,t));break}case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:case c.TD:case c.TH:break;default:ar(e,t)}}function wm(e,t){const n=t.tagID;Lc.has(n)?(e.openElements.hasInTableScope(c.TD)||e.openElements.hasInTableScope(c.TH))&&(e._closeTableCell(),Ei(e,t)):Fe(e,t)}function Am(e,t){const n=t.tagID;switch(n){case c.TD:case c.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=y.IN_ROW);break}case c.TABLE:case c.TBODY:case c.TFOOT:case c.THEAD:case c.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),Rc(e,t));break}case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:break;default:gi(e,t)}}function Oc(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.OPTION:{e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e._insertElement(t,M.HTML);break}case c.OPTGROUP:{e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e.openElements.currentTagId===c.OPTGROUP&&e.openElements.pop(),e._insertElement(t,M.HTML);break}case c.HR:{e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e.openElements.currentTagId===c.OPTGROUP&&e.openElements.pop(),e._appendElement(t,M.HTML),t.ackSelfClosing=!0;break}case c.INPUT:case c.KEYGEN:case c.TEXTAREA:case c.SELECT:{e.openElements.hasInSelectScope(c.SELECT)&&(e.openElements.popUntilTagNamePopped(c.SELECT),e._resetInsertionMode(),t.tagID!==c.SELECT&&e._processStartTag(t));break}case c.SCRIPT:case c.TEMPLATE:{ct(e,t);break}}}function Dc(e,t){switch(t.tagID){case c.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===c.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===c.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===c.OPTGROUP&&e.openElements.pop();break}case c.OPTION:{e.openElements.currentTagId===c.OPTION&&e.openElements.pop();break}case c.SELECT:{e.openElements.hasInSelectScope(c.SELECT)&&(e.openElements.popUntilTagNamePopped(c.SELECT),e._resetInsertionMode());break}case c.TEMPLATE:{nn(e,t);break}}}function Cm(e,t){const n=t.tagID;n===c.CAPTION||n===c.TABLE||n===c.TBODY||n===c.TFOOT||n===c.THEAD||n===c.TR||n===c.TD||n===c.TH?(e.openElements.popUntilTagNamePopped(c.SELECT),e._resetInsertionMode(),e._processStartTag(t)):Oc(e,t)}function Sm(e,t){const n=t.tagID;n===c.CAPTION||n===c.TABLE||n===c.TBODY||n===c.TFOOT||n===c.THEAD||n===c.TR||n===c.TD||n===c.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(c.SELECT),e._resetInsertionMode(),e.onEndTag(t)):Dc(e,t)}function vm(e,t){switch(t.tagID){case c.BASE:case c.BASEFONT:case c.BGSOUND:case c.LINK:case c.META:case c.NOFRAMES:case c.SCRIPT:case c.STYLE:case c.TEMPLATE:case c.TITLE:{ct(e,t);break}case c.CAPTION:case c.COLGROUP:case c.TBODY:case c.TFOOT:case c.THEAD:{e.tmplInsertionModeStack[0]=y.IN_TABLE,e.insertionMode=y.IN_TABLE,En(e,t);break}case c.COL:{e.tmplInsertionModeStack[0]=y.IN_COLUMN_GROUP,e.insertionMode=y.IN_COLUMN_GROUP,Ja(e,t);break}case c.TR:{e.tmplInsertionModeStack[0]=y.IN_TABLE_BODY,e.insertionMode=y.IN_TABLE_BODY,bi(e,t);break}case c.TD:case c.TH:{e.tmplInsertionModeStack[0]=y.IN_ROW,e.insertionMode=y.IN_ROW,Ei(e,t);break}default:e.tmplInsertionModeStack[0]=y.IN_BODY,e.insertionMode=y.IN_BODY,Fe(e,t)}}function Im(e,t){t.tagID===c.TEMPLATE&&nn(e,t)}function Pc(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(c.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):Za(e,t)}function Nm(e,t){t.tagID===c.HTML?Fe(e,t):Xr(e,t)}function Mc(e,t){var n;if(t.tagID===c.HTML){if(e.fragmentContext||(e.insertionMode=y.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===c.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 Xr(e,t)}function Xr(e,t){e.insertionMode=y.IN_BODY,mi(e,t)}function Lm(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.FRAMESET:{e._insertElement(t,M.HTML);break}case c.FRAME:{e._appendElement(t,M.HTML),t.ackSelfClosing=!0;break}case c.NOFRAMES:{ct(e,t);break}}}function Rm(e,t){t.tagID===c.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==c.FRAMESET&&(e.insertionMode=y.AFTER_FRAMESET))}function Om(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.NOFRAMES:{ct(e,t);break}}}function Dm(e,t){t.tagID===c.HTML&&(e.insertionMode=y.AFTER_AFTER_FRAMESET)}function Pm(e,t){t.tagID===c.HTML?Fe(e,t):Br(e,t)}function Br(e,t){e.insertionMode=y.IN_BODY,mi(e,t)}function Mm(e,t){switch(t.tagID){case c.HTML:{Fe(e,t);break}case c.NOFRAMES:{ct(e,t);break}}}function Bm(e,t){t.chars=we,e._insertCharacters(t)}function Fm(e,t){e._insertCharacters(t),e.framesetOk=!1}function Bc(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==M.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function Hm(e,t){if(e1(t))Bc(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===M.MATHML?_c(t):r===M.SVG&&(t1(t),kc(t)),Ka(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function Um(e,t){if(t.tagID===c.P||t.tagID===c.BR){Bc(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)===M.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=Fc("end"),Et=Fc("start");function Fc(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 Hc(e){const t=Et(e),n=Ti(e);if(t&&n)return{start:t,end:n}}const zm=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,$m=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),Lo={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function Uc(e,t){const n=Zm(e),r=lc("type",{handlers:{root:Ym,element:jm,text:Vm,comment:$c,doctype:qm,raw:Gm},unknown:Qm}),i={parser:n?new vo(Lo):vo.getFragmentParser(void 0,Lo),handle(o){r(o,i)},stitches:!1,options:t||{}};r(e,i),Cn(i,Et());const a=n?i.parser.document:i.parser.getFragment(),s=Jf(a,{file:i.options.file});return i.stitches&&Mt(s,"comment",function(o,u,l){const h=o;if(h.value.stitch&&l&&u!==void 0){const d=l.children;return d[u]=h.value.stitch,u}}),s.type==="root"&&s.children.length===1&&s.children[0].type===e.type?s.children[0]:s}function zc(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function Ym(e,t){zc(e.children,t)}function jm(e,t){Km(e,t),zc(e.children,t),Xm(e,t)}function Vm(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:ae.CHARACTER,chars:e.value,location:mr(e)};Cn(t,Et(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function qm(e,t){const n={type:ae.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:mr(e)};Cn(t,Et(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function Wm(e,t){t.stitches=!0;const n=Jm(e);if("children"in e&&"children"in n){const r=Uc({type:"root",children:e.children},t.options);n.children=r.children}$c({type:"comment",value:{stitch:n}},t)}function $c(e,t){const n=e.value,r={type:ae.COMMENT,data:n,location:mr(e)};Cn(t,Et(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function Gm(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,Yc(t,Et(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(zm,"<$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 Qm(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))Wm(n,t);else{let r="";throw $m.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){Yc(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=Le.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 Yc(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 Km(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===Le.PLAINTEXT)return;Cn(t,Et(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=ip({...e,children:[]},{space:i===Qt.svg?"svg":"html"}),s={type:ae.START_TAG,tagName:n,tagID:An(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:mr(e)};t.parser.currentToken=s,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function Xm(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&hp.includes(n)||t.parser.tokenizer.state===Le.PLAINTEXT)return;Cn(t,Ti(e));const r={type:ae.END_TAG,tagName:n,tagID:An(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:mr(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===Le.RCDATA||t.parser.tokenizer.state===Le.RAWTEXT||t.parser.tokenizer.state===Le.SCRIPT_DATA)&&(t.parser.tokenizer.state=Le.DATA)}function Zm(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function mr(e){const t=Et(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 Jm(e){return"children"in e?Zt({...e,children:[]}):Zt(e)}function pa(e){return function(t,n){return Uc(t,{...e,file:n})}}const Yt=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],Xn={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Yt,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Yt],h2:[["className","sr-only"]],img:[...Yt,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Yt,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Yt],table:[...Yt],ul:[...Yt,["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 eg(e,t){let n={type:"root",children:[]};const r={schema:t?{...Xn,...t}:Xn,stack:[]},i=jc(r,e);return i&&(Array.isArray(i)?i.length===1?n=i[0]:n.children=i:n=i),n}function jc(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return tg(e,n);case"doctype":return ng(e,n);case"element":return rg(e,n);case"root":return ig(e,n);case"text":return ag(e,n)}}}function tg(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 gr(a,t),a}}function ng(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return gr(n,t),n}}function rg(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=Vc(e,t.children),i=sg(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 gr(s,t),s}function ig(e,t){const r={type:"root",children:Vc(e,t.children)};return gr(r,t),r}function ag(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return gr(r,t),r}function Vc(e,t){const n=[];if(Array.isArray(t)){const r=t;let i=-1;for(;++i<r.length;){const a=jc(e,r[i]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function sg(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 l;for(l in o)if(Rt.call(o,l)){const h=o[l];let d=Ro(e,Oo(a,l),l,h);d==null&&(d=Ro(e,Oo(s,l),l,h)),d!=null&&(u[l]=d)}if(i&&Rt.call(i,n)){const h=i[n];for(l in h)Rt.call(h,l)&&!Rt.call(u,l)&&(u[l]=h[l])}return u}function Ro(e,t,n,r){return t?Array.isArray(r)?og(e,t,n,r):qc(e,t,n,r):void 0}function og(e,t,n,r){let i=-1;const a=[];for(;++i<r.length;){const s=qc(e,t,n,r[i]);(typeof s=="number"||typeof s=="string")&&a.push(s)}return a}function qc(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&ug(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 ug(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 l=-1;for(;++l<r.length;){const h=r[l];if(a===h.length&&i.slice(0,h.length)===h)return!0}return!1}function gr(e,t){const n=Hc(t);t.data&&(e.data=Zt(t.data)),n&&(e.position=n)}function Oo(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 Wc(e){return function(t){return eg(t,e)}}function Do(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 $e=Ut(/[A-Za-z]/),Be=Ut(/[\dA-Za-z]/),lg=Ut(/[#-'*+\--9=?A-Z^-~]/);function Zr(e){return e!==null&&(e<32||e===127)}const ma=Ut(/\d/),cg=Ut(/[\dA-Fa-f]/),dg=Ut(/[!-/:-@[-`{-~]/);function X(e){return e!==null&&e<-2}function _e(e){return e!==null&&(e<0||e===32)}function se(e){return e===-2||e===-1||e===32}const _i=Ut(/\p{P}|\p{S}/u),Jt=Ut(/\s/);function Ut(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function hg(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function fg(e,t,n){const i=di((n||{}).ignore||[]),a=pg(t);let s=-1;for(;++s<a.length;)$a(e,"text",o);function o(l,h){let d=-1,p;for(;++d<h.length;){const f=h[d],m=p?p.children:void 0;if(i(f,m?m.indexOf(f):void 0,p))return;p=f}if(p)return u(l,h)}function u(l,h){const d=h[h.length-1],p=a[s][0],f=a[s][1];let m=0;const x=d.children.indexOf(l);let k=!1,v=[];p.lastIndex=0;let C=p.exec(l.value);for(;C;){const R=C.index,F={index:C.index,input:C.input,stack:[...h,l]};let S=f(...C,F);if(typeof S=="string"&&(S=S.length>0?{type:"text",value:S}:void 0),S===!1?p.lastIndex=R+1:(m!==R&&v.push({type:"text",value:l.value.slice(m,R)}),Array.isArray(S)?v.push(...S):S&&v.push(S),m=R+C[0].length,k=!0),!p.global)break;C=p.exec(l.value)}return k?(m<l.value.length&&v.push({type:"text",value:l.value.slice(m)}),d.children.splice(x,1,...v)):v=[l],x+v.length}}function pg(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([mg(i[0]),gg(i[1])])}return t}function mg(e){return typeof e=="string"?new RegExp(hg(e),"g"):e}function gg(e){return typeof e=="function"?e:function(){return e}}const Bi="phrasing",Fi=["autolink","link","image","label"];function bg(){return{transforms:[wg],enter:{literalAutolink:Tg,literalAutolinkEmail:Hi,literalAutolinkHttp:Hi,literalAutolinkWww:Hi},exit:{literalAutolink:yg,literalAutolinkEmail:xg,literalAutolinkHttp:_g,literalAutolinkWww:kg}}}function Eg(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Bi,notInConstruct:Fi},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Bi,notInConstruct:Fi},{character:":",before:"[ps]",after:"\\/",inConstruct:Bi,notInConstruct:Fi}]}}function Tg(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Hi(e){this.config.enter.autolinkProtocol.call(this,e)}function _g(e){this.config.exit.autolinkProtocol.call(this,e)}function kg(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.url="http://"+this.sliceSerialize(e)}function xg(e){this.config.exit.autolinkEmail.call(this,e)}function yg(e){this.exit(e)}function wg(e){fg(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Ag],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),Cg]],{ignore:["link","linkReference"]})}function Ag(e,t,n,r,i){let a="";if(!Gc(i)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!Sg(n)))return!1;const s=vg(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 Cg(e,t,n,r){return!Gc(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function Sg(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 vg(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=Do(e,"(");let a=Do(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 Gc(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Jt(n)||_i(n))&&(!t||n!==47)}function lt(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}Qc.peek=Bg;function Ig(){this.buffer()}function Ng(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function Lg(){this.buffer()}function Rg(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function Og(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.identifier=lt(this.sliceSerialize(e)).toLowerCase(),n.label=t}function Dg(e){this.exit(e)}function Pg(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.identifier=lt(this.sliceSerialize(e)).toLowerCase(),n.label=t}function Mg(e){this.exit(e)}function Bg(){return"["}function Qc(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 Fg(){return{enter:{gfmFootnoteCallString:Ig,gfmFootnoteCall:Ng,gfmFootnoteDefinitionLabelString:Lg,gfmFootnoteDefinition:Rg},exit:{gfmFootnoteCallString:Og,gfmFootnoteCall:Dg,gfmFootnoteDefinitionLabelString:Pg,gfmFootnoteDefinition:Mg}}}function Hg(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:Qc},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,i,a,s){const o=a.createTracker(s);let u=o.move("[^");const l=a.enter("footnoteDefinition"),h=a.enter("label");return u+=o.move(a.safe(a.associationId(r),{before:u,after:"]"})),h(),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
|
+
"use strict";var kh=Object.defineProperty;var xh=(e,t,n)=>t in e?kh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var be=(e,t,n)=>(xh(e,typeof t!="symbol"?t+"":t,n),n);const Li=require("@inploi/sdk");var cr,G,cl,dl,qt,Ms,hl,ra,fl,fn={},pl=[],yh=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,oi=Array.isArray;function wt(e,t){for(var n in t)e[n]=t[n];return e}function ml(e){var t=e.parentNode;t&&t.removeChild(e)}function mt(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?cr.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 Yn(e,s,r,i,null)}function Yn(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??++cl};return i==null&&G.vnode!=null&&G.vnode(a),a}function pe(e){return e.children}function gt(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 gl(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 gl(e)}}function ia(e){(!e.__d&&(e.__d=!0)&&qt.push(e)&&!Yr.__r++||Ms!==G.debounceRendering)&&((Ms=G.debounceRendering)||hl)(Yr)}function Yr(){var e,t,n,r,i,a,s,o,u;for(qt.sort(ra);e=qt.shift();)e.__d&&(t=qt.length,r=void 0,i=void 0,a=void 0,o=(s=(n=e).__v).__e,(u=n.__P)&&(r=[],i=[],(a=wt({},s)).__v=s.__v+1,Ma(u,s,a,n.__n,u.ownerSVGElement!==void 0,s.__h!=null?[o]:null,r,o??$r(s),s.__h,i),_l(r,s,i),s.__e!=o&&gl(s)),qt.length>t&&qt.sort(ra));Yr.__r=0}function bl(e,t,n,r,i,a,s,o,u,l,h){var d,p,f,m,_,x,k,v,C,R,F=0,S=r&&r.__k||pl,Y=S.length,L=Y,O=t.length;for(n.__k=[],d=0;d<O;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"?Yn(null,m,null,null,m):oi(m)?Yn(pe,{children:m},null,null,null):m.__b>0?Yn(m.type,m.props,m.key,m.ref?m.ref:null,m.__v):m)!=null&&(m.__=n,m.__b=n.__b+1,(v=wh(m,S,k=d+F,L))===-1?f=fn:(f=S[v]||fn,S[v]=void 0,L--),Ma(e,m,f,i,a,s,o,u,l,h),_=m.__e,(p=m.ref)&&f.ref!=p&&(f.ref&&Ba(f.ref,null,m),h.push(p,m.__c||_,m)),_!=null&&(x==null&&(x=_),R=!(C=f===fn||f.__v===null)&&v===k,C?v==-1&&F--:v!==k&&(v===k+1?(F++,R=!0):v>k?L>O-k?(F+=v-k,R=!0):F--:F=v<k&&v==k-1?v-k:0),k=d+F,R=R||v==d&&!C,typeof m.type!="function"||v===k&&f.__k!==m.__k?typeof m.type=="function"||R?m.__d!==void 0?(u=m.__d,m.__d=void 0):u=_.nextSibling:u=Tl(e,_,u):u=El(m,u,e),typeof n.type=="function"&&(n.__d=u)));for(n.__e=x,d=Y;d--;)S[d]!=null&&(typeof n.type=="function"&&S[d].__e!=null&&S[d].__e==n.__d&&(n.__d=S[d].__e.nextSibling),kl(S[d],S[d]))}function El(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"?El(r,t,n):Tl(n,r.__e,t));return t}function jr(e,t){return t=t||[],e==null||typeof e=="boolean"||(oi(e)?e.some(function(n){jr(n,t)}):t.push(e)),t}function Tl(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 wh(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 Ah(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 Bs(e,t,n){t[0]==="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||yh.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||Bs(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||Bs(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?Hs:Fs,a):e.removeEventListener(t,a?Hs:Fs,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 Fs(e){return this.l[e.type+!1](G.event?G.event(e):e)}function Hs(e){return this.l[e.type+!0](G.event?G.event(e):e)}function Ma(e,t,n,r,i,a,s,o,u,l){var h,d,p,f,m,_,x,k,v,C,R,F,S,Y,L,O=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]),(h=G.__b)&&h(t);try{e:if(typeof O=="function"){if(k=t.props,v=(h=O.contextType)&&r[h.__c],C=h?v?v.props.value:h.__:r,n.__c?x=(d=t.__c=n.__c).__=d.__E:("prototype"in O&&O.prototype.render?t.__c=d=new O(k,C):(t.__c=d=new gt(k,C),d.constructor=O,d.render=Sh),v&&v.sub(d),d.props=k,d.state||(d.state={}),d.context=C,d.__n=r,p=d.__d=!0,d.__h=[],d._sb=[]),d.__s==null&&(d.__s=d.state),O.getDerivedStateFromProps!=null&&(d.__s==d.state&&(d.__s=wt({},d.__s)),wt(d.__s,O.getDerivedStateFromProps(k,d.__s))),f=d.props,m=d.state,d.__v=t,p)O.getDerivedStateFromProps==null&&d.componentWillMount!=null&&d.componentWillMount(),d.componentDidMount!=null&&d.__h.push(d.componentDidMount);else{if(O.getDerivedStateFromProps==null&&k!==f&&d.componentWillReceiveProps!=null&&d.componentWillReceiveProps(k,C),!d.__e&&(d.shouldComponentUpdate!=null&&d.shouldComponentUpdate(k,d.__s,C)===!1||t.__v===n.__v)){for(t.__v!==n.__v&&(d.props=k,d.state=d.__s,d.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.forEach(function(A){A&&(A.__=t)}),R=0;R<d._sb.length;R++)d.__h.push(d._sb[R]);d._sb=[],d.__h.length&&s.push(d);break e}d.componentWillUpdate!=null&&d.componentWillUpdate(k,d.__s,C),d.componentDidUpdate!=null&&d.__h.push(function(){d.componentDidUpdate(f,m,_)})}if(d.context=C,d.props=k,d.__P=e,d.__e=!1,F=G.__r,S=0,"prototype"in O&&O.prototype.render){for(d.state=d.__s,d.__d=!1,F&&F(t),h=d.render(d.props,d.state,d.context),Y=0;Y<d._sb.length;Y++)d.__h.push(d._sb[Y]);d._sb=[]}else do d.__d=!1,F&&F(t),h=d.render(d.props,d.state,d.context),d.state=d.__s;while(d.__d&&++S<25);d.state=d.__s,d.getChildContext!=null&&(r=wt(wt({},r),d.getChildContext())),p||d.getSnapshotBeforeUpdate==null||(_=d.getSnapshotBeforeUpdate(f,m)),bl(e,oi(L=h!=null&&h.type===pe&&h.key==null?h.props.children:h)?L:[L],t,n,r,i,a,s,o,u,l),d.base=t.__e,t.__h=null,d.__h.length&&s.push(d),x&&(d.__E=d.__=null)}else a==null&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=Ch(n.__e,t,n,r,i,a,s,u,l);(h=G.diffed)&&h(t)}catch(A){t.__v=null,(u||a!=null)&&(t.__e=o,t.__h=!!u,a[a.indexOf(o)]=null),G.__e(A,t,n)}}function _l(e,t,n){for(var r=0;r<n.length;r++)Ba(n[r],n[++r],n[++r]);G.__c&&G.__c(t,e),e.some(function(i){try{e=i.__h,i.__h=[],e.some(function(a){a.call(i)})}catch(a){G.__e(a,i.__v)}})}function Ch(e,t,n,r,i,a,s,o,u){var l,h,d,p=n.props,f=t.props,m=t.type,_=0;if(m==="svg"&&(i=!0),a!=null){for(;_<a.length;_++)if((l=a[_])&&"setAttribute"in l==!!m&&(m?l.localName===m:l.nodeType===3)){e=l,a[_]=null;break}}if(e==null){if(m===null)return document.createTextNode(f);e=i?document.createElementNS("http://www.w3.org/2000/svg",m):document.createElement(m,f.is&&f),a=null,o=!1}if(m===null)p===f||o&&e.data===f||(e.data=f);else{if(a=a&&cr.call(e.childNodes),h=(p=n.props||fn).dangerouslySetInnerHTML,d=f.dangerouslySetInnerHTML,!o){if(a!=null)for(p={},_=0;_<e.attributes.length;_++)p[e.attributes[_].name]=e.attributes[_].value;(d||h)&&(d&&(h&&d.__html==h.__html||d.__html===e.innerHTML)||(e.innerHTML=d&&d.__html||""))}if(Ah(e,f,p,i,o),d)t.__k=[];else if(bl(e,oi(_=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&&ml(a[_]);o||("value"in f&&(_=f.value)!==void 0&&(_!==e.value||m==="progress"&&!_||m==="option"&&_!==p.value)&&Vr(e,"value",_,p.value,!1),"checked"in f&&(_=f.checked)!==void 0&&_!==e.checked&&Vr(e,"checked",_,p.checked,!1))}return e}function Ba(e,t,n){try{typeof e=="function"?e(t):e.current=t}catch(r){G.__e(r,n)}}function kl(e,t,n){var r,i;if(G.unmount&&G.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||Ba(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(a){G.__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]&&kl(r[i],t,n||typeof e.type!="function");n||e.__e==null||ml(e.__e),e.__=e.__e=e.__d=void 0}function Sh(e,t,n){return this.constructor(e,n)}function qr(e,t,n){var r,i,a,s;G.__&&G.__(e,t),i=(r=typeof n=="function")?null:n&&n.__k||t.__k,a=[],s=[],Ma(t,e=(!r&&n||t).__k=mt(pe,null,[e]),i||fn,fn,t.ownerSVGElement!==void 0,!r&&n?[n]:i?null:t.firstChild?cr.call(t.childNodes):null,a,!r&&n?n:i?i.__e:t.firstChild,r,s),_l(a,e,s)}function xl(e,t,n){var r,i,a,s,o=wt({},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?cr.call(arguments,2):n),Yn(e.type,o,r||e.key,i||e.ref,null)}function ui(e,t){var n={__c:t="__cC"+fl++,__: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,ia(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}cr=pl.slice,G={__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}},cl=0,dl=function(e){return e!=null&&e.constructor===void 0},gt.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=wt({},this.state),typeof e=="function"&&(e=e(wt({},n),this.props)),e&&wt(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),ia(this))},gt.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),ia(this))},gt.prototype.render=pe,qt=[],hl=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,ra=function(e,t){return e.__v.__b-t.__v.__b},Yr.__r=0,fl=0;function yl(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=yl(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Ri(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=yl(e))&&(r&&(r+=" "),r+=t);return r}const Us=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,vh=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==null?void 0:e.hooks["cx:done"](Ri(a)):typeof(e==null||(u=e.hooks)===null||u===void 0?void 0:u.onComplete)<"u"?e==null?void 0:e.hooks.onComplete(Ri(a)):Ri(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(l=>{let[h]=l;return!["class","className"].includes(h)}));return t(a.map(l=>l(u)),o==null?void 0:o.class,o==null?void 0:o.className)}},cva:i=>a=>{var s;if((i==null?void 0:i.variants)==null)return t(i==null?void 0:i.base,a==null?void 0:a.class,a==null?void 0:a.className);const{variants:o,defaultVariants:u}=i,l=Object.keys(o).map(p=>{const f=a==null?void 0:a[p],m=u==null?void 0:u[p],_=Us(f)||Us(m);return o[p][_]}),h={...u,...a&&Object.entries(a).reduce((p,f)=>{let[m,_]=f;return typeof _>"u"?p:{...p,[m]:_}},{})},d=i==null||(s=i.compoundVariants)===null||s===void 0?void 0:s.reduce((p,f)=>{let{class:m,className:_,...x}=f;return Object.entries(x).every(k=>{let[v,C]=k;const R=h[v];return Array.isArray(C)?C.includes(R):R===C})?[...p,m,_]:p},[]);return t(i==null?void 0:i.base,l,d,a==null?void 0:a.class,a==null?void 0:a.className)},cx:t}},{compose:Y5,cva:Ft,cx:j5}=vh();var Pt,ye,Oi,zs,rr=0,wl=[],Dr=[],$s=G.__b,Ys=G.__r,js=G.diffed,Vs=G.__c,qs=G.unmount;function kn(e,t){G.__h&&G.__h(ye,e,rr||t),rr=0;var n=ye.__H||(ye.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({__V:Dr}),n.__[e]}function fe(e){return rr=1,Ih(Al,e)}function Ih(e,t,n){var r=kn(Pt++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):Al(void 0,t),function(o){var u=r.__N?r.__N[0]:r.__[0],l=r.t(u,o);u!==l&&(r.__N=[l,r.__[1]],r.__c.setState({}))}],r.__c=ye,!ye.u)){var i=function(o,u,l){if(!r.__c.__H)return!0;var h=r.__c.__H.__.filter(function(p){return p.__c});if(h.every(function(p){return!p.__N}))return!a||a.call(this,o,u,l);var d=!1;return h.forEach(function(p){if(p.__N){var f=p.__[0];p.__=p.__N,p.__N=void 0,f!==p.__[0]&&(d=!0)}}),!(!d&&r.__c.props===o)&&(!a||a.call(this,o,u,l))};ye.u=!0;var a=ye.shouldComponentUpdate,s=ye.componentWillUpdate;ye.componentWillUpdate=function(o,u,l){if(this.__e){var h=a;a=void 0,i(o,u,l),a=h}s&&s.call(this,o,u,l)},ye.shouldComponentUpdate=i}return r.__N||r.__}function Ce(e,t){var n=kn(Pt++,3);!G.__s&&Fa(n.__H,t)&&(n.__=e,n.i=t,ye.__H.__h.push(n))}function Nh(e,t){var n=kn(Pt++,4);!G.__s&&Fa(n.__H,t)&&(n.__=e,n.i=t,ye.__h.push(n))}function ve(e){return rr=5,Ne(function(){return{current:e}},[])}function Ne(e,t){var n=kn(Pt++,7);return Fa(n.__H,t)?(n.__V=e(),n.i=t,n.__h=e,n.__V):n.__}function $e(e,t){return rr=8,Ne(function(){return e},t)}function Ge(e){var t=ye.context[e.__c],n=kn(Pt++,9);return n.c=e,t?(n.__==null&&(n.__=!0,t.sub(ye)),t.props.value):e.__}function Lh(){var e=kn(Pt++,11);if(!e.__){for(var t=ye.__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 Rh(){for(var e;e=wl.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Pr),e.__H.__h.forEach(aa),e.__H.__h=[]}catch(t){e.__H.__h=[],G.__e(t,e.__v)}}G.__b=function(e){ye=null,$s&&$s(e)},G.__r=function(e){Ys&&Ys(e),Pt=0;var t=(ye=e.__c).__H;t&&(Oi===ye?(t.__h=[],ye.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=Dr,n.__N=n.i=void 0})):(t.__h.forEach(Pr),t.__h.forEach(aa),t.__h=[],Pt=0)),Oi=ye},G.diffed=function(e){js&&js(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(wl.push(t)!==1&&zs===G.requestAnimationFrame||((zs=G.requestAnimationFrame)||Oh)(Rh)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==Dr&&(n.__=n.__V),n.i=void 0,n.__V=Dr})),Oi=ye=null},G.__c=function(e,t){t.some(function(n){try{n.__h.forEach(Pr),n.__h=n.__h.filter(function(r){return!r.__||aa(r)})}catch(r){t.some(function(i){i.__h&&(i.__h=[])}),t=[],G.__e(r,n.__v)}}),Vs&&Vs(e,t)},G.unmount=function(e){qs&&qs(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{Pr(r)}catch(i){t=i}}),n.__H=void 0,t&&G.__e(t,n.__v))};var Ws=typeof requestAnimationFrame=="function";function Oh(e){var t,n=function(){clearTimeout(r),Ws&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);Ws&&(t=requestAnimationFrame(n))}function Pr(e){var t=ye,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),ye=t}function aa(e){var t=ye;e.__c=e.__(),ye=t}function Fa(e,t){return!e||e.length!==t.length||t.some(function(n,r){return n!==e[r]})}function Al(e,t){return typeof t=="function"?t(e):t}var Dh=Symbol.for("preact-signals");function Ha(){if(pn>1)pn--;else{for(var e,t=!1;jn!==void 0;){var n=jn;for(jn=void 0,sa++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&Sl(n))try{n.c()}catch(i){t||(e=i,t=!0)}n=r}}if(sa=0,pn--,t)throw e}}var _e=void 0,jn=void 0,pn=0,sa=0,Wr=0;function Cl(e){if(_e!==void 0){var t=e.n;if(t===void 0||t.t!==_e)return t={i:0,S:e,p:_e.s,n:void 0,t:_e,e:void 0,x:void 0,r:t},_e.s!==void 0&&(_e.s.n=t),_e.s=t,e.n=t,32&_e.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=_e.s,t.n=void 0,_e.s.n=t,_e.s=t),t}}function Me(e){this.v=e,this.i=0,this.n=void 0,this.t=void 0}Me.prototype.brand=Dh;Me.prototype.h=function(){return!0};Me.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)};Me.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)}};Me.prototype.subscribe=function(e){var t=this;return za(function(){var n=t.value,r=_e;_e=void 0;try{e(n)}finally{_e=r}})};Me.prototype.valueOf=function(){return this.value};Me.prototype.toString=function(){return this.value+""};Me.prototype.toJSON=function(){return this.value};Me.prototype.peek=function(){var e=_e;_e=void 0;try{return this.value}finally{_e=e}};Object.defineProperty(Me.prototype,"value",{get:function(){var e=Cl(this);return e!==void 0&&(e.i=this.i),this.v},set:function(e){if(e!==this.v){if(sa>100)throw new Error("Cycle detected");this.v=e,this.i++,Wr++,pn++;try{for(var t=this.t;t!==void 0;t=t.x)t.t.N()}finally{Ha()}}}});function tt(e){return new Me(e)}function Sl(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 vl(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 Il(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 xn(e){Me.call(this,void 0),this.x=e,this.s=void 0,this.g=Wr-1,this.f=4}(xn.prototype=new Me).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===Wr))return!0;if(this.g=Wr,this.f|=1,this.i>0&&!Sl(this))return this.f&=-2,!0;var e=_e;try{vl(this),_e=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 _e=e,Il(this),this.f&=-2,!0};xn.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)}Me.prototype.S.call(this,e)};xn.prototype.U=function(e){if(this.t!==void 0&&(Me.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)}};xn.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(xn.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var e=Cl(this);if(this.h(),e!==void 0&&(e.i=this.i),16&this.f)throw this.v;return this.v}});function Ph(e){return new xn(e)}function Nl(e){var t=e.u;if(e.u=void 0,typeof t=="function"){pn++;var n=_e;_e=void 0;try{t()}catch(r){throw e.f&=-2,e.f|=8,Ua(e),r}finally{_e=n,Ha()}}}function Ua(e){for(var t=e.s;t!==void 0;t=t.n)t.S.U(t);e.x=void 0,e.s=void 0,Nl(e)}function Mh(e){if(_e!==this)throw new Error("Out-of-order effect");Il(this),_e=e,this.f&=-2,8&this.f&&Ua(this),Ha()}function dr(e){this.x=e,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}dr.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()}};dr.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,Nl(this),vl(this),pn++;var e=_e;return _e=this,Mh.bind(this,e)};dr.prototype.N=function(){2&this.f||(this.f|=2,this.o=jn,jn=this)};dr.prototype.d=function(){this.f|=8,1&this.f||Ua(this)};function za(e){var t=new dr(e);try{t.c()}catch(n){throw t.d(),n}return t.d.bind(t)}var Di;function yn(e,t){G[e]=t.bind(null,G[e]||function(){})}function Gr(e){Di&&Di(),Di=e&&e.S()}function Ll(e){var t=this,n=e.data,r=Fh(n);r.value=n;var i=Ne(function(){for(var a=t.__v;a=a.__;)if(a.__c){a.__c.__$f|=4;break}return t.__$u.c=function(){var s;!dl(i.peek())&&((s=t.base)==null?void 0:s.nodeType)===3?t.base.data=i.peek():(t.__$f|=1,t.setState({}))},Ph(function(){var s=r.value.value;return s===0?0:s===!0?"":s||""})},[]);return i.value}Ll.displayName="_st";Object.defineProperties(Me.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:Ll},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}});yn("__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 Me&&(n||(t.__np=n={}),n[i]=a,r[i]=a.peek())}}e(t)});yn("__r",function(e,t){Gr();var n,r=t.__c;r&&(r.__$f&=-2,(n=r.__$u)===void 0&&(r.__$u=n=function(i){var a;return za(function(){a=this}),a.c=function(){r.__$f|=1,r.setState({})},a}())),Gr(n),e(t)});yn("__e",function(e,t,n,r){Gr(),e(t,n,r)});yn("diffed",function(e,t){Gr();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 l=a[u],h=r[u];l===void 0?(l=Bh(n,u,h,i),a[u]=l):l.o(h,i)}}}e(t)});function Bh(e,t,n,r){var i=t in e&&e.ownerSVGElement===void 0,a=tt(n);return{o:function(s,o){a.value=s,r=o},d:za(function(){var s=a.value.value;r[t]!==s&&(r[t]=s,i?e[t]=s:s?e.setAttribute(t,s):e.removeAttribute(t))})}}yn("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)});yn("__h",function(e,t,n,r){(r<3||r===9)&&(t.__$f|=2),e(t,n,r)});gt.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 Fh(e){return Ne(function(){return tt(e)},[])}const Rl=tt(!1),li=tt(!1),ci=tt(null),Xt=tt(null),Ol=tt("idle"),Dl=tt(!1),Pl=tt("idle"),Ml=tt(null),Bl=tt(null),bt=tt([]),$a=tt([]),Hh=e=>({...e,timestamp:new Date(e.timestamp)}),di=e=>({...e,id:crypto.randomUUID(),timestamp:new Date}),At=typeof BroadcastChannel<"u"?new BroadcastChannel("kin-sync"):null;At==null||At.addEventListener("message",e=>{const{type:t,data:n}=e.data;switch(t){case"messages_updated":if(!Array.isArray(n==null?void 0:n.messages))return;bt.value=n.messages.map(Hh);break;case"messages_cleared":bt.value=[];break}});const hi=()=>{At==null||At.postMessage({type:"messages_updated",data:{messages:bt.value}})},Fl=(e,t=!0)=>{bt.value=[...bt.value,e],$a.value=[],t&&hi()},Uh=e=>{const t=di(e);return Fl(t),t},zh=e=>{bt.value=bt.value.filter(t=>t.id!==e),hi()},$h=()=>{li.value=!0,ci.value="thinking",Xt.value=di({role:"assistant",content:""})},Yh=e=>{if(!e)return;const t=Xt.value;t&&(Xt.value={...t,content:t.content+e})},jh=e=>{const{commit:t=!0,broadcast:n=!0,blocks:r}=e??{},i=Xt.value;if(Xt.value=null,li.value=!1,ci.value=null,t&&(i!=null&&i.content||r!=null&&r.length)){const a=i??di({role:"assistant",content:""});Fl(r!=null&&r.length?{...a,blocks:r}:a,!1)}n&&hi()},Ya=()=>{Xt.value=null,li.value=!1,ci.value=null},Hl=()=>{bt.value=[],Ya(),At==null||At.postMessage({type:"messages_cleared"})},Vh=e=>{Ya(),bt.value=e.filter(t=>t.role!=="system").map(di),hi()},Ul=(e,t,n)=>{Pl.value=e,Bl.value=t??null,Ml.value=n??null},qh=()=>{Rl.value=!1,Ol.value="idle",$a.value=[],Dl.value=!1,Hl(),Ul("idle")},$={isOpen:Rl,isStreaming:li,assistantStatus:ci,liveAssistantMessage:Xt,connectionState:Ol,messages:bt,quickReplies:$a,uploadState:Pl,uploadError:Ml,uploadFileName:Bl,hasUnreadMessages:Dl,addMessage:Uh,removeMessage:zh,startAssistantResponse:$h,appendToLiveAssistantMessage:Yh,finishAssistantResponse:jh,clearAssistantResponse:Ya,clearMessages:Hl,setMessages:Vh,setUploadState:Ul,resetState:qh},bn=Ft({base:"fr inline-flex shrink-0 items-center corner-smooth justify-center no-underline transition-all duration-kin disabled:cursor-not-allowed",variants:{variant:{ghost:"bg-transparent text-n-8 hover:bg-n-3 hover:text-n-11 disabled:text-n-6 active:scale-95",neutral:"bg-n-3 text-n-9 hover:bg-n-4 hover:text-n-11 disabled:opacity-50 active:scale-95",accent:"bg-a-9 text-white hover:bg-a-10 disabled:opacity-50 active:scale-95"},size:{iconSm:"size-8 sm:size-7 [&_svg]:size-3.5 rounded-kin-xl",iconMd:"size-10 sm:size-8 [&_svg]:size-4 rounded-kin-2xl sm:rounded-kin-xl",sm:"px-2.5 py-2 text-xs font-medium rounded-kin-md",md:"px-4 py-2.5 text-sm font-medium rounded-kin-lg"}},defaultVariants:{size:"iconMd"}});var Wh=0;function g(e,t,n,r,i,a){var s,o,u={};for(o in t)o=="ref"?s=t[o]:u[o]=t[o];var l={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:--Wh,__source:i,__self:a};if(typeof e=="function"&&(s=e.defaultProps))for(o in s)u[o]===void 0&&(u[o]=s[o]);return G.vnode&&G.vnode(l),l}function Be(e){return function(n){return g("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:n.strokeWidth??1.5,strokeLinecap:"round",strokeLinejoin:"round",focusable:"false","aria-hidden":"true",...n,children:e()})}}function Gh({class:e}){return g("svg",{class:e,viewBox:"0 0 32 16",fill:"currentColor","aria-hidden":"true",focusable:"false",children:g("path",{d:"M8.28 12.54c-.76-.34-1.52-1.08-2.88-2.44l-2.02-2.02-.68-.68-.12-.16a.76.76 90 010-.72l.12-.16.68-.68A16.5 16.5 90 015.9 3.36a4.5 4.5 90 014.62 0c.44.26.94.72 2.5 2.32l1.1 1.1 1.54-1.54-1.1-1.1c-1.48-1.44-2.22-2.18-2.98-2.62a6.76 6.76 90 00-6.82 0c-.74.42-1.46 1.16-2.94 2.6-.64.64-.92.94-1.14 1.28a3 3 90 000 2.92c.2.34.52.64 1.14 1.28L4.3 12.1c1.1 1.08 1.64 1.62 2.26 2.02a6 6 90 001.76.72c.72.18 1.5.18 3.04.18h10.9c1.54 0 2.32 0 3.04-.18q.92-.22 1.76-.72c.64-.4 1.16-.94 2.26-2.02l.46-.48c5.8-5.8-2.88-14.48-8.66-8.66L13.98 10.1c-1.52 1.5-2.28 2.28-3.16 2.56a3.76 3.76 90 01-2.16.02l-.4-.16Z"})})}const Qh=Be(()=>g("path",{d:"M6 10c2-4 3.5-7 6-7s4 3 6 7 4 8 2 9-6-2.5-8-2.5S6 20 4 19s0-5 2-9"})),Kh=Be(()=>g("path",{d:"M18 6 6 18M18 18 6 6"})),Xh=Be(()=>g(pe,{children:[g("path",{d:"M4.5 5.5l.6 10c.2 2.6.2 3.9.9 4.8.3.4.7.8 1.2 1.1.9.6 2.2.6 4.8.6s3.8 0 4.8-.6c.5-.3.9-.7 1.2-1.1.6-.9.7-2.2.9-4.8l.6-10"}),g("path",{d:"m8.05 5.5.61-1.33c.44-.97.66-1.45 1.06-1.76.09-.07.18-.13.28-.18.44-.23.97-.23 2.04-.23 1.04 0 1.56 0 1.99.22.1.05.19.11.27.17.39.29.62.76 1.07 1.69l.68 1.41m4.94 0h-18"})]})),Zh=Be(()=>g("path",{d:"M5 14s1.5.5 3.5 4C8.5 18 12 11 19 7"})),zl=Be(()=>g("path",{d:"M5.8 12 4.3 10.5C2.6 8.8 2.6 6 4.3 4.3c1.7-1.7 4.5-1.7 6.2 0l9.2 9.2c1.7 1.8 1.7 4.5 0 6.2s-4.4 1.7-6.2 0l-3.4-3.4c-1.1-1.1-1.1-2.9 0-3.9 1-1.1 2.8-1.1 3.8 0l2 1.9"})),Jh=Be(()=>g("path",{d:"M21 12a9 9 0 11-6.219-8.56"})),Gs=Be(()=>g(pe,{children:[g("path",{d:"M9.6 6.1c.3-.8 1.5-.8 1.8 0l.9 2.3c.6 1.5 1.8 2.7 3.3 3.3l2.3.9c.8.3.8 1.5 0 1.8l-2.3.9c-1.5.6-2.7 1.8-3.3 3.3l-.9 2.3c-.3.8-1.5.8-1.8 0l-.9-2.3c-.6-1.5-1.8-2.7-3.3-3.3l-2.3-.9c-.8-.3-.8-1.5 0-1.8l2.3-.9c1.5-.6 2.7-1.8 3.3-3.3l.9-2.3Z"}),g("path",{d:"M18.16 2.73c.12-.31.56-.31.68 0l.34.87c.22.56.66 1 1.22 1.22l.87.34c.31.12.31.56 0 .68l-.87.34c-.56.22-1 .66-1.22 1.22l-.34.87c-.12.31-.56.31-.68 0l-.34-.87c-.22-.56-.66-1-1.22-1.22l-.87-.34c-.31-.12-.31-.56 0-.68l.87-.34c.56-.22 1-.66 1.22-1.22l.34-.87Z"})]})),ef=Be(()=>g(pe,{children:[g("path",{d:"M15 15l1.5 1.5"}),g("path",{d:"M16.93 19.03c-.57-.58-.57-1.52 0-2.1.58-.57 1.52-.57 2.1 0l2.04 2.04c.57.58.57 1.52 0 2.1-.58.57-1.52.57-2.1 0l-2.04-2.04Z"}),g("path",{d:"M16.5 9.5c0-3.9-3.1-7-7-7s-7 3.1-7 7 3.1 7 7 7 7-3.1 7-7Z"})]})),Qs=Be(()=>g(pe,{children:[g("path",{d:"M21 11c0-2.2-.2-3.5-1.1-4.4-1.1-1.1-2.9-1.1-6.5-1.1H9.6c-3.6 0-5.4 0-6.5 1.1C2 7.8 2 9.6 2 13.3c0 3.6 0 5.4 1.1 6.6C4.2 21 6 21 9.6 21H11"}),g("path",{d:"M20 20l2 2m-.9-4.5c0-1.9-1.6-3.5-3.6-3.5-1.9 0-3.5 1.6-3.5 3.5 0 2 1.6 3.6 3.5 3.6 2 0 3.6-1.6 3.6-3.6Z"}),g("path",{d:"M7 5.5l.1-.3c.5-1.5.7-2.3 1.3-2.8C9 2 9.8 2 11.4 2h.2c1.6 0 2.4 0 3 .4.6.5.8 1.3 1.3 2.8l.1.3"})]})),Ks=Be(()=>g(pe,{children:[g("path",{d:"M11 21H10c-3.8 0-5.7 0-6.8-1.2C2 18.7 2 16.8 2 13V10C2 6.2 2 4.3 3.2 3.2 4.3 2 6.2 2 10 2h2c3.8 0 5.7 0 6.8 1.2C20 4.3 20 6.2 20 10v.5"}),g("path",{d:"M17.41 14.4c.21-.54.97-.54 1.19 0l.04.09c.52 1.31 1.56 2.35 2.87 2.87l.09.04c.54.21.54.97 0 1.19l-.09.04c-1.31.52-2.35 1.56-2.87 2.87l-.04.09c-.21.54-.97.54-1.19 0l-.04-.09c-.52-1.31-1.56-2.35-2.87-2.87l-.09-.04c-.54-.21-.54-.97 0-1.19l.09-.04c1.31-.52 2.35-1.56 2.87-2.87l.04-.09Z"}),g("path",{d:"M7 7h8M7 11.5h8M7 16h4"})]})),tf=Be(()=>g(pe,{children:[g("path",{d:"M5 14v6"}),g("path",{d:"M5 4v7"}),g("path",{d:"M9 8h6"}),g("path",{d:"M2 14H8"}),g("path",{d:"M16 12h6"}),g("path",{d:"M12 8V4"}),g("path",{d:"M12 11v9"}),g("path",{d:"M19 4v8"}),g("path",{d:"M19 15v5"})]})),nf=Be(()=>g("path",{d:"M4 18c0 2.3 0 3.5.8 3.9 1.5.8 4.3-1.9 5.6-2.7.8-.5 1.2-.7 1.6-.7s.8.2 1.6.7c1.3.8 4.1 3.5 5.6 2.7.8-.4.8-1.6.8-3.9V9.7c0-3.6 0-5.5-1.2-6.6C17.7 2 15.8 2 12 2S6.3 2 5.2 3.1 4 6.1 4 9.7v8.3Z"})),Xs=Be(()=>g(pe,{children:[g("path",{d:"m19.4 7.6-3-3m3 3-6.7 6.7c-.5.5-1.1.9-1.8 1L8 16l.7-2.9c.2-.7.5-1.3 1-1.8l6.7-6.7m3 3 1-1c.8-.8.8-2.1 0-3-.8-.8-2.1-.8-3 0l-1 1"}),g("path",{d:"M10.5 5c-3.29 0-4.93 0-6.04.91-.2.17-.39.35-.55.55C3 7.57 3 9.21 3 12.5V13c0 3.77 0 5.66 1.17 6.83C5.34 21 7.23 21 11 21h.5c3.29 0 4.93 0 6.04-.91.2-.17.39-.35.55-.55.91-1.11.91-2.75.91-6.04"})]})),rf=Be(()=>g("path",{d:"M6 10s3.5 6 6 6 6-6 6-6"})),af=Be(()=>g(pe,{children:[g("path",{d:"M13.6 21.4c-.4.4-1 .6-1.6.6s-1.2-.2-1.6-.6c-4-3.8-9.3-8-6.7-14C5.1 4.1 8.5 2 12 2s6.9 2.1 8.3 5.4c2.6 6.1-2.7 10.3-6.7 14Z"}),g("path",{d:"M15.5 11c0-1.9-1.6-3.5-3.5-3.5S8.5 9.1 8.5 11s1.6 3.5 3.5 3.5 3.5-1.6 3.5-3.5Z"})]})),sf=Be(()=>g(pe,{children:[g("path",{d:"M14.5 12c0 1.4-1.1 2.5-2.5 2.5S9.5 13.4 9.5 12 10.6 9.5 12 9.5s2.5 1.1 2.5 2.5Z"}),g("path",{d:"M18.5 11.5v0"}),g("path",{d:"M5.5 12.5v0"}),g("path",{d:"M16 5c2.5 0 4.2.4 5.1.7.5.2.9.7.9 1.3v9.8c0 1.1-1.2 2-2.3 1.7-.9-.2-2.2-.3-3.7-.3-4.8 0-5.9 1.8-12.9.3-.6-.3-1.1-.9-1.1-1.6V6.9c0-1 .9-1.7 1.9-1.5C10.2 6.7 11.4 5 16 5Z"})]})),of=Be(()=>g(pe,{children:[g("path",{d:"M12 6v6h4"}),g("path",{d:"M12 2C6.5 2 2 6.5 2 12c0 5.5 4.5 10 10 10 5.5 0 10-4.5 10-10"}),g("path",{d:"M18.85 4.17c.17.15.34.31.51.48s.32.33.48.51M15 2c.48.14.95.33 1.41.55m5.02 5.01c.23.47.42.95.56 1.45"})]})),uf={location:af,type:of,salary:sf};function lf({jobs:e}){return g("div",{class:"grid gap-2 py-1.5",children:e.map(t=>g("div",{class:"corner-smooth rounded-kin-xl outline-n-3 bg-n-2 flex items-center gap-1 py-2 pl-3 pr-2.5 outline outline-1",children:[g("div",{class:"flex min-w-0 flex-1 flex-col gap-1",children:[g("p",{class:"text-n-12 text-sm font-semibold leading-snug",children:t.title}),t.details.length>0&&g("div",{class:"text-n-10 flex flex-wrap gap-x-2.5 gap-y-1 text-xs",children:t.details.map(n=>{const r=uf[n.key];return g("span",{class:"flex items-center gap-1",children:[r&&g(r,{class:"size-3 shrink-0"}),n.value]},n.key)})})]}),t.applyUrl&&g("a",{href:t.applyUrl,target:"_blank",rel:"noopener noreferrer",class:bn({variant:"accent",size:"sm"}),"aria-label":`Apply for ${t.title}`,children:"Apply"})]},t.id))})}function cf(e,t){for(var n in t)e[n]=t[n];return e}function oa(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 Zs(e){this.props=e}function Ee(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:oa(this.props,i)}function r(i){return this.shouldComponentUpdate=n,mt(e,i)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(Zs.prototype=new gt).isPureReactComponent=!0,Zs.prototype.shouldComponentUpdate=function(e,t){return oa(this.props,e)||oa(this.state,t)};var Js=G.__b;G.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),Js&&Js(e)};var df=G.__e;G.__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)}df(e,t,n,r)};var eo=G.unmount;function $l(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=cf({},e)).__c!=null&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map(function(r){return $l(r,t,n)})),e}function Yl(e,t,n){return e&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(r){return Yl(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 Vn(){this.__u=0,this.t=null,this.__b=null}function jl(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function Vl(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 mt(n,a)}return i.displayName="Lazy",i.__f=!0,i}function _r(){this.u=null,this.o=null}G.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&e.__h===!0&&(e.type=null),eo&&eo(e)},(Vn.prototype=new gt).__c=function(e,t){var n=t.__c,r=this;r.t==null&&(r.t=[]),r.t.push(n);var i=jl(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 l=r.state.__a;r.__v.__k[0]=Yl(l,l.__c.__P,l.__c.__O)}var h;for(r.setState({__a:r.__b=null});h=r.t.pop();)h.forceUpdate()}},u=t.__h===!0;r.__u++||u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(s,s)},Vn.prototype.componentWillUnmount=function(){this.t=[]},Vn.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]=$l(this.__b,n,r.__O=r.__P)}this.__b=null}var i=t.__a&&mt(pe,null,e.fallback);return i&&(i.__h=null),[mt(pe,null,t.__a?null:e.children),i]};var to=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 hf(e){return this.getChildContext=function(){return e.context},e.children}function ff(e){var t=this,n=e.i;t.componentWillUnmount=function(){qr(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)}}),qr(mt(hf,{context:t.context},e.__v),t.l)):t.l&&t.componentWillUnmount()}function ql(e,t){var n=mt(ff,{__v:e,i:t});return n.containerInfo=t,n}(_r.prototype=new gt).__a=function(e){var t=this,n=jl(t.__v),r=t.o.get(e);return r[0]++,function(i){var a=function(){t.props.revealOrder?(r.push(i),to(t,e,r)):i()};n?n(a):a()}},_r.prototype.render=function(e){this.u=null,this.o=new Map;var t=jr(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},_r.prototype.componentDidUpdate=_r.prototype.componentDidMount=function(){var e=this;this.o.forEach(function(t,n){to(e,n,t)})};var Wl=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.element")||60103,pf=/^(?: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]/,mf=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,gf=/[A-Z0-9]/g,bf=typeof document<"u",Ef=function(e){return(typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(e)};gt.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(gt.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var no=G.event;function Tf(){}function _f(){return this.cancelBubble}function kf(){return this.defaultPrevented}G.event=function(e){return no&&(e=no(e)),e.persist=Tf,e.isPropagationStopped=_f,e.isDefaultPrevented=kf,e.nativeEvent=e};var xf={enumerable:!1,configurable:!0,get:function(){return this.class}},ro=G.vnode;G.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||bf&&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"||Ef(n.type)?o==="onfocus"?a="onfocusin":o==="onblur"?a="onfocusout":mf.test(a)?a=o:r.indexOf("-")===-1&&pf.test(a)?a=a.replace(gf,"-$&").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=jr(n.children).forEach(function(u){u.props.selected=i.value.indexOf(u.props.value)!=-1})),r=="select"&&i.defaultValue!=null&&(i.value=jr(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",xf)):(n.className&&!n.class||n.class&&n.className)&&(i.class=i.className=n.className),t.props=i}(e),e.$$typeof=Wl,ro&&ro(e)};var io=G.__r;G.__r=function(e){io&&io(e)};var ao=G.diffed;G.diffed=function(e){ao&&ao(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 Ot(e){return!!e&&e.$$typeof===Wl}function yf(e){return Ot(e)?xl.apply(null,arguments):e}function wf(e){e()}function Af(){return[!1,wf]}const fi=function(e){if(e==null)return If;if(typeof e=="function")return pi(e);if(typeof e=="object")return Array.isArray(e)?Cf(e):Sf(e);if(typeof e=="string")return vf(e);throw new Error("Expected function, string, or object as test")};function Cf(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=fi(e[n]);return pi(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function Sf(e){const t=e;return pi(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function vf(e){return pi(t);function t(n){return n&&n.type===e}}function pi(e){return t;function t(n,r,i){return!!(Nf(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function If(){return!0}function Nf(e){return e!==null&&typeof e=="object"&&"type"in e}const Gl=[],Hn=!0,ua=!1,dn="skip";function ja(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=fi(i),s=r?-1:1;o(e,void 0,[])();function o(u,l,h){const d=u&&typeof u=="object"?u:{};if(typeof d.type=="string"){const f=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0;Object.defineProperty(p,"name",{value:"node ("+(u.type+(f?"<"+f+">":""))+")"})}return p;function p(){let f=Gl,m,_,x;if((!t||a(u,l,h[h.length-1]||void 0))&&(f=Lf(n(u,h)),f[0]===ua))return f;if("children"in u&&u.children){const k=u;if(k.children&&f[0]!==dn)for(_=(r?k.children.length:-1)+s,x=h.concat(k);_>-1&&_<k.children.length;){const v=k.children[_];if(m=o(v,_,x)(),m[0]===ua)return m;_=typeof m[1]=="number"?m[1]:_+s}}return f}}}function Lf(e){return Array.isArray(e)?e:typeof e=="number"?[Hn,e]:e==null?Gl:[e]}function Mt(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),ja(e,a,o,i);function o(u,l){const h=l[l.length-1],d=h?h.children.indexOf(u):void 0;return s(u,d,h)}}const En={indicator:"indicator",textOnly:"text-only",remove:"remove"};function Rf({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 l=t.length&&!t.every(d=>d==="*"),h=n.length&&!n.every(d=>d==="*");if(!e&&(l||h))throw new Error("defaultOrigin is required when allowedLinkPrefixes or allowedImagePrefixes are provided");return d=>{const p=Ff(e,t,n,r,i,a,s,o,u);Ql(d),Mt(d,p)}}function so(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 Of(e){return typeof e!="string"?!1:e.startsWith("/")||e.startsWith("./")||e.startsWith("../")}const Df=new Set(["https:","http:","irc:","ircs:","mailto:","xmpp:","blob:"]),Pf=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 h=e.substring(5);if(h&&h.length>0&&h!=="invalid")return e}}catch{return null}return null}const s=so(e,n);if(!s||Pf.has(s.protocol)||!(Df.has(s.protocol)||a.includes(s.protocol)||a.includes("*")))return null;if(s.protocol==="mailto:"||!s.protocol.match(/^https?:$/))return s.href;const u=Of(e);return s&&t.some(l=>{const h=so(l,n);return!h||h.origin!==s.origin?!1:s.href.startsWith(h.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 Ql(e){if("children"in e&&Array.isArray(e.children)){e.children=e.children.filter(t=>t!=null);for(const t of e.children)Ql(t)}}const Pi=Symbol("node-seen");function Mf(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 Bf(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 Ff=(e,t,n,r,i,a,s,o,u)=>{const l=(h,d,p)=>{if(h.type!=="element"||h[Pi])return Hn;if(h.tagName==="a"){const f=oo(h.properties.href,t,e,!1,!1,i);if(f===null){if(h[Pi]=!0,Mt(h,l),p&&typeof d=="number"){const m=Mf(h,o,s);if(m.type==="remove")return p.children.splice(d,1),[dn,d];p.children[d]=m.element}return dn}else return h.properties.href=f,h.properties.target="_blank",h.properties.rel="noopener noreferrer",Hn}if(h.tagName==="img"){const f=oo(h.properties.src,n,e,r,!0,i);if(f===null){if(h[Pi]=!0,Mt(h,l),p&&typeof d=="number"){const m=Bf(h,u,a);if(m.type==="remove")return p.children.splice(d,1),[dn,d];p.children[d]=m.element}return dn}else return h.properties.src=f,Hn}return Hn};return l},Kl=-1,mi=0,qn=1,Qr=2,Va=3,qa=4,Wa=5,Ga=6,Xl=7,Zl=8,uo=typeof self=="object"?self:globalThis,Hf=(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 mi:case Kl:return n(s,i);case qn:{const o=n([],i);for(const u of s)o.push(r(u));return o}case Qr:{const o=n({},i);for(const[u,l]of s)o[r(u)]=r(l);return o}case Va:return n(new Date(s),i);case qa:{const{source:o,flags:u}=s;return n(new RegExp(o,u),i)}case Wa:{const o=n(new Map,i);for(const[u,l]of s)o.set(r(u),r(l));return o}case Ga:{const o=n(new Set,i);for(const u of s)o.add(r(u));return o}case Xl:{const{name:o,message:u}=s;return n(new uo[o](u),i)}case Zl: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 uo[a](s),i)};return r},lo=e=>Hf(new Map,e)(0),ln="",{toString:Uf}={},{keys:zf}=Object,Rn=e=>{const t=typeof e;if(t!=="object"||!e)return[mi,t];const n=Uf.call(e).slice(8,-1);switch(n){case"Array":return[qn,ln];case"Object":return[Qr,ln];case"Date":return[Va,ln];case"RegExp":return[qa,ln];case"Map":return[Wa,ln];case"Set":return[Ga,ln];case"DataView":return[qn,n]}return n.includes("Array")?[qn,n]:n.includes("Error")?[Xl,n]:[Qr,n]},kr=([e,t])=>e===mi&&(t==="function"||t==="symbol"),$f=(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]=Rn(s);switch(o){case mi:{let h=s;switch(u){case"bigint":o=Zl,h=s.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+u);h=null;break;case"undefined":return i([Kl],s)}return i([o,h],s)}case qn:{if(u){let p=s;return u==="DataView"?p=new Uint8Array(s.buffer):u==="ArrayBuffer"&&(p=new Uint8Array(s)),i([u,[...p]],s)}const h=[],d=i([o,h],s);for(const p of s)h.push(a(p));return d}case Qr:{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 h=[],d=i([o,h],s);for(const p of zf(s))(e||!kr(Rn(s[p])))&&h.push([a(p),a(s[p])]);return d}case Va:return i([o,s.toISOString()],s);case qa:{const{source:h,flags:d}=s;return i([o,{source:h,flags:d}],s)}case Wa:{const h=[],d=i([o,h],s);for(const[p,f]of s)(e||!(kr(Rn(p))||kr(Rn(f))))&&h.push([a(p),a(f)]);return d}case Ga:{const h=[],d=i([o,h],s);for(const p of s)(e||!kr(Rn(p)))&&h.push(a(p));return d}}const{message:l}=s;return i([o,{name:u,message:l}],s)};return a},co=(e,{json:t,lossy:n}={})=>{const r=[];return $f(!(t||n),!!t,new Map,r)(e),r},Zt=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?lo(co(e,t)):structuredClone(e):(e,t)=>lo(co(e,t));class hr{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}}hr.prototype.normal={};hr.prototype.property={};hr.prototype.space=void 0;function Jl(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new hr(n,r,t)}function ir(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 Yf=0;const re=tn(),Re=tn(),la=tn(),H=tn(),xe=tn(),mn=tn(),Xe=tn();function tn(){return 2**++Yf}const ca=Object.freeze(Object.defineProperty({__proto__:null,boolean:re,booleanish:Re,commaOrSpaceSeparated:Xe,commaSeparated:mn,number:H,overloadedBoolean:la,spaceSeparated:xe},Symbol.toStringTag,{value:"Module"})),Mi=Object.keys(ca);class Qa extends Qe{constructor(t,n,r,i){let a=-1;if(super(t,n),ho(this,"space",i),typeof r=="number")for(;++a<Mi.length;){const s=Mi[a];ho(this,Mi[a],(r&ca[s])===ca[s])}}}Qa.prototype.defined=!0;function ho(e,t,n){n&&(e[t]=n)}function wn(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const a=new Qa(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[ir(r)]=r,n[ir(a.attribute)]=r}return new hr(t,n,e.space)}const ec=wn({properties:{ariaActiveDescendant:null,ariaAtomic:Re,ariaAutoComplete:null,ariaBusy:Re,ariaChecked:Re,ariaColCount:H,ariaColIndex:H,ariaColSpan:H,ariaControls:xe,ariaCurrent:null,ariaDescribedBy:xe,ariaDetails:null,ariaDisabled:Re,ariaDropEffect:xe,ariaErrorMessage:null,ariaExpanded:Re,ariaFlowTo:xe,ariaGrabbed:Re,ariaHasPopup:null,ariaHidden:Re,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:xe,ariaLevel:H,ariaLive:null,ariaModal:Re,ariaMultiLine:Re,ariaMultiSelectable:Re,ariaOrientation:null,ariaOwns:xe,ariaPlaceholder:null,ariaPosInSet:H,ariaPressed:Re,ariaReadOnly:Re,ariaRelevant:null,ariaRequired:Re,ariaRoleDescription:xe,ariaRowCount:H,ariaRowIndex:H,ariaRowSpan:H,ariaSelected:Re,ariaSetSize:H,ariaSort:null,ariaValueMax:H,ariaValueMin:H,ariaValueNow:H,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function tc(e,t){return t in e?e[t]:t}function nc(e,t){return tc(e,t.toLowerCase())}const jf=wn({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:mn,acceptCharset:xe,accessKey:xe,action:null,allow:null,allowFullScreen:re,allowPaymentRequest:re,allowUserMedia:re,alt:null,as:null,async:re,autoCapitalize:null,autoComplete:xe,autoFocus:re,autoPlay:re,blocking:xe,capture:null,charSet:null,checked:re,cite:null,className:xe,cols:H,colSpan:null,content:null,contentEditable:Re,controls:re,controlsList:xe,coords:H|mn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:re,defer:re,dir:null,dirName:null,disabled:re,download:la,draggable:Re,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:re,formTarget:null,headers:xe,height:H,hidden:la,high:H,href:null,hrefLang:null,htmlFor:xe,httpEquiv:xe,id:null,imageSizes:null,imageSrcSet:null,inert:re,inputMode:null,integrity:null,is:null,isMap:re,itemId:null,itemProp:xe,itemRef:xe,itemScope:re,itemType:xe,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:re,low:H,manifest:null,max:null,maxLength:H,media:null,method:null,min:null,minLength:H,multiple:re,muted:re,name:null,nonce:null,noModule:re,noValidate:re,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:re,optimum:H,pattern:null,ping:xe,placeholder:null,playsInline:re,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:re,referrerPolicy:null,rel:xe,required:re,reversed:re,rows:H,rowSpan:H,sandbox:xe,scope:null,scoped:re,seamless:re,selected:re,shadowRootClonable:re,shadowRootDelegatesFocus:re,shadowRootMode:null,shape:null,size:H,sizes:null,slot:null,span:H,spellCheck:Re,src:null,srcDoc:null,srcLang:null,srcSet:null,start:H,step:null,style:null,tabIndex:H,target:null,title:null,translate:null,type:null,typeMustMatch:re,useMap:null,value:Re,width:H,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:xe,axis:null,background:null,bgColor:null,border:H,borderColor:null,bottomMargin:H,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:re,declare:re,event:null,face:null,frame:null,frameBorder:null,hSpace:H,leftMargin:H,link:null,longDesc:null,lowSrc:null,marginHeight:H,marginWidth:H,noResize:re,noHref:re,noShade:re,noWrap:re,object:null,profile:null,prompt:null,rev:null,rightMargin:H,rules:null,scheme:null,scrolling:Re,standby:null,summary:null,text:null,topMargin:H,valueType:null,version:null,vAlign:null,vLink:null,vSpace:H,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:re,disableRemotePlayback:re,prefix:null,property:null,results:H,security:null,unselectable:null},space:"html",transform:nc}),Vf=wn({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:Xe,accentHeight:H,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:H,amplitude:H,arabicForm:null,ascent:H,attributeName:null,attributeType:null,azimuth:H,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:H,by:null,calcMode:null,capHeight:H,className:xe,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:H,diffuseConstant:H,direction:null,display:null,dur:null,divisor:H,dominantBaseline:null,download:re,dx:null,dy:null,edgeMode:null,editable:null,elevation:H,enableBackground:null,end:null,event:null,exponent:H,externalResourcesRequired:null,fill:null,fillOpacity:H,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:mn,g2:mn,glyphName:mn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:H,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:H,horizOriginX:H,horizOriginY:H,id:null,ideographic:H,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:H,k:H,k1:H,k2:H,k3:H,k4:H,kernelMatrix:Xe,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:H,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:H,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:H,overlineThickness:H,paintOrder:null,panose1:null,path:null,pathLength:H,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:xe,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:H,pointsAtY:H,pointsAtZ:H,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Xe,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Xe,rev:Xe,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Xe,requiredFeatures:Xe,requiredFonts:Xe,requiredFormats:Xe,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:H,specularExponent:H,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:H,strikethroughThickness:H,string:null,stroke:null,strokeDashArray:Xe,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:H,strokeOpacity:H,strokeWidth:null,style:null,surfaceScale:H,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Xe,tabIndex:H,tableValues:null,target:null,targetX:H,targetY:H,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Xe,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:H,underlineThickness:H,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:H,values:null,vAlphabetic:H,vMathematical:H,vectorEffect:null,vHanging:H,vIdeographic:H,version:null,vertAdvY:H,vertOriginX:H,vertOriginY:H,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:H,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:tc}),rc=wn({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()}}),ic=wn({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:nc}),ac=wn({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),qf={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"},Wf=/[A-Z]/g,fo=/-[a-z]/g,Gf=/^data[-\w.:]+$/i;function gi(e,t){const n=ir(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"&&Gf.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(fo,Kf);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!fo.test(a)){let s=a.replace(Wf,Qf);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}i=Qa}return new i(r,t)}function Qf(e){return"-"+e.toLowerCase()}function Kf(e){return e.charAt(1).toUpperCase()}const fr=Jl([ec,jf,rc,ic,ac],"html"),Ht=Jl([ec,Vf,rc,ic,ac],"svg");function po(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 sc(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const mo=/[#.]/g;function Xf(e,t){const n=e||"",r={};let i=0,a,s;for(;i<n.length;){mo.lastIndex=i;const o=mo.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 go(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function oc(e){return e.join(" ").trim()}function uc(e,t,n){const r=n?tp(n):void 0;function i(a,s,...o){let u;if(a==null){u={type:"root",children:[]};const l=s;o.unshift(l)}else{u=Xf(a,t);const l=u.tagName.toLowerCase(),h=r?r.get(l):void 0;if(u.tagName=h||l,Zf(s))o.unshift(s);else for(const[d,p]of Object.entries(s))Jf(e,u.properties,d,p)}for(const l of o)da(u.children,l);return u.type==="element"&&u.tagName==="template"&&(u.content={type:"root",children:u.children},u.children=[]),u}return i}function Zf(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 Jf(e,t,n,r){const i=gi(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=go(r):i.commaSeparated?a=po(r):i.commaOrSpaceSeparated?a=go(po(r).join(" ")):a=bo(i,i.property,r):Array.isArray(r)?a=[...r]:a=i.property==="style"?ep(r):String(r);if(Array.isArray(a)){const s=[];for(const o of a)s.push(bo(i,i.property,o));a=s}i.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[i.property]=a}}function da(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)da(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?da(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function bo(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||ir(n)===ir(t)))return!0}return n}function ep(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function tp(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const np=["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"],rp=uc(fr,"div"),ip=uc(Ht,"g",np);function ap(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=Eo(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=Eo(t,o),l=u===-1?t.length+1:u+1;if(o===l)break;n.push(l)}const s=(a.line>1?n[a.line-2]:0)+a.column-1;if(s<n[a.line-1])return s}}}function Eo(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/"},lc={}.hasOwnProperty,sp=Object.prototype;function op(e,t){const n=t||{};return Ka({file:n.file||void 0,location:!1,schema:n.space==="svg"?Ht:fr,verbose:n.verbose||!1},e)}function Ka(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Mr(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:cc(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){const a=String(e.file),s=ap(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"},Mr(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Mr(e,r,n),n}default:return n=up(e,t),n}}function cc(e,t){let n=-1;const r=[];for(;++n<t.length;){const i=Ka(e,t[n]);r.push(i)}return r}function up(e,t){const n=e.schema;e.schema=t.namespaceURI===Qt.svg?Ht:fr;let r=-1;const i={};for(;++r<t.attrs.length;){const o=t.attrs[r],u=(o.prefix?o.prefix+":":"")+o.name;lc.call(sp,u)||(i[u]=o.value)}const s=(e.schema.space==="svg"?ip:rp)(t.tagName,i,cc(e,t.childNodes));if(Mr(e,t,s),s.tagName==="template"){const o=t,u=o.sourceCodeLocation,l=u&&u.startTag&&hn(u.startTag),h=u&&u.endTag&&hn(u.endTag),d=Ka(e,o.content);l&&h&&e.file&&(d.position={start:l.end,end:h.start}),s.content=d}return e.schema=n,s}function Mr(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=lp(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function lp(e,t,n){const r=hn(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)lc.call(n.attrs,s)&&(a[gi(e.schema,s).property]=hn(n.attrs[s]));const o=hn(n.startTag),u=n.endTag?hn(n.endTag):void 0,l={opening:o};u&&(l.closing=u),l.properties=a,t.data={position:l}}}return r}function hn(e){const t=To({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=To({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function To(e){return e.line&&e.column?e:void 0}const _o={}.hasOwnProperty;function dc(e,t){const n=t||{};function r(i,...a){let s=r.invalid;const o=r.handlers;if(i&&_o.call(i,e)){const u=String(i[e]);s=_o.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 cp={},dp={}.hasOwnProperty,hc=dc("type",{handlers:{root:fp,element:Ep,text:gp,comment:bp,doctype:mp}});function hp(e,t){const r=(t||cp).space;return hc(e,r==="svg"?Ht:fr)}function fp(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=Xa(e.children,n,t),An(e,n),n}function pp(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=Xa(e.children,n,t),An(e,n),n}function mp(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return An(e,t),t}function gp(e){const t={nodeName:"#text",value:e.value,parentNode:null};return An(e,t),t}function bp(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return An(e,t),t}function Ep(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=Ht);const i=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&dp.call(e.properties,a)){const u=Tp(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=Xa(e.children,o,r),An(e,o),e.tagName==="template"&&e.content&&(o.content=pp(e.content,r)),o}function Tp(e,t,n){const r=gi(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?sc(n):oc(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 Xa(e,t,n){let r=-1;const i=[];if(e)for(;++r<e.length;){const a=hc(e[r],n);a.parentNode=t,i.push(a)}return i}function An(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 _p=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],kp=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]),we="�";var b;(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"})(b||(b={}));const qe={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function fc(e){return e>=55296&&e<=57343}function xp(e){return e>=56320&&e<=57343}function yp(e,t){return(e-55296)*1024+9216+t}function pc(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function mc(e){return e>=64976&&e<=65007||kp.has(e)}var N;(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"})(N||(N={}));const wp=65536;class Ap{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=wp,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(xp(n))return this.pos++,this._addGap(),yp(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,b.EOF;return this._err(N.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,b.EOF;const r=this.html.charCodeAt(n);return r===b.CARRIAGE_RETURN?b.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,b.EOF;let t=this.html.charCodeAt(this.pos);return t===b.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,b.LINE_FEED):t===b.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,fc(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===b.LINE_FEED||t===b.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){pc(t)?this._err(N.controlCharacterInInputStream):mc(t)&&this._err(N.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var ae;(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"})(ae||(ae={}));function gc(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 Cp=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))),Sp=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 vp(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=Sp.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 Ip=32;var Dt;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Dt||(Dt={}));function ha(e){return e>=Pe.ZERO&&e<=Pe.NINE}function Np(e){return e>=Pe.UPPER_A&&e<=Pe.UPPER_F||e>=Pe.LOWER_A&&e<=Pe.LOWER_F}function Lp(e){return e>=Pe.UPPER_A&&e<=Pe.UPPER_Z||e>=Pe.LOWER_A&&e<=Pe.LOWER_Z||ha(e)}function Rp(e){return e===Pe.EQUALS||Lp(e)}var De;(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"})(De||(De={}));var yt;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(yt||(yt={}));class Op{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=De.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=yt.Strict}startEntity(t){this.decodeMode=t,this.state=De.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case De.EntityStart:return t.charCodeAt(n)===Pe.NUM?(this.state=De.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=De.NamedEntity,this.stateNamedEntity(t,n));case De.NumericStart:return this.stateNumericStart(t,n);case De.NumericDecimal:return this.stateNumericDecimal(t,n);case De.NumericHex:return this.stateNumericHex(t,n);case De.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|Ip)===Pe.LOWER_X?(this.state=De.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=De.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(ha(i)||Np(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(ha(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===yt.Strict)return 0;return this.emitCodePoint(vp(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&Dt.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const s=t.charCodeAt(n);if(this.treeIndex=Dp(r,i,this.treeIndex+Math.max(1,a),s),this.treeIndex<0)return this.result===0||this.decodeMode===yt.Attribute&&(a===0||Rp(s))?0:this.emitNotTerminatedNamedEntity();if(i=r[this.treeIndex],a=(i&Dt.VALUE_LENGTH)>>14,a!==0){if(s===Pe.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==yt.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]&Dt.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]&~Dt.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case De.NamedEntity:return this.result!==0&&(this.decodeMode!==yt.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case De.NumericDecimal:return this.emitNumericEntity(0,2);case De.NumericHex:return this.emitNumericEntity(0,3);case De.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case De.EntityStart:return 0}}}function Dp(e,t,n,r){const i=(t&Dt.BRANCH_LENGTH)>>7,a=t&Dt.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,l=e[u];if(l<r)s=u+1;else if(l>r)o=u-1;else return e[u+i]}return-1}var P;(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/"})(P||(P={}));var Kt;(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"})(Kt||(Kt={}));var it;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(it||(it={}));var I;(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"})(I||(I={}));var c;(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"})(c||(c={}));const Pp=new Map([[I.A,c.A],[I.ADDRESS,c.ADDRESS],[I.ANNOTATION_XML,c.ANNOTATION_XML],[I.APPLET,c.APPLET],[I.AREA,c.AREA],[I.ARTICLE,c.ARTICLE],[I.ASIDE,c.ASIDE],[I.B,c.B],[I.BASE,c.BASE],[I.BASEFONT,c.BASEFONT],[I.BGSOUND,c.BGSOUND],[I.BIG,c.BIG],[I.BLOCKQUOTE,c.BLOCKQUOTE],[I.BODY,c.BODY],[I.BR,c.BR],[I.BUTTON,c.BUTTON],[I.CAPTION,c.CAPTION],[I.CENTER,c.CENTER],[I.CODE,c.CODE],[I.COL,c.COL],[I.COLGROUP,c.COLGROUP],[I.DD,c.DD],[I.DESC,c.DESC],[I.DETAILS,c.DETAILS],[I.DIALOG,c.DIALOG],[I.DIR,c.DIR],[I.DIV,c.DIV],[I.DL,c.DL],[I.DT,c.DT],[I.EM,c.EM],[I.EMBED,c.EMBED],[I.FIELDSET,c.FIELDSET],[I.FIGCAPTION,c.FIGCAPTION],[I.FIGURE,c.FIGURE],[I.FONT,c.FONT],[I.FOOTER,c.FOOTER],[I.FOREIGN_OBJECT,c.FOREIGN_OBJECT],[I.FORM,c.FORM],[I.FRAME,c.FRAME],[I.FRAMESET,c.FRAMESET],[I.H1,c.H1],[I.H2,c.H2],[I.H3,c.H3],[I.H4,c.H4],[I.H5,c.H5],[I.H6,c.H6],[I.HEAD,c.HEAD],[I.HEADER,c.HEADER],[I.HGROUP,c.HGROUP],[I.HR,c.HR],[I.HTML,c.HTML],[I.I,c.I],[I.IMG,c.IMG],[I.IMAGE,c.IMAGE],[I.INPUT,c.INPUT],[I.IFRAME,c.IFRAME],[I.KEYGEN,c.KEYGEN],[I.LABEL,c.LABEL],[I.LI,c.LI],[I.LINK,c.LINK],[I.LISTING,c.LISTING],[I.MAIN,c.MAIN],[I.MALIGNMARK,c.MALIGNMARK],[I.MARQUEE,c.MARQUEE],[I.MATH,c.MATH],[I.MENU,c.MENU],[I.META,c.META],[I.MGLYPH,c.MGLYPH],[I.MI,c.MI],[I.MO,c.MO],[I.MN,c.MN],[I.MS,c.MS],[I.MTEXT,c.MTEXT],[I.NAV,c.NAV],[I.NOBR,c.NOBR],[I.NOFRAMES,c.NOFRAMES],[I.NOEMBED,c.NOEMBED],[I.NOSCRIPT,c.NOSCRIPT],[I.OBJECT,c.OBJECT],[I.OL,c.OL],[I.OPTGROUP,c.OPTGROUP],[I.OPTION,c.OPTION],[I.P,c.P],[I.PARAM,c.PARAM],[I.PLAINTEXT,c.PLAINTEXT],[I.PRE,c.PRE],[I.RB,c.RB],[I.RP,c.RP],[I.RT,c.RT],[I.RTC,c.RTC],[I.RUBY,c.RUBY],[I.S,c.S],[I.SCRIPT,c.SCRIPT],[I.SEARCH,c.SEARCH],[I.SECTION,c.SECTION],[I.SELECT,c.SELECT],[I.SOURCE,c.SOURCE],[I.SMALL,c.SMALL],[I.SPAN,c.SPAN],[I.STRIKE,c.STRIKE],[I.STRONG,c.STRONG],[I.STYLE,c.STYLE],[I.SUB,c.SUB],[I.SUMMARY,c.SUMMARY],[I.SUP,c.SUP],[I.TABLE,c.TABLE],[I.TBODY,c.TBODY],[I.TEMPLATE,c.TEMPLATE],[I.TEXTAREA,c.TEXTAREA],[I.TFOOT,c.TFOOT],[I.TD,c.TD],[I.TH,c.TH],[I.THEAD,c.THEAD],[I.TITLE,c.TITLE],[I.TR,c.TR],[I.TRACK,c.TRACK],[I.TT,c.TT],[I.U,c.U],[I.UL,c.UL],[I.SVG,c.SVG],[I.VAR,c.VAR],[I.WBR,c.WBR],[I.XMP,c.XMP]]);function Cn(e){var t;return(t=Pp.get(e))!==null&&t!==void 0?t:c.UNKNOWN}const B=c,Mp={[P.HTML]:new Set([B.ADDRESS,B.APPLET,B.AREA,B.ARTICLE,B.ASIDE,B.BASE,B.BASEFONT,B.BGSOUND,B.BLOCKQUOTE,B.BODY,B.BR,B.BUTTON,B.CAPTION,B.CENTER,B.COL,B.COLGROUP,B.DD,B.DETAILS,B.DIR,B.DIV,B.DL,B.DT,B.EMBED,B.FIELDSET,B.FIGCAPTION,B.FIGURE,B.FOOTER,B.FORM,B.FRAME,B.FRAMESET,B.H1,B.H2,B.H3,B.H4,B.H5,B.H6,B.HEAD,B.HEADER,B.HGROUP,B.HR,B.HTML,B.IFRAME,B.IMG,B.INPUT,B.LI,B.LINK,B.LISTING,B.MAIN,B.MARQUEE,B.MENU,B.META,B.NAV,B.NOEMBED,B.NOFRAMES,B.NOSCRIPT,B.OBJECT,B.OL,B.P,B.PARAM,B.PLAINTEXT,B.PRE,B.SCRIPT,B.SECTION,B.SELECT,B.SOURCE,B.STYLE,B.SUMMARY,B.TABLE,B.TBODY,B.TD,B.TEMPLATE,B.TEXTAREA,B.TFOOT,B.TH,B.THEAD,B.TITLE,B.TR,B.TRACK,B.UL,B.WBR,B.XMP]),[P.MATHML]:new Set([B.MI,B.MO,B.MN,B.MS,B.MTEXT,B.ANNOTATION_XML]),[P.SVG]:new Set([B.TITLE,B.FOREIGN_OBJECT,B.DESC]),[P.XLINK]:new Set,[P.XML]:new Set,[P.XMLNS]:new Set},fa=new Set([B.H1,B.H2,B.H3,B.H4,B.H5,B.H6]);var T;(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"})(T||(T={}));const Le={DATA:T.DATA,RCDATA:T.RCDATA,RAWTEXT:T.RAWTEXT,SCRIPT_DATA:T.SCRIPT_DATA,PLAINTEXT:T.PLAINTEXT,CDATA_SECTION:T.CDATA_SECTION};function Bp(e){return e>=b.DIGIT_0&&e<=b.DIGIT_9}function Un(e){return e>=b.LATIN_CAPITAL_A&&e<=b.LATIN_CAPITAL_Z}function Fp(e){return e>=b.LATIN_SMALL_A&&e<=b.LATIN_SMALL_Z}function Nt(e){return Fp(e)||Un(e)}function ko(e){return Nt(e)||Bp(e)}function xr(e){return e+32}function bc(e){return e===b.SPACE||e===b.LINE_FEED||e===b.TABULATION||e===b.FORM_FEED}function xo(e){return bc(e)||e===b.SOLIDUS||e===b.GREATER_THAN_SIGN}function Hp(e){return e===b.NULL?N.nullCharacterReference:e>1114111?N.characterReferenceOutsideUnicodeRange:fc(e)?N.surrogateCharacterReference:mc(e)?N.noncharacterCharacterReference:pc(e)||e===b.CARRIAGE_RETURN?N.controlCharacterReference:null}class Up{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=T.DATA,this.returnState=T.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new Ap(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new Op(Cp,(r,i)=>{this.preprocessor.pos=this.entityStartPos+i-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(N.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(N.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const i=Hp(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==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||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:ae.START_TAG,tagName:"",tagID:c.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:ae.END_TAG,tagName:"",tagID:c.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:ae.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:ae.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(gc(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(N.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=Cn(t.tagName),t.type===ae.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(N.endTagWithAttributes),t.selfClosing&&this._err(N.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 ae.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case ae.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case ae.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:ae.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=bc(t)?ae.WHITESPACE_CHARACTER:t===b.NULL?ae.NULL_CHARACTER:ae.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(ae.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=T.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?yt.Attribute:yt.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===T.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===T.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===T.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case T.DATA:{this._stateData(t);break}case T.RCDATA:{this._stateRcdata(t);break}case T.RAWTEXT:{this._stateRawtext(t);break}case T.SCRIPT_DATA:{this._stateScriptData(t);break}case T.PLAINTEXT:{this._statePlaintext(t);break}case T.TAG_OPEN:{this._stateTagOpen(t);break}case T.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case T.TAG_NAME:{this._stateTagName(t);break}case T.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case T.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case T.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case T.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case T.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case T.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case T.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case T.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case T.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case T.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case T.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case T.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case T.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case T.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case T.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case T.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case T.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case T.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case T.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case T.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case T.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case T.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case T.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case T.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case T.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case T.BOGUS_COMMENT:{this._stateBogusComment(t);break}case T.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case T.COMMENT_START:{this._stateCommentStart(t);break}case T.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case T.COMMENT:{this._stateComment(t);break}case T.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case T.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case T.COMMENT_END:{this._stateCommentEnd(t);break}case T.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case T.DOCTYPE:{this._stateDoctype(t);break}case T.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case T.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case T.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case T.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case T.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case T.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case T.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case T.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case T.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case T.CDATA_SECTION:{this._stateCdataSection(t);break}case T.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case T.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case T.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case T.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.TAG_OPEN;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitCodePoint(t);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case b.AMPERSAND:{this._startCharacterReference();break}case b.LESS_THAN_SIGN:{this.state=T.RCDATA_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.RAWTEXT_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Nt(t))this._createStartTagToken(),this.state=T.TAG_NAME,this._stateTagName(t);else switch(t){case b.EXCLAMATION_MARK:{this.state=T.MARKUP_DECLARATION_OPEN;break}case b.SOLIDUS:{this.state=T.END_TAG_OPEN;break}case b.QUESTION_MARK:{this._err(N.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t);break}case b.EOF:{this._err(N.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(N.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=T.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Nt(t))this._createEndTagToken(),this.state=T.TAG_NAME,this._stateTagName(t);else switch(t){case b.GREATER_THAN_SIGN:{this._err(N.missingEndTagName),this.state=T.DATA;break}case b.EOF:{this._err(N.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(N.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.SOLIDUS:{this.state=T.SELF_CLOSING_START_TAG;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentTagToken();break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.tagName+=we;break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(Un(t)?xr(t):t)}}_stateRcdataLessThanSign(t){t===b.SOLIDUS?this.state=T.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=T.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Nt(t)?(this.state=T.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=T.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 b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=T.BEFORE_ATTRIBUTE_NAME,!1;case b.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=T.SELF_CLOSING_START_TAG,!1;case b.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=T.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===b.SOLIDUS?this.state=T.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Nt(t)?(this.state=T.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case b.SOLIDUS:{this.state=T.SCRIPT_DATA_END_TAG_OPEN;break}case b.EXCLAMATION_MARK:{this.state=T.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=T.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Nt(t)?(this.state=T.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===b.HYPHEN_MINUS?(this.state=T.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===b.HYPHEN_MINUS?(this.state=T.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_ESCAPED,this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case b.HYPHEN_MINUS:{this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.GREATER_THAN_SIGN:{this.state=T.SCRIPT_DATA,this._emitChars(">");break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_ESCAPED,this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===b.SOLIDUS?this.state=T.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Nt(t)?(this._emitChars("<"),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Nt(t)?(this.state=T.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(qe.SCRIPT,!1)&&xo(this.preprocessor.peek(qe.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<qe.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case b.HYPHEN_MINUS:{this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.GREATER_THAN_SIGN:{this.state=T.SCRIPT_DATA,this._emitChars(">");break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(we);break}case b.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===b.SOLIDUS?(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(qe.SCRIPT,!1)&&xo(this.preprocessor.peek(qe.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<qe.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=T.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.SOLIDUS:case b.GREATER_THAN_SIGN:case b.EOF:{this.state=T.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case b.EQUALS_SIGN:{this._err(N.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=T.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=T.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:case b.SOLIDUS:case b.GREATER_THAN_SIGN:case b.EOF:{this._leaveAttrName(),this.state=T.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case b.EQUALS_SIGN:{this._leaveAttrName(),this.state=T.BEFORE_ATTRIBUTE_VALUE;break}case b.QUOTATION_MARK:case b.APOSTROPHE:case b.LESS_THAN_SIGN:{this._err(N.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.name+=we;break}default:this.currentAttr.name+=String.fromCodePoint(Un(t)?xr(t):t)}}_stateAfterAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.SOLIDUS:{this.state=T.SELF_CLOSING_START_TAG;break}case b.EQUALS_SIGN:{this.state=T.BEFORE_ATTRIBUTE_VALUE;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=T.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{this.state=T.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this.state=T.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingAttributeValue),this.state=T.DATA,this.emitCurrentTagToken();break}default:this.state=T.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=we;break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case b.APOSTROPHE:{this.state=T.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=we;break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this._leaveAttrValue(),this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=T.DATA,this.emitCurrentTagToken();break}case b.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=we;break}case b.QUOTATION_MARK:case b.APOSTROPHE:case b.LESS_THAN_SIGN:case b.EQUALS_SIGN:case b.GRAVE_ACCENT:{this._err(N.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this._leaveAttrValue(),this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.SOLIDUS:{this._leaveAttrValue(),this.state=T.SELF_CLOSING_START_TAG;break}case b.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._err(N.missingWhitespaceBetweenAttributes),this.state=T.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case b.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._err(N.unexpectedSolidusInTag),this.state=T.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.data+=we;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(qe.DASH_DASH,!0)?(this._createCommentToken(qe.DASH_DASH.length+1),this.state=T.COMMENT_START):this._consumeSequenceIfMatch(qe.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(qe.DOCTYPE.length+1),this.state=T.DOCTYPE):this._consumeSequenceIfMatch(qe.CDATA_START,!0)?this.inForeignNode?this.state=T.CDATA_SECTION:(this._err(N.cdataInHtmlContent),this._createCommentToken(qe.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=T.BOGUS_COMMENT):this._ensureHibernation()||(this._err(N.incorrectlyOpenedComment),this._createCommentToken(2),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_START_DASH;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptClosingOfEmptyComment),this.state=T.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=T.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptClosingOfEmptyComment),this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=T.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END_DASH;break}case b.LESS_THAN_SIGN:{n.data+="<",this.state=T.COMMENT_LESS_THAN_SIGN;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.data+=we;break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case b.EXCLAMATION_MARK:{n.data+="!",this.state=T.COMMENT_LESS_THAN_SIGN_BANG;break}case b.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=T.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===b.HYPHEN_MINUS?this.state=T.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=T.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===b.HYPHEN_MINUS?this.state=T.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=T.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==b.GREATER_THAN_SIGN&&t!==b.EOF&&this._err(N.nestedComment),this.state=T.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END;break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=T.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentComment(n);break}case b.EXCLAMATION_MARK:{this.state=T.COMMENT_END_BANG;break}case b.HYPHEN_MINUS:{n.data+="-";break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=T.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{n.data+="--!",this.state=T.COMMENT_END_DASH;break}case b.GREATER_THAN_SIGN:{this._err(N.incorrectlyClosedComment),this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=T.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this.state=T.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case b.EOF:{this._err(N.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingWhitespaceBeforeDoctypeName),this.state=T.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(Un(t))this._createDoctypeToken(String.fromCharCode(xr(t))),this.state=T.DOCTYPE_NAME;else switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.NULL:{this._err(N.unexpectedNullCharacter),this._createDoctypeToken(we),this.state=T.DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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=T.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.AFTER_DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.name+=we;break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(Un(t)?xr(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(qe.PUBLIC,!1)?this.state=T.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(qe.SYSTEM,!1)?this.state=T.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(N.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.QUOTATION_MARK:{this._err(N.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(N.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.publicId+=we;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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 b.APOSTROPHE:{this.state=T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.publicId+=we;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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 b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.QUOTATION_MARK:{this._err(N.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(N.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.QUOTATION_MARK:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.QUOTATION_MARK:{this._err(N.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(N.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(N.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.systemId+=we;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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 b.APOSTROPHE:{this.state=T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.NULL:{this._err(N.unexpectedNullCharacter),n.systemId+=we;break}case b.GREATER_THAN_SIGN:{this._err(N.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.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 b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.NULL:{this._err(N.unexpectedNullCharacter);break}case b.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case b.RIGHT_SQUARE_BRACKET:{this.state=T.CDATA_SECTION_BRACKET;break}case b.EOF:{this._err(N.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===b.RIGHT_SQUARE_BRACKET?this.state=T.CDATA_SECTION_END:(this._emitChars("]"),this.state=T.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA;break}case b.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=T.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(b.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&ko(this.preprocessor.peek(1))?T.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){ko(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===b.SEMICOLON&&this._err(N.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const Ec=new Set([c.DD,c.DT,c.LI,c.OPTGROUP,c.OPTION,c.P,c.RB,c.RP,c.RT,c.RTC]),yo=new Set([...Ec,c.CAPTION,c.COLGROUP,c.TBODY,c.TD,c.TFOOT,c.TH,c.THEAD,c.TR]),Kr=new Set([c.APPLET,c.CAPTION,c.HTML,c.MARQUEE,c.OBJECT,c.TABLE,c.TD,c.TEMPLATE,c.TH]),zp=new Set([...Kr,c.OL,c.UL]),$p=new Set([...Kr,c.BUTTON]),wo=new Set([c.ANNOTATION_XML,c.MI,c.MN,c.MO,c.MS,c.MTEXT]),Ao=new Set([c.DESC,c.FOREIGN_OBJECT,c.TITLE]),Yp=new Set([c.TR,c.TEMPLATE,c.HTML]),jp=new Set([c.TBODY,c.TFOOT,c.THEAD,c.TEMPLATE,c.HTML]),Vp=new Set([c.TABLE,c.TEMPLATE,c.HTML]),qp=new Set([c.TD,c.TH]);class Wp{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=c.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===c.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===P.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])!==P.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(fa,P.HTML)}popUntilTableCellPopped(){this.popUntilPopped(qp,P.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(Vp,P.HTML)}clearBackToTableBodyContext(){this.clearBackTo(jp,P.HTML)}clearBackToTableRowContext(){this.clearBackTo(Yp,P.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]===c.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]===c.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 P.HTML:{if(i===t)return!0;if(n.has(i))return!1;break}case P.SVG:{if(Ao.has(i))return!1;break}case P.MATHML:{if(wo.has(i))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Kr)}hasInListItemScope(t){return this.hasInDynamicScope(t,zp)}hasInButtonScope(t){return this.hasInDynamicScope(t,$p)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case P.HTML:{if(fa.has(n))return!0;if(Kr.has(n))return!1;break}case P.SVG:{if(Ao.has(n))return!1;break}case P.MATHML:{if(wo.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===P.HTML)switch(this.tagIDs[n]){case t:return!0;case c.TABLE:case c.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===P.HTML)switch(this.tagIDs[t]){case c.TBODY:case c.THEAD:case c.TFOOT:return!0;case c.TABLE:case c.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===P.HTML)switch(this.tagIDs[n]){case t:return!0;case c.OPTION:case c.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&Ec.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&yo.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&yo.has(this.currentTagId);)this.pop()}}const Bi=3;var ft;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(ft||(ft={}));const Co={type:ft.Marker};class Gp{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===ft.Marker)break;const{element:l}=u;if(this.treeAdapter.getTagName(l)===a&&this.treeAdapter.getNamespaceURI(l)===s){const h=this.treeAdapter.getAttrList(l);h.length===i&&r.push({idx:o,attrs:h})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<Bi)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<Bi)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>=Bi&&this.entries.splice(o.idx,1))}}insertMarker(){this.entries.unshift(Co)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:ft.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:ft.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(Co);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===ft.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===ft.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===ft.Element&&n.element===t)}}const Lt={createDocument(){return{nodeName:"#document",mode:it.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}}},Tc="html",Qp="about:legacy-compat",Kp="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",_c=["+//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//"],Xp=[..._c,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],Zp=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),kc=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],Jp=[...kc,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function So(e,t){return t.some(n=>e.startsWith(n))}function e1(e){return e.name===Tc&&e.publicId===null&&(e.systemId===null||e.systemId===Qp)}function t1(e){if(e.name!==Tc)return it.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===Kp)return it.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),Zp.has(n))return it.QUIRKS;let r=t===null?Xp:_c;if(So(n,r))return it.QUIRKS;if(r=t===null?kc:Jp,So(n,r))return it.LIMITED_QUIRKS}return it.NO_QUIRKS}const vo={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},n1="definitionurl",r1="definitionURL",i1=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])),a1=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:P.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:P.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:P.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:P.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:P.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:P.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:P.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:P.XML}],["xml:space",{prefix:"xml",name:"space",namespace:P.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:P.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:P.XMLNS}]]),s1=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])),o1=new Set([c.B,c.BIG,c.BLOCKQUOTE,c.BODY,c.BR,c.CENTER,c.CODE,c.DD,c.DIV,c.DL,c.DT,c.EM,c.EMBED,c.H1,c.H2,c.H3,c.H4,c.H5,c.H6,c.HEAD,c.HR,c.I,c.IMG,c.LI,c.LISTING,c.MENU,c.META,c.NOBR,c.OL,c.P,c.PRE,c.RUBY,c.S,c.SMALL,c.SPAN,c.STRONG,c.STRIKE,c.SUB,c.SUP,c.TABLE,c.TT,c.U,c.UL,c.VAR]);function u1(e){const t=e.tagID;return t===c.FONT&&e.attrs.some(({name:r})=>r===Kt.COLOR||r===Kt.SIZE||r===Kt.FACE)||o1.has(t)}function xc(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===n1){e.attrs[t].name=r1;break}}function yc(e){for(let t=0;t<e.attrs.length;t++){const n=i1.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function Za(e){for(let t=0;t<e.attrs.length;t++){const n=a1.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 l1(e){const t=s1.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=Cn(e.tagName))}function c1(e,t){return t===P.MATHML&&(e===c.MI||e===c.MO||e===c.MN||e===c.MS||e===c.MTEXT)}function d1(e,t,n){if(t===P.MATHML&&e===c.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Kt.ENCODING){const i=n[r].value.toLowerCase();return i===vo.TEXT_HTML||i===vo.APPLICATION_XML}}return t===P.SVG&&(e===c.FOREIGN_OBJECT||e===c.DESC||e===c.TITLE)}function h1(e,t,n,r){return(!r||r===P.HTML)&&d1(e,t,n)||(!r||r===P.MATHML)&&c1(e,t)}const f1="hidden",p1=8,m1=3;var y;(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"})(y||(y={}));const g1={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},wc=new Set([c.TABLE,c.TBODY,c.TFOOT,c.THEAD,c.TR]),Io={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Lt,onParseError:null};class No{constructor(t,n,r=null,i=null){this.fragmentContext=r,this.scriptHandler=i,this.currentToken=null,this.stopped=!1,this.insertionMode=y.INITIAL,this.originalInsertionMode=y.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={...Io,...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 Up(this.options,this),this.activeFormattingElements=new Gp(this.treeAdapter),this.fragmentContextID=r?Cn(this.treeAdapter.getTagName(r)):c.UNKNOWN,this._setContextModes(r??this.document,this.fragmentContextID),this.openElements=new Wp(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={...Io,...n};t??(t=r.treeAdapter.createElement(I.TEMPLATE,P.HTML,[]));const i=r.treeAdapter.createElement("documentmock",P.HTML,[]),a=new this(r,i,t);return a.fragmentContextID===c.TEMPLATE&&a.tmplInsertionModeStack.unshift(y.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:g1,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)===P.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,P.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=y.TEXT}switchToPlaintextParsing(){this.insertionMode=y.TEXT,this.originalInsertionMode=y.IN_BODY,this.tokenizer.state=Le.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)===I.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==P.HTML))switch(this.fragmentContextID){case c.TITLE:case c.TEXTAREA:{this.tokenizer.state=Le.RCDATA;break}case c.STYLE:case c.XMP:case c.IFRAME:case c.NOEMBED:case c.NOFRAMES:case c.NOSCRIPT:{this.tokenizer.state=Le.RAWTEXT;break}case c.SCRIPT:{this.tokenizer.state=Le.SCRIPT_DATA;break}case c.PLAINTEXT:{this.tokenizer.state=Le.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,P.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,P.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(I.HTML,P.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,c.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:l,endOffset:h}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(s,{endLine:u,endCol:l,endOffset:h})}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===ae.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===c.SVG&&this.treeAdapter.getTagName(n)===I.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===P.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===c.MGLYPH||t.tagID===c.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,P.HTML)}_processToken(t){switch(t.type){case ae.CHARACTER:{this.onCharacter(t);break}case ae.NULL_CHARACTER:{this.onNullCharacter(t);break}case ae.COMMENT:{this.onComment(t);break}case ae.DOCTYPE:{this.onDoctype(t);break}case ae.START_TAG:{this._processStartTag(t);break}case ae.END_TAG:{this.onEndTag(t);break}case ae.EOF:{this.onEof(t);break}case ae.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return h1(t,i,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===ft.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=y.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(c.P),this.openElements.popUntilTagNamePopped(c.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case c.TR:{this.insertionMode=y.IN_ROW;return}case c.TBODY:case c.THEAD:case c.TFOOT:{this.insertionMode=y.IN_TABLE_BODY;return}case c.CAPTION:{this.insertionMode=y.IN_CAPTION;return}case c.COLGROUP:{this.insertionMode=y.IN_COLUMN_GROUP;return}case c.TABLE:{this.insertionMode=y.IN_TABLE;return}case c.BODY:{this.insertionMode=y.IN_BODY;return}case c.FRAMESET:{this.insertionMode=y.IN_FRAMESET;return}case c.SELECT:{this._resetInsertionModeForSelect(t);return}case c.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case c.HTML:{this.insertionMode=this.headElement?y.AFTER_HEAD:y.BEFORE_HEAD;return}case c.TD:case c.TH:{if(t>0){this.insertionMode=y.IN_CELL;return}break}case c.HEAD:{if(t>0){this.insertionMode=y.IN_HEAD;return}break}}this.insertionMode=y.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===c.TEMPLATE)break;if(r===c.TABLE){this.insertionMode=y.IN_SELECT_IN_TABLE;return}}this.insertionMode=y.IN_SELECT}_isElementCausesFosterParenting(t){return wc.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 c.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===P.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case c.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 Mp[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){qm(this,t);return}switch(this.insertionMode){case y.INITIAL:{On(this,t);break}case y.BEFORE_HTML:{Wn(this,t);break}case y.BEFORE_HEAD:{Gn(this,t);break}case y.IN_HEAD:{Qn(this,t);break}case y.IN_HEAD_NO_SCRIPT:{Kn(this,t);break}case y.AFTER_HEAD:{Xn(this,t);break}case y.IN_BODY:case y.IN_CAPTION:case y.IN_CELL:case y.IN_TEMPLATE:{Cc(this,t);break}case y.TEXT:case y.IN_SELECT:case y.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case y.IN_TABLE:case y.IN_TABLE_BODY:case y.IN_ROW:{Fi(this,t);break}case y.IN_TABLE_TEXT:{Rc(this,t);break}case y.IN_COLUMN_GROUP:{Xr(this,t);break}case y.AFTER_BODY:{Zr(this,t);break}case y.AFTER_AFTER_BODY:{Br(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Vm(this,t);return}switch(this.insertionMode){case y.INITIAL:{On(this,t);break}case y.BEFORE_HTML:{Wn(this,t);break}case y.BEFORE_HEAD:{Gn(this,t);break}case y.IN_HEAD:{Qn(this,t);break}case y.IN_HEAD_NO_SCRIPT:{Kn(this,t);break}case y.AFTER_HEAD:{Xn(this,t);break}case y.TEXT:{this._insertCharacters(t);break}case y.IN_TABLE:case y.IN_TABLE_BODY:case y.IN_ROW:{Fi(this,t);break}case y.IN_COLUMN_GROUP:{Xr(this,t);break}case y.AFTER_BODY:{Zr(this,t);break}case y.AFTER_AFTER_BODY:{Br(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){pa(this,t);return}switch(this.insertionMode){case y.INITIAL:case y.BEFORE_HTML:case y.BEFORE_HEAD:case y.IN_HEAD:case y.IN_HEAD_NO_SCRIPT:case y.AFTER_HEAD:case y.IN_BODY:case y.IN_TABLE:case y.IN_CAPTION:case y.IN_COLUMN_GROUP:case y.IN_TABLE_BODY:case y.IN_ROW:case y.IN_CELL:case y.IN_SELECT:case y.IN_SELECT_IN_TABLE:case y.IN_TEMPLATE:case y.IN_FRAMESET:case y.AFTER_FRAMESET:{pa(this,t);break}case y.IN_TABLE_TEXT:{Dn(this,t);break}case y.AFTER_BODY:{y1(this,t);break}case y.AFTER_AFTER_BODY:case y.AFTER_AFTER_FRAMESET:{w1(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case y.INITIAL:{A1(this,t);break}case y.BEFORE_HEAD:case y.IN_HEAD:case y.IN_HEAD_NO_SCRIPT:case y.AFTER_HEAD:{this._err(t,N.misplacedDoctype);break}case y.IN_TABLE_TEXT:{Dn(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,N.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?Wm(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case y.INITIAL:{On(this,t);break}case y.BEFORE_HTML:{C1(this,t);break}case y.BEFORE_HEAD:{v1(this,t);break}case y.IN_HEAD:{ct(this,t);break}case y.IN_HEAD_NO_SCRIPT:{L1(this,t);break}case y.AFTER_HEAD:{O1(this,t);break}case y.IN_BODY:{He(this,t);break}case y.IN_TABLE:{Tn(this,t);break}case y.IN_TABLE_TEXT:{Dn(this,t);break}case y.IN_CAPTION:{Im(this,t);break}case y.IN_COLUMN_GROUP:{ts(this,t);break}case y.IN_TABLE_BODY:{Ti(this,t);break}case y.IN_ROW:{_i(this,t);break}case y.IN_CELL:{Rm(this,t);break}case y.IN_SELECT:{Pc(this,t);break}case y.IN_SELECT_IN_TABLE:{Dm(this,t);break}case y.IN_TEMPLATE:{Mm(this,t);break}case y.AFTER_BODY:{Fm(this,t);break}case y.IN_FRAMESET:{Hm(this,t);break}case y.AFTER_FRAMESET:{zm(this,t);break}case y.AFTER_AFTER_BODY:{Ym(this,t);break}case y.AFTER_AFTER_FRAMESET:{jm(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?Gm(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case y.INITIAL:{On(this,t);break}case y.BEFORE_HTML:{S1(this,t);break}case y.BEFORE_HEAD:{I1(this,t);break}case y.IN_HEAD:{N1(this,t);break}case y.IN_HEAD_NO_SCRIPT:{R1(this,t);break}case y.AFTER_HEAD:{D1(this,t);break}case y.IN_BODY:{Ei(this,t);break}case y.TEXT:{Tm(this,t);break}case y.IN_TABLE:{ar(this,t);break}case y.IN_TABLE_TEXT:{Dn(this,t);break}case y.IN_CAPTION:{Nm(this,t);break}case y.IN_COLUMN_GROUP:{Lm(this,t);break}case y.IN_TABLE_BODY:{ma(this,t);break}case y.IN_ROW:{Dc(this,t);break}case y.IN_CELL:{Om(this,t);break}case y.IN_SELECT:{Mc(this,t);break}case y.IN_SELECT_IN_TABLE:{Pm(this,t);break}case y.IN_TEMPLATE:{Bm(this,t);break}case y.AFTER_BODY:{Fc(this,t);break}case y.IN_FRAMESET:{Um(this,t);break}case y.AFTER_FRAMESET:{$m(this,t);break}case y.AFTER_AFTER_BODY:{Br(this,t);break}}}onEof(t){switch(this.insertionMode){case y.INITIAL:{On(this,t);break}case y.BEFORE_HTML:{Wn(this,t);break}case y.BEFORE_HEAD:{Gn(this,t);break}case y.IN_HEAD:{Qn(this,t);break}case y.IN_HEAD_NO_SCRIPT:{Kn(this,t);break}case y.AFTER_HEAD:{Xn(this,t);break}case y.IN_BODY:case y.IN_TABLE:case y.IN_CAPTION:case y.IN_COLUMN_GROUP:case y.IN_TABLE_BODY:case y.IN_ROW:case y.IN_CELL:case y.IN_SELECT:case y.IN_SELECT_IN_TABLE:{Nc(this,t);break}case y.TEXT:{_m(this,t);break}case y.IN_TABLE_TEXT:{Dn(this,t);break}case y.IN_TEMPLATE:{Bc(this,t);break}case y.AFTER_BODY:case y.IN_FRAMESET:case y.AFTER_FRAMESET:case y.AFTER_AFTER_BODY:case y.AFTER_AFTER_FRAMESET:{es(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===b.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 y.IN_HEAD:case y.IN_HEAD_NO_SCRIPT:case y.AFTER_HEAD:case y.TEXT:case y.IN_COLUMN_GROUP:case y.IN_SELECT:case y.IN_SELECT_IN_TABLE:case y.IN_FRAMESET:case y.AFTER_FRAMESET:{this._insertCharacters(t);break}case y.IN_BODY:case y.IN_CAPTION:case y.IN_CELL:case y.IN_TEMPLATE:case y.AFTER_BODY:case y.AFTER_AFTER_BODY:case y.AFTER_AFTER_FRAMESET:{Ac(this,t);break}case y.IN_TABLE:case y.IN_TABLE_BODY:case y.IN_ROW:{Fi(this,t);break}case y.IN_TABLE_TEXT:{Lc(this,t);break}}}}function b1(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):Ic(e,t),n}function E1(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 T1(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>=m1;!o||u?(u&&e.activeFormattingElements.removeEntry(o),e.openElements.remove(s)):(s=_1(e,o),r===t&&(e.activeFormattingElements.bookmark=o),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(s,r),r=s)}return r}function _1(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 k1(e,t,n){const r=e.treeAdapter.getTagName(t),i=Cn(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);i===c.TEMPLATE&&a===P.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function x1(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 Ja(e,t){for(let n=0;n<p1;n++){const r=b1(e,t);if(!r)break;const i=E1(e,r);if(!i)break;e.activeFormattingElements.bookmark=r;const a=T1(e,i,r.element),s=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),s&&k1(e,s,a),x1(e,i,r)}}function pa(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function y1(e,t){e._appendCommentNode(t,e.openElements.items[0])}function w1(e,t){e._appendCommentNode(t,e.document)}function es(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 A1(e,t){e._setDocumentType(t);const n=t.forceQuirks?it.QUIRKS:t1(t);e1(t)||e._err(t,N.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=y.BEFORE_HTML}function On(e,t){e._err(t,N.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,it.QUIRKS),e.insertionMode=y.BEFORE_HTML,e._processToken(t)}function C1(e,t){t.tagID===c.HTML?(e._insertElement(t,P.HTML),e.insertionMode=y.BEFORE_HEAD):Wn(e,t)}function S1(e,t){const n=t.tagID;(n===c.HTML||n===c.HEAD||n===c.BODY||n===c.BR)&&Wn(e,t)}function Wn(e,t){e._insertFakeRootElement(),e.insertionMode=y.BEFORE_HEAD,e._processToken(t)}function v1(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.HEAD:{e._insertElement(t,P.HTML),e.headElement=e.openElements.current,e.insertionMode=y.IN_HEAD;break}default:Gn(e,t)}}function I1(e,t){const n=t.tagID;n===c.HEAD||n===c.BODY||n===c.HTML||n===c.BR?Gn(e,t):e._err(t,N.endTagWithoutMatchingOpenElement)}function Gn(e,t){e._insertFakeElement(I.HEAD,c.HEAD),e.headElement=e.openElements.current,e.insertionMode=y.IN_HEAD,e._processToken(t)}function ct(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.BASE:case c.BASEFONT:case c.BGSOUND:case c.LINK:case c.META:{e._appendElement(t,P.HTML),t.ackSelfClosing=!0;break}case c.TITLE:{e._switchToTextParsing(t,Le.RCDATA);break}case c.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,Le.RAWTEXT):(e._insertElement(t,P.HTML),e.insertionMode=y.IN_HEAD_NO_SCRIPT);break}case c.NOFRAMES:case c.STYLE:{e._switchToTextParsing(t,Le.RAWTEXT);break}case c.SCRIPT:{e._switchToTextParsing(t,Le.SCRIPT_DATA);break}case c.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=y.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(y.IN_TEMPLATE);break}case c.HEAD:{e._err(t,N.misplacedStartTagForHeadElement);break}default:Qn(e,t)}}function N1(e,t){switch(t.tagID){case c.HEAD:{e.openElements.pop(),e.insertionMode=y.AFTER_HEAD;break}case c.BODY:case c.BR:case c.HTML:{Qn(e,t);break}case c.TEMPLATE:{nn(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function nn(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==c.TEMPLATE&&e._err(t,N.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(c.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,N.endTagWithoutMatchingOpenElement)}function Qn(e,t){e.openElements.pop(),e.insertionMode=y.AFTER_HEAD,e._processToken(t)}function L1(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.BASEFONT:case c.BGSOUND:case c.HEAD:case c.LINK:case c.META:case c.NOFRAMES:case c.STYLE:{ct(e,t);break}case c.NOSCRIPT:{e._err(t,N.nestedNoscriptInHead);break}default:Kn(e,t)}}function R1(e,t){switch(t.tagID){case c.NOSCRIPT:{e.openElements.pop(),e.insertionMode=y.IN_HEAD;break}case c.BR:{Kn(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function Kn(e,t){const n=t.type===ae.EOF?N.openElementsLeftAfterEof:N.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=y.IN_HEAD,e._processToken(t)}function O1(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.BODY:{e._insertElement(t,P.HTML),e.framesetOk=!1,e.insertionMode=y.IN_BODY;break}case c.FRAMESET:{e._insertElement(t,P.HTML),e.insertionMode=y.IN_FRAMESET;break}case c.BASE:case c.BASEFONT:case c.BGSOUND:case c.LINK:case c.META:case c.NOFRAMES:case c.SCRIPT:case c.STYLE:case c.TEMPLATE:case c.TITLE:{e._err(t,N.abandonedHeadElementChild),e.openElements.push(e.headElement,c.HEAD),ct(e,t),e.openElements.remove(e.headElement);break}case c.HEAD:{e._err(t,N.misplacedStartTagForHeadElement);break}default:Xn(e,t)}}function D1(e,t){switch(t.tagID){case c.BODY:case c.HTML:case c.BR:{Xn(e,t);break}case c.TEMPLATE:{nn(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function Xn(e,t){e._insertFakeElement(I.BODY,c.BODY),e.insertionMode=y.IN_BODY,bi(e,t)}function bi(e,t){switch(t.type){case ae.CHARACTER:{Cc(e,t);break}case ae.WHITESPACE_CHARACTER:{Ac(e,t);break}case ae.COMMENT:{pa(e,t);break}case ae.START_TAG:{He(e,t);break}case ae.END_TAG:{Ei(e,t);break}case ae.EOF:{Nc(e,t);break}}}function Ac(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function Cc(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function P1(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function M1(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function B1(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,P.HTML),e.insertionMode=y.IN_FRAMESET)}function F1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,P.HTML)}function H1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&fa.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,P.HTML)}function U1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,P.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function z1(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,P.HTML),n||(e.formElement=e.openElements.current))}function $1(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===c.LI&&i===c.LI||(n===c.DD||n===c.DT)&&(i===c.DD||i===c.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==c.ADDRESS&&i!==c.DIV&&i!==c.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,P.HTML)}function Y1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,P.HTML),e.tokenizer.state=Le.PLAINTEXT}function j1(e,t){e.openElements.hasInScope(c.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(c.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,P.HTML),e.framesetOk=!1}function V1(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(I.A);n&&(Ja(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,P.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function q1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,P.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function W1(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(c.NOBR)&&(Ja(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,P.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function G1(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,P.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function Q1(e,t){e.treeAdapter.getDocumentMode(e.document)!==it.QUIRKS&&e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,P.HTML),e.framesetOk=!1,e.insertionMode=y.IN_TABLE}function Sc(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,P.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function vc(e){const t=gc(e,Kt.TYPE);return t!=null&&t.toLowerCase()===f1}function K1(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,P.HTML),vc(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function X1(e,t){e._appendElement(t,P.HTML),t.ackSelfClosing=!0}function Z1(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._appendElement(t,P.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function J1(e,t){t.tagName=I.IMG,t.tagID=c.IMG,Sc(e,t)}function em(e,t){e._insertElement(t,P.HTML),e.skipNextNewLine=!0,e.tokenizer.state=Le.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=y.TEXT}function tm(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,Le.RAWTEXT)}function nm(e,t){e.framesetOk=!1,e._switchToTextParsing(t,Le.RAWTEXT)}function Lo(e,t){e._switchToTextParsing(t,Le.RAWTEXT)}function rm(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,P.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===y.IN_TABLE||e.insertionMode===y.IN_CAPTION||e.insertionMode===y.IN_TABLE_BODY||e.insertionMode===y.IN_ROW||e.insertionMode===y.IN_CELL?y.IN_SELECT_IN_TABLE:y.IN_SELECT}function im(e,t){e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,P.HTML)}function am(e,t){e.openElements.hasInScope(c.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,P.HTML)}function sm(e,t){e.openElements.hasInScope(c.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(c.RTC),e._insertElement(t,P.HTML)}function om(e,t){e._reconstructActiveFormattingElements(),xc(t),Za(t),t.selfClosing?e._appendElement(t,P.MATHML):e._insertElement(t,P.MATHML),t.ackSelfClosing=!0}function um(e,t){e._reconstructActiveFormattingElements(),yc(t),Za(t),t.selfClosing?e._appendElement(t,P.SVG):e._insertElement(t,P.SVG),t.ackSelfClosing=!0}function Ro(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,P.HTML)}function He(e,t){switch(t.tagID){case c.I:case c.S:case c.B:case c.U:case c.EM:case c.TT:case c.BIG:case c.CODE:case c.FONT:case c.SMALL:case c.STRIKE:case c.STRONG:{q1(e,t);break}case c.A:{V1(e,t);break}case c.H1:case c.H2:case c.H3:case c.H4:case c.H5:case c.H6:{H1(e,t);break}case c.P:case c.DL:case c.OL:case c.UL:case c.DIV:case c.DIR:case c.NAV:case c.MAIN:case c.MENU:case c.ASIDE:case c.CENTER:case c.FIGURE:case c.FOOTER:case c.HEADER:case c.HGROUP:case c.DIALOG:case c.DETAILS:case c.ADDRESS:case c.ARTICLE:case c.SEARCH:case c.SECTION:case c.SUMMARY:case c.FIELDSET:case c.BLOCKQUOTE:case c.FIGCAPTION:{F1(e,t);break}case c.LI:case c.DD:case c.DT:{$1(e,t);break}case c.BR:case c.IMG:case c.WBR:case c.AREA:case c.EMBED:case c.KEYGEN:{Sc(e,t);break}case c.HR:{Z1(e,t);break}case c.RB:case c.RTC:{am(e,t);break}case c.RT:case c.RP:{sm(e,t);break}case c.PRE:case c.LISTING:{U1(e,t);break}case c.XMP:{tm(e,t);break}case c.SVG:{um(e,t);break}case c.HTML:{P1(e,t);break}case c.BASE:case c.LINK:case c.META:case c.STYLE:case c.TITLE:case c.SCRIPT:case c.BGSOUND:case c.BASEFONT:case c.TEMPLATE:{ct(e,t);break}case c.BODY:{M1(e,t);break}case c.FORM:{z1(e,t);break}case c.NOBR:{W1(e,t);break}case c.MATH:{om(e,t);break}case c.TABLE:{Q1(e,t);break}case c.INPUT:{K1(e,t);break}case c.PARAM:case c.TRACK:case c.SOURCE:{X1(e,t);break}case c.IMAGE:{J1(e,t);break}case c.BUTTON:{j1(e,t);break}case c.APPLET:case c.OBJECT:case c.MARQUEE:{G1(e,t);break}case c.IFRAME:{nm(e,t);break}case c.SELECT:{rm(e,t);break}case c.OPTION:case c.OPTGROUP:{im(e,t);break}case c.NOEMBED:case c.NOFRAMES:{Lo(e,t);break}case c.FRAMESET:{B1(e,t);break}case c.TEXTAREA:{em(e,t);break}case c.NOSCRIPT:{e.options.scriptingEnabled?Lo(e,t):Ro(e,t);break}case c.PLAINTEXT:{Y1(e,t);break}case c.COL:case c.TH:case c.TD:case c.TR:case c.HEAD:case c.FRAME:case c.TBODY:case c.TFOOT:case c.THEAD:case c.CAPTION:case c.COLGROUP:break;default:Ro(e,t)}}function lm(e,t){if(e.openElements.hasInScope(c.BODY)&&(e.insertionMode=y.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function cm(e,t){e.openElements.hasInScope(c.BODY)&&(e.insertionMode=y.AFTER_BODY,Fc(e,t))}function dm(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function hm(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(c.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(c.FORM):n&&e.openElements.remove(n))}function fm(e){e.openElements.hasInButtonScope(c.P)||e._insertFakeElement(I.P,c.P),e._closePElement()}function pm(e){e.openElements.hasInListItemScope(c.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(c.LI),e.openElements.popUntilTagNamePopped(c.LI))}function mm(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function gm(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function bm(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function Em(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(I.BR,c.BR),e.openElements.pop(),e.framesetOk=!1}function Ic(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!==c.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 Ei(e,t){switch(t.tagID){case c.A:case c.B:case c.I:case c.S:case c.U:case c.EM:case c.TT:case c.BIG:case c.CODE:case c.FONT:case c.NOBR:case c.SMALL:case c.STRIKE:case c.STRONG:{Ja(e,t);break}case c.P:{fm(e);break}case c.DL:case c.UL:case c.OL:case c.DIR:case c.DIV:case c.NAV:case c.PRE:case c.MAIN:case c.MENU:case c.ASIDE:case c.BUTTON:case c.CENTER:case c.FIGURE:case c.FOOTER:case c.HEADER:case c.HGROUP:case c.DIALOG:case c.ADDRESS:case c.ARTICLE:case c.DETAILS:case c.SEARCH:case c.SECTION:case c.SUMMARY:case c.LISTING:case c.FIELDSET:case c.BLOCKQUOTE:case c.FIGCAPTION:{dm(e,t);break}case c.LI:{pm(e);break}case c.DD:case c.DT:{mm(e,t);break}case c.H1:case c.H2:case c.H3:case c.H4:case c.H5:case c.H6:{gm(e);break}case c.BR:{Em(e);break}case c.BODY:{lm(e,t);break}case c.HTML:{cm(e,t);break}case c.FORM:{hm(e);break}case c.APPLET:case c.OBJECT:case c.MARQUEE:{bm(e,t);break}case c.TEMPLATE:{nn(e,t);break}default:Ic(e,t)}}function Nc(e,t){e.tmplInsertionModeStack.length>0?Bc(e,t):es(e,t)}function Tm(e,t){var n;t.tagID===c.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function _m(e,t){e._err(t,N.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Fi(e,t){if(e.openElements.currentTagId!==void 0&&wc.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=y.IN_TABLE_TEXT,t.type){case ae.CHARACTER:{Rc(e,t);break}case ae.WHITESPACE_CHARACTER:{Lc(e,t);break}}else pr(e,t)}function km(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,P.HTML),e.insertionMode=y.IN_CAPTION}function xm(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,P.HTML),e.insertionMode=y.IN_COLUMN_GROUP}function ym(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(I.COLGROUP,c.COLGROUP),e.insertionMode=y.IN_COLUMN_GROUP,ts(e,t)}function wm(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,P.HTML),e.insertionMode=y.IN_TABLE_BODY}function Am(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(I.TBODY,c.TBODY),e.insertionMode=y.IN_TABLE_BODY,Ti(e,t)}function Cm(e,t){e.openElements.hasInTableScope(c.TABLE)&&(e.openElements.popUntilTagNamePopped(c.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function Sm(e,t){vc(t)?e._appendElement(t,P.HTML):pr(e,t),t.ackSelfClosing=!0}function vm(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,P.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Tn(e,t){switch(t.tagID){case c.TD:case c.TH:case c.TR:{Am(e,t);break}case c.STYLE:case c.SCRIPT:case c.TEMPLATE:{ct(e,t);break}case c.COL:{ym(e,t);break}case c.FORM:{vm(e,t);break}case c.TABLE:{Cm(e,t);break}case c.TBODY:case c.TFOOT:case c.THEAD:{wm(e,t);break}case c.INPUT:{Sm(e,t);break}case c.CAPTION:{km(e,t);break}case c.COLGROUP:{xm(e,t);break}default:pr(e,t)}}function ar(e,t){switch(t.tagID){case c.TABLE:{e.openElements.hasInTableScope(c.TABLE)&&(e.openElements.popUntilTagNamePopped(c.TABLE),e._resetInsertionMode());break}case c.TEMPLATE:{nn(e,t);break}case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:case c.TBODY:case c.TD:case c.TFOOT:case c.TH:case c.THEAD:case c.TR:break;default:pr(e,t)}}function pr(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,bi(e,t),e.fosterParentingEnabled=n}function Lc(e,t){e.pendingCharacterTokens.push(t)}function Rc(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Dn(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)pr(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const Oc=new Set([c.CAPTION,c.COL,c.COLGROUP,c.TBODY,c.TD,c.TFOOT,c.TH,c.THEAD,c.TR]);function Im(e,t){const n=t.tagID;Oc.has(n)?e.openElements.hasInTableScope(c.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(c.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=y.IN_TABLE,Tn(e,t)):He(e,t)}function Nm(e,t){const n=t.tagID;switch(n){case c.CAPTION:case c.TABLE:{e.openElements.hasInTableScope(c.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(c.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=y.IN_TABLE,n===c.TABLE&&ar(e,t));break}case c.BODY:case c.COL:case c.COLGROUP:case c.HTML:case c.TBODY:case c.TD:case c.TFOOT:case c.TH:case c.THEAD:case c.TR:break;default:Ei(e,t)}}function ts(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.COL:{e._appendElement(t,P.HTML),t.ackSelfClosing=!0;break}case c.TEMPLATE:{ct(e,t);break}default:Xr(e,t)}}function Lm(e,t){switch(t.tagID){case c.COLGROUP:{e.openElements.currentTagId===c.COLGROUP&&(e.openElements.pop(),e.insertionMode=y.IN_TABLE);break}case c.TEMPLATE:{nn(e,t);break}case c.COL:break;default:Xr(e,t)}}function Xr(e,t){e.openElements.currentTagId===c.COLGROUP&&(e.openElements.pop(),e.insertionMode=y.IN_TABLE,e._processToken(t))}function Ti(e,t){switch(t.tagID){case c.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,P.HTML),e.insertionMode=y.IN_ROW;break}case c.TH:case c.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(I.TR,c.TR),e.insertionMode=y.IN_ROW,_i(e,t);break}case c.CAPTION:case c.COL:case c.COLGROUP:case c.TBODY:case c.TFOOT:case c.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE,Tn(e,t));break}default:Tn(e,t)}}function ma(e,t){const n=t.tagID;switch(t.tagID){case c.TBODY:case c.TFOOT:case c.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE);break}case c.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE,ar(e,t));break}case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:case c.TD:case c.TH:case c.TR:break;default:ar(e,t)}}function _i(e,t){switch(t.tagID){case c.TH:case c.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,P.HTML),e.insertionMode=y.IN_CELL,e.activeFormattingElements.insertMarker();break}case c.CAPTION:case c.COL:case c.COLGROUP:case c.TBODY:case c.TFOOT:case c.THEAD:case c.TR:{e.openElements.hasInTableScope(c.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE_BODY,Ti(e,t));break}default:Tn(e,t)}}function Dc(e,t){switch(t.tagID){case c.TR:{e.openElements.hasInTableScope(c.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE_BODY);break}case c.TABLE:{e.openElements.hasInTableScope(c.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE_BODY,ma(e,t));break}case c.TBODY:case c.TFOOT:case c.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(c.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=y.IN_TABLE_BODY,ma(e,t));break}case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:case c.TD:case c.TH:break;default:ar(e,t)}}function Rm(e,t){const n=t.tagID;Oc.has(n)?(e.openElements.hasInTableScope(c.TD)||e.openElements.hasInTableScope(c.TH))&&(e._closeTableCell(),_i(e,t)):He(e,t)}function Om(e,t){const n=t.tagID;switch(n){case c.TD:case c.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=y.IN_ROW);break}case c.TABLE:case c.TBODY:case c.TFOOT:case c.THEAD:case c.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),Dc(e,t));break}case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:break;default:Ei(e,t)}}function Pc(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.OPTION:{e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e._insertElement(t,P.HTML);break}case c.OPTGROUP:{e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e.openElements.currentTagId===c.OPTGROUP&&e.openElements.pop(),e._insertElement(t,P.HTML);break}case c.HR:{e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e.openElements.currentTagId===c.OPTGROUP&&e.openElements.pop(),e._appendElement(t,P.HTML),t.ackSelfClosing=!0;break}case c.INPUT:case c.KEYGEN:case c.TEXTAREA:case c.SELECT:{e.openElements.hasInSelectScope(c.SELECT)&&(e.openElements.popUntilTagNamePopped(c.SELECT),e._resetInsertionMode(),t.tagID!==c.SELECT&&e._processStartTag(t));break}case c.SCRIPT:case c.TEMPLATE:{ct(e,t);break}}}function Mc(e,t){switch(t.tagID){case c.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===c.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===c.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===c.OPTGROUP&&e.openElements.pop();break}case c.OPTION:{e.openElements.currentTagId===c.OPTION&&e.openElements.pop();break}case c.SELECT:{e.openElements.hasInSelectScope(c.SELECT)&&(e.openElements.popUntilTagNamePopped(c.SELECT),e._resetInsertionMode());break}case c.TEMPLATE:{nn(e,t);break}}}function Dm(e,t){const n=t.tagID;n===c.CAPTION||n===c.TABLE||n===c.TBODY||n===c.TFOOT||n===c.THEAD||n===c.TR||n===c.TD||n===c.TH?(e.openElements.popUntilTagNamePopped(c.SELECT),e._resetInsertionMode(),e._processStartTag(t)):Pc(e,t)}function Pm(e,t){const n=t.tagID;n===c.CAPTION||n===c.TABLE||n===c.TBODY||n===c.TFOOT||n===c.THEAD||n===c.TR||n===c.TD||n===c.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(c.SELECT),e._resetInsertionMode(),e.onEndTag(t)):Mc(e,t)}function Mm(e,t){switch(t.tagID){case c.BASE:case c.BASEFONT:case c.BGSOUND:case c.LINK:case c.META:case c.NOFRAMES:case c.SCRIPT:case c.STYLE:case c.TEMPLATE:case c.TITLE:{ct(e,t);break}case c.CAPTION:case c.COLGROUP:case c.TBODY:case c.TFOOT:case c.THEAD:{e.tmplInsertionModeStack[0]=y.IN_TABLE,e.insertionMode=y.IN_TABLE,Tn(e,t);break}case c.COL:{e.tmplInsertionModeStack[0]=y.IN_COLUMN_GROUP,e.insertionMode=y.IN_COLUMN_GROUP,ts(e,t);break}case c.TR:{e.tmplInsertionModeStack[0]=y.IN_TABLE_BODY,e.insertionMode=y.IN_TABLE_BODY,Ti(e,t);break}case c.TD:case c.TH:{e.tmplInsertionModeStack[0]=y.IN_ROW,e.insertionMode=y.IN_ROW,_i(e,t);break}default:e.tmplInsertionModeStack[0]=y.IN_BODY,e.insertionMode=y.IN_BODY,He(e,t)}}function Bm(e,t){t.tagID===c.TEMPLATE&&nn(e,t)}function Bc(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(c.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):es(e,t)}function Fm(e,t){t.tagID===c.HTML?He(e,t):Zr(e,t)}function Fc(e,t){var n;if(t.tagID===c.HTML){if(e.fragmentContext||(e.insertionMode=y.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===c.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 Zr(e,t)}function Zr(e,t){e.insertionMode=y.IN_BODY,bi(e,t)}function Hm(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.FRAMESET:{e._insertElement(t,P.HTML);break}case c.FRAME:{e._appendElement(t,P.HTML),t.ackSelfClosing=!0;break}case c.NOFRAMES:{ct(e,t);break}}}function Um(e,t){t.tagID===c.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==c.FRAMESET&&(e.insertionMode=y.AFTER_FRAMESET))}function zm(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.NOFRAMES:{ct(e,t);break}}}function $m(e,t){t.tagID===c.HTML&&(e.insertionMode=y.AFTER_AFTER_FRAMESET)}function Ym(e,t){t.tagID===c.HTML?He(e,t):Br(e,t)}function Br(e,t){e.insertionMode=y.IN_BODY,bi(e,t)}function jm(e,t){switch(t.tagID){case c.HTML:{He(e,t);break}case c.NOFRAMES:{ct(e,t);break}}}function Vm(e,t){t.chars=we,e._insertCharacters(t)}function qm(e,t){e._insertCharacters(t),e.framesetOk=!1}function Hc(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==P.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function Wm(e,t){if(u1(t))Hc(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===P.MATHML?xc(t):r===P.SVG&&(l1(t),yc(t)),Za(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function Gm(e,t){if(t.tagID===c.P||t.tagID===c.BR){Hc(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)===P.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 ki=Uc("end"),Et=Uc("start");function Uc(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 zc(e){const t=Et(e),n=ki(e);if(t&&n)return{start:t,end:n}}const Qm=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,Km=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),Oo={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function $c(e,t){const n=sg(e),r=dc("type",{handlers:{root:Xm,element:Zm,text:Jm,comment:jc,doctype:eg,raw:ng},unknown:rg}),i={parser:n?new No(Oo):No.getFragmentParser(void 0,Oo),handle(o){r(o,i)},stitches:!1,options:t||{}};r(e,i),Sn(i,Et());const a=n?i.parser.document:i.parser.getFragment(),s=op(a,{file:i.options.file});return i.stitches&&Mt(s,"comment",function(o,u,l){const h=o;if(h.value.stitch&&l&&u!==void 0){const d=l.children;return d[u]=h.value.stitch,u}}),s.type==="root"&&s.children.length===1&&s.children[0].type===e.type?s.children[0]:s}function Yc(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function Xm(e,t){Yc(e.children,t)}function Zm(e,t){ig(e,t),Yc(e.children,t),ag(e,t)}function Jm(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:ae.CHARACTER,chars:e.value,location:mr(e)};Sn(t,Et(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function eg(e,t){const n={type:ae.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:mr(e)};Sn(t,Et(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function tg(e,t){t.stitches=!0;const n=og(e);if("children"in e&&"children"in n){const r=$c({type:"root",children:e.children},t.options);n.children=r.children}jc({type:"comment",value:{stitch:n}},t)}function jc(e,t){const n=e.value,r={type:ae.COMMENT,data:n,location:mr(e)};Sn(t,Et(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function ng(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,Vc(t,Et(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(Qm,"<$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 rg(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))tg(n,t);else{let r="";throw Km.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 Sn(e,t){Vc(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=Le.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 Vc(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 ig(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===Le.PLAINTEXT)return;Sn(t,Et(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=hp({...e,children:[]},{space:i===Qt.svg?"svg":"html"}),s={type:ae.START_TAG,tagName:n,tagID:Cn(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:mr(e)};t.parser.currentToken=s,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function ag(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&_p.includes(n)||t.parser.tokenizer.state===Le.PLAINTEXT)return;Sn(t,ki(e));const r={type:ae.END_TAG,tagName:n,tagID:Cn(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:mr(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===Le.RCDATA||t.parser.tokenizer.state===Le.RAWTEXT||t.parser.tokenizer.state===Le.SCRIPT_DATA)&&(t.parser.tokenizer.state=Le.DATA)}function sg(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function mr(e){const t=Et(e)||{line:void 0,column:void 0,offset:void 0},n=ki(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 og(e){return"children"in e?Zt({...e,children:[]}):Zt(e)}function ga(e){return function(t,n){return $c(t,{...e,file:n})}}const Yt=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],Zn={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Yt,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Yt],h2:[["className","sr-only"]],img:[...Yt,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Yt,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Yt],table:[...Yt],ul:[...Yt,["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 ug(e,t){let n={type:"root",children:[]};const r={schema:t?{...Zn,...t}:Zn,stack:[]},i=qc(r,e);return i&&(Array.isArray(i)?i.length===1?n=i[0]:n.children=i:n=i),n}function qc(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return lg(e,n);case"doctype":return cg(e,n);case"element":return dg(e,n);case"root":return hg(e,n);case"text":return fg(e,n)}}}function lg(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 gr(a,t),a}}function cg(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return gr(n,t),n}}function dg(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=Wc(e,t.children),i=pg(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 gr(s,t),s}function hg(e,t){const r={type:"root",children:Wc(e,t.children)};return gr(r,t),r}function fg(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return gr(r,t),r}function Wc(e,t){const n=[];if(Array.isArray(t)){const r=t;let i=-1;for(;++i<r.length;){const a=qc(e,r[i]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function pg(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 l;for(l in o)if(Rt.call(o,l)){const h=o[l];let d=Do(e,Po(a,l),l,h);d==null&&(d=Do(e,Po(s,l),l,h)),d!=null&&(u[l]=d)}if(i&&Rt.call(i,n)){const h=i[n];for(l in h)Rt.call(h,l)&&!Rt.call(u,l)&&(u[l]=h[l])}return u}function Do(e,t,n,r){return t?Array.isArray(r)?mg(e,t,n,r):Gc(e,t,n,r):void 0}function mg(e,t,n,r){let i=-1;const a=[];for(;++i<r.length;){const s=Gc(e,t,n,r[i]);(typeof s=="number"||typeof s=="string")&&a.push(s)}return a}function Gc(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&gg(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 gg(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 l=-1;for(;++l<r.length;){const h=r[l];if(a===h.length&&i.slice(0,h.length)===h)return!0}return!1}function gr(e,t){const n=zc(t);t.data&&(e.data=Zt(t.data)),n&&(e.position=n)}function Po(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 Qc(e){return function(t){return ug(t,e)}}function Mo(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=Ut(/[A-Za-z]/),Fe=Ut(/[\dA-Za-z]/),bg=Ut(/[#-'*+\--9=?A-Z^-~]/);function Jr(e){return e!==null&&(e<32||e===127)}const ba=Ut(/\d/),Eg=Ut(/[\dA-Fa-f]/),Tg=Ut(/[!-/:-@[-`{-~]/);function X(e){return e!==null&&e<-2}function ke(e){return e!==null&&(e<0||e===32)}function se(e){return e===-2||e===-1||e===32}const xi=Ut(/\p{P}|\p{S}/u),Jt=Ut(/\s/);function Ut(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function _g(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function kg(e,t,n){const i=fi((n||{}).ignore||[]),a=xg(t);let s=-1;for(;++s<a.length;)ja(e,"text",o);function o(l,h){let d=-1,p;for(;++d<h.length;){const f=h[d],m=p?p.children:void 0;if(i(f,m?m.indexOf(f):void 0,p))return;p=f}if(p)return u(l,h)}function u(l,h){const d=h[h.length-1],p=a[s][0],f=a[s][1];let m=0;const x=d.children.indexOf(l);let k=!1,v=[];p.lastIndex=0;let C=p.exec(l.value);for(;C;){const R=C.index,F={index:C.index,input:C.input,stack:[...h,l]};let S=f(...C,F);if(typeof S=="string"&&(S=S.length>0?{type:"text",value:S}:void 0),S===!1?p.lastIndex=R+1:(m!==R&&v.push({type:"text",value:l.value.slice(m,R)}),Array.isArray(S)?v.push(...S):S&&v.push(S),m=R+C[0].length,k=!0),!p.global)break;C=p.exec(l.value)}return k?(m<l.value.length&&v.push({type:"text",value:l.value.slice(m)}),d.children.splice(x,1,...v)):v=[l],x+v.length}}function xg(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([yg(i[0]),wg(i[1])])}return t}function yg(e){return typeof e=="string"?new RegExp(_g(e),"g"):e}function wg(e){return typeof e=="function"?e:function(){return e}}const Hi="phrasing",Ui=["autolink","link","image","label"];function Ag(){return{transforms:[Rg],enter:{literalAutolink:Sg,literalAutolinkEmail:zi,literalAutolinkHttp:zi,literalAutolinkWww:zi},exit:{literalAutolink:Lg,literalAutolinkEmail:Ng,literalAutolinkHttp:vg,literalAutolinkWww:Ig}}}function Cg(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Hi,notInConstruct:Ui},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Hi,notInConstruct:Ui},{character:":",before:"[ps]",after:"\\/",inConstruct:Hi,notInConstruct:Ui}]}}function Sg(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function zi(e){this.config.enter.autolinkProtocol.call(this,e)}function vg(e){this.config.exit.autolinkProtocol.call(this,e)}function Ig(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.url="http://"+this.sliceSerialize(e)}function Ng(e){this.config.exit.autolinkEmail.call(this,e)}function Lg(e){this.exit(e)}function Rg(e){kg(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Og],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),Dg]],{ignore:["link","linkReference"]})}function Og(e,t,n,r,i){let a="";if(!Kc(i)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!Pg(n)))return!1;const s=Mg(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 Dg(e,t,n,r){return!Kc(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function Pg(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 Mg(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=Mo(e,"(");let a=Mo(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 Kc(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Jt(n)||xi(n))&&(!t||n!==47)}function lt(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}Xc.peek=Vg;function Bg(){this.buffer()}function Fg(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function Hg(){this.buffer()}function Ug(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function zg(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.identifier=lt(this.sliceSerialize(e)).toLowerCase(),n.label=t}function $g(e){this.exit(e)}function Yg(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.identifier=lt(this.sliceSerialize(e)).toLowerCase(),n.label=t}function jg(e){this.exit(e)}function Vg(){return"["}function Xc(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 qg(){return{enter:{gfmFootnoteCallString:Bg,gfmFootnoteCall:Fg,gfmFootnoteDefinitionLabelString:Hg,gfmFootnoteDefinition:Ug},exit:{gfmFootnoteCallString:zg,gfmFootnoteCall:$g,gfmFootnoteDefinitionLabelString:Yg,gfmFootnoteDefinition:jg}}}function Wg(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:Xc},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,i,a,s){const o=a.createTracker(s);let u=o.move("[^");const l=a.enter("footnoteDefinition"),h=a.enter("label");return u+=o.move(a.safe(a.associationId(r),{before:u,after:"]"})),h(),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?Zc:Gg))),l(),u}}function Gg(e,t,n){return t===0?e:Zc(e,t,n)}function Zc(e,t,n){return(n?"":" ")+e}const Qg=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];Jc.peek=eb;function Kg(){return{canContainEols:["delete"],enter:{strikethrough:Zg},exit:{strikethrough:Jg}}}function Xg(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:Qg}],handlers:{delete:Jc}}}function Zg(e){this.enter({type:"delete",children:[]},e)}function Jg(e){this.exit(e)}function Jc(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 eb(){return"~"}function tb(e){return e.length}function nb(e,t){const n=t||{},r=(n.align||[]).concat(),i=n.stringLength||tb,a=[],s=[],o=[],u=[];let l=0,h=-1;for(;++h<e.length;){const _=[],x=[];let k=-1;for(e[h].length>l&&(l=e[h].length);++k<e[h].length;){const v=rb(e[h][k]);if(n.alignDelimiters!==!1){const C=i(v);x[k]=C,(u[k]===void 0||C>u[k])&&(u[k]=C)}_.push(v)}s[h]=_,o[h]=x}let d=-1;if(typeof r=="object"&&"length"in r)for(;++d<l;)a[d]=Bo(r[d]);else{const _=Bo(r);for(;++d<l;)a[d]=_}d=-1;const p=[],f=[];for(;++d<l;){const _=a[d];let x="",k="";_===99?(x=":",k=":"):_===108?x=":":_===114&&(k=":");let v=n.alignDelimiters===!1?1:Math.max(1,u[d]-x.length-k.length);const C=x+"-".repeat(v)+k;n.alignDelimiters!==!1&&(v=x.length+v+k.length,v>u[d]&&(u[d]=v),f[d]=v),p[d]=C}s.splice(1,0,p),o.splice(1,0,f),h=-1;const m=[];for(;++h<s.length;){const _=s[h],x=o[h];d=-1;const k=[];for(;++d<l;){const v=_[d]||"";let C="",R="";if(n.alignDelimiters!==!1){const F=u[d]-(x[d]||0),S=a[d];S===114?C=" ".repeat(F):S===99?F%2?(C=" ".repeat(F/2+.5),R=" ".repeat(F/2-.5)):(C=" ".repeat(F/2),R=C):R=" ".repeat(F)}n.delimiterStart!==!1&&!d&&k.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&v==="")&&(n.delimiterStart!==!1||d)&&k.push(" "),n.alignDelimiters!==!1&&k.push(C),k.push(v),n.alignDelimiters!==!1&&k.push(R),n.padding!==!1&&k.push(" "),(n.delimiterEnd!==!1||d!==l-1)&&k.push("|")}m.push(n.delimiterEnd===!1?k.join("").replace(/ +$/,""):k.join(""))}return m.join(`
|
|
4
|
+
`)}function rb(e){return e==null?"":String(e)}function Bo(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 ib(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()),ab);return i(),s}function ab(e,t,n){return">"+(n?"":" ")+e}function sb(e,t){return Fo(e,t.inConstruct,!0)&&!Fo(e,t.notInConstruct,!1)}function Fo(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 Ho(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
|
|
5
|
+
`&&sb(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?"":" ";return`\\
|
|
6
|
+
`}function ob(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 ub(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 lb(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 cb(e,t,n,r){const i=lb(n),a=e.value||"",s=i==="`"?"GraveAccent":"Tilde";if(ub(e,n)){const d=n.enter("codeIndented"),p=n.indentLines(a,db);return d(),p}const o=n.createTracker(r),u=i.repeat(Math.max(ob(a,i)+1,3)),l=n.enter("codeFenced");let h=o.move(u);if(e.lang){const d=n.enter(`codeFencedLang${s}`);h+=o.move(n.safe(e.lang,{before:h,after:" ",encode:["`"],...o.current()})),d()}if(e.lang&&e.meta){const d=n.enter(`codeFencedMeta${s}`);h+=o.move(" "),h+=o.move(n.safe(e.meta,{before:h,after:`
|
|
7
7
|
`,encode:["`"],...o.current()})),d()}return h+=o.move(`
|
|
8
8
|
`),a&&(h+=o.move(a+`
|
|
9
|
-
`)),h+=o.move(u),l(),h}function
|
|
10
|
-
`,...u.current()}))),o(),e.title&&(o=n.enter(`title${a}`),l+=u.move(" "+i),l+=u.move(n.safe(e.title,{before:l,after:i,...u.current()})),l+=u.move(i),o()),s(),l}function
|
|
9
|
+
`)),h+=o.move(u),l(),h}function db(e,t,n){return(n?"":" ")+e}function ns(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 hb(e,t,n,r){const i=ns(n),a=i==='"'?"Quote":"Apostrophe",s=n.enter("definition");let o=n.enter("label");const u=n.createTracker(r);let l=u.move("[");return l+=u.move(n.safe(n.associationId(e),{before:l,after:"]",...u.current()})),l+=u.move("]: "),o(),!e.url||/[\0- \u007F]/.test(e.url)?(o=n.enter("destinationLiteral"),l+=u.move("<"),l+=u.move(n.safe(e.url,{before:l,after:">",...u.current()})),l+=u.move(">")):(o=n.enter("destinationRaw"),l+=u.move(n.safe(e.url,{before:l,after:e.title?" ":`
|
|
10
|
+
`,...u.current()}))),o(),e.title&&(o=n.enter(`title${a}`),l+=u.move(" "+i),l+=u.move(n.safe(e.title,{before:l,after:i,...u.current()})),l+=u.move(i),o()),s(),l}function fb(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 sr(e){return"&#x"+e.toString(16).toUpperCase()+";"}function _n(e){if(e===null||ke(e)||Jt(e))return 1;if(xi(e))return 2}function ei(e,t,n){const r=_n(e),i=_n(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}}ed.peek=pb;function ed(e,t,n,r){const i=fb(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 l=u.charCodeAt(0),h=ei(r.before.charCodeAt(r.before.length-1),l,i);h.inside&&(u=sr(l)+u.slice(1));const d=u.charCodeAt(u.length-1),p=ei(r.after.charCodeAt(0),d,i);p.inside&&(u=u.slice(0,-1)+sr(d));const f=s.move(i);return a(),n.attentionEncodeSurroundingInfo={after:p.outside,before:h.outside},o+u+f}function pb(e,t,n){return n.options.emphasis||"*"}const mb={};function rs(e,t){const n=t||mb,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,i=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return td(e,r,i)}function td(e,t,n){if(gb(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 Uo(e.children,t,n)}return Array.isArray(e)?Uo(e,t,n):""}function Uo(e,t,n){const r=[];let i=-1;for(;++i<e.length;)r[i]=td(e[i],t,n);return r.join("")}function gb(e){return!!(e&&typeof e=="object")}function bb(e,t){let n=!1;return Mt(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,ua}),!!((!e.depth||e.depth<3)&&rs(e)&&(t.options.setext||n))}function Eb(e,t,n,r){const i=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(bb(e,n)){const h=n.enter("headingSetext"),d=n.enter("phrasing"),p=n.containerPhrasing(e,{...a.current(),before:`
|
|
11
11
|
`,after:`
|
|
12
12
|
`});return d(),h(),p+`
|
|
13
13
|
`+(i===1?"=":"-").repeat(p.length-(Math.max(p.lastIndexOf("\r"),p.lastIndexOf(`
|
|
14
14
|
`))+1))}const s="#".repeat(i),o=n.enter("headingAtx"),u=n.enter("phrasing");a.move(s+" ");let l=n.containerPhrasing(e,{before:"# ",after:`
|
|
15
|
-
`,...a.current()});return/^[\t ]/.test(l)&&(l=sr(l.charCodeAt(0))+l.slice(1)),l=l?s+" "+l:s,n.options.closeAtx&&(l+=" "+s),u(),o(),l}
|
|
15
|
+
`,...a.current()});return/^[\t ]/.test(l)&&(l=sr(l.charCodeAt(0))+l.slice(1)),l=l?s+" "+l:s,n.options.closeAtx&&(l+=" "+s),u(),o(),l}nd.peek=Tb;function nd(e){return e.value||""}function Tb(){return"<"}rd.peek=_b;function rd(e,t,n,r){const i=ns(n),a=i==='"'?"Quote":"Apostrophe",s=n.enter("image");let o=n.enter("label");const u=n.createTracker(r);let l=u.move("![");return l+=u.move(n.safe(e.alt,{before:l,after:"]",...u.current()})),l+=u.move("]("),o(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(o=n.enter("destinationLiteral"),l+=u.move("<"),l+=u.move(n.safe(e.url,{before:l,after:">",...u.current()})),l+=u.move(">")):(o=n.enter("destinationRaw"),l+=u.move(n.safe(e.url,{before:l,after:e.title?" ":")",...u.current()}))),o(),e.title&&(o=n.enter(`title${a}`),l+=u.move(" "+i),l+=u.move(n.safe(e.title,{before:l,after:i,...u.current()})),l+=u.move(i),o()),l+=u.move(")"),s(),l}function _b(){return"!"}id.peek=kb;function id(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 l=n.safe(e.alt,{before:u,after:"]",...o.current()});u+=o.move(l+"]["),s();const h=n.stack;n.stack=[],s=n.enter("reference");const d=n.safe(n.associationId(e),{before:u,after:"]",...o.current()});return s(),n.stack=h,a(),i==="full"||!l||l!==d?u+=o.move(d+"]"):i==="shortcut"?u=u.slice(0,-1):u+=o.move("]"),u}function kb(){return"!"}ad.peek=xb;function ad(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 l=u.index;r.charCodeAt(l)===10&&r.charCodeAt(l-1)===13&&l--,r=r.slice(0,l)+" "+r.slice(u.index+1)}}return i+r+i}function xb(){return"`"}function sd(e,t){const n=rs(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))}od.peek=yb;function od(e,t,n,r){const i=ns(n),a=i==='"'?"Quote":"Apostrophe",s=n.createTracker(r);let o,u;if(sd(e,n)){const h=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=h,d}o=n.enter("link"),u=n.enter("label");let l=s.move("[");return l+=s.move(n.containerPhrasing(e,{before:l,after:"](",...s.current()})),l+=s.move("]("),u(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(u=n.enter("destinationLiteral"),l+=s.move("<"),l+=s.move(n.safe(e.url,{before:l,after:">",...s.current()})),l+=s.move(">")):(u=n.enter("destinationRaw"),l+=s.move(n.safe(e.url,{before:l,after:e.title?" ":")",...s.current()}))),u(),e.title&&(u=n.enter(`title${a}`),l+=s.move(" "+i),l+=s.move(n.safe(e.title,{before:l,after:i,...s.current()})),l+=s.move(i),u()),l+=s.move(")"),o(),l}function yb(e,t,n){return sd(e,n)?"<":"["}ud.peek=wb;function ud(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 l=n.containerPhrasing(e,{before:u,after:"]",...o.current()});u+=o.move(l+"]["),s();const h=n.stack;n.stack=[],s=n.enter("reference");const d=n.safe(n.associationId(e),{before:u,after:"]",...o.current()});return s(),n.stack=h,a(),i==="full"||!l||l!==d?u+=o.move(d+"]"):i==="shortcut"?u=u.slice(0,-1):u+=o.move("]"),u}function wb(){return"["}function is(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 Ab(e){const t=is(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 Cb(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 ld(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 Sb(e,t,n,r){const i=n.enter("list"),a=n.bulletCurrent;let s=e.ordered?Cb(n):is(n);const o=e.ordered?s==="."?")":".":Ab(n);let u=t&&n.bulletLastUsed?s===n.bulletLastUsed:!1;if(!e.ordered){const h=e.children?e.children[0]:void 0;if((s==="*"||s==="-")&&h&&(!h.children||!h.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),ld(n)===s&&h){let d=-1;for(;++d<e.children.length;){const p=e.children[d];if(p&&p.type==="listItem"&&p.children&&p.children[0]&&p.children[0].type==="thematicBreak"){u=!0;break}}}}u&&(s=o),n.bulletCurrent=s;const l=n.containerFlow(e,r);return n.bulletLastUsed=s,n.bulletCurrent=a,i(),l}function vb(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 Ib(e,t,n,r){const i=vb(n);let a=n.bulletCurrent||is(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"),l=n.indentLines(n.containerFlow(e,o.current()),h);return u(),l;function h(d,p,f){return p?(f?"":" ".repeat(s))+d:(f?a:a+" ".repeat(s-a.length))+d}}function Nb(e,t,n,r){const i=n.enter("paragraph"),a=n.enter("phrasing"),s=n.containerPhrasing(e,r);return a(),i(),s}const Lb=fi(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function Rb(e,t,n,r){return(e.children.some(function(s){return Lb(s)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function Ob(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}cd.peek=Db;function cd(e,t,n,r){const i=Ob(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 l=u.charCodeAt(0),h=ei(r.before.charCodeAt(r.before.length-1),l,i);h.inside&&(u=sr(l)+u.slice(1));const d=u.charCodeAt(u.length-1),p=ei(r.after.charCodeAt(0),d,i);p.inside&&(u=u.slice(0,-1)+sr(d));const f=s.move(i+i);return a(),n.attentionEncodeSurroundingInfo={after:p.outside,before:h.outside},o+u+f}function Db(e,t,n){return n.options.strong||"*"}function Pb(e,t,n,r){return n.safe(e.value,r)}function Mb(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 Bb(e,t,n){const r=(ld(n)+(n.options.ruleSpaces?" ":"")).repeat(Mb(n));return n.options.ruleSpaces?r.slice(0,-1):r}const dd={blockquote:ib,break:Ho,code:cb,definition:hb,emphasis:ed,hardBreak:Ho,heading:Eb,html:nd,image:rd,imageReference:id,inlineCode:ad,link:od,linkReference:ud,list:Sb,listItem:Ib,paragraph:Nb,root:Rb,strong:cd,text:Pb,thematicBreak:Bb},zo=document.createElement("i");function as(e){const t="&"+e+";";zo.innerHTML=t;const n=zo.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function hd(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 Fb=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Hb(e){return e.replace(Fb,Ub)}function Ub(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const i=n.charCodeAt(1),a=i===120||i===88;return hd(n.slice(a?2:1),a?16:10)}return as(n)||e}function zb(){return{enter:{table:$b,tableData:$o,tableHeader:$o,tableRow:jb},exit:{codeText:Vb,table:Yb,tableData:$i,tableHeader:$i,tableRow:$i}}}function $b(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 Yb(e){this.exit(e),this.data.inTable=void 0}function jb(e){this.enter({type:"tableRow",children:[]},e)}function $i(e){this.exit(e)}function $o(e){this.enter({type:"tableCell",children:[]},e)}function Vb(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,qb));const n=this.stack[this.stack.length-1];n.value=t,this.exit(e)}function qb(e,t){return t==="|"?t:e}function Wb(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,i=t.stringLength,a=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
|
|
16
16
|
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:p,table:s,tableCell:u,tableRow:o}};function s(f,m,_,x){return l(h(f,_,x),f.align)}function o(f,m,_,x){const k=d(f,_,x),v=l([k]);return v.slice(0,v.indexOf(`
|
|
17
|
-
`))}function u(f,m,_,x){const k=_.enter("tableCell"),v=_.enter("phrasing"),C=_.containerPhrasing(f,{...x,before:a,after:a});return v(),k(),C}function l(f,m){return Gg(f,{align:m,alignDelimiters:r,padding:n,stringLength:i})}function h(f,m,_){const x=f.children;let k=-1;const v=[],C=m.enter("table");for(;++k<x.length;)v[k]=d(x[k],m,_);return C(),v}function d(f,m,_){const x=f.children;let k=-1;const v=[],C=m.enter("tableRow");for(;++k<x.length;)v[k]=u(x[k],f,m,_);return C(),v}function p(f,m,_){let x=ld.inlineCode(f,m,_);return _.stack.includes("tableCell")&&(x=x.replace(/\|/g,"\\$&")),x}}function Ub(){return{exit:{taskListCheckValueChecked:zo,taskListCheckValueUnchecked:zo,paragraph:$b}}}function zb(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:Yb}}}function zo(e){const t=this.stack[this.stack.length-2];t.checked=e.type==="taskListCheckValueChecked"}function $b(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 Yb(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=ld.listItem(e,t,n,{...r,...o.current()});return a&&(u=u.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,l)),u;function l(h){return h+s}}function jb(){return[bg(),Fg(),$g(),Ob(),Ub()]}function Vb(e){return{extensions:[Eg(),Hg(e),Yg(),Hb(e),zb()]}}function Je(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 at(e,t){return e.length>0?(Je(e,e.length,0,t),e):t}const $o={}.hasOwnProperty;function dd(e){const t={};let n=-1;for(;++n<e.length;)qb(t,e[n]);return t}function qb(e,t){let n;for(n in t){const i=($o.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let s;if(a)for(s in a){$o.call(i,s)||(i[s]=[]);const o=a[s];Wb(i[s],Array.isArray(o)?o:o?[o]:[])}}}function Wb(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);Je(e,0,0,r)}const Gb={tokenize:e2,partial:!0},hd={tokenize:t2,partial:!0},fd={tokenize:n2,partial:!0},pd={tokenize:r2,partial:!0},Qb={tokenize:i2,partial:!0},md={name:"wwwAutolink",tokenize:Zb,previous:bd},gd={name:"protocolAutolink",tokenize:Jb,previous:Ed},Ct={name:"emailAutolink",tokenize:Xb,previous:Td},Tt={};function Kb(){return{text:Tt}}let jt=48;for(;jt<123;)Tt[jt]=Ct,jt++,jt===58?jt=65:jt===91&&(jt=97);Tt[43]=Ct;Tt[45]=Ct;Tt[46]=Ct;Tt[95]=Ct;Tt[72]=[Ct,gd];Tt[104]=[Ct,gd];Tt[87]=[Ct,md];Tt[119]=[Ct,md];function Xb(e,t,n){const r=this;let i,a;return s;function s(d){return!ga(d)||!Td.call(r,r.previous)||is(r.events)?n(d):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),o(d))}function o(d){return ga(d)?(e.consume(d),o):d===64?(e.consume(d),u):n(d)}function u(d){return d===46?e.check(Qb,h,l)(d):d===45||d===95||Be(d)?(a=!0,e.consume(d),u):h(d)}function l(d){return e.consume(d),i=!0,u}function h(d){return a&&i&&$e(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(d)):n(d)}}function Zb(e,t,n){const r=this;return i;function i(s){return s!==87&&s!==119||!bd.call(r,r.previous)||is(r.events)?n(s):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(Gb,e.attempt(hd,e.attempt(fd,a),n),n)(s))}function a(s){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(s)}}function Jb(e,t,n){const r=this;let i="",a=!1;return s;function s(d){return(d===72||d===104)&&Ed.call(r,r.previous)&&!is(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),i+=String.fromCodePoint(d),e.consume(d),o):n(d)}function o(d){if($e(d)&&i.length<5)return i+=String.fromCodePoint(d),e.consume(d),o;if(d===58){const p=i.toLowerCase();if(p==="http"||p==="https")return e.consume(d),u}return n(d)}function u(d){return d===47?(e.consume(d),a?l:(a=!0,u)):n(d)}function l(d){return d===null||Zr(d)||_e(d)||Jt(d)||_i(d)?n(d):e.attempt(hd,e.attempt(fd,h),n)(d)}function h(d){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(d)}}function e2(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 t2(e,t,n){let r,i,a;return s;function s(l){return l===46||l===95?e.check(pd,u,o)(l):l===null||_e(l)||Jt(l)||l!==45&&_i(l)?u(l):(a=!0,e.consume(l),s)}function o(l){return l===95?r=!0:(i=r,r=void 0),e.consume(l),s}function u(l){return i||r||!a?n(l):t(l)}}function n2(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(pd,t,a)(s):s===null||_e(s)||Jt(s)?t(s):(e.consume(s),i)}function a(s){return s===41&&r++,e.consume(s),i}}function r2(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||_e(o)||Jt(o)?t(o):n(o)}function i(o){return o===null||o===40||o===91||_e(o)||Jt(o)?t(o):r(o)}function a(o){return $e(o)?s(o):n(o)}function s(o){return o===59?(e.consume(o),r):$e(o)?(e.consume(o),s):n(o)}}function i2(e,t,n){return r;function r(a){return e.consume(a),i}function i(a){return Be(a)?n(a):t(a)}}function bd(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||_e(e)}function Ed(e){return!$e(e)}function Td(e){return!(e===47||ga(e))}function ga(e){return e===43||e===45||e===46||e===95||Be(e)}function is(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 Sn(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 ki(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 ba={name:"attention",resolveAll:a2,tokenize:s2};function a2(e,t){let n=-1,r,i,a,s,o,u,l,h;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},p={...e[n][1].start};Yo(d,-u),Yo(p,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:p},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},l=[],e[r][1].end.offset-e[r][1].start.offset&&(l=at(l,[["enter",e[r][1],t],["exit",e[r][1],t]])),l=at(l,[["enter",i,t],["enter",s,t],["exit",s,t],["enter",a,t]]),l=at(l,ki(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),l=at(l,[["exit",a,t],["enter",o,t],["exit",o,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(h=2,l=at(l,[["enter",e[n][1],t],["exit",e[n][1],t]])):h=0,Je(e,r-1,n-r+3,l),n=r+l.length-h-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function s2(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 l=e.exit("attentionSequence"),h=Tn(u),d=!h||h===2&&i||n.includes(u),p=!i||i===2&&h||n.includes(r);return l._open=!!(a===42?d:d&&(i||!p)),l._close=!!(a===42?p:p&&(h||!d)),t(u)}}function Yo(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const o2={name:"autolink",tokenize:u2};function u2(e,t,n){let r=0;return i;function i(f){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(f),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(f){return $e(f)?(e.consume(f),s):f===64?n(f):l(f)}function s(f){return f===43||f===45||f===46||Be(f)?(r=1,o(f)):l(f)}function o(f){return f===58?(e.consume(f),r=0,u):(f===43||f===45||f===46||Be(f))&&r++<32?(e.consume(f),o):(r=0,l(f))}function u(f){return f===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(f),e.exit("autolinkMarker"),e.exit("autolink"),t):f===null||f===32||f===60||Zr(f)?n(f):(e.consume(f),u)}function l(f){return f===64?(e.consume(f),h):lg(f)?(e.consume(f),l):n(f)}function h(f){return Be(f)?d(f):n(f)}function d(f){return f===46?(e.consume(f),r=0,h):f===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(f),e.exit("autolinkMarker"),e.exit("autolink"),t):p(f)}function p(f){if((f===45||Be(f))&&r++<63){const m=f===45?p:d;return e.consume(f),m}return n(f)}}function ce(e,t,n,r){const i=r?r-1:Number.POSITIVE_INFINITY;let a=0;return s;function s(u){return se(u)?(e.enter(n),o(u)):t(u)}function o(u){return se(u)&&a++<i?(e.consume(u),o):(e.exit(n),t(u))}}const br={partial:!0,tokenize:l2};function l2(e,t,n){return r;function r(a){return se(a)?ce(e,i,"linePrefix")(a):i(a)}function i(a){return a===null||X(a)?t(a):n(a)}}const _d={continuation:{tokenize:d2},exit:h2,name:"blockQuote",tokenize:c2};function c2(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 se(s)?(e.enter("blockQuotePrefixWhitespace"),e.consume(s),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(s))}}function d2(e,t,n){const r=this;return i;function i(s){return se(s)?ce(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s):a(s)}function a(s){return e.attempt(_d,t,n)(s)}}function h2(e){e.exit("blockQuote")}const kd={name:"characterEscape",tokenize:f2};function f2(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 dg(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const xd={name:"characterReference",tokenize:p2};function p2(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"),l):(e.enter("characterReferenceValue"),a=31,s=Be,h(d))}function l(d){return d===88||d===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(d),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,s=cg,h):(e.enter("characterReferenceValue"),a=7,s=ma,h(d))}function h(d){if(d===59&&i){const p=e.exit("characterReferenceValue");return s===Be&&!rs(r.sliceSerialize(p))?n(d):(e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return s(d)&&i++<a?(e.consume(d),h):n(d)}}const jo={partial:!0,tokenize:g2},Vo={concrete:!0,name:"codeFenced",tokenize:m2};function m2(e,t,n){const r=this,i={partial:!0,tokenize:F};let a=0,s=0,o;return u;function u(S){return l(S)}function l(S){const Y=r.events[r.events.length-1];return a=Y&&Y[1].type==="linePrefix"?Y[2].sliceSerialize(Y[1],!0).length:0,o=S,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),h(S)}function h(S){return S===o?(s++,e.consume(S),h):s<3?n(S):(e.exit("codeFencedFenceSequence"),se(S)?ce(e,d,"whitespace")(S):d(S))}function d(S){return S===null||X(S)?(e.exit("codeFencedFence"),r.interrupt?t(S):e.check(jo,_,R)(S)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),p(S))}function p(S){return S===null||X(S)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),d(S)):se(S)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),ce(e,f,"whitespace")(S)):S===96&&S===o?n(S):(e.consume(S),p)}function f(S){return S===null||X(S)?d(S):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),m(S))}function m(S){return S===null||X(S)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),d(S)):S===96&&S===o?n(S):(e.consume(S),m)}function _(S){return e.attempt(i,R,x)(S)}function x(S){return e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),k}function k(S){return a>0&&se(S)?ce(e,v,"linePrefix",a+1)(S):v(S)}function v(S){return S===null||X(S)?e.check(jo,_,R)(S):(e.enter("codeFlowValue"),C(S))}function C(S){return S===null||X(S)?(e.exit("codeFlowValue"),v(S)):(e.consume(S),C)}function R(S){return e.exit("codeFenced"),t(S)}function F(S,Y,L){let D=0;return A;function A(J){return S.enter("lineEnding"),S.consume(J),S.exit("lineEnding"),z}function z(J){return S.enter("codeFencedFence"),se(J)?ce(S,P,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(J):P(J)}function P(J){return J===o?(S.enter("codeFencedFenceSequence"),Q(J)):L(J)}function Q(J){return J===o?(D++,S.consume(J),Q):D>=s?(S.exit("codeFencedFenceSequence"),se(J)?ce(S,ue,"whitespace")(J):ue(J)):L(J)}function ue(J){return J===null||X(J)?(S.exit("codeFencedFence"),Y(J)):L(J)}}}function g2(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 zi={name:"codeIndented",tokenize:E2},b2={partial:!0,tokenize:T2};function E2(e,t,n){const r=this;return i;function i(l){return e.enter("codeIndented"),ce(e,a,"linePrefix",4+1)(l)}function a(l){const h=r.events[r.events.length-1];return h&&h[1].type==="linePrefix"&&h[2].sliceSerialize(h[1],!0).length>=4?s(l):n(l)}function s(l){return l===null?u(l):X(l)?e.attempt(b2,s,u)(l):(e.enter("codeFlowValue"),o(l))}function o(l){return l===null||X(l)?(e.exit("codeFlowValue"),s(l)):(e.consume(l),o)}function u(l){return e.exit("codeIndented"),t(l)}}function T2(e,t,n){const r=this;return i;function i(s){return r.parser.lazy[r.now().line]?n(s):X(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),i):ce(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):X(s)?i(s):n(s)}}const _2={name:"codeText",previous:x2,resolve:k2,tokenize:y2};function k2(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 x2(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function y2(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,h(d)):X(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),u):(e.enter("codeTextData"),l(d))}function l(d){return d===null||d===32||d===96||X(d)?(e.exit("codeTextData"),u(d)):(e.consume(d),l)}function h(d){return d===96?(e.consume(d),i++,h):i===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(d)):(a.type="codeTextData",l(d))}}class w2{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&&Dn(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),Dn(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Dn(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);Dn(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Dn(this.left,n.reverse())}}}function Dn(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 yd(e){const t={};let n=-1,r,i,a,s,o,u,l;const h=new w2(e);for(;++n<h.length;){for(;n in t;)n=t[n];if(r=h.get(n),n&&r[1].type==="chunkFlow"&&h.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,A2(h,n)),n=t[n],l=!0);else if(r[1]._container){for(a=n,i=void 0;a--;)if(s=h.get(a),s[1].type==="lineEnding"||s[1].type==="lineEndingBlank")s[0]==="enter"&&(i&&(h.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={...h.get(i)[1].start},o=h.slice(i,n),o.unshift(r),h.splice(i,n-i+1,o))}}return Je(e,0,Number.POSITIVE_INFINITY,h.slice(0)),!l}function A2(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=[],l={};let h,d,p=-1,f=n,m=0,_=0;const x=[_];for(;f;){for(;e.get(++i)[1]!==f;);a.push(i),f._tokenizer||(h=r.sliceStream(f),f.next||h.push(null),d&&s.defineSkip(f.start),f._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=!0),s.write(h),f._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=void 0)),d=f,f=f.next}for(f=n;++p<o.length;)o[p][0]==="exit"&&o[p-1][0]==="enter"&&o[p][1].type===o[p-1][1].type&&o[p][1].start.line!==o[p][1].end.line&&(_=p+1,x.push(_),f._tokenizer=void 0,f.previous=void 0,f=f.next);for(s.events=[],f?(f._tokenizer=void 0,f.previous=void 0):x.pop(),p=x.length;p--;){const k=o.slice(x[p],x[p+1]),v=a.pop();u.push([v,v+k.length-1]),e.splice(v,2,k)}for(u.reverse(),p=-1;++p<u.length;)l[m+u[p][0]]=m+u[p][1],m+=u[p][1]-u[p][0]-1;return l}const C2={resolve:v2,tokenize:I2},S2={partial:!0,tokenize:N2};function v2(e){return yd(e),e}function I2(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):X(o)?e.check(S2,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 N2(e,t,n){const r=this;return i;function i(s){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),ce(e,a,"linePrefix")}function a(s){if(s===null||X(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 wd(e,t,n,r,i,a,s,o,u){const l=u||Number.POSITIVE_INFINITY;let h=0;return d;function d(k){return k===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(k),e.exit(a),p):k===null||k===32||k===41||Zr(k)?n(k):(e.enter(r),e.enter(s),e.enter(o),e.enter("chunkString",{contentType:"string"}),_(k))}function p(k){return k===62?(e.enter(a),e.consume(k),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(o),e.enter("chunkString",{contentType:"string"}),f(k))}function f(k){return k===62?(e.exit("chunkString"),e.exit(o),p(k)):k===null||k===60||X(k)?n(k):(e.consume(k),k===92?m:f)}function m(k){return k===60||k===62||k===92?(e.consume(k),f):f(k)}function _(k){return!h&&(k===null||k===41||_e(k))?(e.exit("chunkString"),e.exit(o),e.exit(s),e.exit(r),t(k)):h<l&&k===40?(e.consume(k),h++,_):k===41?(e.consume(k),h--,_):k===null||k===32||k===40||Zr(k)?n(k):(e.consume(k),k===92?x:_)}function x(k){return k===40||k===41||k===92?(e.consume(k),_):_(k)}}function Ad(e,t,n,r,i,a){const s=this;let o=0,u;return l;function l(f){return e.enter(r),e.enter(i),e.consume(f),e.exit(i),e.enter(a),h}function h(f){return o>999||f===null||f===91||f===93&&!u||f===94&&!o&&"_hiddenFootnoteSupport"in s.parser.constructs?n(f):f===93?(e.exit(a),e.enter(i),e.consume(f),e.exit(i),e.exit(r),t):X(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),h):(e.enter("chunkString",{contentType:"string"}),d(f))}function d(f){return f===null||f===91||f===93||X(f)||o++>999?(e.exit("chunkString"),h(f)):(e.consume(f),u||(u=!se(f)),f===92?p:d)}function p(f){return f===91||f===92||f===93?(e.consume(f),o++,d):d(f)}}function Cd(e,t,n,r,i,a){let s;return o;function o(p){return p===34||p===39||p===40?(e.enter(r),e.enter(i),e.consume(p),e.exit(i),s=p===40?41:p,u):n(p)}function u(p){return p===s?(e.enter(i),e.consume(p),e.exit(i),e.exit(r),t):(e.enter(a),l(p))}function l(p){return p===s?(e.exit(a),u(s)):p===null?n(p):X(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),ce(e,l,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),h(p))}function h(p){return p===s||p===null||X(p)?(e.exit("chunkString"),l(p)):(e.consume(p),p===92?d:h)}function d(p){return p===s||p===92?(e.consume(p),h):h(p)}}function Zn(e,t){let n;return r;function r(i){return X(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):se(i)?ce(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}const L2={name:"definition",tokenize:O2},R2={partial:!0,tokenize:D2};function O2(e,t,n){const r=this;let i;return a;function a(f){return e.enter("definition"),s(f)}function s(f){return Ad.call(r,e,o,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(f)}function o(f){return i=lt(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),f===58?(e.enter("definitionMarker"),e.consume(f),e.exit("definitionMarker"),u):n(f)}function u(f){return _e(f)?Zn(e,l)(f):l(f)}function l(f){return wd(e,h,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(f)}function h(f){return e.attempt(R2,d,d)(f)}function d(f){return se(f)?ce(e,p,"whitespace")(f):p(f)}function p(f){return f===null||X(f)?(e.exit("definition"),r.parser.defined.push(i),t(f)):n(f)}}function D2(e,t,n){return r;function r(o){return _e(o)?Zn(e,i)(o):n(o)}function i(o){return Cd(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(o)}function a(o){return se(o)?ce(e,s,"whitespace")(o):s(o)}function s(o){return o===null||X(o)?t(o):n(o)}}const P2={name:"hardBreakEscape",tokenize:M2};function M2(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.consume(a),i}function i(a){return X(a)?(e.exit("hardBreakEscape"),t(a)):n(a)}}const B2={name:"headingAtx",resolve:F2,tokenize:H2};function F2(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"},Je(e,r,n-r+1,[["enter",i,t],["enter",a,t],["exit",a,t],["exit",i,t]])),e}function H2(e,t,n){let r=0;return i;function i(h){return e.enter("atxHeading"),a(h)}function a(h){return e.enter("atxHeadingSequence"),s(h)}function s(h){return h===35&&r++<6?(e.consume(h),s):h===null||_e(h)?(e.exit("atxHeadingSequence"),o(h)):n(h)}function o(h){return h===35?(e.enter("atxHeadingSequence"),u(h)):h===null||X(h)?(e.exit("atxHeading"),t(h)):se(h)?ce(e,o,"whitespace")(h):(e.enter("atxHeadingText"),l(h))}function u(h){return h===35?(e.consume(h),u):(e.exit("atxHeadingSequence"),o(h))}function l(h){return h===null||h===35||_e(h)?(e.exit("atxHeadingText"),o(h)):(e.consume(h),l)}}const U2=["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"],qo=["pre","script","style","textarea"],z2={concrete:!0,name:"htmlFlow",resolveTo:j2,tokenize:V2},$2={partial:!0,tokenize:W2},Y2={partial:!0,tokenize:q2};function j2(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 V2(e,t,n){const r=this;let i,a,s,o,u;return l;function l(w){return h(w)}function h(w){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(w),d}function d(w){return w===33?(e.consume(w),p):w===47?(e.consume(w),a=!0,_):w===63?(e.consume(w),i=3,r.interrupt?t:E):$e(w)?(e.consume(w),s=String.fromCharCode(w),x):n(w)}function p(w){return w===45?(e.consume(w),i=2,f):w===91?(e.consume(w),i=5,o=0,m):$e(w)?(e.consume(w),i=4,r.interrupt?t:E):n(w)}function f(w){return w===45?(e.consume(w),r.interrupt?t:E):n(w)}function m(w){const Se="CDATA[";return w===Se.charCodeAt(o++)?(e.consume(w),o===Se.length?r.interrupt?t:P:m):n(w)}function _(w){return $e(w)?(e.consume(w),s=String.fromCharCode(w),x):n(w)}function x(w){if(w===null||w===47||w===62||_e(w)){const Se=w===47,pe=s.toLowerCase();return!Se&&!a&&qo.includes(pe)?(i=1,r.interrupt?t(w):P(w)):U2.includes(s.toLowerCase())?(i=6,Se?(e.consume(w),k):r.interrupt?t(w):P(w)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(w):a?v(w):C(w))}return w===45||Be(w)?(e.consume(w),s+=String.fromCharCode(w),x):n(w)}function k(w){return w===62?(e.consume(w),r.interrupt?t:P):n(w)}function v(w){return se(w)?(e.consume(w),v):A(w)}function C(w){return w===47?(e.consume(w),A):w===58||w===95||$e(w)?(e.consume(w),R):se(w)?(e.consume(w),C):A(w)}function R(w){return w===45||w===46||w===58||w===95||Be(w)?(e.consume(w),R):F(w)}function F(w){return w===61?(e.consume(w),S):se(w)?(e.consume(w),F):C(w)}function S(w){return w===null||w===60||w===61||w===62||w===96?n(w):w===34||w===39?(e.consume(w),u=w,Y):se(w)?(e.consume(w),S):L(w)}function Y(w){return w===u?(e.consume(w),u=null,D):w===null||X(w)?n(w):(e.consume(w),Y)}function L(w){return w===null||w===34||w===39||w===47||w===60||w===61||w===62||w===96||_e(w)?F(w):(e.consume(w),L)}function D(w){return w===47||w===62||se(w)?C(w):n(w)}function A(w){return w===62?(e.consume(w),z):n(w)}function z(w){return w===null||X(w)?P(w):se(w)?(e.consume(w),z):n(w)}function P(w){return w===45&&i===2?(e.consume(w),oe):w===60&&i===1?(e.consume(w),q):w===62&&i===4?(e.consume(w),he):w===63&&i===3?(e.consume(w),E):w===93&&i===5?(e.consume(w),W):X(w)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check($2,Z,Q)(w)):w===null||X(w)?(e.exit("htmlFlowData"),Q(w)):(e.consume(w),P)}function Q(w){return e.check(Y2,ue,Z)(w)}function ue(w){return e.enter("lineEnding"),e.consume(w),e.exit("lineEnding"),J}function J(w){return w===null||X(w)?Q(w):(e.enter("htmlFlowData"),P(w))}function oe(w){return w===45?(e.consume(w),E):P(w)}function q(w){return w===47?(e.consume(w),s="",K):P(w)}function K(w){if(w===62){const Se=s.toLowerCase();return qo.includes(Se)?(e.consume(w),he):P(w)}return $e(w)&&s.length<8?(e.consume(w),s+=String.fromCharCode(w),K):P(w)}function W(w){return w===93?(e.consume(w),E):P(w)}function E(w){return w===62?(e.consume(w),he):w===45&&i===2?(e.consume(w),E):P(w)}function he(w){return w===null||X(w)?(e.exit("htmlFlowData"),Z(w)):(e.consume(w),he)}function Z(w){return e.exit("htmlFlow"),t(w)}}function q2(e,t,n){const r=this;return i;function i(s){return X(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 W2(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(br,t,n)}}const G2={name:"htmlText",tokenize:Q2};function Q2(e,t,n){const r=this;let i,a,s;return o;function o(E){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(E),u}function u(E){return E===33?(e.consume(E),l):E===47?(e.consume(E),F):E===63?(e.consume(E),C):$e(E)?(e.consume(E),L):n(E)}function l(E){return E===45?(e.consume(E),h):E===91?(e.consume(E),a=0,m):$e(E)?(e.consume(E),v):n(E)}function h(E){return E===45?(e.consume(E),f):n(E)}function d(E){return E===null?n(E):E===45?(e.consume(E),p):X(E)?(s=d,q(E)):(e.consume(E),d)}function p(E){return E===45?(e.consume(E),f):d(E)}function f(E){return E===62?oe(E):E===45?p(E):d(E)}function m(E){const he="CDATA[";return E===he.charCodeAt(a++)?(e.consume(E),a===he.length?_:m):n(E)}function _(E){return E===null?n(E):E===93?(e.consume(E),x):X(E)?(s=_,q(E)):(e.consume(E),_)}function x(E){return E===93?(e.consume(E),k):_(E)}function k(E){return E===62?oe(E):E===93?(e.consume(E),k):_(E)}function v(E){return E===null||E===62?oe(E):X(E)?(s=v,q(E)):(e.consume(E),v)}function C(E){return E===null?n(E):E===63?(e.consume(E),R):X(E)?(s=C,q(E)):(e.consume(E),C)}function R(E){return E===62?oe(E):C(E)}function F(E){return $e(E)?(e.consume(E),S):n(E)}function S(E){return E===45||Be(E)?(e.consume(E),S):Y(E)}function Y(E){return X(E)?(s=Y,q(E)):se(E)?(e.consume(E),Y):oe(E)}function L(E){return E===45||Be(E)?(e.consume(E),L):E===47||E===62||_e(E)?D(E):n(E)}function D(E){return E===47?(e.consume(E),oe):E===58||E===95||$e(E)?(e.consume(E),A):X(E)?(s=D,q(E)):se(E)?(e.consume(E),D):oe(E)}function A(E){return E===45||E===46||E===58||E===95||Be(E)?(e.consume(E),A):z(E)}function z(E){return E===61?(e.consume(E),P):X(E)?(s=z,q(E)):se(E)?(e.consume(E),z):D(E)}function P(E){return E===null||E===60||E===61||E===62||E===96?n(E):E===34||E===39?(e.consume(E),i=E,Q):X(E)?(s=P,q(E)):se(E)?(e.consume(E),P):(e.consume(E),ue)}function Q(E){return E===i?(e.consume(E),i=void 0,J):E===null?n(E):X(E)?(s=Q,q(E)):(e.consume(E),Q)}function ue(E){return E===null||E===34||E===39||E===60||E===61||E===96?n(E):E===47||E===62||_e(E)?D(E):(e.consume(E),ue)}function J(E){return E===47||E===62||_e(E)?D(E):n(E)}function oe(E){return E===62?(e.consume(E),e.exit("htmlTextData"),e.exit("htmlText"),t):n(E)}function q(E){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),K}function K(E){return se(E)?ce(e,W,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(E):W(E)}function W(E){return e.enter("htmlTextData"),s(E)}}const as={name:"labelEnd",resolveAll:J2,resolveTo:eE,tokenize:tE},K2={tokenize:nE},X2={tokenize:rE},Z2={tokenize:iE};function J2(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&&Je(e,0,e.length,n),e}function eE(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}},l={type:"label",start:{...e[a][1].start},end:{...e[s][1].end}},h={type:"labelText",start:{...e[a+r+2][1].end},end:{...e[s-2][1].start}};return o=[["enter",u,t],["enter",l,t]],o=at(o,e.slice(a+1,a+r+3)),o=at(o,[["enter",h,t]]),o=at(o,ki(t.parser.constructs.insideSpan.null,e.slice(a+r+4,s-3),t)),o=at(o,[["exit",h,t],e[s-2],e[s-1],["exit",l,t]]),o=at(o,e.slice(s+1)),o=at(o,[["exit",u,t]]),Je(e,a,e.length,o),e}function tE(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(p){return a?a._inactive?d(p):(s=r.parser.defined.includes(lt(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(p),e.exit("labelMarker"),e.exit("labelEnd"),u):n(p)}function u(p){return p===40?e.attempt(K2,h,s?h:d)(p):p===91?e.attempt(X2,h,s?l:d)(p):s?h(p):d(p)}function l(p){return e.attempt(Z2,h,d)(p)}function h(p){return t(p)}function d(p){return a._balanced=!0,n(p)}}function nE(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 _e(d)?Zn(e,a)(d):a(d)}function a(d){return d===41?h(d):wd(e,s,o,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(d)}function s(d){return _e(d)?Zn(e,u)(d):h(d)}function o(d){return n(d)}function u(d){return d===34||d===39||d===40?Cd(e,l,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(d):h(d)}function l(d){return _e(d)?Zn(e,h)(d):h(d)}function h(d){return d===41?(e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),e.exit("resource"),t):n(d)}}function rE(e,t,n){const r=this;return i;function i(o){return Ad.call(r,e,a,s,"reference","referenceMarker","referenceString")(o)}function a(o){return r.parser.defined.includes(lt(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(o):n(o)}function s(o){return n(o)}}function iE(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 aE={name:"labelStartImage",resolveAll:as.resolveAll,tokenize:sE};function sE(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 oE={name:"labelStartLink",resolveAll:as.resolveAll,tokenize:uE};function uE(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 $i={name:"lineEnding",tokenize:lE};function lE(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),ce(e,t,"linePrefix")}}const Fr={name:"thematicBreak",tokenize:cE};function cE(e,t,n){let r=0,i;return a;function a(l){return e.enter("thematicBreak"),s(l)}function s(l){return i=l,o(l)}function o(l){return l===i?(e.enter("thematicBreakSequence"),u(l)):r>=3&&(l===null||X(l))?(e.exit("thematicBreak"),t(l)):n(l)}function u(l){return l===i?(e.consume(l),r++,u):(e.exit("thematicBreakSequence"),se(l)?ce(e,o,"whitespace")(l):o(l))}}const qe={continuation:{tokenize:pE},exit:gE,name:"list",tokenize:fE},dE={partial:!0,tokenize:bE},hE={partial:!0,tokenize:mE};function fE(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(f){const m=r.containerState.type||(f===42||f===43||f===45?"listUnordered":"listOrdered");if(m==="listUnordered"?!r.containerState.marker||f===r.containerState.marker:ma(f)){if(r.containerState.type||(r.containerState.type=m,e.enter(m,{_container:!0})),m==="listUnordered")return e.enter("listItemPrefix"),f===42||f===45?e.check(Fr,n,l)(f):l(f);if(!r.interrupt||f===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),u(f)}return n(f)}function u(f){return ma(f)&&++s<10?(e.consume(f),u):(!r.interrupt||s<2)&&(r.containerState.marker?f===r.containerState.marker:f===41||f===46)?(e.exit("listItemValue"),l(f)):n(f)}function l(f){return e.enter("listItemMarker"),e.consume(f),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||f,e.check(br,r.interrupt?n:h,e.attempt(dE,p,d))}function h(f){return r.containerState.initialBlankLine=!0,a++,p(f)}function d(f){return se(f)?(e.enter("listItemPrefixWhitespace"),e.consume(f),e.exit("listItemPrefixWhitespace"),p):n(f)}function p(f){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(f)}}function pE(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(br,i,a);function i(o){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,ce(e,t,"listItemIndent",r.containerState.size+1)(o)}function a(o){return r.containerState.furtherBlankLines||!se(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(hE,t,s)(o))}function s(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,ce(e,e.attempt(qe,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o)}}function mE(e,t,n){const r=this;return ce(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 gE(e){e.exit(this.containerState.type)}function bE(e,t,n){const r=this;return ce(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!se(a)&&s&&s[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const Wo={name:"setextUnderline",resolveTo:EE,tokenize:TE};function EE(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 TE(e,t,n){const r=this;let i;return a;function a(l){let h=r.events.length,d;for(;h--;)if(r.events[h][1].type!=="lineEnding"&&r.events[h][1].type!=="linePrefix"&&r.events[h][1].type!=="content"){d=r.events[h][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||d)?(e.enter("setextHeadingLine"),i=l,s(l)):n(l)}function s(l){return e.enter("setextHeadingLineSequence"),o(l)}function o(l){return l===i?(e.consume(l),o):(e.exit("setextHeadingLineSequence"),se(l)?ce(e,u,"lineSuffix")(l):u(l))}function u(l){return l===null||X(l)?(e.exit("setextHeadingLine"),t(l)):n(l)}}const _E={tokenize:vE,partial:!0};function kE(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:AE,continuation:{tokenize:CE},exit:SE}},text:{91:{name:"gfmFootnoteCall",tokenize:wE},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:xE,resolveTo:yE}}}}function xE(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 l=lt(r.sliceSerialize({start:s.end,end:r.now()}));return l.codePointAt(0)!==94||!a.includes(l.slice(1))?n(u):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(u),e.exit("gfmFootnoteCallLabelMarker"),t(u))}}function yE(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 wE(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",l)}function l(d){if(a>999||d===93&&!s||d===null||d===91||_e(d))return n(d);if(d===93){e.exit("chunkString");const p=e.exit("gfmFootnoteCallString");return i.includes(lt(r.sliceSerialize(p)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(d)}return _e(d)||(s=!0),a++,e.consume(d),d===92?h:l}function h(d){return d===91||d===92||d===93?(e.consume(d),a++,l):l(d)}}function AE(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"),l}function l(m){return m===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",h):n(m)}function h(m){if(s>999||m===93&&!o||m===null||m===91||_e(m))return n(m);if(m===93){e.exit("chunkString");const _=e.exit("gfmFootnoteDefinitionLabelString");return a=lt(r.sliceSerialize(_)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),p}return _e(m)||(o=!0),s++,e.consume(m),m===92?d:h}function d(m){return m===91||m===92||m===93?(e.consume(m),s++,h):h(m)}function p(m){return m===58?(e.enter("definitionMarker"),e.consume(m),e.exit("definitionMarker"),i.includes(a)||i.push(a),ce(e,f,"gfmFootnoteDefinitionWhitespace")):n(m)}function f(m){return t(m)}}function CE(e,t,n){return e.check(br,t,e.attempt(_E,t,n))}function SE(e){e.exit("gfmFootnoteDefinition")}function vE(e,t,n){const r=this;return ce(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 IE(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 l=u;for(;l--;)if(s[l][0]==="exit"&&s[l][1].type==="strikethroughSequenceTemporary"&&s[l][1]._open&&s[u][1].end.offset-s[u][1].start.offset===s[l][1].end.offset-s[l][1].start.offset){s[u][1].type="strikethroughSequence",s[l][1].type="strikethroughSequence";const h={type:"strikethrough",start:Object.assign({},s[l][1].start),end:Object.assign({},s[u][1].end)},d={type:"strikethroughText",start:Object.assign({},s[l][1].end),end:Object.assign({},s[u][1].start)},p=[["enter",h,o],["enter",s[l][1],o],["exit",s[l][1],o],["enter",d,o]],f=o.parser.constructs.insideSpan.null;f&&Je(p,p.length,0,ki(f,s.slice(l+1,u),o)),Je(p,p.length,0,[["exit",d,o],["enter",s[u][1],o],["exit",s[u][1],o],["exit",h,o]]),Je(s,l-1,u-l+3,p),u=l+p.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 l=this.previous,h=this.events;let d=0;return p;function p(m){return l===126&&h[h.length-1][1].type!=="characterEscape"?u(m):(s.enter("strikethroughSequenceTemporary"),f(m))}function f(m){const _=Tn(l);if(m===126)return d>1?u(m):(s.consume(m),d++,f);if(d<2&&!n)return u(m);const x=s.exit("strikethroughSequenceTemporary"),k=Tn(m);return x._open=!k||k===2&&!!_,x._close=!_||_===2&&!!k,o(m)}}}class NE{constructor(){this.map=[]}add(t,n,r){LE(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 LE(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 RE(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 OE(){return{flow:{null:{name:"table",tokenize:DE,resolveAll:PE}}}}function DE(e,t,n){const r=this;let i=0,a=0,s;return o;function o(A){let z=r.events.length-1;for(;z>-1;){const ue=r.events[z][1].type;if(ue==="lineEnding"||ue==="linePrefix")z--;else break}const P=z>-1?r.events[z][1].type:null,Q=P==="tableHead"||P==="tableRow"?S:u;return Q===S&&r.parser.lazy[r.now().line]?n(A):Q(A)}function u(A){return e.enter("tableHead"),e.enter("tableRow"),l(A)}function l(A){return A===124||(s=!0,a+=1),h(A)}function h(A){return A===null?n(A):X(A)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(A),e.exit("lineEnding"),f):n(A):se(A)?ce(e,h,"whitespace")(A):(a+=1,s&&(s=!1,i+=1),A===124?(e.enter("tableCellDivider"),e.consume(A),e.exit("tableCellDivider"),s=!0,h):(e.enter("data"),d(A)))}function d(A){return A===null||A===124||_e(A)?(e.exit("data"),h(A)):(e.consume(A),A===92?p:d)}function p(A){return A===92||A===124?(e.consume(A),d):d(A)}function f(A){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(A):(e.enter("tableDelimiterRow"),s=!1,se(A)?ce(e,m,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(A):m(A))}function m(A){return A===45||A===58?x(A):A===124?(s=!0,e.enter("tableCellDivider"),e.consume(A),e.exit("tableCellDivider"),_):F(A)}function _(A){return se(A)?ce(e,x,"whitespace")(A):x(A)}function x(A){return A===58?(a+=1,s=!0,e.enter("tableDelimiterMarker"),e.consume(A),e.exit("tableDelimiterMarker"),k):A===45?(a+=1,k(A)):A===null||X(A)?R(A):F(A)}function k(A){return A===45?(e.enter("tableDelimiterFiller"),v(A)):F(A)}function v(A){return A===45?(e.consume(A),v):A===58?(s=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(A),e.exit("tableDelimiterMarker"),C):(e.exit("tableDelimiterFiller"),C(A))}function C(A){return se(A)?ce(e,R,"whitespace")(A):R(A)}function R(A){return A===124?m(A):A===null||X(A)?!s||i!==a?F(A):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(A)):F(A)}function F(A){return n(A)}function S(A){return e.enter("tableRow"),Y(A)}function Y(A){return A===124?(e.enter("tableCellDivider"),e.consume(A),e.exit("tableCellDivider"),Y):A===null||X(A)?(e.exit("tableRow"),t(A)):se(A)?ce(e,Y,"whitespace")(A):(e.enter("data"),L(A))}function L(A){return A===null||A===124||_e(A)?(e.exit("data"),Y(A)):(e.consume(A),A===92?D:L)}function D(A){return A===92||A===124?(e.consume(A),L):L(A)}}function PE(e,t){let n=-1,r=!0,i=0,a=[0,0,0,0],s=[0,0,0,0],o=!1,u=0,l,h,d;const p=new NE;for(;++n<e.length;){const f=e[n],m=f[1];f[0]==="enter"?m.type==="tableHead"?(o=!1,u!==0&&(Go(p,t,u,l,h),h=void 0,u=0),l={type:"table",start:Object.assign({},m.start),end:Object.assign({},m.end)},p.add(n,0,[["enter",l,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,h={type:"tableBody",start:Object.assign({},m.start),end:Object.assign({},m.end)},p.add(n,0,[["enter",h,t]])),i=m.type==="tableDelimiterRow"?2:h?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=yr(p,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=yr(p,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=yr(p,t,a,i,n,d)):s[1]!==0&&(d=yr(p,t,s,i,n,d)),i=0):i&&(m.type==="data"||m.type==="tableDelimiterMarker"||m.type==="tableDelimiterFiller")&&(s[3]=n)}for(u!==0&&Go(p,t,u,l,h),p.consume(t.events),n=-1;++n<t.events.length;){const f=t.events[n];f[0]==="enter"&&f[1].type==="table"&&(f[1]._align=RE(t.events,n))}return e}function yr(e,t,n,r,i,a){const s=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",o="tableContent";n[0]!==0&&(a.end=Object.assign({},cn(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const u=cn(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 l=cn(t.events,n[2]),h=cn(t.events,n[3]),d={type:o,start:Object.assign({},l),end:Object.assign({},h)};if(e.add(n[2],0,[["enter",d,t]]),r!==2){const p=t.events[n[2]],f=t.events[n[3]];if(p[1].end=Object.assign({},f[1].end),p[1].type="chunkText",p[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({},cn(t.events,i)),e.add(i,0,[["exit",a,t]]),a=void 0),a}function Go(e,t,n,r,i){const a=[],s=cn(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 cn(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const ME={name:"tasklistCheck",tokenize:FE};function BE(){return{text:{91:ME}}}function FE(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 _e(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 X(u)?t(u):se(u)?e.check({tokenize:HE},t,n)(u):n(u)}}function HE(e,t,n){return ce(e,r,"whitespace");function r(i){return i===null?n(i):t(i)}}function UE(e){return dd([Kb(),kE(),IE(e),OE(),BE()])}const zE={};function $E(e){const t=this,n=e||zE,r=t.data(),i=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),s=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);i.push(UE(n)),a.push(jb()),s.push(Vb(n))}var YE=Object.defineProperty,jE=Object.defineProperties,VE=Object.getOwnPropertyDescriptors,Qo=Object.getOwnPropertySymbols,qE=Object.prototype.hasOwnProperty,WE=Object.prototype.propertyIsEnumerable,Ko=(e,t,n)=>t in e?YE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Sd=(e,t)=>{for(var n in t||(t={}))qE.call(t,n)&&Ko(e,n,t[n]);if(Qo)for(var n of Qo(t))WE.call(t,n)&&Ko(e,n,t[n]);return e},vd=(e,t)=>jE(e,VE(t)),GE=/(\*\*)([^*]*\*?)$/,QE=/(__)([^_]*?)$/,KE=/(\*\*\*)([^*]*?)$/,XE=/(\*)([^*]*?)$/,ZE=/(_)([^_]*?)$/,JE=/(`)([^`]*?)$/,e3=/(~~)([^~]*?)$/,rn=/^[\s_~*`]*$/,Id=/^[\s]*[-*+][\s]+$/,t3=/[\p{L}\p{N}_]/u,n3=/^```[^`\n]*```?$/,r3=/^\*{4,}$/,i3=/(__)([^_]+)_$/,a3=/(~~)([^~]+)~$/,Xo=/~~/g,Bt=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:t3.test(e)},or=(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},s3=(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},Nd=(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},xi=(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},o3=(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},
|
|
20
|
-
`)return!1}return!1},
|
|
17
|
+
`))}function u(f,m,_,x){const k=_.enter("tableCell"),v=_.enter("phrasing"),C=_.containerPhrasing(f,{...x,before:a,after:a});return v(),k(),C}function l(f,m){return nb(f,{align:m,alignDelimiters:r,padding:n,stringLength:i})}function h(f,m,_){const x=f.children;let k=-1;const v=[],C=m.enter("table");for(;++k<x.length;)v[k]=d(x[k],m,_);return C(),v}function d(f,m,_){const x=f.children;let k=-1;const v=[],C=m.enter("tableRow");for(;++k<x.length;)v[k]=u(x[k],f,m,_);return C(),v}function p(f,m,_){let x=dd.inlineCode(f,m,_);return _.stack.includes("tableCell")&&(x=x.replace(/\|/g,"\\$&")),x}}function Gb(){return{exit:{taskListCheckValueChecked:Yo,taskListCheckValueUnchecked:Yo,paragraph:Kb}}}function Qb(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:Xb}}}function Yo(e){const t=this.stack[this.stack.length-2];t.checked=e.type==="taskListCheckValueChecked"}function Kb(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 Xb(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=dd.listItem(e,t,n,{...r,...o.current()});return a&&(u=u.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,l)),u;function l(h){return h+s}}function Zb(){return[Ag(),qg(),Kg(),zb(),Gb()]}function Jb(e){return{extensions:[Cg(),Wg(e),Xg(),Wb(e),Qb()]}}function Je(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 at(e,t){return e.length>0?(Je(e,e.length,0,t),e):t}const jo={}.hasOwnProperty;function fd(e){const t={};let n=-1;for(;++n<e.length;)e2(t,e[n]);return t}function e2(e,t){let n;for(n in t){const i=(jo.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let s;if(a)for(s in a){jo.call(i,s)||(i[s]=[]);const o=a[s];t2(i[s],Array.isArray(o)?o:o?[o]:[])}}}function t2(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);Je(e,0,0,r)}const n2={tokenize:u2,partial:!0},pd={tokenize:l2,partial:!0},md={tokenize:c2,partial:!0},gd={tokenize:d2,partial:!0},r2={tokenize:h2,partial:!0},bd={name:"wwwAutolink",tokenize:s2,previous:Td},Ed={name:"protocolAutolink",tokenize:o2,previous:_d},Ct={name:"emailAutolink",tokenize:a2,previous:kd},Tt={};function i2(){return{text:Tt}}let jt=48;for(;jt<123;)Tt[jt]=Ct,jt++,jt===58?jt=65:jt===91&&(jt=97);Tt[43]=Ct;Tt[45]=Ct;Tt[46]=Ct;Tt[95]=Ct;Tt[72]=[Ct,Ed];Tt[104]=[Ct,Ed];Tt[87]=[Ct,bd];Tt[119]=[Ct,bd];function a2(e,t,n){const r=this;let i,a;return s;function s(d){return!Ea(d)||!kd.call(r,r.previous)||ss(r.events)?n(d):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),o(d))}function o(d){return Ea(d)?(e.consume(d),o):d===64?(e.consume(d),u):n(d)}function u(d){return d===46?e.check(r2,h,l)(d):d===45||d===95||Fe(d)?(a=!0,e.consume(d),u):h(d)}function l(d){return e.consume(d),i=!0,u}function h(d){return a&&i&&Ye(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(d)):n(d)}}function s2(e,t,n){const r=this;return i;function i(s){return s!==87&&s!==119||!Td.call(r,r.previous)||ss(r.events)?n(s):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(n2,e.attempt(pd,e.attempt(md,a),n),n)(s))}function a(s){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(s)}}function o2(e,t,n){const r=this;let i="",a=!1;return s;function s(d){return(d===72||d===104)&&_d.call(r,r.previous)&&!ss(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 p=i.toLowerCase();if(p==="http"||p==="https")return e.consume(d),u}return n(d)}function u(d){return d===47?(e.consume(d),a?l:(a=!0,u)):n(d)}function l(d){return d===null||Jr(d)||ke(d)||Jt(d)||xi(d)?n(d):e.attempt(pd,e.attempt(md,h),n)(d)}function h(d){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(d)}}function u2(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 l2(e,t,n){let r,i,a;return s;function s(l){return l===46||l===95?e.check(gd,u,o)(l):l===null||ke(l)||Jt(l)||l!==45&&xi(l)?u(l):(a=!0,e.consume(l),s)}function o(l){return l===95?r=!0:(i=r,r=void 0),e.consume(l),s}function u(l){return i||r||!a?n(l):t(l)}}function c2(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(gd,t,a)(s):s===null||ke(s)||Jt(s)?t(s):(e.consume(s),i)}function a(s){return s===41&&r++,e.consume(s),i}}function d2(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||ke(o)||Jt(o)?t(o):n(o)}function i(o){return o===null||o===40||o===91||ke(o)||Jt(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 h2(e,t,n){return r;function r(a){return e.consume(a),i}function i(a){return Fe(a)?n(a):t(a)}}function Td(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||ke(e)}function _d(e){return!Ye(e)}function kd(e){return!(e===47||Ea(e))}function Ea(e){return e===43||e===45||e===46||e===95||Fe(e)}function ss(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 vn(e){const t=[];let n=-1,r=0,i=0;for(;++n<e.length;){const a=e.charCodeAt(n);let s="";if(a===37&&Fe(e.charCodeAt(n+1))&&Fe(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 yi(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 Ta={name:"attention",resolveAll:f2,tokenize:p2};function f2(e,t){let n=-1,r,i,a,s,o,u,l,h;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},p={...e[n][1].start};Vo(d,-u),Vo(p,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:p},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},l=[],e[r][1].end.offset-e[r][1].start.offset&&(l=at(l,[["enter",e[r][1],t],["exit",e[r][1],t]])),l=at(l,[["enter",i,t],["enter",s,t],["exit",s,t],["enter",a,t]]),l=at(l,yi(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),l=at(l,[["exit",a,t],["enter",o,t],["exit",o,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(h=2,l=at(l,[["enter",e[n][1],t],["exit",e[n][1],t]])):h=0,Je(e,r-1,n-r+3,l),n=r+l.length-h-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function p2(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=_n(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 l=e.exit("attentionSequence"),h=_n(u),d=!h||h===2&&i||n.includes(u),p=!i||i===2&&h||n.includes(r);return l._open=!!(a===42?d:d&&(i||!p)),l._close=!!(a===42?p:p&&(h||!d)),t(u)}}function Vo(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const m2={name:"autolink",tokenize:g2};function g2(e,t,n){let r=0;return i;function i(f){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(f),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(f){return Ye(f)?(e.consume(f),s):f===64?n(f):l(f)}function s(f){return f===43||f===45||f===46||Fe(f)?(r=1,o(f)):l(f)}function o(f){return f===58?(e.consume(f),r=0,u):(f===43||f===45||f===46||Fe(f))&&r++<32?(e.consume(f),o):(r=0,l(f))}function u(f){return f===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(f),e.exit("autolinkMarker"),e.exit("autolink"),t):f===null||f===32||f===60||Jr(f)?n(f):(e.consume(f),u)}function l(f){return f===64?(e.consume(f),h):bg(f)?(e.consume(f),l):n(f)}function h(f){return Fe(f)?d(f):n(f)}function d(f){return f===46?(e.consume(f),r=0,h):f===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(f),e.exit("autolinkMarker"),e.exit("autolink"),t):p(f)}function p(f){if((f===45||Fe(f))&&r++<63){const m=f===45?p:d;return e.consume(f),m}return n(f)}}function ce(e,t,n,r){const i=r?r-1:Number.POSITIVE_INFINITY;let a=0;return s;function s(u){return se(u)?(e.enter(n),o(u)):t(u)}function o(u){return se(u)&&a++<i?(e.consume(u),o):(e.exit(n),t(u))}}const br={partial:!0,tokenize:b2};function b2(e,t,n){return r;function r(a){return se(a)?ce(e,i,"linePrefix")(a):i(a)}function i(a){return a===null||X(a)?t(a):n(a)}}const xd={continuation:{tokenize:T2},exit:_2,name:"blockQuote",tokenize:E2};function E2(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 se(s)?(e.enter("blockQuotePrefixWhitespace"),e.consume(s),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(s))}}function T2(e,t,n){const r=this;return i;function i(s){return se(s)?ce(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s):a(s)}function a(s){return e.attempt(xd,t,n)(s)}}function _2(e){e.exit("blockQuote")}const yd={name:"characterEscape",tokenize:k2};function k2(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 Tg(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const wd={name:"characterReference",tokenize:x2};function x2(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"),l):(e.enter("characterReferenceValue"),a=31,s=Fe,h(d))}function l(d){return d===88||d===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(d),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,s=Eg,h):(e.enter("characterReferenceValue"),a=7,s=ba,h(d))}function h(d){if(d===59&&i){const p=e.exit("characterReferenceValue");return s===Fe&&!as(r.sliceSerialize(p))?n(d):(e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return s(d)&&i++<a?(e.consume(d),h):n(d)}}const qo={partial:!0,tokenize:w2},Wo={concrete:!0,name:"codeFenced",tokenize:y2};function y2(e,t,n){const r=this,i={partial:!0,tokenize:F};let a=0,s=0,o;return u;function u(S){return l(S)}function l(S){const Y=r.events[r.events.length-1];return a=Y&&Y[1].type==="linePrefix"?Y[2].sliceSerialize(Y[1],!0).length:0,o=S,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),h(S)}function h(S){return S===o?(s++,e.consume(S),h):s<3?n(S):(e.exit("codeFencedFenceSequence"),se(S)?ce(e,d,"whitespace")(S):d(S))}function d(S){return S===null||X(S)?(e.exit("codeFencedFence"),r.interrupt?t(S):e.check(qo,_,R)(S)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),p(S))}function p(S){return S===null||X(S)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),d(S)):se(S)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),ce(e,f,"whitespace")(S)):S===96&&S===o?n(S):(e.consume(S),p)}function f(S){return S===null||X(S)?d(S):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),m(S))}function m(S){return S===null||X(S)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),d(S)):S===96&&S===o?n(S):(e.consume(S),m)}function _(S){return e.attempt(i,R,x)(S)}function x(S){return e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),k}function k(S){return a>0&&se(S)?ce(e,v,"linePrefix",a+1)(S):v(S)}function v(S){return S===null||X(S)?e.check(qo,_,R)(S):(e.enter("codeFlowValue"),C(S))}function C(S){return S===null||X(S)?(e.exit("codeFlowValue"),v(S)):(e.consume(S),C)}function R(S){return e.exit("codeFenced"),t(S)}function F(S,Y,L){let O=0;return A;function A(J){return S.enter("lineEnding"),S.consume(J),S.exit("lineEnding"),z}function z(J){return S.enter("codeFencedFence"),se(J)?ce(S,M,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(J):M(J)}function M(J){return J===o?(S.enter("codeFencedFenceSequence"),Q(J)):L(J)}function Q(J){return J===o?(O++,S.consume(J),Q):O>=s?(S.exit("codeFencedFenceSequence"),se(J)?ce(S,ue,"whitespace")(J):ue(J)):L(J)}function ue(J){return J===null||X(J)?(S.exit("codeFencedFence"),Y(J)):L(J)}}}function w2(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 Yi={name:"codeIndented",tokenize:C2},A2={partial:!0,tokenize:S2};function C2(e,t,n){const r=this;return i;function i(l){return e.enter("codeIndented"),ce(e,a,"linePrefix",4+1)(l)}function a(l){const h=r.events[r.events.length-1];return h&&h[1].type==="linePrefix"&&h[2].sliceSerialize(h[1],!0).length>=4?s(l):n(l)}function s(l){return l===null?u(l):X(l)?e.attempt(A2,s,u)(l):(e.enter("codeFlowValue"),o(l))}function o(l){return l===null||X(l)?(e.exit("codeFlowValue"),s(l)):(e.consume(l),o)}function u(l){return e.exit("codeIndented"),t(l)}}function S2(e,t,n){const r=this;return i;function i(s){return r.parser.lazy[r.now().line]?n(s):X(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),i):ce(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):X(s)?i(s):n(s)}}const v2={name:"codeText",previous:N2,resolve:I2,tokenize:L2};function I2(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 N2(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function L2(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,h(d)):X(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),u):(e.enter("codeTextData"),l(d))}function l(d){return d===null||d===32||d===96||X(d)?(e.exit("codeTextData"),u(d)):(e.consume(d),l)}function h(d){return d===96?(e.consume(d),i++,h):i===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(d)):(a.type="codeTextData",l(d))}}class R2{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&&Pn(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),Pn(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Pn(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);Pn(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Pn(this.left,n.reverse())}}}function Pn(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 Ad(e){const t={};let n=-1,r,i,a,s,o,u,l;const h=new R2(e);for(;++n<h.length;){for(;n in t;)n=t[n];if(r=h.get(n),n&&r[1].type==="chunkFlow"&&h.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,O2(h,n)),n=t[n],l=!0);else if(r[1]._container){for(a=n,i=void 0;a--;)if(s=h.get(a),s[1].type==="lineEnding"||s[1].type==="lineEndingBlank")s[0]==="enter"&&(i&&(h.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={...h.get(i)[1].start},o=h.slice(i,n),o.unshift(r),h.splice(i,n-i+1,o))}}return Je(e,0,Number.POSITIVE_INFINITY,h.slice(0)),!l}function O2(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=[],l={};let h,d,p=-1,f=n,m=0,_=0;const x=[_];for(;f;){for(;e.get(++i)[1]!==f;);a.push(i),f._tokenizer||(h=r.sliceStream(f),f.next||h.push(null),d&&s.defineSkip(f.start),f._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=!0),s.write(h),f._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=void 0)),d=f,f=f.next}for(f=n;++p<o.length;)o[p][0]==="exit"&&o[p-1][0]==="enter"&&o[p][1].type===o[p-1][1].type&&o[p][1].start.line!==o[p][1].end.line&&(_=p+1,x.push(_),f._tokenizer=void 0,f.previous=void 0,f=f.next);for(s.events=[],f?(f._tokenizer=void 0,f.previous=void 0):x.pop(),p=x.length;p--;){const k=o.slice(x[p],x[p+1]),v=a.pop();u.push([v,v+k.length-1]),e.splice(v,2,k)}for(u.reverse(),p=-1;++p<u.length;)l[m+u[p][0]]=m+u[p][1],m+=u[p][1]-u[p][0]-1;return l}const D2={resolve:M2,tokenize:B2},P2={partial:!0,tokenize:F2};function M2(e){return Ad(e),e}function B2(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):X(o)?e.check(P2,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 F2(e,t,n){const r=this;return i;function i(s){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),ce(e,a,"linePrefix")}function a(s){if(s===null||X(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 Cd(e,t,n,r,i,a,s,o,u){const l=u||Number.POSITIVE_INFINITY;let h=0;return d;function d(k){return k===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(k),e.exit(a),p):k===null||k===32||k===41||Jr(k)?n(k):(e.enter(r),e.enter(s),e.enter(o),e.enter("chunkString",{contentType:"string"}),_(k))}function p(k){return k===62?(e.enter(a),e.consume(k),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(o),e.enter("chunkString",{contentType:"string"}),f(k))}function f(k){return k===62?(e.exit("chunkString"),e.exit(o),p(k)):k===null||k===60||X(k)?n(k):(e.consume(k),k===92?m:f)}function m(k){return k===60||k===62||k===92?(e.consume(k),f):f(k)}function _(k){return!h&&(k===null||k===41||ke(k))?(e.exit("chunkString"),e.exit(o),e.exit(s),e.exit(r),t(k)):h<l&&k===40?(e.consume(k),h++,_):k===41?(e.consume(k),h--,_):k===null||k===32||k===40||Jr(k)?n(k):(e.consume(k),k===92?x:_)}function x(k){return k===40||k===41||k===92?(e.consume(k),_):_(k)}}function Sd(e,t,n,r,i,a){const s=this;let o=0,u;return l;function l(f){return e.enter(r),e.enter(i),e.consume(f),e.exit(i),e.enter(a),h}function h(f){return o>999||f===null||f===91||f===93&&!u||f===94&&!o&&"_hiddenFootnoteSupport"in s.parser.constructs?n(f):f===93?(e.exit(a),e.enter(i),e.consume(f),e.exit(i),e.exit(r),t):X(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),h):(e.enter("chunkString",{contentType:"string"}),d(f))}function d(f){return f===null||f===91||f===93||X(f)||o++>999?(e.exit("chunkString"),h(f)):(e.consume(f),u||(u=!se(f)),f===92?p:d)}function p(f){return f===91||f===92||f===93?(e.consume(f),o++,d):d(f)}}function vd(e,t,n,r,i,a){let s;return o;function o(p){return p===34||p===39||p===40?(e.enter(r),e.enter(i),e.consume(p),e.exit(i),s=p===40?41:p,u):n(p)}function u(p){return p===s?(e.enter(i),e.consume(p),e.exit(i),e.exit(r),t):(e.enter(a),l(p))}function l(p){return p===s?(e.exit(a),u(s)):p===null?n(p):X(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),ce(e,l,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),h(p))}function h(p){return p===s||p===null||X(p)?(e.exit("chunkString"),l(p)):(e.consume(p),p===92?d:h)}function d(p){return p===s||p===92?(e.consume(p),h):h(p)}}function Jn(e,t){let n;return r;function r(i){return X(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):se(i)?ce(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}const H2={name:"definition",tokenize:z2},U2={partial:!0,tokenize:$2};function z2(e,t,n){const r=this;let i;return a;function a(f){return e.enter("definition"),s(f)}function s(f){return Sd.call(r,e,o,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(f)}function o(f){return i=lt(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),f===58?(e.enter("definitionMarker"),e.consume(f),e.exit("definitionMarker"),u):n(f)}function u(f){return ke(f)?Jn(e,l)(f):l(f)}function l(f){return Cd(e,h,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(f)}function h(f){return e.attempt(U2,d,d)(f)}function d(f){return se(f)?ce(e,p,"whitespace")(f):p(f)}function p(f){return f===null||X(f)?(e.exit("definition"),r.parser.defined.push(i),t(f)):n(f)}}function $2(e,t,n){return r;function r(o){return ke(o)?Jn(e,i)(o):n(o)}function i(o){return vd(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(o)}function a(o){return se(o)?ce(e,s,"whitespace")(o):s(o)}function s(o){return o===null||X(o)?t(o):n(o)}}const Y2={name:"hardBreakEscape",tokenize:j2};function j2(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.consume(a),i}function i(a){return X(a)?(e.exit("hardBreakEscape"),t(a)):n(a)}}const V2={name:"headingAtx",resolve:q2,tokenize:W2};function q2(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"},Je(e,r,n-r+1,[["enter",i,t],["enter",a,t],["exit",a,t],["exit",i,t]])),e}function W2(e,t,n){let r=0;return i;function i(h){return e.enter("atxHeading"),a(h)}function a(h){return e.enter("atxHeadingSequence"),s(h)}function s(h){return h===35&&r++<6?(e.consume(h),s):h===null||ke(h)?(e.exit("atxHeadingSequence"),o(h)):n(h)}function o(h){return h===35?(e.enter("atxHeadingSequence"),u(h)):h===null||X(h)?(e.exit("atxHeading"),t(h)):se(h)?ce(e,o,"whitespace")(h):(e.enter("atxHeadingText"),l(h))}function u(h){return h===35?(e.consume(h),u):(e.exit("atxHeadingSequence"),o(h))}function l(h){return h===null||h===35||ke(h)?(e.exit("atxHeadingText"),o(h)):(e.consume(h),l)}}const G2=["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"],Go=["pre","script","style","textarea"],Q2={concrete:!0,name:"htmlFlow",resolveTo:Z2,tokenize:J2},K2={partial:!0,tokenize:tE},X2={partial:!0,tokenize:eE};function Z2(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 J2(e,t,n){const r=this;let i,a,s,o,u;return l;function l(w){return h(w)}function h(w){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(w),d}function d(w){return w===33?(e.consume(w),p):w===47?(e.consume(w),a=!0,_):w===63?(e.consume(w),i=3,r.interrupt?t:E):Ye(w)?(e.consume(w),s=String.fromCharCode(w),x):n(w)}function p(w){return w===45?(e.consume(w),i=2,f):w===91?(e.consume(w),i=5,o=0,m):Ye(w)?(e.consume(w),i=4,r.interrupt?t:E):n(w)}function f(w){return w===45?(e.consume(w),r.interrupt?t:E):n(w)}function m(w){const Se="CDATA[";return w===Se.charCodeAt(o++)?(e.consume(w),o===Se.length?r.interrupt?t:M:m):n(w)}function _(w){return Ye(w)?(e.consume(w),s=String.fromCharCode(w),x):n(w)}function x(w){if(w===null||w===47||w===62||ke(w)){const Se=w===47,me=s.toLowerCase();return!Se&&!a&&Go.includes(me)?(i=1,r.interrupt?t(w):M(w)):G2.includes(s.toLowerCase())?(i=6,Se?(e.consume(w),k):r.interrupt?t(w):M(w)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(w):a?v(w):C(w))}return w===45||Fe(w)?(e.consume(w),s+=String.fromCharCode(w),x):n(w)}function k(w){return w===62?(e.consume(w),r.interrupt?t:M):n(w)}function v(w){return se(w)?(e.consume(w),v):A(w)}function C(w){return w===47?(e.consume(w),A):w===58||w===95||Ye(w)?(e.consume(w),R):se(w)?(e.consume(w),C):A(w)}function R(w){return w===45||w===46||w===58||w===95||Fe(w)?(e.consume(w),R):F(w)}function F(w){return w===61?(e.consume(w),S):se(w)?(e.consume(w),F):C(w)}function S(w){return w===null||w===60||w===61||w===62||w===96?n(w):w===34||w===39?(e.consume(w),u=w,Y):se(w)?(e.consume(w),S):L(w)}function Y(w){return w===u?(e.consume(w),u=null,O):w===null||X(w)?n(w):(e.consume(w),Y)}function L(w){return w===null||w===34||w===39||w===47||w===60||w===61||w===62||w===96||ke(w)?F(w):(e.consume(w),L)}function O(w){return w===47||w===62||se(w)?C(w):n(w)}function A(w){return w===62?(e.consume(w),z):n(w)}function z(w){return w===null||X(w)?M(w):se(w)?(e.consume(w),z):n(w)}function M(w){return w===45&&i===2?(e.consume(w),oe):w===60&&i===1?(e.consume(w),q):w===62&&i===4?(e.consume(w),he):w===63&&i===3?(e.consume(w),E):w===93&&i===5?(e.consume(w),W):X(w)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check(K2,Z,Q)(w)):w===null||X(w)?(e.exit("htmlFlowData"),Q(w)):(e.consume(w),M)}function Q(w){return e.check(X2,ue,Z)(w)}function ue(w){return e.enter("lineEnding"),e.consume(w),e.exit("lineEnding"),J}function J(w){return w===null||X(w)?Q(w):(e.enter("htmlFlowData"),M(w))}function oe(w){return w===45?(e.consume(w),E):M(w)}function q(w){return w===47?(e.consume(w),s="",K):M(w)}function K(w){if(w===62){const Se=s.toLowerCase();return Go.includes(Se)?(e.consume(w),he):M(w)}return Ye(w)&&s.length<8?(e.consume(w),s+=String.fromCharCode(w),K):M(w)}function W(w){return w===93?(e.consume(w),E):M(w)}function E(w){return w===62?(e.consume(w),he):w===45&&i===2?(e.consume(w),E):M(w)}function he(w){return w===null||X(w)?(e.exit("htmlFlowData"),Z(w)):(e.consume(w),he)}function Z(w){return e.exit("htmlFlow"),t(w)}}function eE(e,t,n){const r=this;return i;function i(s){return X(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 tE(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(br,t,n)}}const nE={name:"htmlText",tokenize:rE};function rE(e,t,n){const r=this;let i,a,s;return o;function o(E){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(E),u}function u(E){return E===33?(e.consume(E),l):E===47?(e.consume(E),F):E===63?(e.consume(E),C):Ye(E)?(e.consume(E),L):n(E)}function l(E){return E===45?(e.consume(E),h):E===91?(e.consume(E),a=0,m):Ye(E)?(e.consume(E),v):n(E)}function h(E){return E===45?(e.consume(E),f):n(E)}function d(E){return E===null?n(E):E===45?(e.consume(E),p):X(E)?(s=d,q(E)):(e.consume(E),d)}function p(E){return E===45?(e.consume(E),f):d(E)}function f(E){return E===62?oe(E):E===45?p(E):d(E)}function m(E){const he="CDATA[";return E===he.charCodeAt(a++)?(e.consume(E),a===he.length?_:m):n(E)}function _(E){return E===null?n(E):E===93?(e.consume(E),x):X(E)?(s=_,q(E)):(e.consume(E),_)}function x(E){return E===93?(e.consume(E),k):_(E)}function k(E){return E===62?oe(E):E===93?(e.consume(E),k):_(E)}function v(E){return E===null||E===62?oe(E):X(E)?(s=v,q(E)):(e.consume(E),v)}function C(E){return E===null?n(E):E===63?(e.consume(E),R):X(E)?(s=C,q(E)):(e.consume(E),C)}function R(E){return E===62?oe(E):C(E)}function F(E){return Ye(E)?(e.consume(E),S):n(E)}function S(E){return E===45||Fe(E)?(e.consume(E),S):Y(E)}function Y(E){return X(E)?(s=Y,q(E)):se(E)?(e.consume(E),Y):oe(E)}function L(E){return E===45||Fe(E)?(e.consume(E),L):E===47||E===62||ke(E)?O(E):n(E)}function O(E){return E===47?(e.consume(E),oe):E===58||E===95||Ye(E)?(e.consume(E),A):X(E)?(s=O,q(E)):se(E)?(e.consume(E),O):oe(E)}function A(E){return E===45||E===46||E===58||E===95||Fe(E)?(e.consume(E),A):z(E)}function z(E){return E===61?(e.consume(E),M):X(E)?(s=z,q(E)):se(E)?(e.consume(E),z):O(E)}function M(E){return E===null||E===60||E===61||E===62||E===96?n(E):E===34||E===39?(e.consume(E),i=E,Q):X(E)?(s=M,q(E)):se(E)?(e.consume(E),M):(e.consume(E),ue)}function Q(E){return E===i?(e.consume(E),i=void 0,J):E===null?n(E):X(E)?(s=Q,q(E)):(e.consume(E),Q)}function ue(E){return E===null||E===34||E===39||E===60||E===61||E===96?n(E):E===47||E===62||ke(E)?O(E):(e.consume(E),ue)}function J(E){return E===47||E===62||ke(E)?O(E):n(E)}function oe(E){return E===62?(e.consume(E),e.exit("htmlTextData"),e.exit("htmlText"),t):n(E)}function q(E){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),K}function K(E){return se(E)?ce(e,W,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(E):W(E)}function W(E){return e.enter("htmlTextData"),s(E)}}const os={name:"labelEnd",resolveAll:oE,resolveTo:uE,tokenize:lE},iE={tokenize:cE},aE={tokenize:dE},sE={tokenize:hE};function oE(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&&Je(e,0,e.length,n),e}function uE(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}},l={type:"label",start:{...e[a][1].start},end:{...e[s][1].end}},h={type:"labelText",start:{...e[a+r+2][1].end},end:{...e[s-2][1].start}};return o=[["enter",u,t],["enter",l,t]],o=at(o,e.slice(a+1,a+r+3)),o=at(o,[["enter",h,t]]),o=at(o,yi(t.parser.constructs.insideSpan.null,e.slice(a+r+4,s-3),t)),o=at(o,[["exit",h,t],e[s-2],e[s-1],["exit",l,t]]),o=at(o,e.slice(s+1)),o=at(o,[["exit",u,t]]),Je(e,a,e.length,o),e}function lE(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(p){return a?a._inactive?d(p):(s=r.parser.defined.includes(lt(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(p),e.exit("labelMarker"),e.exit("labelEnd"),u):n(p)}function u(p){return p===40?e.attempt(iE,h,s?h:d)(p):p===91?e.attempt(aE,h,s?l:d)(p):s?h(p):d(p)}function l(p){return e.attempt(sE,h,d)(p)}function h(p){return t(p)}function d(p){return a._balanced=!0,n(p)}}function cE(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 ke(d)?Jn(e,a)(d):a(d)}function a(d){return d===41?h(d):Cd(e,s,o,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(d)}function s(d){return ke(d)?Jn(e,u)(d):h(d)}function o(d){return n(d)}function u(d){return d===34||d===39||d===40?vd(e,l,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(d):h(d)}function l(d){return ke(d)?Jn(e,h)(d):h(d)}function h(d){return d===41?(e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),e.exit("resource"),t):n(d)}}function dE(e,t,n){const r=this;return i;function i(o){return Sd.call(r,e,a,s,"reference","referenceMarker","referenceString")(o)}function a(o){return r.parser.defined.includes(lt(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(o):n(o)}function s(o){return n(o)}}function hE(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 fE={name:"labelStartImage",resolveAll:os.resolveAll,tokenize:pE};function pE(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 mE={name:"labelStartLink",resolveAll:os.resolveAll,tokenize:gE};function gE(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 ji={name:"lineEnding",tokenize:bE};function bE(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),ce(e,t,"linePrefix")}}const Fr={name:"thematicBreak",tokenize:EE};function EE(e,t,n){let r=0,i;return a;function a(l){return e.enter("thematicBreak"),s(l)}function s(l){return i=l,o(l)}function o(l){return l===i?(e.enter("thematicBreakSequence"),u(l)):r>=3&&(l===null||X(l))?(e.exit("thematicBreak"),t(l)):n(l)}function u(l){return l===i?(e.consume(l),r++,u):(e.exit("thematicBreakSequence"),se(l)?ce(e,o,"whitespace")(l):o(l))}}const We={continuation:{tokenize:xE},exit:wE,name:"list",tokenize:kE},TE={partial:!0,tokenize:AE},_E={partial:!0,tokenize:yE};function kE(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(f){const m=r.containerState.type||(f===42||f===43||f===45?"listUnordered":"listOrdered");if(m==="listUnordered"?!r.containerState.marker||f===r.containerState.marker:ba(f)){if(r.containerState.type||(r.containerState.type=m,e.enter(m,{_container:!0})),m==="listUnordered")return e.enter("listItemPrefix"),f===42||f===45?e.check(Fr,n,l)(f):l(f);if(!r.interrupt||f===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),u(f)}return n(f)}function u(f){return ba(f)&&++s<10?(e.consume(f),u):(!r.interrupt||s<2)&&(r.containerState.marker?f===r.containerState.marker:f===41||f===46)?(e.exit("listItemValue"),l(f)):n(f)}function l(f){return e.enter("listItemMarker"),e.consume(f),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||f,e.check(br,r.interrupt?n:h,e.attempt(TE,p,d))}function h(f){return r.containerState.initialBlankLine=!0,a++,p(f)}function d(f){return se(f)?(e.enter("listItemPrefixWhitespace"),e.consume(f),e.exit("listItemPrefixWhitespace"),p):n(f)}function p(f){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(f)}}function xE(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(br,i,a);function i(o){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,ce(e,t,"listItemIndent",r.containerState.size+1)(o)}function a(o){return r.containerState.furtherBlankLines||!se(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(_E,t,s)(o))}function s(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,ce(e,e.attempt(We,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o)}}function yE(e,t,n){const r=this;return ce(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 wE(e){e.exit(this.containerState.type)}function AE(e,t,n){const r=this;return ce(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!se(a)&&s&&s[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const Qo={name:"setextUnderline",resolveTo:CE,tokenize:SE};function CE(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 SE(e,t,n){const r=this;let i;return a;function a(l){let h=r.events.length,d;for(;h--;)if(r.events[h][1].type!=="lineEnding"&&r.events[h][1].type!=="linePrefix"&&r.events[h][1].type!=="content"){d=r.events[h][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||d)?(e.enter("setextHeadingLine"),i=l,s(l)):n(l)}function s(l){return e.enter("setextHeadingLineSequence"),o(l)}function o(l){return l===i?(e.consume(l),o):(e.exit("setextHeadingLineSequence"),se(l)?ce(e,u,"lineSuffix")(l):u(l))}function u(l){return l===null||X(l)?(e.exit("setextHeadingLine"),t(l)):n(l)}}const vE={tokenize:ME,partial:!0};function IE(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:OE,continuation:{tokenize:DE},exit:PE}},text:{91:{name:"gfmFootnoteCall",tokenize:RE},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:NE,resolveTo:LE}}}}function NE(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 l=lt(r.sliceSerialize({start:s.end,end:r.now()}));return l.codePointAt(0)!==94||!a.includes(l.slice(1))?n(u):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(u),e.exit("gfmFootnoteCallLabelMarker"),t(u))}}function LE(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 RE(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",l)}function l(d){if(a>999||d===93&&!s||d===null||d===91||ke(d))return n(d);if(d===93){e.exit("chunkString");const p=e.exit("gfmFootnoteCallString");return i.includes(lt(r.sliceSerialize(p)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(d)}return ke(d)||(s=!0),a++,e.consume(d),d===92?h:l}function h(d){return d===91||d===92||d===93?(e.consume(d),a++,l):l(d)}}function OE(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"),l}function l(m){return m===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",h):n(m)}function h(m){if(s>999||m===93&&!o||m===null||m===91||ke(m))return n(m);if(m===93){e.exit("chunkString");const _=e.exit("gfmFootnoteDefinitionLabelString");return a=lt(r.sliceSerialize(_)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),p}return ke(m)||(o=!0),s++,e.consume(m),m===92?d:h}function d(m){return m===91||m===92||m===93?(e.consume(m),s++,h):h(m)}function p(m){return m===58?(e.enter("definitionMarker"),e.consume(m),e.exit("definitionMarker"),i.includes(a)||i.push(a),ce(e,f,"gfmFootnoteDefinitionWhitespace")):n(m)}function f(m){return t(m)}}function DE(e,t,n){return e.check(br,t,e.attempt(vE,t,n))}function PE(e){e.exit("gfmFootnoteDefinition")}function ME(e,t,n){const r=this;return ce(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 BE(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 l=u;for(;l--;)if(s[l][0]==="exit"&&s[l][1].type==="strikethroughSequenceTemporary"&&s[l][1]._open&&s[u][1].end.offset-s[u][1].start.offset===s[l][1].end.offset-s[l][1].start.offset){s[u][1].type="strikethroughSequence",s[l][1].type="strikethroughSequence";const h={type:"strikethrough",start:Object.assign({},s[l][1].start),end:Object.assign({},s[u][1].end)},d={type:"strikethroughText",start:Object.assign({},s[l][1].end),end:Object.assign({},s[u][1].start)},p=[["enter",h,o],["enter",s[l][1],o],["exit",s[l][1],o],["enter",d,o]],f=o.parser.constructs.insideSpan.null;f&&Je(p,p.length,0,yi(f,s.slice(l+1,u),o)),Je(p,p.length,0,[["exit",d,o],["enter",s[u][1],o],["exit",s[u][1],o],["exit",h,o]]),Je(s,l-1,u-l+3,p),u=l+p.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 l=this.previous,h=this.events;let d=0;return p;function p(m){return l===126&&h[h.length-1][1].type!=="characterEscape"?u(m):(s.enter("strikethroughSequenceTemporary"),f(m))}function f(m){const _=_n(l);if(m===126)return d>1?u(m):(s.consume(m),d++,f);if(d<2&&!n)return u(m);const x=s.exit("strikethroughSequenceTemporary"),k=_n(m);return x._open=!k||k===2&&!!_,x._close=!_||_===2&&!!k,o(m)}}}class FE{constructor(){this.map=[]}add(t,n,r){HE(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 HE(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 UE(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 zE(){return{flow:{null:{name:"table",tokenize:$E,resolveAll:YE}}}}function $E(e,t,n){const r=this;let i=0,a=0,s;return o;function o(A){let z=r.events.length-1;for(;z>-1;){const ue=r.events[z][1].type;if(ue==="lineEnding"||ue==="linePrefix")z--;else break}const M=z>-1?r.events[z][1].type:null,Q=M==="tableHead"||M==="tableRow"?S:u;return Q===S&&r.parser.lazy[r.now().line]?n(A):Q(A)}function u(A){return e.enter("tableHead"),e.enter("tableRow"),l(A)}function l(A){return A===124||(s=!0,a+=1),h(A)}function h(A){return A===null?n(A):X(A)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(A),e.exit("lineEnding"),f):n(A):se(A)?ce(e,h,"whitespace")(A):(a+=1,s&&(s=!1,i+=1),A===124?(e.enter("tableCellDivider"),e.consume(A),e.exit("tableCellDivider"),s=!0,h):(e.enter("data"),d(A)))}function d(A){return A===null||A===124||ke(A)?(e.exit("data"),h(A)):(e.consume(A),A===92?p:d)}function p(A){return A===92||A===124?(e.consume(A),d):d(A)}function f(A){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(A):(e.enter("tableDelimiterRow"),s=!1,se(A)?ce(e,m,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(A):m(A))}function m(A){return A===45||A===58?x(A):A===124?(s=!0,e.enter("tableCellDivider"),e.consume(A),e.exit("tableCellDivider"),_):F(A)}function _(A){return se(A)?ce(e,x,"whitespace")(A):x(A)}function x(A){return A===58?(a+=1,s=!0,e.enter("tableDelimiterMarker"),e.consume(A),e.exit("tableDelimiterMarker"),k):A===45?(a+=1,k(A)):A===null||X(A)?R(A):F(A)}function k(A){return A===45?(e.enter("tableDelimiterFiller"),v(A)):F(A)}function v(A){return A===45?(e.consume(A),v):A===58?(s=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(A),e.exit("tableDelimiterMarker"),C):(e.exit("tableDelimiterFiller"),C(A))}function C(A){return se(A)?ce(e,R,"whitespace")(A):R(A)}function R(A){return A===124?m(A):A===null||X(A)?!s||i!==a?F(A):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(A)):F(A)}function F(A){return n(A)}function S(A){return e.enter("tableRow"),Y(A)}function Y(A){return A===124?(e.enter("tableCellDivider"),e.consume(A),e.exit("tableCellDivider"),Y):A===null||X(A)?(e.exit("tableRow"),t(A)):se(A)?ce(e,Y,"whitespace")(A):(e.enter("data"),L(A))}function L(A){return A===null||A===124||ke(A)?(e.exit("data"),Y(A)):(e.consume(A),A===92?O:L)}function O(A){return A===92||A===124?(e.consume(A),L):L(A)}}function YE(e,t){let n=-1,r=!0,i=0,a=[0,0,0,0],s=[0,0,0,0],o=!1,u=0,l,h,d;const p=new FE;for(;++n<e.length;){const f=e[n],m=f[1];f[0]==="enter"?m.type==="tableHead"?(o=!1,u!==0&&(Ko(p,t,u,l,h),h=void 0,u=0),l={type:"table",start:Object.assign({},m.start),end:Object.assign({},m.end)},p.add(n,0,[["enter",l,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,h={type:"tableBody",start:Object.assign({},m.start),end:Object.assign({},m.end)},p.add(n,0,[["enter",h,t]])),i=m.type==="tableDelimiterRow"?2:h?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=yr(p,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=yr(p,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=yr(p,t,a,i,n,d)):s[1]!==0&&(d=yr(p,t,s,i,n,d)),i=0):i&&(m.type==="data"||m.type==="tableDelimiterMarker"||m.type==="tableDelimiterFiller")&&(s[3]=n)}for(u!==0&&Ko(p,t,u,l,h),p.consume(t.events),n=-1;++n<t.events.length;){const f=t.events[n];f[0]==="enter"&&f[1].type==="table"&&(f[1]._align=UE(t.events,n))}return e}function yr(e,t,n,r,i,a){const s=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",o="tableContent";n[0]!==0&&(a.end=Object.assign({},cn(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const u=cn(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 l=cn(t.events,n[2]),h=cn(t.events,n[3]),d={type:o,start:Object.assign({},l),end:Object.assign({},h)};if(e.add(n[2],0,[["enter",d,t]]),r!==2){const p=t.events[n[2]],f=t.events[n[3]];if(p[1].end=Object.assign({},f[1].end),p[1].type="chunkText",p[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({},cn(t.events,i)),e.add(i,0,[["exit",a,t]]),a=void 0),a}function Ko(e,t,n,r,i){const a=[],s=cn(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 cn(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const jE={name:"tasklistCheck",tokenize:qE};function VE(){return{text:{91:jE}}}function qE(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 ke(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 X(u)?t(u):se(u)?e.check({tokenize:WE},t,n)(u):n(u)}}function WE(e,t,n){return ce(e,r,"whitespace");function r(i){return i===null?n(i):t(i)}}function GE(e){return fd([i2(),IE(),BE(e),zE(),VE()])}const QE={};function KE(e){const t=this,n=e||QE,r=t.data(),i=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),s=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);i.push(GE(n)),a.push(Zb()),s.push(Jb(n))}var XE=Object.defineProperty,ZE=Object.defineProperties,JE=Object.getOwnPropertyDescriptors,Xo=Object.getOwnPropertySymbols,e3=Object.prototype.hasOwnProperty,t3=Object.prototype.propertyIsEnumerable,Zo=(e,t,n)=>t in e?XE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Id=(e,t)=>{for(var n in t||(t={}))e3.call(t,n)&&Zo(e,n,t[n]);if(Xo)for(var n of Xo(t))t3.call(t,n)&&Zo(e,n,t[n]);return e},Nd=(e,t)=>ZE(e,JE(t)),n3=/(\*\*)([^*]*\*?)$/,r3=/(__)([^_]*?)$/,i3=/(\*\*\*)([^*]*?)$/,a3=/(\*)([^*]*?)$/,s3=/(_)([^_]*?)$/,o3=/(`)([^`]*?)$/,u3=/(~~)([^~]*?)$/,rn=/^[\s_~*`]*$/,Ld=/^[\s]*[-*+][\s]+$/,l3=/[\p{L}\p{N}_]/u,c3=/^```[^`\n]*```?$/,d3=/^\*{4,}$/,h3=/(__)([^_]+)_$/,f3=/(~~)([^~]+)~$/,Jo=/~~/g,Bt=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:l3.test(e)},or=(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},p3=(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},Rd=(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},wi=(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},m3=(e,t)=>{for(let n=t;n<e.length;n+=1){if(e[n]===")")return!0;if(e[n]===`
|
|
18
|
+
`)return!1}return!1},Od=(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]==="]"?m3(e,t):!1;if(e[n]===`
|
|
19
|
+
`)return!1}return!1},g3=(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},us=(e,t,n)=>{let r=0;for(let u=t-1;u>=0;u-=1)if(e[u]===`
|
|
21
21
|
`){r=u+1;break}let i=e.length;for(let u=t;u<e.length;u+=1)if(e[u]===`
|
|
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},
|
|
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},b3=/^(\s*(?:[-*+]|\d+[.)]) +)>(=?\s*[$]?\d)/gm,E3=e=>!e||typeof e!="string"||!e.includes(">")?e:e.replace(b3,(t,n,r,i)=>or(e,i)?t:`${n}\\>${r}`),T3=(e,t,n,r)=>n==="\\"||e.includes("$")&&wi(e,t)?!0:n!=="*"&&r==="*"?(t<e.length-2?e[t+2]:"")!=="*":!!(n==="*"||n&&r&&Bt(n)&&Bt(r)||(!n||n===" "||n===" "||n===`
|
|
23
23
|
`)&&(!r||r===" "||r===" "||r===`
|
|
24
|
-
`)),
|
|
25
|
-
`),i=r===-1?0:r+1,a=e.substring(i,n);return
|
|
26
|
-
`)?!0:
|
|
27
|
-
`),i=r===-1?0:r+1,a=e.substring(i,n);return
|
|
28
|
-
`)?!0:
|
|
24
|
+
`)),Dd=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]:"";T3(e,i,a,s)||(t+=1)}return t},_3=(e,t,n,r)=>!!(n==="\\"||e.includes("$")&&wi(e,t)||Od(e,t)||g3(e,t)||n==="_"||r==="_"||n&&r&&Bt(n)&&Bt(r)),k3=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]:"";_3(e,i,a,s)||(t+=1)}return t},x3=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},ls=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},eu=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},y3=(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 Ld.test(a)&&t.includes(`
|
|
26
|
+
`)?!0:us(e,n,"*")},w3=e=>{let t=e.match(n3);if(!t)return e;let n=t[2],r=e.lastIndexOf(t[1]);return or(e,r)||y3(e,n,r)?e:ls(e)%2===1?n.endsWith("*")?`${e}*`:`${e}**`:e},A3=(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 Ld.test(a)&&t.includes(`
|
|
28
|
+
`)?!0:us(e,n,"_")},C3=e=>{let t=e.match(r3);if(!t){let i=e.match(h3);if(i){let a=e.lastIndexOf(i[1]);if(!or(e,a)&&eu(e)%2===1)return`${e}_`}return e}let n=t[2],r=e.lastIndexOf(t[1]);return or(e,r)||A3(e,n,r)?e:eu(e)%2===1?`${e}__`:e},S3=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]!=="\\"&&!wi(e,n)){let r=n>0?e[n-1]:"",i=n<e.length-1?e[n+1]:"";if((!r||r===" "||r===" "||r===`
|
|
29
29
|
`)&&(!i||i===" "||i===" "||i===`
|
|
30
|
-
`)||r&&i&&Bt(r)&&Bt(i))continue;return n}}return-1},
|
|
31
|
-
`;)t-=1;if(t<e.length){let n=e.slice(0,t),r=e.slice(t);return`${n}_${r}`}return`${e}_`},
|
|
32
|
-
`)?null:e.endsWith("``")&&!e.endsWith("```")?`${e}\``:e,
|
|
30
|
+
`)||r&&i&&Bt(r)&&Bt(i))continue;return n}}return-1},v3=e=>{if(!e.match(a3))return e;let t=S3(e);if(t===-1)return e;let n=e.substring(t+1);return!n||rn.test(n)?e:Dd(e)%2===1?`${e}*`:e},Pd=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]!=="\\"&&!wi(e,n)&&!Od(e,n)){let r=n>0?e[n-1]:"",i=n<e.length-1?e[n+1]:"";if(r&&i&&Bt(r)&&Bt(i))continue;return n}}return-1},I3=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}_`},N3=e=>{if(!e.endsWith("**"))return null;let t=e.slice(0,-2);if(ls(t)%2!==1)return null;let n=t.indexOf("**"),r=Pd(t);return n!==-1&&r!==-1&&n<r?`${t}_**`:null},L3=e=>{if(!e.match(s3))return e;let t=Pd(e);if(t===-1)return e;let n=e.substring(t+1);if(!n||rn.test(n))return e;if(k3(e)%2===1){let r=N3(e);return r!==null?r:I3(e)}return e},R3=e=>{let t=ls(e),n=Dd(e);return t%2===0&&n%2===0},O3=(e,t,n)=>!t||rn.test(t)||or(e,n)?!0:us(e,n,"*"),D3=e=>{if(d3.test(e))return e;let t=e.match(i3);if(!t)return e;let n=t[2],r=e.lastIndexOf(t[1]);return O3(e,n,r)?e:x3(e)%2===1?R3(e)?e:`${e}***`:e},ur=(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},P3=(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},M3=e=>{let t=0;for(let n=0;n<e.length;n+=1)e[n]==="`"&&!P3(e,n)&&(t+=1);return t},B3=/<[a-zA-Z/][^>]*$/,F3=e=>{let t=e.match(B3);return!t||t.index===void 0||ur(e,t.index)?e:e.substring(0,t.index).trimEnd()},H3=e=>!e.match(c3)||e.includes(`
|
|
32
|
+
`)?null:e.endsWith("``")&&!e.endsWith("```")?`${e}\``:e,U3=e=>(e.match(/```/g)||[]).length%2===1,z3=e=>{let t=H3(e);if(t!==null)return t;let n=e.match(o3);if(n&&!U3(e)){let r=n[2];if(!r||rn.test(r))return e;if(M3(e)%2===1)return`${e}\``}return e},$3=(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)==="```",Y3=e=>{let t=0,n=!1;for(let r=0;r<e.length-1;r+=1)e[r]==="`"&&!$3(e,r)&&(n=!n),!n&&e[r]==="$"&&e[r+1]==="$"&&(t+=1,r+=1);return t},j3=e=>{let t=e.indexOf("$$");return t!==-1&&e.indexOf(`
|
|
33
33
|
`,t)!==-1&&!e.endsWith(`
|
|
34
34
|
`)?`${e}
|
|
35
|
-
$$`:`${e}$$`},
|
|
36
|
-
`);if(t===-1)return e;let n=e.substring(t+1),r=e.substring(0,t),i=n.trim();if(
|
|
37
|
-
`).at(-1);if(a&&a.trim().length>0)return`${e}`}if(
|
|
38
|
-
`).at(-1);if(a&&a.trim().length>0)return`${e}`}return e},V3=e=>{var t,n;let r=e.match(e3);if(r){let i=r[2];if(!i||rn.test(i))return e;if(((t=e.match(Xo))==null?void 0:t.length)%2===1)return`${e}~~`}else if(e.match(a3)&&((n=e.match(Xo))==null?void 0:n.length)%2===1)return`${e}~`;return e},Yi=e=>e!==!1,Ze={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},q3=[{handler:{name:"comparisonOperators",handle:c3,priority:Ze.COMPARISON_OPERATORS},optionKey:"comparisonOperators"},{handler:{name:"htmlTags",handle:N3,priority:Ze.HTML_TAGS},optionKey:"htmlTags"},{handler:{name:"setextHeadings",handle:j3,priority:Ze.SETEXT_HEADINGS},optionKey:"setextHeadings"},{handler:{name:"links",handle:Dd,priority:Ze.LINKS},optionKey:"links",earlyReturn:e=>e.endsWith("](streamdown:incomplete-link)")},{handler:{name:"boldItalic",handle:C3,priority:Ze.BOLD_ITALIC},optionKey:"boldItalic"},{handler:{name:"bold",handle:g3,priority:Ze.BOLD},optionKey:"bold"},{handler:{name:"italicDoubleUnderscore",handle:E3,priority:Ze.ITALIC_DOUBLE_UNDERSCORE},optionKey:"italic"},{handler:{name:"italicSingleAsterisk",handle:_3,priority:Ze.ITALIC_SINGLE_ASTERISK},optionKey:"italic"},{handler:{name:"italicSingleUnderscore",handle:y3,priority:Ze.ITALIC_SINGLE_UNDERSCORE},optionKey:"italic"},{handler:{name:"inlineCode",handle:O3,priority:Ze.INLINE_CODE},optionKey:"inlineCode"},{handler:{name:"strikethrough",handle:V3,priority:Ze.STRIKETHROUGH},optionKey:"strikethrough"},{handler:{name:"katex",handle:B3,priority:Ze.KATEX},optionKey:"katex"}],W3=e=>{var t;let n=(t=e==null?void 0:e.linkMode)!=null?t:"protocol";return q3.filter(({handler:r,optionKey:i})=>r.name==="links"?Yi(e==null?void 0:e.links)||Yi(e==null?void 0:e.images):Yi(e==null?void 0:e[i])).map(({handler:r,earlyReturn:i})=>r.name==="links"?{handler:vd(Sd({},r),{handle:a=>Dd(a,n)}),earlyReturn:n==="protocol"?i:void 0}:{handler:r,earlyReturn:i})},G3=(e,t)=>{var n;if(!e||typeof e!="string")return e;let r=e.endsWith(" ")&&!e.endsWith(" ")?e.slice(0,-1):e,i=W3(t),a=((n=t==null?void 0:t.handlers)!=null?n:[]).map(o=>{var u;return{handler:vd(Sd({},o),{priority:(u=o.priority)!=null?u:Ze.DEFAULT}),earlyReturn:void 0}}),s=[...i,...a].sort((o,u)=>{var l,h;return((l=o.handler.priority)!=null?l:0)-((h=u.handler.priority)!=null?h:0)});for(let{handler:o,earlyReturn:u}of s)if(r=o.handle(r),u!=null&&u(r))return r;return r},Q3=G3;function Pd(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=Pd(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function K3(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=Pd(e))&&(r&&(r+=" "),r+=t);return r}const X3=(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},Z3=(e,t)=>({classGroupId:e,validator:t}),Md=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),ei="-",eu=[],J3="arbitrary..",eT=e=>{const t=nT(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{if(s.startsWith("[")&&s.endsWith("]"))return tT(s);const o=s.split(ei),u=o[0]===""&&o.length>1?1:0;return Bd(o,u,t)},getConflictingClassGroupIds:(s,o)=>{if(o){const u=r[s],l=n[s];return u?l?X3(l,u):u:l||eu}return n[s]||eu}}},Bd=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const i=e[t],a=n.nextPart.get(i);if(a){const l=Bd(e,t+1,a);if(l)return l}const s=n.validators;if(s===null)return;const o=t===0?e.join(ei):e.slice(t).join(ei),u=s.length;for(let l=0;l<u;l++){const h=s[l];if(h.validator(o))return h.classGroupId}},tT=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?J3+r:void 0})(),nT=e=>{const{theme:t,classGroups:n}=e;return rT(n,t)},rT=(e,t)=>{const n=Md();for(const r in e){const i=e[r];us(i,n,r,t)}return n},us=(e,t,n,r)=>{const i=e.length;for(let a=0;a<i;a++){const s=e[a];iT(s,t,n,r)}},iT=(e,t,n,r)=>{if(typeof e=="string"){aT(e,t,n);return}if(typeof e=="function"){sT(e,t,n,r);return}oT(e,t,n,r)},aT=(e,t,n)=>{const r=e===""?t:Fd(t,e);r.classGroupId=n},sT=(e,t,n,r)=>{if(uT(e)){us(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(Z3(n,e))},oT=(e,t,n,r)=>{const i=Object.entries(e),a=i.length;for(let s=0;s<a;s++){const[o,u]=i[s];us(u,Fd(t,o),n,r)}},Fd=(e,t)=>{let n=e;const r=t.split(ei),i=r.length;for(let a=0;a<i;a++){const s=r[a];let o=n.nextPart.get(s);o||(o=Md(),n.nextPart.set(s,o)),n=o}return n},uT=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,lT=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)}}},Ea="!",tu=":",cT=[],nu=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),dT=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=i=>{const a=[];let s=0,o=0,u=0,l;const h=i.length;for(let _=0;_<h;_++){const x=i[_];if(s===0&&o===0){if(x===tu){a.push(i.slice(u,_)),u=_+1;continue}if(x==="/"){l=_;continue}}x==="["?s++:x==="]"?s--:x==="("?o++:x===")"&&o--}const d=a.length===0?i:i.slice(u);let p=d,f=!1;d.endsWith(Ea)?(p=d.slice(0,-1),f=!0):d.startsWith(Ea)&&(p=d.slice(1),f=!0);const m=l&&l>u?l-u:void 0;return nu(a,f,p,m)};if(t){const i=t+tu,a=r;r=s=>s.startsWith(i)?a(s.slice(i.length)):nu(cT,!1,s,void 0,!0)}if(n){const i=r;r=a=>n({className:a,parseClassName:i})}return r},hT=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}},fT=e=>({cache:lT(e.cacheSize),parseClassName:dT(e),sortModifiers:hT(e),...eT(e)}),pT=/\s+/,mT=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,s=[],o=e.trim().split(pT);let u="";for(let l=o.length-1;l>=0;l-=1){const h=o[l],{isExternal:d,modifiers:p,hasImportantModifier:f,baseClassName:m,maybePostfixModifierPosition:_}=n(h);if(d){u=h+(u.length>0?" "+u:u);continue}let x=!!_,k=r(x?m.substring(0,_):m);if(!k){if(!x){u=h+(u.length>0?" "+u:u);continue}if(k=r(m),!k){u=h+(u.length>0?" "+u:u);continue}x=!1}const v=p.length===0?"":p.length===1?p[0]:a(p).join(":"),C=f?v+Ea:v,R=C+k;if(s.indexOf(R)>-1)continue;s.push(R);const F=i(k,x);for(let S=0;S<F.length;++S){const Y=F[S];s.push(C+Y)}u=h+(u.length>0?" "+u:u)}return u},gT=(...e)=>{let t=0,n,r,i="";for(;t<e.length;)(n=e[t++])&&(r=Hd(n))&&(i&&(i+=" "),i+=r);return i},Hd=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Hd(e[r]))&&(n&&(n+=" "),n+=t);return n},bT=(e,...t)=>{let n,r,i,a;const s=u=>{const l=t.reduce((h,d)=>d(h),e());return n=fT(l),r=n.cache.get,i=n.cache.set,a=o,o(u)},o=u=>{const l=r(u);if(l)return l;const h=mT(u,n);return i(u,h),h};return a=s,(...u)=>a(gT(...u))},ET=[],Oe=e=>{const t=n=>n[e]||ET;return t.isThemeGetter=!0,t},Ud=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,zd=/^\((?:(\w[\w-]*):)?(.+)\)$/i,TT=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,_T=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,kT=/\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$/,xT=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,yT=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,wT=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,St=e=>TT.test(e),ie=e=>!!e&&!Number.isNaN(Number(e)),vt=e=>!!e&&Number.isInteger(Number(e)),ji=e=>e.endsWith("%")&&ie(e.slice(0,-1)),xt=e=>_T.test(e),$d=()=>!0,AT=e=>kT.test(e)&&!xT.test(e),ls=()=>!1,CT=e=>yT.test(e),ST=e=>wT.test(e),vT=e=>!j(e)&&!V(e),IT=e=>zt(e,Vd,ls),j=e=>Ud.test(e),Vt=e=>zt(e,qd,AT),ru=e=>zt(e,BT,ie),NT=e=>zt(e,Gd,$d),LT=e=>zt(e,Wd,ls),iu=e=>zt(e,Yd,ls),RT=e=>zt(e,jd,ST),wr=e=>zt(e,Qd,CT),V=e=>zd.test(e),Pn=e=>an(e,qd),OT=e=>an(e,Wd),au=e=>an(e,Yd),DT=e=>an(e,Vd),PT=e=>an(e,jd),Ar=e=>an(e,Qd,!0),MT=e=>an(e,Gd,!0),zt=(e,t,n)=>{const r=Ud.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},an=(e,t,n=!1)=>{const r=zd.exec(e);return r?r[1]?t(r[1]):n:!1},Yd=e=>e==="position"||e==="percentage",jd=e=>e==="image"||e==="url",Vd=e=>e==="length"||e==="size"||e==="bg-size",qd=e=>e==="length",BT=e=>e==="number",Wd=e=>e==="family-name",Gd=e=>e==="number"||e==="weight",Qd=e=>e==="shadow",FT=()=>{const e=Oe("color"),t=Oe("font"),n=Oe("text"),r=Oe("font-weight"),i=Oe("tracking"),a=Oe("leading"),s=Oe("breakpoint"),o=Oe("container"),u=Oe("spacing"),l=Oe("radius"),h=Oe("shadow"),d=Oe("inset-shadow"),p=Oe("text-shadow"),f=Oe("drop-shadow"),m=Oe("blur"),_=Oe("perspective"),x=Oe("aspect"),k=Oe("ease"),v=Oe("animate"),C=()=>["auto","avoid","all","avoid-page","page","left","right","column"],R=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],F=()=>[...R(),V,j],S=()=>["auto","hidden","clip","visible","scroll"],Y=()=>["auto","contain","none"],L=()=>[V,j,u],D=()=>[St,"full","auto",...L()],A=()=>[vt,"none","subgrid",V,j],z=()=>["auto",{span:["full",vt,V,j]},vt,V,j],P=()=>[vt,"auto",V,j],Q=()=>["auto","min","max","fr",V,j],ue=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],J=()=>["start","end","center","stretch","center-safe","end-safe"],oe=()=>["auto",...L()],q=()=>[St,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...L()],K=()=>[St,"screen","full","dvw","lvw","svw","min","max","fit",...L()],W=()=>[St,"screen","full","lh","dvh","lvh","svh","min","max","fit",...L()],E=()=>[e,V,j],he=()=>[...R(),au,iu,{position:[V,j]}],Z=()=>["no-repeat",{repeat:["","x","y","space","round"]}],w=()=>["auto","cover","contain",DT,IT,{size:[V,j]}],Se=()=>[ji,Pn,Vt],pe=()=>["","none","full",l,V,j],ne=()=>["",ie,Pn,Vt],Ue=()=>["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"],me=()=>[ie,ji,au,iu],st=()=>["","none",m,V,j],nt=()=>["none",ie,V,j],rt=()=>["none",ie,V,j],vn=()=>[ie,V,j],on=()=>[St,"full",...L()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[xt],breakpoint:[xt],color:[$d],container:[xt],"drop-shadow":[xt],ease:["in","out","in-out"],font:[vT],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[xt],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[xt],shadow:[xt],spacing:["px",ie],text:[xt],"text-shadow":[xt],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",St,j,V,x]}],container:["container"],columns:[{columns:[ie,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:F()}],overflow:[{overflow:S()}],"overflow-x":[{"overflow-x":S()}],"overflow-y":[{"overflow-y":S()}],overscroll:[{overscroll:Y()}],"overscroll-x":[{"overscroll-x":Y()}],"overscroll-y":[{"overscroll-y":Y()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:D()}],"inset-x":[{"inset-x":D()}],"inset-y":[{"inset-y":D()}],start:[{"inset-s":D(),start:D()}],end:[{"inset-e":D(),end:D()}],"inset-bs":[{"inset-bs":D()}],"inset-be":[{"inset-be":D()}],top:[{top:D()}],right:[{right:D()}],bottom:[{bottom:D()}],left:[{left:D()}],visibility:["visible","invisible","collapse"],z:[{z:[vt,"auto",V,j]}],basis:[{basis:[St,"full","auto",o,...L()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[ie,St,"auto","initial","none",j]}],grow:[{grow:["",ie,V,j]}],shrink:[{shrink:["",ie,V,j]}],order:[{order:[vt,"first","last","none",V,j]}],"grid-cols":[{"grid-cols":A()}],"col-start-end":[{col:z()}],"col-start":[{"col-start":P()}],"col-end":[{"col-end":P()}],"grid-rows":[{"grid-rows":A()}],"row-start-end":[{row:z()}],"row-start":[{"row-start":P()}],"row-end":[{"row-end":P()}],"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:[...ue(),"normal"]}],"justify-items":[{"justify-items":[...J(),"normal"]}],"justify-self":[{"justify-self":["auto",...J()]}],"align-content":[{content:["normal",...ue()]}],"align-items":[{items:[...J(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...J(),{baseline:["","last"]}]}],"place-content":[{"place-content":ue()}],"place-items":[{"place-items":[...J(),"baseline"]}],"place-self":[{"place-self":["auto",...J()]}],p:[{p:L()}],px:[{px:L()}],py:[{py:L()}],ps:[{ps:L()}],pe:[{pe:L()}],pbs:[{pbs:L()}],pbe:[{pbe:L()}],pt:[{pt:L()}],pr:[{pr:L()}],pb:[{pb:L()}],pl:[{pl:L()}],m:[{m:oe()}],mx:[{mx:oe()}],my:[{my:oe()}],ms:[{ms:oe()}],me:[{me:oe()}],mbs:[{mbs:oe()}],mbe:[{mbe:oe()}],mt:[{mt:oe()}],mr:[{mr:oe()}],mb:[{mb:oe()}],ml:[{ml:oe()}],"space-x":[{"space-x":L()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":L()}],"space-y-reverse":["space-y-reverse"],size:[{size:q()}],"inline-size":[{inline:["auto",...K()]}],"min-inline-size":[{"min-inline":["auto",...K()]}],"max-inline-size":[{"max-inline":["none",...K()]}],"block-size":[{block:["auto",...W()]}],"min-block-size":[{"min-block":["auto",...W()]}],"max-block-size":[{"max-block":["none",...W()]}],w:[{w:[o,"screen",...q()]}],"min-w":[{"min-w":[o,"screen","none",...q()]}],"max-w":[{"max-w":[o,"screen","none","prose",{screen:[s]},...q()]}],h:[{h:["screen","lh",...q()]}],"min-h":[{"min-h":["screen","lh","none",...q()]}],"max-h":[{"max-h":["screen","lh",...q()]}],"font-size":[{text:["base",n,Pn,Vt]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,MT,NT]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",ji,j]}],"font-family":[{font:[OT,LT,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":[ie,"none",V,ru]}],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:E()}],"text-color":[{text:E()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...Ue(),"wavy"]}],"text-decoration-thickness":[{decoration:[ie,"from-font","auto",V,Vt]}],"text-decoration-color":[{decoration:E()}],"underline-offset":[{"underline-offset":[ie,"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:he()}],"bg-repeat":[{bg:Z()}],"bg-size":[{bg:w()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},vt,V,j],radial:["",V,j],conic:[vt,V,j]},PT,RT]}],"bg-color":[{bg:E()}],"gradient-from-pos":[{from:Se()}],"gradient-via-pos":[{via:Se()}],"gradient-to-pos":[{to:Se()}],"gradient-from":[{from:E()}],"gradient-via":[{via:E()}],"gradient-to":[{to:E()}],rounded:[{rounded:pe()}],"rounded-s":[{"rounded-s":pe()}],"rounded-e":[{"rounded-e":pe()}],"rounded-t":[{"rounded-t":pe()}],"rounded-r":[{"rounded-r":pe()}],"rounded-b":[{"rounded-b":pe()}],"rounded-l":[{"rounded-l":pe()}],"rounded-ss":[{"rounded-ss":pe()}],"rounded-se":[{"rounded-se":pe()}],"rounded-ee":[{"rounded-ee":pe()}],"rounded-es":[{"rounded-es":pe()}],"rounded-tl":[{"rounded-tl":pe()}],"rounded-tr":[{"rounded-tr":pe()}],"rounded-br":[{"rounded-br":pe()}],"rounded-bl":[{"rounded-bl":pe()}],"border-w":[{border:ne()}],"border-w-x":[{"border-x":ne()}],"border-w-y":[{"border-y":ne()}],"border-w-s":[{"border-s":ne()}],"border-w-e":[{"border-e":ne()}],"border-w-bs":[{"border-bs":ne()}],"border-w-be":[{"border-be":ne()}],"border-w-t":[{"border-t":ne()}],"border-w-r":[{"border-r":ne()}],"border-w-b":[{"border-b":ne()}],"border-w-l":[{"border-l":ne()}],"divide-x":[{"divide-x":ne()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":ne()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...Ue(),"hidden","none"]}],"divide-style":[{divide:[...Ue(),"hidden","none"]}],"border-color":[{border:E()}],"border-color-x":[{"border-x":E()}],"border-color-y":[{"border-y":E()}],"border-color-s":[{"border-s":E()}],"border-color-e":[{"border-e":E()}],"border-color-bs":[{"border-bs":E()}],"border-color-be":[{"border-be":E()}],"border-color-t":[{"border-t":E()}],"border-color-r":[{"border-r":E()}],"border-color-b":[{"border-b":E()}],"border-color-l":[{"border-l":E()}],"divide-color":[{divide:E()}],"outline-style":[{outline:[...Ue(),"none","hidden"]}],"outline-offset":[{"outline-offset":[ie,V,j]}],"outline-w":[{outline:["",ie,Pn,Vt]}],"outline-color":[{outline:E()}],shadow:[{shadow:["","none",h,Ar,wr]}],"shadow-color":[{shadow:E()}],"inset-shadow":[{"inset-shadow":["none",d,Ar,wr]}],"inset-shadow-color":[{"inset-shadow":E()}],"ring-w":[{ring:ne()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:E()}],"ring-offset-w":[{"ring-offset":[ie,Vt]}],"ring-offset-color":[{"ring-offset":E()}],"inset-ring-w":[{"inset-ring":ne()}],"inset-ring-color":[{"inset-ring":E()}],"text-shadow":[{"text-shadow":["none",p,Ar,wr]}],"text-shadow-color":[{"text-shadow":E()}],opacity:[{opacity:[ie,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":[ie]}],"mask-image-linear-from-pos":[{"mask-linear-from":me()}],"mask-image-linear-to-pos":[{"mask-linear-to":me()}],"mask-image-linear-from-color":[{"mask-linear-from":E()}],"mask-image-linear-to-color":[{"mask-linear-to":E()}],"mask-image-t-from-pos":[{"mask-t-from":me()}],"mask-image-t-to-pos":[{"mask-t-to":me()}],"mask-image-t-from-color":[{"mask-t-from":E()}],"mask-image-t-to-color":[{"mask-t-to":E()}],"mask-image-r-from-pos":[{"mask-r-from":me()}],"mask-image-r-to-pos":[{"mask-r-to":me()}],"mask-image-r-from-color":[{"mask-r-from":E()}],"mask-image-r-to-color":[{"mask-r-to":E()}],"mask-image-b-from-pos":[{"mask-b-from":me()}],"mask-image-b-to-pos":[{"mask-b-to":me()}],"mask-image-b-from-color":[{"mask-b-from":E()}],"mask-image-b-to-color":[{"mask-b-to":E()}],"mask-image-l-from-pos":[{"mask-l-from":me()}],"mask-image-l-to-pos":[{"mask-l-to":me()}],"mask-image-l-from-color":[{"mask-l-from":E()}],"mask-image-l-to-color":[{"mask-l-to":E()}],"mask-image-x-from-pos":[{"mask-x-from":me()}],"mask-image-x-to-pos":[{"mask-x-to":me()}],"mask-image-x-from-color":[{"mask-x-from":E()}],"mask-image-x-to-color":[{"mask-x-to":E()}],"mask-image-y-from-pos":[{"mask-y-from":me()}],"mask-image-y-to-pos":[{"mask-y-to":me()}],"mask-image-y-from-color":[{"mask-y-from":E()}],"mask-image-y-to-color":[{"mask-y-to":E()}],"mask-image-radial":[{"mask-radial":[V,j]}],"mask-image-radial-from-pos":[{"mask-radial-from":me()}],"mask-image-radial-to-pos":[{"mask-radial-to":me()}],"mask-image-radial-from-color":[{"mask-radial-from":E()}],"mask-image-radial-to-color":[{"mask-radial-to":E()}],"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":R()}],"mask-image-conic-pos":[{"mask-conic":[ie]}],"mask-image-conic-from-pos":[{"mask-conic-from":me()}],"mask-image-conic-to-pos":[{"mask-conic-to":me()}],"mask-image-conic-from-color":[{"mask-conic-from":E()}],"mask-image-conic-to-color":[{"mask-conic-to":E()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:he()}],"mask-repeat":[{mask:Z()}],"mask-size":[{mask:w()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",V,j]}],filter:[{filter:["","none",V,j]}],blur:[{blur:st()}],brightness:[{brightness:[ie,V,j]}],contrast:[{contrast:[ie,V,j]}],"drop-shadow":[{"drop-shadow":["","none",f,Ar,wr]}],"drop-shadow-color":[{"drop-shadow":E()}],grayscale:[{grayscale:["",ie,V,j]}],"hue-rotate":[{"hue-rotate":[ie,V,j]}],invert:[{invert:["",ie,V,j]}],saturate:[{saturate:[ie,V,j]}],sepia:[{sepia:["",ie,V,j]}],"backdrop-filter":[{"backdrop-filter":["","none",V,j]}],"backdrop-blur":[{"backdrop-blur":st()}],"backdrop-brightness":[{"backdrop-brightness":[ie,V,j]}],"backdrop-contrast":[{"backdrop-contrast":[ie,V,j]}],"backdrop-grayscale":[{"backdrop-grayscale":["",ie,V,j]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[ie,V,j]}],"backdrop-invert":[{"backdrop-invert":["",ie,V,j]}],"backdrop-opacity":[{"backdrop-opacity":[ie,V,j]}],"backdrop-saturate":[{"backdrop-saturate":[ie,V,j]}],"backdrop-sepia":[{"backdrop-sepia":["",ie,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:[ie,"initial",V,j]}],ease:[{ease:["linear","initial",k,V,j]}],delay:[{delay:[ie,V,j]}],animate:[{animate:["none",v,V,j]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[_,V,j]}],"perspective-origin":[{"perspective-origin":F()}],rotate:[{rotate:nt()}],"rotate-x":[{"rotate-x":nt()}],"rotate-y":[{"rotate-y":nt()}],"rotate-z":[{"rotate-z":nt()}],scale:[{scale:rt()}],"scale-x":[{"scale-x":rt()}],"scale-y":[{"scale-y":rt()}],"scale-z":[{"scale-z":rt()}],"scale-3d":["scale-3d"],skew:[{skew:vn()}],"skew-x":[{"skew-x":vn()}],"skew-y":[{"skew-y":vn()}],transform:[{transform:[V,j,"","none","gpu","cpu"]}],"transform-origin":[{origin:F()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:on()}],"translate-x":[{"translate-x":on()}],"translate-y":[{"translate-y":on()}],"translate-z":[{"translate-z":on()}],"translate-none":["translate-none"],accent:[{accent:E()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:E()}],"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-mbs":[{"scroll-mbs":L()}],"scroll-mbe":[{"scroll-mbe":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-pbs":[{"scroll-pbs":L()}],"scroll-pbe":[{"scroll-pbe":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",...E()]}],"stroke-w":[{stroke:[ie,Pn,Vt,ru]}],stroke:[{stroke:["none",...E()]}],"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"]}},HT=bT(FT),UT=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,zT=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,$T={};function su(e,t){return((t||$T).jsx?zT:UT).test(e)}const YT=/[ \t\n\f\r]/g;function jT(e){return typeof e=="object"?e.type==="text"?ou(e.value):!1:ou(e)}function ou(e){return e.replace(YT,"")===""}var ti=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Kd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var cs={},uu=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,VT=/\n/g,qT=/^\s*/,WT=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,GT=/^:\s*/,QT=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,KT=/^[;\s]*/,XT=/^\s+|\s+$/g,ZT=`
|
|
39
|
-
`,lu="/",cu="*",Wt="",JT="comment",e_="declaration";function t_(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(VT);_&&(n+=_.length);var x=m.lastIndexOf(ZT);r=~x?m.length-x:r+m.length}function a(){var m={line:n,column:r};return function(_){return _.position=new s(m),l(),_}}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 x=_[0];return i(x),e=e.slice(x.length),_}}function l(){u(qT)}function h(m){var _;for(m=m||[];_=d();)_!==!1&&m.push(_);return m}function d(){var m=a();if(!(lu!=e.charAt(0)||cu!=e.charAt(1))){for(var _=2;Wt!=e.charAt(_)&&(cu!=e.charAt(_)||lu!=e.charAt(_+1));)++_;if(_+=2,Wt===e.charAt(_-1))return o("End of comment missing");var x=e.slice(2,_-2);return r+=2,i(x),e=e.slice(_),r+=2,m({type:JT,comment:x})}}function p(){var m=a(),_=u(WT);if(_){if(d(),!u(GT))return o("property missing ':'");var x=u(QT),k=m({type:e_,property:du(_[0].replace(uu,Wt)),value:x?du(x[0].replace(uu,Wt)):Wt});return u(KT),k}}function f(){var m=[];h(m);for(var _;_=p();)_!==!1&&(m.push(_),h(m));return m}return l(),f()}function du(e){return e?e.replace(XT,Wt):Wt}var n_=t_,r_=ti&&ti.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(cs,"__esModule",{value:!0});cs.default=a_;const i_=r_(n_);function a_(e,t){let n=null;if(!e||typeof e!="string")return n;const r=(0,i_.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 yi={};Object.defineProperty(yi,"__esModule",{value:!0});yi.camelCase=void 0;var s_=/^--[a-zA-Z0-9_-]+$/,o_=/-([a-z])/g,u_=/^[^-]+$/,l_=/^-(webkit|moz|ms|o|khtml)-/,c_=/^-(ms)-/,d_=function(e){return!e||u_.test(e)||s_.test(e)},h_=function(e,t){return t.toUpperCase()},hu=function(e,t){return"".concat(t,"-")},f_=function(e,t){return t===void 0&&(t={}),d_(e)?e:(e=e.toLowerCase(),t.reactCompat?e=e.replace(c_,hu):e=e.replace(l_,hu),e.replace(o_,h_))};yi.camelCase=f_;var p_=ti&&ti.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},m_=p_(cs),g_=yi;function Ta(e,t){var n={};return!e||typeof e!="string"||(0,m_.default)(e,function(r,i){r&&i&&(n[(0,g_.camelCase)(r,t)]=i)}),n}Ta.default=Ta;var b_=Ta;const E_=Kd(b_);function Jn(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?fu(e.position):"start"in e||"end"in e?fu(e):"line"in e||"column"in e?_a(e):""}function _a(e){return pu(e&&e.line)+":"+pu(e&&e.column)}function fu(e){return _a(e&&e.start)+"-"+_a(e&&e.end)}function pu(e){return e&&typeof e=="number"?e:1}class He 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=Jn(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}}He.prototype.file="";He.prototype.name="";He.prototype.reason="";He.prototype.message="";He.prototype.stack="";He.prototype.column=void 0;He.prototype.line=void 0;He.prototype.ancestors=void 0;He.prototype.cause=void 0;He.prototype.fatal=void 0;He.prototype.place=void 0;He.prototype.ruleId=void 0;He.prototype.source=void 0;const ds={}.hasOwnProperty,T_=new Map,__=/[A-Z]/g,k_=new Set(["table","tbody","thead","tfoot","tr"]),x_=new Set(["td","th"]),Xd="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function y_(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=L_(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=N_(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"?Ht:fr,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=Zd(i,e,void 0);return a&&typeof a!="string"?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function Zd(e,t,n){if(t.type==="element")return w_(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return A_(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return S_(e,t,n);if(t.type==="mdxjsEsm")return C_(e,t);if(t.type==="root")return v_(e,t,n);if(t.type==="text")return I_(e,t)}function w_(e,t,n){const r=e.schema;let i=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=Ht,e.schema=i),e.ancestors.push(t);const a=e0(e,t.tagName,!1),s=R_(e,t);let o=fs(e,t);return k_.has(t.tagName)&&(o=o.filter(function(u){return typeof u=="string"?!jT(u):!0})),Jd(e,s,a,t),hs(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function A_(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return e.evaluater.evaluateExpression(r.expression)}lr(e,t.position)}function C_(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);lr(e,t.position)}function S_(e,t,n){const r=e.schema;let i=r;t.name==="svg"&&r.space==="html"&&(i=Ht,e.schema=i),e.ancestors.push(t);const a=t.name===null?e.Fragment:e0(e,t.name,!0),s=O_(e,t),o=fs(e,t);return Jd(e,s,a,t),hs(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function v_(e,t,n){const r={};return hs(r,fs(e,t)),e.create(t,e.Fragment,r,n)}function I_(e,t){return t.value}function Jd(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function hs(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function N_(e,t,n){return r;function r(i,a,s,o){const l=Array.isArray(s.children)?n:t;return o?l(a,s,o):l(a,s)}}function L_(e,t){return n;function n(r,i,a,s){const o=Array.isArray(a.children),u=Et(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 R_(e,t){const n={};let r,i;for(i in t.properties)if(i!=="children"&&ds.call(t.properties,i)){const a=D_(e,i,t.properties[i]);if(a){const[s,o]=a;e.tableCellAlignToStyle&&s==="align"&&typeof o=="string"&&x_.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 O_(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 lr(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 lr(e,t.position);else a=r.value===null?!0:r.value;n[i]=a}return n}function fs(e,t){const n=[];let r=-1;const i=e.passKeys?new Map:T_;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 l=i.get(u)||0;s=u+"-"+l,i.set(u,l+1)}}const o=Zd(e,a,s);o!==void 0&&n.push(o)}return n}function D_(e,t,n){const r=pi(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?ic(n):ac(n)),r.property==="style"){let i=typeof n=="object"?n:P_(e,String(n));return e.stylePropertyNameCase==="css"&&(i=M_(i)),["style",i]}return[e.elementAttributeNameCase==="react"&&r.space?Ff[r.property]||r.property:r.attribute,n]}}function P_(e,t){try{return E_(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,i=new He("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=Xd+"#cannot-parse-style-attribute",i}}function e0(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=su(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=su(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const i=r.value;return ds.call(e.components,i)?e.components[i]:i}if(e.evaluater)return e.evaluater.evaluateExpression(r);lr(e)}function lr(e,t){const n=new He("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=Xd+"#cannot-handle-mdx-estrees-without-createevaluater",n}function M_(e){const t={};let n;for(n in e)ds.call(e,n)&&(t[B_(n)]=e[n]);return t}function B_(e){let t=e.replace(__,F_);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function F_(e){return"-"+e.toLowerCase()}const Vi={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"]},H_={tokenize:U_};function U_(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"),ce(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 X(o)?(e.consume(o),e.exit("chunkText"),a):(e.consume(o),s)}}const z_={tokenize:$_},mu={tokenize:Y_};function $_(e){const t=this,n=[];let r=0,i,a,s;return o;function o(C){if(r<n.length){const R=n[r];return t.containerState=R[1],e.attempt(R[0].continuation,u,l)(C)}return l(C)}function u(C){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&v();const R=t.events.length;let F=R,S;for(;F--;)if(t.events[F][0]==="exit"&&t.events[F][1].type==="chunkFlow"){S=t.events[F][1].end;break}k(r);let Y=R;for(;Y<t.events.length;)t.events[Y][1].end={...S},Y++;return Je(t.events,F+1,0,t.events.slice(R)),t.events.length=Y,l(C)}return o(C)}function l(C){if(r===n.length){if(!i)return p(C);if(i.currentConstruct&&i.currentConstruct.concrete)return m(C);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(mu,h,d)(C)}function h(C){return i&&v(),k(r),p(C)}function d(C){return t.parser.lazy[t.now().line]=r!==n.length,s=t.now().offset,m(C)}function p(C){return t.containerState={},e.attempt(mu,f,m)(C)}function f(C){return r++,n.push([t.currentConstruct,t.containerState]),p(C)}function m(C){if(C===null){i&&v(),k(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){x(e.exit("chunkFlow"),!0),k(0),e.consume(C);return}return X(C)?(e.consume(C),x(e.exit("chunkFlow")),r=0,t.interrupt=void 0,o):(e.consume(C),_)}function x(C,R){const F=t.sliceStream(C);if(R&&F.push(null),C.previous=a,a&&(a.next=C),a=C,i.defineSkip(C.start),i.write(F),t.parser.lazy[C.start.line]){let S=i.events.length;for(;S--;)if(i.events[S][1].start.offset<s&&(!i.events[S][1].end||i.events[S][1].end.offset>s))return;const Y=t.events.length;let L=Y,D,A;for(;L--;)if(t.events[L][0]==="exit"&&t.events[L][1].type==="chunkFlow"){if(D){A=t.events[L][1].end;break}D=!0}for(k(r),S=Y;S<t.events.length;)t.events[S][1].end={...A},S++;Je(t.events,L+1,0,t.events.slice(Y)),t.events.length=S}}function k(C){let R=n.length;for(;R-- >C;){const F=n[R];t.containerState=F[1],F[0].exit.call(t,e)}n.length=C}function v(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function Y_(e,t,n){return ce(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}const j_={tokenize:V_};function V_(e){const t=this,n=e.attempt(br,r,e.attempt(this.parser.constructs.flowInitial,i,ce(e,e.attempt(this.parser.constructs.flow,i,e.attempt(C2,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 q_={resolveAll:n0()},W_=t0("string"),G_=t0("text");function t0(e){return{resolveAll:n0(e==="text"?Q_: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(h){return l(h)?a(h):o(h)}function o(h){if(h===null){n.consume(h);return}return n.enter("data"),n.consume(h),u}function u(h){return l(h)?(n.exit("data"),a(h)):(n.consume(h),u)}function l(h){if(h===null)return!0;const d=i[h];let p=-1;if(d)for(;++p<d.length;){const f=d[p];if(!f.previous||f.previous.call(r,r.previous))return!0}return!1}}}function n0(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 Q_(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 l=i[a];if(typeof l=="string"){for(s=l.length;l.charCodeAt(s-1)===32;)o++,s--;if(s)break;s=-1}else if(l===-2)u=!0,o++;else if(l!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(o=0),o){const l={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={...l.start},r.start.offset===r.end.offset?Object.assign(r,l):(e.splice(n,0,["enter",l,t],["exit",l,t]),n+=2)}n++}return e}const K_={42:qe,43:qe,45:qe,48:qe,49:qe,50:qe,51:qe,52:qe,53:qe,54:qe,55:qe,56:qe,57:qe,62:_d},X_={91:L2},Z_={[-2]:zi,[-1]:zi,32:zi},J_={35:B2,42:Fr,45:[Wo,Fr],60:z2,61:Wo,95:Fr,96:Vo,126:Vo},ek={38:xd,92:kd},tk={[-5]:$i,[-4]:$i,[-3]:$i,33:aE,38:xd,42:ba,60:[o2,G2],91:oE,92:[P2,kd],93:as,95:ba,96:_2},nk={null:[ba,q_]},rk={null:[42,95]},ik={null:[]},ak=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:rk,contentInitial:X_,disable:ik,document:K_,flow:J_,flowInitial:Z_,insideSpan:nk,string:ek,text:tk},Symbol.toStringTag,{value:"Module"}));function sk(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:Y(F),check:Y(S),consume:v,enter:C,exit:R,interrupt:Y(S,{interrupt:!0})},l={code:null,containerState:{},defineSkip:_,events:[],now:m,parser:e,previous:null,sliceSerialize:p,sliceStream:f,write:d};let h=t.tokenize.call(l,u);return t.resolveAll&&a.push(t),l;function d(z){return s=at(s,z),x(),s[s.length-1]!==null?[]:(L(t,0),l.events=ki(a,l.events,l),l.events)}function p(z,P){return uk(f(z),P)}function f(z){return ok(s,z)}function m(){const{_bufferIndex:z,_index:P,line:Q,column:ue,offset:J}=r;return{_bufferIndex:z,_index:P,line:Q,column:ue,offset:J}}function _(z){i[z.line]=z.column,A()}function x(){let z;for(;r._index<s.length;){const P=s[r._index];if(typeof P=="string")for(z=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===z&&r._bufferIndex<P.length;)k(P.charCodeAt(r._bufferIndex));else k(P)}}function k(z){h=h(z)}function v(z){X(z)?(r.line++,r.column=1,r.offset+=z===-3?2:1,A()):z!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===s[r._index].length&&(r._bufferIndex=-1,r._index++)),l.previous=z}function C(z,P){const Q=P||{};return Q.type=z,Q.start=m(),l.events.push(["enter",Q,l]),o.push(Q),Q}function R(z){const P=o.pop();return P.end=m(),l.events.push(["exit",P,l]),P}function F(z,P){L(z,P.from)}function S(z,P){P.restore()}function Y(z,P){return Q;function Q(ue,J,oe){let q,K,W,E;return Array.isArray(ue)?Z(ue):"tokenize"in ue?Z([ue]):he(ue);function he(ne){return Ue;function Ue(je){const me=je!==null&&ne[je],st=je!==null&&ne.null,nt=[...Array.isArray(me)?me:me?[me]:[],...Array.isArray(st)?st:st?[st]:[]];return Z(nt)(je)}}function Z(ne){return q=ne,K=0,ne.length===0?oe:w(ne[K])}function w(ne){return Ue;function Ue(je){return E=D(),W=ne,ne.partial||(l.currentConstruct=ne),ne.name&&l.parser.constructs.disable.null.includes(ne.name)?pe():ne.tokenize.call(P?Object.assign(Object.create(l),P):l,u,Se,pe)(je)}}function Se(ne){return z(W,E),J}function pe(ne){return E.restore(),++K<q.length?w(q[K]):oe}}}function L(z,P){z.resolveAll&&!a.includes(z)&&a.push(z),z.resolve&&Je(l.events,P,l.events.length-P,z.resolve(l.events.slice(P),l)),z.resolveTo&&(l.events=z.resolveTo(l.events,l))}function D(){const z=m(),P=l.previous,Q=l.currentConstruct,ue=l.events.length,J=Array.from(o);return{from:ue,restore:oe};function oe(){r=z,l.previous=P,l.currentConstruct=Q,l.events.length=ue,o=J,A()}}function A(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function ok(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 uk(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}$$`},V3=e=>Y3(e)%2===0?e:j3(e),q3=(e,t,n)=>{if(e.substring(t+2).includes(")"))return null;let r=p3(e,t);if(r===-1||ur(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)`},tu=(e,t)=>{for(let n=0;n<t;n++)if(e[n]==="["&&!ur(e,n)){if(n>0&&e[n-1]==="!")continue;let r=Rd(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},W3=(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=tu(e,t);return e.substring(0,s)+e.substring(s+1)}return`${e}](streamdown:incomplete-link)`}if(Rd(e,t)===-1){let a=e.substring(0,i);if(r)return a;if(n==="text-only"){let s=tu(e,t);return e.substring(0,s)+e.substring(s+1)}return`${e}](streamdown:incomplete-link)`}return null},Md=(e,t="protocol")=>{let n=e.lastIndexOf("](");if(n!==-1&&!ur(e,n)){let r=q3(e,n,t);if(r!==null)return r}for(let r=e.length-1;r>=0;r-=1)if(e[r]==="["&&!ur(e,r)){let i=W3(e,r,t);if(i!==null)return i}return e},G3=/^-{1,2}$/,Q3=/^[\s]*-{1,2}[\s]+$/,K3=/^={1,2}$/,X3=/^[\s]*={1,2}[\s]+$/,Z3=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(G3.test(i)&&!n.match(Q3)){let a=r.split(`
|
|
37
|
+
`).at(-1);if(a&&a.trim().length>0)return`${e}`}if(K3.test(i)&&!n.match(X3)){let a=r.split(`
|
|
38
|
+
`).at(-1);if(a&&a.trim().length>0)return`${e}`}return e},J3=e=>{var t,n;let r=e.match(u3);if(r){let i=r[2];if(!i||rn.test(i))return e;if(((t=e.match(Jo))==null?void 0:t.length)%2===1)return`${e}~~`}else if(e.match(f3)&&((n=e.match(Jo))==null?void 0:n.length)%2===1)return`${e}~`;return e},Vi=e=>e!==!1,Ze={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},eT=[{handler:{name:"comparisonOperators",handle:E3,priority:Ze.COMPARISON_OPERATORS},optionKey:"comparisonOperators"},{handler:{name:"htmlTags",handle:F3,priority:Ze.HTML_TAGS},optionKey:"htmlTags"},{handler:{name:"setextHeadings",handle:Z3,priority:Ze.SETEXT_HEADINGS},optionKey:"setextHeadings"},{handler:{name:"links",handle:Md,priority:Ze.LINKS},optionKey:"links",earlyReturn:e=>e.endsWith("](streamdown:incomplete-link)")},{handler:{name:"boldItalic",handle:D3,priority:Ze.BOLD_ITALIC},optionKey:"boldItalic"},{handler:{name:"bold",handle:w3,priority:Ze.BOLD},optionKey:"bold"},{handler:{name:"italicDoubleUnderscore",handle:C3,priority:Ze.ITALIC_DOUBLE_UNDERSCORE},optionKey:"italic"},{handler:{name:"italicSingleAsterisk",handle:v3,priority:Ze.ITALIC_SINGLE_ASTERISK},optionKey:"italic"},{handler:{name:"italicSingleUnderscore",handle:L3,priority:Ze.ITALIC_SINGLE_UNDERSCORE},optionKey:"italic"},{handler:{name:"inlineCode",handle:z3,priority:Ze.INLINE_CODE},optionKey:"inlineCode"},{handler:{name:"strikethrough",handle:J3,priority:Ze.STRIKETHROUGH},optionKey:"strikethrough"},{handler:{name:"katex",handle:V3,priority:Ze.KATEX},optionKey:"katex"}],tT=e=>{var t;let n=(t=e==null?void 0:e.linkMode)!=null?t:"protocol";return eT.filter(({handler:r,optionKey:i})=>r.name==="links"?Vi(e==null?void 0:e.links)||Vi(e==null?void 0:e.images):Vi(e==null?void 0:e[i])).map(({handler:r,earlyReturn:i})=>r.name==="links"?{handler:Nd(Id({},r),{handle:a=>Md(a,n)}),earlyReturn:n==="protocol"?i:void 0}:{handler:r,earlyReturn:i})},nT=(e,t)=>{var n;if(!e||typeof e!="string")return e;let r=e.endsWith(" ")&&!e.endsWith(" ")?e.slice(0,-1):e,i=tT(t),a=((n=t==null?void 0:t.handlers)!=null?n:[]).map(o=>{var u;return{handler:Nd(Id({},o),{priority:(u=o.priority)!=null?u:Ze.DEFAULT}),earlyReturn:void 0}}),s=[...i,...a].sort((o,u)=>{var l,h;return((l=o.handler.priority)!=null?l:0)-((h=u.handler.priority)!=null?h:0)});for(let{handler:o,earlyReturn:u}of s)if(r=o.handle(r),u!=null&&u(r))return r;return r},rT=nT;function Bd(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=Bd(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function iT(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=Bd(e))&&(r&&(r+=" "),r+=t);return r}const aT=(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},sT=(e,t)=>({classGroupId:e,validator:t}),Fd=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),ti="-",nu=[],oT="arbitrary..",uT=e=>{const t=cT(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{if(s.startsWith("[")&&s.endsWith("]"))return lT(s);const o=s.split(ti),u=o[0]===""&&o.length>1?1:0;return Hd(o,u,t)},getConflictingClassGroupIds:(s,o)=>{if(o){const u=r[s],l=n[s];return u?l?aT(l,u):u:l||nu}return n[s]||nu}}},Hd=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const i=e[t],a=n.nextPart.get(i);if(a){const l=Hd(e,t+1,a);if(l)return l}const s=n.validators;if(s===null)return;const o=t===0?e.join(ti):e.slice(t).join(ti),u=s.length;for(let l=0;l<u;l++){const h=s[l];if(h.validator(o))return h.classGroupId}},lT=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?oT+r:void 0})(),cT=e=>{const{theme:t,classGroups:n}=e;return dT(n,t)},dT=(e,t)=>{const n=Fd();for(const r in e){const i=e[r];cs(i,n,r,t)}return n},cs=(e,t,n,r)=>{const i=e.length;for(let a=0;a<i;a++){const s=e[a];hT(s,t,n,r)}},hT=(e,t,n,r)=>{if(typeof e=="string"){fT(e,t,n);return}if(typeof e=="function"){pT(e,t,n,r);return}mT(e,t,n,r)},fT=(e,t,n)=>{const r=e===""?t:Ud(t,e);r.classGroupId=n},pT=(e,t,n,r)=>{if(gT(e)){cs(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(sT(n,e))},mT=(e,t,n,r)=>{const i=Object.entries(e),a=i.length;for(let s=0;s<a;s++){const[o,u]=i[s];cs(u,Ud(t,o),n,r)}},Ud=(e,t)=>{let n=e;const r=t.split(ti),i=r.length;for(let a=0;a<i;a++){const s=r[a];let o=n.nextPart.get(s);o||(o=Fd(),n.nextPart.set(s,o)),n=o}return n},gT=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,bT=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="!",ru=":",ET=[],iu=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),TT=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=i=>{const a=[];let s=0,o=0,u=0,l;const h=i.length;for(let _=0;_<h;_++){const x=i[_];if(s===0&&o===0){if(x===ru){a.push(i.slice(u,_)),u=_+1;continue}if(x==="/"){l=_;continue}}x==="["?s++:x==="]"?s--:x==="("?o++:x===")"&&o--}const d=a.length===0?i:i.slice(u);let p=d,f=!1;d.endsWith(_a)?(p=d.slice(0,-1),f=!0):d.startsWith(_a)&&(p=d.slice(1),f=!0);const m=l&&l>u?l-u:void 0;return iu(a,f,p,m)};if(t){const i=t+ru,a=r;r=s=>s.startsWith(i)?a(s.slice(i.length)):iu(ET,!1,s,void 0,!0)}if(n){const i=r;r=a=>n({className:a,parseClassName:i})}return r},_T=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}},kT=e=>({cache:bT(e.cacheSize),parseClassName:TT(e),sortModifiers:_T(e),...uT(e)}),xT=/\s+/,yT=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,s=[],o=e.trim().split(xT);let u="";for(let l=o.length-1;l>=0;l-=1){const h=o[l],{isExternal:d,modifiers:p,hasImportantModifier:f,baseClassName:m,maybePostfixModifierPosition:_}=n(h);if(d){u=h+(u.length>0?" "+u:u);continue}let x=!!_,k=r(x?m.substring(0,_):m);if(!k){if(!x){u=h+(u.length>0?" "+u:u);continue}if(k=r(m),!k){u=h+(u.length>0?" "+u:u);continue}x=!1}const v=p.length===0?"":p.length===1?p[0]:a(p).join(":"),C=f?v+_a:v,R=C+k;if(s.indexOf(R)>-1)continue;s.push(R);const F=i(k,x);for(let S=0;S<F.length;++S){const Y=F[S];s.push(C+Y)}u=h+(u.length>0?" "+u:u)}return u},wT=(...e)=>{let t=0,n,r,i="";for(;t<e.length;)(n=e[t++])&&(r=zd(n))&&(i&&(i+=" "),i+=r);return i},zd=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=zd(e[r]))&&(n&&(n+=" "),n+=t);return n},AT=(e,...t)=>{let n,r,i,a;const s=u=>{const l=t.reduce((h,d)=>d(h),e());return n=kT(l),r=n.cache.get,i=n.cache.set,a=o,o(u)},o=u=>{const l=r(u);if(l)return l;const h=yT(u,n);return i(u,h),h};return a=s,(...u)=>a(wT(...u))},CT=[],Oe=e=>{const t=n=>n[e]||CT;return t.isThemeGetter=!0,t},$d=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Yd=/^\((?:(\w[\w-]*):)?(.+)\)$/i,ST=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,vT=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,IT=/\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$/,NT=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,LT=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,RT=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,St=e=>ST.test(e),ie=e=>!!e&&!Number.isNaN(Number(e)),vt=e=>!!e&&Number.isInteger(Number(e)),qi=e=>e.endsWith("%")&&ie(e.slice(0,-1)),xt=e=>vT.test(e),jd=()=>!0,OT=e=>IT.test(e)&&!NT.test(e),ds=()=>!1,DT=e=>LT.test(e),PT=e=>RT.test(e),MT=e=>!j(e)&&!V(e),BT=e=>zt(e,Wd,ds),j=e=>$d.test(e),Vt=e=>zt(e,Gd,OT),au=e=>zt(e,VT,ie),FT=e=>zt(e,Kd,jd),HT=e=>zt(e,Qd,ds),su=e=>zt(e,Vd,ds),UT=e=>zt(e,qd,PT),wr=e=>zt(e,Xd,DT),V=e=>Yd.test(e),Mn=e=>an(e,Gd),zT=e=>an(e,Qd),ou=e=>an(e,Vd),$T=e=>an(e,Wd),YT=e=>an(e,qd),Ar=e=>an(e,Xd,!0),jT=e=>an(e,Kd,!0),zt=(e,t,n)=>{const r=$d.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},an=(e,t,n=!1)=>{const r=Yd.exec(e);return r?r[1]?t(r[1]):n:!1},Vd=e=>e==="position"||e==="percentage",qd=e=>e==="image"||e==="url",Wd=e=>e==="length"||e==="size"||e==="bg-size",Gd=e=>e==="length",VT=e=>e==="number",Qd=e=>e==="family-name",Kd=e=>e==="number"||e==="weight",Xd=e=>e==="shadow",qT=()=>{const e=Oe("color"),t=Oe("font"),n=Oe("text"),r=Oe("font-weight"),i=Oe("tracking"),a=Oe("leading"),s=Oe("breakpoint"),o=Oe("container"),u=Oe("spacing"),l=Oe("radius"),h=Oe("shadow"),d=Oe("inset-shadow"),p=Oe("text-shadow"),f=Oe("drop-shadow"),m=Oe("blur"),_=Oe("perspective"),x=Oe("aspect"),k=Oe("ease"),v=Oe("animate"),C=()=>["auto","avoid","all","avoid-page","page","left","right","column"],R=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],F=()=>[...R(),V,j],S=()=>["auto","hidden","clip","visible","scroll"],Y=()=>["auto","contain","none"],L=()=>[V,j,u],O=()=>[St,"full","auto",...L()],A=()=>[vt,"none","subgrid",V,j],z=()=>["auto",{span:["full",vt,V,j]},vt,V,j],M=()=>[vt,"auto",V,j],Q=()=>["auto","min","max","fr",V,j],ue=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],J=()=>["start","end","center","stretch","center-safe","end-safe"],oe=()=>["auto",...L()],q=()=>[St,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...L()],K=()=>[St,"screen","full","dvw","lvw","svw","min","max","fit",...L()],W=()=>[St,"screen","full","lh","dvh","lvh","svh","min","max","fit",...L()],E=()=>[e,V,j],he=()=>[...R(),ou,su,{position:[V,j]}],Z=()=>["no-repeat",{repeat:["","x","y","space","round"]}],w=()=>["auto","cover","contain",$T,BT,{size:[V,j]}],Se=()=>[qi,Mn,Vt],me=()=>["","none","full",l,V,j],ne=()=>["",ie,Mn,Vt],ze=()=>["solid","dashed","dotted","double"],Ve=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],ge=()=>[ie,qi,ou,su],st=()=>["","none",m,V,j],nt=()=>["none",ie,V,j],rt=()=>["none",ie,V,j],In=()=>[ie,V,j],on=()=>[St,"full",...L()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[xt],breakpoint:[xt],color:[jd],container:[xt],"drop-shadow":[xt],ease:["in","out","in-out"],font:[MT],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[xt],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[xt],shadow:[xt],spacing:["px",ie],text:[xt],"text-shadow":[xt],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",St,j,V,x]}],container:["container"],columns:[{columns:[ie,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:F()}],overflow:[{overflow:S()}],"overflow-x":[{"overflow-x":S()}],"overflow-y":[{"overflow-y":S()}],overscroll:[{overscroll:Y()}],"overscroll-x":[{"overscroll-x":Y()}],"overscroll-y":[{"overscroll-y":Y()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:O()}],"inset-x":[{"inset-x":O()}],"inset-y":[{"inset-y":O()}],start:[{"inset-s":O(),start:O()}],end:[{"inset-e":O(),end:O()}],"inset-bs":[{"inset-bs":O()}],"inset-be":[{"inset-be":O()}],top:[{top:O()}],right:[{right:O()}],bottom:[{bottom:O()}],left:[{left:O()}],visibility:["visible","invisible","collapse"],z:[{z:[vt,"auto",V,j]}],basis:[{basis:[St,"full","auto",o,...L()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[ie,St,"auto","initial","none",j]}],grow:[{grow:["",ie,V,j]}],shrink:[{shrink:["",ie,V,j]}],order:[{order:[vt,"first","last","none",V,j]}],"grid-cols":[{"grid-cols":A()}],"col-start-end":[{col:z()}],"col-start":[{"col-start":M()}],"col-end":[{"col-end":M()}],"grid-rows":[{"grid-rows":A()}],"row-start-end":[{row:z()}],"row-start":[{"row-start":M()}],"row-end":[{"row-end":M()}],"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:[...ue(),"normal"]}],"justify-items":[{"justify-items":[...J(),"normal"]}],"justify-self":[{"justify-self":["auto",...J()]}],"align-content":[{content:["normal",...ue()]}],"align-items":[{items:[...J(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...J(),{baseline:["","last"]}]}],"place-content":[{"place-content":ue()}],"place-items":[{"place-items":[...J(),"baseline"]}],"place-self":[{"place-self":["auto",...J()]}],p:[{p:L()}],px:[{px:L()}],py:[{py:L()}],ps:[{ps:L()}],pe:[{pe:L()}],pbs:[{pbs:L()}],pbe:[{pbe:L()}],pt:[{pt:L()}],pr:[{pr:L()}],pb:[{pb:L()}],pl:[{pl:L()}],m:[{m:oe()}],mx:[{mx:oe()}],my:[{my:oe()}],ms:[{ms:oe()}],me:[{me:oe()}],mbs:[{mbs:oe()}],mbe:[{mbe:oe()}],mt:[{mt:oe()}],mr:[{mr:oe()}],mb:[{mb:oe()}],ml:[{ml:oe()}],"space-x":[{"space-x":L()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":L()}],"space-y-reverse":["space-y-reverse"],size:[{size:q()}],"inline-size":[{inline:["auto",...K()]}],"min-inline-size":[{"min-inline":["auto",...K()]}],"max-inline-size":[{"max-inline":["none",...K()]}],"block-size":[{block:["auto",...W()]}],"min-block-size":[{"min-block":["auto",...W()]}],"max-block-size":[{"max-block":["none",...W()]}],w:[{w:[o,"screen",...q()]}],"min-w":[{"min-w":[o,"screen","none",...q()]}],"max-w":[{"max-w":[o,"screen","none","prose",{screen:[s]},...q()]}],h:[{h:["screen","lh",...q()]}],"min-h":[{"min-h":["screen","lh","none",...q()]}],"max-h":[{"max-h":["screen","lh",...q()]}],"font-size":[{text:["base",n,Mn,Vt]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,jT,FT]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",qi,j]}],"font-family":[{font:[zT,HT,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":[ie,"none",V,au]}],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:E()}],"text-color":[{text:E()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ze(),"wavy"]}],"text-decoration-thickness":[{decoration:[ie,"from-font","auto",V,Vt]}],"text-decoration-color":[{decoration:E()}],"underline-offset":[{"underline-offset":[ie,"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:he()}],"bg-repeat":[{bg:Z()}],"bg-size":[{bg:w()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},vt,V,j],radial:["",V,j],conic:[vt,V,j]},YT,UT]}],"bg-color":[{bg:E()}],"gradient-from-pos":[{from:Se()}],"gradient-via-pos":[{via:Se()}],"gradient-to-pos":[{to:Se()}],"gradient-from":[{from:E()}],"gradient-via":[{via:E()}],"gradient-to":[{to:E()}],rounded:[{rounded:me()}],"rounded-s":[{"rounded-s":me()}],"rounded-e":[{"rounded-e":me()}],"rounded-t":[{"rounded-t":me()}],"rounded-r":[{"rounded-r":me()}],"rounded-b":[{"rounded-b":me()}],"rounded-l":[{"rounded-l":me()}],"rounded-ss":[{"rounded-ss":me()}],"rounded-se":[{"rounded-se":me()}],"rounded-ee":[{"rounded-ee":me()}],"rounded-es":[{"rounded-es":me()}],"rounded-tl":[{"rounded-tl":me()}],"rounded-tr":[{"rounded-tr":me()}],"rounded-br":[{"rounded-br":me()}],"rounded-bl":[{"rounded-bl":me()}],"border-w":[{border:ne()}],"border-w-x":[{"border-x":ne()}],"border-w-y":[{"border-y":ne()}],"border-w-s":[{"border-s":ne()}],"border-w-e":[{"border-e":ne()}],"border-w-bs":[{"border-bs":ne()}],"border-w-be":[{"border-be":ne()}],"border-w-t":[{"border-t":ne()}],"border-w-r":[{"border-r":ne()}],"border-w-b":[{"border-b":ne()}],"border-w-l":[{"border-l":ne()}],"divide-x":[{"divide-x":ne()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":ne()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ze(),"hidden","none"]}],"divide-style":[{divide:[...ze(),"hidden","none"]}],"border-color":[{border:E()}],"border-color-x":[{"border-x":E()}],"border-color-y":[{"border-y":E()}],"border-color-s":[{"border-s":E()}],"border-color-e":[{"border-e":E()}],"border-color-bs":[{"border-bs":E()}],"border-color-be":[{"border-be":E()}],"border-color-t":[{"border-t":E()}],"border-color-r":[{"border-r":E()}],"border-color-b":[{"border-b":E()}],"border-color-l":[{"border-l":E()}],"divide-color":[{divide:E()}],"outline-style":[{outline:[...ze(),"none","hidden"]}],"outline-offset":[{"outline-offset":[ie,V,j]}],"outline-w":[{outline:["",ie,Mn,Vt]}],"outline-color":[{outline:E()}],shadow:[{shadow:["","none",h,Ar,wr]}],"shadow-color":[{shadow:E()}],"inset-shadow":[{"inset-shadow":["none",d,Ar,wr]}],"inset-shadow-color":[{"inset-shadow":E()}],"ring-w":[{ring:ne()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:E()}],"ring-offset-w":[{"ring-offset":[ie,Vt]}],"ring-offset-color":[{"ring-offset":E()}],"inset-ring-w":[{"inset-ring":ne()}],"inset-ring-color":[{"inset-ring":E()}],"text-shadow":[{"text-shadow":["none",p,Ar,wr]}],"text-shadow-color":[{"text-shadow":E()}],opacity:[{opacity:[ie,V,j]}],"mix-blend":[{"mix-blend":[...Ve(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":Ve()}],"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":[ie]}],"mask-image-linear-from-pos":[{"mask-linear-from":ge()}],"mask-image-linear-to-pos":[{"mask-linear-to":ge()}],"mask-image-linear-from-color":[{"mask-linear-from":E()}],"mask-image-linear-to-color":[{"mask-linear-to":E()}],"mask-image-t-from-pos":[{"mask-t-from":ge()}],"mask-image-t-to-pos":[{"mask-t-to":ge()}],"mask-image-t-from-color":[{"mask-t-from":E()}],"mask-image-t-to-color":[{"mask-t-to":E()}],"mask-image-r-from-pos":[{"mask-r-from":ge()}],"mask-image-r-to-pos":[{"mask-r-to":ge()}],"mask-image-r-from-color":[{"mask-r-from":E()}],"mask-image-r-to-color":[{"mask-r-to":E()}],"mask-image-b-from-pos":[{"mask-b-from":ge()}],"mask-image-b-to-pos":[{"mask-b-to":ge()}],"mask-image-b-from-color":[{"mask-b-from":E()}],"mask-image-b-to-color":[{"mask-b-to":E()}],"mask-image-l-from-pos":[{"mask-l-from":ge()}],"mask-image-l-to-pos":[{"mask-l-to":ge()}],"mask-image-l-from-color":[{"mask-l-from":E()}],"mask-image-l-to-color":[{"mask-l-to":E()}],"mask-image-x-from-pos":[{"mask-x-from":ge()}],"mask-image-x-to-pos":[{"mask-x-to":ge()}],"mask-image-x-from-color":[{"mask-x-from":E()}],"mask-image-x-to-color":[{"mask-x-to":E()}],"mask-image-y-from-pos":[{"mask-y-from":ge()}],"mask-image-y-to-pos":[{"mask-y-to":ge()}],"mask-image-y-from-color":[{"mask-y-from":E()}],"mask-image-y-to-color":[{"mask-y-to":E()}],"mask-image-radial":[{"mask-radial":[V,j]}],"mask-image-radial-from-pos":[{"mask-radial-from":ge()}],"mask-image-radial-to-pos":[{"mask-radial-to":ge()}],"mask-image-radial-from-color":[{"mask-radial-from":E()}],"mask-image-radial-to-color":[{"mask-radial-to":E()}],"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":R()}],"mask-image-conic-pos":[{"mask-conic":[ie]}],"mask-image-conic-from-pos":[{"mask-conic-from":ge()}],"mask-image-conic-to-pos":[{"mask-conic-to":ge()}],"mask-image-conic-from-color":[{"mask-conic-from":E()}],"mask-image-conic-to-color":[{"mask-conic-to":E()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:he()}],"mask-repeat":[{mask:Z()}],"mask-size":[{mask:w()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",V,j]}],filter:[{filter:["","none",V,j]}],blur:[{blur:st()}],brightness:[{brightness:[ie,V,j]}],contrast:[{contrast:[ie,V,j]}],"drop-shadow":[{"drop-shadow":["","none",f,Ar,wr]}],"drop-shadow-color":[{"drop-shadow":E()}],grayscale:[{grayscale:["",ie,V,j]}],"hue-rotate":[{"hue-rotate":[ie,V,j]}],invert:[{invert:["",ie,V,j]}],saturate:[{saturate:[ie,V,j]}],sepia:[{sepia:["",ie,V,j]}],"backdrop-filter":[{"backdrop-filter":["","none",V,j]}],"backdrop-blur":[{"backdrop-blur":st()}],"backdrop-brightness":[{"backdrop-brightness":[ie,V,j]}],"backdrop-contrast":[{"backdrop-contrast":[ie,V,j]}],"backdrop-grayscale":[{"backdrop-grayscale":["",ie,V,j]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[ie,V,j]}],"backdrop-invert":[{"backdrop-invert":["",ie,V,j]}],"backdrop-opacity":[{"backdrop-opacity":[ie,V,j]}],"backdrop-saturate":[{"backdrop-saturate":[ie,V,j]}],"backdrop-sepia":[{"backdrop-sepia":["",ie,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:[ie,"initial",V,j]}],ease:[{ease:["linear","initial",k,V,j]}],delay:[{delay:[ie,V,j]}],animate:[{animate:["none",v,V,j]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[_,V,j]}],"perspective-origin":[{"perspective-origin":F()}],rotate:[{rotate:nt()}],"rotate-x":[{"rotate-x":nt()}],"rotate-y":[{"rotate-y":nt()}],"rotate-z":[{"rotate-z":nt()}],scale:[{scale:rt()}],"scale-x":[{"scale-x":rt()}],"scale-y":[{"scale-y":rt()}],"scale-z":[{"scale-z":rt()}],"scale-3d":["scale-3d"],skew:[{skew:In()}],"skew-x":[{"skew-x":In()}],"skew-y":[{"skew-y":In()}],transform:[{transform:[V,j,"","none","gpu","cpu"]}],"transform-origin":[{origin:F()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:on()}],"translate-x":[{"translate-x":on()}],"translate-y":[{"translate-y":on()}],"translate-z":[{"translate-z":on()}],"translate-none":["translate-none"],accent:[{accent:E()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:E()}],"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-mbs":[{"scroll-mbs":L()}],"scroll-mbe":[{"scroll-mbe":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-pbs":[{"scroll-pbs":L()}],"scroll-pbe":[{"scroll-pbe":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",...E()]}],"stroke-w":[{stroke:[ie,Mn,Vt,au]}],stroke:[{stroke:["none",...E()]}],"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"]}},WT=AT(qT),GT=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,QT=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,KT={};function uu(e,t){return((t||KT).jsx?QT:GT).test(e)}const XT=/[ \t\n\f\r]/g;function ZT(e){return typeof e=="object"?e.type==="text"?lu(e.value):!1:lu(e)}function lu(e){return e.replace(XT,"")===""}var ni=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Zd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var hs={},cu=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,JT=/\n/g,e_=/^\s*/,t_=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,n_=/^:\s*/,r_=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,i_=/^[;\s]*/,a_=/^\s+|\s+$/g,s_=`
|
|
39
|
+
`,du="/",hu="*",Wt="",o_="comment",u_="declaration";function l_(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(JT);_&&(n+=_.length);var x=m.lastIndexOf(s_);r=~x?m.length-x:r+m.length}function a(){var m={line:n,column:r};return function(_){return _.position=new s(m),l(),_}}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 x=_[0];return i(x),e=e.slice(x.length),_}}function l(){u(e_)}function h(m){var _;for(m=m||[];_=d();)_!==!1&&m.push(_);return m}function d(){var m=a();if(!(du!=e.charAt(0)||hu!=e.charAt(1))){for(var _=2;Wt!=e.charAt(_)&&(hu!=e.charAt(_)||du!=e.charAt(_+1));)++_;if(_+=2,Wt===e.charAt(_-1))return o("End of comment missing");var x=e.slice(2,_-2);return r+=2,i(x),e=e.slice(_),r+=2,m({type:o_,comment:x})}}function p(){var m=a(),_=u(t_);if(_){if(d(),!u(n_))return o("property missing ':'");var x=u(r_),k=m({type:u_,property:fu(_[0].replace(cu,Wt)),value:x?fu(x[0].replace(cu,Wt)):Wt});return u(i_),k}}function f(){var m=[];h(m);for(var _;_=p();)_!==!1&&(m.push(_),h(m));return m}return l(),f()}function fu(e){return e?e.replace(a_,Wt):Wt}var c_=l_,d_=ni&&ni.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(hs,"__esModule",{value:!0});hs.default=f_;const h_=d_(c_);function f_(e,t){let n=null;if(!e||typeof e!="string")return n;const r=(0,h_.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 Ai={};Object.defineProperty(Ai,"__esModule",{value:!0});Ai.camelCase=void 0;var p_=/^--[a-zA-Z0-9_-]+$/,m_=/-([a-z])/g,g_=/^[^-]+$/,b_=/^-(webkit|moz|ms|o|khtml)-/,E_=/^-(ms)-/,T_=function(e){return!e||g_.test(e)||p_.test(e)},__=function(e,t){return t.toUpperCase()},pu=function(e,t){return"".concat(t,"-")},k_=function(e,t){return t===void 0&&(t={}),T_(e)?e:(e=e.toLowerCase(),t.reactCompat?e=e.replace(E_,pu):e=e.replace(b_,pu),e.replace(m_,__))};Ai.camelCase=k_;var x_=ni&&ni.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},y_=x_(hs),w_=Ai;function ka(e,t){var n={};return!e||typeof e!="string"||(0,y_.default)(e,function(r,i){r&&i&&(n[(0,w_.camelCase)(r,t)]=i)}),n}ka.default=ka;var A_=ka;const C_=Zd(A_);function er(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?mu(e.position):"start"in e||"end"in e?mu(e):"line"in e||"column"in e?xa(e):""}function xa(e){return gu(e&&e.line)+":"+gu(e&&e.column)}function mu(e){return xa(e&&e.start)+"-"+xa(e&&e.end)}function gu(e){return e&&typeof e=="number"?e:1}class Ue 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=er(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}}Ue.prototype.file="";Ue.prototype.name="";Ue.prototype.reason="";Ue.prototype.message="";Ue.prototype.stack="";Ue.prototype.column=void 0;Ue.prototype.line=void 0;Ue.prototype.ancestors=void 0;Ue.prototype.cause=void 0;Ue.prototype.fatal=void 0;Ue.prototype.place=void 0;Ue.prototype.ruleId=void 0;Ue.prototype.source=void 0;const fs={}.hasOwnProperty,S_=new Map,v_=/[A-Z]/g,I_=new Set(["table","tbody","thead","tfoot","tr"]),N_=new Set(["td","th"]),Jd="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function L_(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=H_(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=F_(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"?Ht:fr,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=e0(i,e,void 0);return a&&typeof a!="string"?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function e0(e,t,n){if(t.type==="element")return R_(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return O_(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return P_(e,t,n);if(t.type==="mdxjsEsm")return D_(e,t);if(t.type==="root")return M_(e,t,n);if(t.type==="text")return B_(e,t)}function R_(e,t,n){const r=e.schema;let i=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=Ht,e.schema=i),e.ancestors.push(t);const a=n0(e,t.tagName,!1),s=U_(e,t);let o=ms(e,t);return I_.has(t.tagName)&&(o=o.filter(function(u){return typeof u=="string"?!ZT(u):!0})),t0(e,s,a,t),ps(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function O_(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return e.evaluater.evaluateExpression(r.expression)}lr(e,t.position)}function D_(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);lr(e,t.position)}function P_(e,t,n){const r=e.schema;let i=r;t.name==="svg"&&r.space==="html"&&(i=Ht,e.schema=i),e.ancestors.push(t);const a=t.name===null?e.Fragment:n0(e,t.name,!0),s=z_(e,t),o=ms(e,t);return t0(e,s,a,t),ps(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function M_(e,t,n){const r={};return ps(r,ms(e,t)),e.create(t,e.Fragment,r,n)}function B_(e,t){return t.value}function t0(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function ps(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function F_(e,t,n){return r;function r(i,a,s,o){const l=Array.isArray(s.children)?n:t;return o?l(a,s,o):l(a,s)}}function H_(e,t){return n;function n(r,i,a,s){const o=Array.isArray(a.children),u=Et(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 U_(e,t){const n={};let r,i;for(i in t.properties)if(i!=="children"&&fs.call(t.properties,i)){const a=$_(e,i,t.properties[i]);if(a){const[s,o]=a;e.tableCellAlignToStyle&&s==="align"&&typeof o=="string"&&N_.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 z_(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 lr(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 lr(e,t.position);else a=r.value===null?!0:r.value;n[i]=a}return n}function ms(e,t){const n=[];let r=-1;const i=e.passKeys?new Map:S_;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 l=i.get(u)||0;s=u+"-"+l,i.set(u,l+1)}}const o=e0(e,a,s);o!==void 0&&n.push(o)}return n}function $_(e,t,n){const r=gi(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?sc(n):oc(n)),r.property==="style"){let i=typeof n=="object"?n:Y_(e,String(n));return e.stylePropertyNameCase==="css"&&(i=j_(i)),["style",i]}return[e.elementAttributeNameCase==="react"&&r.space?qf[r.property]||r.property:r.attribute,n]}}function Y_(e,t){try{return C_(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,i=new Ue("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=Jd+"#cannot-parse-style-attribute",i}}function n0(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=uu(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=uu(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const i=r.value;return fs.call(e.components,i)?e.components[i]:i}if(e.evaluater)return e.evaluater.evaluateExpression(r);lr(e)}function lr(e,t){const n=new Ue("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=Jd+"#cannot-handle-mdx-estrees-without-createevaluater",n}function j_(e){const t={};let n;for(n in e)fs.call(e,n)&&(t[V_(n)]=e[n]);return t}function V_(e){let t=e.replace(v_,q_);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function q_(e){return"-"+e.toLowerCase()}const Wi={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"]},W_={tokenize:G_};function G_(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"),ce(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 X(o)?(e.consume(o),e.exit("chunkText"),a):(e.consume(o),s)}}const Q_={tokenize:K_},bu={tokenize:X_};function K_(e){const t=this,n=[];let r=0,i,a,s;return o;function o(C){if(r<n.length){const R=n[r];return t.containerState=R[1],e.attempt(R[0].continuation,u,l)(C)}return l(C)}function u(C){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&v();const R=t.events.length;let F=R,S;for(;F--;)if(t.events[F][0]==="exit"&&t.events[F][1].type==="chunkFlow"){S=t.events[F][1].end;break}k(r);let Y=R;for(;Y<t.events.length;)t.events[Y][1].end={...S},Y++;return Je(t.events,F+1,0,t.events.slice(R)),t.events.length=Y,l(C)}return o(C)}function l(C){if(r===n.length){if(!i)return p(C);if(i.currentConstruct&&i.currentConstruct.concrete)return m(C);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(bu,h,d)(C)}function h(C){return i&&v(),k(r),p(C)}function d(C){return t.parser.lazy[t.now().line]=r!==n.length,s=t.now().offset,m(C)}function p(C){return t.containerState={},e.attempt(bu,f,m)(C)}function f(C){return r++,n.push([t.currentConstruct,t.containerState]),p(C)}function m(C){if(C===null){i&&v(),k(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){x(e.exit("chunkFlow"),!0),k(0),e.consume(C);return}return X(C)?(e.consume(C),x(e.exit("chunkFlow")),r=0,t.interrupt=void 0,o):(e.consume(C),_)}function x(C,R){const F=t.sliceStream(C);if(R&&F.push(null),C.previous=a,a&&(a.next=C),a=C,i.defineSkip(C.start),i.write(F),t.parser.lazy[C.start.line]){let S=i.events.length;for(;S--;)if(i.events[S][1].start.offset<s&&(!i.events[S][1].end||i.events[S][1].end.offset>s))return;const Y=t.events.length;let L=Y,O,A;for(;L--;)if(t.events[L][0]==="exit"&&t.events[L][1].type==="chunkFlow"){if(O){A=t.events[L][1].end;break}O=!0}for(k(r),S=Y;S<t.events.length;)t.events[S][1].end={...A},S++;Je(t.events,L+1,0,t.events.slice(Y)),t.events.length=S}}function k(C){let R=n.length;for(;R-- >C;){const F=n[R];t.containerState=F[1],F[0].exit.call(t,e)}n.length=C}function v(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function X_(e,t,n){return ce(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}const Z_={tokenize:J_};function J_(e){const t=this,n=e.attempt(br,r,e.attempt(this.parser.constructs.flowInitial,i,ce(e,e.attempt(this.parser.constructs.flow,i,e.attempt(D2,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 ek={resolveAll:i0()},tk=r0("string"),nk=r0("text");function r0(e){return{resolveAll:i0(e==="text"?rk: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(h){return l(h)?a(h):o(h)}function o(h){if(h===null){n.consume(h);return}return n.enter("data"),n.consume(h),u}function u(h){return l(h)?(n.exit("data"),a(h)):(n.consume(h),u)}function l(h){if(h===null)return!0;const d=i[h];let p=-1;if(d)for(;++p<d.length;){const f=d[p];if(!f.previous||f.previous.call(r,r.previous))return!0}return!1}}}function i0(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 rk(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 l=i[a];if(typeof l=="string"){for(s=l.length;l.charCodeAt(s-1)===32;)o++,s--;if(s)break;s=-1}else if(l===-2)u=!0,o++;else if(l!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(o=0),o){const l={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={...l.start},r.start.offset===r.end.offset?Object.assign(r,l):(e.splice(n,0,["enter",l,t],["exit",l,t]),n+=2)}n++}return e}const ik={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:xd},ak={91:H2},sk={[-2]:Yi,[-1]:Yi,32:Yi},ok={35:V2,42:Fr,45:[Qo,Fr],60:Q2,61:Qo,95:Fr,96:Wo,126:Wo},uk={38:wd,92:yd},lk={[-5]:ji,[-4]:ji,[-3]:ji,33:fE,38:wd,42:Ta,60:[m2,nE],91:mE,92:[Y2,yd],93:os,95:Ta,96:v2},ck={null:[Ta,ek]},dk={null:[42,95]},hk={null:[]},fk=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:dk,contentInitial:ak,disable:hk,document:ik,flow:ok,flowInitial:sk,insideSpan:ck,string:uk,text:lk},Symbol.toStringTag,{value:"Module"}));function pk(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:Y(F),check:Y(S),consume:v,enter:C,exit:R,interrupt:Y(S,{interrupt:!0})},l={code:null,containerState:{},defineSkip:_,events:[],now:m,parser:e,previous:null,sliceSerialize:p,sliceStream:f,write:d};let h=t.tokenize.call(l,u);return t.resolveAll&&a.push(t),l;function d(z){return s=at(s,z),x(),s[s.length-1]!==null?[]:(L(t,0),l.events=yi(a,l.events,l),l.events)}function p(z,M){return gk(f(z),M)}function f(z){return mk(s,z)}function m(){const{_bufferIndex:z,_index:M,line:Q,column:ue,offset:J}=r;return{_bufferIndex:z,_index:M,line:Q,column:ue,offset:J}}function _(z){i[z.line]=z.column,A()}function x(){let z;for(;r._index<s.length;){const M=s[r._index];if(typeof M=="string")for(z=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===z&&r._bufferIndex<M.length;)k(M.charCodeAt(r._bufferIndex));else k(M)}}function k(z){h=h(z)}function v(z){X(z)?(r.line++,r.column=1,r.offset+=z===-3?2:1,A()):z!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===s[r._index].length&&(r._bufferIndex=-1,r._index++)),l.previous=z}function C(z,M){const Q=M||{};return Q.type=z,Q.start=m(),l.events.push(["enter",Q,l]),o.push(Q),Q}function R(z){const M=o.pop();return M.end=m(),l.events.push(["exit",M,l]),M}function F(z,M){L(z,M.from)}function S(z,M){M.restore()}function Y(z,M){return Q;function Q(ue,J,oe){let q,K,W,E;return Array.isArray(ue)?Z(ue):"tokenize"in ue?Z([ue]):he(ue);function he(ne){return ze;function ze(Ve){const ge=Ve!==null&&ne[Ve],st=Ve!==null&&ne.null,nt=[...Array.isArray(ge)?ge:ge?[ge]:[],...Array.isArray(st)?st:st?[st]:[]];return Z(nt)(Ve)}}function Z(ne){return q=ne,K=0,ne.length===0?oe:w(ne[K])}function w(ne){return ze;function ze(Ve){return E=O(),W=ne,ne.partial||(l.currentConstruct=ne),ne.name&&l.parser.constructs.disable.null.includes(ne.name)?me():ne.tokenize.call(M?Object.assign(Object.create(l),M):l,u,Se,me)(Ve)}}function Se(ne){return z(W,E),J}function me(ne){return E.restore(),++K<q.length?w(q[K]):oe}}}function L(z,M){z.resolveAll&&!a.includes(z)&&a.push(z),z.resolve&&Je(l.events,M,l.events.length-M,z.resolve(l.events.slice(M),l)),z.resolveTo&&(l.events=z.resolveTo(l.events,l))}function O(){const z=m(),M=l.previous,Q=l.currentConstruct,ue=l.events.length,J=Array.from(o);return{from:ue,restore:oe};function oe(){r=z,l.previous=M,l.currentConstruct=Q,l.events.length=ue,o=J,A()}}function A(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function mk(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 gk(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=`
|
|
40
40
|
`;break}case-3:{s=`\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 lk(e){const r={constructs:dd([ak,...(e||{}).extensions||[]]),content:i(H_),defined:[],document:i(z_),flow:i(j_),lazy:{},string:i(W_),text:i(G_)};return r;function i(a){return s;function s(o){return sk(r,a,o)}}}function ck(e){for(;!yd(e););return e}const gu=/[\0\t\n\r]/g;function dk(){let e=1,t="",n=!0,r;return i;function i(a,s,o){const u=[];let l,h,d,p,f;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(gu.lastIndex=d,l=gu.exec(a),p=l&&l.index!==void 0?l.index:a.length,f=a.charCodeAt(p),!l){t=a.slice(d);break}if(f===10&&d===p&&r)u.push(-3),r=void 0;else switch(r&&(u.push(-5),r=void 0),d<p&&(u.push(a.slice(d,p)),e+=p-d),f){case 0:{u.push(65533),e++;break}case 9:{for(h=Math.ceil(e/4)*4,u.push(-2);e++<h;)u.push(-1);break}case 10:{u.push(-4),e=1;break}default:r=!0,e=1}d=p+1}return o&&(r&&u.push(-5),t&&u.push(t),u.push(null)),u}}const r0={}.hasOwnProperty;function hk(e,t,n){return t&&typeof t=="object"&&(n=t,t=void 0),fk(n)(ck(lk(n).document().write(dk()(e,t,!0))))}function fk(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(Rs),autolinkProtocol:D,autolinkEmail:D,atxHeading:a(Is),blockQuote:a(st),characterEscape:D,characterReference:D,codeFenced:a(nt),codeFencedFenceInfo:s,codeFencedFenceMeta:s,codeIndented:a(nt,s),codeText:a(rt,s),codeTextData:D,data:D,codeFlowValue:D,definition:a(vn),definitionDestinationString:s,definitionLabelString:s,definitionTitleString:s,emphasis:a(on),hardBreakEscape:a(Ns),hardBreakTrailing:a(Ns),htmlFlow:a(Ls,s),htmlFlowData:D,htmlText:a(Ls,s),htmlTextData:D,image:a(hh),label:s,link:a(Rs),listItem:a(fh),listItemValue:p,listOrdered:a(Os,d),listUnordered:a(Os),paragraph:a(ph),reference:w,referenceString:s,resourceDestinationString:s,resourceTitleString:s,setextHeading:a(Is),strong:a(mh),thematicBreak:a(bh)},exit:{atxHeading:u(),atxHeadingSequence:F,autolink:u(),autolinkEmail:me,autolinkProtocol:je,blockQuote:u(),characterEscapeValue:A,characterReferenceMarkerHexadecimal:pe,characterReferenceMarkerNumeric:pe,characterReferenceValue:ne,characterReference:Ue,codeFenced:u(x),codeFencedFence:_,codeFencedFenceInfo:f,codeFencedFenceMeta:m,codeFlowValue:A,codeIndented:u(k),codeText:u(J),codeTextData:A,data:A,definition:u(),definitionDestinationString:R,definitionLabelString:v,definitionTitleString:C,emphasis:u(),hardBreakEscape:u(P),hardBreakTrailing:u(P),htmlFlow:u(Q),htmlFlowData:A,htmlText:u(ue),htmlTextData:A,image:u(q),label:W,labelText:K,lineEnding:z,link:u(oe),listItem:u(),listOrdered:u(),listUnordered:u(),paragraph:u(),referenceString:Se,resourceDestinationString:E,resourceTitleString:he,resource:Z,setextHeading:u(L),setextHeadingLineSequence:Y,setextHeadingText:S,strong:u(),thematicBreak:u()}};i0(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(O){let U={type:"root",children:[]};const te={stack:[U],tokenStack:[],config:t,enter:o,exit:l,buffer:s,resume:h,data:n},le=[];let Ee=-1;for(;++Ee<O.length;)if(O[Ee][1].type==="listOrdered"||O[Ee][1].type==="listUnordered")if(O[Ee][0]==="enter")le.push(Ee);else{const ot=le.pop();Ee=i(O,ot,Ee)}for(Ee=-1;++Ee<O.length;){const ot=t[O[Ee][0]];r0.call(ot,O[Ee][1].type)&&ot[O[Ee][1].type].call(Object.assign({sliceSerialize:O[Ee][2].sliceSerialize},te),O[Ee][1])}if(te.tokenStack.length>0){const ot=te.tokenStack[te.tokenStack.length-1];(ot[1]||bu).call(te,void 0,ot[0])}for(U.position={start:It(O.length>0?O[0][1].start:{line:1,column:1,offset:0}),end:It(O.length>0?O[O.length-2][1].end:{line:1,column:1,offset:0})},Ee=-1;++Ee<t.transforms.length;)U=t.transforms[Ee](U)||U;return U}function i(O,U,te){let le=U-1,Ee=-1,ot=!1,$t,_t,In,Nn;for(;++le<=te;){const Ke=O[le];switch(Ke[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Ke[0]==="enter"?Ee++:Ee--,Nn=void 0;break}case"lineEndingBlank":{Ke[0]==="enter"&&($t&&!Nn&&!Ee&&!In&&(In=le),Nn=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Nn=void 0}if(!Ee&&Ke[0]==="enter"&&Ke[1].type==="listItemPrefix"||Ee===-1&&Ke[0]==="exit"&&(Ke[1].type==="listUnordered"||Ke[1].type==="listOrdered")){if($t){let un=le;for(_t=void 0;un--;){const kt=O[un];if(kt[1].type==="lineEnding"||kt[1].type==="lineEndingBlank"){if(kt[0]==="exit")continue;_t&&(O[_t][1].type="lineEndingBlank",ot=!0),kt[1].type="lineEnding",_t=un}else if(!(kt[1].type==="linePrefix"||kt[1].type==="blockQuotePrefix"||kt[1].type==="blockQuotePrefixWhitespace"||kt[1].type==="blockQuoteMarker"||kt[1].type==="listItemIndent"))break}In&&(!_t||In<_t)&&($t._spread=!0),$t.end=Object.assign({},_t?O[_t][1].start:Ke[1].end),O.splice(_t||le,0,["exit",$t,Ke[2]]),le++,te++}if(Ke[1].type==="listItemPrefix"){const un={type:"listItem",_spread:!1,start:Object.assign({},Ke[1].start),end:void 0};$t=un,O.splice(le,0,["enter",un,Ke[2]]),le++,te++,In=void 0,Nn=!0}}}return O[U][1]._spread=ot,te}function a(O,U){return te;function te(le){o.call(this,O(le),le),U&&U.call(this,le)}}function s(){this.stack.push({type:"fragment",children:[]})}function o(O,U,te){this.stack[this.stack.length-1].children.push(O),this.stack.push(O),this.tokenStack.push([U,te||void 0]),O.position={start:It(U.start),end:void 0}}function u(O){return U;function U(te){O&&O.call(this,te),l.call(this,te)}}function l(O,U){const te=this.stack.pop(),le=this.tokenStack.pop();if(le)le[0].type!==O.type&&(U?U.call(this,O,le[0]):(le[1]||bu).call(this,O,le[0]));else throw new Error("Cannot close `"+O.type+"` ("+Jn({start:O.start,end:O.end})+"): it’s not open");te.position.end=It(O.end)}function h(){return ts(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function p(O){if(this.data.expectingFirstListItemValue){const U=this.stack[this.stack.length-2];U.start=Number.parseInt(this.sliceSerialize(O),10),this.data.expectingFirstListItemValue=void 0}}function f(){const O=this.resume(),U=this.stack[this.stack.length-1];U.lang=O}function m(){const O=this.resume(),U=this.stack[this.stack.length-1];U.meta=O}function _(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function x(){const O=this.resume(),U=this.stack[this.stack.length-1];U.value=O.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function k(){const O=this.resume(),U=this.stack[this.stack.length-1];U.value=O.replace(/(\r?\n|\r)$/g,"")}function v(O){const U=this.resume(),te=this.stack[this.stack.length-1];te.label=U,te.identifier=lt(this.sliceSerialize(O)).toLowerCase()}function C(){const O=this.resume(),U=this.stack[this.stack.length-1];U.title=O}function R(){const O=this.resume(),U=this.stack[this.stack.length-1];U.url=O}function F(O){const U=this.stack[this.stack.length-1];if(!U.depth){const te=this.sliceSerialize(O).length;U.depth=te}}function S(){this.data.setextHeadingSlurpLineEnding=!0}function Y(O){const U=this.stack[this.stack.length-1];U.depth=this.sliceSerialize(O).codePointAt(0)===61?1:2}function L(){this.data.setextHeadingSlurpLineEnding=void 0}function D(O){const te=this.stack[this.stack.length-1].children;let le=te[te.length-1];(!le||le.type!=="text")&&(le=gh(),le.position={start:It(O.start),end:void 0},te.push(le)),this.stack.push(le)}function A(O){const U=this.stack.pop();U.value+=this.sliceSerialize(O),U.position.end=It(O.end)}function z(O){const U=this.stack[this.stack.length-1];if(this.data.atHardBreak){const te=U.children[U.children.length-1];te.position.end=It(O.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(U.type)&&(D.call(this,O),A.call(this,O))}function P(){this.data.atHardBreak=!0}function Q(){const O=this.resume(),U=this.stack[this.stack.length-1];U.value=O}function ue(){const O=this.resume(),U=this.stack[this.stack.length-1];U.value=O}function J(){const O=this.resume(),U=this.stack[this.stack.length-1];U.value=O}function oe(){const O=this.stack[this.stack.length-1];if(this.data.inReference){const U=this.data.referenceType||"shortcut";O.type+="Reference",O.referenceType=U,delete O.url,delete O.title}else delete O.identifier,delete O.label;this.data.referenceType=void 0}function q(){const O=this.stack[this.stack.length-1];if(this.data.inReference){const U=this.data.referenceType||"shortcut";O.type+="Reference",O.referenceType=U,delete O.url,delete O.title}else delete O.identifier,delete O.label;this.data.referenceType=void 0}function K(O){const U=this.sliceSerialize(O),te=this.stack[this.stack.length-2];te.label=Lb(U),te.identifier=lt(U).toLowerCase()}function W(){const O=this.stack[this.stack.length-1],U=this.resume(),te=this.stack[this.stack.length-1];if(this.data.inReference=!0,te.type==="link"){const le=O.children;te.children=le}else te.alt=U}function E(){const O=this.resume(),U=this.stack[this.stack.length-1];U.url=O}function he(){const O=this.resume(),U=this.stack[this.stack.length-1];U.title=O}function Z(){this.data.inReference=void 0}function w(){this.data.referenceType="collapsed"}function Se(O){const U=this.resume(),te=this.stack[this.stack.length-1];te.label=U,te.identifier=lt(this.sliceSerialize(O)).toLowerCase(),this.data.referenceType="full"}function pe(O){this.data.characterReferenceType=O.type}function ne(O){const U=this.sliceSerialize(O),te=this.data.characterReferenceType;let le;te?(le=cd(U,te==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):le=rs(U);const Ee=this.stack[this.stack.length-1];Ee.value+=le}function Ue(O){const U=this.stack.pop();U.position.end=It(O.end)}function je(O){A.call(this,O);const U=this.stack[this.stack.length-1];U.url=this.sliceSerialize(O)}function me(O){A.call(this,O);const U=this.stack[this.stack.length-1];U.url="mailto:"+this.sliceSerialize(O)}function st(){return{type:"blockquote",children:[]}}function nt(){return{type:"code",lang:null,meta:null,value:""}}function rt(){return{type:"inlineCode",value:""}}function vn(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function on(){return{type:"emphasis",children:[]}}function Is(){return{type:"heading",depth:0,children:[]}}function Ns(){return{type:"break"}}function Ls(){return{type:"html",value:""}}function hh(){return{type:"image",title:null,url:"",alt:null}}function Rs(){return{type:"link",title:null,url:"",children:[]}}function Os(O){return{type:"list",ordered:O.type==="listOrdered",start:null,spread:O._spread,children:[]}}function fh(O){return{type:"listItem",spread:O._spread,checked:null,children:[]}}function ph(){return{type:"paragraph",children:[]}}function mh(){return{type:"strong",children:[]}}function gh(){return{type:"text",value:""}}function bh(){return{type:"thematicBreak"}}}function It(e){return{line:e.line,column:e.column,offset:e.offset}}function i0(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?i0(e,r):pk(e,r)}}function pk(e,t){let n;for(n in t)if(r0.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 bu(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Jn({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Jn({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Jn({start:t.start,end:t.end})+") is still open")}function mk(e){const t=this;t.parser=n;function n(r){return hk(r,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function gk(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 bk(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
|
|
42
|
-
`}]}function
|
|
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
|
|
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 bk(e){const r={constructs:fd([fk,...(e||{}).extensions||[]]),content:i(W_),defined:[],document:i(Q_),flow:i(Z_),lazy:{},string:i(tk),text:i(nk)};return r;function i(a){return s;function s(o){return pk(r,a,o)}}}function Ek(e){for(;!Ad(e););return e}const Eu=/[\0\t\n\r]/g;function Tk(){let e=1,t="",n=!0,r;return i;function i(a,s,o){const u=[];let l,h,d,p,f;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(Eu.lastIndex=d,l=Eu.exec(a),p=l&&l.index!==void 0?l.index:a.length,f=a.charCodeAt(p),!l){t=a.slice(d);break}if(f===10&&d===p&&r)u.push(-3),r=void 0;else switch(r&&(u.push(-5),r=void 0),d<p&&(u.push(a.slice(d,p)),e+=p-d),f){case 0:{u.push(65533),e++;break}case 9:{for(h=Math.ceil(e/4)*4,u.push(-2);e++<h;)u.push(-1);break}case 10:{u.push(-4),e=1;break}default:r=!0,e=1}d=p+1}return o&&(r&&u.push(-5),t&&u.push(t),u.push(null)),u}}const a0={}.hasOwnProperty;function _k(e,t,n){return t&&typeof t=="object"&&(n=t,t=void 0),kk(n)(Ek(bk(n).document().write(Tk()(e,t,!0))))}function kk(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(Ds),autolinkProtocol:O,autolinkEmail:O,atxHeading:a(Ls),blockQuote:a(st),characterEscape:O,characterReference:O,codeFenced:a(nt),codeFencedFenceInfo:s,codeFencedFenceMeta:s,codeIndented:a(nt,s),codeText:a(rt,s),codeTextData:O,data:O,codeFlowValue:O,definition:a(In),definitionDestinationString:s,definitionLabelString:s,definitionTitleString:s,emphasis:a(on),hardBreakEscape:a(Rs),hardBreakTrailing:a(Rs),htmlFlow:a(Os,s),htmlFlowData:O,htmlText:a(Os,s),htmlTextData:O,image:a(mh),label:s,link:a(Ds),listItem:a(gh),listItemValue:p,listOrdered:a(Ps,d),listUnordered:a(Ps),paragraph:a(bh),reference:w,referenceString:s,resourceDestinationString:s,resourceTitleString:s,setextHeading:a(Ls),strong:a(Eh),thematicBreak:a(_h)},exit:{atxHeading:u(),atxHeadingSequence:F,autolink:u(),autolinkEmail:ge,autolinkProtocol:Ve,blockQuote:u(),characterEscapeValue:A,characterReferenceMarkerHexadecimal:me,characterReferenceMarkerNumeric:me,characterReferenceValue:ne,characterReference:ze,codeFenced:u(x),codeFencedFence:_,codeFencedFenceInfo:f,codeFencedFenceMeta:m,codeFlowValue:A,codeIndented:u(k),codeText:u(J),codeTextData:A,data:A,definition:u(),definitionDestinationString:R,definitionLabelString:v,definitionTitleString:C,emphasis:u(),hardBreakEscape:u(M),hardBreakTrailing:u(M),htmlFlow:u(Q),htmlFlowData:A,htmlText:u(ue),htmlTextData:A,image:u(q),label:W,labelText:K,lineEnding:z,link:u(oe),listItem:u(),listOrdered:u(),listUnordered:u(),paragraph:u(),referenceString:Se,resourceDestinationString:E,resourceTitleString:he,resource:Z,setextHeading:u(L),setextHeadingLineSequence:Y,setextHeadingText:S,strong:u(),thematicBreak:u()}};s0(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(D){let U={type:"root",children:[]};const te={stack:[U],tokenStack:[],config:t,enter:o,exit:l,buffer:s,resume:h,data:n},le=[];let Te=-1;for(;++Te<D.length;)if(D[Te][1].type==="listOrdered"||D[Te][1].type==="listUnordered")if(D[Te][0]==="enter")le.push(Te);else{const ot=le.pop();Te=i(D,ot,Te)}for(Te=-1;++Te<D.length;){const ot=t[D[Te][0]];a0.call(ot,D[Te][1].type)&&ot[D[Te][1].type].call(Object.assign({sliceSerialize:D[Te][2].sliceSerialize},te),D[Te][1])}if(te.tokenStack.length>0){const ot=te.tokenStack[te.tokenStack.length-1];(ot[1]||Tu).call(te,void 0,ot[0])}for(U.position={start:It(D.length>0?D[0][1].start:{line:1,column:1,offset:0}),end:It(D.length>0?D[D.length-2][1].end:{line:1,column:1,offset:0})},Te=-1;++Te<t.transforms.length;)U=t.transforms[Te](U)||U;return U}function i(D,U,te){let le=U-1,Te=-1,ot=!1,$t,_t,Nn,Ln;for(;++le<=te;){const Ke=D[le];switch(Ke[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Ke[0]==="enter"?Te++:Te--,Ln=void 0;break}case"lineEndingBlank":{Ke[0]==="enter"&&($t&&!Ln&&!Te&&!Nn&&(Nn=le),Ln=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Ln=void 0}if(!Te&&Ke[0]==="enter"&&Ke[1].type==="listItemPrefix"||Te===-1&&Ke[0]==="exit"&&(Ke[1].type==="listUnordered"||Ke[1].type==="listOrdered")){if($t){let un=le;for(_t=void 0;un--;){const kt=D[un];if(kt[1].type==="lineEnding"||kt[1].type==="lineEndingBlank"){if(kt[0]==="exit")continue;_t&&(D[_t][1].type="lineEndingBlank",ot=!0),kt[1].type="lineEnding",_t=un}else if(!(kt[1].type==="linePrefix"||kt[1].type==="blockQuotePrefix"||kt[1].type==="blockQuotePrefixWhitespace"||kt[1].type==="blockQuoteMarker"||kt[1].type==="listItemIndent"))break}Nn&&(!_t||Nn<_t)&&($t._spread=!0),$t.end=Object.assign({},_t?D[_t][1].start:Ke[1].end),D.splice(_t||le,0,["exit",$t,Ke[2]]),le++,te++}if(Ke[1].type==="listItemPrefix"){const un={type:"listItem",_spread:!1,start:Object.assign({},Ke[1].start),end:void 0};$t=un,D.splice(le,0,["enter",un,Ke[2]]),le++,te++,Nn=void 0,Ln=!0}}}return D[U][1]._spread=ot,te}function a(D,U){return te;function te(le){o.call(this,D(le),le),U&&U.call(this,le)}}function s(){this.stack.push({type:"fragment",children:[]})}function o(D,U,te){this.stack[this.stack.length-1].children.push(D),this.stack.push(D),this.tokenStack.push([U,te||void 0]),D.position={start:It(U.start),end:void 0}}function u(D){return U;function U(te){D&&D.call(this,te),l.call(this,te)}}function l(D,U){const te=this.stack.pop(),le=this.tokenStack.pop();if(le)le[0].type!==D.type&&(U?U.call(this,D,le[0]):(le[1]||Tu).call(this,D,le[0]));else throw new Error("Cannot close `"+D.type+"` ("+er({start:D.start,end:D.end})+"): it’s not open");te.position.end=It(D.end)}function h(){return rs(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function p(D){if(this.data.expectingFirstListItemValue){const U=this.stack[this.stack.length-2];U.start=Number.parseInt(this.sliceSerialize(D),10),this.data.expectingFirstListItemValue=void 0}}function f(){const D=this.resume(),U=this.stack[this.stack.length-1];U.lang=D}function m(){const D=this.resume(),U=this.stack[this.stack.length-1];U.meta=D}function _(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function x(){const D=this.resume(),U=this.stack[this.stack.length-1];U.value=D.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function k(){const D=this.resume(),U=this.stack[this.stack.length-1];U.value=D.replace(/(\r?\n|\r)$/g,"")}function v(D){const U=this.resume(),te=this.stack[this.stack.length-1];te.label=U,te.identifier=lt(this.sliceSerialize(D)).toLowerCase()}function C(){const D=this.resume(),U=this.stack[this.stack.length-1];U.title=D}function R(){const D=this.resume(),U=this.stack[this.stack.length-1];U.url=D}function F(D){const U=this.stack[this.stack.length-1];if(!U.depth){const te=this.sliceSerialize(D).length;U.depth=te}}function S(){this.data.setextHeadingSlurpLineEnding=!0}function Y(D){const U=this.stack[this.stack.length-1];U.depth=this.sliceSerialize(D).codePointAt(0)===61?1:2}function L(){this.data.setextHeadingSlurpLineEnding=void 0}function O(D){const te=this.stack[this.stack.length-1].children;let le=te[te.length-1];(!le||le.type!=="text")&&(le=Th(),le.position={start:It(D.start),end:void 0},te.push(le)),this.stack.push(le)}function A(D){const U=this.stack.pop();U.value+=this.sliceSerialize(D),U.position.end=It(D.end)}function z(D){const U=this.stack[this.stack.length-1];if(this.data.atHardBreak){const te=U.children[U.children.length-1];te.position.end=It(D.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(U.type)&&(O.call(this,D),A.call(this,D))}function M(){this.data.atHardBreak=!0}function Q(){const D=this.resume(),U=this.stack[this.stack.length-1];U.value=D}function ue(){const D=this.resume(),U=this.stack[this.stack.length-1];U.value=D}function J(){const D=this.resume(),U=this.stack[this.stack.length-1];U.value=D}function oe(){const D=this.stack[this.stack.length-1];if(this.data.inReference){const U=this.data.referenceType||"shortcut";D.type+="Reference",D.referenceType=U,delete D.url,delete D.title}else delete D.identifier,delete D.label;this.data.referenceType=void 0}function q(){const D=this.stack[this.stack.length-1];if(this.data.inReference){const U=this.data.referenceType||"shortcut";D.type+="Reference",D.referenceType=U,delete D.url,delete D.title}else delete D.identifier,delete D.label;this.data.referenceType=void 0}function K(D){const U=this.sliceSerialize(D),te=this.stack[this.stack.length-2];te.label=Hb(U),te.identifier=lt(U).toLowerCase()}function W(){const D=this.stack[this.stack.length-1],U=this.resume(),te=this.stack[this.stack.length-1];if(this.data.inReference=!0,te.type==="link"){const le=D.children;te.children=le}else te.alt=U}function E(){const D=this.resume(),U=this.stack[this.stack.length-1];U.url=D}function he(){const D=this.resume(),U=this.stack[this.stack.length-1];U.title=D}function Z(){this.data.inReference=void 0}function w(){this.data.referenceType="collapsed"}function Se(D){const U=this.resume(),te=this.stack[this.stack.length-1];te.label=U,te.identifier=lt(this.sliceSerialize(D)).toLowerCase(),this.data.referenceType="full"}function me(D){this.data.characterReferenceType=D.type}function ne(D){const U=this.sliceSerialize(D),te=this.data.characterReferenceType;let le;te?(le=hd(U,te==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):le=as(U);const Te=this.stack[this.stack.length-1];Te.value+=le}function ze(D){const U=this.stack.pop();U.position.end=It(D.end)}function Ve(D){A.call(this,D);const U=this.stack[this.stack.length-1];U.url=this.sliceSerialize(D)}function ge(D){A.call(this,D);const U=this.stack[this.stack.length-1];U.url="mailto:"+this.sliceSerialize(D)}function st(){return{type:"blockquote",children:[]}}function nt(){return{type:"code",lang:null,meta:null,value:""}}function rt(){return{type:"inlineCode",value:""}}function In(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function on(){return{type:"emphasis",children:[]}}function Ls(){return{type:"heading",depth:0,children:[]}}function Rs(){return{type:"break"}}function Os(){return{type:"html",value:""}}function mh(){return{type:"image",title:null,url:"",alt:null}}function Ds(){return{type:"link",title:null,url:"",children:[]}}function Ps(D){return{type:"list",ordered:D.type==="listOrdered",start:null,spread:D._spread,children:[]}}function gh(D){return{type:"listItem",spread:D._spread,checked:null,children:[]}}function bh(){return{type:"paragraph",children:[]}}function Eh(){return{type:"strong",children:[]}}function Th(){return{type:"text",value:""}}function _h(){return{type:"thematicBreak"}}}function It(e){return{line:e.line,column:e.column,offset:e.offset}}function s0(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?s0(e,r):xk(e,r)}}function xk(e,t){let n;for(n in t)if(a0.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 Tu(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+er({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+er({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+er({start:t.start,end:t.end})+") is still open")}function yk(e){const t=this;t.parser=n;function n(r){return _k(r,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function wk(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 Ak(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
|
|
42
|
+
`}]}function Ck(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 Sk(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function vk(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Ik(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),i=vn(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 l={type:"element",tagName:"sup",properties:{},children:[u]};return e.patch(t,l),e.applyData(t,l)}function Nk(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 Lk(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function o0(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 Rk(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return o0(e,t);const i={src:vn(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 Ok(e,t){const n={src:vn(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 Dk(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 Pk(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return o0(e,t);const i={href:vn(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 Mk(e,t){const n={href:vn(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 Bk(e,t,n){const r=e.all(t),i=n?Fk(n):u0(t),a={},s=[];if(typeof t.checked=="boolean"){const h=r[0];let d;h&&h.type==="element"&&h.tagName==="p"?d=h:(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 h=r[o];(i||o!==0||h.type!=="element"||h.tagName!=="p")&&s.push({type:"text",value:`
|
|
44
44
|
`}),h.type==="element"&&h.tagName==="p"&&!i?s.push(...h.children):s.push(h)}const u=r[r.length-1];u&&(i||u.type!=="element"||u.tagName!=="p")&&s.push({type:"text",value:`
|
|
45
|
-
`});const l={type:"element",tagName:"li",properties:a,children:s};return e.patch(t,l),e.applyData(t,l)}function
|
|
45
|
+
`});const l={type:"element",tagName:"li",properties:a,children:s};return e.patch(t,l),e.applyData(t,l)}function Fk(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=u0(n[r])}return t}function u0(e){const t=e.spread;return t??e.children.length>1}function Hk(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 Uk(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function zk(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function $k(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Yk(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=Et(t.children[1]),u=ki(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 jk(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 l=[];for(;++u<o;){const d=t.children[u],p={},f=s?s[u]:void 0;f&&(p.align=f);let m={type:"element",tagName:a,properties:p,children:[]};d&&(m.children=e.all(d),e.patch(d,m),m=e.applyData(d,m)),l.push(m)}const h={type:"element",tagName:"tr",properties:{},children:e.wrap(l,!0)};return e.patch(t,h),e.applyData(t,h)}function Vk(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const _u=9,ku=32;function qk(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),i=0;const a=[];for(;r;)a.push(xu(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return a.push(xu(t.slice(i),i>0,!1)),a.join("")}function xu(e,t,n){let r=0,i=e.length;if(t){let a=e.codePointAt(r);for(;a===_u||a===ku;)r++,a=e.codePointAt(r)}if(n){let a=e.codePointAt(i-1);for(;a===_u||a===ku;)i--,a=e.codePointAt(i-1)}return i>r?e.slice(r,i):""}function Wk(e,t){const n={type:"text",value:qk(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function Gk(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const Qk={blockquote:wk,break:Ak,code:Ck,delete:Sk,emphasis:vk,footnoteReference:Ik,heading:Nk,html:Lk,imageReference:Rk,image:Ok,inlineCode:Dk,linkReference:Pk,link:Mk,listItem:Bk,list:Hk,paragraph:Uk,root:zk,strong:$k,table:Yk,tableCell:Vk,tableRow:jk,text:Wk,thematicBreak:Gk,toml:Cr,yaml:Cr,definition:Cr,footnoteDefinition:Cr};function Cr(){}function Kk(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 Xk(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function Zk(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||Kk,r=e.options.footnoteBackLabel||Xk,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 l=e.footnoteById.get(e.footnoteOrder[u]);if(!l)continue;const h=e.all(l),d=String(l.identifier).toUpperCase(),p=vn(d.toLowerCase());let f=0;const m=[],_=e.footnoteCounts.get(d);for(;_!==void 0&&++f<=_;){m.length>0&&m.push({type:"text",value:" "});let v=typeof n=="string"?n:n(u,f);typeof v=="string"&&(v={type:"text",value:v}),m.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+p+(f>1?"-"+f:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(u,f),className:["data-footnote-backref"]},children:Array.isArray(v)?v:[v]})}const x=h[h.length-1];if(x&&x.type==="element"&&x.tagName==="p"){const v=x.children[x.children.length-1];v&&v.type==="text"?v.value+=" ":x.children.push({type:"text",value:" "}),x.children.push(...m)}else h.push(...m);const k={type:"element",tagName:"li",properties:{id:t+"fn-"+p},children:e.wrap(h,!0)};e.patch(l,k),o.push(k)}if(o.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:a,properties:{...Zt(s),id:"footnote-label"},children:[{type:"text",value:i}]},{type:"text",value:`
|
|
46
46
|
`},{type:"element",tagName:"ol",properties:{},children:e.wrap(o,!0)},{type:"text",value:`
|
|
47
|
-
`}]}}const
|
|
47
|
+
`}]}}const ya={}.hasOwnProperty,Jk={};function e6(e,t){const n=t||Jk,r=new Map,i=new Map,a=new Map,s={...Qk,...n.handlers},o={all:l,applyData:n6,definitionById:r,footnoteById:i,footnoteCounts:a,footnoteOrder:[],handlers:s,one:u,options:n,patch:t6,wrap:i6};return Mt(e,function(h){if(h.type==="definition"||h.type==="footnoteDefinition"){const d=h.type==="definition"?r:i,p=String(h.identifier).toUpperCase();d.has(p)||d.set(p,h)}}),o;function u(h,d){const p=h.type,f=o.handlers[p];if(ya.call(o.handlers,p)&&f)return f(o,h,d);if(o.options.passThrough&&o.options.passThrough.includes(p)){if("children"in h){const{children:_,...x}=h,k=Zt(x);return k.children=o.all(h),k}return Zt(h)}return(o.options.unknownHandler||r6)(o,h,d)}function l(h){const d=[];if("children"in h){const p=h.children;let f=-1;for(;++f<p.length;){const m=o.one(p[f],h);if(m){if(f&&p[f-1].type==="break"&&(!Array.isArray(m)&&m.type==="text"&&(m.value=yu(m.value)),!Array.isArray(m)&&m.type==="element")){const _=m.children[0];_&&_.type==="text"&&(_.value=yu(_.value))}Array.isArray(m)?d.push(...m):d.push(m)}}}return d}}function t6(e,t){e.position&&(t.position=zc(e))}function n6(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,Zt(a)),"children"in n&&n.children&&i!==null&&i!==void 0&&(n.children=i)}return n}function r6(e,t){const n=t.data||{},r="value"in t&&!(ya.call(n,"hProperties")||ya.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 i6(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
|
|
48
48
|
`});++r<e.length;)r&&n.push({type:"text",value:`
|
|
49
49
|
`}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
|
|
50
|
-
`}),n}function
|
|
51
|
-
`},i),a}function Xk(e,t){return e&&"run"in e?async function(n,r){const i=xu(n,{file:r,...t});await e.run(i,r)}:function(n,r){return xu(n,{file:r,...e||t})}}function yu(e){if(e)throw e}var Hr=Object.prototype.hasOwnProperty,o0=Object.prototype.toString,wu=Object.defineProperty,Au=Object.getOwnPropertyDescriptor,Cu=function(t){return typeof Array.isArray=="function"?Array.isArray(t):o0.call(t)==="[object Array]"},Su=function(t){if(!t||o0.call(t)!=="[object Object]")return!1;var n=Hr.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&Hr.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var i;for(i in t);return typeof i>"u"||Hr.call(t,i)},vu=function(t,n){wu&&n.name==="__proto__"?wu(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},Iu=function(t,n){if(n==="__proto__")if(Hr.call(t,n)){if(Au)return Au(t,n).value}else return;return t[n]},Zk=function e(){var t,n,r,i,a,s,o=arguments[0],u=1,l=arguments.length,h=!1;for(typeof o=="boolean"&&(h=o,o=arguments[1]||{},u=2),(o==null||typeof o!="object"&&typeof o!="function")&&(o={});u<l;++u)if(t=arguments[u],t!=null)for(n in t)r=Iu(o,n),i=Iu(t,n),o!==i&&(h&&i&&(Su(i)||(a=Cu(i)))?(a?(a=!1,s=r&&Cu(r)?r:[]):s=r&&Su(r)?r:{},vu(o,{name:n,newValue:e(h,s,i)})):typeof i<"u"&&vu(o,{name:n,newValue:i}));return o};const qi=Kd(Zk);function xa(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 Jk(){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,...l){const h=e[++a];let d=-1;if(u){s(u);return}for(;++d<i.length;)(l[d]===null||l[d]===void 0)&&(l[d]=i[d]);i=l,h?e6(h,o)(...l):s(null,...l)}}function r(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function e6(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(l){const h=l;if(o&&n)throw h;return i(h)}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 ht={basename:t6,dirname:n6,extname:r6,join:i6,sep:"/"};function t6(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Er(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 n6(e){if(Er(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 r6(e){Er(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 i6(...e){let t=-1,n;for(;++t<e.length;)Er(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":a6(n)}function a6(e){Er(e);const t=e.codePointAt(0)===47;let n=s6(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function s6(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 Er(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const o6={cwd:u6};function u6(){return"/"}function ya(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function l6(e){if(typeof e=="string")e=new URL(e);else if(!ya(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 c6(e)}function c6(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 Wi=["history","path","basename","stem","extname","dirname"];class d6{constructor(t){let n;t?ya(t)?n={path:t}:typeof t=="string"||h6(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":o6.cwd(),this.data={},this.history=[],this.messages=[];let r=-1;for(;++r<Wi.length;){const a=Wi[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)Wi.includes(i)||(this[i]=n[i])}get basename(){return typeof this.path=="string"?ht.basename(this.path):void 0}set basename(t){Qi(t,"basename"),Gi(t,"basename"),this.path=ht.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?ht.dirname(this.path):void 0}set dirname(t){Nu(this.basename,"dirname"),this.path=ht.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?ht.extname(this.path):void 0}set extname(t){if(Gi(t,"extname"),Nu(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=ht.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){ya(t)&&(t=l6(t)),Qi(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?ht.basename(this.path,this.extname):void 0}set stem(t){Qi(t,"stem"),Gi(t,"stem"),this.path=ht.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 He(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 Gi(e,t){if(e&&e.includes(ht.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+ht.sep+"`")}function Qi(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Nu(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function h6(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const f6=function(e){const r=this.constructor.prototype,i=r[e],a=function(){return i.apply(a,arguments)};return Object.setPrototypeOf(a,r),a},p6={}.hasOwnProperty;class ps extends f6{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=Jk()}copy(){const t=new ps;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(qi(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(Zi("data",this.frozen),this.namespace[t]=n,this):p6.call(this.namespace,t)&&this.namespace[t]||void 0:t?(Zi("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=Sr(t),r=this.parser||this.Parser;return Ki("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),Ki("process",this.parser||this.Parser),Xi("process",this.compiler||this.Compiler),n?i(void 0,n):new Promise(i);function i(a,s){const o=Sr(t),u=r.parse(o);r.run(u,o,function(h,d,p){if(h||!d||!p)return l(h);const f=d,m=r.stringify(f,p);b6(m)?p.value=m:p.result=m,l(h,p)});function l(h,d){h||!d?s(h):a?a(d):n(void 0,d)}}}processSync(t){let n=!1,r;return this.freeze(),Ki("processSync",this.parser||this.Parser),Xi("processSync",this.compiler||this.Compiler),this.process(t,i),Ru("processSync","process",n),r;function i(a,s){n=!0,yu(a),r=s}}run(t,n,r){Lu(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=Sr(n);i.run(t,u,l);function l(h,d,p){const f=d||t;h?o(h):s?s(f):r(void 0,f,p)}}}runSync(t,n){let r=!1,i;return this.run(t,n,a),Ru("runSync","run",r),i;function a(s,o){yu(s),i=o,r=!0}}stringify(t,n){this.freeze();const r=Sr(n),i=this.compiler||this.Compiler;return Xi("stringify",i),Lu(t),i(t,r)}use(t,...n){const r=this.attachers,i=this.namespace;if(Zi("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(l){if(typeof l=="function")u(l,[]);else if(typeof l=="object")if(Array.isArray(l)){const[h,...d]=l;u(h,d)}else s(l);else throw new TypeError("Expected usable value, not `"+l+"`")}function s(l){if(!("plugins"in l)&&!("settings"in l))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(l.plugins),l.settings&&(i.settings=qi(!0,i.settings,l.settings))}function o(l){let h=-1;if(l!=null)if(Array.isArray(l))for(;++h<l.length;){const d=l[h];a(d)}else throw new TypeError("Expected a list of plugins, not `"+l+"`")}function u(l,h){let d=-1,p=-1;for(;++d<r.length;)if(r[d][0]===l){p=d;break}if(p===-1)r.push([l,...h]);else if(h.length>0){let[f,...m]=h;const _=r[p][1];xa(_)&&xa(f)&&(f=qi(!0,_,f)),r[p]=[l,f,...m]}}}}const m6=new ps().freeze();function Ki(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Xi(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function Zi(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 Lu(e){if(!xa(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Ru(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Sr(e){return g6(e)?e:new d6(e)}function g6(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function b6(e){return typeof e=="string"||E6(e)}function E6(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}function ms(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var sn=ms();function u0(e){sn=e}var Gt={exec:()=>null};function de(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(Ye.caret,"$1"),n=n.replace(i,s),r},getRegex:()=>new RegExp(n,t)};return r}var T6=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),Ye={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)}}>`)},_6=/^(?:[ \t]*(?:\n|$))+/,k6=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,x6=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,Tr=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,y6=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,gs=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,l0=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,c0=de(l0).replace(/bull/g,gs).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(),w6=de(l0).replace(/bull/g,gs).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(),bs=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,A6=/^[^\n]+/,Es=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,C6=de(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Es).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),S6=de(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,gs).getRegex(),wi="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",Ts=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,v6=de("^ {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",Ts).replace("tag",wi).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),d0=de(bs).replace("hr",Tr).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",wi).getRegex(),I6=de(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",d0).getRegex(),_s={blockquote:I6,code:k6,def:C6,fences:x6,heading:y6,hr:Tr,html:v6,lheading:c0,list:S6,newline:_6,paragraph:d0,table:Gt,text:A6},Ou=de("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",Tr).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",wi).getRegex(),N6={..._s,lheading:w6,table:Ou,paragraph:de(bs).replace("hr",Tr).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Ou).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",wi).getRegex()},L6={..._s,html:de(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Ts).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:Gt,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:de(bs).replace("hr",Tr).replace("heading",` *#{1,6} *[^
|
|
52
|
-
]`).replace("lheading",
|
|
50
|
+
`}),n}function yu(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function wu(e,t){const n=e6(e,t),r=n.one(e,void 0),i=Zk(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 a6(e,t){return e&&"run"in e?async function(n,r){const i=wu(n,{file:r,...t});await e.run(i,r)}:function(n,r){return wu(n,{file:r,...e||t})}}function Au(e){if(e)throw e}var Hr=Object.prototype.hasOwnProperty,l0=Object.prototype.toString,Cu=Object.defineProperty,Su=Object.getOwnPropertyDescriptor,vu=function(t){return typeof Array.isArray=="function"?Array.isArray(t):l0.call(t)==="[object Array]"},Iu=function(t){if(!t||l0.call(t)!=="[object Object]")return!1;var n=Hr.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&Hr.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var i;for(i in t);return typeof i>"u"||Hr.call(t,i)},Nu=function(t,n){Cu&&n.name==="__proto__"?Cu(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},Lu=function(t,n){if(n==="__proto__")if(Hr.call(t,n)){if(Su)return Su(t,n).value}else return;return t[n]},s6=function e(){var t,n,r,i,a,s,o=arguments[0],u=1,l=arguments.length,h=!1;for(typeof o=="boolean"&&(h=o,o=arguments[1]||{},u=2),(o==null||typeof o!="object"&&typeof o!="function")&&(o={});u<l;++u)if(t=arguments[u],t!=null)for(n in t)r=Lu(o,n),i=Lu(t,n),o!==i&&(h&&i&&(Iu(i)||(a=vu(i)))?(a?(a=!1,s=r&&vu(r)?r:[]):s=r&&Iu(r)?r:{},Nu(o,{name:n,newValue:e(h,s,i)})):typeof i<"u"&&Nu(o,{name:n,newValue:i}));return o};const Gi=Zd(s6);function wa(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 o6(){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,...l){const h=e[++a];let d=-1;if(u){s(u);return}for(;++d<i.length;)(l[d]===null||l[d]===void 0)&&(l[d]=i[d]);i=l,h?u6(h,o)(...l):s(null,...l)}}function r(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function u6(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(l){const h=l;if(o&&n)throw h;return i(h)}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 ht={basename:l6,dirname:c6,extname:d6,join:h6,sep:"/"};function l6(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Er(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 c6(e){if(Er(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 d6(e){Er(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 h6(...e){let t=-1,n;for(;++t<e.length;)Er(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":f6(n)}function f6(e){Er(e);const t=e.codePointAt(0)===47;let n=p6(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function p6(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 Er(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const m6={cwd:g6};function g6(){return"/"}function Aa(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function b6(e){if(typeof e=="string")e=new URL(e);else if(!Aa(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 E6(e)}function E6(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 Qi=["history","path","basename","stem","extname","dirname"];class T6{constructor(t){let n;t?Aa(t)?n={path:t}:typeof t=="string"||_6(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":m6.cwd(),this.data={},this.history=[],this.messages=[];let r=-1;for(;++r<Qi.length;){const a=Qi[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)Qi.includes(i)||(this[i]=n[i])}get basename(){return typeof this.path=="string"?ht.basename(this.path):void 0}set basename(t){Xi(t,"basename"),Ki(t,"basename"),this.path=ht.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?ht.dirname(this.path):void 0}set dirname(t){Ru(this.basename,"dirname"),this.path=ht.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?ht.extname(this.path):void 0}set extname(t){if(Ki(t,"extname"),Ru(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=ht.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){Aa(t)&&(t=b6(t)),Xi(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?ht.basename(this.path,this.extname):void 0}set stem(t){Xi(t,"stem"),Ki(t,"stem"),this.path=ht.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 Ue(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 Ki(e,t){if(e&&e.includes(ht.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+ht.sep+"`")}function Xi(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Ru(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function _6(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const k6=function(e){const r=this.constructor.prototype,i=r[e],a=function(){return i.apply(a,arguments)};return Object.setPrototypeOf(a,r),a},x6={}.hasOwnProperty;class gs extends k6{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=o6()}copy(){const t=new gs;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(Gi(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(ea("data",this.frozen),this.namespace[t]=n,this):x6.call(this.namespace,t)&&this.namespace[t]||void 0:t?(ea("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=Sr(t),r=this.parser||this.Parser;return Zi("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),Zi("process",this.parser||this.Parser),Ji("process",this.compiler||this.Compiler),n?i(void 0,n):new Promise(i);function i(a,s){const o=Sr(t),u=r.parse(o);r.run(u,o,function(h,d,p){if(h||!d||!p)return l(h);const f=d,m=r.stringify(f,p);A6(m)?p.value=m:p.result=m,l(h,p)});function l(h,d){h||!d?s(h):a?a(d):n(void 0,d)}}}processSync(t){let n=!1,r;return this.freeze(),Zi("processSync",this.parser||this.Parser),Ji("processSync",this.compiler||this.Compiler),this.process(t,i),Du("processSync","process",n),r;function i(a,s){n=!0,Au(a),r=s}}run(t,n,r){Ou(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=Sr(n);i.run(t,u,l);function l(h,d,p){const f=d||t;h?o(h):s?s(f):r(void 0,f,p)}}}runSync(t,n){let r=!1,i;return this.run(t,n,a),Du("runSync","run",r),i;function a(s,o){Au(s),i=o,r=!0}}stringify(t,n){this.freeze();const r=Sr(n),i=this.compiler||this.Compiler;return Ji("stringify",i),Ou(t),i(t,r)}use(t,...n){const r=this.attachers,i=this.namespace;if(ea("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(l){if(typeof l=="function")u(l,[]);else if(typeof l=="object")if(Array.isArray(l)){const[h,...d]=l;u(h,d)}else s(l);else throw new TypeError("Expected usable value, not `"+l+"`")}function s(l){if(!("plugins"in l)&&!("settings"in l))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(l.plugins),l.settings&&(i.settings=Gi(!0,i.settings,l.settings))}function o(l){let h=-1;if(l!=null)if(Array.isArray(l))for(;++h<l.length;){const d=l[h];a(d)}else throw new TypeError("Expected a list of plugins, not `"+l+"`")}function u(l,h){let d=-1,p=-1;for(;++d<r.length;)if(r[d][0]===l){p=d;break}if(p===-1)r.push([l,...h]);else if(h.length>0){let[f,...m]=h;const _=r[p][1];wa(_)&&wa(f)&&(f=Gi(!0,_,f)),r[p]=[l,f,...m]}}}}const y6=new gs().freeze();function Zi(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Ji(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function ea(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 Ou(e){if(!wa(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Du(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Sr(e){return w6(e)?e:new T6(e)}function w6(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function A6(e){return typeof e=="string"||C6(e)}function C6(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}function bs(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var sn=bs();function c0(e){sn=e}var Gt={exec:()=>null};function de(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 S6=(()=>{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)}}>`)},v6=/^(?:[ \t]*(?:\n|$))+/,I6=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,N6=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,Tr=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,L6=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Es=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,d0=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,h0=de(d0).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(),R6=de(d0).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]+)*)/,O6=/^[^\n]+/,_s=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,D6=de(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",_s).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),P6=de(/^(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",ks=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,M6=de("^ {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",ks).replace("tag",Ci).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),f0=de(Ts).replace("hr",Tr).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",Ci).getRegex(),B6=de(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",f0).getRegex(),xs={blockquote:B6,code:I6,def:D6,fences:N6,heading:L6,hr:Tr,html:M6,lheading:h0,list:P6,newline:v6,paragraph:f0,table:Gt,text:O6},Pu=de("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",Tr).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",Ci).getRegex(),F6={...xs,lheading:R6,table:Pu,paragraph:de(Ts).replace("hr",Tr).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Pu).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",Ci).getRegex()},H6={...xs,html:de(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",ks).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:Gt,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:de(Ts).replace("hr",Tr).replace("heading",` *#{1,6} *[^
|
|
52
|
+
]`).replace("lheading",h0).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},U6=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,z6=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,p0=/^( {2,}|\\)\n(?!\s*$)/,$6=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Si=/[\p{P}\p{S}]/u,ys=/[\s\p{P}\p{S}]/u,m0=/[^\s\p{P}\p{S}]/u,Y6=de(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,ys).getRegex(),g0=/(?!~)[\p{P}\p{S}]/u,j6=/(?!~)[\s\p{P}\p{S}]/u,V6=/(?:[^\s\p{P}\p{S}]|~)/u,b0=/(?![*_])[\p{P}\p{S}]/u,q6=/(?![*_])[\s\p{P}\p{S}]/u,W6=/(?:[^\s\p{P}\p{S}]|[*_])/u,G6=de(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",S6?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),E0=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,Q6=de(E0,"u").replace(/punct/g,Si).getRegex(),K6=de(E0,"u").replace(/punct/g,g0).getRegex(),T0="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",X6=de(T0,"gu").replace(/notPunctSpace/g,m0).replace(/punctSpace/g,ys).replace(/punct/g,Si).getRegex(),Z6=de(T0,"gu").replace(/notPunctSpace/g,V6).replace(/punctSpace/g,j6).replace(/punct/g,g0).getRegex(),J6=de("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,m0).replace(/punctSpace/g,ys).replace(/punct/g,Si).getRegex(),ex=de(/^~~?(?:((?!~)punct)|[^\s~])/,"u").replace(/punct/g,b0).getRegex(),tx="^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)",nx=de(tx,"gu").replace(/notPunctSpace/g,W6).replace(/punctSpace/g,q6).replace(/punct/g,b0).getRegex(),rx=de(/\\(punct)/,"gu").replace(/punct/g,Si).getRegex(),ix=de(/^<(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(),ax=de(ks).replace("(?:-->|$)","-->").getRegex(),sx=de("^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",ax).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),ri=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,ox=de(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",ri).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),_0=de(/^!?\[(label)\]\[(ref)\]/).replace("label",ri).replace("ref",_s).getRegex(),k0=de(/^!?\[(ref)\](?:\[\])?/).replace("ref",_s).getRegex(),ux=de("reflink|nolink(?!\\()","g").replace("reflink",_0).replace("nolink",k0).getRegex(),Mu=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,ws={_backpedal:Gt,anyPunctuation:rx,autolink:ix,blockSkip:G6,br:p0,code:z6,del:Gt,delLDelim:Gt,delRDelim:Gt,emStrongLDelim:Q6,emStrongRDelimAst:X6,emStrongRDelimUnd:J6,escape:U6,link:ox,nolink:k0,punctuation:Y6,reflink:_0,reflinkSearch:ux,tag:sx,text:$6,url:Gt},lx={...ws,link:de(/^!?\[(label)\]\((.*?)\)/).replace("label",ri).getRegex(),reflink:de(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",ri).getRegex()},Ca={...ws,emStrongRDelimAst:Z6,emStrongLDelim:K6,delLDelim:ex,delRDelim:nx,url:de(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",Mu).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:de(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",Mu).getRegex()},cx={...Ca,br:de(p0).replace("{2,}","*").getRegex(),text:de(Ca.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},vr={normal:xs,gfm:F6,pedantic:H6},Bn={normal:ws,gfm:Ca,breaks:cx,pedantic:lx},dx={"&":"&","<":"<",">":">",'"':""","'":"'"},Bu=e=>dx[e];function dt(e,t){if(t){if(je.escapeTest.test(e))return e.replace(je.escapeReplace,Bu)}else if(je.escapeTestNoEncode.test(e))return e.replace(je.escapeReplaceNoEncode,Bu);return e}function Fu(e){try{e=encodeURI(e).replace(je.percentDecode,"%")}catch{return null}return e}function Hu(e,t){var a;let n=e.replace(je.findPipe,(s,o,u)=>{let l=!1,h=o;for(;--h>=0&&u[h]==="\\";)l=!l;return l?"|":" |"}),r=n.split(je.splitPipe),i=0;if(r[0].trim()||r.shift(),r.length>0&&!((a=r.at(-1))!=null&&a.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 Fn(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 hx(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 fx(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 Uu(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 px(e,t,n){let r=e.match(n.other.indentCodeCompensation);if(r===null)return t;let i=r[1];return t.split(`
|
|
53
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(`
|
|
54
|
-
`)}var
|
|
55
|
-
`)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let n=t[0],r=
|
|
56
|
-
`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let n=
|
|
54
|
+
`)}var ii=class{constructor(e){be(this,"options");be(this,"rules");be(this,"lexer");this.options=e||sn}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:Fn(n,`
|
|
55
|
+
`)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let n=t[0],r=px(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=Fn(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:Fn(t[0],`
|
|
56
|
+
`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let n=Fn(t[0],`
|
|
57
57
|
`).split(`
|
|
58
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 l=o.join(`
|
|
59
59
|
`),h=l.replace(this.rules.other.blockquoteSetextReplace,`
|
|
@@ -64,17 +64,17 @@ ${h}`:h;let d=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTo
|
|
|
64
64
|
`),_=this.blockquote(m);a[a.length-1]=_,r=r.substring(0,r.length-f.raw.length)+_.raw,i=i.substring(0,i.length-f.text.length)+_.text;break}else if((p==null?void 0:p.type)==="list"){let f=p,m=f.raw+`
|
|
65
65
|
`+n.join(`
|
|
66
66
|
`),_=this.list(m);a[a.length-1]=_,r=r.substring(0,r.length-p.raw.length)+_.raw,i=i.substring(0,i.length-f.raw.length)+_.raw,n=m.substring(a.at(-1).raw.length).split(`
|
|
67
|
-
`);continue}}return{type:"blockquote",raw:r,tokens:a,text:i}}}list(e){var n,r;let t=this.rules.block.list.exec(e);if(t){let i=t[1].trim(),a=i.length>1,s={type:"list",raw:"",ordered:a,start:a?+i.slice(0,-1):"",loose:!1,items:[]};i=a?`\\d{1,9}\\${i.slice(-1)}`:`\\${i}`,this.options.pedantic&&(i=a?i:"[*+-]");let o=this.rules.other.listItemRegex(i),u=!1;for(;e;){let h=!1,d="",p="";if(!(t=o.exec(e))||this.rules.block.hr.test(e))break;d=t[0],e=e.substring(d.length);let f=
|
|
67
|
+
`);continue}}return{type:"blockquote",raw:r,tokens:a,text:i}}}list(e){var n,r;let t=this.rules.block.list.exec(e);if(t){let i=t[1].trim(),a=i.length>1,s={type:"list",raw:"",ordered:a,start:a?+i.slice(0,-1):"",loose:!1,items:[]};i=a?`\\d{1,9}\\${i.slice(-1)}`:`\\${i}`,this.options.pedantic&&(i=a?i:"[*+-]");let o=this.rules.other.listItemRegex(i),u=!1;for(;e;){let h=!1,d="",p="";if(!(t=o.exec(e))||this.rules.block.hr.test(e))break;d=t[0],e=e.substring(d.length);let f=fx(t[2].split(`
|
|
68
68
|
`,1)[0],t[1].length),m=e.split(`
|
|
69
69
|
`,1)[0],_=!f.trim(),x=0;if(this.options.pedantic?(x=2,p=f.trimStart()):_?x=t[1].length+1:(x=f.search(this.rules.other.nonSpaceChar),x=x>4?1:x,p=f.slice(x),x+=t[1].length),_&&this.rules.other.blankLine.test(m)&&(d+=m+`
|
|
70
70
|
`,e=e.substring(m.length+1),h=!0),!h){let k=this.rules.other.nextBulletRegex(x),v=this.rules.other.hrRegex(x),C=this.rules.other.fencesBeginRegex(x),R=this.rules.other.headingBeginRegex(x),F=this.rules.other.htmlBeginRegex(x),S=this.rules.other.blockquoteBeginRegex(x);for(;e;){let Y=e.split(`
|
|
71
71
|
`,1)[0],L;if(m=Y,this.options.pedantic?(m=m.replace(this.rules.other.listReplaceNesting," "),L=m):L=m.replace(this.rules.other.tabCharGlobal," "),C.test(m)||R.test(m)||F.test(m)||S.test(m)||k.test(m)||v.test(m))break;if(L.search(this.rules.other.nonSpaceChar)>=x||!m.trim())p+=`
|
|
72
72
|
`+L.slice(x);else{if(_||f.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||C.test(f)||R.test(f)||v.test(f))break;p+=`
|
|
73
73
|
`+m}_=!m.trim(),d+=Y+`
|
|
74
|
-
`,e=e.substring(Y.length+1),f=L.slice(x)}}s.loose||(u?s.loose=!0:this.rules.other.doubleBlankLine.test(d)&&(u=!0)),s.items.push({type:"list_item",raw:d,task:!!this.options.gfm&&this.rules.other.listIsTask.test(p),loose:!1,text:p,tokens:[]}),s.raw+=d}let l=s.items.at(-1);if(l)l.raw=l.raw.trimEnd(),l.text=l.text.trimEnd();else return;s.raw=s.raw.trimEnd();for(let h of s.items){if(this.lexer.state.top=!1,h.tokens=this.lexer.blockTokens(h.text,[]),h.task){if(h.text=h.text.replace(this.rules.other.listReplaceTask,""),((n=h.tokens[0])==null?void 0:n.type)==="text"||((r=h.tokens[0])==null?void 0:r.type)==="paragraph"){h.tokens[0].raw=h.tokens[0].raw.replace(this.rules.other.listReplaceTask,""),h.tokens[0].text=h.tokens[0].text.replace(this.rules.other.listReplaceTask,"");for(let p=this.lexer.inlineQueue.length-1;p>=0;p--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[p].src)){this.lexer.inlineQueue[p].src=this.lexer.inlineQueue[p].src.replace(this.rules.other.listReplaceTask,"");break}}let d=this.rules.other.listTaskCheckbox.exec(h.raw);if(d){let p={type:"checkbox",raw:d[0]+" ",checked:d[0]!=="[ ]"};h.checked=p.checked,s.loose?h.tokens[0]&&["paragraph","text"].includes(h.tokens[0].type)&&"tokens"in h.tokens[0]&&h.tokens[0].tokens?(h.tokens[0].raw=p.raw+h.tokens[0].raw,h.tokens[0].text=p.raw+h.tokens[0].text,h.tokens[0].tokens.unshift(p)):h.tokens.unshift({type:"paragraph",raw:p.raw,text:p.raw,tokens:[p]}):h.tokens.unshift(p)}}if(!s.loose){let d=h.tokens.filter(f=>f.type==="space"),p=d.length>0&&d.some(f=>this.rules.other.anyLine.test(f.raw));s.loose=p}}if(s.loose)for(let h of s.items){h.loose=!0;for(let d of h.tokens)d.type==="text"&&(d.type="paragraph")}return s}}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){var s;let t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let n=
|
|
75
|
-
`):[],a={type:"table",raw:t[0],header:[],align:[],rows:[]};if(n.length===r.length){for(let o of r)this.rules.other.tableAlignRight.test(o)?a.align.push("right"):this.rules.other.tableAlignCenter.test(o)?a.align.push("center"):this.rules.other.tableAlignLeft.test(o)?a.align.push("left"):a.align.push(null);for(let o=0;o<n.length;o++)a.header.push({text:n[o],tokens:this.lexer.inline(n[o]),header:!0,align:a.align[o]});for(let o of i)a.rows.push(
|
|
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=
|
|
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){var i,a,s;for(this.options.pedantic&&(t=t.replace(
|
|
74
|
+
`,e=e.substring(Y.length+1),f=L.slice(x)}}s.loose||(u?s.loose=!0:this.rules.other.doubleBlankLine.test(d)&&(u=!0)),s.items.push({type:"list_item",raw:d,task:!!this.options.gfm&&this.rules.other.listIsTask.test(p),loose:!1,text:p,tokens:[]}),s.raw+=d}let l=s.items.at(-1);if(l)l.raw=l.raw.trimEnd(),l.text=l.text.trimEnd();else return;s.raw=s.raw.trimEnd();for(let h of s.items){if(this.lexer.state.top=!1,h.tokens=this.lexer.blockTokens(h.text,[]),h.task){if(h.text=h.text.replace(this.rules.other.listReplaceTask,""),((n=h.tokens[0])==null?void 0:n.type)==="text"||((r=h.tokens[0])==null?void 0:r.type)==="paragraph"){h.tokens[0].raw=h.tokens[0].raw.replace(this.rules.other.listReplaceTask,""),h.tokens[0].text=h.tokens[0].text.replace(this.rules.other.listReplaceTask,"");for(let p=this.lexer.inlineQueue.length-1;p>=0;p--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[p].src)){this.lexer.inlineQueue[p].src=this.lexer.inlineQueue[p].src.replace(this.rules.other.listReplaceTask,"");break}}let d=this.rules.other.listTaskCheckbox.exec(h.raw);if(d){let p={type:"checkbox",raw:d[0]+" ",checked:d[0]!=="[ ]"};h.checked=p.checked,s.loose?h.tokens[0]&&["paragraph","text"].includes(h.tokens[0].type)&&"tokens"in h.tokens[0]&&h.tokens[0].tokens?(h.tokens[0].raw=p.raw+h.tokens[0].raw,h.tokens[0].text=p.raw+h.tokens[0].text,h.tokens[0].tokens.unshift(p)):h.tokens.unshift({type:"paragraph",raw:p.raw,text:p.raw,tokens:[p]}):h.tokens.unshift(p)}}if(!s.loose){let d=h.tokens.filter(f=>f.type==="space"),p=d.length>0&&d.some(f=>this.rules.other.anyLine.test(f.raw));s.loose=p}}if(s.loose)for(let h of s.items){h.loose=!0;for(let d of h.tokens)d.type==="text"&&(d.type="paragraph")}return s}}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){var s;let t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let n=Hu(t[1]),r=t[2].replace(this.rules.other.tableAlignChars,"").split("|"),i=(s=t[3])!=null&&s.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 o of r)this.rules.other.tableAlignRight.test(o)?a.align.push("right"):this.rules.other.tableAlignCenter.test(o)?a.align.push("center"):this.rules.other.tableAlignLeft.test(o)?a.align.push("left"):a.align.push(null);for(let o=0;o<n.length;o++)a.header.push({text:n[o],tokens:this.lexer.inline(n[o]),header:!0,align:a.align[o]});for(let o of i)a.rows.push(Hu(o,a.header.length).map((u,l)=>({text:u,tokens:this.lexer.inline(u),header:!1,align:a.align[l]})));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=Fn(n.slice(0,-1),"\\");if((n.length-a.length)%2===0)return}else{let a=hx(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)),Uu(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 Uu(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,l=r[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(l.lastIndex=0,t=t.slice(-1*e.length+i);(r=l.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 h=[...r[0]][0].length,d=e.slice(0,i+r.index+h+s);if(Math.min(i,s)%2){let f=d.slice(1,-1);return{type:"em",raw:d,text:f,tokens:this.lexer.inlineTokens(f)}}let p=d.slice(2,-2);return{type:"strong",raw:d,text:p,tokens:this.lexer.inlineTokens(p)}}}}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 l=[...r[0]][0].length,h=e.slice(0,i+r.index+l+s),d=h.slice(i,-i);return{type:"del",raw:h,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){var n;let t;if(t=this.rules.inline.url.exec(e)){let r,i;if(t[2]==="@")r=t[0],i="mailto:"+r;else{let a;do a=t[0],t[0]=((n=this.rules.inline._backpedal.exec(t[0]))==null?void 0:n[0])??"";while(a!==t[0]);r=t[0],t[1]==="www."?i="http://"+t[0]:i=t[0]}return{type:"link",raw:t[0],text:r,href:i,tokens:[{type:"text",raw:r,text:r}]}}}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 Sa{constructor(t){be(this,"tokens");be(this,"options");be(this,"state");be(this,"inlineQueue");be(this,"tokenizer");this.tokens=[],this.tokens.links=Object.create(null),this.options=t||sn,this.options.tokenizer=this.options.tokenizer||new ii,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:vr.normal,inline:Bn.normal};this.options.pedantic?(n.block=vr.pedantic,n.inline=Bn.pedantic):this.options.gfm&&(n.block=vr.gfm,this.options.breaks?n.inline=Bn.breaks:n.inline=Bn.gfm),this.tokenizer.rules=n}static get rules(){return{block:vr,inline:Bn}}static lex(t,n){return new Sa(n).lex(t)}static lexInline(t,n){return new Sa(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){var i,a,s;for(this.options.pedantic&&(t=t.replace(je.tabCharGlobal," ").replace(je.spaceLine,""));t;){let o;if((a=(i=this.options.extensions)==null?void 0:i.block)!=null&&a.some(l=>(o=l.call({lexer:this},t,n))?(t=t.substring(o.raw.length),n.push(o),!0):!1))continue;if(o=this.tokenizer.space(t)){t=t.substring(o.raw.length);let l=n.at(-1);o.raw.length===1&&l!==void 0?l.raw+=`
|
|
78
78
|
`:n.push(o);continue}if(o=this.tokenizer.code(t)){t=t.substring(o.raw.length);let l=n.at(-1);(l==null?void 0:l.type)==="paragraph"||(l==null?void 0:l.type)==="text"?(l.raw+=(l.raw.endsWith(`
|
|
79
79
|
`)?"":`
|
|
80
80
|
`)+o.raw,l.text+=`
|
|
@@ -87,7 +87,7 @@ ${h}`:h;let d=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTo
|
|
|
87
87
|
`+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=l.text):n.push(o),r=u.length!==t.length,t=t.substring(o.raw.length);continue}if(o=this.tokenizer.text(t)){t=t.substring(o.raw.length);let l=n.at(-1);(l==null?void 0:l.type)==="text"?(l.raw+=(l.raw.endsWith(`
|
|
88
88
|
`)?"":`
|
|
89
89
|
`)+o.raw,l.text+=`
|
|
90
|
-
`+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=l.text):n.push(o);continue}if(t){let l="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(l);break}else throw new Error(l)}}return this.state.top=!0,n}inline(t,n=[]){return this.inlineQueue.push({src:t,tokens:n}),n}inlineTokens(t,n=[]){var u,l,h,d,p;let r=t,i=null;if(this.tokens.links){let f=Object.keys(this.tokens.links);if(f.length>0)for(;(i=this.tokenizer.rules.inline.reflinkSearch.exec(r))!=null;)f.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=((l=(u=this.options.hooks)==null?void 0:u.emStrongMask)==null?void 0:l.call({lexer:this},r))??r;let s=!1,o="";for(;t;){s||(o=""),s=!1;let f;if((d=(h=this.options.extensions)==null?void 0:h.inline)!=null&&d.some(_=>(f=_.call({lexer:this},t,n))?(t=t.substring(f.raw.length),n.push(f),!0):!1))continue;if(f=this.tokenizer.escape(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.tag(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.link(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(f.raw.length);let _=n.at(-1);f.type==="text"&&(_==null?void 0:_.type)==="text"?(_.raw+=f.raw,_.text+=f.text):n.push(f);continue}if(f=this.tokenizer.emStrong(t,r,o)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.codespan(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.br(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.del(t,r,o)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.autolink(t)){t=t.substring(f.raw.length),n.push(f);continue}if(!this.state.inLink&&(f=this.tokenizer.url(t))){t=t.substring(f.raw.length),n.push(f);continue}let m=t;if((p=this.options.extensions)!=null&&p.startInline){let _=1/0,x=t.slice(1),k;this.options.extensions.startInline.forEach(v=>{k=v.call({lexer:this},x),typeof k=="number"&&k>=0&&(_=Math.min(_,k))}),_<1/0&&_>=0&&(m=t.substring(0,_+1))}if(f=this.tokenizer.inlineText(m)){t=t.substring(f.raw.length),f.raw.slice(-1)!=="_"&&(o=f.raw.slice(-1)),s=!0;let _=n.at(-1);(_==null?void 0:_.type)==="text"?(_.raw+=f.raw,_.text+=f.text):n.push(f);continue}if(t){let _="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(_);break}else throw new Error(_)}}return n}},
|
|
90
|
+
`+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=l.text):n.push(o);continue}if(t){let l="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(l);break}else throw new Error(l)}}return this.state.top=!0,n}inline(t,n=[]){return this.inlineQueue.push({src:t,tokens:n}),n}inlineTokens(t,n=[]){var u,l,h,d,p;let r=t,i=null;if(this.tokens.links){let f=Object.keys(this.tokens.links);if(f.length>0)for(;(i=this.tokenizer.rules.inline.reflinkSearch.exec(r))!=null;)f.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=((l=(u=this.options.hooks)==null?void 0:u.emStrongMask)==null?void 0:l.call({lexer:this},r))??r;let s=!1,o="";for(;t;){s||(o=""),s=!1;let f;if((d=(h=this.options.extensions)==null?void 0:h.inline)!=null&&d.some(_=>(f=_.call({lexer:this},t,n))?(t=t.substring(f.raw.length),n.push(f),!0):!1))continue;if(f=this.tokenizer.escape(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.tag(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.link(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(f.raw.length);let _=n.at(-1);f.type==="text"&&(_==null?void 0:_.type)==="text"?(_.raw+=f.raw,_.text+=f.text):n.push(f);continue}if(f=this.tokenizer.emStrong(t,r,o)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.codespan(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.br(t)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.del(t,r,o)){t=t.substring(f.raw.length),n.push(f);continue}if(f=this.tokenizer.autolink(t)){t=t.substring(f.raw.length),n.push(f);continue}if(!this.state.inLink&&(f=this.tokenizer.url(t))){t=t.substring(f.raw.length),n.push(f);continue}let m=t;if((p=this.options.extensions)!=null&&p.startInline){let _=1/0,x=t.slice(1),k;this.options.extensions.startInline.forEach(v=>{k=v.call({lexer:this},x),typeof k=="number"&&k>=0&&(_=Math.min(_,k))}),_<1/0&&_>=0&&(m=t.substring(0,_+1))}if(f=this.tokenizer.inlineText(m)){t=t.substring(f.raw.length),f.raw.slice(-1)!=="_"&&(o=f.raw.slice(-1)),s=!0;let _=n.at(-1);(_==null?void 0:_.type)==="text"?(_.raw+=f.raw,_.text+=f.text):n.push(f);continue}if(t){let _="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(_);break}else throw new Error(_)}}return n}},ai=class{constructor(e){be(this,"options");be(this,"parser");this.options=e||sn}space(e){return""}code({text:e,lang:t,escaped:n}){var a;let r=(a=(t||"").match(je.notSpaceStart))==null?void 0:a[0],i=e.replace(je.endingNewline,"")+`
|
|
91
91
|
`;return r?'<pre><code class="language-'+dt(r)+'">'+(n?i:dt(i,!0))+`</code></pre>
|
|
92
92
|
`:"<pre><code>"+(n?i:dt(i,!0))+`</code></pre>
|
|
93
93
|
`}blockquote({tokens:e}){return`<blockquote>
|
|
@@ -105,25 +105,25 @@ ${this.parser.parse(e)}</blockquote>
|
|
|
105
105
|
`}tablerow({text:e}){return`<tr>
|
|
106
106
|
${e}</tr>
|
|
107
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}>
|
|
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>${dt(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=
|
|
109
|
-
Please report this to https://github.com/markedjs/marked.`,e){let r="<p>An error occurred:</p><pre>"+dt(n.message+"",!0)+"</pre>";return t?Promise.resolve(r):r}if(t)return Promise.reject(n);throw n}}},en=new
|
|
110
|
-
`).map(u=>[{content:u,color:"inherit",bgColor:"transparent",htmlStyle:{},offset:0}])}),[s]);return g(y0.Provider,{value:{code:e},children:g(yx,{isIncomplete:i,language:t,children:[g(wx,{language:t}),r?g("div",{className:"pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end",children:g("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,g(jn,{fallback:g(x0,{className:n,language:t,result:o,...a}),children:g(Cx,{className:n,code:s,language:t,raw:o,...a})})]})})},ws=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),As=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Ci=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),vx=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:[g("path",{d:"M8 0V4",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M8 16V12",opacity:"0.5",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M3.29773 1.52783L5.64887 4.7639",opacity:"0.9",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M12.7023 1.52783L10.3511 4.7639",opacity:"0.1",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M12.7023 14.472L10.3511 11.236",opacity:"0.4",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M3.29773 14.472L5.64887 11.236",opacity:"0.6",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M15.6085 5.52783L11.8043 6.7639",opacity:"0.2",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M0.391602 10.472L4.19583 9.23598",opacity:"0.7",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M15.6085 10.4722L11.8043 9.2361",opacity:"0.3",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M0.391602 5.52783L4.19583 6.7639",opacity:"0.8",stroke:"currentColor",strokeWidth:"1.5"})]}),Ix=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Nx=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),A0=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Hu=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Lx=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Rx=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Uu=({onCopy:e,onError:t,timeout:n=2e3,children:r,className:i,code:a,...s})=>{let[o,u]=fe(!1),l=ve(0),{code:h}=w0(),{isAnimating:d}=We(et),p=a??h,f=async()=>{var _;if(typeof window>"u"||!((_=navigator==null?void 0:navigator.clipboard)!=null&&_.writeText)){t==null||t(new Error("Clipboard API not available"));return}try{o||(await navigator.clipboard.writeText(p),u(!0),e==null||e(),l.current=window.setTimeout(()=>u(!1),n))}catch(x){t==null||t(x)}};Ce(()=>()=>{window.clearTimeout(l.current)},[]);let m=o?ws:As;return g("button",{className:ee("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:f,title:"Copy Code",type:"button",...s,children:r??g(m,{size:14})})},zu={"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"},Ox=({onDownload:e,onError:t,language:n,children:r,className:i,code:a,...s})=>{let{code:o}=w0(),{isAnimating:u}=We(et),l=a??o,h=`file.${n&&n in zu?zu[n]:"txt"}`,d="text/plain",p=()=>{try{gn(h,l,d),e==null||e()}catch(f){t==null||t(f)}};return g("button",{className:ee("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:p,title:"Download file",type:"button",...s,children:r??g(Ci,{size:14})})},Dx=()=>g("div",{className:"w-full divide-y divide-border overflow-hidden rounded-xl border border-border",children:[g("div",{className:"h-[46px] w-full bg-muted/80"}),g("div",{className:"flex w-full items-center justify-center p-4",children:g(vx,{className:"size-4 animate-spin"})})]}),Px=/\.[^/.]+$/,Mx=({node:e,className:t,src:n,alt:r,onLoad:i,onError:a,...s})=>{let o=ve(null),[u,l]=fe(!1),[h,d]=fe(!1),p=s.width!=null||s.height!=null,f=(u||p)&&!h,m=h&&!p;Ce(()=>{let v=o.current;if(v!=null&&v.complete){let C=v.naturalWidth>0;l(C),d(!C)}},[]);let _=ze(v=>{l(!0),d(!1),i==null||i(v)},[i]),x=ze(v=>{l(!1),d(!0),a==null||a(v)},[a]),k=async()=>{if(n)try{let v=await(await fetch(n)).blob(),C=new URL(n,window.location.origin).pathname.split("/").pop()||"",R=C.split(".").pop(),F=C.includes(".")&&R!==void 0&&R.length<=4,S="";if(F)S=C;else{let Y=v.type,L="png";Y.includes("jpeg")||Y.includes("jpg")?L="jpg":Y.includes("png")?L="png":Y.includes("svg")?L="svg":Y.includes("gif")?L="gif":Y.includes("webp")&&(L="webp"),S=`${(r||C||"image").replace(Px,"")}.${L}`}gn(S,v,v.type)}catch{window.open(n,"_blank")}};return n?g("div",{className:"group relative my-4 inline-block","data-streamdown":"image-wrapper",children:[g("img",{alt:r,className:ee("max-w-full rounded-lg",m&&"hidden",t),"data-streamdown":"image",onError:x,onLoad:_,ref:o,src:n,...s}),m&&g("span",{className:"text-muted-foreground text-xs italic","data-streamdown":"image-fallback",children:"Image not available"}),g("div",{className:"pointer-events-none absolute inset-0 hidden rounded-lg bg-black/10 group-hover:block"}),f&&g("button",{className:ee("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:k,title:"Download image",type:"button",children:g(Ci,{size:14})})]}):null},er=0,Bx=()=>{er+=1,er===1&&(document.body.style.overflow="hidden")},Fx=()=>{er=Math.max(0,er-1),er===0&&(document.body.style.overflow="")},Hx=({url:e,isOpen:t,onClose:n,onConfirm:r})=>{let[i,a]=fe(!1),s=ze(async()=>{try{await navigator.clipboard.writeText(e),a(!0),setTimeout(()=>a(!1),2e3)}catch{}},[e]),o=ze(()=>{r(),n()},[r,n]);return Ce(()=>{if(t){Bx();let u=l=>{l.key==="Escape"&&n()};return document.addEventListener("keydown",u),()=>{document.removeEventListener("keydown",u),Fx()}}},[t,n]),t?g("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:g("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:[g("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:g(A0,{size:16})}),g("div",{className:"flex flex-col gap-2",children:[g("div",{className:"flex items-center gap-2 font-semibold text-lg",children:[g(Hu,{size:20}),g("span",{children:"Open external link?"})]}),g("p",{className:"text-muted-foreground text-sm",children:"You're about to visit an external website."})]}),g("div",{className:ee("break-all rounded-md bg-muted p-3 font-mono text-sm",e.length>100&&"max-h-32 overflow-y-auto"),children:e}),g("div",{className:"flex gap-2",children:[g("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?g(xe,{children:[g(ws,{size:14}),g("span",{children:"Copied"})]}):g(xe,{children:[g(As,{size:14}),g("span",{children:"Copy link"})]})}),g("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:[g(Hu,{size:14}),g("span",{children:"Open link"})]})]})]})}):null},va=oi(null),C0=()=>We(va),Ux=()=>{var e;let t=C0();return(e=t==null?void 0:t.code)!=null?e:null},Cs=()=>{var e;let t=C0();return(e=t==null?void 0: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"),l=o.width*r,h=o.height*r;u.width=l,u.height=h;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,l,h),u.toBlob(p=>{if(!p){a(new Error("Failed to create PNG blob"));return}i(p)},"image/png")},o.onerror=()=>a(new Error("Failed to load SVG image")),o.src=s})},$x=({chart:e,children:t,className:n,onDownload:r,config:i,onError:a})=>{let[s,o]=fe(!1),u=ve(null),{isAnimating:l}=We(et),h=Cs(),d=async p=>{try{if(p==="mmd"){gn("diagram.mmd",e,"text/plain"),o(!1),r==null||r(p);return}if(!h){a==null||a(new Error("Mermaid plugin not available"));return}let f=h.getMermaid(i),m=e.split("").reduce((k,v)=>(k<<5)-k+v.charCodeAt(0)|0,0),_=`mermaid-${Math.abs(m)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:x}=await f.render(_,e);if(!x){a==null||a(new Error("SVG not found. Please wait for the diagram to render."));return}if(p==="svg"){gn("diagram.svg",x,"image/svg+xml"),o(!1),r==null||r(p);return}if(p==="png"){let k=await zx(x);gn("diagram.png",k,"image/png"),r==null||r(p),o(!1);return}}catch(f){a==null||a(f)}};return Ce(()=>{let p=f=>{let m=f.composedPath();u.current&&!m.includes(u.current)&&o(!1)};return document.addEventListener("mousedown",p),()=>{document.removeEventListener("mousedown",p)}},[]),g("div",{className:"relative",ref:u,children:[g("button",{className:ee("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",n),disabled:l,onClick:()=>o(!s),title:"Download diagram",type:"button",children:t??g(Ci,{size:14})}),s?g("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:[g("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"}),g("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"}),g("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]})},tr=0,Yx=()=>{tr+=1,tr===1&&(document.body.style.overflow="hidden")},jx=()=>{tr=Math.max(0,tr-1),tr===0&&(document.body.style.overflow="")},Vx=({chart:e,config:t,onFullscreen:n,onExit:r,className:i,...a})=>{let[s,o]=fe(!1),{isAnimating:u,controls:l}=We(et),h=(()=>{if(typeof l=="boolean")return l;let p=l.mermaid;return p===!1?!1:p===!0||p===void 0?!0:p.panZoom!==!1})(),d=()=>{o(!s)};return Ce(()=>{if(s){Yx();let p=f=>{f.key==="Escape"&&o(!1)};return document.addEventListener("keydown",p),()=>{document.removeEventListener("keydown",p),jx()}}},[s]),Ce(()=>{s?n==null||n():r&&r()},[s,n,r]),g(xe,{children:[g("button",{className:ee("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:g(Ix,{size:14})}),s?jl(g("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-background/95 backdrop-blur-sm",onClick:d,onKeyDown:p=>{p.key==="Escape"&&d()},role:"button",tabIndex:0,children:[g("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:g(A0,{size:20})}),g("div",{className:"flex size-full items-center justify-center p-4",onClick:p=>p.stopPropagation(),onKeyDown:p=>p.stopPropagation(),role:"presentation",children:g(nh,{chart:e,className:"size-full [&_svg]:h-auto [&_svg]:w-auto",config:t,fullscreen:!0,showControls:h})})]}),document.body):null]})},S0=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=[],l=o.querySelectorAll("td");for(let h of l)u.push(((n=h.textContent)==null?void 0:n.trim())||"");i.push(u)}return{headers:r,rows:i}},v0=e=>{let{headers:t,rows:n}=e,r=o=>{let u=!1,l=!1;for(let h of o){if(h==='"'){u=!0,l=!0;break}(h===","||h===`
|
|
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>${dt(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=Fu(e);if(i===null)return r;e=i;let a='<a href="'+e+'"';return t&&(a+=' title="'+dt(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=Fu(e);if(i===null)return dt(n);e=i;let a=`<img src="${e}" alt="${dt(n)}"`;return t&&(a+=` title="${dt(t)}"`),a+=">",a}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:dt(e.text)}},As=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}},pt=class va{constructor(t){be(this,"options");be(this,"renderer");be(this,"textRenderer");this.options=t||sn,this.options.renderer=this.options.renderer||new ai,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new As}static parse(t,n){return new va(n).parse(t)}static parseInline(t,n){return new va(n).parseInline(t)}parse(t){var r,i;let n="";for(let a=0;a<t.length;a++){let s=t[a];if((i=(r=this.options.extensions)==null?void 0:r.renderers)!=null&&i[s.type]){let u=s,l=this.options.extensions.renderers[u.type].call({parser:this},u);if(l!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(u.type)){n+=l||"";continue}}let o=s;switch(o.type){case"space":{n+=this.renderer.space(o);break}case"hr":{n+=this.renderer.hr(o);break}case"heading":{n+=this.renderer.heading(o);break}case"code":{n+=this.renderer.code(o);break}case"table":{n+=this.renderer.table(o);break}case"blockquote":{n+=this.renderer.blockquote(o);break}case"list":{n+=this.renderer.list(o);break}case"checkbox":{n+=this.renderer.checkbox(o);break}case"html":{n+=this.renderer.html(o);break}case"def":{n+=this.renderer.def(o);break}case"paragraph":{n+=this.renderer.paragraph(o);break}case"text":{n+=this.renderer.text(o);break}default:{let u='Token with "'+o.type+'" type was not found.';if(this.options.silent)return console.error(u),"";throw new Error(u)}}}return n}parseInline(t,n=this.renderer){var i,a;let r="";for(let s=0;s<t.length;s++){let o=t[s];if((a=(i=this.options.extensions)==null?void 0:i.renderers)!=null&&a[o.type]){let l=this.options.extensions.renderers[o.type].call({parser:this},o);if(l!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(o.type)){r+=l||"";continue}}let u=o;switch(u.type){case"escape":{r+=n.text(u);break}case"html":{r+=n.html(u);break}case"link":{r+=n.link(u);break}case"image":{r+=n.image(u);break}case"checkbox":{r+=n.checkbox(u);break}case"strong":{r+=n.strong(u);break}case"em":{r+=n.em(u);break}case"codespan":{r+=n.codespan(u);break}case"br":{r+=n.br(u);break}case"del":{r+=n.del(u);break}case"text":{r+=n.text(u);break}default:{let l='Token with "'+u.type+'" type was not found.';if(this.options.silent)return console.error(l),"";throw new Error(l)}}}return r}},Or,zn=(Or=class{constructor(e){be(this,"options");be(this,"block");this.options=e||sn}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?pt.parse:pt.parseInline}},be(Or,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens","emStrongMask"])),be(Or,"passThroughHooksRespectAsync",new Set(["preprocess","postprocess","processAllTokens"])),Or),mx=class{constructor(...e){be(this,"defaults",bs());be(this,"options",this.setOptions);be(this,"parse",this.parseMarkdown(!0));be(this,"parseInline",this.parseMarkdown(!1));be(this,"Parser",pt);be(this,"Renderer",ai);be(this,"TextRenderer",As);be(this,"Lexer",ut);be(this,"Tokenizer",ii);be(this,"Hooks",zn);this.use(...e)}walkTokens(e,t){var r,i;let n=[];for(let a of e)switch(n=n.concat(t.call(this,a)),a.type){case"table":{let s=a;for(let o of s.header)n=n.concat(this.walkTokens(o.tokens,t));for(let o of s.rows)for(let u of o)n=n.concat(this.walkTokens(u.tokens,t));break}case"list":{let s=a;n=n.concat(this.walkTokens(s.items,t));break}default:{let s=a;(i=(r=this.defaults.extensions)==null?void 0:r.childTokens)!=null&&i[s.type]?this.defaults.extensions.childTokens[s.type].forEach(o=>{let u=s[o].flat(1/0);n=n.concat(this.walkTokens(u,t))}):s.tokens&&(n=n.concat(this.walkTokens(s.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 ai(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]=(...l)=>{let h=o.apply(i,l);return h===!1&&(h=u.apply(i,l)),h||""}}r.renderer=i}if(n.tokenizer){let i=this.defaults.tokenizer||new ii(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]=(...l)=>{let h=o.apply(i,l);return h===!1&&(h=u.apply(i,l)),h}}r.tokenizer=i}if(n.hooks){let i=this.defaults.hooks||new zn;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];zn.passThroughHooks.has(a)?i[s]=l=>{if(this.defaults.async&&zn.passThroughHooksRespectAsync.has(a))return(async()=>{let d=await o.call(i,l);return u.call(i,d)})();let h=o.call(i,l);return u.call(i,h)}:i[s]=(...l)=>{if(this.defaults.async)return(async()=>{let d=await o.apply(i,l);return d===!1&&(d=await u.apply(i,l)),d})();let h=o.apply(i,l);return h===!1&&(h=u.apply(i,l)),h}}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 pt.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 l=await(i.hooks?await i.hooks.provideParser():e?pt.parse:pt.parseInline)(u,i);return i.hooks?await i.hooks.postprocess(l):l})().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?pt.parse:pt.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>"+dt(n.message+"",!0)+"</pre>";return t?Promise.resolve(r):r}if(t)return Promise.reject(n);throw n}}},en=new mx;function Ae(e,t){return en.parse(e,t)}Ae.options=Ae.setOptions=function(e){return en.setOptions(e),Ae.defaults=en.defaults,c0(Ae.defaults),Ae};Ae.getDefaults=bs;Ae.defaults=sn;Ae.use=function(...e){return en.use(...e),Ae.defaults=en.defaults,c0(Ae.defaults),Ae};Ae.walkTokens=function(e,t){return en.walkTokens(e,t)};Ae.parseInline=en.parseInline;Ae.Parser=pt;Ae.parser=pt.parse;Ae.Renderer=ai;Ae.TextRenderer=As;Ae.Lexer=ut;Ae.lexer=ut.lex;Ae.Tokenizer=ii;Ae.Hooks=zn;Ae.parse=Ae;var gx=300,bx="300px",Ex=500;function Tx(e={}){let{immediate:t=!1,debounceDelay:n=gx,rootMargin:r=bx,idleTimeout:i=Ex}=e,[a,s]=fe(!1),o=ve(null),u=ve(null),l=ve(null),h=Ne(()=>f=>{let m=Date.now();return window.setTimeout(()=>{f({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-m))})},1)},[]),d=Ne(()=>typeof window<"u"&&window.requestIdleCallback?(f,m)=>window.requestIdleCallback(f,m):h,[h]),p=Ne(()=>typeof window<"u"&&window.cancelIdleCallback?f=>window.cancelIdleCallback(f):f=>{clearTimeout(f)},[]);return Ce(()=>{if(t){s(!0);return}let f=o.current;if(!f)return;u.current&&(clearTimeout(u.current),u.current=null),l.current&&(p(l.current),l.current=null);let m=()=>{u.current&&(clearTimeout(u.current),u.current=null),l.current&&(p(l.current),l.current=null)},_=C=>{l.current=d(R=>{R.timeRemaining()>0||R.didTimeout?(s(!0),C.disconnect()):l.current=d(()=>{s(!0),C.disconnect()},{timeout:i/2})},{timeout:i})},x=C=>{m(),u.current=window.setTimeout(()=>{var R,F;let S=C.takeRecords();(S.length===0||(F=(R=S.at(-1))==null?void 0:R.isIntersecting)!=null&&F)&&_(C)},n)},k=(C,R)=>{C.isIntersecting?x(R):m()},v=new IntersectionObserver(C=>{for(let R of C)k(R,v)},{rootMargin:r,threshold:0});return v.observe(f),()=>{u.current&&clearTimeout(u.current),l.current&&p(l.current),v.disconnect()}},[t,n,r,i,p,d]),{shouldRender:a,containerRef:o}}var x0=/\s/,_x=/^\s+$/,kx=new Set(["code","pre","svg","math","annotation"]),xx=e=>typeof e=="object"&&e!==null&&"type"in e&&e.type==="element",yx=e=>e.some(t=>xx(t)&&kx.has(t.tagName)),wx=e=>{let t=[],n="",r=!1;for(let i of e){let a=x0.test(i);a!==r&&n&&(t.push(n),n=""),n+=i,r=a}return n&&t.push(n),t},Ax=e=>{let t=[],n="";for(let r of e)x0.test(r)?n+=r:(n&&(t.push(n),n=""),t.push(r));return n&&t.push(n),t},Cx=(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}]}),Sx=(e,t,n)=>{let r=t.at(-1);if(!(r&&"children"in r))return;if(yx(t))return dn;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"?Ax(s):wx(s)).map(u=>_x.test(u)?{type:"text",value:u}:Cx(u,n.animation,n.duration,n.easing));return i.children.splice(a,1,...o),a+o.length};function Ia(e){var t,n,r,i;let a={animation:(t=e==null?void 0:e.animation)!=null?t:"fadeIn",duration:(n=e==null?void 0:e.duration)!=null?n:150,easing:(r=e==null?void 0:e.easing)!=null?r:"ease",sep:(i=e==null?void 0:e.sep)!=null?i:"word"};return{name:"animate",type:"animate",rehypePlugin:()=>s=>{ja(s,"text",(o,u)=>Sx(o,u,a))}}}Ia();var y0=ui(!1),vx=()=>Ge(y0),ee=(...e)=>WT(iT(e)),gn=(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)},Ix=ee("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"),Nx=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},w0=Ee(({children:e,result:t,language:n,className:r,...i})=>{let a=Ne(()=>{let s={};return t.bg&&(s["--sdm-bg"]=t.bg),t.fg&&(s["--sdm-fg"]=t.fg),t.rootStyle&&Object.assign(s,Nx(t.rootStyle)),s},[t.bg,t.fg,t.rootStyle]);return g("div",{className:ee(r,"overflow-hidden rounded-md border border-border bg-background p-4 text-sm"),"data-language":n,"data-streamdown":"code-block-body",...i,children:g("pre",{className:ee(r,"bg-[var(--sdm-bg,inherit]","dark:bg-[var(--shiki-dark-bg,var(--sdm-bg,inherit)]"),style:a,children:g("code",{className:"[counter-increment:line_0] [counter-reset:line]",children:t.tokens.map((s,o)=>g("span",{className:Ix,children:s.map((u,l)=>{let h={},d=!!u.bgColor;if(u.color&&(h["--sdm-c"]=u.color),u.bgColor&&(h["--sdm-tbg"]=u.bgColor),u.htmlStyle)for(let[p,f]of Object.entries(u.htmlStyle))p==="color"?h["--sdm-c"]=f:p==="background-color"?(h["--sdm-tbg"]=f,d=!0):h[p]=f;return g("span",{className:ee("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:h,...u.htmlAttrs,children:u.content},l)})},o))})})})},(e,t)=>e.result===t.result&&e.language===t.language&&e.className===t.className),Lx=({className:e,language:t,style:n,isIncomplete:r,...i})=>g("div",{className:ee("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}),A0=ui({code:""}),C0=()=>Ge(A0),Rx=({language:e})=>g("div",{className:"flex h-8 items-center text-muted-foreground text-xs","data-language":e,"data-streamdown":"code-block-header",children:g("span",{className:"ml-1 font-mono lowercase",children:e})}),Ox=/\n+$/,Dx=Vl(()=>Promise.resolve().then(()=>require("./highlighted-body-B3W2YXNL-d2c84a6f.cjs")).then(e=>({default:e.HighlightedCodeBlockBody}))),Px=({code:e,language:t,className:n,children:r,isIncomplete:i=!1,...a})=>{let s=Ne(()=>e.replace(Ox,""),[e]),o=Ne(()=>({bg:"transparent",fg:"inherit",tokens:s.split(`
|
|
110
|
+
`).map(u=>[{content:u,color:"inherit",bgColor:"transparent",htmlStyle:{},offset:0}])}),[s]);return g(A0.Provider,{value:{code:e},children:g(Lx,{isIncomplete:i,language:t,children:[g(Rx,{language:t}),r?g("div",{className:"pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end",children:g("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,g(Vn,{fallback:g(w0,{className:n,language:t,result:o,...a}),children:g(Dx,{className:n,code:s,language:t,raw:o,...a})})]})})},Cs=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Ss=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),vi=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Mx=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:[g("path",{d:"M8 0V4",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M8 16V12",opacity:"0.5",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M3.29773 1.52783L5.64887 4.7639",opacity:"0.9",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M12.7023 1.52783L10.3511 4.7639",opacity:"0.1",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M12.7023 14.472L10.3511 11.236",opacity:"0.4",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M3.29773 14.472L5.64887 11.236",opacity:"0.6",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M15.6085 5.52783L11.8043 6.7639",opacity:"0.2",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M0.391602 10.472L4.19583 9.23598",opacity:"0.7",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M15.6085 10.4722L11.8043 9.2361",opacity:"0.3",stroke:"currentColor",strokeWidth:"1.5"}),g("path",{d:"M0.391602 5.52783L4.19583 6.7639",opacity:"0.8",stroke:"currentColor",strokeWidth:"1.5"})]}),Bx=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Fx=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),S0=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),zu=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Hx=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),Ux=e=>g("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:g("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"})}),$u=({onCopy:e,onError:t,timeout:n=2e3,children:r,className:i,code:a,...s})=>{let[o,u]=fe(!1),l=ve(0),{code:h}=C0(),{isAnimating:d}=Ge(et),p=a??h,f=async()=>{var _;if(typeof window>"u"||!((_=navigator==null?void 0:navigator.clipboard)!=null&&_.writeText)){t==null||t(new Error("Clipboard API not available"));return}try{o||(await navigator.clipboard.writeText(p),u(!0),e==null||e(),l.current=window.setTimeout(()=>u(!1),n))}catch(x){t==null||t(x)}};Ce(()=>()=>{window.clearTimeout(l.current)},[]);let m=o?Cs:Ss;return g("button",{className:ee("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:f,title:"Copy Code",type:"button",...s,children:r??g(m,{size:14})})},Yu={"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"},zx=({onDownload:e,onError:t,language:n,children:r,className:i,code:a,...s})=>{let{code:o}=C0(),{isAnimating:u}=Ge(et),l=a??o,h=`file.${n&&n in Yu?Yu[n]:"txt"}`,d="text/plain",p=()=>{try{gn(h,l,d),e==null||e()}catch(f){t==null||t(f)}};return g("button",{className:ee("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:p,title:"Download file",type:"button",...s,children:r??g(vi,{size:14})})},$x=()=>g("div",{className:"w-full divide-y divide-border overflow-hidden rounded-xl border border-border",children:[g("div",{className:"h-[46px] w-full bg-muted/80"}),g("div",{className:"flex w-full items-center justify-center p-4",children:g(Mx,{className:"size-4 animate-spin"})})]}),Yx=/\.[^/.]+$/,jx=({node:e,className:t,src:n,alt:r,onLoad:i,onError:a,...s})=>{let o=ve(null),[u,l]=fe(!1),[h,d]=fe(!1),p=s.width!=null||s.height!=null,f=(u||p)&&!h,m=h&&!p;Ce(()=>{let v=o.current;if(v!=null&&v.complete){let C=v.naturalWidth>0;l(C),d(!C)}},[]);let _=$e(v=>{l(!0),d(!1),i==null||i(v)},[i]),x=$e(v=>{l(!1),d(!0),a==null||a(v)},[a]),k=async()=>{if(n)try{let v=await(await fetch(n)).blob(),C=new URL(n,window.location.origin).pathname.split("/").pop()||"",R=C.split(".").pop(),F=C.includes(".")&&R!==void 0&&R.length<=4,S="";if(F)S=C;else{let Y=v.type,L="png";Y.includes("jpeg")||Y.includes("jpg")?L="jpg":Y.includes("png")?L="png":Y.includes("svg")?L="svg":Y.includes("gif")?L="gif":Y.includes("webp")&&(L="webp"),S=`${(r||C||"image").replace(Yx,"")}.${L}`}gn(S,v,v.type)}catch{window.open(n,"_blank")}};return n?g("div",{className:"group relative my-4 inline-block","data-streamdown":"image-wrapper",children:[g("img",{alt:r,className:ee("max-w-full rounded-lg",m&&"hidden",t),"data-streamdown":"image",onError:x,onLoad:_,ref:o,src:n,...s}),m&&g("span",{className:"text-muted-foreground text-xs italic","data-streamdown":"image-fallback",children:"Image not available"}),g("div",{className:"pointer-events-none absolute inset-0 hidden rounded-lg bg-black/10 group-hover:block"}),f&&g("button",{className:ee("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:k,title:"Download image",type:"button",children:g(vi,{size:14})})]}):null},tr=0,Vx=()=>{tr+=1,tr===1&&(document.body.style.overflow="hidden")},qx=()=>{tr=Math.max(0,tr-1),tr===0&&(document.body.style.overflow="")},Wx=({url:e,isOpen:t,onClose:n,onConfirm:r})=>{let[i,a]=fe(!1),s=$e(async()=>{try{await navigator.clipboard.writeText(e),a(!0),setTimeout(()=>a(!1),2e3)}catch{}},[e]),o=$e(()=>{r(),n()},[r,n]);return Ce(()=>{if(t){Vx();let u=l=>{l.key==="Escape"&&n()};return document.addEventListener("keydown",u),()=>{document.removeEventListener("keydown",u),qx()}}},[t,n]),t?g("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:g("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:[g("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:g(S0,{size:16})}),g("div",{className:"flex flex-col gap-2",children:[g("div",{className:"flex items-center gap-2 font-semibold text-lg",children:[g(zu,{size:20}),g("span",{children:"Open external link?"})]}),g("p",{className:"text-muted-foreground text-sm",children:"You're about to visit an external website."})]}),g("div",{className:ee("break-all rounded-md bg-muted p-3 font-mono text-sm",e.length>100&&"max-h-32 overflow-y-auto"),children:e}),g("div",{className:"flex gap-2",children:[g("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?g(pe,{children:[g(Cs,{size:14}),g("span",{children:"Copied"})]}):g(pe,{children:[g(Ss,{size:14}),g("span",{children:"Copy link"})]})}),g("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:[g(zu,{size:14}),g("span",{children:"Open link"})]})]})]})}):null},Na=ui(null),v0=()=>Ge(Na),Gx=()=>{var e;let t=v0();return(e=t==null?void 0:t.code)!=null?e:null},vs=()=>{var e;let t=v0();return(e=t==null?void 0:t.mermaid)!=null?e:null},Qx=(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"),l=o.width*r,h=o.height*r;u.width=l,u.height=h;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,l,h),u.toBlob(p=>{if(!p){a(new Error("Failed to create PNG blob"));return}i(p)},"image/png")},o.onerror=()=>a(new Error("Failed to load SVG image")),o.src=s})},Kx=({chart:e,children:t,className:n,onDownload:r,config:i,onError:a})=>{let[s,o]=fe(!1),u=ve(null),{isAnimating:l}=Ge(et),h=vs(),d=async p=>{try{if(p==="mmd"){gn("diagram.mmd",e,"text/plain"),o(!1),r==null||r(p);return}if(!h){a==null||a(new Error("Mermaid plugin not available"));return}let f=h.getMermaid(i),m=e.split("").reduce((k,v)=>(k<<5)-k+v.charCodeAt(0)|0,0),_=`mermaid-${Math.abs(m)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:x}=await f.render(_,e);if(!x){a==null||a(new Error("SVG not found. Please wait for the diagram to render."));return}if(p==="svg"){gn("diagram.svg",x,"image/svg+xml"),o(!1),r==null||r(p);return}if(p==="png"){let k=await Qx(x);gn("diagram.png",k,"image/png"),r==null||r(p),o(!1);return}}catch(f){a==null||a(f)}};return Ce(()=>{let p=f=>{let m=f.composedPath();u.current&&!m.includes(u.current)&&o(!1)};return document.addEventListener("mousedown",p),()=>{document.removeEventListener("mousedown",p)}},[]),g("div",{className:"relative",ref:u,children:[g("button",{className:ee("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",n),disabled:l,onClick:()=>o(!s),title:"Download diagram",type:"button",children:t??g(vi,{size:14})}),s?g("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:[g("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"}),g("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"}),g("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]})},nr=0,Xx=()=>{nr+=1,nr===1&&(document.body.style.overflow="hidden")},Zx=()=>{nr=Math.max(0,nr-1),nr===0&&(document.body.style.overflow="")},Jx=({chart:e,config:t,onFullscreen:n,onExit:r,className:i,...a})=>{let[s,o]=fe(!1),{isAnimating:u,controls:l}=Ge(et),h=(()=>{if(typeof l=="boolean")return l;let p=l.mermaid;return p===!1?!1:p===!0||p===void 0?!0:p.panZoom!==!1})(),d=()=>{o(!s)};return Ce(()=>{if(s){Xx();let p=f=>{f.key==="Escape"&&o(!1)};return document.addEventListener("keydown",p),()=>{document.removeEventListener("keydown",p),Zx()}}},[s]),Ce(()=>{s?n==null||n():r&&r()},[s,n,r]),g(pe,{children:[g("button",{className:ee("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:g(Bx,{size:14})}),s?ql(g("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-background/95 backdrop-blur-sm",onClick:d,onKeyDown:p=>{p.key==="Escape"&&d()},role:"button",tabIndex:0,children:[g("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:g(S0,{size:20})}),g("div",{className:"flex size-full items-center justify-center p-4",onClick:p=>p.stopPropagation(),onKeyDown:p=>p.stopPropagation(),role:"presentation",children:g(ih,{chart:e,className:"size-full [&_svg]:h-auto [&_svg]:w-auto",config:t,fullscreen:!0,showControls:h})})]}),document.body):null]})},I0=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=[],l=o.querySelectorAll("td");for(let h of l)u.push(((n=h.textContent)==null?void 0:n.trim())||"");i.push(u)}return{headers:r,rows:i}},N0=e=>{let{headers:t,rows:n}=e,r=o=>{let u=!1,l=!1;for(let h of o){if(h==='"'){u=!0,l=!0;break}(h===","||h===`
|
|
111
111
|
`)&&(u=!0)}return u?l?`"${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(`
|
|
112
|
-
`)},
|
|
112
|
+
`)},ey=e=>{let{headers:t,rows:n}=e,r=o=>{let u=!1;for(let h of o)if(h===" "||h===`
|
|
113
113
|
`||h==="\r"){u=!0;break}if(!u)return o;let l=[];for(let h of o)h===" "?l.push("\\t"):h===`
|
|
114
114
|
`?l.push("\\n"):h==="\r"?l.push("\\r"):l.push(h);return l.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(`
|
|
115
|
-
`)},
|
|
116
|
-
`)},Wx=({children:e,className:t,onCopy:n,onError:r,timeout:i=2e3})=>{let[a,s]=fe(!1),[o,u]=fe(!1),l=ve(null),h=ve(0),{isAnimating:d}=We(et),p=async m=>{var _,x;if(typeof window>"u"||!((_=navigator==null?void 0:navigator.clipboard)!=null&&_.write)){r==null||r(new Error("Clipboard API not available"));return}try{let k=(x=l.current)==null?void 0:x.closest('[data-streamdown="table-wrapper"]'),v=k==null?void 0:k.querySelector("table");if(!v){r==null||r(new Error("Table not found"));return}let C=S0(v),R=({csv:v0,tsv:qx,md:Ia}[m]||Ia)(C),F=new ClipboardItem({"text/plain":new Blob([R],{type:"text/plain"}),"text/html":new Blob([v.outerHTML],{type:"text/html"})});await navigator.clipboard.write([F]),u(!0),s(!1),n==null||n(m),h.current=window.setTimeout(()=>u(!1),i)}catch(k){r==null||r(k)}};Ce(()=>{let m=_=>{let x=_.composedPath();l.current&&!x.includes(l.current)&&s(!1)};return document.addEventListener("mousedown",m),()=>{document.removeEventListener("mousedown",m),window.clearTimeout(h.current)}},[]);let f=o?ws:As;return g("div",{className:"relative",ref:l,children:[g("button",{className:ee("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??g(f,{size:14})}),a?g("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:[g("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>p("md"),title:"Copy table as Markdown",type:"button",children:"Markdown"}),g("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>p("csv"),title:"Copy table as CSV",type:"button",children:"CSV"}),g("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>p("tsv"),title:"Copy table as TSV",type:"button",children:"TSV"})]}):null]})},Gx=({children:e,className:t,onDownload:n,onError:r})=>{let[i,a]=fe(!1),s=ve(null),{isAnimating:o}=We(et),u=l=>{var h;try{let d=(h=s.current)==null?void 0:h.closest('[data-streamdown="table-wrapper"]'),p=d==null?void 0:d.querySelector("table");if(!p){r==null||r(new Error("Table not found"));return}let f=S0(p),m=l==="csv"?v0(f):Ia(f);gn(`table.${l==="csv"?"csv":"md"}`,m,l==="csv"?"text/csv":"text/markdown"),a(!1),n==null||n(l)}catch(d){r==null||r(d)}};return Ce(()=>{let l=h=>{let d=h.composedPath();s.current&&!d.includes(s.current)&&a(!1)};return document.addEventListener("mousedown",l),()=>{document.removeEventListener("mousedown",l)}},[]),g("div",{className:"relative",ref:s,children:[g("button",{className:ee("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??g(Ci,{size:14})}),i?g("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:[g("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"}),g("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]})},Qx=({children:e,className:t,showControls:n,...r})=>g("div",{className:"my-4 flex flex-col gap-2 rounded-lg border border-border bg-sidebar p-2","data-streamdown":"table-wrapper",children:[n?g("div",{className:"flex items-center justify-end gap-1",children:[g(Wx,{}),g(Gx,{})]}):null,g("div",{className:"border-collapse overflow-x-auto overscroll-y-auto rounded-md border border-border bg-background",children:g("table",{className:ee("w-full divide-y divide-border",t),"data-streamdown":"table",...r,children:e})})]}),Kx=Yl(()=>Promise.resolve().then(()=>require("./mermaid-3ZIDBTTL-6f144371.cjs")).then(e=>({default:e.Mermaid}))),Xx=/language-([^\s]+)/;function Si(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==null?void 0:n.line)===(r==null?void 0:r.line)&&(n==null?void 0:n.column)===(r==null?void 0:r.column)&&(i==null?void 0:i.line)===(a==null?void 0:a.line)&&(i==null?void 0:i.column)===(a==null?void 0:a.column)}function Ie(e,t){return e.className===t.className&&Si(e.node,t.node)}var Na=(e,t)=>typeof e=="boolean"?e:e[t]!==!1,Ir=(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=be(({children:e,className:t,node:n,...r})=>g("ol",{className:ee("list-inside list-decimal whitespace-normal [li_&]:pl-6",t),"data-streamdown":"ordered-list",...r,children:e}),(e,t)=>Ie(e,t));Ss.displayName="MarkdownOl";var I0=be(({children:e,className:t,node:n,...r})=>g("li",{className:ee("py-1 [&>p]:inline",t),"data-streamdown":"list-item",...r,children:e}),(e,t)=>e.className===t.className&&Si(e.node,t.node));I0.displayName="MarkdownLi";var N0=be(({children:e,className:t,node:n,...r})=>g("ul",{className:ee("list-inside list-disc whitespace-normal [li_&]:pl-6",t),"data-streamdown":"unordered-list",...r,children:e}),(e,t)=>Ie(e,t));N0.displayName="MarkdownUl";var L0=be(({className:e,node:t,...n})=>g("hr",{className:ee("my-6 border-border",e),"data-streamdown":"horizontal-rule",...n}),(e,t)=>Ie(e,t));L0.displayName="MarkdownHr";var R0=be(({children:e,className:t,node:n,...r})=>g("span",{className:ee("font-semibold",t),"data-streamdown":"strong",...r,children:e}),(e,t)=>Ie(e,t));R0.displayName="MarkdownStrong";var Zx=({children:e,className:t,href:n,node:r,...i})=>{let{linkSafety:a}=We(et),[s,o]=fe(!1),u=n==="streamdown:incomplete-link",l=ze(async f=>{if(!(!(a!=null&&a.enabled&&n)||u)){if(f.preventDefault(),a.onLinkCheck&&await a.onLinkCheck(n)){window.open(n,"_blank","noreferrer");return}o(!0)}},[a,n,u]),h=ze(()=>{n&&window.open(n,"_blank","noreferrer")},[n]),d=ze(()=>{o(!1)},[]),p={url:n??"",isOpen:s,onClose:d,onConfirm:h};return a!=null&&a.enabled&&n?g(xe,{children:[g("button",{className:ee("wrap-anywhere appearance-none text-left font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",onClick:l,type:"button",children:e}),a.renderModal?a.renderModal(p):g(Hx,{...p})]}):g("a",{className:ee("wrap-anywhere font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",href:n,rel:"noreferrer",target:"_blank",...i,children:e})},O0=be(Zx,(e,t)=>Ie(e,t)&&e.href===t.href);O0.displayName="MarkdownA";var D0=be(({children:e,className:t,node:n,...r})=>g("h1",{className:ee("mt-6 mb-2 font-semibold text-3xl",t),"data-streamdown":"heading-1",...r,children:e}),(e,t)=>Ie(e,t));D0.displayName="MarkdownH1";var P0=be(({children:e,className:t,node:n,...r})=>g("h2",{className:ee("mt-6 mb-2 font-semibold text-2xl",t),"data-streamdown":"heading-2",...r,children:e}),(e,t)=>Ie(e,t));P0.displayName="MarkdownH2";var M0=be(({children:e,className:t,node:n,...r})=>g("h3",{className:ee("mt-6 mb-2 font-semibold text-xl",t),"data-streamdown":"heading-3",...r,children:e}),(e,t)=>Ie(e,t));M0.displayName="MarkdownH3";var B0=be(({children:e,className:t,node:n,...r})=>g("h4",{className:ee("mt-6 mb-2 font-semibold text-lg",t),"data-streamdown":"heading-4",...r,children:e}),(e,t)=>Ie(e,t));B0.displayName="MarkdownH4";var F0=be(({children:e,className:t,node:n,...r})=>g("h5",{className:ee("mt-6 mb-2 font-semibold text-base",t),"data-streamdown":"heading-5",...r,children:e}),(e,t)=>Ie(e,t));F0.displayName="MarkdownH5";var H0=be(({children:e,className:t,node:n,...r})=>g("h6",{className:ee("mt-6 mb-2 font-semibold text-sm",t),"data-streamdown":"heading-6",...r,children:e}),(e,t)=>Ie(e,t));H0.displayName="MarkdownH6";var U0=be(({children:e,className:t,node:n,...r})=>{let{controls:i}=We(et),a=Na(i,"table");return g(Qx,{className:t,showControls:a,...r,children:e})},(e,t)=>Ie(e,t));U0.displayName="MarkdownTable";var z0=be(({children:e,className:t,node:n,...r})=>g("thead",{className:ee("bg-muted/80",t),"data-streamdown":"table-header",...r,children:e}),(e,t)=>Ie(e,t));z0.displayName="MarkdownThead";var $0=be(({children:e,className:t,node:n,...r})=>g("tbody",{className:ee("divide-y divide-border",t),"data-streamdown":"table-body",...r,children:e}),(e,t)=>Ie(e,t));$0.displayName="MarkdownTbody";var Y0=be(({children:e,className:t,node:n,...r})=>g("tr",{className:ee("border-border",t),"data-streamdown":"table-row",...r,children:e}),(e,t)=>Ie(e,t));Y0.displayName="MarkdownTr";var j0=be(({children:e,className:t,node:n,...r})=>g("th",{className:ee("whitespace-nowrap px-4 py-2 text-left font-semibold text-sm",t),"data-streamdown":"table-header-cell",...r,children:e}),(e,t)=>Ie(e,t));j0.displayName="MarkdownTh";var V0=be(({children:e,className:t,node:n,...r})=>g("td",{className:ee("px-4 py-2 text-sm",t),"data-streamdown":"table-cell",...r,children:e}),(e,t)=>Ie(e,t));V0.displayName="MarkdownTd";var q0=be(({children:e,className:t,node:n,...r})=>g("blockquote",{className:ee("my-4 border-muted-foreground/30 border-l-4 pl-4 text-muted-foreground italic",t),"data-streamdown":"blockquote",...r,children:e}),(e,t)=>Ie(e,t));q0.displayName="MarkdownBlockquote";var W0=be(({children:e,className:t,node:n,...r})=>g("sup",{className:ee("text-sm",t),"data-streamdown":"superscript",...r,children:e}),(e,t)=>Ie(e,t));W0.displayName="MarkdownSup";var G0=be(({children:e,className:t,node:n,...r})=>g("sub",{className:ee("text-sm",t),"data-streamdown":"subscript",...r,children:e}),(e,t)=>Ie(e,t));G0.displayName="MarkdownSub";var Q0=be(({children:e,className:t,node:n,...r})=>{if("data-footnotes"in r){let i=s=>{var o,u;if(!Ot(s))return!1;let l=Array.isArray(s.props.children)?s.props.children:[s.props.children],h=!1,d=!1;for(let p of l)if(p){if(typeof p=="string")p.trim()!==""&&(h=!0);else if(Ot(p))if(((o=p.props)==null?void 0:o["data-footnote-backref"])!==void 0)d=!0;else{let f=Array.isArray(p.props.children)?p.props.children:[p.props.children];for(let m of f){if(typeof m=="string"&&m.trim()!==""){h=!0;break}if(Ot(m)&&((u=m.props)==null?void 0:u["data-footnote-backref"])===void 0){h=!0;break}}}}return d&&!h},a=Array.isArray(e)?e.map(s=>{if(!Ot(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)?g("section",{className:t,...r,children:a}):null}return g("section",{className:t,...r,children:e})},(e,t)=>Ie(e,t));Q0.displayName="MarkdownSection";var Jx=({node:e,className:t,children:n,...r})=>{var i;let a=!("data-block"in r),{mermaid:s,controls:o}=We(et),u=Cs(),l=_x();if(a)return g("code",{className:ee("rounded bg-muted px-1.5 py-0.5 font-mono text-sm",t),"data-streamdown":"inline-code",...r,children:n});let h=t==null?void 0:t.match(Xx),d=(i=h==null?void 0:h.at(1))!=null?i:"",p="";if(Ot(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),d==="mermaid"&&u){let m=Na(o,"mermaid"),_=Ir(o,"download"),x=Ir(o,"copy"),k=Ir(o,"fullscreen"),v=Ir(o,"panZoom"),C=m&&(_||x||k);return g(jn,{fallback:g(Dx,{}),children:g("div",{className:ee("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:[g("div",{className:"flex h-8 items-center text-muted-foreground text-xs",children:g("span",{className:"ml-1 font-mono lowercase",children:"mermaid"})}),C?g("div",{className:"pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end",children:g("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:[_?g($x,{chart:p,config:s==null?void 0:s.config}):null,x?g(Uu,{code:p}):null,k?g(Vx,{chart:p,config:s==null?void 0:s.config}):null]})}):null,g("div",{className:"rounded-md border border-border bg-background",children:g(Kx,{chart:p,config:s==null?void 0:s.config,showControls:v})})]})})}let f=Na(o,"code");return g(Sx,{className:t,code:p,isIncomplete:l,language:d,children:f?g(xe,{children:[g(Ox,{code:p,language:d}),g(Uu,{})]}):null})},K0=be(Jx,(e,t)=>e.className===t.className&&Si(e.node,t.node));K0.displayName="MarkdownCode";var X0=be(Mx,(e,t)=>e.className===t.className&&Si(e.node,t.node));X0.displayName="MarkdownImg";var Z0=be(({children:e,node:t,...n})=>{let r=(Array.isArray(e)?e:[e]).filter(i=>i!=null&&i!=="");if(r.length===1&&Ot(r[0])){let i=r[0].props.node,a=i==null?void 0:i.tagName;if(a==="img")return g(xe,{children:e});if(a==="code"&&"data-block"in r[0].props)return g(xe,{children:e})}return g("p",{...n,children:e})},(e,t)=>Ie(e,t));Z0.displayName="MarkdownParagraph";var ey={ol:Ss,li:I0,ul:N0,hr:L0,strong:R0,a:O0,h1:D0,h2:P0,h3:M0,h4:B0,h5:F0,h6:H0,table:U0,thead:z0,tbody:$0,tr:Y0,th:j0,td:V0,blockquote:q0,code:K0,img:X0,pre:({children:e})=>Ot(e)?mf(e,{"data-block":"true"}):e,sup:W0,sub:G0,p:Z0,section:Q0},ty=/^[ \t]{0,3}(`{3,}|~{3,})/,ny=/^\|?[ \t]*:?-{1,}:?[ \t]*(\|[ \t]*:?-{1,}:?[ \t]*)*\|?$/,$u=e=>{let t=e.split(`
|
|
117
|
-
`),n=null,r=0;for(let i of t){let a=
|
|
118
|
-
`);for(let n of t){let r=n.trim();if(r.length>0&&r.includes("|")&&
|
|
115
|
+
`)},ta=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("")},La=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=>ta(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 l=0;l<t.length;l+=1)u[l]=l<o.length?ta(o[l]):"";r[i]=`| ${u.join(" | ")} |`,i+=1}else{let u=o.map(l=>ta(l));r[i]=`| ${u.join(" | ")} |`,i+=1}return r.join(`
|
|
116
|
+
`)},ty=({children:e,className:t,onCopy:n,onError:r,timeout:i=2e3})=>{let[a,s]=fe(!1),[o,u]=fe(!1),l=ve(null),h=ve(0),{isAnimating:d}=Ge(et),p=async m=>{var _,x;if(typeof window>"u"||!((_=navigator==null?void 0:navigator.clipboard)!=null&&_.write)){r==null||r(new Error("Clipboard API not available"));return}try{let k=(x=l.current)==null?void 0:x.closest('[data-streamdown="table-wrapper"]'),v=k==null?void 0:k.querySelector("table");if(!v){r==null||r(new Error("Table not found"));return}let C=I0(v),R=({csv:N0,tsv:ey,md:La}[m]||La)(C),F=new ClipboardItem({"text/plain":new Blob([R],{type:"text/plain"}),"text/html":new Blob([v.outerHTML],{type:"text/html"})});await navigator.clipboard.write([F]),u(!0),s(!1),n==null||n(m),h.current=window.setTimeout(()=>u(!1),i)}catch(k){r==null||r(k)}};Ce(()=>{let m=_=>{let x=_.composedPath();l.current&&!x.includes(l.current)&&s(!1)};return document.addEventListener("mousedown",m),()=>{document.removeEventListener("mousedown",m),window.clearTimeout(h.current)}},[]);let f=o?Cs:Ss;return g("div",{className:"relative",ref:l,children:[g("button",{className:ee("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??g(f,{size:14})}),a?g("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:[g("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>p("md"),title:"Copy table as Markdown",type:"button",children:"Markdown"}),g("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>p("csv"),title:"Copy table as CSV",type:"button",children:"CSV"}),g("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>p("tsv"),title:"Copy table as TSV",type:"button",children:"TSV"})]}):null]})},ny=({children:e,className:t,onDownload:n,onError:r})=>{let[i,a]=fe(!1),s=ve(null),{isAnimating:o}=Ge(et),u=l=>{var h;try{let d=(h=s.current)==null?void 0:h.closest('[data-streamdown="table-wrapper"]'),p=d==null?void 0:d.querySelector("table");if(!p){r==null||r(new Error("Table not found"));return}let f=I0(p),m=l==="csv"?N0(f):La(f);gn(`table.${l==="csv"?"csv":"md"}`,m,l==="csv"?"text/csv":"text/markdown"),a(!1),n==null||n(l)}catch(d){r==null||r(d)}};return Ce(()=>{let l=h=>{let d=h.composedPath();s.current&&!d.includes(s.current)&&a(!1)};return document.addEventListener("mousedown",l),()=>{document.removeEventListener("mousedown",l)}},[]),g("div",{className:"relative",ref:s,children:[g("button",{className:ee("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??g(vi,{size:14})}),i?g("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:[g("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"}),g("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]})},ry=({children:e,className:t,showControls:n,...r})=>g("div",{className:"my-4 flex flex-col gap-2 rounded-lg border border-border bg-sidebar p-2","data-streamdown":"table-wrapper",children:[n?g("div",{className:"flex items-center justify-end gap-1",children:[g(ty,{}),g(ny,{})]}):null,g("div",{className:"border-collapse overflow-x-auto overscroll-y-auto rounded-md border border-border bg-background",children:g("table",{className:ee("w-full divide-y divide-border",t),"data-streamdown":"table",...r,children:e})})]}),iy=Vl(()=>Promise.resolve().then(()=>require("./mermaid-3ZIDBTTL-03c52040.cjs")).then(e=>({default:e.Mermaid}))),ay=/language-([^\s]+)/;function Ii(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==null?void 0:n.line)===(r==null?void 0:r.line)&&(n==null?void 0:n.column)===(r==null?void 0:r.column)&&(i==null?void 0:i.line)===(a==null?void 0:a.line)&&(i==null?void 0:i.column)===(a==null?void 0:a.column)}function Ie(e,t){return e.className===t.className&&Ii(e.node,t.node)}var Ra=(e,t)=>typeof e=="boolean"?e:e[t]!==!1,Ir=(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},Is=Ee(({children:e,className:t,node:n,...r})=>g("ol",{className:ee("list-inside list-decimal whitespace-normal [li_&]:pl-6",t),"data-streamdown":"ordered-list",...r,children:e}),(e,t)=>Ie(e,t));Is.displayName="MarkdownOl";var L0=Ee(({children:e,className:t,node:n,...r})=>g("li",{className:ee("py-1 [&>p]:inline",t),"data-streamdown":"list-item",...r,children:e}),(e,t)=>e.className===t.className&&Ii(e.node,t.node));L0.displayName="MarkdownLi";var R0=Ee(({children:e,className:t,node:n,...r})=>g("ul",{className:ee("list-inside list-disc whitespace-normal [li_&]:pl-6",t),"data-streamdown":"unordered-list",...r,children:e}),(e,t)=>Ie(e,t));R0.displayName="MarkdownUl";var O0=Ee(({className:e,node:t,...n})=>g("hr",{className:ee("my-6 border-border",e),"data-streamdown":"horizontal-rule",...n}),(e,t)=>Ie(e,t));O0.displayName="MarkdownHr";var D0=Ee(({children:e,className:t,node:n,...r})=>g("span",{className:ee("font-semibold",t),"data-streamdown":"strong",...r,children:e}),(e,t)=>Ie(e,t));D0.displayName="MarkdownStrong";var sy=({children:e,className:t,href:n,node:r,...i})=>{let{linkSafety:a}=Ge(et),[s,o]=fe(!1),u=n==="streamdown:incomplete-link",l=$e(async f=>{if(!(!(a!=null&&a.enabled&&n)||u)){if(f.preventDefault(),a.onLinkCheck&&await a.onLinkCheck(n)){window.open(n,"_blank","noreferrer");return}o(!0)}},[a,n,u]),h=$e(()=>{n&&window.open(n,"_blank","noreferrer")},[n]),d=$e(()=>{o(!1)},[]),p={url:n??"",isOpen:s,onClose:d,onConfirm:h};return a!=null&&a.enabled&&n?g(pe,{children:[g("button",{className:ee("wrap-anywhere appearance-none text-left font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",onClick:l,type:"button",children:e}),a.renderModal?a.renderModal(p):g(Wx,{...p})]}):g("a",{className:ee("wrap-anywhere font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",href:n,rel:"noreferrer",target:"_blank",...i,children:e})},P0=Ee(sy,(e,t)=>Ie(e,t)&&e.href===t.href);P0.displayName="MarkdownA";var M0=Ee(({children:e,className:t,node:n,...r})=>g("h1",{className:ee("mt-6 mb-2 font-semibold text-3xl",t),"data-streamdown":"heading-1",...r,children:e}),(e,t)=>Ie(e,t));M0.displayName="MarkdownH1";var B0=Ee(({children:e,className:t,node:n,...r})=>g("h2",{className:ee("mt-6 mb-2 font-semibold text-2xl",t),"data-streamdown":"heading-2",...r,children:e}),(e,t)=>Ie(e,t));B0.displayName="MarkdownH2";var F0=Ee(({children:e,className:t,node:n,...r})=>g("h3",{className:ee("mt-6 mb-2 font-semibold text-xl",t),"data-streamdown":"heading-3",...r,children:e}),(e,t)=>Ie(e,t));F0.displayName="MarkdownH3";var H0=Ee(({children:e,className:t,node:n,...r})=>g("h4",{className:ee("mt-6 mb-2 font-semibold text-lg",t),"data-streamdown":"heading-4",...r,children:e}),(e,t)=>Ie(e,t));H0.displayName="MarkdownH4";var U0=Ee(({children:e,className:t,node:n,...r})=>g("h5",{className:ee("mt-6 mb-2 font-semibold text-base",t),"data-streamdown":"heading-5",...r,children:e}),(e,t)=>Ie(e,t));U0.displayName="MarkdownH5";var z0=Ee(({children:e,className:t,node:n,...r})=>g("h6",{className:ee("mt-6 mb-2 font-semibold text-sm",t),"data-streamdown":"heading-6",...r,children:e}),(e,t)=>Ie(e,t));z0.displayName="MarkdownH6";var $0=Ee(({children:e,className:t,node:n,...r})=>{let{controls:i}=Ge(et),a=Ra(i,"table");return g(ry,{className:t,showControls:a,...r,children:e})},(e,t)=>Ie(e,t));$0.displayName="MarkdownTable";var Y0=Ee(({children:e,className:t,node:n,...r})=>g("thead",{className:ee("bg-muted/80",t),"data-streamdown":"table-header",...r,children:e}),(e,t)=>Ie(e,t));Y0.displayName="MarkdownThead";var j0=Ee(({children:e,className:t,node:n,...r})=>g("tbody",{className:ee("divide-y divide-border",t),"data-streamdown":"table-body",...r,children:e}),(e,t)=>Ie(e,t));j0.displayName="MarkdownTbody";var V0=Ee(({children:e,className:t,node:n,...r})=>g("tr",{className:ee("border-border",t),"data-streamdown":"table-row",...r,children:e}),(e,t)=>Ie(e,t));V0.displayName="MarkdownTr";var q0=Ee(({children:e,className:t,node:n,...r})=>g("th",{className:ee("whitespace-nowrap px-4 py-2 text-left font-semibold text-sm",t),"data-streamdown":"table-header-cell",...r,children:e}),(e,t)=>Ie(e,t));q0.displayName="MarkdownTh";var W0=Ee(({children:e,className:t,node:n,...r})=>g("td",{className:ee("px-4 py-2 text-sm",t),"data-streamdown":"table-cell",...r,children:e}),(e,t)=>Ie(e,t));W0.displayName="MarkdownTd";var G0=Ee(({children:e,className:t,node:n,...r})=>g("blockquote",{className:ee("my-4 border-muted-foreground/30 border-l-4 pl-4 text-muted-foreground italic",t),"data-streamdown":"blockquote",...r,children:e}),(e,t)=>Ie(e,t));G0.displayName="MarkdownBlockquote";var Q0=Ee(({children:e,className:t,node:n,...r})=>g("sup",{className:ee("text-sm",t),"data-streamdown":"superscript",...r,children:e}),(e,t)=>Ie(e,t));Q0.displayName="MarkdownSup";var K0=Ee(({children:e,className:t,node:n,...r})=>g("sub",{className:ee("text-sm",t),"data-streamdown":"subscript",...r,children:e}),(e,t)=>Ie(e,t));K0.displayName="MarkdownSub";var X0=Ee(({children:e,className:t,node:n,...r})=>{if("data-footnotes"in r){let i=s=>{var o,u;if(!Ot(s))return!1;let l=Array.isArray(s.props.children)?s.props.children:[s.props.children],h=!1,d=!1;for(let p of l)if(p){if(typeof p=="string")p.trim()!==""&&(h=!0);else if(Ot(p))if(((o=p.props)==null?void 0:o["data-footnote-backref"])!==void 0)d=!0;else{let f=Array.isArray(p.props.children)?p.props.children:[p.props.children];for(let m of f){if(typeof m=="string"&&m.trim()!==""){h=!0;break}if(Ot(m)&&((u=m.props)==null?void 0:u["data-footnote-backref"])===void 0){h=!0;break}}}}return d&&!h},a=Array.isArray(e)?e.map(s=>{if(!Ot(s))return s;if(s.type===Is){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)?g("section",{className:t,...r,children:a}):null}return g("section",{className:t,...r,children:e})},(e,t)=>Ie(e,t));X0.displayName="MarkdownSection";var oy=({node:e,className:t,children:n,...r})=>{var i;let a=!("data-block"in r),{mermaid:s,controls:o}=Ge(et),u=vs(),l=vx();if(a)return g("code",{className:ee("rounded bg-muted px-1.5 py-0.5 font-mono text-sm",t),"data-streamdown":"inline-code",...r,children:n});let h=t==null?void 0:t.match(ay),d=(i=h==null?void 0:h.at(1))!=null?i:"",p="";if(Ot(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),d==="mermaid"&&u){let m=Ra(o,"mermaid"),_=Ir(o,"download"),x=Ir(o,"copy"),k=Ir(o,"fullscreen"),v=Ir(o,"panZoom"),C=m&&(_||x||k);return g(Vn,{fallback:g($x,{}),children:g("div",{className:ee("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:[g("div",{className:"flex h-8 items-center text-muted-foreground text-xs",children:g("span",{className:"ml-1 font-mono lowercase",children:"mermaid"})}),C?g("div",{className:"pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end",children:g("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:[_?g(Kx,{chart:p,config:s==null?void 0:s.config}):null,x?g($u,{code:p}):null,k?g(Jx,{chart:p,config:s==null?void 0:s.config}):null]})}):null,g("div",{className:"rounded-md border border-border bg-background",children:g(iy,{chart:p,config:s==null?void 0:s.config,showControls:v})})]})})}let f=Ra(o,"code");return g(Px,{className:t,code:p,isIncomplete:l,language:d,children:f?g(pe,{children:[g(zx,{code:p,language:d}),g($u,{})]}):null})},Z0=Ee(oy,(e,t)=>e.className===t.className&&Ii(e.node,t.node));Z0.displayName="MarkdownCode";var J0=Ee(jx,(e,t)=>e.className===t.className&&Ii(e.node,t.node));J0.displayName="MarkdownImg";var eh=Ee(({children:e,node:t,...n})=>{let r=(Array.isArray(e)?e:[e]).filter(i=>i!=null&&i!=="");if(r.length===1&&Ot(r[0])){let i=r[0].props.node,a=i==null?void 0:i.tagName;if(a==="img")return g(pe,{children:e});if(a==="code"&&"data-block"in r[0].props)return g(pe,{children:e})}return g("p",{...n,children:e})},(e,t)=>Ie(e,t));eh.displayName="MarkdownParagraph";var uy={ol:Is,li:L0,ul:R0,hr:O0,strong:D0,a:P0,h1:M0,h2:B0,h3:F0,h4:H0,h5:U0,h6:z0,table:$0,thead:Y0,tbody:j0,tr:V0,th:q0,td:W0,blockquote:G0,code:Z0,img:J0,pre:({children:e})=>Ot(e)?yf(e,{"data-block":"true"}):e,sup:Q0,sub:K0,p:eh,section:X0},ly=/^[ \t]{0,3}(`{3,}|~{3,})/,cy=/^\|?[ \t]*:?-{1,}:?[ \t]*(\|[ \t]*:?-{1,}:?[ \t]*)*\|?$/,ju=e=>{let t=e.split(`
|
|
117
|
+
`),n=null,r=0;for(let i of t){let a=ly.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},dy=e=>{let t=e.split(`
|
|
118
|
+
`);for(let n of t){let r=n.trim();if(r.length>0&&r.includes("|")&&cy.test(r))return!0}return!1},hy=()=>e=>{Mt(e,"html",(t,n,r)=>{!r||typeof n!="number"||(r.children[n]={type:"text",value:t.value})})},Vu=[],qu={allowDangerousHtml:!0},Nr=new WeakMap,fy=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 h="default";return this.keyCache.set(e,h),h}let a=h=>{if(!h||h.length===0)return"";let d="";for(let p=0;p<h.length;p+=1){let f=h[p];if(p>0&&(d+=","),Array.isArray(f)){let[m,_]=f;if(typeof m=="function"){let x=Nr.get(m);x||(x=m.name,Nr.set(m,x)),d+=x}else d+=String(m);d+=":",d+=JSON.stringify(_)}else if(typeof f=="function"){let m=Nr.get(f);m||(m=f.name,Nr.set(f,m)),d+=m}else d+=String(f)}return d},s=a(n),o=a(r),u=i?JSON.stringify(i):"",l=`${o}::${s}::${u}`;return this.keyCache.set(e,l),l}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()}},Wu=new fy,th=e=>{let t=py(e),n=e.children||"";return ky(t.runSync(t.parse(n),n),e)},py=e=>{let t=Wu.get(e);if(t)return t;let n=gy(e);return Wu.set(e,n),n},my=e=>e.some(t=>Array.isArray(t)?t[0]===ga:t===ga),gy=e=>{let t=e.rehypePlugins||Vu,n=e.remarkPlugins||Vu,r=my(t)?n:[...n,hy],i=e.remarkRehypeOptions?{...qu,...e.remarkRehypeOptions}:qu;return y6().use(yk).use(r).use(a6,i).use(t)},by=e=>e,Ey=(e,t,n,r)=>{n?e.children.splice(t,1):e.children[t]={type:"text",value:r}},Ty=(e,t)=>{var n;for(let r in Wi)if(Object.hasOwn(Wi,r)&&Object.hasOwn(e.properties,r)){let i=e.properties[r],a=Wi[r];(a===null||a.includes(e.tagName))&&(e.properties[r]=(n=t(String(i||""),r,e))!=null?n:void 0)}},_y=(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},ky=(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||by;Mt(e,(l,h,d)=>{if(l.type==="raw"&&d&&typeof h=="number")return Ey(d,h,a,l.value),h;if(l.type==="element"&&(Ty(l,u),_y(l,h,d,r,i,n)&&d&&typeof h=="number"))return s&&l.children?d.children.splice(h,1,...l.children):d.children.splice(h,1),h})}return L_(e,{Fragment:pe,components:t.components,ignoreInvalidStyle:!0,jsx:g,jsxs:g,passKeys:!0,passNode:!0})},xy=/\[\^[\w-]{1,200}\](?!:)/,yy=/\[\^[\w-]{1,200}\]:/,wy=/<(\w+)[\s>]/,Ay=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]),Gu=new Map,Qu=new Map,Cy=e=>{let t=e.toLowerCase(),n=Gu.get(t);if(n)return n;let r=new RegExp(`<${t}(?=[\\s>/])[^>]*>`,"gi");return Gu.set(t,r),r},Sy=e=>{let t=e.toLowerCase(),n=Qu.get(t);if(n)return n;let r=new RegExp(`</${t}(?=[\\s>])[^>]*>`,"gi");return Qu.set(t,r),r},Ku=(e,t)=>{if(Ay.has(t.toLowerCase()))return 0;let n=e.match(Cy(t));if(!n)return 0;let r=0;for(let i of n)i.trimEnd().endsWith("/>")||(r+=1);return r},Xu=(e,t)=>{let n=e.match(Sy(t));return n?n.length:0},vy=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},Iy=e=>{let t=xy.test(e),n=yy.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,l=i.length;if(a.length>0){i[l-1]+=u;let h=a.at(-1),d=Ku(u,h),p=Xu(u,h);for(let f=0;f<d;f+=1)a.push(h);for(let f=0;f<p;f+=1)a.length>0&&a.at(-1)===h&&a.pop();continue}if(o.type==="html"&&o.block){let h=u.match(wy);if(h){let d=h[1],p=Ku(u,d),f=Xu(u,d);p>f&&a.push(d)}}if(l>0&&!s){let h=i[l-1];if(vy(h)%2===1){i[l-1]=h+u;continue}}i.push(u),o.type!=="space"&&(s=o.type==="code")}return i},Ny=(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 l=o.replace(/\n\n/g,`
|
|
119
119
|
<!---->
|
|
120
|
-
`);return s+l+u})}return n},yy=/^[ \t]*<[\w!/?-]/,wy=/(^|\n)[ \t]{4,}(?=<[\w!/?-])/g,Ay=e=>typeof e!="string"||e.length===0||!yy.test(e)?e:e.replace(wy,"$1"),Ku,Xu,Ur={...Xn,protocols:{...Xn.protocols,href:[...(Xu=(Ku=Xn.protocols)==null?void 0:Ku.href)!=null?Xu:[],"tel"]}},La={raw:pa,sanitize:[Wc,Ur],harden:[wf,{allowedImagePrefixes:["*"],allowedLinkPrefixes:["*"],allowedProtocols:["*"],defaultOrigin:void 0,allowDataImages:!0}]},Cy={gfm:[$E,{}]},Zu=Object.values(La),Sy=Object.values(Cy),vy={block:" ▋",circle:" ●"},Iy={shikiTheme:["github-light","github-dark"],controls:!0,isAnimating:!1,mode:"streaming",mermaid:void 0,linkSafety:{enabled:!0}},et=oi(Iy),eh=be(({content:e,shouldParseIncompleteMarkdown:t,shouldNormalizeHtmlIndentation:n,index:r,isIncomplete:i,...a})=>{let s=typeof e=="string"&&n?Ay(e):e;return g(k0.Provider,{value:i,children:g(J0,{...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)});eh.displayName="Block";var Ny=["github-light","github-dark"],th=be(({children:e,mode:t="streaming",parseIncompleteMarkdown:n=!0,normalizeHtmlIndentation:r=!1,components:i,rehypePlugins:a=Zu,remarkPlugins:s=Sy,className:o,shikiTheme:u=Ny,mermaid:l,controls:h=!0,isAnimating:d=!1,animated:p,BlockComponent:f=eh,parseMarkdownIntoBlocksFn:m=ky,caret:_,plugins:x,remend:k,linkSafety:v={enabled:!0},allowedTags:C,...R})=>{let F=vh(),[S,Y]=bf(),L=Ne(()=>C?Object.keys(C):[],[C]),D=Ne(()=>{if(typeof e!="string")return"";let Z=t==="streaming"&&n?Q3(e,k):e;return L.length>0&&(Z=xy(Z,L)),Z},[e,t,n,k,L]),A=Ne(()=>m(D),[D,m]),[z,P]=fe(A);Ce(()=>{t==="streaming"?Y(()=>{P(A)}):P(A)},[A,t]);let Q=t==="streaming"?z:A,ue=Ne(()=>Q.map((Z,w)=>`${F}-${w}`),[Q.length,F]),J=Ne(()=>p?p===!0?Sa():Sa(p):null,[p]),oe=Ne(()=>{var Z,w;return{shikiTheme:(w=(Z=x==null?void 0:x.code)==null?void 0:Z.getThemes())!=null?w:u,controls:h,isAnimating:d,mode:t,mermaid:l,linkSafety:v}},[u,h,d,t,l,v,x==null?void 0:x.code]),q=Ne(()=>({...ey,...i}),[i]),K=Ne(()=>{let Z=[];return x!=null&&x.cjk&&(Z=[...Z,...x.cjk.remarkPluginsBefore]),Z=[...Z,...s],x!=null&&x.cjk&&(Z=[...Z,...x.cjk.remarkPluginsAfter]),x!=null&&x.math&&(Z=[...Z,x.math.remarkPlugin]),Z},[s,x==null?void 0:x.math,x==null?void 0:x.cjk]),W=Ne(()=>{var Z;let w=a;if(C&&Object.keys(C).length>0&&a===Zu){let Se={...Ur,tagNames:[...(Z=Ur.tagNames)!=null?Z:[],...Object.keys(C)],attributes:{...Ur.attributes,...C}};w=[La.raw,[Wc,Se],La.harden]}return x!=null&&x.math&&(w=[...w,x.math.rehypePlugin]),J&&d&&(w=[...w,J.rehypePlugin]),w},[a,x==null?void 0:x.math,J,d,C]),E=Ne(()=>{if(!d||Q.length===0)return!1;let Z=Q.at(-1);return $u(Z)||ry(Z)},[d,Q]),he=Ne(()=>_&&d&&!E?{"--streamdown-caret":`"${vy[_]}"`}:void 0,[_,d,E]);return t==="static"?g(va.Provider,{value:x??null,children:g(et.Provider,{value:oe,children:g("div",{className:ee("space-y-4 whitespace-normal *:first:mt-0 *:last:mb-0",o),children:g(J0,{components:q,rehypePlugins:W,remarkPlugins:K,...R,children:D})})})}):g(va.Provider,{value:x??null,children:g(et.Provider,{value:oe,children:g("div",{className:ee("space-y-4 whitespace-normal *:first:mt-0 *:last:mb-0",_&&!E?"*:last:after:inline *:last:after:align-baseline *:last:after:content-[var(--streamdown-caret)]":null,o),style:he,children:[Q.length===0&&_&&d&&g("span",{}),Q.map((Z,w)=>{let Se=w===Q.length-1,pe=d&&Se&&$u(Z);return g(f,{components:q,content:Z,index:w,isIncomplete:pe,rehypePlugins:W,remarkPlugins:K,shouldNormalizeHtmlIndentation:r,shouldParseIncompleteMarkdown:n,...R},ue[w])})]})})})},(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);th.displayName="Streamdown";var Ly=({children:e,className:t,minZoom:n=.5,maxZoom:r=3,zoomStep:i=.1,showControls:a=!0,initialZoom:s=1,fullscreen:o=!1})=>{let u=ve(null),l=ve(null),[h,d]=fe(s),[p,f]=fe({x:0,y:0}),[m,_]=fe(!1),[x,k]=fe({x:0,y:0}),[v,C]=fe({x:0,y:0}),R=ze(P=>{d(Q=>Math.max(n,Math.min(r,Q+P)))},[n,r]),F=ze(()=>{R(i)},[R,i]),S=ze(()=>{R(-i)},[R,i]),Y=ze(()=>{d(s),f({x:0,y:0})},[s]),L=ze(P=>{P.preventDefault();let Q=P.deltaY>0?-i:i;R(Q)},[R,i]),D=ze(P=>{if(P.button!==0||P.isPrimary===!1)return;_(!0),k({x:P.clientX,y:P.clientY}),C(p);let Q=P.currentTarget;Q instanceof HTMLElement&&Q.setPointerCapture(P.pointerId)},[p]),A=ze(P=>{if(!m)return;P.preventDefault();let Q=P.clientX-x.x,ue=P.clientY-x.y;f({x:v.x+Q,y:v.y+ue})},[m,x,v]),z=ze(P=>{_(!1);let Q=P.currentTarget;Q instanceof HTMLElement&&Q.releasePointerCapture(P.pointerId)},[]);return Ce(()=>{let P=u.current;if(P)return P.addEventListener("wheel",L,{passive:!1}),()=>{P.removeEventListener("wheel",L)}},[L]),Ce(()=>{let P=l.current;if(P&&m)return document.body.style.userSelect="none",P.addEventListener("pointermove",A,{passive:!1}),P.addEventListener("pointerup",z),P.addEventListener("pointercancel",z),()=>{document.body.style.userSelect="",P.removeEventListener("pointermove",A),P.removeEventListener("pointerup",z),P.removeEventListener("pointercancel",z)}},[m,A,z]),g("div",{className:ee("relative flex flex-col",o?"h-full w-full":"min-h-28 w-full",t),ref:u,style:{cursor:m?"grabbing":"grab"},children:[a?g("div",{className:ee("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:[g("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:h>=r,onClick:F,title:"Zoom in",type:"button",children:g(Lx,{size:16})}),g("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:h<=n,onClick:S,title:"Zoom out",type:"button",children:g(Rx,{size:16})}),g("button",{className:"flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",onClick:Y,title:"Reset zoom and pan",type:"button",children:g(Nx,{size:16})})]}):null,g("div",{className:ee("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:D,ref:l,role:"application",style:{transform:`translate(${p.x}px, ${p.y}px) scale(${h})`,transformOrigin:"center center",touchAction:"none",willChange:"transform"},children:e})]})},nh=({chart:e,className:t,config:n,fullscreen:r=!1,showControls:i=!0})=>{let[a,s]=fe(null),[o,u]=fe(!1),[l,h]=fe(""),[d,p]=fe(""),[f,m]=fe(0),{mermaid:_}=We(et),x=Cs(),k=_==null?void 0:_.errorComponent,{shouldRender:v,containerRef:C}=dx({immediate:r});if(Ce(()=>{if(v){if(!x){s("Mermaid plugin not available. Please add the mermaid plugin to enable diagram rendering.");return}(async()=>{try{s(null),u(!0);let F=x.getMermaid(n),S=e.split("").reduce((D,A)=>(D<<5)-D+A.charCodeAt(0)|0,0),Y=`mermaid-${Math.abs(S)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:L}=await F.render(Y,e);h(L),p(L)}catch(F){if(!(d||l)){let S=F instanceof Error?F.message:"Failed to render Mermaid chart";s(S)}}finally{u(!1)}})()}},[e,n,f,v,x]),!(v||l||d))return g("div",{className:ee("my-4 min-h-[200px]",t),ref:C});if(o&&!l&&!d)return g("div",{className:ee("my-4 flex justify-center p-4",t),ref:C,children:g("div",{className:"flex items-center space-x-2 text-muted-foreground",children:[g("div",{className:"h-4 w-4 animate-spin rounded-full border-current border-b-2"}),g("span",{className:"text-sm",children:"Loading diagram..."})]})});if(a&&!l&&!d)return k?g("div",{ref:C,children:g(k,{chart:e,error:a,retry:()=>m(S=>S+1)})}):g("div",{className:ee("rounded-md bg-red-50 p-4",t),ref:C,children:[g("p",{className:"font-mono text-red-700 text-sm",children:["Mermaid Error: ",a]}),g("details",{className:"mt-2",children:[g("summary",{className:"cursor-pointer text-red-600 text-xs",children:"Show Code"}),g("pre",{className:"mt-2 overflow-x-auto rounded bg-red-100 p-2 text-red-800 text-xs",children:e})]})]});let R=l||d;return g("div",{className:ee("size-full",t),"data-streamdown":"mermaid",ref:C,children:g(Ly,{className:ee(r?"size-full overflow-hidden":"overflow-hidden",t),fullscreen:r,maxZoom:3,minZoom:.5,showControls:i,zoomStep:.1,children:g("div",{"aria-label":"Mermaid chart",className:ee("flex justify-center",r?"size-full items-center":null),dangerouslySetInnerHTML:{__html:R},role:"img"})})})};function Ry({href:e,children:t}){return g("a",{href:e,target:"_blank",rel:"noopener noreferrer",class:"fr hover:text-a-9 focus-visible:rounded-kin-xs text-inherit underline underline-offset-2 transition-all hover:underline-offset-4",children:t})}const Oy={a:Ry};function rh({content:e,isStreaming:t=!1}){return e?g("div",{class:"kin-markdown text-n-12 border-n-4 border-b pb-2.5 text-sm leading-relaxed",children:g(th,{isAnimating:t,mode:t?"streaming":"static",components:Oy,children:e})}):null}const Dy={thinking:{label:"Thinking…",icon:qs},responding:{label:"Writing response…",icon:Qs},processing_results:{label:"Processing results…",icon:qs},processing_cv:{label:"Scanning your CV…",icon:Gs},searchJobs:{label:"Searching jobs…",icon:Ws},matchJobs:{label:"Matching jobs…",icon:Ws},searchKnowledge:{label:"Searching company info…",icon:Xh},getProfileSummary:{label:"Reviewing your profile…",icon:Gs},updatePreferences:{label:"Updating your preferences…",icon:Zh},remember:{label:"Saving details…",icon:Jh},suggestQuickReplies:{label:"Preparing reply options…",icon:Qs}},ih=Ft({base:"animate-kin-message-in flex max-w-[85%] flex-col",variants:{side:{user:"self-end",assistant:"self-start gap-1.5 p-1"}}});function Py(){const e=ve(null);return g("div",{ref:e,class:"pl-safe-l pr-safe-r [&::-webkit-scrollbar-thumb]:bg-n-4 [&::-webkit-scrollbar-thumb]:rounded-kin-xs flex min-h-0 flex-1 flex-col gap-4 overflow-y-auto overscroll-none scroll-smooth break-words py-4 [mask-image:linear-gradient(to_bottom,transparent_0,_black_1.5rem,_black_calc(100%-1.5rem),transparent_100%)] sm:overscroll-auto sm:px-4 [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar]:w-1.5 [&>:first-child]:mt-auto",role:"log","aria-label":"Chat messages","aria-live":"polite","aria-relevant":"additions",children:[g(By,{}),g(Fy,{}),g(Hy,{}),g(My,{containerRef:e})]})}function My({containerRef:e}){var h,d;const[t,n]=fe(!0),r=ve(!1),i=$.messages.value.length,a=((h=$.messages.value.at(-1))==null?void 0:h.role)==="user",s=(d=$.liveAssistantMessage.value)==null?void 0:d.content,o=$.assistantStatus.value,u=$.quickReplies.value.length,l=()=>{const p=e.current;p&&(r.current=!0,p.scrollTop=p.scrollHeight,n(!0))};return Ce(()=>{const p=e.current;if(!p)return;l();const f=()=>{const m=p.scrollHeight-p.scrollTop-p.clientHeight<80;r.current?r.current=!m:n(m)};return p.addEventListener("scroll",f,{passive:!0}),()=>p.removeEventListener("scroll",f)},[]),Ce(()=>{(t||a)&&l()},[i,s,o,u,a]),t?null:g("button",{type:"button",class:rr({variant:"neutral",size:"sm",class:"absolute bottom-3 left-1/2 -translate-x-1/2"}),"aria-label":"Scroll to latest message",onClick:l,children:g(ef,{strokeWidth:2})})}function By(){const e=$.messages.value.length,t=!!($.liveAssistantMessage.value||$.isStreaming.value||$.assistantStatus.value);return e||t?null:g("div",{class:"animate-kin-fade-in my-auto px-6 py-6 text-center",style:{animationDelay:"150ms"},children:[g("div",{class:"text-n-9 mx-auto mb-4 size-12 opacity-50","aria-hidden":"true",children:g(Vh,{class:"h-full w-full"})}),g("p",{class:"text-n-12 mb-2 text-base",children:"Hi there, you're speaking with Kin AI Agent."}),g("p",{class:"text-n-9 text-sm",children:"How can I help you today?"})]})}function Fy(){return g(xe,{children:$.messages.value.filter(e=>e.role!=="assistant"||!!e.content.trim()).filter(e=>e.role!=="user"||!!e.content.trim()||!!e.attachment).map((e,t)=>g(Uy,{message:e,animationIndex:t},e.id))})}function ah({statusMeta:e,timestamp:t}){const n=e==null?void 0:e.icon;return g("div",{class:"text-n-9 inline-flex items-center gap-1.5 text-xs","aria-hidden":"true",children:n?g(xe,{children:[g(n,{class:"size-3 shrink-0 animate-pulse"}),g("span",{class:"animate-kin-shimmer bg-[linear-gradient(90deg,oklch(var(--n-9))_40%,oklch(var(--n-11))_50%,oklch(var(--n-9))_60%)] bg-[length:200%_100%] bg-clip-text text-transparent",children:e.label})]}):g("span",{children:["Kin • AI Agent • ",t?zy(t):"typing..."]})})}function Hy(){const e=$.liveAssistantMessage.value,t=$.isStreaming.value,n=$.assistantStatus.value,r=n?Dy[n]:void 0;return!e&&!t&&!r?null:g("article",{class:ih({side:"assistant"}),"aria-label":"Message from Kin AI Agent",children:[e!=null&&e.content?g(rh,{content:e.content,isStreaming:t}):null,g(ah,{statusMeta:r,timestamp:t||e==null?void 0:e.timestamp})]})}function Uy({message:e,animationIndex:t}){const{role:n,content:r,timestamp:i,attachment:a}=e,s=n==="user",o=Math.min((t+1)*.05,.35);return n==="system"?g("div",{class:"flex justify-center px-4 py-2",role:"status","aria-label":"System notification",children:g("span",{class:"border-n-6/40 bg-n-3 text-n-9 corner-smooth rounded-kin-lg border px-3 py-1.5 text-xs",children:r})}):g("article",{class:ih({side:s?"user":"assistant"}),style:{animationDelay:`${o}s`},"aria-label":`Message from ${s?"You":"Kin AI Agent"}`,children:[s&&g("div",{class:"bg-n-3 text-n-12 corner-smooth rounded-kin-lg relative px-3.5 py-2 text-sm",children:[a&&g("div",{class:"text-n-10 flex items-center gap-1.5",children:[g(Hl,{class:"text-n-9 size-3.5 shrink-0"}),g("span",{class:"max-w-full truncate",children:a.name})]}),g("p",{children:r}),g("svg",{class:"text-n-3 absolute -bottom-1.5 right-1.5 w-4","aria-hidden":"true",viewBox:"0 0 16 8",children:g("path",{d:"M15 0S16 3 16 7C16 8 15 7 15 7 11 3 9 2 0 2Z",fill:"currentColor"})})]}),!s&&r&&g(rh,{content:r}),!s&&g(ah,{timestamp:i})]})}function zy(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"})}function sh({content:e,children:t}){var l;const[n,r]=fe(!1),i=ve(null),a=ve(null),s=t.props,o=_l(t,{ref:i,onMouseEnter:Lr(s.onMouseEnter,()=>r(!0)),onMouseLeave:Lr(s.onMouseLeave,()=>r(!1)),onFocus:Lr(s.onFocus,()=>r(!0)),onBlur:Lr(s.onBlur,()=>r(!1))});Ce(()=>{if(!n)return;const h=d=>{i.current&&!d.composedPath().includes(i.current)&&r(!1)};return document.addEventListener("pointerdown",h),()=>document.removeEventListener("pointerdown",h)},[n]),Sh(()=>{const h=i.current,d=a.current;if(!n||!h||!d)return;const p=h.getBoundingClientRect(),f=d.offsetWidth,m=d.offsetHeight,_=p.top>m+8,x=Math.max(4,Math.min(p.left+(p.width-f)/2,innerWidth-f-4)),k=p.left+p.width/2-x;d.setAttribute("data-side",_?"top":"bottom"),d.style.left=`${x}px`,d.style.top=`${_?p.top-m-6:p.bottom+6}px`,d.style.setProperty("--ax",`${k-12}px`),d.style.setProperty("--origin",`${k}px ${_?"100%":"0%"}`),requestAnimationFrame(()=>d.setAttribute("data-open",""))},[n,e]);const u=n?(l=i.current)==null?void 0:l.getRootNode():null;return g(xe,{children:[o,u&&jl(g("span",{ref:a,"data-side":"top",role:"tooltip",class:"bg-n-12 text-n-1 corner-smooth ease-out-back rounded-kin-sm duration-kin group pointer-events-none fixed z-[999999] origin-[--origin] scale-90 whitespace-nowrap px-2.5 py-1.5 text-xs opacity-0 transition-[opacity,transform] data-[open]:scale-100 data-[open]:opacity-100 data-[open]:delay-300",children:[e,g("svg",{viewBox:"0 0 32 32","aria-hidden":"true",class:"fill-n-12 absolute left-[--ax] w-6 group-data-[side=bottom]:-top-6 group-data-[side=top]:-bottom-6 group-data-[side=top]:rotate-180",children:g("path",{d:"M3 32C9 32 10 31 15 26Q16 25 17 26C22 31 23 32 29 32"})})]}),u)]})}function Lr(e,t){return typeof e=="function"?(...n)=>{e(...n),t()}:t}const $y=Ft({base:"relative animate-none flex min-h-0 w-full flex-1 flex-col overflow-hidden",variants:{embedded:{false:"sm:animate-kin-panel-in [will-change:transform,opacity]"}}});function Yy({embedded:e=!1,onClose:t,onClearData:n,onSkipToInput:r}){const[i,a]=fe(!1),s=()=>a(!1),o=l=>{if(l.key==="Escape"){if(l.preventDefault(),i){s();return}e||t()}},u=()=>{if(i){n(),s();return}a(!0)};return g("div",{class:$y({embedded:e}),role:"dialog","aria-modal":!e,"aria-labelledby":"kin-panel-title",onKeyDown:o,children:[g("button",{type:"button",class:"fr bg-n-2 text-n-12 rounded-kin-sm absolute -top-full left-1/2 z-[1000000] -translate-x-1/2 px-3 py-1.5 text-sm font-medium no-underline focus:top-2",onClick:r,children:"Skip to chat input"}),g("header",{class:"from-a-2/50 relative flex select-none items-center justify-between bg-gradient-to-b to-transparent p-4 sm:p-3 sm:pl-5",children:[g("h2",{id:"kin-panel-title",class:"text-n-12 m-0 text-base font-semibold sm:text-sm sm:font-medium",children:"Kin Assistant"}),!e&&g("div",{"aria-hidden":"true",class:"bg-n-5/50 absolute left-1/2 top-2 h-1 w-12 -translate-x-1/2 rounded-full"}),g("div",{class:"flex items-center gap-1.5",children:[g(sh,{content:i?"Click again to confirm":"Clear my data",children:g("button",{class:rr({variant:i?"accent":"ghost",size:"sm"}),"aria-label":i?"Confirm clear data":"Clear my data",type:"button",onClick:u,onBlur:s,children:i?g(Qh,{}):g(Gh,{})})}),!e&&g("button",{class:rr({variant:"neutral",size:"sm"}),"aria-label":"Close chat",type:"button",onClick:t,children:g(Wh,{strokeWidth:2})})]})]}),g(Py,{})]})}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}},Vy=".pdf,.docx,.doc,.txt,.jpg,.jpeg,.png,.webp";function qy(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 Wy(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 Gy({url:e,onMessage:t,onOpen:n,onClose:r,onError:i}){let a=null,s=[];const o=()=>(a==null?void 0:a.readyState)===WebSocket.OPEN,u=p=>{o()&&a.send(JSON.stringify(p))},l=p=>u({type:"user_message",content:p}),h=()=>{if(o()){for(const p of s)l(p);s.length=0}};return(()=>{a=new WebSocket(e),a.onopen=()=>{n(),h()},a.onmessage=p=>{try{const f=JSON.parse(p.data);t(f)}catch(f){console.error("Failed to parse message:",f)}},a.onclose=()=>{s=[],r(),a=null},a.onerror=p=>{i(p)}})(),{sendMessage:p=>{a&&(o()?l(p):a.readyState===WebSocket.CONNECTING&&s.push(p))},uploadFile:async(p,f)=>{if(!o())return{success:!1,error:"Not connected"};const m=qy(p);if(!m.valid)return{success:!1,error:m.error};try{const _=await Wy(p);return o()?(u({type:"file_upload",fileType:f,fileName:p.name,mimeType:p.type,data:_}),{success:!0}):{success:!1,error:"Connection lost while reading file. Please try again."}}catch(_){return{success:!1,error:_ instanceof Error?_.message:"Failed to read file"}}},clearData:()=>{u({type:"clear_data"})},disconnect:()=>{a&&(a.close(),a=null)},isConnected:()=>(a==null?void 0:a.readyState)===WebSocket.OPEN}}const Ju=2e3,el="absolute bottom-full left-1/2 mb-2 -translate-x-1/2 whitespace-nowrap rounded-kin-sm bg-red-600 px-3 py-2 text-xs text-white animate-kin-error-in",Qy=Ft({base:"w-full pt-1 px-2 pb-safe-b focus-within:pb-2 transition-all duration-kin ease-kin-fluid group-data-[placement=embedded]:pb-2",variants:{panelOpen:{true:"bg-gradient-to-b from-transparent to-n-2",false:"px-5 sm:px-14 group-data-[placement=left]:sm:pl-2 group-data-[placement=left]:sm:pr-24 group-data-[placement=right]:sm:pl-24 group-data-[placement=right]:sm:pr-2"}}}),Ky=Ft({base:"border outline relative flex p-0.5 gap-1 flex-col corner-smooth rounded-kin-3xl bg-highest transition-all duration-kin",variants:{panelOpen:{true:"outline-1 outline-transparent border-n-4 focus-within:outline-[3px] focus-within:outline-a-4/50 focus-within:border-a-6/50 shadow-md shadow-n-4/30",false:"outline-2 outline-a-9 border-transparent shadow-xl shadow-a-9/10"}}});function Xy({panelOpen:e,suggestions:t,onSubmit:n,onEscape:r,onFocus:i,onBlur:a,onUploadFile:s,inputRef:o}){const[u,l]=fe(""),h=ve(null),d=$.isStreaming.value,p=$.connectionState.value,f=$.uploadState.value,m=$.uploadError.value,_=$.uploadFileName.value,x=p==="connected",k=p==="connecting",v=p==="disconnected",C=p==="idle",R=f==="uploading"||f==="processing",F=u.length>Ju,S=u.trim(),Y=S.length>0,L=$.messages.value.length>0,D=t.length>0,A=_?`Uploading ${_}...`:"Uploading file...",z=Y&&!d&&!R&&!F&&(x||k),P=x&&!d&&!R,Q=D?"Or type a message...":R?A:k?"Connecting...":v?"Disconnected - Click to retry":d?"Waiting for response...":!e&&L?"Continue conversation...":"Ask me anything...",ue=R?A:d?"Waiting for response":C?"Click to connect":k?"Connecting...":Y?x?"Send message":"Cannot send message":"Enter a message to send",J=R?A:P?"Attach file (CV, document, or image)":"Cannot upload file",oe=W=>{W.preventDefault(),z&&(n(S),l(""),o.current&&(o.current.style.height="auto"))},q=W=>{W.key==="Enter"&&!W.shiftKey?(W.preventDefault(),oe(W)):W.key==="Escape"&&(W.preventDefault(),W.stopPropagation(),r())},K=W=>{var Z;const E=W.target,he=(Z=E.files)==null?void 0:Z[0];he&&s(he,"cv"),E.value=""};return g("div",{class:Qy({panelOpen:e}),role:"search","aria-label":"Chat with Kin AI",children:g("form",{onSubmit:oe,class:Ky({panelOpen:e}),autoComplete:"off",children:[D&&g("div",{class:"bg-n-3/75 corner-smooth shadow-n-4/50 rounded-b-kin-sm rounded-t-kin-2xl flex flex-wrap gap-1.5 p-2 shadow-inner","aria-label":"Suggested prompts",children:t.map((W,E)=>g("button",{type:"button",class:"fr bg-highest animate-kin-pop-in text-n-11 corner-smooth outline-n-4/50 hover:outline-n-7/50 hover:text-n-12 rounded-kin-xl inline-flex items-center whitespace-nowrap px-3 py-1.5 text-sm outline outline-1 transition-all hover:outline-2 active:scale-95",style:{animationDelay:`${.05+E*.05}s`},onPointerDown:he=>he.preventDefault(),onClick:()=>n(W.value),children:W.label},W.id))}),g("div",{class:"flex items-end gap-1 p-1 pl-3",children:[g("label",{for:"kin-input",class:"sr-only",children:"Ask Kin a question"}),g("textarea",{id:"kin-input",ref:o,rows:1,enterkeyhint:"send",class:"text-n-12 placeholder:text-n-9 -my-[0.125em] max-h-[6.5em] min-w-0 flex-1 resize-none self-center overflow-y-auto overscroll-none border-none bg-transparent px-0 py-[0.25em] text-base outline-none [mask-image:linear-gradient(to_bottom,transparent_0,_black_0.5em,_black_calc(100%-0.5em),transparent_100%)] disabled:cursor-not-allowed sm:text-sm",placeholder:Q,value:u,onInput:W=>{const E=W.target;l(E.value),E.style.height="auto",E.style.height=`${E.scrollHeight}px`},onFocus:i,onBlur:W=>a(W.relatedTarget),onKeyDown:q,"aria-describedby":"kin-input-status",autoComplete:"off",disabled:R}),g("input",{ref:h,type:"file",class:"sr-only",accept:Vy,onChange:K,"aria-hidden":"true",tabIndex:-1}),g(sh,{content:J,children:g("button",{type:"button",class:rr({variant:"ghost"}),disabled:!P,"aria-label":J,onPointerDown:W=>W.preventDefault(),onClick:()=>{var W;return(W=h.current)==null?void 0:W.click()},children:R?g(Kh,{class:"animate-kin-spin"}):g(Hl,{})})}),g("button",{type:"submit",class:rr({variant:"accent"}),disabled:!z,"aria-label":ue,onPointerDown:W=>W.preventDefault(),children:g(qh,{strokeWidth:2})})]}),g("div",{id:"kin-input-status",class:"sr-only",role:"status","aria-live":"polite",children:[k&&"Connecting to Kin...",v&&"Connection lost. Click input to retry.",d&&"Kin is responding...",R&&A]}),m&&f==="error"&&g("div",{class:`${el} max-w-[calc(100%-32px)] truncate`,role:"alert",children:m}),F&&g("div",{class:el,role:"alert",children:["Message too long (",u.length.toLocaleString(),"/",Ju.toLocaleString()," characters)"]})]})})}const Zy=.25,Jy=.4,e5=10,t5=5,Ra=240,tl=`transform ${Ra}ms var(--kin-fluid-ease)`,nl=()=>({pointerId:null,startX:0,startY:0,startTime:0,targetHeight:0,currentTranslateY:0,threshold:0,phase:"idle"});function Rr(e){e.style.removeProperty("transition"),e.style.removeProperty("transform"),e.style.removeProperty("will-change")}function n5(e,t){var r;if(!(e instanceof Element)||e.closest("button,input,textarea,select,a")||(r=window.getSelection())!=null&&r.toString())return!1;let n=e;for(;n&&n!==t;){const i=window.getComputedStyle(n);if((/(auto|scroll)/.test(i.overflowY)||/(auto|scroll)/.test(i.overflow))&&n.scrollHeight>n.clientHeight&&n.scrollTop>0)return!1;n=n.parentElement}return!0}function r5({enabled:e,onClose:t}){const n=ve(null),r=ve(nl()),i=ve(null),[a,s]=fe(!1),o=()=>{i.current&&(clearTimeout(i.current),i.current=null)},u=()=>{var k;const x=r.current.phase;r.current=nl(),x==="dragging"&&((k=n.current)==null||k.toggleAttribute("data-dragging",!1))},l=x=>{if(x===null)return;const k=n.current;k!=null&&k.hasPointerCapture(x)&&k.releasePointerCapture(x)},h=()=>{const x=n.current;x&&(x.style.transition=tl,x.style.transform="translate3d(0, 0, 0)",setTimeout(()=>{i.current||Rr(x)},Ra))},d=()=>{if(!e||i.current)return;const x=n.current;if(!x){t();return}s(!0),x.style.willChange="transform",x.style.transition=tl,x.style.transform=`translate3d(0, ${x.getBoundingClientRect().height}px, 0)`,i.current=setTimeout(()=>{i.current=null,t(),Rr(x),s(!1)},Ra)},p=x=>{if(!e||i.current||r.current.phase==="pending"||r.current.phase==="dragging"||x.pointerType==="mouse"&&x.button!==0)return;const k=n.current;!k||!n5(x.target,k)||(r.current={pointerId:x.pointerId,startX:x.clientX,startY:x.clientY,startTime:performance.now(),targetHeight:k.getBoundingClientRect().height,currentTranslateY:0,threshold:x.pointerType==="touch"||x.pointerType==="pen"?e5:t5,phase:"pending"})},f=x=>{const k=r.current;if(k.phase!=="pending"&&k.phase!=="dragging"||k.pointerId!==x.pointerId||i.current)return;const v=n.current;if(!v)return;const C=x.clientX-k.startX,R=x.clientY-k.startY;if(k.phase==="pending"){if(Math.abs(C)<k.threshold&&Math.abs(R)<k.threshold)return;if(Math.abs(R)<=Math.abs(C)||R<=0){k.phase="rejected";return}k.phase="dragging",v.toggleAttribute("data-dragging",!0),v.setPointerCapture(x.pointerId),v.style.willChange="transform",v.style.transition="none"}k.phase==="dragging"&&(k.currentTranslateY=Math.max(0,R),v.style.transform=`translate3d(0, ${k.currentTranslateY}px, 0)`,x.preventDefault())},m=x=>{const k=r.current;if(k.pointerId!==x.pointerId)return;l(k.pointerId);const v=k.phase==="dragging";u(),v&&h()},_=x=>{const k=r.current;if(k.pointerId!==x.pointerId)return;if(l(k.pointerId),k.phase!=="dragging"){u();return}const v=k.currentTranslateY,C=Math.max(1,performance.now()-k.startTime),R=v/C,F=v>=k.targetHeight*Zy||R>Jy;u(),F?d():h()};return Ce(()=>{if(e)return;o(),s(!1),u();const x=n.current;x&&Rr(x)},[e]),Ce(()=>()=>{o();const x=n.current;x&&(x.toggleAttribute("data-dragging",!1),Rr(x))},[]),{shellRef:n,isClosing:a,closeWithSlideOut:d,dragHandlers:{onPointerDown:p,onPointerMove:f,onPointerUp:_,onPointerCancel:m}}}const i5="(hover: none) and (pointer: coarse)",a5='button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex="-1"])';function rl(){var t;let e=document.activeElement;for(;(t=e==null?void 0:e.shadowRoot)!=null&&t.activeElement;)e=e.shadowRoot.activeElement;return e}const s5=Ft({base:"font-kin text-kin text-n-12 group flex w-full data-[placement=left]:sm:left-4 data-[placement=right]:sm:right-4 data-[placement=center]:sm:left-1/2 data-[placement=center]:sm:-translate-x-1/2",variants:{layout:{embedded:"relative h-full items-stretch",closed:"items-end",open:"top-[var(--kin-viewport-top)] h-[var(--kin-viewport-h)] overscroll-none items-stretch pt-safe-t [touch-action:manipulation] sm:top-auto sm:h-auto sm:items-end sm:pt-0 sm:[touch-action:auto]"}},compoundVariants:[{layout:["closed","open"],class:"fixed inset-x-0 bottom-0 z-[999999] sm:inset-x-auto sm:bottom-4 sm:w-auto"}]}),o5=Ft({base:"pointer-events-auto sm:w-[480px] rounded-t-kin-4xl flex w-full flex-col transition-all outline outline-1 outline-transparent duration-kin sm:rounded-kin-4xl corner-smooth ease-kin-fluid",variants:{layout:{embedded:"h-full rounded-none bg-n-1 outline-none sm:w-full sm:rounded-none",closed:"",open:"sm:min-h-[50vh] bg-n-1 h-full overflow-hidden sm:max-h-[min(90vh,var(--kin-viewport-h))] sm:outline-n-6/50 sm:shadow-2xl sm:shadow-n-6/30"}}}),u5=Ft({base:"fixed inset-0 z-[999998] bg-black/20 transition-opacity duration-kin ease-kin-fluid",variants:{visible:{false:"pointer-events-none opacity-0",true:"pointer-events-auto opacity-100"}}});function l5({starterPrompts:e,onSendMessage:t,onOpen:n,onClose:r,onConnect:i,onClearData:a,onUploadFile:s,placement:o="center"}){const u=o==="embedded",l=$.isOpen.value,h=u?"embedded":l?"open":"closed",d=h!=="closed",[p,f]=fe(!1),m=ve(null),_=ve(null),x=ve(null),k=$.messages.value.length>0,v=$.quickReplies.value,C=!d&&!k&&p&&e.length>0,R=d&&v.length>0,F=C?e.map((q,K)=>({id:`sp-${K}`,label:q.label,value:q.message})):R?v.map((q,K)=>({id:`qr-${K}`,label:q,value:q})):[];Ce(()=>{var q;if(d){const K=rl();_.current=K instanceof HTMLElement&&!((q=m.current)!=null&&q.contains(K))?K:null,requestAnimationFrame(()=>{var W;return(W=x.current)==null?void 0:W.focus()})}else f(!1)},[d]),Ce(()=>{u&&!l&&n()},[u,n,l]),Ce(()=>{if(h!=="open")return;const q=window.matchMedia(i5);if(!q.matches)return;const K=m.current,W=window.visualViewport;if(!K||!W)return;const E=()=>{K.style.setProperty("--kin-viewport-h",`${W.height}px`),K.style.setProperty("--kin-viewport-top",`${W.offsetTop}px`)};E(),W.addEventListener("resize",E),W.addEventListener("scroll",E);let he=0;const Z=ne=>{var Ue;he=((Ue=ne.touches[0])==null?void 0:Ue.clientY)??0},w=ne=>{var nt;const Ue=he-(((nt=ne.touches[0])==null?void 0:nt.clientY)??he),je=ne.composedPath(),me=je.indexOf(K);if(me<0)return;const st=rt=>rt instanceof Element&&(Ue>0?rt.scrollTop+rt.clientHeight<rt.scrollHeight-1:rt.scrollTop>0);je.slice(0,me).some(st)||ne.preventDefault()};document.addEventListener("touchstart",Z,{passive:!0}),document.addEventListener("touchmove",w,{passive:!1});const Se=()=>{W.removeEventListener("resize",E),W.removeEventListener("scroll",E),K.style.removeProperty("--kin-viewport-h"),K.style.removeProperty("--kin-viewport-top"),document.removeEventListener("touchstart",Z),document.removeEventListener("touchmove",w)},pe=ne=>{ne.matches||Se()};return q.addEventListener("change",pe),()=>{Se(),q.removeEventListener("change",pe)}},[h]),Ce(()=>{if(h!=="open")return;const q=K=>{if(K.key!=="Tab")return;const W=m.current;if(!W)return;const E=W.querySelectorAll(a5),he=E[0],Z=E[E.length-1];if(!he||!Z)return;const w=rl();K.shiftKey&&w===he?(K.preventDefault(),Z.focus()):!K.shiftKey&&w===Z&&(K.preventDefault(),he.focus())};return document.addEventListener("keydown",q),()=>document.removeEventListener("keydown",q)},[h]);const S=()=>{h==="closed"&&n()},Y=()=>{var q;(q=x.current)==null||q.blur(),r(),_.current&&requestAnimationFrame(()=>{var K;return(K=_.current)==null?void 0:K.focus()})},{shellRef:L,isClosing:D,closeWithSlideOut:A,dragHandlers:z}=r5({enabled:h==="open"&&!u,onClose:Y}),P=q=>{const K=q.trim();if(!K)return;const W=$.isStreaming.value,E=$.uploadState.value==="uploading"||$.uploadState.value==="processing",he=$.connectionState.value;!W&&!E&&(he==="connected"||he==="connecting")&&($.addMessage({role:"user",content:K}),S(),i(),t(K))},Q=()=>{f(!0),i(),!d&&k&&S()},ue=q=>{var K;q instanceof Node&&((K=m.current)!=null&&K.contains(q))||f(!1)},J=()=>{var q;d?A():(q=x.current)==null||q.blur()},oe=(q,K)=>{S(),s(q,K)};return g(xe,{children:[!u&&g("div",{class:u5({visible:h==="open"&&!D}),"aria-hidden":"true",onClick:A}),g("div",{ref:m,class:s5({layout:h}),"data-placement":o,role:"region","aria-label":"Kin AI Chat",children:g("div",{ref:L,class:o5({layout:h}),...z,children:[g("div",{class:"sr-only",role:"status","aria-live":"polite","aria-atomic":"true",children:d?"Chat panel opened":""}),d&&g(Yy,{embedded:u,onClose:A,onClearData:a,onSkipToInput:()=>{var q;return(q=x.current)==null?void 0:q.focus()}}),g(Xy,{panelOpen:d,suggestions:F,onSubmit:P,onEscape:J,onFocus:Q,onBlur:ue,onUploadFile:oe,inputRef:x})]})})]})}const c5=`*,: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-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--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-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--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}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{top:0;right:0;bottom:0;left:0}.inset-x-0{left:0;right:0}.-bottom-1\\.5{bottom:-.375rem}.-top-full{top:-100%}.bottom-0{bottom:0}.bottom-3{bottom:.75rem}.bottom-full{bottom:100%}.left-1\\/2{left:50%}.left-\\[--ax\\]{left:var(--ax)}.right-1\\.5{right:.375rem}.top-2{top:.5rem}.top-\\[var\\(--kin-viewport-top\\)\\]{top:var(--kin-viewport-top)}.z-\\[1000000\\]{z-index:1000000}.z-\\[999998\\]{z-index:999998}.z-\\[999999\\]{z-index:999999}.m-0{margin:0}.-my-\\[0\\.125em\\]{margin-top:-.125em;margin-bottom:-.125em}.mx-auto{margin-left:auto;margin-right:auto}.my-auto{margin-top:auto;margin-bottom:auto}.mb-2{margin-bottom:.5rem}.mb-4{margin-bottom:1rem}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.hidden{display:none}.size-10{width:2.5rem;height:2.5rem}.size-12{width:3rem;height:3rem}.size-3{width:.75rem;height:.75rem}.size-3\\.5{width:.875rem;height:.875rem}.size-8{width:2rem;height:2rem}.h-1{height:.25rem}.h-\\[var\\(--kin-viewport-h\\)\\]{height:var(--kin-viewport-h)}.h-full{height:100%}.max-h-\\[6\\.5em\\]{max-height:6.5em}.min-h-0{min-height:0px}.w-12{width:3rem}.w-4{width:1rem}.w-6{width:1.5rem}.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%}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.origin-\\[--origin\\]{transform-origin:var(--origin)}.-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))}.scale-90{--tw-scale-x: .9;--tw-scale-y: .9;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 .24s ease}@keyframes kin-fade{0%{opacity:0}to{opacity:1}}.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 .24s var(--kin-fluid-ease) both}@keyframes kin-pop{0%{opacity:0;scale:.9}to{opacity:1;scale:1}}.animate-kin-pop-in{animation:kin-pop .24s cubic-bezier(.34,1.56,.64,1) backwards}@keyframes kin-shimmer{0%{background-position:200% 50%}to{background-position:-200% 50%}}.animate-kin-shimmer{animation:kin-shimmer 2.5s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-kin-spin{animation:spin 1s linear infinite}.animate-none{animation:none}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize-none{resize:none}.resize{resize:both}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-end{align-items:flex-end}.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-4{gap:1rem}.self-start{align-self:flex-start}.self-end{align-self:flex-end}.self-center{align-self:center}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overscroll-none{overscroll-behavior:none}.scroll-smooth{scroll-behavior:smooth}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.break-words{overflow-wrap:break-word}.rounded{border-radius:.25rem}.rounded-full{border-radius:9999px}.rounded-kin-2xl{border-radius:var(--kin-r-2xl)}.rounded-kin-3xl{border-radius:var(--kin-r-3xl)}.rounded-kin-lg{border-radius:var(--kin-r-lg)}.rounded-kin-sm{border-radius:var(--kin-r-sm)}.rounded-kin-xl{border-radius:var(--kin-r-xl)}.rounded-none{border-radius:0}.rounded-b-kin-sm{border-bottom-right-radius:var(--kin-r-sm);border-bottom-left-radius:var(--kin-r-sm)}.rounded-t-kin-2xl{border-top-left-radius:var(--kin-r-2xl);border-top-right-radius:var(--kin-r-2xl)}.rounded-t-kin-4xl{border-top-left-radius:var(--kin-r-4xl);border-top-right-radius:var(--kin-r-4xl)}.border{border-width:1px}.border-b{border-bottom-width:1px}.border-none{border-style:none}.border-n-4{--tw-border-opacity: 1;border-color:oklch(var(--n-4) / var(--tw-border-opacity, 1))}.border-n-6\\/40{border-color:oklch(var(--n-6) / .4)}.border-transparent{border-color:transparent}.bg-a-9{--tw-bg-opacity: 1;background-color:oklch(var(--a-9) / var(--tw-bg-opacity, 1))}.bg-black\\/20{background-color:#0003}.bg-highest{--tw-bg-opacity: 1;background-color:oklch(var(--highest) / var(--tw-bg-opacity, 1))}.bg-n-1{--tw-bg-opacity: 1;background-color:oklch(var(--n-1) / var(--tw-bg-opacity, 1))}.bg-n-12{--tw-bg-opacity: 1;background-color:oklch(var(--n-12) / var(--tw-bg-opacity, 1))}.bg-n-2{--tw-bg-opacity: 1;background-color:oklch(var(--n-2) / var(--tw-bg-opacity, 1))}.bg-n-3{--tw-bg-opacity: 1;background-color:oklch(var(--n-3) / var(--tw-bg-opacity, 1))}.bg-n-3\\/75{background-color:oklch(var(--n-3) / .75)}.bg-n-5\\/50{background-color:oklch(var(--n-5) / .5)}.bg-red-600{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity, 1))}.bg-transparent{background-color:transparent}.bg-\\[linear-gradient\\(90deg\\,oklch\\(var\\(--n-9\\)\\)_40\\%\\,oklch\\(var\\(--n-11\\)\\)_50\\%\\,oklch\\(var\\(--n-9\\)\\)_60\\%\\)\\]{background-image:linear-gradient(90deg,oklch(var(--n-9)) 40%,oklch(var(--n-11)) 50%,oklch(var(--n-9)) 60%)}.bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))}.from-a-2\\/50{--tw-gradient-from: oklch(var(--a-2) / .5) var(--tw-gradient-from-position);--tw-gradient-to: rgb(255 255 255 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-transparent{--tw-gradient-from: transparent var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.to-n-2{--tw-gradient-to: oklch(var(--n-2) / 1) var(--tw-gradient-to-position)}.to-transparent{--tw-gradient-to: transparent var(--tw-gradient-to-position)}.bg-\\[length\\:200\\%_100\\%\\]{background-size:200% 100%}.bg-clip-text{-webkit-background-clip:text;background-clip:text}.fill-n-12{fill:oklch(var(--n-12) / 1)}.p-0\\.5{padding:.125rem}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-4{padding:1rem}.px-0{padding-left:0;padding-right:0}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\\.5{padding-left:.625rem;padding-right:.625rem}.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-5{padding-left:1.25rem;padding-right:1.25rem}.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-4{padding-top:1rem;padding-bottom:1rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.py-\\[0\\.25em\\]{padding-top:.25em;padding-bottom:.25em}.pb-2\\.5{padding-bottom:.625rem}.pb-safe-b{padding-bottom:max(.5rem,calc(env(safe-area-inset-bottom,0px) + .5rem))}.pl-3{padding-left:.75rem}.pl-safe-l{padding-left:max(1rem,env(safe-area-inset-left,1rem))}.pr-safe-r{padding-right:max(1rem,env(safe-area-inset-right,1rem))}.pt-1{padding-top:.25rem}.pt-safe-t{padding-top:max(1rem,env(safe-area-inset-top,1rem))}.text-center{text-align:center}.font-kin{font-family:var(--kin-font-family)}.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}.leading-relaxed{line-height:1.625}.text-inherit{color:inherit}.text-n-1{--tw-text-opacity: 1;color:oklch(var(--n-1) / var(--tw-text-opacity, 1))}.text-n-10{--tw-text-opacity: 1;color:oklch(var(--n-10) / var(--tw-text-opacity, 1))}.text-n-11{--tw-text-opacity: 1;color:oklch(var(--n-11) / var(--tw-text-opacity, 1))}.text-n-12{--tw-text-opacity: 1;color:oklch(var(--n-12) / var(--tw-text-opacity, 1))}.text-n-3{--tw-text-opacity: 1;color:oklch(var(--n-3) / var(--tw-text-opacity, 1))}.text-n-8{--tw-text-opacity: 1;color:oklch(var(--n-8) / var(--tw-text-opacity, 1))}.text-n-9{--tw-text-opacity: 1;color:oklch(var(--n-9) / var(--tw-text-opacity, 1))}.text-transparent{color:transparent}.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-100{opacity:1}.opacity-50{opacity:.5}.shadow-inner{--tw-shadow: inset 0 2px 4px 0 rgb(0 0 0 / .05);--tw-shadow-colored: inset 0 2px 4px 0 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-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -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)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px 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-a-9\\/10{--tw-shadow-color: oklch(var(--a-9) / .1);--tw-shadow: var(--tw-shadow-colored)}.shadow-n-4\\/30{--tw-shadow-color: oklch(var(--n-4) / .3);--tw-shadow: var(--tw-shadow-colored)}.shadow-n-4\\/50{--tw-shadow-color: oklch(var(--n-4) / .5);--tw-shadow: var(--tw-shadow-colored)}.outline-none{outline:2px solid transparent;outline-offset:2px}.outline{outline-style:solid}.outline-1{outline-width:1px}.outline-2{outline-width:2px}.outline-a-9{outline-color:oklch(var(--a-9) / 1)}.outline-n-4\\/50{outline-color:oklch(var(--n-4) / .5)}.outline-transparent{outline-color: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{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\\[opacity\\,transform\\]{transition-property:opacity,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-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-kin{transition-duration:.24s}.ease-kin-fluid{transition-timing-function:var(--kin-fluid-ease)}.ease-out-back{transition-timing-function:cubic-bezier(.34,1.56,.64,1)}.fr:focus-visible{outline:2px solid oklch(var(--a-9) / .5);outline-offset:2px}.corner-smooth{corner-shape:superellipse(1.25)}.\\[mask-image\\:linear-gradient\\(to_bottom\\,transparent_0\\,_black_0\\.5em\\,_black_calc\\(100\\%-0\\.5em\\)\\,transparent_100\\%\\)\\]{-webkit-mask-image:linear-gradient(to bottom,transparent 0,black .5em,black calc(100% - .5em),transparent 100%);mask-image:linear-gradient(to bottom,transparent 0,black .5em,black calc(100% - .5em),transparent 100%)}.\\[mask-image\\:linear-gradient\\(to_bottom\\,transparent_0\\,_black_1\\.5rem\\,_black_calc\\(100\\%-1\\.5rem\\)\\,transparent_100\\%\\)\\]{-webkit-mask-image:linear-gradient(to bottom,transparent 0,black 1.5rem,black calc(100% - 1.5rem),transparent 100%);mask-image:linear-gradient(to bottom,transparent 0,black 1.5rem,black calc(100% - 1.5rem),transparent 100%)}.\\[touch-action\\:manipulation\\]{touch-action:manipulation}.\\[will-change\\:transform\\,opacity\\]{will-change:transform,opacity}:host{--a-1: 99.4% .003 22.8;--a-2: 98.4% .007 31;--a-3: 95.4% .022 30.9;--a-4: 92.6% .047 31.8;--a-5: 89.2% .063 31.5;--a-6: 85.2% .077 32;--a-7: 80.3% .094 32.2;--a-8: 74.1% .118 32.1;--a-9: 62.7% .194 33.3;--a-10: 60.4% .195 33.3;--a-11: 56.7% .198 32.8;--a-12: 34.6% .08 30.5;--n-1: 99.1% 0 0;--n-2: 98.1% 0 0;--n-3: 95.3% 0 0;--n-4: 93% 0 0;--n-5: 90.8% 0 0;--n-6: 88.4% 0 0;--n-7: 85.1% 0 0;--n-8: 79.1% 0 0;--n-9: 64.3% 0 0;--n-10: 60.9% 0 0;--n-11: 50.3% 0 0;--n-12: 24.3% 0 0;--kin-viewport-h: 100dvh;--kin-viewport-top: 0px;--kin-fluid-ease: cubic-bezier(.32, .72, 0, 1);--kin-font-family: inherit}.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:var(--kin-r-xs);font-family:SF Mono,Monaco,Consolas,monospace;font-size:.875em}.kin-markdown pre{background:rgba(0,0,0,.4);padding:14px 16px;border-radius:var(--kin-r-sm);overflow-x:auto;margin:1em 0;border:1px solid oklch(var(--n-6) / .4)}.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:oklch(var(--n-9))}.kin-markdown :is(ul,ol) :is(ul,ol){margin:.25em 0}.kin-markdown blockquote{border-left:3px solid oklch(var(--a-9));margin:1em 0;padding:.5em 0 .5em 1em;color:oklch(var(--n-11));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 oklch(var(--n-6) / .4);text-align:left}.kin-markdown th{background:oklch(var(--n-4));font-weight:600}.kin-markdown hr{border:none;border-top:1px solid oklch(var(--n-6) / .4);margin:1.5em 0}.kin-markdown hr+p{display:flex;flex-wrap:wrap;align-items:center;gap:5px;font-size:.75em;color:oklch(var(--n-9));margin:-1em 0 0;line-height:1.6}.kin-markdown input[type=checkbox]{margin-right:.5em;accent-color:oklch(var(--a-9))}.kin-markdown .streamdown-caret{display:inline-block;width:2px;height:1em;background:oklch(var(--a-9));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}}[data-dragging],[data-dragging] *{touch-action:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;cursor:grabbing}.placeholder\\:text-n-9::-moz-placeholder{--tw-text-opacity: 1;color:oklch(var(--n-9) / var(--tw-text-opacity, 1))}.placeholder\\:text-n-9::placeholder{--tw-text-opacity: 1;color:oklch(var(--n-9) / var(--tw-text-opacity, 1))}.focus-within\\:border-a-6\\/50:focus-within{border-color:oklch(var(--a-6) / .5)}.focus-within\\:pb-2:focus-within{padding-bottom:.5rem}.focus-within\\:outline-\\[3px\\]:focus-within{outline-width:3px}.focus-within\\:outline-a-4\\/50:focus-within{outline-color:oklch(var(--a-4) / .5)}.hover\\:bg-a-10:hover{--tw-bg-opacity: 1;background-color:oklch(var(--a-10) / var(--tw-bg-opacity, 1))}.hover\\:bg-n-3:hover{--tw-bg-opacity: 1;background-color:oklch(var(--n-3) / var(--tw-bg-opacity, 1))}.hover\\:bg-n-4:hover{--tw-bg-opacity: 1;background-color:oklch(var(--n-4) / var(--tw-bg-opacity, 1))}.hover\\:text-a-9:hover{--tw-text-opacity: 1;color:oklch(var(--a-9) / var(--tw-text-opacity, 1))}.hover\\:text-n-11:hover{--tw-text-opacity: 1;color:oklch(var(--n-11) / var(--tw-text-opacity, 1))}.hover\\:text-n-12:hover{--tw-text-opacity: 1;color:oklch(var(--n-12) / var(--tw-text-opacity, 1))}.hover\\:underline-offset-4:hover{text-underline-offset:4px}.hover\\:outline-2:hover{outline-width:2px}.hover\\:outline-n-7\\/50:hover{outline-color:oklch(var(--n-7) / .5)}.focus\\:top-2:focus{top:.5rem}.focus-visible\\:rounded-kin-xs:focus-visible{border-radius:var(--kin-r-xs)}.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))}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:text-n-6:disabled{--tw-text-opacity: 1;color:oklch(var(--n-6) / var(--tw-text-opacity, 1))}.disabled\\:opacity-50:disabled{opacity:.5}.data-\\[open\\]\\:scale-100[data-open]{--tw-scale-x: 1;--tw-scale-y: 1;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))}.data-\\[open\\]\\:opacity-100[data-open]{opacity:1}.data-\\[open\\]\\:delay-300[data-open]{transition-delay:.3s}.group[data-side=bottom] .group-data-\\[side\\=bottom\\]\\:-top-6{top:-1.5rem}.group[data-side=top] .group-data-\\[side\\=top\\]\\:-bottom-6{bottom:-1.5rem}.group[data-side=top] .group-data-\\[side\\=top\\]\\:rotate-180{--tw-rotate: 180deg;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))}.group[data-placement=embedded] .group-data-\\[placement\\=embedded\\]\\:pb-2{padding-bottom:.5rem}@media (min-width: 640px){.sm\\:inset-x-auto{left:auto;right:auto}.sm\\:bottom-4{bottom:1rem}.sm\\:top-auto{top:auto}.sm\\:size-7{width:1.75rem;height:1.75rem}.sm\\:size-8{width:2rem;height:2rem}.sm\\:h-auto{height:auto}.sm\\:max-h-\\[min\\(90vh\\,var\\(--kin-viewport-h\\)\\)\\]{max-height:min(90vh,var(--kin-viewport-h))}.sm\\:min-h-\\[50vh\\]{min-height:50vh}.sm\\:w-\\[480px\\]{width:480px}.sm\\:w-auto{width:auto}.sm\\:w-full{width:100%}@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 var(--kin-fluid-ease) both}.sm\\:items-end{align-items:flex-end}.sm\\:overscroll-auto{overscroll-behavior:auto}.sm\\:rounded-kin-4xl{border-radius:var(--kin-r-4xl)}.sm\\:rounded-kin-xl{border-radius:var(--kin-r-xl)}.sm\\:rounded-none{border-radius:0}.sm\\:p-3{padding:.75rem}.sm\\:px-14{padding-left:3.5rem;padding-right:3.5rem}.sm\\:px-4{padding-left:1rem;padding-right:1rem}.sm\\:pl-5{padding-left:1.25rem}.sm\\:pt-0{padding-top:0}.sm\\:text-sm{font-size:.875rem;line-height:1.25rem}.sm\\:font-medium{font-weight:500}.sm\\:shadow-2xl{--tw-shadow: 0 25px 50px -12px rgb(0 0 0 / .25);--tw-shadow-colored: 0 25px 50px -12px 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-n-6\\/30{--tw-shadow-color: oklch(var(--n-6) / .3);--tw-shadow: var(--tw-shadow-colored)}.sm\\:outline-n-6\\/50{outline-color:oklch(var(--n-6) / .5)}.sm\\:\\[touch-action\\:auto\\]{touch-action:auto}.data-\\[placement\\=center\\]\\:sm\\:left-1\\/2[data-placement=center]{left:50%}.data-\\[placement\\=left\\]\\:sm\\:left-4[data-placement=left]{left:1rem}.data-\\[placement\\=right\\]\\:sm\\:right-4[data-placement=right]{right:1rem}.data-\\[placement\\=center\\]\\:sm\\:-translate-x-1\\/2[data-placement=center]{--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))}.group[data-placement=left] .group-data-\\[placement\\=left\\]\\:sm\\:pl-2{padding-left:.5rem}.group[data-placement=left] .group-data-\\[placement\\=left\\]\\:sm\\:pr-24{padding-right:6rem}.group[data-placement=right] .group-data-\\[placement\\=right\\]\\:sm\\:pl-24{padding-left:6rem}.group[data-placement=right] .group-data-\\[placement\\=right\\]\\:sm\\:pr-2{padding-right:.5rem}}.\\[\\&\\:\\:-webkit-scrollbar-thumb\\]\\:rounded-kin-xs::-webkit-scrollbar-thumb{border-radius:var(--kin-r-xs)}.\\[\\&\\:\\:-webkit-scrollbar-thumb\\]\\:bg-n-4::-webkit-scrollbar-thumb{--tw-bg-opacity: 1;background-color:oklch(var(--n-4) / var(--tw-bg-opacity, 1))}.\\[\\&\\:\\:-webkit-scrollbar-track\\]\\:bg-transparent::-webkit-scrollbar-track{background-color:transparent}.\\[\\&\\:\\:-webkit-scrollbar\\]\\:w-1\\.5::-webkit-scrollbar{width:.375rem}.\\[\\&\\>\\:first-child\\]\\:mt-auto>:first-child{margin-top:auto}.\\[\\&_svg\\]\\:size-3\\.5 svg{width:.875rem;height:.875rem}.\\[\\&_svg\\]\\:size-4 svg{width:1rem;height:1rem}
|
|
121
|
-
`,oh=["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"],uh={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]]},lh={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]]},ea=e=>(e/=255,e<=.04045?e/12.92:((e+.055)/1.055)**2.4),d5=(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),l=.2104542553*s+.793617785*o-.0040720468*u,h=1.9779984951*s-2.428592205*o+.4505937099*u,d=.0259040371*s+.7827717662*o-.808675766*u;return[l,h,d]},ch=([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]},ai=([e,t,n])=>{const r=(n??0)*Math.PI/180;return[e,t*Math.cos(r),t*Math.sin(r)]},h5=e=>{const t=e.replace("#",""),n=parseInt(t.length===3?t.replace(/./g,s=>s+s):t,16),r=ea(n>>16&255),i=ea(n>>8&255),a=ea(n&255);return ch(d5(r,i,a))},zn=(e,t)=>{const[n,r,i]=ai(e),[a,s,o]=ai(t);return Math.hypot(n-a,r-s,i-o)},f5=(e,t,n)=>{const r=ai(e),i=ai(t),a=[r[0]+(i[0]-r[0])*n,r[1]+(i[1]-r[1])*n,r[2]+(i[2]-r[2])*n];return ch(a)},p5=([e,t,n])=>`oklch(${(e*100).toFixed(1)}% ${+t.toFixed(3)} ${+(n??0).toFixed(2)})`,dh=["1","2","3","4","5","6","7","8","9","10","11","12"],vs=["gray","mauve","slate","sage","olive","sand"];function vi(e,t){return Object.fromEntries(t.map(n=>[n,e[n]]))}const m5=vi(lh,oh),g5=vi(uh,oh),b5=vi(lh,vs),E5=vi(uh,vs),il=({prefix:e,appearance:t,color:n,isNeutral:r=!1})=>{if(!/^#?[0-9A-Fa-f]{6}$/.test(n))throw new Error("Color must be a valid 6-digit hex");const i=t==="light"?m5:g5,a=t==="light"?b5:E5,s=h5(n),o=r?al(s,a):al(s,i);if(!r){o[8]=s,o[9]=T5(s,[o]);const u=Math.max(o[8][1],o[7][1]);o[10][1]=Math.min(u,o[10][1]),o[11][1]=Math.min(u,o[11][1])}return Object.fromEntries(dh.map((u,l)=>[`${e}${u}`,p5(o[l])]))};function T5(e,t){const[n,r,i]=e,a=n>.4?n-.03/(n+.1):n+.03/(n+.1),s=n>.4&&i!==null?r*.93:r,o=[a,s,i];let u=o,l=1/0;for(const h of t)for(const d of h){const p=zn(o,d);p<l&&(l=p,u=d)}return[a,u[1],u[2]]}function al(e,t){const n=[];for(const[C,R]of Object.entries(t))for(const F of R)n.push({scale:C,color:F,distance:zn(e,F)});n.sort((C,R)=>C.distance-R.distance);const r=n.filter((C,R,F)=>R===F.findIndex(S=>S.scale===C.scale)),i=new Set(vs);if(!r.every(C=>i.has(C.scale))&&i.has(r[0].scale))for(;r.length>1&&i.has(r[1].scale);)r.splice(1,1);const[s,o]=[r[0],r[1]],u=o.distance,l=s.distance,h=zn(s.color,o.color),d=(l**2+h**2-u**2)/(2*l*h),p=(u**2+h**2-l**2)/(2*u*h),f=Math.max(0,d/Math.sqrt(1-d**2)/(p/Math.sqrt(1-p**2)))*.5,m=t[s.scale],_=t[o.scale],x=dh.map((C,R)=>f5(m[R],_[R],f)),k=x.slice().sort((C,R)=>zn(e,C)-zn(e,R))[0],v=e[1]/(k[1]||1e-6);for(const C of x)C[1]=Math.min(e[1]*1.5,C[1]*v),C[2]=e[2];return x}const _5=e=>e.slice(6,-1),sl=e=>Object.entries(e).map(([t,n])=>`--${t}: ${_5(n)};`);function k5(e){const t=il({prefix:"a-",appearance:e.mode,color:e.accentColor}),n=il({prefix:"n-",appearance:e.mode,color:e.neutralColor??"#555555",isNeutral:!0}),r=`--highest: ${e.mode==="light"?"100% 0 0":"10% 0 0"};`;return[...sl(t),...sl(n),r].join(`
|
|
122
|
-
`)}const
|
|
123
|
-
`)}const
|
|
120
|
+
`);return s+l+u})}return n},Ly=/^[ \t]*<[\w!/?-]/,Ry=/(^|\n)[ \t]{4,}(?=<[\w!/?-])/g,Oy=e=>typeof e!="string"||e.length===0||!Ly.test(e)?e:e.replace(Ry,"$1"),Zu,Ju,Ur={...Zn,protocols:{...Zn.protocols,href:[...(Ju=(Zu=Zn.protocols)==null?void 0:Zu.href)!=null?Ju:[],"tel"]}},Oa={raw:ga,sanitize:[Qc,Ur],harden:[Rf,{allowedImagePrefixes:["*"],allowedLinkPrefixes:["*"],allowedProtocols:["*"],defaultOrigin:void 0,allowDataImages:!0}]},Dy={gfm:[KE,{}]},el=Object.values(Oa),Py=Object.values(Dy),My={block:" ▋",circle:" ●"},By={shikiTheme:["github-light","github-dark"],controls:!0,isAnimating:!1,mode:"streaming",mermaid:void 0,linkSafety:{enabled:!0}},et=ui(By),nh=Ee(({content:e,shouldParseIncompleteMarkdown:t,shouldNormalizeHtmlIndentation:n,index:r,isIncomplete:i,...a})=>{let s=typeof e=="string"&&n?Oy(e):e;return g(y0.Provider,{value:i,children:g(th,{...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)});nh.displayName="Block";var Fy=["github-light","github-dark"],rh=Ee(({children:e,mode:t="streaming",parseIncompleteMarkdown:n=!0,normalizeHtmlIndentation:r=!1,components:i,rehypePlugins:a=el,remarkPlugins:s=Py,className:o,shikiTheme:u=Fy,mermaid:l,controls:h=!0,isAnimating:d=!1,animated:p,BlockComponent:f=nh,parseMarkdownIntoBlocksFn:m=Iy,caret:_,plugins:x,remend:k,linkSafety:v={enabled:!0},allowedTags:C,...R})=>{let F=Lh(),[S,Y]=Af(),L=Ne(()=>C?Object.keys(C):[],[C]),O=Ne(()=>{if(typeof e!="string")return"";let Z=t==="streaming"&&n?rT(e,k):e;return L.length>0&&(Z=Ny(Z,L)),Z},[e,t,n,k,L]),A=Ne(()=>m(O),[O,m]),[z,M]=fe(A);Ce(()=>{t==="streaming"?Y(()=>{M(A)}):M(A)},[A,t]);let Q=t==="streaming"?z:A,ue=Ne(()=>Q.map((Z,w)=>`${F}-${w}`),[Q.length,F]),J=Ne(()=>p?p===!0?Ia():Ia(p):null,[p]),oe=Ne(()=>{var Z,w;return{shikiTheme:(w=(Z=x==null?void 0:x.code)==null?void 0:Z.getThemes())!=null?w:u,controls:h,isAnimating:d,mode:t,mermaid:l,linkSafety:v}},[u,h,d,t,l,v,x==null?void 0:x.code]),q=Ne(()=>({...uy,...i}),[i]),K=Ne(()=>{let Z=[];return x!=null&&x.cjk&&(Z=[...Z,...x.cjk.remarkPluginsBefore]),Z=[...Z,...s],x!=null&&x.cjk&&(Z=[...Z,...x.cjk.remarkPluginsAfter]),x!=null&&x.math&&(Z=[...Z,x.math.remarkPlugin]),Z},[s,x==null?void 0:x.math,x==null?void 0:x.cjk]),W=Ne(()=>{var Z;let w=a;if(C&&Object.keys(C).length>0&&a===el){let Se={...Ur,tagNames:[...(Z=Ur.tagNames)!=null?Z:[],...Object.keys(C)],attributes:{...Ur.attributes,...C}};w=[Oa.raw,[Qc,Se],Oa.harden]}return x!=null&&x.math&&(w=[...w,x.math.rehypePlugin]),J&&d&&(w=[...w,J.rehypePlugin]),w},[a,x==null?void 0:x.math,J,d,C]),E=Ne(()=>{if(!d||Q.length===0)return!1;let Z=Q.at(-1);return ju(Z)||dy(Z)},[d,Q]),he=Ne(()=>_&&d&&!E?{"--streamdown-caret":`"${My[_]}"`}:void 0,[_,d,E]);return t==="static"?g(Na.Provider,{value:x??null,children:g(et.Provider,{value:oe,children:g("div",{className:ee("space-y-4 whitespace-normal *:first:mt-0 *:last:mb-0",o),children:g(th,{components:q,rehypePlugins:W,remarkPlugins:K,...R,children:O})})})}):g(Na.Provider,{value:x??null,children:g(et.Provider,{value:oe,children:g("div",{className:ee("space-y-4 whitespace-normal *:first:mt-0 *:last:mb-0",_&&!E?"*:last:after:inline *:last:after:align-baseline *:last:after:content-[var(--streamdown-caret)]":null,o),style:he,children:[Q.length===0&&_&&d&&g("span",{}),Q.map((Z,w)=>{let Se=w===Q.length-1,me=d&&Se&&ju(Z);return g(f,{components:q,content:Z,index:w,isIncomplete:me,rehypePlugins:W,remarkPlugins:K,shouldNormalizeHtmlIndentation:r,shouldParseIncompleteMarkdown:n,...R},ue[w])})]})})})},(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);rh.displayName="Streamdown";var Hy=({children:e,className:t,minZoom:n=.5,maxZoom:r=3,zoomStep:i=.1,showControls:a=!0,initialZoom:s=1,fullscreen:o=!1})=>{let u=ve(null),l=ve(null),[h,d]=fe(s),[p,f]=fe({x:0,y:0}),[m,_]=fe(!1),[x,k]=fe({x:0,y:0}),[v,C]=fe({x:0,y:0}),R=$e(M=>{d(Q=>Math.max(n,Math.min(r,Q+M)))},[n,r]),F=$e(()=>{R(i)},[R,i]),S=$e(()=>{R(-i)},[R,i]),Y=$e(()=>{d(s),f({x:0,y:0})},[s]),L=$e(M=>{M.preventDefault();let Q=M.deltaY>0?-i:i;R(Q)},[R,i]),O=$e(M=>{if(M.button!==0||M.isPrimary===!1)return;_(!0),k({x:M.clientX,y:M.clientY}),C(p);let Q=M.currentTarget;Q instanceof HTMLElement&&Q.setPointerCapture(M.pointerId)},[p]),A=$e(M=>{if(!m)return;M.preventDefault();let Q=M.clientX-x.x,ue=M.clientY-x.y;f({x:v.x+Q,y:v.y+ue})},[m,x,v]),z=$e(M=>{_(!1);let Q=M.currentTarget;Q instanceof HTMLElement&&Q.releasePointerCapture(M.pointerId)},[]);return Ce(()=>{let M=u.current;if(M)return M.addEventListener("wheel",L,{passive:!1}),()=>{M.removeEventListener("wheel",L)}},[L]),Ce(()=>{let M=l.current;if(M&&m)return document.body.style.userSelect="none",M.addEventListener("pointermove",A,{passive:!1}),M.addEventListener("pointerup",z),M.addEventListener("pointercancel",z),()=>{document.body.style.userSelect="",M.removeEventListener("pointermove",A),M.removeEventListener("pointerup",z),M.removeEventListener("pointercancel",z)}},[m,A,z]),g("div",{className:ee("relative flex flex-col",o?"h-full w-full":"min-h-28 w-full",t),ref:u,style:{cursor:m?"grabbing":"grab"},children:[a?g("div",{className:ee("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:[g("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:h>=r,onClick:F,title:"Zoom in",type:"button",children:g(Hx,{size:16})}),g("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:h<=n,onClick:S,title:"Zoom out",type:"button",children:g(Ux,{size:16})}),g("button",{className:"flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",onClick:Y,title:"Reset zoom and pan",type:"button",children:g(Fx,{size:16})})]}):null,g("div",{className:ee("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:O,ref:l,role:"application",style:{transform:`translate(${p.x}px, ${p.y}px) scale(${h})`,transformOrigin:"center center",touchAction:"none",willChange:"transform"},children:e})]})},ih=({chart:e,className:t,config:n,fullscreen:r=!1,showControls:i=!0})=>{let[a,s]=fe(null),[o,u]=fe(!1),[l,h]=fe(""),[d,p]=fe(""),[f,m]=fe(0),{mermaid:_}=Ge(et),x=vs(),k=_==null?void 0:_.errorComponent,{shouldRender:v,containerRef:C}=Tx({immediate:r});if(Ce(()=>{if(v){if(!x){s("Mermaid plugin not available. Please add the mermaid plugin to enable diagram rendering.");return}(async()=>{try{s(null),u(!0);let F=x.getMermaid(n),S=e.split("").reduce((O,A)=>(O<<5)-O+A.charCodeAt(0)|0,0),Y=`mermaid-${Math.abs(S)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:L}=await F.render(Y,e);h(L),p(L)}catch(F){if(!(d||l)){let S=F instanceof Error?F.message:"Failed to render Mermaid chart";s(S)}}finally{u(!1)}})()}},[e,n,f,v,x]),!(v||l||d))return g("div",{className:ee("my-4 min-h-[200px]",t),ref:C});if(o&&!l&&!d)return g("div",{className:ee("my-4 flex justify-center p-4",t),ref:C,children:g("div",{className:"flex items-center space-x-2 text-muted-foreground",children:[g("div",{className:"h-4 w-4 animate-spin rounded-full border-current border-b-2"}),g("span",{className:"text-sm",children:"Loading diagram..."})]})});if(a&&!l&&!d)return k?g("div",{ref:C,children:g(k,{chart:e,error:a,retry:()=>m(S=>S+1)})}):g("div",{className:ee("rounded-md bg-red-50 p-4",t),ref:C,children:[g("p",{className:"font-mono text-red-700 text-sm",children:["Mermaid Error: ",a]}),g("details",{className:"mt-2",children:[g("summary",{className:"cursor-pointer text-red-600 text-xs",children:"Show Code"}),g("pre",{className:"mt-2 overflow-x-auto rounded bg-red-100 p-2 text-red-800 text-xs",children:e})]})]});let R=l||d;return g("div",{className:ee("size-full",t),"data-streamdown":"mermaid",ref:C,children:g(Hy,{className:ee(r?"size-full overflow-hidden":"overflow-hidden",t),fullscreen:r,maxZoom:3,minZoom:.5,showControls:i,zoomStep:.1,children:g("div",{"aria-label":"Mermaid chart",className:ee("flex justify-center",r?"size-full items-center":null),dangerouslySetInnerHTML:{__html:R},role:"img"})})})};function Uy({href:e,children:t}){return g("a",{href:e,target:"_blank",rel:"noopener noreferrer",class:"fr hover:text-a-9 focus-visible:rounded-kin-xs text-inherit underline underline-offset-2 transition-all hover:underline-offset-4",children:t})}const zy={a:Uy};function ah({content:e,isStreaming:t=!1}){return e?g(rh,{className:"kin-markdown text-n-12 text-sm leading-relaxed",isAnimating:t,mode:t?"streaming":"static",components:zy,children:e}):null}const $y={thinking:{label:"Thinking…",icon:Gs},responding:{label:"Writing response…",icon:Xs},processing_results:{label:"Processing results…",icon:Gs},processing_cv:{label:"Scanning your CV…",icon:Ks},searchJobs:{label:"Searching jobs…",icon:Qs},matchJobs:{label:"Matching jobs…",icon:Qs},searchKnowledge:{label:"Searching company info…",icon:ef},getProfileSummary:{label:"Reviewing your profile…",icon:Ks},updatePreferences:{label:"Updating your preferences…",icon:tf},remember:{label:"Saving details…",icon:nf},suggestQuickReplies:{label:"Preparing reply options…",icon:Xs}},sh=Ft({base:"animate-kin-message-in flex max-w-[95%] flex-col",variants:{side:{user:"self-end",assistant:"self-start gap-2.5 p-1"}}});function Yy(){const e=ve(null);return g("div",{ref:e,class:"pl-safe-l pr-safe-r [&::-webkit-scrollbar-thumb]:bg-n-4 [&::-webkit-scrollbar-thumb]:rounded-kin-xs flex min-h-0 flex-1 flex-col gap-4 overflow-y-auto overscroll-none scroll-smooth break-words py-4 [mask-image:linear-gradient(to_bottom,transparent_0,_black_1.5rem,_black_calc(100%-1.5rem),transparent_100%)] sm:overscroll-auto sm:px-4 [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar]:w-1.5 [&>:first-child]:mt-auto",role:"log","aria-label":"Chat messages","aria-live":"polite","aria-relevant":"additions",children:[g(Vy,{}),g(qy,{}),g(Wy,{}),g(jy,{containerRef:e})]})}function jy({containerRef:e}){var h,d;const[t,n]=fe(!0),r=ve(!1),i=$.messages.value.length,a=((h=$.messages.value.at(-1))==null?void 0:h.role)==="user",s=(d=$.liveAssistantMessage.value)==null?void 0:d.content,o=$.assistantStatus.value,u=$.quickReplies.value.length,l=()=>{const p=e.current;p&&(r.current=!0,p.scrollTop=p.scrollHeight,n(!0))};return Ce(()=>{const p=e.current;if(!p)return;l();const f=()=>{const m=p.scrollHeight-p.scrollTop-p.clientHeight<80;r.current?r.current=!m:n(m)};return p.addEventListener("scroll",f,{passive:!0}),()=>p.removeEventListener("scroll",f)},[]),Ce(()=>{(t||a)&&l()},[i,s,o,u,a]),t?null:g("button",{type:"button",class:bn({variant:"neutral",size:"iconSm",class:"absolute bottom-3 left-1/2 -translate-x-1/2"}),"aria-label":"Scroll to latest message",onClick:l,children:g(rf,{strokeWidth:2})})}function Vy(){const e=$.messages.value.length,t=!!($.liveAssistantMessage.value||$.isStreaming.value||$.assistantStatus.value);return e||t?null:g("div",{class:"animate-kin-fade-in my-auto px-6 py-6 text-center",style:{animationDelay:"150ms"},children:[g("div",{class:"text-n-9 mx-auto mb-4 size-12 opacity-50","aria-hidden":"true",children:g(Gh,{class:"h-full w-full"})}),g("p",{class:"text-n-12 mb-2 text-base",children:"Hi there, you're speaking with Kin AI Agent."}),g("p",{class:"text-n-9 text-sm",children:"How can I help you today?"})]})}function qy(){return g(pe,{children:$.messages.value.filter(e=>{var t;return e.role==="assistant"?!!e.content.trim()||!!((t=e.blocks)!=null&&t.length):e.role==="user"?!!e.content.trim()||!!e.attachment:!0}).map((e,t)=>g(Gy,{message:e,animationIndex:t},e.id))})}function oh({statusMeta:e,timestamp:t}){const n=e==null?void 0:e.icon;return g("div",{class:"text-n-9 border-n-4 inline-flex items-center gap-1.5 border-t pt-1.5 text-xs first:border-t-0 first:pt-0","aria-hidden":"true",children:n?g(pe,{children:[g(n,{class:"size-3 shrink-0 animate-pulse"}),g("span",{class:"animate-kin-shimmer bg-[linear-gradient(90deg,oklch(var(--n-9))_40%,oklch(var(--n-11))_50%,oklch(var(--n-9))_60%)] bg-[length:200%_100%] bg-clip-text text-transparent",children:e.label})]}):g("span",{children:["Kin • AI Agent • ",t?Ky(t):"typing..."]})})}function Wy(){const e=$.liveAssistantMessage.value,t=$.isStreaming.value,n=$.assistantStatus.value,r=n?$y[n]:void 0;return!e&&!t&&!r?null:g("article",{class:sh({side:"assistant"}),"aria-label":"Message from Kin AI Agent",children:[(e==null?void 0:e.content)&&g(ah,{content:e.content,isStreaming:t}),g(oh,{statusMeta:r,timestamp:t||e==null?void 0:e.timestamp})]})}function Gy({message:e,animationIndex:t}){const{role:n,content:r,timestamp:i,attachment:a,blocks:s}=e,o=n==="user",u=Math.min((t+1)*.05,.35);return n==="system"?g("div",{class:"flex justify-center px-4 py-2",role:"status","aria-label":"System notification",children:g("span",{class:"border-n-6/40 bg-n-3 text-n-9 corner-smooth rounded-kin-lg border px-3 py-1.5 text-xs",children:r})}):g("article",{class:sh({side:o?"user":"assistant"}),style:{animationDelay:`${u}s`},"aria-label":`Message from ${o?"You":"Kin AI Agent"}`,children:[o&&g("div",{class:"bg-n-3 text-n-12 corner-smooth rounded-kin-lg relative px-3.5 py-2 text-sm",children:[a&&g("div",{class:"text-n-10 flex items-center gap-1.5",children:[g(zl,{class:"text-n-9 size-3.5 shrink-0"}),g("span",{class:"max-w-full truncate",children:a.name})]}),g("p",{children:r}),g("svg",{class:"text-n-3 absolute -bottom-1.5 right-1.5 w-4","aria-hidden":"true",viewBox:"0 0 16 8",children:g("path",{d:"M15 0S16 3 16 7C16 8 15 7 15 7 11 3 9 2 0 2Z",fill:"currentColor"})})]}),!o&&r&&g(ah,{content:r}),!o&&(s==null?void 0:s.map((l,h)=>g(Qy,{block:l},h))),!o&&g(oh,{timestamp:i})]})}function Qy({block:e}){switch(e.kind){case"job_cards":return g(lf,{jobs:e.jobs});default:return null}}function Ky(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"})}function uh({content:e,children:t}){var l;const[n,r]=fe(!1),i=ve(null),a=ve(null),s=t.props,o=xl(t,{ref:i,onMouseEnter:Lr(s.onMouseEnter,()=>r(!0)),onMouseLeave:Lr(s.onMouseLeave,()=>r(!1)),onFocus:Lr(s.onFocus,()=>r(!0)),onBlur:Lr(s.onBlur,()=>r(!1))});Ce(()=>{if(!n)return;const h=d=>{i.current&&!d.composedPath().includes(i.current)&&r(!1)};return document.addEventListener("pointerdown",h),()=>document.removeEventListener("pointerdown",h)},[n]),Nh(()=>{const h=i.current,d=a.current;if(!n||!h||!d)return;const p=h.getBoundingClientRect(),f=d.offsetWidth,m=d.offsetHeight,_=p.top>m+8,x=Math.max(4,Math.min(p.left+(p.width-f)/2,innerWidth-f-4)),k=p.left+p.width/2-x;d.setAttribute("data-side",_?"top":"bottom"),d.style.left=`${x}px`,d.style.top=`${_?p.top-m-6:p.bottom+6}px`,d.style.setProperty("--ax",`${k-12}px`),d.style.setProperty("--origin",`${k}px ${_?"100%":"0%"}`),requestAnimationFrame(()=>d.setAttribute("data-open",""))},[n,e]);const u=n?(l=i.current)==null?void 0:l.getRootNode():null;return g(pe,{children:[o,u&&ql(g("span",{ref:a,"data-side":"top",role:"tooltip",class:"bg-n-12 text-n-1 corner-smooth ease-out-back rounded-kin-sm duration-kin group pointer-events-none fixed z-[999999] origin-[--origin] scale-90 whitespace-nowrap px-2.5 py-1.5 text-xs opacity-0 transition-[opacity,transform] data-[open]:scale-100 data-[open]:opacity-100 data-[open]:delay-300",children:[e,g("svg",{viewBox:"0 0 32 32","aria-hidden":"true",class:"fill-n-12 absolute left-[--ax] w-6 group-data-[side=bottom]:-top-6 group-data-[side=top]:-bottom-6 group-data-[side=top]:rotate-180",children:g("path",{d:"M3 32C9 32 10 31 15 26Q16 25 17 26C22 31 23 32 29 32"})})]}),u)]})}function Lr(e,t){return typeof e=="function"?(...n)=>{e(...n),t()}:t}const Xy=Ft({base:"relative animate-none flex min-h-0 w-full flex-1 flex-col overflow-hidden",variants:{embedded:{false:"sm:animate-kin-panel-in [will-change:transform,opacity]"}}});function Zy({embedded:e=!1,onClose:t,onClearData:n,onSkipToInput:r}){const[i,a]=fe(!1),s=()=>a(!1),o=l=>{if(l.key==="Escape"){if(l.preventDefault(),i){s();return}e||t()}},u=()=>{if(i){n(),s();return}a(!0)};return g("div",{class:Xy({embedded:e}),role:"dialog","aria-modal":!e,"aria-labelledby":"kin-panel-title",onKeyDown:o,children:[g("button",{type:"button",class:"fr bg-n-2 text-n-12 rounded-kin-sm absolute -top-full left-1/2 z-[1000000] -translate-x-1/2 px-3 py-1.5 text-sm font-medium no-underline focus:top-2",onClick:r,children:"Skip to chat input"}),g("header",{class:"from-a-2/50 relative flex select-none items-center justify-between bg-gradient-to-b to-transparent p-4 sm:p-3 sm:pl-5",children:[g("h2",{id:"kin-panel-title",class:"text-n-12 m-0 text-base font-semibold sm:text-sm sm:font-medium",children:"Kin Assistant"}),!e&&g("div",{"aria-hidden":"true",class:"bg-n-5/50 absolute left-1/2 top-2 h-1 w-12 -translate-x-1/2 rounded-full"}),g("div",{class:"flex items-center gap-1.5",children:[g(uh,{content:i?"Click again to confirm":"Clear my data",children:g("button",{class:bn({variant:i?"accent":"ghost",size:"iconSm"}),"aria-label":i?"Confirm clear data":"Clear my data",type:"button",onClick:u,onBlur:s,children:i?g(Zh,{}):g(Xh,{})})}),!e&&g("button",{class:bn({variant:"neutral",size:"iconSm"}),"aria-label":"Close chat",type:"button",onClick:t,children:g(Kh,{strokeWidth:2})})]})]}),g(Yy,{})]})}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}},e5=".pdf,.docx,.doc,.txt,.jpg,.jpeg,.png,.webp";function t5(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 n5(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 r5({url:e,onMessage:t,onOpen:n,onClose:r,onError:i}){let a=null,s=[];const o=()=>(a==null?void 0:a.readyState)===WebSocket.OPEN,u=p=>{o()&&a.send(JSON.stringify(p))},l=p=>u({type:"user_message",content:p}),h=()=>{if(o()){for(const p of s)l(p);s.length=0}};return(()=>{a=new WebSocket(e),a.onopen=()=>{n(),h()},a.onmessage=p=>{try{const f=JSON.parse(p.data);t(f)}catch(f){console.error("Failed to parse message:",f)}},a.onclose=()=>{s=[],r(),a=null},a.onerror=p=>{i(p)}})(),{sendMessage:p=>{a&&(o()?l(p):a.readyState===WebSocket.CONNECTING&&s.push(p))},uploadFile:async(p,f)=>{if(!o())return{success:!1,error:"Not connected"};const m=t5(p);if(!m.valid)return{success:!1,error:m.error};try{const _=await n5(p);return o()?(u({type:"file_upload",fileType:f,fileName:p.name,mimeType:p.type,data:_}),{success:!0}):{success:!1,error:"Connection lost while reading file. Please try again."}}catch(_){return{success:!1,error:_ instanceof Error?_.message:"Failed to read file"}}},clearData:()=>{u({type:"clear_data"})},disconnect:()=>{a&&(a.close(),a=null)},isConnected:()=>(a==null?void 0:a.readyState)===WebSocket.OPEN}}const tl=2e3,nl="absolute bottom-full left-1/2 mb-2 -translate-x-1/2 whitespace-nowrap rounded-kin-sm bg-red-600 px-3 py-2 text-xs text-white animate-kin-error-in",i5=Ft({base:"w-full pt-1 px-2 pb-safe-b focus-within:pb-2 transition-all duration-kin ease-kin-fluid group-data-[placement=embedded]:pb-2",variants:{panelOpen:{true:"bg-gradient-to-b from-transparent to-n-2",false:"px-5 sm:px-14 group-data-[placement=left]:sm:pl-2 group-data-[placement=left]:sm:pr-24 group-data-[placement=right]:sm:pl-24 group-data-[placement=right]:sm:pr-2"}}}),a5=Ft({base:"border outline relative flex p-0.5 gap-1 flex-col corner-smooth rounded-kin-3xl bg-highest transition-all duration-kin",variants:{panelOpen:{true:"outline-1 outline-transparent border-n-4 focus-within:outline-[3px] focus-within:outline-a-4/50 focus-within:border-a-6/50 shadow-md shadow-n-4/30",false:"outline-2 outline-a-9 border-transparent shadow-xl shadow-a-9/10"}}});function s5({panelOpen:e,suggestions:t,onSubmit:n,onEscape:r,onFocus:i,onBlur:a,onUploadFile:s,inputRef:o}){const[u,l]=fe(""),h=ve(null),d=$.isStreaming.value,p=$.connectionState.value,f=$.uploadState.value,m=$.uploadError.value,_=$.uploadFileName.value,x=p==="connected",k=p==="connecting",v=p==="disconnected",C=p==="idle",R=f==="uploading"||f==="processing",F=u.length>tl,S=u.trim(),Y=S.length>0,L=$.messages.value.length>0,O=t.length>0,A=_?`Uploading ${_}...`:"Uploading file...",z=Y&&!d&&!R&&!F&&(x||k),M=x&&!d&&!R,Q=O?"Or type a message...":R?A:k?"Connecting...":v?"Disconnected - Click to retry":d?"Waiting for response...":!e&&L?"Continue conversation...":"Ask me anything...",ue=R?A:d?"Waiting for response":C?"Click to connect":k?"Connecting...":Y?x?"Send message":"Cannot send message":"Enter a message to send",J=R?A:M?"Attach file (CV, document, or image)":"Cannot upload file",oe=W=>{W.preventDefault(),z&&(n(S),l(""),o.current&&(o.current.style.height="auto"))},q=W=>{W.key==="Enter"&&!W.shiftKey?(W.preventDefault(),oe(W)):W.key==="Escape"&&(W.preventDefault(),W.stopPropagation(),r())},K=W=>{var Z;const E=W.target,he=(Z=E.files)==null?void 0:Z[0];he&&s(he,"cv"),E.value=""};return g("div",{class:i5({panelOpen:e}),role:"search","aria-label":"Chat with Kin AI",children:g("form",{onSubmit:oe,class:a5({panelOpen:e}),autoComplete:"off",children:[O&&g("div",{class:"bg-n-3/75 corner-smooth shadow-n-4/50 rounded-b-kin-sm rounded-t-kin-2xl flex flex-wrap gap-1.5 p-2 shadow-inner","aria-label":"Suggested prompts",children:t.map((W,E)=>g("button",{type:"button",class:"fr bg-highest animate-kin-pop-in text-n-11 corner-smooth outline-n-4/50 hover:outline-n-7/50 hover:text-n-12 rounded-kin-xl inline-flex items-center whitespace-nowrap px-3 py-1.5 text-sm outline outline-1 transition-all hover:outline-2 active:scale-95",style:{animationDelay:`${.05+E*.05}s`},onPointerDown:he=>he.preventDefault(),onClick:()=>n(W.value),children:W.label},W.id))}),g("div",{class:"flex items-end gap-1 p-1 pl-3",children:[g("label",{for:"kin-input",class:"sr-only",children:"Ask Kin a question"}),g("textarea",{id:"kin-input",ref:o,rows:1,enterkeyhint:"send",class:"text-n-12 placeholder:text-n-9 -my-[0.125em] max-h-[6.5em] min-w-0 flex-1 resize-none self-center overflow-y-auto overscroll-none border-none bg-transparent px-0 py-[0.25em] text-base outline-none [mask-image:linear-gradient(to_bottom,transparent_0,_black_0.5em,_black_calc(100%-0.5em),transparent_100%)] disabled:cursor-not-allowed sm:text-sm",placeholder:Q,value:u,onInput:W=>{const E=W.target;l(E.value),E.style.height="auto",E.style.height=`${E.scrollHeight}px`},onFocus:i,onBlur:W=>a(W.relatedTarget),onKeyDown:q,"aria-describedby":"kin-input-status",autoComplete:"off",disabled:R}),g("input",{ref:h,type:"file",class:"sr-only",accept:e5,onChange:K,"aria-hidden":"true",tabIndex:-1}),g(uh,{content:J,children:g("button",{type:"button",class:bn({variant:"ghost"}),disabled:!M,"aria-label":J,onPointerDown:W=>W.preventDefault(),onClick:()=>{var W;return(W=h.current)==null?void 0:W.click()},children:R?g(Jh,{class:"animate-kin-spin"}):g(zl,{})})}),g("button",{type:"submit",class:bn({variant:"accent"}),disabled:!z,"aria-label":ue,onPointerDown:W=>W.preventDefault(),children:g(Qh,{strokeWidth:2})})]}),g("div",{id:"kin-input-status",class:"sr-only",role:"status","aria-live":"polite",children:[k&&"Connecting to Kin...",v&&"Connection lost. Click input to retry.",d&&"Kin is responding...",R&&A]}),m&&f==="error"&&g("div",{class:`${nl} max-w-[calc(100%-32px)] truncate`,role:"alert",children:m}),F&&g("div",{class:nl,role:"alert",children:["Message too long (",u.length.toLocaleString(),"/",tl.toLocaleString()," characters)"]})]})})}const o5=.25,u5=.4,l5=10,c5=5,Da=240,rl=`transform ${Da}ms var(--kin-fluid-ease)`,il=()=>({pointerId:null,startX:0,startY:0,startTime:0,targetHeight:0,currentTranslateY:0,threshold:0,phase:"idle"});function Rr(e){e.style.removeProperty("transition"),e.style.removeProperty("transform"),e.style.removeProperty("will-change")}function d5(e,t){var r;if(!(e instanceof Element)||e.closest("button,input,textarea,select,a")||(r=window.getSelection())!=null&&r.toString())return!1;let n=e;for(;n&&n!==t;){const i=window.getComputedStyle(n);if((/(auto|scroll)/.test(i.overflowY)||/(auto|scroll)/.test(i.overflow))&&n.scrollHeight>n.clientHeight&&n.scrollTop>0)return!1;n=n.parentElement}return!0}function h5({enabled:e,onClose:t}){const n=ve(null),r=ve(il()),i=ve(null),[a,s]=fe(!1),o=()=>{i.current&&(clearTimeout(i.current),i.current=null)},u=()=>{var k;const x=r.current.phase;r.current=il(),x==="dragging"&&((k=n.current)==null||k.toggleAttribute("data-dragging",!1))},l=x=>{if(x===null)return;const k=n.current;k!=null&&k.hasPointerCapture(x)&&k.releasePointerCapture(x)},h=()=>{const x=n.current;x&&(x.style.transition=rl,x.style.transform="translate3d(0, 0, 0)",setTimeout(()=>{i.current||Rr(x)},Da))},d=()=>{if(!e||i.current)return;const x=n.current;if(!x){t();return}s(!0),x.style.willChange="transform",x.style.transition=rl,x.style.transform=`translate3d(0, ${x.getBoundingClientRect().height}px, 0)`,i.current=setTimeout(()=>{i.current=null,t(),Rr(x),s(!1)},Da)},p=x=>{if(!e||i.current||r.current.phase==="pending"||r.current.phase==="dragging"||x.pointerType==="mouse"&&x.button!==0)return;const k=n.current;!k||!d5(x.target,k)||(r.current={pointerId:x.pointerId,startX:x.clientX,startY:x.clientY,startTime:performance.now(),targetHeight:k.getBoundingClientRect().height,currentTranslateY:0,threshold:x.pointerType==="touch"||x.pointerType==="pen"?l5:c5,phase:"pending"})},f=x=>{const k=r.current;if(k.phase!=="pending"&&k.phase!=="dragging"||k.pointerId!==x.pointerId||i.current)return;const v=n.current;if(!v)return;const C=x.clientX-k.startX,R=x.clientY-k.startY;if(k.phase==="pending"){if(Math.abs(C)<k.threshold&&Math.abs(R)<k.threshold)return;if(Math.abs(R)<=Math.abs(C)||R<=0){k.phase="rejected";return}k.phase="dragging",v.toggleAttribute("data-dragging",!0),v.setPointerCapture(x.pointerId),v.style.willChange="transform",v.style.transition="none"}k.phase==="dragging"&&(k.currentTranslateY=Math.max(0,R),v.style.transform=`translate3d(0, ${k.currentTranslateY}px, 0)`,x.preventDefault())},m=x=>{const k=r.current;if(k.pointerId!==x.pointerId)return;l(k.pointerId);const v=k.phase==="dragging";u(),v&&h()},_=x=>{const k=r.current;if(k.pointerId!==x.pointerId)return;if(l(k.pointerId),k.phase!=="dragging"){u();return}const v=k.currentTranslateY,C=Math.max(1,performance.now()-k.startTime),R=v/C,F=v>=k.targetHeight*o5||R>u5;u(),F?d():h()};return Ce(()=>{if(e)return;o(),s(!1),u();const x=n.current;x&&Rr(x)},[e]),Ce(()=>()=>{o();const x=n.current;x&&(x.toggleAttribute("data-dragging",!1),Rr(x))},[]),{shellRef:n,isClosing:a,closeWithSlideOut:d,dragHandlers:{onPointerDown:p,onPointerMove:f,onPointerUp:_,onPointerCancel:m}}}const f5="(hover: none) and (pointer: coarse)",p5='a[href], button:not([disabled]), input:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])';function al(){var t;let e=document.activeElement;for(;(t=e==null?void 0:e.shadowRoot)!=null&&t.activeElement;)e=e.shadowRoot.activeElement;return e}const m5=Ft({base:"font-kin text-kin text-n-12 group flex w-full data-[placement=left]:sm:left-4 data-[placement=right]:sm:right-4 data-[placement=center]:sm:left-1/2 data-[placement=center]:sm:-translate-x-1/2",variants:{layout:{embedded:"relative h-full items-stretch",closed:"items-end",open:"top-[var(--kin-viewport-top)] h-[var(--kin-viewport-h)] overscroll-none items-stretch pt-safe-t [touch-action:manipulation] sm:top-auto sm:h-auto sm:items-end sm:pt-0 sm:[touch-action:auto]"}},compoundVariants:[{layout:["closed","open"],class:"fixed inset-x-0 bottom-0 z-[999999] sm:inset-x-auto sm:bottom-4 sm:w-auto"}]}),g5=Ft({base:"pointer-events-auto sm:w-[480px] rounded-t-kin-4xl flex w-full flex-col transition-all outline outline-1 outline-transparent duration-kin sm:rounded-kin-4xl corner-smooth ease-kin-fluid",variants:{layout:{embedded:"h-full rounded-none bg-n-1 outline-none sm:w-full sm:rounded-none",closed:"",open:"sm:min-h-[50vh] bg-n-1 h-full overflow-hidden sm:max-h-[min(90vh,var(--kin-viewport-h))] sm:outline-n-6/50 sm:shadow-2xl sm:shadow-n-6/30"}}}),b5=Ft({base:"fixed inset-0 z-[999998] bg-black/20 transition-opacity duration-kin ease-kin-fluid",variants:{visible:{false:"pointer-events-none opacity-0",true:"pointer-events-auto opacity-100"}}});function E5({starterPrompts:e,onSendMessage:t,onOpen:n,onClose:r,onConnect:i,onClearData:a,onUploadFile:s,placement:o="center"}){const u=o==="embedded",l=$.isOpen.value,h=u?"embedded":l?"open":"closed",d=h!=="closed",[p,f]=fe(!1),m=ve(null),_=ve(null),x=ve(null),k=$.messages.value.length>0,v=$.quickReplies.value,C=!d&&!k&&p&&e.length>0,R=d&&v.length>0,F=C?e.map((q,K)=>({id:`sp-${K}`,label:q.label,value:q.message})):R?v.map((q,K)=>({id:`qr-${K}`,label:q,value:q})):[];Ce(()=>{var q;if(d){const K=al();_.current=K instanceof HTMLElement&&!((q=m.current)!=null&&q.contains(K))?K:null,requestAnimationFrame(()=>{var W;return(W=x.current)==null?void 0:W.focus()})}else f(!1)},[d]),Ce(()=>{u&&!l&&n()},[u,n,l]),Ce(()=>{if(h!=="open")return;const q=window.matchMedia(f5);if(!q.matches)return;const K=m.current,W=window.visualViewport;if(!K||!W)return;const E=()=>{K.style.setProperty("--kin-viewport-h",`${W.height}px`),K.style.setProperty("--kin-viewport-top",`${W.offsetTop}px`)};E(),W.addEventListener("resize",E),W.addEventListener("scroll",E);let he=0;const Z=ne=>{var ze;he=((ze=ne.touches[0])==null?void 0:ze.clientY)??0},w=ne=>{var nt;const ze=he-(((nt=ne.touches[0])==null?void 0:nt.clientY)??he),Ve=ne.composedPath(),ge=Ve.indexOf(K);if(ge<0)return;const st=rt=>rt instanceof Element&&(ze>0?rt.scrollTop+rt.clientHeight<rt.scrollHeight-1:rt.scrollTop>0);Ve.slice(0,ge).some(st)||ne.preventDefault()};document.addEventListener("touchstart",Z,{passive:!0}),document.addEventListener("touchmove",w,{passive:!1});const Se=()=>{W.removeEventListener("resize",E),W.removeEventListener("scroll",E),K.style.removeProperty("--kin-viewport-h"),K.style.removeProperty("--kin-viewport-top"),document.removeEventListener("touchstart",Z),document.removeEventListener("touchmove",w)},me=ne=>{ne.matches||Se()};return q.addEventListener("change",me),()=>{Se(),q.removeEventListener("change",me)}},[h]),Ce(()=>{if(h!=="open")return;const q=K=>{if(K.key!=="Tab")return;const W=m.current;if(!W)return;const E=W.querySelectorAll(p5),he=E[0],Z=E[E.length-1];if(!he||!Z)return;const w=al();K.shiftKey&&w===he?(K.preventDefault(),Z.focus()):!K.shiftKey&&w===Z&&(K.preventDefault(),he.focus())};return document.addEventListener("keydown",q),()=>document.removeEventListener("keydown",q)},[h]);const S=()=>{h==="closed"&&n()},Y=()=>{var q;(q=x.current)==null||q.blur(),r(),_.current&&requestAnimationFrame(()=>{var K;return(K=_.current)==null?void 0:K.focus()})},{shellRef:L,isClosing:O,closeWithSlideOut:A,dragHandlers:z}=h5({enabled:h==="open"&&!u,onClose:Y}),M=q=>{const K=q.trim();if(!K)return;const W=$.isStreaming.value,E=$.uploadState.value==="uploading"||$.uploadState.value==="processing",he=$.connectionState.value;!W&&!E&&(he==="connected"||he==="connecting")&&($.addMessage({role:"user",content:K}),S(),i(),t(K))},Q=()=>{f(!0),i(),!d&&k&&S()},ue=q=>{var K;q instanceof Node&&((K=m.current)!=null&&K.contains(q))||f(!1)},J=()=>{var q;d?A():(q=x.current)==null||q.blur()},oe=(q,K)=>{S(),s(q,K)};return g(pe,{children:[!u&&g("div",{class:b5({visible:h==="open"&&!O}),"aria-hidden":"true",onClick:A}),g("div",{ref:m,class:m5({layout:h}),"data-placement":o,role:"region","aria-label":"Kin AI Chat",children:g("div",{ref:L,class:g5({layout:h}),...z,children:[g("div",{class:"sr-only",role:"status","aria-live":"polite","aria-atomic":"true",children:d?"Chat panel opened":""}),d&&g(Zy,{embedded:u,onClose:A,onClearData:a,onSkipToInput:()=>{var q;return(q=x.current)==null?void 0:q.focus()}}),g(s5,{panelOpen:d,suggestions:F,onSubmit:M,onEscape:J,onFocus:Q,onBlur:ue,onUploadFile:oe,inputRef:x})]})})]})}const T5=`*,: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-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--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-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--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}.pointer-events-none{pointer-events:none}.pointer-events-auto{pointer-events:auto}.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-0{top:0;right:0;bottom:0;left:0}.inset-x-0{left:0;right:0}.-bottom-1\\.5{bottom:-.375rem}.-top-full{top:-100%}.bottom-0{bottom:0}.bottom-3{bottom:.75rem}.bottom-full{bottom:100%}.left-1\\/2{left:50%}.left-\\[--ax\\]{left:var(--ax)}.right-1\\.5{right:.375rem}.top-2{top:.5rem}.top-\\[var\\(--kin-viewport-top\\)\\]{top:var(--kin-viewport-top)}.z-\\[1000000\\]{z-index:1000000}.z-\\[999998\\]{z-index:999998}.z-\\[999999\\]{z-index:999999}.m-0{margin:0}.-my-\\[0\\.125em\\]{margin-top:-.125em;margin-bottom:-.125em}.mx-auto{margin-left:auto;margin-right:auto}.my-auto{margin-top:auto;margin-bottom:auto}.mb-2{margin-bottom:.5rem}.mb-4{margin-bottom:1rem}.block{display:block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.hidden{display:none}.size-10{width:2.5rem;height:2.5rem}.size-12{width:3rem;height:3rem}.size-3{width:.75rem;height:.75rem}.size-3\\.5{width:.875rem;height:.875rem}.size-8{width:2rem;height:2rem}.h-1{height:.25rem}.h-\\[var\\(--kin-viewport-h\\)\\]{height:var(--kin-viewport-h)}.h-full{height:100%}.max-h-\\[6\\.5em\\]{max-height:6.5em}.min-h-0{min-height:0px}.w-12{width:3rem}.w-4{width:1rem}.w-6{width:1.5rem}.w-full{width:100%}.min-w-0{min-width:0px}.max-w-\\[95\\%\\]{max-width:95%}.max-w-\\[calc\\(100\\%-32px\\)\\]{max-width:calc(100% - 32px)}.max-w-full{max-width:100%}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.origin-\\[--origin\\]{transform-origin:var(--origin)}.-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))}.scale-90{--tw-scale-x: .9;--tw-scale-y: .9;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 .24s ease}@keyframes kin-fade{0%{opacity:0}to{opacity:1}}.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 .24s var(--kin-fluid-ease) both}@keyframes kin-pop{0%{opacity:0;scale:.9}to{opacity:1;scale:1}}.animate-kin-pop-in{animation:kin-pop .24s cubic-bezier(.34,1.56,.64,1) backwards}@keyframes kin-shimmer{0%{background-position:200% 50%}to{background-position:-200% 50%}}.animate-kin-shimmer{animation:kin-shimmer 2.5s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-kin-spin{animation:spin 1s linear infinite}.animate-none{animation:none}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize-none{resize:none}.resize{resize:both}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-end{align-items:flex-end}.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-2\\.5{gap:.625rem}.gap-4{gap:1rem}.gap-x-2\\.5{-moz-column-gap:.625rem;column-gap:.625rem}.gap-y-1{row-gap:.25rem}.self-start{align-self:flex-start}.self-end{align-self:flex-end}.self-center{align-self:center}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overscroll-none{overscroll-behavior:none}.scroll-smooth{scroll-behavior:smooth}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.break-words{overflow-wrap:break-word}.rounded{border-radius:.25rem}.rounded-full{border-radius:9999px}.rounded-kin-2xl{border-radius:var(--kin-r-2xl)}.rounded-kin-3xl{border-radius:var(--kin-r-3xl)}.rounded-kin-lg{border-radius:var(--kin-r-lg)}.rounded-kin-md{border-radius:var(--kin-r-md)}.rounded-kin-sm{border-radius:var(--kin-r-sm)}.rounded-kin-xl{border-radius:var(--kin-r-xl)}.rounded-none{border-radius:0}.rounded-b-kin-sm{border-bottom-right-radius:var(--kin-r-sm);border-bottom-left-radius:var(--kin-r-sm)}.rounded-t-kin-2xl{border-top-left-radius:var(--kin-r-2xl);border-top-right-radius:var(--kin-r-2xl)}.rounded-t-kin-4xl{border-top-left-radius:var(--kin-r-4xl);border-top-right-radius:var(--kin-r-4xl)}.border{border-width:1px}.border-t{border-top-width:1px}.border-none{border-style:none}.border-n-4{--tw-border-opacity: 1;border-color:oklch(var(--n-4) / var(--tw-border-opacity, 1))}.border-n-6\\/40{border-color:oklch(var(--n-6) / .4)}.border-transparent{border-color:transparent}.bg-a-9{--tw-bg-opacity: 1;background-color:oklch(var(--a-9) / var(--tw-bg-opacity, 1))}.bg-black\\/20{background-color:#0003}.bg-highest{--tw-bg-opacity: 1;background-color:oklch(var(--highest) / var(--tw-bg-opacity, 1))}.bg-n-1{--tw-bg-opacity: 1;background-color:oklch(var(--n-1) / var(--tw-bg-opacity, 1))}.bg-n-12{--tw-bg-opacity: 1;background-color:oklch(var(--n-12) / var(--tw-bg-opacity, 1))}.bg-n-2{--tw-bg-opacity: 1;background-color:oklch(var(--n-2) / var(--tw-bg-opacity, 1))}.bg-n-3{--tw-bg-opacity: 1;background-color:oklch(var(--n-3) / var(--tw-bg-opacity, 1))}.bg-n-3\\/75{background-color:oklch(var(--n-3) / .75)}.bg-n-5\\/50{background-color:oklch(var(--n-5) / .5)}.bg-red-600{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity, 1))}.bg-transparent{background-color:transparent}.bg-\\[linear-gradient\\(90deg\\,oklch\\(var\\(--n-9\\)\\)_40\\%\\,oklch\\(var\\(--n-11\\)\\)_50\\%\\,oklch\\(var\\(--n-9\\)\\)_60\\%\\)\\]{background-image:linear-gradient(90deg,oklch(var(--n-9)) 40%,oklch(var(--n-11)) 50%,oklch(var(--n-9)) 60%)}.bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))}.from-a-2\\/50{--tw-gradient-from: oklch(var(--a-2) / .5) var(--tw-gradient-from-position);--tw-gradient-to: rgb(255 255 255 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.from-transparent{--tw-gradient-from: transparent var(--tw-gradient-from-position);--tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.to-n-2{--tw-gradient-to: oklch(var(--n-2) / 1) var(--tw-gradient-to-position)}.to-transparent{--tw-gradient-to: transparent var(--tw-gradient-to-position)}.bg-\\[length\\:200\\%_100\\%\\]{background-size:200% 100%}.bg-clip-text{-webkit-background-clip:text;background-clip:text}.fill-n-12{fill:oklch(var(--n-12) / 1)}.p-0\\.5{padding:.125rem}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-4{padding:1rem}.px-0{padding-left:0;padding-right:0}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\\.5{padding-left:.625rem;padding-right:.625rem}.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-5{padding-left:1.25rem;padding-right:1.25rem}.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-4{padding-top:1rem;padding-bottom:1rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.py-\\[0\\.25em\\]{padding-top:.25em;padding-bottom:.25em}.pb-safe-b{padding-bottom:max(.5rem,calc(env(safe-area-inset-bottom,0px) + .5rem))}.pl-3{padding-left:.75rem}.pl-safe-l{padding-left:max(1rem,env(safe-area-inset-left,1rem))}.pr-2\\.5{padding-right:.625rem}.pr-safe-r{padding-right:max(1rem,env(safe-area-inset-right,1rem))}.pt-1{padding-top:.25rem}.pt-1\\.5{padding-top:.375rem}.pt-safe-t{padding-top:max(1rem,env(safe-area-inset-top,1rem))}.text-center{text-align:center}.font-kin{font-family:var(--kin-font-family)}.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}.leading-relaxed{line-height:1.625}.leading-snug{line-height:1.375}.text-inherit{color:inherit}.text-n-1{--tw-text-opacity: 1;color:oklch(var(--n-1) / var(--tw-text-opacity, 1))}.text-n-10{--tw-text-opacity: 1;color:oklch(var(--n-10) / var(--tw-text-opacity, 1))}.text-n-11{--tw-text-opacity: 1;color:oklch(var(--n-11) / var(--tw-text-opacity, 1))}.text-n-12{--tw-text-opacity: 1;color:oklch(var(--n-12) / var(--tw-text-opacity, 1))}.text-n-3{--tw-text-opacity: 1;color:oklch(var(--n-3) / var(--tw-text-opacity, 1))}.text-n-8{--tw-text-opacity: 1;color:oklch(var(--n-8) / var(--tw-text-opacity, 1))}.text-n-9{--tw-text-opacity: 1;color:oklch(var(--n-9) / var(--tw-text-opacity, 1))}.text-transparent{color:transparent}.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-100{opacity:1}.opacity-50{opacity:.5}.shadow-inner{--tw-shadow: inset 0 2px 4px 0 rgb(0 0 0 / .05);--tw-shadow-colored: inset 0 2px 4px 0 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-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -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)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px 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-a-9\\/10{--tw-shadow-color: oklch(var(--a-9) / .1);--tw-shadow: var(--tw-shadow-colored)}.shadow-n-4\\/30{--tw-shadow-color: oklch(var(--n-4) / .3);--tw-shadow: var(--tw-shadow-colored)}.shadow-n-4\\/50{--tw-shadow-color: oklch(var(--n-4) / .5);--tw-shadow: var(--tw-shadow-colored)}.outline-none{outline:2px solid transparent;outline-offset:2px}.outline{outline-style:solid}.outline-1{outline-width:1px}.outline-2{outline-width:2px}.outline-a-9{outline-color:oklch(var(--a-9) / 1)}.outline-n-3{outline-color:oklch(var(--n-3) / 1)}.outline-n-4\\/50{outline-color:oklch(var(--n-4) / .5)}.outline-transparent{outline-color: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{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-\\[opacity\\,transform\\]{transition-property:opacity,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-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-kin{transition-duration:.24s}.ease-kin-fluid{transition-timing-function:var(--kin-fluid-ease)}.ease-out-back{transition-timing-function:cubic-bezier(.34,1.56,.64,1)}.fr:focus-visible{outline:2px solid oklch(var(--a-9) / .5);outline-offset:2px}.corner-smooth{corner-shape:superellipse(1.25)}.\\[mask-image\\:linear-gradient\\(to_bottom\\,transparent_0\\,_black_0\\.5em\\,_black_calc\\(100\\%-0\\.5em\\)\\,transparent_100\\%\\)\\]{-webkit-mask-image:linear-gradient(to bottom,transparent 0,black .5em,black calc(100% - .5em),transparent 100%);mask-image:linear-gradient(to bottom,transparent 0,black .5em,black calc(100% - .5em),transparent 100%)}.\\[mask-image\\:linear-gradient\\(to_bottom\\,transparent_0\\,_black_1\\.5rem\\,_black_calc\\(100\\%-1\\.5rem\\)\\,transparent_100\\%\\)\\]{-webkit-mask-image:linear-gradient(to bottom,transparent 0,black 1.5rem,black calc(100% - 1.5rem),transparent 100%);mask-image:linear-gradient(to bottom,transparent 0,black 1.5rem,black calc(100% - 1.5rem),transparent 100%)}.\\[touch-action\\:manipulation\\]{touch-action:manipulation}.\\[will-change\\:transform\\,opacity\\]{will-change:transform,opacity}:host{--a-1: 99.4% .003 22.8;--a-2: 98.4% .007 31;--a-3: 95.4% .022 30.9;--a-4: 92.6% .047 31.8;--a-5: 89.2% .063 31.5;--a-6: 85.2% .077 32;--a-7: 80.3% .094 32.2;--a-8: 74.1% .118 32.1;--a-9: 62.7% .194 33.3;--a-10: 60.4% .195 33.3;--a-11: 56.7% .198 32.8;--a-12: 34.6% .08 30.5;--n-1: 99.1% 0 0;--n-2: 98.1% 0 0;--n-3: 95.3% 0 0;--n-4: 93% 0 0;--n-5: 90.8% 0 0;--n-6: 88.4% 0 0;--n-7: 85.1% 0 0;--n-8: 79.1% 0 0;--n-9: 64.3% 0 0;--n-10: 60.9% 0 0;--n-11: 50.3% 0 0;--n-12: 24.3% 0 0;--kin-viewport-h: 100dvh;--kin-viewport-top: 0px;--kin-fluid-ease: cubic-bezier(.32, .72, 0, 1);--kin-font-family: inherit}.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:var(--kin-r-xs);font-family:SF Mono,Monaco,Consolas,monospace;font-size:.875em}.kin-markdown pre{background:rgba(0,0,0,.4);padding:14px 16px;border-radius:var(--kin-r-sm);overflow-x:auto;margin:1em 0;border:1px solid oklch(var(--n-6) / .4)}.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:oklch(var(--n-9))}.kin-markdown :is(ul,ol) :is(ul,ol){margin:.25em 0}.kin-markdown blockquote{border-left:3px solid oklch(var(--a-9));margin:1em 0;padding:.5em 0 .5em 1em;color:oklch(var(--n-11));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 oklch(var(--n-6) / .4);text-align:left}.kin-markdown th{background:oklch(var(--n-4));font-weight:600}.kin-markdown hr{border:none;border-top:1px solid oklch(var(--n-6) / .4);margin:1.5em 0}.kin-markdown hr+p{display:flex;flex-wrap:wrap;align-items:center;gap:5px;font-size:.75em;color:oklch(var(--n-9));margin:-1em 0 0;line-height:1.6}.kin-markdown input[type=checkbox]{margin-right:.5em;accent-color:oklch(var(--a-9))}.kin-markdown .streamdown-caret{display:inline-block;width:2px;height:1em;background:oklch(var(--a-9));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}}[data-dragging],[data-dragging] *{touch-action:none;-webkit-user-select:none;-moz-user-select:none;user-select:none;cursor:grabbing}.placeholder\\:text-n-9::-moz-placeholder{--tw-text-opacity: 1;color:oklch(var(--n-9) / var(--tw-text-opacity, 1))}.placeholder\\:text-n-9::placeholder{--tw-text-opacity: 1;color:oklch(var(--n-9) / var(--tw-text-opacity, 1))}.first\\:border-t-0:first-child{border-top-width:0px}.first\\:pt-0:first-child{padding-top:0}.focus-within\\:border-a-6\\/50:focus-within{border-color:oklch(var(--a-6) / .5)}.focus-within\\:pb-2:focus-within{padding-bottom:.5rem}.focus-within\\:outline-\\[3px\\]:focus-within{outline-width:3px}.focus-within\\:outline-a-4\\/50:focus-within{outline-color:oklch(var(--a-4) / .5)}.hover\\:bg-a-10:hover{--tw-bg-opacity: 1;background-color:oklch(var(--a-10) / var(--tw-bg-opacity, 1))}.hover\\:bg-n-3:hover{--tw-bg-opacity: 1;background-color:oklch(var(--n-3) / var(--tw-bg-opacity, 1))}.hover\\:bg-n-4:hover{--tw-bg-opacity: 1;background-color:oklch(var(--n-4) / var(--tw-bg-opacity, 1))}.hover\\:text-a-9:hover{--tw-text-opacity: 1;color:oklch(var(--a-9) / var(--tw-text-opacity, 1))}.hover\\:text-n-11:hover{--tw-text-opacity: 1;color:oklch(var(--n-11) / var(--tw-text-opacity, 1))}.hover\\:text-n-12:hover{--tw-text-opacity: 1;color:oklch(var(--n-12) / var(--tw-text-opacity, 1))}.hover\\:underline-offset-4:hover{text-underline-offset:4px}.hover\\:outline-2:hover{outline-width:2px}.hover\\:outline-n-7\\/50:hover{outline-color:oklch(var(--n-7) / .5)}.focus\\:top-2:focus{top:.5rem}.focus-visible\\:rounded-kin-xs:focus-visible{border-radius:var(--kin-r-xs)}.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))}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:text-n-6:disabled{--tw-text-opacity: 1;color:oklch(var(--n-6) / var(--tw-text-opacity, 1))}.disabled\\:opacity-50:disabled{opacity:.5}.data-\\[open\\]\\:scale-100[data-open]{--tw-scale-x: 1;--tw-scale-y: 1;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))}.data-\\[open\\]\\:opacity-100[data-open]{opacity:1}.data-\\[open\\]\\:delay-300[data-open]{transition-delay:.3s}.group[data-side=bottom] .group-data-\\[side\\=bottom\\]\\:-top-6{top:-1.5rem}.group[data-side=top] .group-data-\\[side\\=top\\]\\:-bottom-6{bottom:-1.5rem}.group[data-side=top] .group-data-\\[side\\=top\\]\\:rotate-180{--tw-rotate: 180deg;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))}.group[data-placement=embedded] .group-data-\\[placement\\=embedded\\]\\:pb-2{padding-bottom:.5rem}@media (min-width: 640px){.sm\\:inset-x-auto{left:auto;right:auto}.sm\\:bottom-4{bottom:1rem}.sm\\:top-auto{top:auto}.sm\\:size-7{width:1.75rem;height:1.75rem}.sm\\:size-8{width:2rem;height:2rem}.sm\\:h-auto{height:auto}.sm\\:max-h-\\[min\\(90vh\\,var\\(--kin-viewport-h\\)\\)\\]{max-height:min(90vh,var(--kin-viewport-h))}.sm\\:min-h-\\[50vh\\]{min-height:50vh}.sm\\:w-\\[480px\\]{width:480px}.sm\\:w-auto{width:auto}.sm\\:w-full{width:100%}@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 var(--kin-fluid-ease) both}.sm\\:items-end{align-items:flex-end}.sm\\:overscroll-auto{overscroll-behavior:auto}.sm\\:rounded-kin-4xl{border-radius:var(--kin-r-4xl)}.sm\\:rounded-kin-xl{border-radius:var(--kin-r-xl)}.sm\\:rounded-none{border-radius:0}.sm\\:p-3{padding:.75rem}.sm\\:px-14{padding-left:3.5rem;padding-right:3.5rem}.sm\\:px-4{padding-left:1rem;padding-right:1rem}.sm\\:pl-5{padding-left:1.25rem}.sm\\:pt-0{padding-top:0}.sm\\:text-sm{font-size:.875rem;line-height:1.25rem}.sm\\:font-medium{font-weight:500}.sm\\:shadow-2xl{--tw-shadow: 0 25px 50px -12px rgb(0 0 0 / .25);--tw-shadow-colored: 0 25px 50px -12px 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-n-6\\/30{--tw-shadow-color: oklch(var(--n-6) / .3);--tw-shadow: var(--tw-shadow-colored)}.sm\\:outline-n-6\\/50{outline-color:oklch(var(--n-6) / .5)}.sm\\:\\[touch-action\\:auto\\]{touch-action:auto}.data-\\[placement\\=center\\]\\:sm\\:left-1\\/2[data-placement=center]{left:50%}.data-\\[placement\\=left\\]\\:sm\\:left-4[data-placement=left]{left:1rem}.data-\\[placement\\=right\\]\\:sm\\:right-4[data-placement=right]{right:1rem}.data-\\[placement\\=center\\]\\:sm\\:-translate-x-1\\/2[data-placement=center]{--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))}.group[data-placement=left] .group-data-\\[placement\\=left\\]\\:sm\\:pl-2{padding-left:.5rem}.group[data-placement=left] .group-data-\\[placement\\=left\\]\\:sm\\:pr-24{padding-right:6rem}.group[data-placement=right] .group-data-\\[placement\\=right\\]\\:sm\\:pl-24{padding-left:6rem}.group[data-placement=right] .group-data-\\[placement\\=right\\]\\:sm\\:pr-2{padding-right:.5rem}}.\\[\\&\\:\\:-webkit-scrollbar-thumb\\]\\:rounded-kin-xs::-webkit-scrollbar-thumb{border-radius:var(--kin-r-xs)}.\\[\\&\\:\\:-webkit-scrollbar-thumb\\]\\:bg-n-4::-webkit-scrollbar-thumb{--tw-bg-opacity: 1;background-color:oklch(var(--n-4) / var(--tw-bg-opacity, 1))}.\\[\\&\\:\\:-webkit-scrollbar-track\\]\\:bg-transparent::-webkit-scrollbar-track{background-color:transparent}.\\[\\&\\:\\:-webkit-scrollbar\\]\\:w-1\\.5::-webkit-scrollbar{width:.375rem}.\\[\\&\\>\\:first-child\\]\\:mt-auto>:first-child{margin-top:auto}.\\[\\&_svg\\]\\:size-3\\.5 svg{width:.875rem;height:.875rem}.\\[\\&_svg\\]\\:size-4 svg{width:1rem;height:1rem}
|
|
121
|
+
`,lh=["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"],ch={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]]},dh={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]]},na=e=>(e/=255,e<=.04045?e/12.92:((e+.055)/1.055)**2.4),_5=(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),l=.2104542553*s+.793617785*o-.0040720468*u,h=1.9779984951*s-2.428592205*o+.4505937099*u,d=.0259040371*s+.7827717662*o-.808675766*u;return[l,h,d]},hh=([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]},si=([e,t,n])=>{const r=(n??0)*Math.PI/180;return[e,t*Math.cos(r),t*Math.sin(r)]},k5=e=>{const t=e.replace("#",""),n=parseInt(t.length===3?t.replace(/./g,s=>s+s):t,16),r=na(n>>16&255),i=na(n>>8&255),a=na(n&255);return hh(_5(r,i,a))},$n=(e,t)=>{const[n,r,i]=si(e),[a,s,o]=si(t);return Math.hypot(n-a,r-s,i-o)},x5=(e,t,n)=>{const r=si(e),i=si(t),a=[r[0]+(i[0]-r[0])*n,r[1]+(i[1]-r[1])*n,r[2]+(i[2]-r[2])*n];return hh(a)},y5=([e,t,n])=>`oklch(${(e*100).toFixed(1)}% ${+t.toFixed(3)} ${+(n??0).toFixed(2)})`,fh=["1","2","3","4","5","6","7","8","9","10","11","12"],Ns=["gray","mauve","slate","sage","olive","sand"];function Ni(e,t){return Object.fromEntries(t.map(n=>[n,e[n]]))}const w5=Ni(dh,lh),A5=Ni(ch,lh),C5=Ni(dh,Ns),S5=Ni(ch,Ns),sl=({prefix:e,appearance:t,color:n,isNeutral:r=!1})=>{if(!/^#?[0-9A-Fa-f]{6}$/.test(n))throw new Error("Color must be a valid 6-digit hex");const i=t==="light"?w5:A5,a=t==="light"?C5:S5,s=k5(n),o=r?ol(s,a):ol(s,i);if(!r){o[8]=s,o[9]=v5(s,[o]);const u=Math.max(o[8][1],o[7][1]);o[10][1]=Math.min(u,o[10][1]),o[11][1]=Math.min(u,o[11][1])}return Object.fromEntries(fh.map((u,l)=>[`${e}${u}`,y5(o[l])]))};function v5(e,t){const[n,r,i]=e,a=n>.4?n-.03/(n+.1):n+.03/(n+.1),s=n>.4&&i!==null?r*.93:r,o=[a,s,i];let u=o,l=1/0;for(const h of t)for(const d of h){const p=$n(o,d);p<l&&(l=p,u=d)}return[a,u[1],u[2]]}function ol(e,t){const n=[];for(const[C,R]of Object.entries(t))for(const F of R)n.push({scale:C,color:F,distance:$n(e,F)});n.sort((C,R)=>C.distance-R.distance);const r=n.filter((C,R,F)=>R===F.findIndex(S=>S.scale===C.scale)),i=new Set(Ns);if(!r.every(C=>i.has(C.scale))&&i.has(r[0].scale))for(;r.length>1&&i.has(r[1].scale);)r.splice(1,1);const[s,o]=[r[0],r[1]],u=o.distance,l=s.distance,h=$n(s.color,o.color),d=(l**2+h**2-u**2)/(2*l*h),p=(u**2+h**2-l**2)/(2*u*h),f=Math.max(0,d/Math.sqrt(1-d**2)/(p/Math.sqrt(1-p**2)))*.5,m=t[s.scale],_=t[o.scale],x=fh.map((C,R)=>x5(m[R],_[R],f)),k=x.slice().sort((C,R)=>$n(e,C)-$n(e,R))[0],v=e[1]/(k[1]||1e-6);for(const C of x)C[1]=Math.min(e[1]*1.5,C[1]*v),C[2]=e[2];return x}const I5=e=>e.slice(6,-1),ul=e=>Object.entries(e).map(([t,n])=>`--${t}: ${I5(n)};`);function N5(e){const t=sl({prefix:"a-",appearance:e.mode,color:e.accentColor}),n=sl({prefix:"n-",appearance:e.mode,color:e.neutralColor??"#555555",isNeutral:!0}),r=`--highest: ${e.mode==="light"?"100% 0 0":"10% 0 0"};`;return[...ul(t),...ul(n),r].join(`
|
|
122
|
+
`)}const L5={sm:.25,md:.5,lg:1},R5={"kin-r-xs":4,"kin-r-sm":8,"kin-r-md":10,"kin-r-lg":12,"kin-r-xl":16,"kin-r-2xl":20,"kin-r-3xl":24,"kin-r-4xl":32},O5=e=>`${Number(e.toFixed(3))}px`;function D5(e){return Object.entries(R5).map(([t,n])=>`--${t}: ${O5(n*L5[e])};`).join(`
|
|
123
|
+
`)}const Pa=e=>typeof e=="object"&&e!==null&&!Array.isArray(e),zr=e=>{if(typeof e!="string")return null;const t=e.trim();return t.length>0?t:null},P5=e=>{const t=zr(e);return t&&(t.startsWith("http://")||t.startsWith("https://")||t.startsWith("/")&&!t.startsWith("//"))?t:null},M5=e=>{if(!Pa(e))return null;if(e.kind==="job_cards"&&Array.isArray(e.jobs)){const t=e.jobs.flatMap(n=>{const r=B5(n);return r?[r]:[]});return t.length>0?{kind:"job_cards",jobs:t}:null}return null},ph=e=>{if(!Array.isArray(e))return null;const t=e.flatMap(n=>{const r=M5(n);return r?[r]:[]});return t.length>0?t:null},B5=e=>{if(!Pa(e))return null;const t=e.id;if(typeof t!="string"&&typeof t!="number")return null;const n=zr(e.title);if(!n)return null;const r=Array.isArray(e.details)?e.details.flatMap(s=>{if(!Pa(s))return[];const o=zr(s.key),u=zr(s.value);return o&&u?[{key:o,value:u}]:[]}):[],i={id:String(t),title:n,details:r},a=P5(e.applyUrl);return a&&(i.applyUrl=a),i},ll={accentColor:"#FF4D00",neutralColor:"#555555",mode:"light",rounded:"lg"},F5="wss://agents.inploi.com",H5=/^\[System: CV uploaded and processed - "(.+?)"/;function U5(e){var r;if(e.role!=="assistant"&&e.role!=="user")return[];const t=typeof e.content=="string"?e.content:"";if(e.role==="user"){const i=(r=H5.exec(t))==null?void 0:r[1];if(i)return[{role:"user",content:"",attachment:{name:i}}];if(t.startsWith("[System:"))return[]}const n=ph(e.blocks)??void 0;return[{role:e.role,content:t,...n&&{blocks:n}}]}const z5=({serviceUrl:e=F5,theme:t=ll,starterPrompts:n=[],placement:r="center",container:i})=>Li.createPlugin(({logger:a,publishableKey:s})=>{if(!s)throw new Error("Kin plugin requires a publishableKey. Pass it to initialiseSdk().");let o=!1,u=null,l={...ll,...t},h=null,d=!1,p=null,f=null,m=!1;const _=r==="embedded",x=()=>{if(i)if(typeof i=="string"){const A=document.querySelector(i);if(A instanceof HTMLElement)return f=A,m=!1,A}else return f=i,m=!1,i;const L=document.getElementById("inploi-kin-root");if(L)return f=L,m=!1,L;const O=document.createElement("div");return O.id="inploi-kin-root",document.body.appendChild(O),f=O,m=!0,O},k=L=>{const O=N5(L),A=D5(L.rounded??"lg");return`${T5}
|
|
124
124
|
|
|
125
125
|
/* Theme overrides */
|
|
126
126
|
:host {
|
|
127
|
-
${
|
|
127
|
+
${O}
|
|
128
128
|
${A}
|
|
129
|
-
}`},v=()=>{if(typeof window>"u")return;const L=x();L.dataset.mode=l.mode;const
|
|
129
|
+
}`},v=()=>{if(typeof window>"u")return;const L=x();L.dataset.mode=l.mode;const O=L.shadowRoot||L.attachShadow({mode:"open"});qr(mt(pe,{},[mt("style",{id:"kin-styles"},k(l)),mt(E5,{starterPrompts:n,placement:r,onSendMessage:A=>u==null?void 0:u.sendMessage(A),onOpen:()=>F(),onClose:()=>{_||($.isOpen.value=!1)},onConnect:()=>S(),onClearData:()=>u==null?void 0:u.clearData(),onUploadFile:async(A,z)=>{if(!u){$.setUploadState("error",A.name,"Not connected");return}const{id:M}=$.addMessage({role:"user",content:"",attachment:{name:A.name}});$.setUploadState("uploading",A.name);const Q=await u.uploadFile(A,z);Q.success||($.removeMessage(M),$.setUploadState("error",A.name,Q.error))}})]),O)},C=()=>{o||(h=Li.getOrCreateAnonymousId(),v(),o=!0)},R=()=>{$.isOpen.value=!0,$.hasUnreadMessages.value=!1},F=()=>{S(),R()},S=()=>{if(u)return;$.connectionState.value="connecting",h||(h=Li.getOrCreateAnonymousId());const L=`${e}/agent/candidate/${h}?key=${s}`;u=r5({url:L,onMessage:O=>{switch(O.type){case"authenticated":a.info(`Authenticated with ${O.company}`),$.connectionState.value="connected";break;case"history":O.messages&&O.messages.length>0&&(a.info(`Loaded ${O.messages.length} messages from server`),$.setMessages(O.messages.flatMap(U5)));break;case"response_start":$.startAssistantResponse();break;case"response_chunk":$.assistantStatus.value="responding",$.appendToLiveAssistantMessage(O.content||"");break;case"response_end":{const A=ph(O.blocks)??void 0;$.finishAssistantResponse({blocks:A}),$.isOpen.value||($.hasUnreadMessages.value=!0);break}case"quick_replies":O.options&&O.options.length>=2&&($.quickReplies.value=O.options),$.assistantStatus.value=null;break;case"tool_call":$.assistantStatus.value=O.tool??"thinking";break;case"tool_result":O.tool&&O.tool!=="suggestQuickReplies"&&($.assistantStatus.value="processing_results");break;case"data_cleared":a.info("User data cleared"),$.clearMessages(),$.addMessage({role:"system",content:"Your conversation data has been cleared."});break;case"guardrail_block":$.finishAssistantResponse({broadcast:!1}),a.warn("Content blocked by safety policy"),$.addMessage({role:"system",content:O.content||"I'm not able to help with that request."});break;case"upload_received":case"file_processing":a.info(`File ${O.type==="upload_received"?"received":"processing"}: ${O.fileName}`),$.setUploadState("processing",O.fileName),$.assistantStatus.value="processing_cv";break;case"file_processed":O.status==="success"?(a.info(`File processed: ${O.fileName}`),$.setUploadState("success",O.fileName),$.assistantStatus.value=null,setTimeout(()=>$.setUploadState("idle"),2e3)):(a.error(`File processing failed: ${O.error}`),$.setUploadState("error",O.fileName,O.error),$.assistantStatus.value=null);break;case"error":$.finishAssistantResponse({broadcast:!1}),$.uploadState.value!=="idle"&&$.setUploadState("error",void 0,O.content),a.error("Kin error:",O.content),$.addMessage({role:"assistant",content:O.content||"An error occurred"});break}},onOpen:()=>{a.info("WebSocket opened, awaiting authentication...")},onClose:()=>{a.info("Disconnected from Kin service"),$.connectionState.value="disconnected",$.finishAssistantResponse({broadcast:!1});const O=d;u=null,d=!1,!O&&$.isOpen.value&&(a.info("Attempting to reconnect..."),p=setTimeout(()=>{p=null,S()},1e3))},onError:O=>{a.error("Kin connection error:",O),$.connectionState.value="error",$.finishAssistantResponse({broadcast:!1})}})},Y=()=>{p&&(clearTimeout(p),p=null),u&&(d=!0,u.disconnect(),u=null)};return{prepare:()=>{typeof window>"u"||o||(C(),S(),a.info("Kin plugin prepared"))},open:()=>{typeof window>"u"||(C(),F(),a.info("Kin opened"))},close:()=>{typeof window>"u"||($.isOpen.value=!1,a.info("Kin closed"))},toggle:()=>{typeof window>"u"||($.isOpen.value?$.isOpen.value=!1:(C(),F()))},setTheme:L=>{var O;if(l={rounded:l.rounded,...L},o&&f){f.dataset.mode=l.mode;const A=(O=f.shadowRoot)==null?void 0:O.getElementById("kin-styles");A&&(A.textContent=k(l))}a.info("Kin theme updated:",L)},destroy:()=>{typeof window>"u"||(Y(),f&&(f.shadowRoot&&qr(null,f.shadowRoot),m&&f.remove()),$.resetState(),o=!1,f=null,m=!1,a.info("Kin plugin destroyed"))}}});exports.Ks=Gx;exports.Nt=ih;exports.Qe=w0;exports.R=et;exports.h=fe;exports.kinPlugin=z5;exports.o=g;exports.p=Ce;exports.q=Ge;
|