db-studio 1.7.5 → 1.7.7
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/dist/core-dist/assets/_pathlessLayout-BU3Kyxsk.js +2 -0
- package/dist/core-dist/assets/{_pathlessLayout-BgaXE7MD.js → _pathlessLayout-lti_XhXr.js} +1 -1
- package/dist/core-dist/assets/_queryId-CCHTTBV8.js +1 -0
- package/dist/core-dist/assets/_table-CJoa4R3j.js +10 -0
- package/dist/core-dist/assets/_table-DUXAj26I.js +1 -0
- package/dist/core-dist/assets/{cdoe-editor--A2X22TE.js → cdoe-editor-D9sNd-1b.js} +2 -2
- package/dist/core-dist/assets/{chat-sidebar-Dq5zKCoF.js → chat-sidebar-Bsby7756.js} +2 -2
- package/dist/core-dist/assets/{chunk-BO2N2NFS-CtrFqJix.js → chunk-BO2N2NFS-BWASkQ7r.js} +4 -4
- package/dist/core-dist/assets/{dist-C-W9v39G.js → dist-BEhHk7ZM.js} +1 -1
- package/dist/core-dist/assets/{dist-CWf64aZV.js → dist-BI9dZvr6.js} +1 -1
- package/dist/core-dist/assets/{highlighted-body-OFNGDK62-Dqw8vrq4.js → highlighted-body-OFNGDK62-BEkQLPsL.js} +1 -1
- package/dist/core-dist/assets/{icons-CAZJbhBz.js → icons-BywMJ5og.js} +1 -1
- package/dist/core-dist/assets/index-CcB1R3kx.js +57 -0
- package/dist/core-dist/assets/index-Dv6o03bL.css +2 -0
- package/dist/core-dist/assets/{indexes-B2pdcOTa.js → indexes-WJgC6xdV.js} +1 -1
- package/dist/core-dist/assets/{logs-DItnmo1m.js → logs-BD6ggRmF.js} +1 -1
- package/dist/core-dist/assets/mermaid-GHXKKRXX-Cey0AJ6z.js +1 -0
- package/dist/core-dist/assets/queries.store-CitCTkPZ.js +1 -0
- package/dist/core-dist/assets/{radix-ui-B93Y7STU.js → radix-ui-C0u6gLux.js} +1 -1
- package/dist/core-dist/assets/{react-dom-KMIgB9GW.js → react-dom-JJlWtX5O.js} +1 -1
- package/dist/core-dist/assets/runner-Be0RXHJn.js +1 -0
- package/dist/core-dist/assets/{runner-tab-JuHyhE5I.js → runner-tab-_ttjqcHa.js} +3 -3
- package/dist/core-dist/assets/{schema-B1a8u8dT.js → schema-fNXfq0jj.js} +1 -1
- package/dist/core-dist/assets/{scroll-area-DIT4iXSA.js → scroll-area-B6qID65r.js} +1 -1
- package/dist/core-dist/assets/{table-Bq-YbPAX.js → table-NRrQaCx4.js} +1 -1
- package/dist/core-dist/assets/{tanstack-COAHM0pn.js → tanstack-DyfKDo5s.js} +1 -1
- package/dist/core-dist/assets/{tooltip-BPnX8rwL.js → tooltip-BpcLhRow.js} +1 -1
- package/dist/core-dist/assets/use-delete-column-DUq6S2en.js +1 -0
- package/dist/core-dist/assets/{use-rate-limit-JM72I-Qe.js → use-rate-limit-HDhI0oS3.js} +1 -1
- package/dist/core-dist/assets/{visualizer-CQk0bfHO.js → visualizer-DBsb8pcK.js} +1 -1
- package/dist/core-dist/index.html +6 -6
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/core-dist/assets/_pathlessLayout-7XOLasgU.js +0 -2
- package/dist/core-dist/assets/_queryId-DHd3r8hS.js +0 -1
- package/dist/core-dist/assets/_table-BrQjEEkt.js +0 -8
- package/dist/core-dist/assets/_table-C6uuIAjA.js +0 -1
- package/dist/core-dist/assets/index-Cw94sGcz.js +0 -57
- package/dist/core-dist/assets/index-hsgkD-V0.css +0 -2
- package/dist/core-dist/assets/mermaid-GHXKKRXX--wNt23Qo.js +0 -1
- package/dist/core-dist/assets/queries.store-B8yJ67Tq.js +0 -1
- package/dist/core-dist/assets/runner-DGQg7j15.js +0 -1
- package/dist/core-dist/assets/use-delete-column-DfaGMfjR.js +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/highlighted-body-OFNGDK62-
|
|
2
|
-
import{n as Cs,r as Zn,t as bn}from"./rolldown-runtime-Bnw7wDfq.js";import{tt as xc}from"./icons-CAZJbhBz.js";import{Dt as Ic,Ot as Nc}from"./radix-ui-B93Y7STU.js";import{n as ys,t as xs}from"./bundle-mjs-DkNbwow-.js";import{It as Is}from"./monaco-editor-B6TxHuqP.js";var Jn=(function(e){if(e==null)return Rc;if(typeof e=="function")return er(e);if(typeof e=="object")return Array.isArray(e)?Sc(e):wc(e);if(typeof e=="string")return Lc(e);throw new Error("Expected function, string, or object as test")});function Sc(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Jn(e[n]);return er(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function wc(e){const t=e;return er(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function Lc(e){return er(t);function t(n){return n&&n.type===e}}function er(e){return t;function t(n,r,i){return!!(Oc(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function Rc(){return!0}function Oc(e){return e!==null&&typeof e=="object"&&"type"in e}var Ns=[];var nn="skip";function si(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=Jn(i),s=r?-1:1;o(e,void 0,[])();function o(l,u,h){const d=l&&typeof l=="object"?l:{};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 ("+(l.type+(f?"<"+f+">":""))+")"})}return p;function p(){let f=Ns,E,I,S;if((!t||a(l,u,h[h.length-1]||void 0))&&(f=Dc(n(l,h)),f[0]===!1))return f;if("children"in l&&l.children){const k=l;if(k.children&&f[0]!=="skip")for(I=(r?k.children.length:-1)+s,S=h.concat(k);I>-1&&I<k.children.length;){const L=k.children[I];if(E=o(L,I,S)(),E[0]===!1)return E;I=typeof E[1]=="number"?E[1]:I+s}}return f}}}function Dc(e){return Array.isArray(e)?e:typeof e=="number"?[!0,e]:e==null?Ns:[e]}function Ke(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),si(e,a,o,i);function o(l,u){const h=u[u.length-1],d=h?h.children.indexOf(l):void 0;return s(l,d,h)}}var y=Zn(xc(),1),Ft={indicator:"indicator",textOnly:"text-only",remove:"remove"};function vc({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=Ft.indicator,imageBlockPolicy:l=Ft.indicator}){const u=t.length&&!t.every(d=>d==="*"),h=n.length&&!n.every(d=>d==="*");if(!e&&(u||h))throw new Error("defaultOrigin is required when allowedLinkPrefixes or allowedImagePrefixes are provided");return d=>{const p=Uc(e,t,n,r,i,a,s,o,l);Ss(d),Ke(d,p)}}function Ui(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 Pc(e){return typeof e!="string"?!1:e.startsWith("/")||e.startsWith("./")||e.startsWith("../")}var Mc=new Set(["https:","http:","irc:","ircs:","mailto:","xmpp:","blob:"]),Bc=new Set(["javascript:","data:","file:","vbscript:"]);function ji(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 l=e.substring(5);if(l&&l.length>0&&l!=="invalid")return e}}catch{return null}return null}const s=Ui(e,n);if(!s||Bc.has(s.protocol)||!(Mc.has(s.protocol)||a.includes(s.protocol)||a.includes("*")))return null;if(s.protocol==="mailto:"||!s.protocol.match(/^https?:$/))return s.href;const o=Pc(e);return s&&t.some(l=>{const u=Ui(l,n);return!u||u.origin!==s.origin?!1:s.href.startsWith(u.href)})?o?s.pathname+s.search+s.hash:s.href:t.includes("*")?s.protocol!=="https:"&&s.protocol!=="http:"?null:o?s.pathname+s.search+s.hash:s.href:null}function Ss(e){if("children"in e&&Array.isArray(e.children)){e.children=e.children.filter(t=>t!=null);for(const t of e.children)Ss(t)}}var fr=Symbol("node-seen");function Fc(e,t,n){return t===Ft.remove?{type:"remove"}:t===Ft.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 Hc(e,t,n){if(t===Ft.remove)return{type:"remove"};if(t===Ft.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")+"]"}]}}}var Uc=(e,t,n,r,i,a,s,o,l)=>{const u=(h,d,p)=>{if(h.type!=="element"||h[fr])return!0;if(h.tagName==="a"){const f=ji(h.properties.href,t,e,!1,!1,i);if(f===null){if(h[fr]=!0,Ke(h,u),p&&typeof d=="number"){const E=Fc(h,o,s);if(E.type==="remove")return p.children.splice(d,1),[nn,d];p.children[d]=E.element}return nn}else return h.properties.href=f,h.properties.target="_blank",h.properties.rel="noopener noreferrer",!0}if(h.tagName==="img"){const f=ji(h.properties.src,n,e,r,!0,i);if(f===null){if(h[fr]=!0,Ke(h,u),p&&typeof d=="number"){const E=Hc(h,l,a);if(E.type==="remove")return p.children.splice(d,1),[nn,d];p.children[d]=E.element}return nn}else return h.properties.src=f,!0}return!0};return u},zi=typeof self=="object"?self:globalThis,jc=(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 0:case-1:return n(s,i);case 1:{const o=n([],i);for(const l of s)o.push(r(l));return o}case 2:{const o=n({},i);for(const[l,u]of s)o[r(l)]=r(u);return o}case 3:return n(new Date(s),i);case 4:{const{source:o,flags:l}=s;return n(new RegExp(o,l),i)}case 5:{const o=n(new Map,i);for(const[l,u]of s)o.set(r(l),r(u));return o}case 6:{const o=n(new Set,i);for(const l of s)o.add(r(l));return o}case 7:{const{name:o,message:l}=s;return n(new zi[o](l),i)}case 8: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 zi[a](s),i)};return r},$i=e=>jc(new Map,e)(0),Dt="",{toString:zc}={},{keys:$c}=Object,Kt=e=>{const t=typeof e;if(t!=="object"||!e)return[0,t];const n=zc.call(e).slice(8,-1);switch(n){case"Array":return[1,Dt];case"Object":return[2,Dt];case"Date":return[3,Dt];case"RegExp":return[4,Dt];case"Map":return[5,Dt];case"Set":return[6,Dt];case"DataView":return[1,n]}return n.includes("Array")?[1,n]:n.includes("Error")?[7,n]:[2,n]},On=([e,t])=>e===0&&(t==="function"||t==="symbol"),Yc=(e,t,n,r)=>{const i=(s,o)=>{const l=r.push(s)-1;return n.set(o,l),l},a=s=>{if(n.has(s))return n.get(s);let[o,l]=Kt(s);switch(o){case 0:{let h=s;switch(l){case"bigint":o=8,h=s.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+l);h=null;break;case"undefined":return i([-1],s)}return i([o,h],s)}case 1:{if(l){let p=s;return l==="DataView"?p=new Uint8Array(s.buffer):l==="ArrayBuffer"&&(p=new Uint8Array(s)),i([l,[...p]],s)}const h=[],d=i([o,h],s);for(const p of s)h.push(a(p));return d}case 2:{if(l)switch(l){case"BigInt":return i([l,s.toString()],s);case"Boolean":case"Number":case"String":return i([l,s.valueOf()],s)}if(t&&"toJSON"in s)return a(s.toJSON());const h=[],d=i([o,h],s);for(const p of $c(s))(e||!On(Kt(s[p])))&&h.push([a(p),a(s[p])]);return d}case 3:return i([o,s.toISOString()],s);case 4:{const{source:h,flags:d}=s;return i([o,{source:h,flags:d}],s)}case 5:{const h=[],d=i([o,h],s);for(const[p,f]of s)(e||!(On(Kt(p))||On(Kt(f))))&&h.push([a(p),a(f)]);return d}case 6:{const h=[],d=i([o,h],s);for(const p of s)(e||!On(Kt(p)))&&h.push(a(p));return d}}const{message:u}=s;return i([o,{name:l,message:u}],s)};return a},Yi=(e,{json:t,lossy:n}={})=>{const r=[];return Yc(!(t||n),!!t,new Map,r)(e),r},Ct=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?$i(Yi(e,t)):structuredClone(e):(e,t)=>$i(Yi(e,t));var kn=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};kn.prototype.normal={};kn.prototype.property={};kn.prototype.space=void 0;function ws(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new kn(n,r,t)}function mn(e){return e.toLowerCase()}var Le=class{constructor(e,t){this.attribute=t,this.property=e}};Le.prototype.attribute="";Le.prototype.booleanish=!1;Le.prototype.boolean=!1;Le.prototype.commaOrSpaceSeparated=!1;Le.prototype.commaSeparated=!1;Le.prototype.defined=!1;Le.prototype.mustUseProperty=!1;Le.prototype.number=!1;Le.prototype.overloadedBoolean=!1;Le.prototype.property="";Le.prototype.spaceSeparated=!1;Le.prototype.space=void 0;var Pr=Cs({boolean:()=>G,booleanish:()=>pe,commaOrSpaceSeparated:()=>ve,commaSeparated:()=>Mt,number:()=>M,overloadedBoolean:()=>Mr,spaceSeparated:()=>le}),qc=0,G=It(),pe=It(),Mr=It(),M=It(),le=It(),Mt=It(),ve=It();function It(){return 2**++qc}var pr=Object.keys(Pr),li=class extends Le{constructor(e,t,n,r){let i=-1;if(super(e,t),qi(this,"space",r),typeof n=="number")for(;++i<pr.length;){const a=pr[i];qi(this,pr[i],(n&Pr[a])===Pr[a])}}};li.prototype.defined=!0;function qi(e,t,n){n&&(e[t]=n)}function jt(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const a=new li(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[mn(r)]=r,n[mn(a.attribute)]=r}return new kn(t,n,e.space)}var Ls=jt({properties:{ariaActiveDescendant:null,ariaAtomic:pe,ariaAutoComplete:null,ariaBusy:pe,ariaChecked:pe,ariaColCount:M,ariaColIndex:M,ariaColSpan:M,ariaControls:le,ariaCurrent:null,ariaDescribedBy:le,ariaDetails:null,ariaDisabled:pe,ariaDropEffect:le,ariaErrorMessage:null,ariaExpanded:pe,ariaFlowTo:le,ariaGrabbed:pe,ariaHasPopup:null,ariaHidden:pe,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:le,ariaLevel:M,ariaLive:null,ariaModal:pe,ariaMultiLine:pe,ariaMultiSelectable:pe,ariaOrientation:null,ariaOwns:le,ariaPlaceholder:null,ariaPosInSet:M,ariaPressed:pe,ariaReadOnly:pe,ariaRelevant:null,ariaRequired:pe,ariaRoleDescription:le,ariaRowCount:M,ariaRowIndex:M,ariaRowSpan:M,ariaSelected:pe,ariaSetSize:M,ariaSort:null,ariaValueMax:M,ariaValueMin:M,ariaValueNow:M,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function Rs(e,t){return t in e?e[t]:t}function Os(e,t){return Rs(e,t.toLowerCase())}var Vc=jt({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Mt,acceptCharset:le,accessKey:le,action:null,allow:null,allowFullScreen:G,allowPaymentRequest:G,allowUserMedia:G,alt:null,as:null,async:G,autoCapitalize:null,autoComplete:le,autoFocus:G,autoPlay:G,blocking:le,capture:null,charSet:null,checked:G,cite:null,className:le,cols:M,colSpan:null,content:null,contentEditable:pe,controls:G,controlsList:le,coords:M|Mt,crossOrigin:null,data:null,dateTime:null,decoding:null,default:G,defer:G,dir:null,dirName:null,disabled:G,download:Mr,draggable:pe,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:G,formTarget:null,headers:le,height:M,hidden:Mr,high:M,href:null,hrefLang:null,htmlFor:le,httpEquiv:le,id:null,imageSizes:null,imageSrcSet:null,inert:G,inputMode:null,integrity:null,is:null,isMap:G,itemId:null,itemProp:le,itemRef:le,itemScope:G,itemType:le,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:G,low:M,manifest:null,max:null,maxLength:M,media:null,method:null,min:null,minLength:M,multiple:G,muted:G,name:null,nonce:null,noModule:G,noValidate:G,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:G,optimum:M,pattern:null,ping:le,placeholder:null,playsInline:G,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:G,referrerPolicy:null,rel:le,required:G,reversed:G,rows:M,rowSpan:M,sandbox:le,scope:null,scoped:G,seamless:G,selected:G,shadowRootClonable:G,shadowRootDelegatesFocus:G,shadowRootMode:null,shape:null,size:M,sizes:null,slot:null,span:M,spellCheck:pe,src:null,srcDoc:null,srcLang:null,srcSet:null,start:M,step:null,style:null,tabIndex:M,target:null,title:null,translate:null,type:null,typeMustMatch:G,useMap:null,value:pe,width:M,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:le,axis:null,background:null,bgColor:null,border:M,borderColor:null,bottomMargin:M,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:G,declare:G,event:null,face:null,frame:null,frameBorder:null,hSpace:M,leftMargin:M,link:null,longDesc:null,lowSrc:null,marginHeight:M,marginWidth:M,noResize:G,noHref:G,noShade:G,noWrap:G,object:null,profile:null,prompt:null,rev:null,rightMargin:M,rules:null,scheme:null,scrolling:pe,standby:null,summary:null,text:null,topMargin:M,valueType:null,version:null,vAlign:null,vLink:null,vSpace:M,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:G,disableRemotePlayback:G,prefix:null,property:null,results:M,security:null,unselectable:null},space:"html",transform:Os}),Wc=jt({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:ve,accentHeight:M,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:M,amplitude:M,arabicForm:null,ascent:M,attributeName:null,attributeType:null,azimuth:M,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:M,by:null,calcMode:null,capHeight:M,className:le,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:M,diffuseConstant:M,direction:null,display:null,dur:null,divisor:M,dominantBaseline:null,download:G,dx:null,dy:null,edgeMode:null,editable:null,elevation:M,enableBackground:null,end:null,event:null,exponent:M,externalResourcesRequired:null,fill:null,fillOpacity:M,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:Mt,g2:Mt,glyphName:Mt,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:M,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:M,horizOriginX:M,horizOriginY:M,id:null,ideographic:M,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:M,k:M,k1:M,k2:M,k3:M,k4:M,kernelMatrix:ve,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:M,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:M,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:M,overlineThickness:M,paintOrder:null,panose1:null,path:null,pathLength:M,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:le,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:M,pointsAtY:M,pointsAtZ:M,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:ve,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:ve,rev:ve,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:ve,requiredFeatures:ve,requiredFonts:ve,requiredFormats:ve,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:M,specularExponent:M,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:M,strikethroughThickness:M,string:null,stroke:null,strokeDashArray:ve,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:M,strokeOpacity:M,strokeWidth:null,style:null,surfaceScale:M,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:ve,tabIndex:M,tableValues:null,target:null,targetX:M,targetY:M,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:ve,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:M,underlineThickness:M,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:M,values:null,vAlphabetic:M,vMathematical:M,vectorEffect:null,vHanging:M,vIdeographic:M,version:null,vertAdvY:M,vertOriginX:M,vertOriginY:M,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:M,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Rs}),Ds=jt({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()}}),vs=jt({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Os}),Ps=jt({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),Qc={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"},Gc=/[A-Z]/g,Vi=/-[a-z]/g,Kc=/^data[-\w.:]+$/i;function tr(e,t){const n=mn(t);let r=t,i=Le;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&Kc.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(Vi,Zc);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!Vi.test(a)){let s=a.replace(Gc,Xc);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}i=li}return new i(r,t)}function Xc(e){return"-"+e.toLowerCase()}function Zc(e){return e.charAt(1).toUpperCase()}var _n=ws([Ls,Vc,Ds,vs,Ps],"html"),ft=ws([Ls,Wc,Ds,vs,Ps],"svg");function Wi(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 Ms(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}var Qi=/[#.]/g;function Jc(e,t){const n=e||"",r={};let i=0,a,s;for(;i<n.length;){Qi.lastIndex=i;const o=Qi.exec(n),l=n.slice(i,o?o.index:n.length);l&&(a?a==="#"?r.id=l:Array.isArray(r.className)?r.className.push(l):r.className=[l]:s=l,i+=l.length),o&&(a=o[0],i++)}return{type:"element",tagName:s||t||"div",properties:r,children:[]}}function Gi(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function Bs(e){return e.join(" ").trim()}function Fs(e,t,n){const r=n?ru(n):void 0;function i(a,s,...o){let l;if(a==null){l={type:"root",children:[]};const u=s;o.unshift(u)}else{l=Jc(a,t);const u=l.tagName.toLowerCase(),h=r?r.get(u):void 0;if(l.tagName=h||u,eu(s))o.unshift(s);else for(const[d,p]of Object.entries(s))tu(e,l.properties,d,p)}for(const u of o)Br(l.children,u);return l.type==="element"&&l.tagName==="template"&&(l.content={type:"root",children:l.children},l.children=[]),l}return i}function eu(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 tu(e,t,n,r){const i=tr(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=Gi(r):i.commaSeparated?a=Wi(r):i.commaOrSpaceSeparated?a=Gi(Wi(r).join(" ")):a=Ki(i,i.property,r):Array.isArray(r)?a=[...r]:a=i.property==="style"?nu(r):String(r);if(Array.isArray(a)){const s=[];for(const o of a)s.push(Ki(i,i.property,o));a=s}i.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[i.property]=a}}function Br(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)Br(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?Br(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function Ki(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||mn(n)===mn(t)))return!0}return n}function nu(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function ru(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}var iu=["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"],au=Fs(_n,"div"),su=Fs(ft,"g",iu);function lu(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 l=Xi(t,n[s-1]);o=l===-1?t.length+1:l+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],l=Xi(t,o),u=l===-1?t.length+1:l+1;if(o===u)break;n.push(u)}const s=(a.line>1?n[a.line-2]:0)+a.column-1;if(s<n[a.line-1])return s}}}function Xi(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/highlighted-body-OFNGDK62-BEkQLPsL.js","assets/rolldown-runtime-Bnw7wDfq.js","assets/radix-ui-C0u6gLux.js","assets/icons-BywMJ5og.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{n as Cs,r as Zn,t as bn}from"./rolldown-runtime-Bnw7wDfq.js";import{nt as xc}from"./icons-BywMJ5og.js";import{Dt as Ic,Ot as Nc}from"./radix-ui-C0u6gLux.js";import{n as ys,t as xs}from"./bundle-mjs-DkNbwow-.js";import{It as Is}from"./monaco-editor-B6TxHuqP.js";var Jn=(function(e){if(e==null)return Rc;if(typeof e=="function")return er(e);if(typeof e=="object")return Array.isArray(e)?Sc(e):wc(e);if(typeof e=="string")return Lc(e);throw new Error("Expected function, string, or object as test")});function Sc(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Jn(e[n]);return er(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function wc(e){const t=e;return er(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function Lc(e){return er(t);function t(n){return n&&n.type===e}}function er(e){return t;function t(n,r,i){return!!(Oc(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function Rc(){return!0}function Oc(e){return e!==null&&typeof e=="object"&&"type"in e}var Ns=[];var nn="skip";function si(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=Jn(i),s=r?-1:1;o(e,void 0,[])();function o(l,u,h){const d=l&&typeof l=="object"?l:{};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 ("+(l.type+(f?"<"+f+">":""))+")"})}return p;function p(){let f=Ns,E,I,S;if((!t||a(l,u,h[h.length-1]||void 0))&&(f=Dc(n(l,h)),f[0]===!1))return f;if("children"in l&&l.children){const k=l;if(k.children&&f[0]!=="skip")for(I=(r?k.children.length:-1)+s,S=h.concat(k);I>-1&&I<k.children.length;){const L=k.children[I];if(E=o(L,I,S)(),E[0]===!1)return E;I=typeof E[1]=="number"?E[1]:I+s}}return f}}}function Dc(e){return Array.isArray(e)?e:typeof e=="number"?[!0,e]:e==null?Ns:[e]}function Ke(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),si(e,a,o,i);function o(l,u){const h=u[u.length-1],d=h?h.children.indexOf(l):void 0;return s(l,d,h)}}var y=Zn(xc(),1),Ft={indicator:"indicator",textOnly:"text-only",remove:"remove"};function vc({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=Ft.indicator,imageBlockPolicy:l=Ft.indicator}){const u=t.length&&!t.every(d=>d==="*"),h=n.length&&!n.every(d=>d==="*");if(!e&&(u||h))throw new Error("defaultOrigin is required when allowedLinkPrefixes or allowedImagePrefixes are provided");return d=>{const p=Uc(e,t,n,r,i,a,s,o,l);Ss(d),Ke(d,p)}}function Ui(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 Pc(e){return typeof e!="string"?!1:e.startsWith("/")||e.startsWith("./")||e.startsWith("../")}var Mc=new Set(["https:","http:","irc:","ircs:","mailto:","xmpp:","blob:"]),Bc=new Set(["javascript:","data:","file:","vbscript:"]);function ji(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 l=e.substring(5);if(l&&l.length>0&&l!=="invalid")return e}}catch{return null}return null}const s=Ui(e,n);if(!s||Bc.has(s.protocol)||!(Mc.has(s.protocol)||a.includes(s.protocol)||a.includes("*")))return null;if(s.protocol==="mailto:"||!s.protocol.match(/^https?:$/))return s.href;const o=Pc(e);return s&&t.some(l=>{const u=Ui(l,n);return!u||u.origin!==s.origin?!1:s.href.startsWith(u.href)})?o?s.pathname+s.search+s.hash:s.href:t.includes("*")?s.protocol!=="https:"&&s.protocol!=="http:"?null:o?s.pathname+s.search+s.hash:s.href:null}function Ss(e){if("children"in e&&Array.isArray(e.children)){e.children=e.children.filter(t=>t!=null);for(const t of e.children)Ss(t)}}var fr=Symbol("node-seen");function Fc(e,t,n){return t===Ft.remove?{type:"remove"}:t===Ft.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 Hc(e,t,n){if(t===Ft.remove)return{type:"remove"};if(t===Ft.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")+"]"}]}}}var Uc=(e,t,n,r,i,a,s,o,l)=>{const u=(h,d,p)=>{if(h.type!=="element"||h[fr])return!0;if(h.tagName==="a"){const f=ji(h.properties.href,t,e,!1,!1,i);if(f===null){if(h[fr]=!0,Ke(h,u),p&&typeof d=="number"){const E=Fc(h,o,s);if(E.type==="remove")return p.children.splice(d,1),[nn,d];p.children[d]=E.element}return nn}else return h.properties.href=f,h.properties.target="_blank",h.properties.rel="noopener noreferrer",!0}if(h.tagName==="img"){const f=ji(h.properties.src,n,e,r,!0,i);if(f===null){if(h[fr]=!0,Ke(h,u),p&&typeof d=="number"){const E=Hc(h,l,a);if(E.type==="remove")return p.children.splice(d,1),[nn,d];p.children[d]=E.element}return nn}else return h.properties.src=f,!0}return!0};return u},zi=typeof self=="object"?self:globalThis,jc=(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 0:case-1:return n(s,i);case 1:{const o=n([],i);for(const l of s)o.push(r(l));return o}case 2:{const o=n({},i);for(const[l,u]of s)o[r(l)]=r(u);return o}case 3:return n(new Date(s),i);case 4:{const{source:o,flags:l}=s;return n(new RegExp(o,l),i)}case 5:{const o=n(new Map,i);for(const[l,u]of s)o.set(r(l),r(u));return o}case 6:{const o=n(new Set,i);for(const l of s)o.add(r(l));return o}case 7:{const{name:o,message:l}=s;return n(new zi[o](l),i)}case 8: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 zi[a](s),i)};return r},$i=e=>jc(new Map,e)(0),Dt="",{toString:zc}={},{keys:$c}=Object,Kt=e=>{const t=typeof e;if(t!=="object"||!e)return[0,t];const n=zc.call(e).slice(8,-1);switch(n){case"Array":return[1,Dt];case"Object":return[2,Dt];case"Date":return[3,Dt];case"RegExp":return[4,Dt];case"Map":return[5,Dt];case"Set":return[6,Dt];case"DataView":return[1,n]}return n.includes("Array")?[1,n]:n.includes("Error")?[7,n]:[2,n]},On=([e,t])=>e===0&&(t==="function"||t==="symbol"),Yc=(e,t,n,r)=>{const i=(s,o)=>{const l=r.push(s)-1;return n.set(o,l),l},a=s=>{if(n.has(s))return n.get(s);let[o,l]=Kt(s);switch(o){case 0:{let h=s;switch(l){case"bigint":o=8,h=s.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+l);h=null;break;case"undefined":return i([-1],s)}return i([o,h],s)}case 1:{if(l){let p=s;return l==="DataView"?p=new Uint8Array(s.buffer):l==="ArrayBuffer"&&(p=new Uint8Array(s)),i([l,[...p]],s)}const h=[],d=i([o,h],s);for(const p of s)h.push(a(p));return d}case 2:{if(l)switch(l){case"BigInt":return i([l,s.toString()],s);case"Boolean":case"Number":case"String":return i([l,s.valueOf()],s)}if(t&&"toJSON"in s)return a(s.toJSON());const h=[],d=i([o,h],s);for(const p of $c(s))(e||!On(Kt(s[p])))&&h.push([a(p),a(s[p])]);return d}case 3:return i([o,s.toISOString()],s);case 4:{const{source:h,flags:d}=s;return i([o,{source:h,flags:d}],s)}case 5:{const h=[],d=i([o,h],s);for(const[p,f]of s)(e||!(On(Kt(p))||On(Kt(f))))&&h.push([a(p),a(f)]);return d}case 6:{const h=[],d=i([o,h],s);for(const p of s)(e||!On(Kt(p)))&&h.push(a(p));return d}}const{message:u}=s;return i([o,{name:l,message:u}],s)};return a},Yi=(e,{json:t,lossy:n}={})=>{const r=[];return Yc(!(t||n),!!t,new Map,r)(e),r},Ct=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?$i(Yi(e,t)):structuredClone(e):(e,t)=>$i(Yi(e,t));var kn=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};kn.prototype.normal={};kn.prototype.property={};kn.prototype.space=void 0;function ws(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new kn(n,r,t)}function mn(e){return e.toLowerCase()}var Le=class{constructor(e,t){this.attribute=t,this.property=e}};Le.prototype.attribute="";Le.prototype.booleanish=!1;Le.prototype.boolean=!1;Le.prototype.commaOrSpaceSeparated=!1;Le.prototype.commaSeparated=!1;Le.prototype.defined=!1;Le.prototype.mustUseProperty=!1;Le.prototype.number=!1;Le.prototype.overloadedBoolean=!1;Le.prototype.property="";Le.prototype.spaceSeparated=!1;Le.prototype.space=void 0;var Pr=Cs({boolean:()=>G,booleanish:()=>pe,commaOrSpaceSeparated:()=>ve,commaSeparated:()=>Mt,number:()=>M,overloadedBoolean:()=>Mr,spaceSeparated:()=>le}),qc=0,G=It(),pe=It(),Mr=It(),M=It(),le=It(),Mt=It(),ve=It();function It(){return 2**++qc}var pr=Object.keys(Pr),li=class extends Le{constructor(e,t,n,r){let i=-1;if(super(e,t),qi(this,"space",r),typeof n=="number")for(;++i<pr.length;){const a=pr[i];qi(this,pr[i],(n&Pr[a])===Pr[a])}}};li.prototype.defined=!0;function qi(e,t,n){n&&(e[t]=n)}function jt(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const a=new li(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[mn(r)]=r,n[mn(a.attribute)]=r}return new kn(t,n,e.space)}var Ls=jt({properties:{ariaActiveDescendant:null,ariaAtomic:pe,ariaAutoComplete:null,ariaBusy:pe,ariaChecked:pe,ariaColCount:M,ariaColIndex:M,ariaColSpan:M,ariaControls:le,ariaCurrent:null,ariaDescribedBy:le,ariaDetails:null,ariaDisabled:pe,ariaDropEffect:le,ariaErrorMessage:null,ariaExpanded:pe,ariaFlowTo:le,ariaGrabbed:pe,ariaHasPopup:null,ariaHidden:pe,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:le,ariaLevel:M,ariaLive:null,ariaModal:pe,ariaMultiLine:pe,ariaMultiSelectable:pe,ariaOrientation:null,ariaOwns:le,ariaPlaceholder:null,ariaPosInSet:M,ariaPressed:pe,ariaReadOnly:pe,ariaRelevant:null,ariaRequired:pe,ariaRoleDescription:le,ariaRowCount:M,ariaRowIndex:M,ariaRowSpan:M,ariaSelected:pe,ariaSetSize:M,ariaSort:null,ariaValueMax:M,ariaValueMin:M,ariaValueNow:M,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function Rs(e,t){return t in e?e[t]:t}function Os(e,t){return Rs(e,t.toLowerCase())}var Vc=jt({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Mt,acceptCharset:le,accessKey:le,action:null,allow:null,allowFullScreen:G,allowPaymentRequest:G,allowUserMedia:G,alt:null,as:null,async:G,autoCapitalize:null,autoComplete:le,autoFocus:G,autoPlay:G,blocking:le,capture:null,charSet:null,checked:G,cite:null,className:le,cols:M,colSpan:null,content:null,contentEditable:pe,controls:G,controlsList:le,coords:M|Mt,crossOrigin:null,data:null,dateTime:null,decoding:null,default:G,defer:G,dir:null,dirName:null,disabled:G,download:Mr,draggable:pe,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:G,formTarget:null,headers:le,height:M,hidden:Mr,high:M,href:null,hrefLang:null,htmlFor:le,httpEquiv:le,id:null,imageSizes:null,imageSrcSet:null,inert:G,inputMode:null,integrity:null,is:null,isMap:G,itemId:null,itemProp:le,itemRef:le,itemScope:G,itemType:le,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:G,low:M,manifest:null,max:null,maxLength:M,media:null,method:null,min:null,minLength:M,multiple:G,muted:G,name:null,nonce:null,noModule:G,noValidate:G,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:G,optimum:M,pattern:null,ping:le,placeholder:null,playsInline:G,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:G,referrerPolicy:null,rel:le,required:G,reversed:G,rows:M,rowSpan:M,sandbox:le,scope:null,scoped:G,seamless:G,selected:G,shadowRootClonable:G,shadowRootDelegatesFocus:G,shadowRootMode:null,shape:null,size:M,sizes:null,slot:null,span:M,spellCheck:pe,src:null,srcDoc:null,srcLang:null,srcSet:null,start:M,step:null,style:null,tabIndex:M,target:null,title:null,translate:null,type:null,typeMustMatch:G,useMap:null,value:pe,width:M,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:le,axis:null,background:null,bgColor:null,border:M,borderColor:null,bottomMargin:M,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:G,declare:G,event:null,face:null,frame:null,frameBorder:null,hSpace:M,leftMargin:M,link:null,longDesc:null,lowSrc:null,marginHeight:M,marginWidth:M,noResize:G,noHref:G,noShade:G,noWrap:G,object:null,profile:null,prompt:null,rev:null,rightMargin:M,rules:null,scheme:null,scrolling:pe,standby:null,summary:null,text:null,topMargin:M,valueType:null,version:null,vAlign:null,vLink:null,vSpace:M,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:G,disableRemotePlayback:G,prefix:null,property:null,results:M,security:null,unselectable:null},space:"html",transform:Os}),Wc=jt({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:ve,accentHeight:M,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:M,amplitude:M,arabicForm:null,ascent:M,attributeName:null,attributeType:null,azimuth:M,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:M,by:null,calcMode:null,capHeight:M,className:le,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:M,diffuseConstant:M,direction:null,display:null,dur:null,divisor:M,dominantBaseline:null,download:G,dx:null,dy:null,edgeMode:null,editable:null,elevation:M,enableBackground:null,end:null,event:null,exponent:M,externalResourcesRequired:null,fill:null,fillOpacity:M,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:Mt,g2:Mt,glyphName:Mt,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:M,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:M,horizOriginX:M,horizOriginY:M,id:null,ideographic:M,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:M,k:M,k1:M,k2:M,k3:M,k4:M,kernelMatrix:ve,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:M,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:M,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:M,overlineThickness:M,paintOrder:null,panose1:null,path:null,pathLength:M,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:le,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:M,pointsAtY:M,pointsAtZ:M,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:ve,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:ve,rev:ve,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:ve,requiredFeatures:ve,requiredFonts:ve,requiredFormats:ve,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:M,specularExponent:M,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:M,strikethroughThickness:M,string:null,stroke:null,strokeDashArray:ve,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:M,strokeOpacity:M,strokeWidth:null,style:null,surfaceScale:M,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:ve,tabIndex:M,tableValues:null,target:null,targetX:M,targetY:M,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:ve,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:M,underlineThickness:M,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:M,values:null,vAlphabetic:M,vMathematical:M,vectorEffect:null,vHanging:M,vIdeographic:M,version:null,vertAdvY:M,vertOriginX:M,vertOriginY:M,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:M,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Rs}),Ds=jt({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()}}),vs=jt({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Os}),Ps=jt({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),Qc={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"},Gc=/[A-Z]/g,Vi=/-[a-z]/g,Kc=/^data[-\w.:]+$/i;function tr(e,t){const n=mn(t);let r=t,i=Le;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&Kc.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(Vi,Zc);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!Vi.test(a)){let s=a.replace(Gc,Xc);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}i=li}return new i(r,t)}function Xc(e){return"-"+e.toLowerCase()}function Zc(e){return e.charAt(1).toUpperCase()}var _n=ws([Ls,Vc,Ds,vs,Ps],"html"),ft=ws([Ls,Wc,Ds,vs,Ps],"svg");function Wi(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 Ms(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}var Qi=/[#.]/g;function Jc(e,t){const n=e||"",r={};let i=0,a,s;for(;i<n.length;){Qi.lastIndex=i;const o=Qi.exec(n),l=n.slice(i,o?o.index:n.length);l&&(a?a==="#"?r.id=l:Array.isArray(r.className)?r.className.push(l):r.className=[l]:s=l,i+=l.length),o&&(a=o[0],i++)}return{type:"element",tagName:s||t||"div",properties:r,children:[]}}function Gi(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function Bs(e){return e.join(" ").trim()}function Fs(e,t,n){const r=n?ru(n):void 0;function i(a,s,...o){let l;if(a==null){l={type:"root",children:[]};const u=s;o.unshift(u)}else{l=Jc(a,t);const u=l.tagName.toLowerCase(),h=r?r.get(u):void 0;if(l.tagName=h||u,eu(s))o.unshift(s);else for(const[d,p]of Object.entries(s))tu(e,l.properties,d,p)}for(const u of o)Br(l.children,u);return l.type==="element"&&l.tagName==="template"&&(l.content={type:"root",children:l.children},l.children=[]),l}return i}function eu(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 tu(e,t,n,r){const i=tr(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=Gi(r):i.commaSeparated?a=Wi(r):i.commaOrSpaceSeparated?a=Gi(Wi(r).join(" ")):a=Ki(i,i.property,r):Array.isArray(r)?a=[...r]:a=i.property==="style"?nu(r):String(r);if(Array.isArray(a)){const s=[];for(const o of a)s.push(Ki(i,i.property,o));a=s}i.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[i.property]=a}}function Br(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)Br(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?Br(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function Ki(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||mn(n)===mn(t)))return!0}return n}function nu(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function ru(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}var iu=["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"],au=Fs(_n,"div"),su=Fs(ft,"g",iu);function lu(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 l=Xi(t,n[s-1]);o=l===-1?t.length+1:l+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],l=Xi(t,o),u=l===-1?t.length+1:l+1;if(o===u)break;n.push(u)}const s=(a.line>1?n[a.line-2]:0)+a.column-1;if(s<n[a.line-1])return s}}}function Xi(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
|
|
3
3
|
`,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}var _t={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/"},Hs={}.hasOwnProperty,ou=Object.prototype;function cu(e,t){const n=t||{};return oi({file:n.file||void 0,location:!1,schema:n.space==="svg"?ft:_n,verbose:n.verbose||!1},e)}function oi(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Un(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:Us(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){const a=String(e.file),s=lu(a),o=s.toPoint(0),l=s.toPoint(a.length);n.position={start:o,end:l}}return n}case"#documentType":{const r=t;return n={type:"doctype"},Un(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Un(e,r,n),n}default:return n=uu(e,t),n}}function Us(e,t){let n=-1;const r=[];for(;++n<t.length;){const i=oi(e,t[n]);r.push(i)}return r}function uu(e,t){const n=e.schema;e.schema=t.namespaceURI===_t.svg?ft:_n;let r=-1;const i={};for(;++r<t.attrs.length;){const s=t.attrs[r],o=(s.prefix?s.prefix+":":"")+s.name;Hs.call(ou,o)||(i[o]=s.value)}const a=(e.schema.space==="svg"?su:au)(t.tagName,i,Us(e,t.childNodes));if(Un(e,t,a),a.tagName==="template"){const s=t,o=s.sourceCodeLocation,l=o&&o.startTag&&Pt(o.startTag),u=o&&o.endTag&&Pt(o.endTag),h=oi(e,s.content);l&&u&&e.file&&(h.position={start:l.end,end:u.start}),a.content=h}return e.schema=n,a}function Un(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=hu(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function hu(e,t,n){const r=Pt(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)Hs.call(n.attrs,s)&&(a[tr(e.schema,s).property]=Pt(n.attrs[s]));n.startTag;const o=Pt(n.startTag),l=n.endTag?Pt(n.endTag):void 0,u={opening:o};l&&(u.closing=l),u.properties=a,t.data={position:u}}}return r}function Pt(e){const t=Zi({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=Zi({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function Zi(e){return e.line&&e.column?e:void 0}var Ji={}.hasOwnProperty;function js(e,t){const n=t||{};function r(i,...a){let s=r.invalid;const o=r.handlers;if(i&&Ji.call(i,e)){const l=String(i[e]);s=Ji.call(o,l)?o[l]:r.unknown}if(s)return s.call(this,i,...a)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}var du={},fu={}.hasOwnProperty,zs=js("type",{handlers:{root:mu,element:ku,text:Tu,comment:bu,doctype:Eu}});function pu(e,t){const n=(t||du).space;return zs(e,n==="svg"?ft:_n)}function mu(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=ci(e.children,n,t),zt(e,n),n}function gu(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=ci(e.children,n,t),zt(e,n),n}function Eu(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return zt(e,t),t}function Tu(e){const t={nodeName:"#text",value:e.value,parentNode:null};return zt(e,t),t}function bu(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return zt(e,t),t}function ku(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=ft);const i=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&fu.call(e.properties,a)){const l=_u(r,a,e.properties[a]);l&&i.push(l)}}const s=r.space,o={nodeName:e.tagName,tagName:e.tagName,attrs:i,namespaceURI:_t[s],childNodes:[],parentNode:null};return o.childNodes=ci(e.children,o,r),zt(e,o),e.tagName==="template"&&e.content&&(o.content=gu(e.content,r)),o}function _u(e,t,n){const r=tr(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?Ms(n):Bs(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=_t[r.space]}return i}function ci(e,t,n){let r=-1;const i=[];if(e)for(;++r<e.length;){const a=zs(e[r],n);a.parentNode=t,i.push(a)}return i}function zt(e,t){const n=e.position;n&&n.start&&n.end&&(n.start.offset,n.end.offset,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})}var Au=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],Cu=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]);var m;(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"})(m||(m={}));var Se={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function $s(e){return e>=55296&&e<=57343}function yu(e){return e>=56320&&e<=57343}function xu(e,t){return(e-55296)*1024+9216+t}function Ys(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function qs(e){return e>=64976&&e<=65007||Cu.has(e)}var w;(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"})(w||(w={}));var Iu=65536,Nu=class{constructor(e){this.handler=e,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=Iu,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(e,t){const{line:n,col:r,offset:i}=this,a=r+t,s=i+t;return{code:e,startLine:n,endLine:n,startCol:a,endCol:a,startOffset:s,endOffset:s}}_err(e){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(e,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(e){if(this.pos!==this.html.length-1){const t=this.html.charCodeAt(this.pos+1);if(yu(t))return this.pos++,this._addGap(),xu(e,t)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,m.EOF;return this._err(w.surrogateInInputStream),e}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(e,t){this.html.length>0?this.html+=e:this.html=e,this.endOfChunkHit=!1,this.lastChunkWritten=t}insertHtmlAtCurrentPos(e){this.html=this.html.substring(0,this.pos+1)+e+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(e,t){if(this.pos+e.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(t)return this.html.startsWith(e,this.pos);for(let n=0;n<e.length;n++)if((this.html.charCodeAt(this.pos+n)|32)!==e.charCodeAt(n))return!1;return!0}peek(e){const t=this.pos+e;if(t>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,m.EOF;const n=this.html.charCodeAt(t);return n===m.CARRIAGE_RETURN?m.LINE_FEED:n}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,m.EOF;let e=this.html.charCodeAt(this.pos);return e===m.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,m.LINE_FEED):e===m.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,$s(e)&&(e=this._processSurrogate(e)),this.handler.onParseError===null||e>31&&e<127||e===m.LINE_FEED||e===m.CARRIAGE_RETURN||e>159&&e<64976||this._checkForProblematicCharacters(e),e)}_checkForProblematicCharacters(e){Ys(e)?this._err(w.controlCharacterInInputStream):qs(e)&&this._err(w.noncharacterInInputStream)}retreat(e){for(this.pos-=e;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}},K;(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"})(K||(K={}));function Vs(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}var Su=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))),mr,wu=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]]),GA=(mr=String.fromCodePoint)!==null&&mr!==void 0?mr:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|e&1023),t+=String.fromCharCode(e),t};function Lu(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=wu.get(e))!==null&&t!==void 0?t:e}var Ee;(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"})(Ee||(Ee={}));var Ru=32,ut;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(ut||(ut={}));function Fr(e){return e>=Ee.ZERO&&e<=Ee.NINE}function Ou(e){return e>=Ee.UPPER_A&&e<=Ee.UPPER_F||e>=Ee.LOWER_A&&e<=Ee.LOWER_F}function Du(e){return e>=Ee.UPPER_A&&e<=Ee.UPPER_Z||e>=Ee.LOWER_A&&e<=Ee.LOWER_Z||Fr(e)}function vu(e){return e===Ee.EQUALS||Du(e)}var ge;(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"})(ge||(ge={}));var nt;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(nt||(nt={}));var Pu=class{constructor(e,t,n){this.decodeTree=e,this.emitCodePoint=t,this.errors=n,this.state=ge.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=nt.Strict}startEntity(e){this.decodeMode=e,this.state=ge.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(e,t){switch(this.state){case ge.EntityStart:return e.charCodeAt(t)===Ee.NUM?(this.state=ge.NumericStart,this.consumed+=1,this.stateNumericStart(e,t+1)):(this.state=ge.NamedEntity,this.stateNamedEntity(e,t));case ge.NumericStart:return this.stateNumericStart(e,t);case ge.NumericDecimal:return this.stateNumericDecimal(e,t);case ge.NumericHex:return this.stateNumericHex(e,t);case ge.NamedEntity:return this.stateNamedEntity(e,t)}}stateNumericStart(e,t){return t>=e.length?-1:(e.charCodeAt(t)|Ru)===Ee.LOWER_X?(this.state=ge.NumericHex,this.consumed+=1,this.stateNumericHex(e,t+1)):(this.state=ge.NumericDecimal,this.stateNumericDecimal(e,t))}addToNumericResult(e,t,n,r){if(t!==n){const i=n-t;this.result=this.result*Math.pow(r,i)+Number.parseInt(e.substr(t,i),r),this.consumed+=i}}stateNumericHex(e,t){const n=t;for(;t<e.length;){const r=e.charCodeAt(t);if(Fr(r)||Ou(r))t+=1;else return this.addToNumericResult(e,n,t,16),this.emitNumericEntity(r,3)}return this.addToNumericResult(e,n,t,16),-1}stateNumericDecimal(e,t){const n=t;for(;t<e.length;){const r=e.charCodeAt(t);if(Fr(r))t+=1;else return this.addToNumericResult(e,n,t,10),this.emitNumericEntity(r,2)}return this.addToNumericResult(e,n,t,10),-1}emitNumericEntity(e,t){var n;if(this.consumed<=t)return(n=this.errors)===null||n===void 0||n.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(e===Ee.SEMI)this.consumed+=1;else if(this.decodeMode===nt.Strict)return 0;return this.emitCodePoint(Lu(this.result),this.consumed),this.errors&&(e!==Ee.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(e,t){const{decodeTree:n}=this;let r=n[this.treeIndex],i=(r&ut.VALUE_LENGTH)>>14;for(;t<e.length;t++,this.excess++){const a=e.charCodeAt(t);if(this.treeIndex=Mu(n,r,this.treeIndex+Math.max(1,i),a),this.treeIndex<0)return this.result===0||this.decodeMode===nt.Attribute&&(i===0||vu(a))?0:this.emitNotTerminatedNamedEntity();if(r=n[this.treeIndex],i=(r&ut.VALUE_LENGTH)>>14,i!==0){if(a===Ee.SEMI)return this.emitNamedEntityData(this.treeIndex,i,this.consumed+this.excess);this.decodeMode!==nt.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var e;const{result:t,decodeTree:n}=this,r=(n[t]&ut.VALUE_LENGTH)>>14;return this.emitNamedEntityData(t,r,this.consumed),(e=this.errors)===null||e===void 0||e.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(e,t,n){const{decodeTree:r}=this;return this.emitCodePoint(t===1?r[e]&~ut.VALUE_LENGTH:r[e+1],n),t===3&&this.emitCodePoint(r[e+2],n),n}end(){var e;switch(this.state){case ge.NamedEntity:return this.result!==0&&(this.decodeMode!==nt.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case ge.NumericDecimal:return this.emitNumericEntity(0,2);case ge.NumericHex:return this.emitNumericEntity(0,3);case ge.NumericStart:return(e=this.errors)===null||e===void 0||e.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case ge.EntityStart:return 0}}};function Mu(e,t,n,r){const i=(t&ut.BRANCH_LENGTH)>>7,a=t&ut.JUMP_TABLE;if(i===0)return a!==0&&r===a?n:-1;if(a){const l=r-a;return l<0||l>=i?-1:e[n+l]-1}let s=n,o=s+i-1;for(;s<=o;){const l=s+o>>>1,u=e[l];if(u<r)s=l+1;else if(u>r)o=l-1;else return e[l+i]}return-1}var D;(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/"})(D||(D={}));var At;(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"})(At||(At={}));var Fe;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Fe||(Fe={}));var C;(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"})(C||(C={}));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={}));var Bu=new Map([[C.A,c.A],[C.ADDRESS,c.ADDRESS],[C.ANNOTATION_XML,c.ANNOTATION_XML],[C.APPLET,c.APPLET],[C.AREA,c.AREA],[C.ARTICLE,c.ARTICLE],[C.ASIDE,c.ASIDE],[C.B,c.B],[C.BASE,c.BASE],[C.BASEFONT,c.BASEFONT],[C.BGSOUND,c.BGSOUND],[C.BIG,c.BIG],[C.BLOCKQUOTE,c.BLOCKQUOTE],[C.BODY,c.BODY],[C.BR,c.BR],[C.BUTTON,c.BUTTON],[C.CAPTION,c.CAPTION],[C.CENTER,c.CENTER],[C.CODE,c.CODE],[C.COL,c.COL],[C.COLGROUP,c.COLGROUP],[C.DD,c.DD],[C.DESC,c.DESC],[C.DETAILS,c.DETAILS],[C.DIALOG,c.DIALOG],[C.DIR,c.DIR],[C.DIV,c.DIV],[C.DL,c.DL],[C.DT,c.DT],[C.EM,c.EM],[C.EMBED,c.EMBED],[C.FIELDSET,c.FIELDSET],[C.FIGCAPTION,c.FIGCAPTION],[C.FIGURE,c.FIGURE],[C.FONT,c.FONT],[C.FOOTER,c.FOOTER],[C.FOREIGN_OBJECT,c.FOREIGN_OBJECT],[C.FORM,c.FORM],[C.FRAME,c.FRAME],[C.FRAMESET,c.FRAMESET],[C.H1,c.H1],[C.H2,c.H2],[C.H3,c.H3],[C.H4,c.H4],[C.H5,c.H5],[C.H6,c.H6],[C.HEAD,c.HEAD],[C.HEADER,c.HEADER],[C.HGROUP,c.HGROUP],[C.HR,c.HR],[C.HTML,c.HTML],[C.I,c.I],[C.IMG,c.IMG],[C.IMAGE,c.IMAGE],[C.INPUT,c.INPUT],[C.IFRAME,c.IFRAME],[C.KEYGEN,c.KEYGEN],[C.LABEL,c.LABEL],[C.LI,c.LI],[C.LINK,c.LINK],[C.LISTING,c.LISTING],[C.MAIN,c.MAIN],[C.MALIGNMARK,c.MALIGNMARK],[C.MARQUEE,c.MARQUEE],[C.MATH,c.MATH],[C.MENU,c.MENU],[C.META,c.META],[C.MGLYPH,c.MGLYPH],[C.MI,c.MI],[C.MO,c.MO],[C.MN,c.MN],[C.MS,c.MS],[C.MTEXT,c.MTEXT],[C.NAV,c.NAV],[C.NOBR,c.NOBR],[C.NOFRAMES,c.NOFRAMES],[C.NOEMBED,c.NOEMBED],[C.NOSCRIPT,c.NOSCRIPT],[C.OBJECT,c.OBJECT],[C.OL,c.OL],[C.OPTGROUP,c.OPTGROUP],[C.OPTION,c.OPTION],[C.P,c.P],[C.PARAM,c.PARAM],[C.PLAINTEXT,c.PLAINTEXT],[C.PRE,c.PRE],[C.RB,c.RB],[C.RP,c.RP],[C.RT,c.RT],[C.RTC,c.RTC],[C.RUBY,c.RUBY],[C.S,c.S],[C.SCRIPT,c.SCRIPT],[C.SEARCH,c.SEARCH],[C.SECTION,c.SECTION],[C.SELECT,c.SELECT],[C.SOURCE,c.SOURCE],[C.SMALL,c.SMALL],[C.SPAN,c.SPAN],[C.STRIKE,c.STRIKE],[C.STRONG,c.STRONG],[C.STYLE,c.STYLE],[C.SUB,c.SUB],[C.SUMMARY,c.SUMMARY],[C.SUP,c.SUP],[C.TABLE,c.TABLE],[C.TBODY,c.TBODY],[C.TEMPLATE,c.TEMPLATE],[C.TEXTAREA,c.TEXTAREA],[C.TFOOT,c.TFOOT],[C.TD,c.TD],[C.TH,c.TH],[C.THEAD,c.THEAD],[C.TITLE,c.TITLE],[C.TR,c.TR],[C.TRACK,c.TRACK],[C.TT,c.TT],[C.U,c.U],[C.UL,c.UL],[C.SVG,c.SVG],[C.VAR,c.VAR],[C.WBR,c.WBR],[C.XMP,c.XMP]]);function $t(e){var t;return(t=Bu.get(e))!==null&&t!==void 0?t:c.UNKNOWN}var v=c,Fu={[D.HTML]:new Set([v.ADDRESS,v.APPLET,v.AREA,v.ARTICLE,v.ASIDE,v.BASE,v.BASEFONT,v.BGSOUND,v.BLOCKQUOTE,v.BODY,v.BR,v.BUTTON,v.CAPTION,v.CENTER,v.COL,v.COLGROUP,v.DD,v.DETAILS,v.DIR,v.DIV,v.DL,v.DT,v.EMBED,v.FIELDSET,v.FIGCAPTION,v.FIGURE,v.FOOTER,v.FORM,v.FRAME,v.FRAMESET,v.H1,v.H2,v.H3,v.H4,v.H5,v.H6,v.HEAD,v.HEADER,v.HGROUP,v.HR,v.HTML,v.IFRAME,v.IMG,v.INPUT,v.LI,v.LINK,v.LISTING,v.MAIN,v.MARQUEE,v.MENU,v.META,v.NAV,v.NOEMBED,v.NOFRAMES,v.NOSCRIPT,v.OBJECT,v.OL,v.P,v.PARAM,v.PLAINTEXT,v.PRE,v.SCRIPT,v.SECTION,v.SELECT,v.SOURCE,v.STYLE,v.SUMMARY,v.TABLE,v.TBODY,v.TD,v.TEMPLATE,v.TEXTAREA,v.TFOOT,v.TH,v.THEAD,v.TITLE,v.TR,v.TRACK,v.UL,v.WBR,v.XMP]),[D.MATHML]:new Set([v.MI,v.MO,v.MN,v.MS,v.MTEXT,v.ANNOTATION_XML]),[D.SVG]:new Set([v.TITLE,v.FOREIGN_OBJECT,v.DESC]),[D.XLINK]:new Set,[D.XML]:new Set,[D.XMLNS]:new Set},Hr=new Set([v.H1,v.H2,v.H3,v.H4,v.H5,v.H6]),KA=new Set([C.STYLE,C.SCRIPT,C.XMP,C.IFRAME,C.NOEMBED,C.NOFRAMES,C.PLAINTEXT]),g;(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"})(g||(g={}));var de={DATA:g.DATA,RCDATA:g.RCDATA,RAWTEXT:g.RAWTEXT,SCRIPT_DATA:g.SCRIPT_DATA,PLAINTEXT:g.PLAINTEXT,CDATA_SECTION:g.CDATA_SECTION};function Hu(e){return e>=m.DIGIT_0&&e<=m.DIGIT_9}function rn(e){return e>=m.LATIN_CAPITAL_A&&e<=m.LATIN_CAPITAL_Z}function Uu(e){return e>=m.LATIN_SMALL_A&&e<=m.LATIN_SMALL_Z}function lt(e){return Uu(e)||rn(e)}function ea(e){return lt(e)||Hu(e)}function Dn(e){return e+32}function Ws(e){return e===m.SPACE||e===m.LINE_FEED||e===m.TABULATION||e===m.FORM_FEED}function ta(e){return Ws(e)||e===m.SOLIDUS||e===m.GREATER_THAN_SIGN}function ju(e){return e===m.NULL?w.nullCharacterReference:e>1114111?w.characterReferenceOutsideUnicodeRange:$s(e)?w.surrogateCharacterReference:qs(e)?w.noncharacterCharacterReference:Ys(e)||e===m.CARRIAGE_RETURN?w.controlCharacterReference:null}var zu=class{constructor(e,t){this.options=e,this.handler=t,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=g.DATA,this.returnState=g.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new Nu(t),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new Pu(Su,(n,r)=>{this.preprocessor.pos=this.entityStartPos+r-1,this._flushCodePointConsumedAsCharacterReference(n)},t.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(w.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:n=>{this._err(w.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+n)},validateNumericCharacterReference:n=>{const r=ju(n);r&&this._err(r,1)}}:void 0)}_err(e,t=0){var n,r;(r=(n=this.handler).onParseError)===null||r===void 0||r.call(n,this.preprocessor.getError(e,t))}getCurrentLocation(e){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-e,startOffset:this.preprocessor.offset-e,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const e=this._consume();this._ensureHibernation()||this._callState(e)}this.inLoop=!1}}pause(){this.paused=!0}resume(e){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||e?.())}write(e,t,n){this.active=!0,this.preprocessor.write(e,t),this._runParsingLoop(),this.paused||n?.()}insertHtmlAtCurrentPos(e){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(e),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(e){this.consumedAfterSnapshot+=e;for(let t=0;t<e;t++)this.preprocessor.advance()}_consumeSequenceIfMatch(e,t){return this.preprocessor.startsWith(e,t)?(this._advanceBy(e.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:K.START_TAG,tagName:"",tagID:c.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:K.END_TAG,tagName:"",tagID:c.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(e){this.currentToken={type:K.COMMENT,data:"",location:this.getCurrentLocation(e)}}_createDoctypeToken(e){this.currentToken={type:K.DOCTYPE,name:e,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(e,t){this.currentCharacterToken={type:e,chars:t,location:this.currentLocation}}_createAttr(e){this.currentAttr={name:e,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var e,t;const n=this.currentToken;if(Vs(n,this.currentAttr.name)===null){if(n.attrs.push(this.currentAttr),n.location&&this.currentLocation){const r=(e=(t=n.location).attrs)!==null&&e!==void 0?e:t.attrs=Object.create(null);r[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(w.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(e){this._emitCurrentCharacterToken(e.location),this.currentToken=null,e.location&&(e.location.endLine=this.preprocessor.line,e.location.endCol=this.preprocessor.col+1,e.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const e=this.currentToken;this.prepareToken(e),e.tagID=$t(e.tagName),e.type===K.START_TAG?(this.lastStartTagName=e.tagName,this.handler.onStartTag(e)):(e.attrs.length>0&&this._err(w.endTagWithAttributes),e.selfClosing&&this._err(w.endTagWithTrailingSolidus),this.handler.onEndTag(e)),this.preprocessor.dropParsedChunk()}emitCurrentComment(e){this.prepareToken(e),this.handler.onComment(e),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(e){this.prepareToken(e),this.handler.onDoctype(e),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(e){if(this.currentCharacterToken){switch(e&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=e.startLine,this.currentCharacterToken.location.endCol=e.startCol,this.currentCharacterToken.location.endOffset=e.startOffset),this.currentCharacterToken.type){case K.CHARACTER:this.handler.onCharacter(this.currentCharacterToken);break;case K.NULL_CHARACTER:this.handler.onNullCharacter(this.currentCharacterToken);break;case K.WHITESPACE_CHARACTER:this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}this.currentCharacterToken=null}}_emitEOFToken(){const e=this.getCurrentLocation(0);e&&(e.endLine=e.startLine,e.endCol=e.startCol,e.endOffset=e.startOffset),this._emitCurrentCharacterToken(e),this.handler.onEof({type:K.EOF,location:e}),this.active=!1}_appendCharToCurrentCharacterToken(e,t){if(this.currentCharacterToken)if(this.currentCharacterToken.type===e){this.currentCharacterToken.chars+=t;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(e,t)}_emitCodePoint(e){const t=Ws(e)?K.WHITESPACE_CHARACTER:e===m.NULL?K.NULL_CHARACTER:K.CHARACTER;this._appendCharToCurrentCharacterToken(t,String.fromCodePoint(e))}_emitChars(e){this._appendCharToCurrentCharacterToken(K.CHARACTER,e)}_startCharacterReference(){this.returnState=this.state,this.state=g.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?nt.Attribute:nt.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===g.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===g.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===g.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(e){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(e):this._emitCodePoint(e)}_callState(e){switch(this.state){case g.DATA:this._stateData(e);break;case g.RCDATA:this._stateRcdata(e);break;case g.RAWTEXT:this._stateRawtext(e);break;case g.SCRIPT_DATA:this._stateScriptData(e);break;case g.PLAINTEXT:this._statePlaintext(e);break;case g.TAG_OPEN:this._stateTagOpen(e);break;case g.END_TAG_OPEN:this._stateEndTagOpen(e);break;case g.TAG_NAME:this._stateTagName(e);break;case g.RCDATA_LESS_THAN_SIGN:this._stateRcdataLessThanSign(e);break;case g.RCDATA_END_TAG_OPEN:this._stateRcdataEndTagOpen(e);break;case g.RCDATA_END_TAG_NAME:this._stateRcdataEndTagName(e);break;case g.RAWTEXT_LESS_THAN_SIGN:this._stateRawtextLessThanSign(e);break;case g.RAWTEXT_END_TAG_OPEN:this._stateRawtextEndTagOpen(e);break;case g.RAWTEXT_END_TAG_NAME:this._stateRawtextEndTagName(e);break;case g.SCRIPT_DATA_LESS_THAN_SIGN:this._stateScriptDataLessThanSign(e);break;case g.SCRIPT_DATA_END_TAG_OPEN:this._stateScriptDataEndTagOpen(e);break;case g.SCRIPT_DATA_END_TAG_NAME:this._stateScriptDataEndTagName(e);break;case g.SCRIPT_DATA_ESCAPE_START:this._stateScriptDataEscapeStart(e);break;case g.SCRIPT_DATA_ESCAPE_START_DASH:this._stateScriptDataEscapeStartDash(e);break;case g.SCRIPT_DATA_ESCAPED:this._stateScriptDataEscaped(e);break;case g.SCRIPT_DATA_ESCAPED_DASH:this._stateScriptDataEscapedDash(e);break;case g.SCRIPT_DATA_ESCAPED_DASH_DASH:this._stateScriptDataEscapedDashDash(e);break;case g.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:this._stateScriptDataEscapedLessThanSign(e);break;case g.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:this._stateScriptDataEscapedEndTagOpen(e);break;case g.SCRIPT_DATA_ESCAPED_END_TAG_NAME:this._stateScriptDataEscapedEndTagName(e);break;case g.SCRIPT_DATA_DOUBLE_ESCAPE_START:this._stateScriptDataDoubleEscapeStart(e);break;case g.SCRIPT_DATA_DOUBLE_ESCAPED:this._stateScriptDataDoubleEscaped(e);break;case g.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:this._stateScriptDataDoubleEscapedDash(e);break;case g.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:this._stateScriptDataDoubleEscapedDashDash(e);break;case g.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:this._stateScriptDataDoubleEscapedLessThanSign(e);break;case g.SCRIPT_DATA_DOUBLE_ESCAPE_END:this._stateScriptDataDoubleEscapeEnd(e);break;case g.BEFORE_ATTRIBUTE_NAME:this._stateBeforeAttributeName(e);break;case g.ATTRIBUTE_NAME:this._stateAttributeName(e);break;case g.AFTER_ATTRIBUTE_NAME:this._stateAfterAttributeName(e);break;case g.BEFORE_ATTRIBUTE_VALUE:this._stateBeforeAttributeValue(e);break;case g.ATTRIBUTE_VALUE_DOUBLE_QUOTED:this._stateAttributeValueDoubleQuoted(e);break;case g.ATTRIBUTE_VALUE_SINGLE_QUOTED:this._stateAttributeValueSingleQuoted(e);break;case g.ATTRIBUTE_VALUE_UNQUOTED:this._stateAttributeValueUnquoted(e);break;case g.AFTER_ATTRIBUTE_VALUE_QUOTED:this._stateAfterAttributeValueQuoted(e);break;case g.SELF_CLOSING_START_TAG:this._stateSelfClosingStartTag(e);break;case g.BOGUS_COMMENT:this._stateBogusComment(e);break;case g.MARKUP_DECLARATION_OPEN:this._stateMarkupDeclarationOpen(e);break;case g.COMMENT_START:this._stateCommentStart(e);break;case g.COMMENT_START_DASH:this._stateCommentStartDash(e);break;case g.COMMENT:this._stateComment(e);break;case g.COMMENT_LESS_THAN_SIGN:this._stateCommentLessThanSign(e);break;case g.COMMENT_LESS_THAN_SIGN_BANG:this._stateCommentLessThanSignBang(e);break;case g.COMMENT_LESS_THAN_SIGN_BANG_DASH:this._stateCommentLessThanSignBangDash(e);break;case g.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:this._stateCommentLessThanSignBangDashDash(e);break;case g.COMMENT_END_DASH:this._stateCommentEndDash(e);break;case g.COMMENT_END:this._stateCommentEnd(e);break;case g.COMMENT_END_BANG:this._stateCommentEndBang(e);break;case g.DOCTYPE:this._stateDoctype(e);break;case g.BEFORE_DOCTYPE_NAME:this._stateBeforeDoctypeName(e);break;case g.DOCTYPE_NAME:this._stateDoctypeName(e);break;case g.AFTER_DOCTYPE_NAME:this._stateAfterDoctypeName(e);break;case g.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._stateAfterDoctypePublicKeyword(e);break;case g.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:this._stateBeforeDoctypePublicIdentifier(e);break;case g.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:this._stateDoctypePublicIdentifierDoubleQuoted(e);break;case g.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:this._stateDoctypePublicIdentifierSingleQuoted(e);break;case g.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:this._stateAfterDoctypePublicIdentifier(e);break;case g.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:this._stateBetweenDoctypePublicAndSystemIdentifiers(e);break;case g.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._stateAfterDoctypeSystemKeyword(e);break;case g.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:this._stateBeforeDoctypeSystemIdentifier(e);break;case g.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:this._stateDoctypeSystemIdentifierDoubleQuoted(e);break;case g.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:this._stateDoctypeSystemIdentifierSingleQuoted(e);break;case g.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:this._stateAfterDoctypeSystemIdentifier(e);break;case g.BOGUS_DOCTYPE:this._stateBogusDoctype(e);break;case g.CDATA_SECTION:this._stateCdataSection(e);break;case g.CDATA_SECTION_BRACKET:this._stateCdataSectionBracket(e);break;case g.CDATA_SECTION_END:this._stateCdataSectionEnd(e);break;case g.CHARACTER_REFERENCE:this._stateCharacterReference();break;case g.AMBIGUOUS_AMPERSAND:this._stateAmbiguousAmpersand(e);break;default:throw new Error("Unknown state")}}_stateData(e){switch(e){case m.LESS_THAN_SIGN:this.state=g.TAG_OPEN;break;case m.AMPERSAND:this._startCharacterReference();break;case m.NULL:this._err(w.unexpectedNullCharacter),this._emitCodePoint(e);break;case m.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateRcdata(e){switch(e){case m.AMPERSAND:this._startCharacterReference();break;case m.LESS_THAN_SIGN:this.state=g.RCDATA_LESS_THAN_SIGN;break;case m.NULL:this._err(w.unexpectedNullCharacter),this._emitChars("�");break;case m.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateRawtext(e){switch(e){case m.LESS_THAN_SIGN:this.state=g.RAWTEXT_LESS_THAN_SIGN;break;case m.NULL:this._err(w.unexpectedNullCharacter),this._emitChars("�");break;case m.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptData(e){switch(e){case m.LESS_THAN_SIGN:this.state=g.SCRIPT_DATA_LESS_THAN_SIGN;break;case m.NULL:this._err(w.unexpectedNullCharacter),this._emitChars("�");break;case m.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_statePlaintext(e){switch(e){case m.NULL:this._err(w.unexpectedNullCharacter),this._emitChars("�");break;case m.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateTagOpen(e){if(lt(e))this._createStartTagToken(),this.state=g.TAG_NAME,this._stateTagName(e);else switch(e){case m.EXCLAMATION_MARK:this.state=g.MARKUP_DECLARATION_OPEN;break;case m.SOLIDUS:this.state=g.END_TAG_OPEN;break;case m.QUESTION_MARK:this._err(w.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=g.BOGUS_COMMENT,this._stateBogusComment(e);break;case m.EOF:this._err(w.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break;default:this._err(w.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=g.DATA,this._stateData(e)}}_stateEndTagOpen(e){if(lt(e))this._createEndTagToken(),this.state=g.TAG_NAME,this._stateTagName(e);else switch(e){case m.GREATER_THAN_SIGN:this._err(w.missingEndTagName),this.state=g.DATA;break;case m.EOF:this._err(w.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break;default:this._err(w.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=g.BOGUS_COMMENT,this._stateBogusComment(e)}}_stateTagName(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:this.state=g.BEFORE_ATTRIBUTE_NAME;break;case m.SOLIDUS:this.state=g.SELF_CLOSING_START_TAG;break;case m.GREATER_THAN_SIGN:this.state=g.DATA,this.emitCurrentTagToken();break;case m.NULL:this._err(w.unexpectedNullCharacter),t.tagName+="�";break;case m.EOF:this._err(w.eofInTag),this._emitEOFToken();break;default:t.tagName+=String.fromCodePoint(rn(e)?Dn(e):e)}}_stateRcdataLessThanSign(e){e===m.SOLIDUS?this.state=g.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=g.RCDATA,this._stateRcdata(e))}_stateRcdataEndTagOpen(e){lt(e)?(this.state=g.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(e)):(this._emitChars("</"),this.state=g.RCDATA,this._stateRcdata(e))}handleSpecialEndTag(e){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const t=this.currentToken;switch(t.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=g.BEFORE_ATTRIBUTE_NAME,!1;case m.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=g.SELF_CLOSING_START_TAG,!1;case m.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=g.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars("</"),this.state=g.RCDATA,this._stateRcdata(e))}_stateRawtextLessThanSign(e){e===m.SOLIDUS?this.state=g.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=g.RAWTEXT,this._stateRawtext(e))}_stateRawtextEndTagOpen(e){lt(e)?(this.state=g.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(e)):(this._emitChars("</"),this.state=g.RAWTEXT,this._stateRawtext(e))}_stateRawtextEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars("</"),this.state=g.RAWTEXT,this._stateRawtext(e))}_stateScriptDataLessThanSign(e){switch(e){case m.SOLIDUS:this.state=g.SCRIPT_DATA_END_TAG_OPEN;break;case m.EXCLAMATION_MARK:this.state=g.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break;default:this._emitChars("<"),this.state=g.SCRIPT_DATA,this._stateScriptData(e)}}_stateScriptDataEndTagOpen(e){lt(e)?(this.state=g.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(e)):(this._emitChars("</"),this.state=g.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars("</"),this.state=g.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscapeStart(e){e===m.HYPHEN_MINUS?(this.state=g.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=g.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscapeStartDash(e){e===m.HYPHEN_MINUS?(this.state=g.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=g.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscaped(e){switch(e){case m.HYPHEN_MINUS:this.state=g.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break;case m.LESS_THAN_SIGN:this.state=g.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case m.NULL:this._err(w.unexpectedNullCharacter),this._emitChars("�");break;case m.EOF:this._err(w.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptDataEscapedDash(e){switch(e){case m.HYPHEN_MINUS:this.state=g.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break;case m.LESS_THAN_SIGN:this.state=g.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case m.NULL:this._err(w.unexpectedNullCharacter),this.state=g.SCRIPT_DATA_ESCAPED,this._emitChars("�");break;case m.EOF:this._err(w.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=g.SCRIPT_DATA_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataEscapedDashDash(e){switch(e){case m.HYPHEN_MINUS:this._emitChars("-");break;case m.LESS_THAN_SIGN:this.state=g.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case m.GREATER_THAN_SIGN:this.state=g.SCRIPT_DATA,this._emitChars(">");break;case m.NULL:this._err(w.unexpectedNullCharacter),this.state=g.SCRIPT_DATA_ESCAPED,this._emitChars("�");break;case m.EOF:this._err(w.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=g.SCRIPT_DATA_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataEscapedLessThanSign(e){e===m.SOLIDUS?this.state=g.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:lt(e)?(this._emitChars("<"),this.state=g.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(e)):(this._emitChars("<"),this.state=g.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataEscapedEndTagOpen(e){lt(e)?(this.state=g.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(e)):(this._emitChars("</"),this.state=g.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataEscapedEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars("</"),this.state=g.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataDoubleEscapeStart(e){if(this.preprocessor.startsWith(Se.SCRIPT,!1)&&ta(this.preprocessor.peek(Se.SCRIPT.length))){this._emitCodePoint(e);for(let t=0;t<Se.SCRIPT.length;t++)this._emitCodePoint(this._consume());this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=g.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataDoubleEscaped(e){switch(e){case m.HYPHEN_MINUS:this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break;case m.LESS_THAN_SIGN:this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break;case m.NULL:this._err(w.unexpectedNullCharacter),this._emitChars("�");break;case m.EOF:this._err(w.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedDash(e){switch(e){case m.HYPHEN_MINUS:this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break;case m.LESS_THAN_SIGN:this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break;case m.NULL:this._err(w.unexpectedNullCharacter),this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars("�");break;case m.EOF:this._err(w.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedDashDash(e){switch(e){case m.HYPHEN_MINUS:this._emitChars("-");break;case m.LESS_THAN_SIGN:this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break;case m.GREATER_THAN_SIGN:this.state=g.SCRIPT_DATA,this._emitChars(">");break;case m.NULL:this._err(w.unexpectedNullCharacter),this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars("�");break;case m.EOF:this._err(w.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedLessThanSign(e){e===m.SOLIDUS?(this.state=g.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(e))}_stateScriptDataDoubleEscapeEnd(e){if(this.preprocessor.startsWith(Se.SCRIPT,!1)&&ta(this.preprocessor.peek(Se.SCRIPT.length))){this._emitCodePoint(e);for(let t=0;t<Se.SCRIPT.length;t++)this._emitCodePoint(this._consume());this.state=g.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=g.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(e))}_stateBeforeAttributeName(e){switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.SOLIDUS:case m.GREATER_THAN_SIGN:case m.EOF:this.state=g.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(e);break;case m.EQUALS_SIGN:this._err(w.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=g.ATTRIBUTE_NAME;break;default:this._createAttr(""),this.state=g.ATTRIBUTE_NAME,this._stateAttributeName(e)}}_stateAttributeName(e){switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:case m.SOLIDUS:case m.GREATER_THAN_SIGN:case m.EOF:this._leaveAttrName(),this.state=g.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(e);break;case m.EQUALS_SIGN:this._leaveAttrName(),this.state=g.BEFORE_ATTRIBUTE_VALUE;break;case m.QUOTATION_MARK:case m.APOSTROPHE:case m.LESS_THAN_SIGN:this._err(w.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(e);break;case m.NULL:this._err(w.unexpectedNullCharacter),this.currentAttr.name+="�";break;default:this.currentAttr.name+=String.fromCodePoint(rn(e)?Dn(e):e)}}_stateAfterAttributeName(e){switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.SOLIDUS:this.state=g.SELF_CLOSING_START_TAG;break;case m.EQUALS_SIGN:this.state=g.BEFORE_ATTRIBUTE_VALUE;break;case m.GREATER_THAN_SIGN:this.state=g.DATA,this.emitCurrentTagToken();break;case m.EOF:this._err(w.eofInTag),this._emitEOFToken();break;default:this._createAttr(""),this.state=g.ATTRIBUTE_NAME,this._stateAttributeName(e)}}_stateBeforeAttributeValue(e){switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:this.state=g.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break;case m.APOSTROPHE:this.state=g.ATTRIBUTE_VALUE_SINGLE_QUOTED;break;case m.GREATER_THAN_SIGN:this._err(w.missingAttributeValue),this.state=g.DATA,this.emitCurrentTagToken();break;default:this.state=g.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(e)}}_stateAttributeValueDoubleQuoted(e){switch(e){case m.QUOTATION_MARK:this.state=g.AFTER_ATTRIBUTE_VALUE_QUOTED;break;case m.AMPERSAND:this._startCharacterReference();break;case m.NULL:this._err(w.unexpectedNullCharacter),this.currentAttr.value+="�";break;case m.EOF:this._err(w.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAttributeValueSingleQuoted(e){switch(e){case m.APOSTROPHE:this.state=g.AFTER_ATTRIBUTE_VALUE_QUOTED;break;case m.AMPERSAND:this._startCharacterReference();break;case m.NULL:this._err(w.unexpectedNullCharacter),this.currentAttr.value+="�";break;case m.EOF:this._err(w.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAttributeValueUnquoted(e){switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:this._leaveAttrValue(),this.state=g.BEFORE_ATTRIBUTE_NAME;break;case m.AMPERSAND:this._startCharacterReference();break;case m.GREATER_THAN_SIGN:this._leaveAttrValue(),this.state=g.DATA,this.emitCurrentTagToken();break;case m.NULL:this._err(w.unexpectedNullCharacter),this.currentAttr.value+="�";break;case m.QUOTATION_MARK:case m.APOSTROPHE:case m.LESS_THAN_SIGN:case m.EQUALS_SIGN:case m.GRAVE_ACCENT:this._err(w.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(e);break;case m.EOF:this._err(w.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAfterAttributeValueQuoted(e){switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:this._leaveAttrValue(),this.state=g.BEFORE_ATTRIBUTE_NAME;break;case m.SOLIDUS:this._leaveAttrValue(),this.state=g.SELF_CLOSING_START_TAG;break;case m.GREATER_THAN_SIGN:this._leaveAttrValue(),this.state=g.DATA,this.emitCurrentTagToken();break;case m.EOF:this._err(w.eofInTag),this._emitEOFToken();break;default:this._err(w.missingWhitespaceBetweenAttributes),this.state=g.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(e)}}_stateSelfClosingStartTag(e){switch(e){case m.GREATER_THAN_SIGN:{const t=this.currentToken;t.selfClosing=!0,this.state=g.DATA,this.emitCurrentTagToken();break}case m.EOF:this._err(w.eofInTag),this._emitEOFToken();break;default:this._err(w.unexpectedSolidusInTag),this.state=g.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(e)}}_stateBogusComment(e){const t=this.currentToken;switch(e){case m.GREATER_THAN_SIGN:this.state=g.DATA,this.emitCurrentComment(t);break;case m.EOF:this.emitCurrentComment(t),this._emitEOFToken();break;case m.NULL:this._err(w.unexpectedNullCharacter),t.data+="�";break;default:t.data+=String.fromCodePoint(e)}}_stateMarkupDeclarationOpen(e){this._consumeSequenceIfMatch(Se.DASH_DASH,!0)?(this._createCommentToken(Se.DASH_DASH.length+1),this.state=g.COMMENT_START):this._consumeSequenceIfMatch(Se.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(Se.DOCTYPE.length+1),this.state=g.DOCTYPE):this._consumeSequenceIfMatch(Se.CDATA_START,!0)?this.inForeignNode?this.state=g.CDATA_SECTION:(this._err(w.cdataInHtmlContent),this._createCommentToken(Se.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=g.BOGUS_COMMENT):this._ensureHibernation()||(this._err(w.incorrectlyOpenedComment),this._createCommentToken(2),this.state=g.BOGUS_COMMENT,this._stateBogusComment(e))}_stateCommentStart(e){switch(e){case m.HYPHEN_MINUS:this.state=g.COMMENT_START_DASH;break;case m.GREATER_THAN_SIGN:{this._err(w.abruptClosingOfEmptyComment),this.state=g.DATA;const t=this.currentToken;this.emitCurrentComment(t);break}default:this.state=g.COMMENT,this._stateComment(e)}}_stateCommentStartDash(e){const t=this.currentToken;switch(e){case m.HYPHEN_MINUS:this.state=g.COMMENT_END;break;case m.GREATER_THAN_SIGN:this._err(w.abruptClosingOfEmptyComment),this.state=g.DATA,this.emitCurrentComment(t);break;case m.EOF:this._err(w.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+="-",this.state=g.COMMENT,this._stateComment(e)}}_stateComment(e){const t=this.currentToken;switch(e){case m.HYPHEN_MINUS:this.state=g.COMMENT_END_DASH;break;case m.LESS_THAN_SIGN:t.data+="<",this.state=g.COMMENT_LESS_THAN_SIGN;break;case m.NULL:this._err(w.unexpectedNullCharacter),t.data+="�";break;case m.EOF:this._err(w.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=String.fromCodePoint(e)}}_stateCommentLessThanSign(e){const t=this.currentToken;switch(e){case m.EXCLAMATION_MARK:t.data+="!",this.state=g.COMMENT_LESS_THAN_SIGN_BANG;break;case m.LESS_THAN_SIGN:t.data+="<";break;default:this.state=g.COMMENT,this._stateComment(e)}}_stateCommentLessThanSignBang(e){e===m.HYPHEN_MINUS?this.state=g.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=g.COMMENT,this._stateComment(e))}_stateCommentLessThanSignBangDash(e){e===m.HYPHEN_MINUS?this.state=g.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=g.COMMENT_END_DASH,this._stateCommentEndDash(e))}_stateCommentLessThanSignBangDashDash(e){e!==m.GREATER_THAN_SIGN&&e!==m.EOF&&this._err(w.nestedComment),this.state=g.COMMENT_END,this._stateCommentEnd(e)}_stateCommentEndDash(e){const t=this.currentToken;switch(e){case m.HYPHEN_MINUS:this.state=g.COMMENT_END;break;case m.EOF:this._err(w.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+="-",this.state=g.COMMENT,this._stateComment(e)}}_stateCommentEnd(e){const t=this.currentToken;switch(e){case m.GREATER_THAN_SIGN:this.state=g.DATA,this.emitCurrentComment(t);break;case m.EXCLAMATION_MARK:this.state=g.COMMENT_END_BANG;break;case m.HYPHEN_MINUS:t.data+="-";break;case m.EOF:this._err(w.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+="--",this.state=g.COMMENT,this._stateComment(e)}}_stateCommentEndBang(e){const t=this.currentToken;switch(e){case m.HYPHEN_MINUS:t.data+="--!",this.state=g.COMMENT_END_DASH;break;case m.GREATER_THAN_SIGN:this._err(w.incorrectlyClosedComment),this.state=g.DATA,this.emitCurrentComment(t);break;case m.EOF:this._err(w.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+="--!",this.state=g.COMMENT,this._stateComment(e)}}_stateDoctype(e){switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:this.state=g.BEFORE_DOCTYPE_NAME;break;case m.GREATER_THAN_SIGN:this.state=g.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(e);break;case m.EOF:{this._err(w.eofInDoctype),this._createDoctypeToken(null);const t=this.currentToken;t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break}default:this._err(w.missingWhitespaceBeforeDoctypeName),this.state=g.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(e)}}_stateBeforeDoctypeName(e){if(rn(e))this._createDoctypeToken(String.fromCharCode(Dn(e))),this.state=g.DOCTYPE_NAME;else switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.NULL:this._err(w.unexpectedNullCharacter),this._createDoctypeToken("�"),this.state=g.DOCTYPE_NAME;break;case m.GREATER_THAN_SIGN:{this._err(w.missingDoctypeName),this._createDoctypeToken(null);const t=this.currentToken;t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=g.DATA;break}case m.EOF:{this._err(w.eofInDoctype),this._createDoctypeToken(null);const t=this.currentToken;t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(e)),this.state=g.DOCTYPE_NAME}}_stateDoctypeName(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:this.state=g.AFTER_DOCTYPE_NAME;break;case m.GREATER_THAN_SIGN:this.state=g.DATA,this.emitCurrentDoctype(t);break;case m.NULL:this._err(w.unexpectedNullCharacter),t.name+="�";break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.name+=String.fromCodePoint(rn(e)?Dn(e):e)}}_stateAfterDoctypeName(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:this.state=g.DATA,this.emitCurrentDoctype(t);break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._consumeSequenceIfMatch(Se.PUBLIC,!1)?this.state=g.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(Se.SYSTEM,!1)?this.state=g.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(w.invalidCharacterSequenceAfterDoctypeName),t.forceQuirks=!0,this.state=g.BOGUS_DOCTYPE,this._stateBogusDoctype(e))}}_stateAfterDoctypePublicKeyword(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:this.state=g.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break;case m.QUOTATION_MARK:this._err(w.missingWhitespaceAfterDoctypePublicKeyword),t.publicId="",this.state=g.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break;case m.APOSTROPHE:this._err(w.missingWhitespaceAfterDoctypePublicKeyword),t.publicId="",this.state=g.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break;case m.GREATER_THAN_SIGN:this._err(w.missingDoctypePublicIdentifier),t.forceQuirks=!0,this.state=g.DATA,this.emitCurrentDoctype(t);break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(w.missingQuoteBeforeDoctypePublicIdentifier),t.forceQuirks=!0,this.state=g.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBeforeDoctypePublicIdentifier(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:t.publicId="",this.state=g.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break;case m.APOSTROPHE:t.publicId="",this.state=g.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break;case m.GREATER_THAN_SIGN:this._err(w.missingDoctypePublicIdentifier),t.forceQuirks=!0,this.state=g.DATA,this.emitCurrentDoctype(t);break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(w.missingQuoteBeforeDoctypePublicIdentifier),t.forceQuirks=!0,this.state=g.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateDoctypePublicIdentifierDoubleQuoted(e){const t=this.currentToken;switch(e){case m.QUOTATION_MARK:this.state=g.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break;case m.NULL:this._err(w.unexpectedNullCharacter),t.publicId+="�";break;case m.GREATER_THAN_SIGN:this._err(w.abruptDoctypePublicIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=g.DATA;break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.publicId+=String.fromCodePoint(e)}}_stateDoctypePublicIdentifierSingleQuoted(e){const t=this.currentToken;switch(e){case m.APOSTROPHE:this.state=g.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break;case m.NULL:this._err(w.unexpectedNullCharacter),t.publicId+="�";break;case m.GREATER_THAN_SIGN:this._err(w.abruptDoctypePublicIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=g.DATA;break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.publicId+=String.fromCodePoint(e)}}_stateAfterDoctypePublicIdentifier(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:this.state=g.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break;case m.GREATER_THAN_SIGN:this.state=g.DATA,this.emitCurrentDoctype(t);break;case m.QUOTATION_MARK:this._err(w.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),t.systemId="",this.state=g.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case m.APOSTROPHE:this._err(w.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),t.systemId="",this.state=g.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(w.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=g.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBetweenDoctypePublicAndSystemIdentifiers(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=g.DATA;break;case m.QUOTATION_MARK:t.systemId="",this.state=g.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case m.APOSTROPHE:t.systemId="",this.state=g.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(w.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=g.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateAfterDoctypeSystemKeyword(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:this.state=g.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break;case m.QUOTATION_MARK:this._err(w.missingWhitespaceAfterDoctypeSystemKeyword),t.systemId="",this.state=g.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case m.APOSTROPHE:this._err(w.missingWhitespaceAfterDoctypeSystemKeyword),t.systemId="",this.state=g.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case m.GREATER_THAN_SIGN:this._err(w.missingDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=g.DATA,this.emitCurrentDoctype(t);break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(w.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=g.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBeforeDoctypeSystemIdentifier(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:t.systemId="",this.state=g.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case m.APOSTROPHE:t.systemId="",this.state=g.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case m.GREATER_THAN_SIGN:this._err(w.missingDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=g.DATA,this.emitCurrentDoctype(t);break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(w.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=g.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateDoctypeSystemIdentifierDoubleQuoted(e){const t=this.currentToken;switch(e){case m.QUOTATION_MARK:this.state=g.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break;case m.NULL:this._err(w.unexpectedNullCharacter),t.systemId+="�";break;case m.GREATER_THAN_SIGN:this._err(w.abruptDoctypeSystemIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=g.DATA;break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.systemId+=String.fromCodePoint(e)}}_stateDoctypeSystemIdentifierSingleQuoted(e){const t=this.currentToken;switch(e){case m.APOSTROPHE:this.state=g.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break;case m.NULL:this._err(w.unexpectedNullCharacter),t.systemId+="�";break;case m.GREATER_THAN_SIGN:this._err(w.abruptDoctypeSystemIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=g.DATA;break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.systemId+=String.fromCodePoint(e)}}_stateAfterDoctypeSystemIdentifier(e){const t=this.currentToken;switch(e){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=g.DATA;break;case m.EOF:this._err(w.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(w.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=g.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBogusDoctype(e){const t=this.currentToken;switch(e){case m.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=g.DATA;break;case m.NULL:this._err(w.unexpectedNullCharacter);break;case m.EOF:this.emitCurrentDoctype(t),this._emitEOFToken();break;default:}}_stateCdataSection(e){switch(e){case m.RIGHT_SQUARE_BRACKET:this.state=g.CDATA_SECTION_BRACKET;break;case m.EOF:this._err(w.eofInCdata),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateCdataSectionBracket(e){e===m.RIGHT_SQUARE_BRACKET?this.state=g.CDATA_SECTION_END:(this._emitChars("]"),this.state=g.CDATA_SECTION,this._stateCdataSection(e))}_stateCdataSectionEnd(e){switch(e){case m.GREATER_THAN_SIGN:this.state=g.DATA;break;case m.RIGHT_SQUARE_BRACKET:this._emitChars("]");break;default:this._emitChars("]]"),this.state=g.CDATA_SECTION,this._stateCdataSection(e)}}_stateCharacterReference(){let e=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(e<0)if(this.preprocessor.lastChunkWritten)e=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}e===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(m.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&ea(this.preprocessor.peek(1))?g.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(e){ea(e)?this._flushCodePointConsumedAsCharacterReference(e):(e===m.SEMICOLON&&this._err(w.unknownNamedCharacterReference),this.state=this.returnState,this._callState(e))}},Qs=new Set([c.DD,c.DT,c.LI,c.OPTGROUP,c.OPTION,c.P,c.RB,c.RP,c.RT,c.RTC]),na=new Set([...Qs,c.CAPTION,c.COLGROUP,c.TBODY,c.TD,c.TFOOT,c.TH,c.THEAD,c.TR]),Yn=new Set([c.APPLET,c.CAPTION,c.HTML,c.MARQUEE,c.OBJECT,c.TABLE,c.TD,c.TEMPLATE,c.TH]),$u=new Set([...Yn,c.OL,c.UL]),Yu=new Set([...Yn,c.BUTTON]),ra=new Set([c.ANNOTATION_XML,c.MI,c.MN,c.MO,c.MS,c.MTEXT]),ia=new Set([c.DESC,c.FOREIGN_OBJECT,c.TITLE]),qu=new Set([c.TR,c.TEMPLATE,c.HTML]),Vu=new Set([c.TBODY,c.TFOOT,c.THEAD,c.TEMPLATE,c.HTML]),Wu=new Set([c.TABLE,c.TEMPLATE,c.HTML]),Qu=new Set([c.TD,c.TH]),Gu=class{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(e,t,n){this.treeAdapter=t,this.handler=n,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=c.UNKNOWN,this.current=e}_indexOf(e){return this.items.lastIndexOf(e,this.stackTop)}_isInTemplate(){return this.currentTagId===c.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===D.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(e,t){this.stackTop++,this.items[this.stackTop]=e,this.current=e,this.tagIDs[this.stackTop]=t,this.currentTagId=t,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(e,t,!0)}pop(){const e=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(e,!0)}replace(e,t){const n=this._indexOf(e);this.items[n]=t,n===this.stackTop&&(this.current=t)}insertAfter(e,t,n){const r=this._indexOf(e)+1;this.items.splice(r,0,t),this.tagIDs.splice(r,0,n),this.stackTop++,r===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,r===this.stackTop)}popUntilTagNamePopped(e){let t=this.stackTop+1;do t=this.tagIDs.lastIndexOf(e,t-1);while(t>0&&this.treeAdapter.getNamespaceURI(this.items[t])!==D.HTML);this.shortenToLength(Math.max(t,0))}shortenToLength(e){for(;this.stackTop>=e;){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,this.stackTop<e)}}popUntilElementPopped(e){const t=this._indexOf(e);this.shortenToLength(Math.max(t,0))}popUntilPopped(e,t){const n=this._indexOfTagNames(e,t);this.shortenToLength(Math.max(n,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(Hr,D.HTML)}popUntilTableCellPopped(){this.popUntilPopped(Qu,D.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(e,t){for(let n=this.stackTop;n>=0;n--)if(e.has(this.tagIDs[n])&&this.treeAdapter.getNamespaceURI(this.items[n])===t)return n;return-1}clearBackTo(e,t){const n=this._indexOfTagNames(e,t);this.shortenToLength(n+1)}clearBackToTableContext(){this.clearBackTo(Wu,D.HTML)}clearBackToTableBodyContext(){this.clearBackTo(Vu,D.HTML)}clearBackToTableRowContext(){this.clearBackTo(qu,D.HTML)}remove(e){const t=this._indexOf(e);t>=0&&(t===this.stackTop?this.pop():(this.items.splice(t,1),this.tagIDs.splice(t,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(e,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===c.BODY?this.items[1]:null}contains(e){return this._indexOf(e)>-1}getCommonAncestor(e){const t=this._indexOf(e)-1;return t>=0?this.items[t]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===c.HTML}hasInDynamicScope(e,t){for(let n=this.stackTop;n>=0;n--){const r=this.tagIDs[n];switch(this.treeAdapter.getNamespaceURI(this.items[n])){case D.HTML:if(r===e)return!0;if(t.has(r))return!1;break;case D.SVG:if(ia.has(r))return!1;break;case D.MATHML:if(ra.has(r))return!1;break}}return!0}hasInScope(e){return this.hasInDynamicScope(e,Yn)}hasInListItemScope(e){return this.hasInDynamicScope(e,$u)}hasInButtonScope(e){return this.hasInDynamicScope(e,Yu)}hasNumberedHeaderInScope(){for(let e=this.stackTop;e>=0;e--){const t=this.tagIDs[e];switch(this.treeAdapter.getNamespaceURI(this.items[e])){case D.HTML:if(Hr.has(t))return!0;if(Yn.has(t))return!1;break;case D.SVG:if(ia.has(t))return!1;break;case D.MATHML:if(ra.has(t))return!1;break}}return!0}hasInTableScope(e){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===D.HTML)switch(this.tagIDs[t]){case e:return!0;case c.TABLE:case c.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let e=this.stackTop;e>=0;e--)if(this.treeAdapter.getNamespaceURI(this.items[e])===D.HTML)switch(this.tagIDs[e]){case c.TBODY:case c.THEAD:case c.TFOOT:return!0;case c.TABLE:case c.HTML:return!1}return!0}hasInSelectScope(e){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===D.HTML)switch(this.tagIDs[t]){case e:return!0;case c.OPTION:case c.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&Qs.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&na.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(e){for(;this.currentTagId!==void 0&&this.currentTagId!==e&&na.has(this.currentTagId);)this.pop()}},gr=3,Ge;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(Ge||(Ge={}));var aa={type:Ge.Marker},Ku=class{constructor(e){this.treeAdapter=e,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(e,t){const n=[],r=t.length,i=this.treeAdapter.getTagName(e),a=this.treeAdapter.getNamespaceURI(e);for(let s=0;s<this.entries.length;s++){const o=this.entries[s];if(o.type===Ge.Marker)break;const{element:l}=o;if(this.treeAdapter.getTagName(l)===i&&this.treeAdapter.getNamespaceURI(l)===a){const u=this.treeAdapter.getAttrList(l);u.length===r&&n.push({idx:s,attrs:u})}}return n}_ensureNoahArkCondition(e){if(this.entries.length<gr)return;const t=this.treeAdapter.getAttrList(e),n=this._getNoahArkConditionCandidates(e,t);if(n.length<gr)return;const r=new Map(t.map(a=>[a.name,a.value]));let i=0;for(let a=0;a<n.length;a++){const s=n[a];s.attrs.every(o=>r.get(o.name)===o.value)&&(i+=1,i>=gr&&this.entries.splice(s.idx,1))}}insertMarker(){this.entries.unshift(aa)}pushElement(e,t){this._ensureNoahArkCondition(e),this.entries.unshift({type:Ge.Element,element:e,token:t})}insertElementAfterBookmark(e,t){const n=this.entries.indexOf(this.bookmark);this.entries.splice(n,0,{type:Ge.Element,element:e,token:t})}removeEntry(e){const t=this.entries.indexOf(e);t!==-1&&this.entries.splice(t,1)}clearToLastMarker(){const e=this.entries.indexOf(aa);e===-1?this.entries.length=0:this.entries.splice(0,e+1)}getElementEntryInScopeWithTagName(e){const t=this.entries.find(n=>n.type===Ge.Marker||this.treeAdapter.getTagName(n.element)===e);return t&&t.type===Ge.Element?t:null}getElementEntry(e){return this.entries.find(t=>t.type===Ge.Element&&t.element===e)}},ot={createDocument(){return{nodeName:"#document",mode:Fe.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const i=e.childNodes.find(a=>a.nodeName==="#documentType");if(i)i.name=t,i.publicId=n,i.systemId=r;else{const a={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};ot.appendChild(e,a)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(ot.isTextNode(n)){n.value+=t;return}}ot.appendChild(e,ot.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&ot.isTextNode(r)?r.value+=t:ot.insertBefore(e,ot.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation={...e.sourceCodeLocation,...t}}},Gs="html",Xu="about:legacy-compat",Zu="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",Ks=["+//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//"],Ju=[...Ks,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],eh=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),Xs=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],th=[...Xs,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function sa(e,t){return t.some(n=>e.startsWith(n))}function nh(e){return e.name===Gs&&e.publicId===null&&(e.systemId===null||e.systemId===Xu)}function rh(e){if(e.name!==Gs)return Fe.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===Zu)return Fe.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),eh.has(n))return Fe.QUIRKS;let r=t===null?Ju:Ks;if(sa(n,r))return Fe.QUIRKS;if(r=t===null?Xs:th,sa(n,r))return Fe.LIMITED_QUIRKS}return Fe.NO_QUIRKS}var la={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},ih="definitionurl",ah="definitionURL",sh=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])),lh=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:D.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:D.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:D.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:D.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:D.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:D.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:D.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:D.XML}],["xml:space",{prefix:"xml",name:"space",namespace:D.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:D.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:D.XMLNS}]]),oh=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])),ch=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 uh(e){const t=e.tagID;return t===c.FONT&&e.attrs.some(({name:n})=>n===At.COLOR||n===At.SIZE||n===At.FACE)||ch.has(t)}function Zs(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===ih){e.attrs[t].name=ah;break}}function Js(e){for(let t=0;t<e.attrs.length;t++){const n=sh.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function ui(e){for(let t=0;t<e.attrs.length;t++){const n=lh.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 hh(e){const t=oh.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=$t(e.tagName))}function dh(e,t){return t===D.MATHML&&(e===c.MI||e===c.MO||e===c.MN||e===c.MS||e===c.MTEXT)}function fh(e,t,n){if(t===D.MATHML&&e===c.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===At.ENCODING){const i=n[r].value.toLowerCase();return i===la.TEXT_HTML||i===la.APPLICATION_XML}}return t===D.SVG&&(e===c.FOREIGN_OBJECT||e===c.DESC||e===c.TITLE)}function ph(e,t,n,r){return(!r||r===D.HTML)&&fh(e,t,n)||(!r||r===D.MATHML)&&dh(e,t)}var mh="hidden",gh=8,Eh=3,T;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(T||(T={}));var Th={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},el=new Set([c.TABLE,c.TBODY,c.TFOOT,c.THEAD,c.TR]),oa={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:ot,onParseError:null},ca=class{constructor(e,t,n=null,r=null){this.fragmentContext=n,this.scriptHandler=r,this.currentToken=null,this.stopped=!1,this.insertionMode=T.INITIAL,this.originalInsertionMode=T.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={...oa,...e},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=t??this.treeAdapter.createDocument(),this.tokenizer=new zu(this.options,this),this.activeFormattingElements=new Ku(this.treeAdapter),this.fragmentContextID=n?$t(this.treeAdapter.getTagName(n)):c.UNKNOWN,this._setContextModes(n??this.document,this.fragmentContextID),this.openElements=new Gu(this.document,this.treeAdapter,this)}static parse(e,t){const n=new this(t);return n.tokenizer.write(e,!0),n.document}static getFragmentParser(e,t){const n={...oa,...t};e!=null||(e=n.treeAdapter.createElement(C.TEMPLATE,D.HTML,[]));const r=n.treeAdapter.createElement("documentmock",D.HTML,[]),i=new this(n,r,e);return i.fragmentContextID===c.TEMPLATE&&i.tmplInsertionModeStack.unshift(T.IN_TEMPLATE),i._initTokenizerForFragmentParsing(),i._insertFakeRootElement(),i._resetInsertionMode(),i._findFormInFragmentContext(),i}getFragment(){const e=this.treeAdapter.getFirstChild(this.document),t=this.treeAdapter.createDocumentFragment();return this._adoptNodes(e,t),t}_err(e,t,n){var r;if(!this.onParseError)return;const i=(r=e.location)!==null&&r!==void 0?r:Th,a={code:t,startLine:i.startLine,startCol:i.startCol,startOffset:i.startOffset,endLine:n?i.startLine:i.endLine,endCol:n?i.startCol:i.endCol,endOffset:n?i.startOffset:i.endOffset};this.onParseError(a)}onItemPush(e,t,n){var r,i;(i=(r=this.treeAdapter).onItemPush)===null||i===void 0||i.call(r,e),n&&this.openElements.stackTop>0&&this._setContextModes(e,t)}onItemPop(e,t){var n,r;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(e,this.currentToken),(r=(n=this.treeAdapter).onItemPop)===null||r===void 0||r.call(n,e,this.openElements.current),t){let i,a;this.openElements.stackTop===0&&this.fragmentContext?(i=this.fragmentContext,a=this.fragmentContextID):{current:i,currentTagId:a}=this.openElements,this._setContextModes(i,a)}}_setContextModes(e,t){const n=e===this.document||e&&this.treeAdapter.getNamespaceURI(e)===D.HTML;this.currentNotInHTML=!n,this.tokenizer.inForeignNode=!n&&e!==void 0&&t!==void 0&&!this._isIntegrationPoint(t,e)}_switchToTextParsing(e,t){this._insertElement(e,D.HTML),this.tokenizer.state=t,this.originalInsertionMode=this.insertionMode,this.insertionMode=T.TEXT}switchToPlaintextParsing(){this.insertionMode=T.TEXT,this.originalInsertionMode=T.IN_BODY,this.tokenizer.state=de.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let e=this.fragmentContext;for(;e;){if(this.treeAdapter.getTagName(e)===C.FORM){this.formElement=e;break}e=this.treeAdapter.getParentNode(e)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==D.HTML))switch(this.fragmentContextID){case c.TITLE:case c.TEXTAREA:this.tokenizer.state=de.RCDATA;break;case c.STYLE:case c.XMP:case c.IFRAME:case c.NOEMBED:case c.NOFRAMES:case c.NOSCRIPT:this.tokenizer.state=de.RAWTEXT;break;case c.SCRIPT:this.tokenizer.state=de.SCRIPT_DATA;break;case c.PLAINTEXT:this.tokenizer.state=de.PLAINTEXT;break;default:}}_setDocumentType(e){const t=e.name||"",n=e.publicId||"",r=e.systemId||"";if(this.treeAdapter.setDocumentType(this.document,t,n,r),e.location){const i=this.treeAdapter.getChildNodes(this.document).find(a=>this.treeAdapter.isDocumentTypeNode(a));i&&this.treeAdapter.setNodeSourceCodeLocation(i,e.location)}}_attachElementToTree(e,t){if(this.options.sourceCodeLocationInfo){const n=t&&{...t,startTag:t};this.treeAdapter.setNodeSourceCodeLocation(e,n)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(e);else{const n=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(n??this.document,e)}}_appendElement(e,t){const n=this.treeAdapter.createElement(e.tagName,t,e.attrs);this._attachElementToTree(n,e.location)}_insertElement(e,t){const n=this.treeAdapter.createElement(e.tagName,t,e.attrs);this._attachElementToTree(n,e.location),this.openElements.push(n,e.tagID)}_insertFakeElement(e,t){const n=this.treeAdapter.createElement(e,D.HTML,[]);this._attachElementToTree(n,null),this.openElements.push(n,t)}_insertTemplate(e){const t=this.treeAdapter.createElement(e.tagName,D.HTML,e.attrs),n=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(t,n),this._attachElementToTree(t,e.location),this.openElements.push(t,e.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(n,null)}_insertFakeRootElement(){const e=this.treeAdapter.createElement(C.HTML,D.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(e,null),this.treeAdapter.appendChild(this.openElements.current,e),this.openElements.push(e,c.HTML)}_appendCommentNode(e,t){const n=this.treeAdapter.createCommentNode(e.data);this.treeAdapter.appendChild(t,n),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(n,e.location)}_insertCharacters(e){let t,n;if(this._shouldFosterParentOnInsertion()?({parent:t,beforeElement:n}=this._findFosterParentingLocation(),n?this.treeAdapter.insertTextBefore(t,e.chars,n):this.treeAdapter.insertText(t,e.chars)):(t=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(t,e.chars)),!e.location)return;const r=this.treeAdapter.getChildNodes(t),i=r[(n?r.lastIndexOf(n):r.length)-1];if(this.treeAdapter.getNodeSourceCodeLocation(i)){const{endLine:a,endCol:s,endOffset:o}=e.location;this.treeAdapter.updateNodeSourceCodeLocation(i,{endLine:a,endCol:s,endOffset:o})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(i,e.location)}_adoptNodes(e,t){for(let n=this.treeAdapter.getFirstChild(e);n;n=this.treeAdapter.getFirstChild(e))this.treeAdapter.detachNode(n),this.treeAdapter.appendChild(t,n)}_setEndLocation(e,t){if(this.treeAdapter.getNodeSourceCodeLocation(e)&&t.location){const n=t.location,r=this.treeAdapter.getTagName(e),i=t.type===K.END_TAG&&r===t.tagName?{endTag:{...n},endLine:n.endLine,endCol:n.endCol,endOffset:n.endOffset}:{endLine:n.startLine,endCol:n.startCol,endOffset:n.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(e,i)}}shouldProcessStartTagTokenInForeignContent(e){if(!this.currentNotInHTML)return!1;let t,n;return this.openElements.stackTop===0&&this.fragmentContext?(t=this.fragmentContext,n=this.fragmentContextID):{current:t,currentTagId:n}=this.openElements,e.tagID===c.SVG&&this.treeAdapter.getTagName(t)===C.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(t)===D.MATHML?!1:this.tokenizer.inForeignNode||(e.tagID===c.MGLYPH||e.tagID===c.MALIGNMARK)&&n!==void 0&&!this._isIntegrationPoint(n,t,D.HTML)}_processToken(e){switch(e.type){case K.CHARACTER:this.onCharacter(e);break;case K.NULL_CHARACTER:this.onNullCharacter(e);break;case K.COMMENT:this.onComment(e);break;case K.DOCTYPE:this.onDoctype(e);break;case K.START_TAG:this._processStartTag(e);break;case K.END_TAG:this.onEndTag(e);break;case K.EOF:this.onEof(e);break;case K.WHITESPACE_CHARACTER:this.onWhitespaceCharacter(e);break}}_isIntegrationPoint(e,t,n){const r=this.treeAdapter.getNamespaceURI(t),i=this.treeAdapter.getAttrList(t);return ph(e,r,i,n)}_reconstructActiveFormattingElements(){const e=this.activeFormattingElements.entries.length;if(e){const t=this.activeFormattingElements.entries.findIndex(r=>r.type===Ge.Marker||this.openElements.contains(r.element)),n=t===-1?e-1:t-1;for(let r=n;r>=0;r--){const i=this.activeFormattingElements.entries[r];this._insertElement(i.token,this.treeAdapter.getNamespaceURI(i.element)),i.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=T.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(c.P),this.openElements.popUntilTagNamePopped(c.P)}_resetInsertionMode(){for(let e=this.openElements.stackTop;e>=0;e--)switch(e===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[e]){case c.TR:this.insertionMode=T.IN_ROW;return;case c.TBODY:case c.THEAD:case c.TFOOT:this.insertionMode=T.IN_TABLE_BODY;return;case c.CAPTION:this.insertionMode=T.IN_CAPTION;return;case c.COLGROUP:this.insertionMode=T.IN_COLUMN_GROUP;return;case c.TABLE:this.insertionMode=T.IN_TABLE;return;case c.BODY:this.insertionMode=T.IN_BODY;return;case c.FRAMESET:this.insertionMode=T.IN_FRAMESET;return;case c.SELECT:this._resetInsertionModeForSelect(e);return;case c.TEMPLATE:this.insertionMode=this.tmplInsertionModeStack[0];return;case c.HTML:this.insertionMode=this.headElement?T.AFTER_HEAD:T.BEFORE_HEAD;return;case c.TD:case c.TH:if(e>0){this.insertionMode=T.IN_CELL;return}break;case c.HEAD:if(e>0){this.insertionMode=T.IN_HEAD;return}break}this.insertionMode=T.IN_BODY}_resetInsertionModeForSelect(e){if(e>0)for(let t=e-1;t>0;t--){const n=this.openElements.tagIDs[t];if(n===c.TEMPLATE)break;if(n===c.TABLE){this.insertionMode=T.IN_SELECT_IN_TABLE;return}}this.insertionMode=T.IN_SELECT}_isElementCausesFosterParenting(e){return el.has(e)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let e=this.openElements.stackTop;e>=0;e--){const t=this.openElements.items[e];switch(this.openElements.tagIDs[e]){case c.TEMPLATE:if(this.treeAdapter.getNamespaceURI(t)===D.HTML)return{parent:this.treeAdapter.getTemplateContent(t),beforeElement:null};break;case c.TABLE:{const n=this.treeAdapter.getParentNode(t);return n?{parent:n,beforeElement:t}:{parent:this.openElements.items[e-1],beforeElement:null}}default:}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(e){const t=this._findFosterParentingLocation();t.beforeElement?this.treeAdapter.insertBefore(t.parent,e,t.beforeElement):this.treeAdapter.appendChild(t.parent,e)}_isSpecialElement(e,t){return Fu[this.treeAdapter.getNamespaceURI(e)].has(t)}onCharacter(e){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Qd(this,e);return}switch(this.insertionMode){case T.INITIAL:Xt(this,e);break;case T.BEFORE_HTML:ln(this,e);break;case T.BEFORE_HEAD:on(this,e);break;case T.IN_HEAD:cn(this,e);break;case T.IN_HEAD_NO_SCRIPT:un(this,e);break;case T.AFTER_HEAD:hn(this,e);break;case T.IN_BODY:case T.IN_CAPTION:case T.IN_CELL:case T.IN_TEMPLATE:nl(this,e);break;case T.TEXT:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:this._insertCharacters(e);break;case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:Er(this,e);break;case T.IN_TABLE_TEXT:ol(this,e);break;case T.IN_COLUMN_GROUP:qn(this,e);break;case T.AFTER_BODY:Vn(this,e);break;case T.AFTER_AFTER_BODY:jn(this,e);break;default:}}onNullCharacter(e){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Wd(this,e);return}switch(this.insertionMode){case T.INITIAL:Xt(this,e);break;case T.BEFORE_HTML:ln(this,e);break;case T.BEFORE_HEAD:on(this,e);break;case T.IN_HEAD:cn(this,e);break;case T.IN_HEAD_NO_SCRIPT:un(this,e);break;case T.AFTER_HEAD:hn(this,e);break;case T.TEXT:this._insertCharacters(e);break;case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:Er(this,e);break;case T.IN_COLUMN_GROUP:qn(this,e);break;case T.AFTER_BODY:Vn(this,e);break;case T.AFTER_AFTER_BODY:jn(this,e);break;default:}}onComment(e){if(this.skipNextNewLine=!1,this.currentNotInHTML){Ur(this,e);return}switch(this.insertionMode){case T.INITIAL:case T.BEFORE_HTML:case T.BEFORE_HEAD:case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:case T.IN_BODY:case T.IN_TABLE:case T.IN_CAPTION:case T.IN_COLUMN_GROUP:case T.IN_TABLE_BODY:case T.IN_ROW:case T.IN_CELL:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:case T.IN_TEMPLATE:case T.IN_FRAMESET:case T.AFTER_FRAMESET:Ur(this,e);break;case T.IN_TABLE_TEXT:Zt(this,e);break;case T.AFTER_BODY:xh(this,e);break;case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:Ih(this,e);break;default:}}onDoctype(e){switch(this.skipNextNewLine=!1,this.insertionMode){case T.INITIAL:Nh(this,e);break;case T.BEFORE_HEAD:case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:this._err(e,w.misplacedDoctype);break;case T.IN_TABLE_TEXT:Zt(this,e);break;default:}}onStartTag(e){this.skipNextNewLine=!1,this.currentToken=e,this._processStartTag(e),e.selfClosing&&!e.ackSelfClosing&&this._err(e,w.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(e){this.shouldProcessStartTagTokenInForeignContent(e)?Gd(this,e):this._startTagOutsideForeignContent(e)}_startTagOutsideForeignContent(e){switch(this.insertionMode){case T.INITIAL:Xt(this,e);break;case T.BEFORE_HTML:Sh(this,e);break;case T.BEFORE_HEAD:Lh(this,e);break;case T.IN_HEAD:qe(this,e);break;case T.IN_HEAD_NO_SCRIPT:Dh(this,e);break;case T.AFTER_HEAD:Ph(this,e);break;case T.IN_BODY:be(this,e);break;case T.IN_TABLE:Ht(this,e);break;case T.IN_TABLE_TEXT:Zt(this,e);break;case T.IN_CAPTION:Rd(this,e);break;case T.IN_COLUMN_GROUP:fi(this,e);break;case T.IN_TABLE_BODY:ir(this,e);break;case T.IN_ROW:ar(this,e);break;case T.IN_CELL:vd(this,e);break;case T.IN_SELECT:hl(this,e);break;case T.IN_SELECT_IN_TABLE:Md(this,e);break;case T.IN_TEMPLATE:Fd(this,e);break;case T.AFTER_BODY:Ud(this,e);break;case T.IN_FRAMESET:jd(this,e);break;case T.AFTER_FRAMESET:$d(this,e);break;case T.AFTER_AFTER_BODY:qd(this,e);break;case T.AFTER_AFTER_FRAMESET:Vd(this,e);break;default:}}onEndTag(e){this.skipNextNewLine=!1,this.currentToken=e,this.currentNotInHTML?Kd(this,e):this._endTagOutsideForeignContent(e)}_endTagOutsideForeignContent(e){switch(this.insertionMode){case T.INITIAL:Xt(this,e);break;case T.BEFORE_HTML:wh(this,e);break;case T.BEFORE_HEAD:Rh(this,e);break;case T.IN_HEAD:Oh(this,e);break;case T.IN_HEAD_NO_SCRIPT:vh(this,e);break;case T.AFTER_HEAD:Mh(this,e);break;case T.IN_BODY:rr(this,e);break;case T.TEXT:_d(this,e);break;case T.IN_TABLE:gn(this,e);break;case T.IN_TABLE_TEXT:Zt(this,e);break;case T.IN_CAPTION:Od(this,e);break;case T.IN_COLUMN_GROUP:Dd(this,e);break;case T.IN_TABLE_BODY:jr(this,e);break;case T.IN_ROW:ul(this,e);break;case T.IN_CELL:Pd(this,e);break;case T.IN_SELECT:dl(this,e);break;case T.IN_SELECT_IN_TABLE:Bd(this,e);break;case T.IN_TEMPLATE:Hd(this,e);break;case T.AFTER_BODY:pl(this,e);break;case T.IN_FRAMESET:zd(this,e);break;case T.AFTER_FRAMESET:Yd(this,e);break;case T.AFTER_AFTER_BODY:jn(this,e);break;default:}}onEof(e){switch(this.insertionMode){case T.INITIAL:Xt(this,e);break;case T.BEFORE_HTML:ln(this,e);break;case T.BEFORE_HEAD:on(this,e);break;case T.IN_HEAD:cn(this,e);break;case T.IN_HEAD_NO_SCRIPT:un(this,e);break;case T.AFTER_HEAD:hn(this,e);break;case T.IN_BODY:case T.IN_TABLE:case T.IN_CAPTION:case T.IN_COLUMN_GROUP:case T.IN_TABLE_BODY:case T.IN_ROW:case T.IN_CELL:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:sl(this,e);break;case T.TEXT:Ad(this,e);break;case T.IN_TABLE_TEXT:Zt(this,e);break;case T.IN_TEMPLATE:fl(this,e);break;case T.AFTER_BODY:case T.IN_FRAMESET:case T.AFTER_FRAMESET:case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:di(this,e);break;default:}}onWhitespaceCharacter(e){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,e.chars.charCodeAt(0)===m.LINE_FEED)){if(e.chars.length===1)return;e.chars=e.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(e);return}switch(this.insertionMode){case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:case T.TEXT:case T.IN_COLUMN_GROUP:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:case T.IN_FRAMESET:case T.AFTER_FRAMESET:this._insertCharacters(e);break;case T.IN_BODY:case T.IN_CAPTION:case T.IN_CELL:case T.IN_TEMPLATE:case T.AFTER_BODY:case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:tl(this,e);break;case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:Er(this,e);break;case T.IN_TABLE_TEXT:ll(this,e);break;default:}}};function bh(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):al(e,t),n}function kh(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 _h(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),l=o&&a>=Eh;!o||l?(l&&e.activeFormattingElements.removeEntry(o),e.openElements.remove(s)):(s=Ah(e,o),r===t&&(e.activeFormattingElements.bookmark=o),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(s,r),r=s)}return r}function Ah(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 Ch(e,t,n){const r=$t(e.treeAdapter.getTagName(t));if(e._isElementCausesFosterParenting(r))e._fosterParentElement(n);else{const i=e.treeAdapter.getNamespaceURI(t);r===c.TEMPLATE&&i===D.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function yh(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 hi(e,t){for(let n=0;n<gh;n++){const r=bh(e,t);if(!r)break;const i=kh(e,r);if(!i)break;e.activeFormattingElements.bookmark=r;const a=_h(e,i,r.element),s=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),s&&Ch(e,s,a),yh(e,i,r)}}function Ur(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function xh(e,t){e._appendCommentNode(t,e.openElements.items[0])}function Ih(e,t){e._appendCommentNode(t,e.document)}function di(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 Nh(e,t){e._setDocumentType(t);const n=t.forceQuirks?Fe.QUIRKS:rh(t);nh(t)||e._err(t,w.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=T.BEFORE_HTML}function Xt(e,t){e._err(t,w.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Fe.QUIRKS),e.insertionMode=T.BEFORE_HTML,e._processToken(t)}function Sh(e,t){t.tagID===c.HTML?(e._insertElement(t,D.HTML),e.insertionMode=T.BEFORE_HEAD):ln(e,t)}function wh(e,t){const n=t.tagID;(n===c.HTML||n===c.HEAD||n===c.BODY||n===c.BR)&&ln(e,t)}function ln(e,t){e._insertFakeRootElement(),e.insertionMode=T.BEFORE_HEAD,e._processToken(t)}function Lh(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.HEAD:e._insertElement(t,D.HTML),e.headElement=e.openElements.current,e.insertionMode=T.IN_HEAD;break;default:on(e,t)}}function Rh(e,t){const n=t.tagID;n===c.HEAD||n===c.BODY||n===c.HTML||n===c.BR?on(e,t):e._err(t,w.endTagWithoutMatchingOpenElement)}function on(e,t){e._insertFakeElement(C.HEAD,c.HEAD),e.headElement=e.openElements.current,e.insertionMode=T.IN_HEAD,e._processToken(t)}function qe(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.BASE:case c.BASEFONT:case c.BGSOUND:case c.LINK:case c.META:e._appendElement(t,D.HTML),t.ackSelfClosing=!0;break;case c.TITLE:e._switchToTextParsing(t,de.RCDATA);break;case c.NOSCRIPT:e.options.scriptingEnabled?e._switchToTextParsing(t,de.RAWTEXT):(e._insertElement(t,D.HTML),e.insertionMode=T.IN_HEAD_NO_SCRIPT);break;case c.NOFRAMES:case c.STYLE:e._switchToTextParsing(t,de.RAWTEXT);break;case c.SCRIPT:e._switchToTextParsing(t,de.SCRIPT_DATA);break;case c.TEMPLATE:e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=T.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(T.IN_TEMPLATE);break;case c.HEAD:e._err(t,w.misplacedStartTagForHeadElement);break;default:cn(e,t)}}function Oh(e,t){switch(t.tagID){case c.HEAD:e.openElements.pop(),e.insertionMode=T.AFTER_HEAD;break;case c.BODY:case c.BR:case c.HTML:cn(e,t);break;case c.TEMPLATE:Nt(e,t);break;default:e._err(t,w.endTagWithoutMatchingOpenElement)}}function Nt(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==c.TEMPLATE&&e._err(t,w.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(c.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,w.endTagWithoutMatchingOpenElement)}function cn(e,t){e.openElements.pop(),e.insertionMode=T.AFTER_HEAD,e._processToken(t)}function Dh(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.BASEFONT:case c.BGSOUND:case c.HEAD:case c.LINK:case c.META:case c.NOFRAMES:case c.STYLE:qe(e,t);break;case c.NOSCRIPT:e._err(t,w.nestedNoscriptInHead);break;default:un(e,t)}}function vh(e,t){switch(t.tagID){case c.NOSCRIPT:e.openElements.pop(),e.insertionMode=T.IN_HEAD;break;case c.BR:un(e,t);break;default:e._err(t,w.endTagWithoutMatchingOpenElement)}}function un(e,t){const n=t.type===K.EOF?w.openElementsLeftAfterEof:w.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=T.IN_HEAD,e._processToken(t)}function Ph(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.BODY:e._insertElement(t,D.HTML),e.framesetOk=!1,e.insertionMode=T.IN_BODY;break;case c.FRAMESET:e._insertElement(t,D.HTML),e.insertionMode=T.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,w.abandonedHeadElementChild),e.openElements.push(e.headElement,c.HEAD),qe(e,t),e.openElements.remove(e.headElement);break;case c.HEAD:e._err(t,w.misplacedStartTagForHeadElement);break;default:hn(e,t)}}function Mh(e,t){switch(t.tagID){case c.BODY:case c.HTML:case c.BR:hn(e,t);break;case c.TEMPLATE:Nt(e,t);break;default:e._err(t,w.endTagWithoutMatchingOpenElement)}}function hn(e,t){e._insertFakeElement(C.BODY,c.BODY),e.insertionMode=T.IN_BODY,nr(e,t)}function nr(e,t){switch(t.type){case K.CHARACTER:nl(e,t);break;case K.WHITESPACE_CHARACTER:tl(e,t);break;case K.COMMENT:Ur(e,t);break;case K.START_TAG:be(e,t);break;case K.END_TAG:rr(e,t);break;case K.EOF:sl(e,t);break;default:}}function tl(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function nl(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function Bh(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function Fh(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function Hh(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,D.HTML),e.insertionMode=T.IN_FRAMESET)}function Uh(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,D.HTML)}function jh(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&Hr.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,D.HTML)}function zh(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,D.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function $h(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,D.HTML),n||(e.formElement=e.openElements.current))}function Yh(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,D.HTML)}function qh(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,D.HTML),e.tokenizer.state=de.PLAINTEXT}function Vh(e,t){e.openElements.hasInScope(c.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(c.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,D.HTML),e.framesetOk=!1}function Wh(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(C.A);n&&(hi(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,D.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Qh(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,D.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Gh(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(c.NOBR)&&(hi(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,D.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Kh(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,D.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function Xh(e,t){e.treeAdapter.getDocumentMode(e.document)!==Fe.QUIRKS&&e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._insertElement(t,D.HTML),e.framesetOk=!1,e.insertionMode=T.IN_TABLE}function rl(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,D.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function il(e){const t=Vs(e,At.TYPE);return t!=null&&t.toLowerCase()===mh}function Zh(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,D.HTML),il(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function Jh(e,t){e._appendElement(t,D.HTML),t.ackSelfClosing=!0}function ed(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._appendElement(t,D.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function td(e,t){t.tagName=C.IMG,t.tagID=c.IMG,rl(e,t)}function nd(e,t){e._insertElement(t,D.HTML),e.skipNextNewLine=!0,e.tokenizer.state=de.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=T.TEXT}function rd(e,t){e.openElements.hasInButtonScope(c.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,de.RAWTEXT)}function id(e,t){e.framesetOk=!1,e._switchToTextParsing(t,de.RAWTEXT)}function ua(e,t){e._switchToTextParsing(t,de.RAWTEXT)}function ad(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,D.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===T.IN_TABLE||e.insertionMode===T.IN_CAPTION||e.insertionMode===T.IN_TABLE_BODY||e.insertionMode===T.IN_ROW||e.insertionMode===T.IN_CELL?T.IN_SELECT_IN_TABLE:T.IN_SELECT}function sd(e,t){e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,D.HTML)}function ld(e,t){e.openElements.hasInScope(c.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,D.HTML)}function od(e,t){e.openElements.hasInScope(c.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(c.RTC),e._insertElement(t,D.HTML)}function cd(e,t){e._reconstructActiveFormattingElements(),Zs(t),ui(t),t.selfClosing?e._appendElement(t,D.MATHML):e._insertElement(t,D.MATHML),t.ackSelfClosing=!0}function ud(e,t){e._reconstructActiveFormattingElements(),Js(t),ui(t),t.selfClosing?e._appendElement(t,D.SVG):e._insertElement(t,D.SVG),t.ackSelfClosing=!0}function ha(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,D.HTML)}function be(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:Qh(e,t);break;case c.A:Wh(e,t);break;case c.H1:case c.H2:case c.H3:case c.H4:case c.H5:case c.H6:jh(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:Uh(e,t);break;case c.LI:case c.DD:case c.DT:Yh(e,t);break;case c.BR:case c.IMG:case c.WBR:case c.AREA:case c.EMBED:case c.KEYGEN:rl(e,t);break;case c.HR:ed(e,t);break;case c.RB:case c.RTC:ld(e,t);break;case c.RT:case c.RP:od(e,t);break;case c.PRE:case c.LISTING:zh(e,t);break;case c.XMP:rd(e,t);break;case c.SVG:ud(e,t);break;case c.HTML:Bh(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:qe(e,t);break;case c.BODY:Fh(e,t);break;case c.FORM:$h(e,t);break;case c.NOBR:Gh(e,t);break;case c.MATH:cd(e,t);break;case c.TABLE:Xh(e,t);break;case c.INPUT:Zh(e,t);break;case c.PARAM:case c.TRACK:case c.SOURCE:Jh(e,t);break;case c.IMAGE:td(e,t);break;case c.BUTTON:Vh(e,t);break;case c.APPLET:case c.OBJECT:case c.MARQUEE:Kh(e,t);break;case c.IFRAME:id(e,t);break;case c.SELECT:ad(e,t);break;case c.OPTION:case c.OPTGROUP:sd(e,t);break;case c.NOEMBED:case c.NOFRAMES:ua(e,t);break;case c.FRAMESET:Hh(e,t);break;case c.TEXTAREA:nd(e,t);break;case c.NOSCRIPT:e.options.scriptingEnabled?ua(e,t):ha(e,t);break;case c.PLAINTEXT:qh(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:ha(e,t)}}function hd(e,t){if(e.openElements.hasInScope(c.BODY)&&(e.insertionMode=T.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function dd(e,t){e.openElements.hasInScope(c.BODY)&&(e.insertionMode=T.AFTER_BODY,pl(e,t))}function fd(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function pd(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 md(e){e.openElements.hasInButtonScope(c.P)||e._insertFakeElement(C.P,c.P),e._closePElement()}function gd(e){e.openElements.hasInListItemScope(c.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(c.LI),e.openElements.popUntilTagNamePopped(c.LI))}function Ed(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function Td(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function bd(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function kd(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(C.BR,c.BR),e.openElements.pop(),e.framesetOk=!1}function al(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 rr(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:hi(e,t);break;case c.P:md(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:fd(e,t);break;case c.LI:gd(e);break;case c.DD:case c.DT:Ed(e,t);break;case c.H1:case c.H2:case c.H3:case c.H4:case c.H5:case c.H6:Td(e);break;case c.BR:kd(e);break;case c.BODY:hd(e,t);break;case c.HTML:dd(e,t);break;case c.FORM:pd(e);break;case c.APPLET:case c.OBJECT:case c.MARQUEE:bd(e,t);break;case c.TEMPLATE:Nt(e,t);break;default:al(e,t)}}function sl(e,t){e.tmplInsertionModeStack.length>0?fl(e,t):di(e,t)}function _d(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 Ad(e,t){e._err(t,w.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Er(e,t){if(e.openElements.currentTagId!==void 0&&el.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=T.IN_TABLE_TEXT,t.type){case K.CHARACTER:ol(e,t);break;case K.WHITESPACE_CHARACTER:ll(e,t);break}else An(e,t)}function Cd(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,D.HTML),e.insertionMode=T.IN_CAPTION}function yd(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,D.HTML),e.insertionMode=T.IN_COLUMN_GROUP}function xd(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(C.COLGROUP,c.COLGROUP),e.insertionMode=T.IN_COLUMN_GROUP,fi(e,t)}function Id(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,D.HTML),e.insertionMode=T.IN_TABLE_BODY}function Nd(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(C.TBODY,c.TBODY),e.insertionMode=T.IN_TABLE_BODY,ir(e,t)}function Sd(e,t){e.openElements.hasInTableScope(c.TABLE)&&(e.openElements.popUntilTagNamePopped(c.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function wd(e,t){il(t)?e._appendElement(t,D.HTML):An(e,t),t.ackSelfClosing=!0}function Ld(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,D.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Ht(e,t){switch(t.tagID){case c.TD:case c.TH:case c.TR:Nd(e,t);break;case c.STYLE:case c.SCRIPT:case c.TEMPLATE:qe(e,t);break;case c.COL:xd(e,t);break;case c.FORM:Ld(e,t);break;case c.TABLE:Sd(e,t);break;case c.TBODY:case c.TFOOT:case c.THEAD:Id(e,t);break;case c.INPUT:wd(e,t);break;case c.CAPTION:Cd(e,t);break;case c.COLGROUP:yd(e,t);break;default:An(e,t)}}function gn(e,t){switch(t.tagID){case c.TABLE:e.openElements.hasInTableScope(c.TABLE)&&(e.openElements.popUntilTagNamePopped(c.TABLE),e._resetInsertionMode());break;case c.TEMPLATE:Nt(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:An(e,t)}}function An(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,nr(e,t),e.fosterParentingEnabled=n}function ll(e,t){e.pendingCharacterTokens.push(t)}function ol(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Zt(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)An(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}var cl=new Set([c.CAPTION,c.COL,c.COLGROUP,c.TBODY,c.TD,c.TFOOT,c.TH,c.THEAD,c.TR]);function Rd(e,t){const n=t.tagID;cl.has(n)?e.openElements.hasInTableScope(c.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(c.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_TABLE,Ht(e,t)):be(e,t)}function Od(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=T.IN_TABLE,n===c.TABLE&&gn(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:rr(e,t)}}function fi(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.COL:e._appendElement(t,D.HTML),t.ackSelfClosing=!0;break;case c.TEMPLATE:qe(e,t);break;default:qn(e,t)}}function Dd(e,t){switch(t.tagID){case c.COLGROUP:e.openElements.currentTagId===c.COLGROUP&&(e.openElements.pop(),e.insertionMode=T.IN_TABLE);break;case c.TEMPLATE:Nt(e,t);break;case c.COL:break;default:qn(e,t)}}function qn(e,t){e.openElements.currentTagId===c.COLGROUP&&(e.openElements.pop(),e.insertionMode=T.IN_TABLE,e._processToken(t))}function ir(e,t){switch(t.tagID){case c.TR:e.openElements.clearBackToTableBodyContext(),e._insertElement(t,D.HTML),e.insertionMode=T.IN_ROW;break;case c.TH:case c.TD:e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(C.TR,c.TR),e.insertionMode=T.IN_ROW,ar(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=T.IN_TABLE,Ht(e,t));break;default:Ht(e,t)}}function jr(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=T.IN_TABLE);break;case c.TABLE:e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE,gn(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:gn(e,t)}}function ar(e,t){switch(t.tagID){case c.TH:case c.TD:e.openElements.clearBackToTableRowContext(),e._insertElement(t,D.HTML),e.insertionMode=T.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=T.IN_TABLE_BODY,ir(e,t));break;default:Ht(e,t)}}function ul(e,t){switch(t.tagID){case c.TR:e.openElements.hasInTableScope(c.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY);break;case c.TABLE:e.openElements.hasInTableScope(c.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,jr(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=T.IN_TABLE_BODY,jr(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:gn(e,t)}}function vd(e,t){const n=t.tagID;cl.has(n)?(e.openElements.hasInTableScope(c.TD)||e.openElements.hasInTableScope(c.TH))&&(e._closeTableCell(),ar(e,t)):be(e,t)}function Pd(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=T.IN_ROW);break;case c.TABLE:case c.TBODY:case c.TFOOT:case c.THEAD:case c.TR:e.openElements.hasInTableScope(n)&&(e._closeTableCell(),ul(e,t));break;case c.BODY:case c.CAPTION:case c.COL:case c.COLGROUP:case c.HTML:break;default:rr(e,t)}}function hl(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.OPTION:e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e._insertElement(t,D.HTML);break;case c.OPTGROUP:e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e.openElements.currentTagId===c.OPTGROUP&&e.openElements.pop(),e._insertElement(t,D.HTML);break;case c.HR:e.openElements.currentTagId===c.OPTION&&e.openElements.pop(),e.openElements.currentTagId===c.OPTGROUP&&e.openElements.pop(),e._appendElement(t,D.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:qe(e,t);break;default:}}function dl(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:Nt(e,t);break;default:}}function Md(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)):hl(e,t)}function Bd(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)):dl(e,t)}function Fd(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:qe(e,t);break;case c.CAPTION:case c.COLGROUP:case c.TBODY:case c.TFOOT:case c.THEAD:e.tmplInsertionModeStack[0]=T.IN_TABLE,e.insertionMode=T.IN_TABLE,Ht(e,t);break;case c.COL:e.tmplInsertionModeStack[0]=T.IN_COLUMN_GROUP,e.insertionMode=T.IN_COLUMN_GROUP,fi(e,t);break;case c.TR:e.tmplInsertionModeStack[0]=T.IN_TABLE_BODY,e.insertionMode=T.IN_TABLE_BODY,ir(e,t);break;case c.TD:case c.TH:e.tmplInsertionModeStack[0]=T.IN_ROW,e.insertionMode=T.IN_ROW,ar(e,t);break;default:e.tmplInsertionModeStack[0]=T.IN_BODY,e.insertionMode=T.IN_BODY,be(e,t)}}function Hd(e,t){t.tagID===c.TEMPLATE&&Nt(e,t)}function fl(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(c.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):di(e,t)}function Ud(e,t){t.tagID===c.HTML?be(e,t):Vn(e,t)}function pl(e,t){var n;if(t.tagID===c.HTML){if(e.fragmentContext||(e.insertionMode=T.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 Vn(e,t)}function Vn(e,t){e.insertionMode=T.IN_BODY,nr(e,t)}function jd(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.FRAMESET:e._insertElement(t,D.HTML);break;case c.FRAME:e._appendElement(t,D.HTML),t.ackSelfClosing=!0;break;case c.NOFRAMES:qe(e,t);break;default:}}function zd(e,t){t.tagID===c.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==c.FRAMESET&&(e.insertionMode=T.AFTER_FRAMESET))}function $d(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.NOFRAMES:qe(e,t);break;default:}}function Yd(e,t){t.tagID===c.HTML&&(e.insertionMode=T.AFTER_AFTER_FRAMESET)}function qd(e,t){t.tagID===c.HTML?be(e,t):jn(e,t)}function jn(e,t){e.insertionMode=T.IN_BODY,nr(e,t)}function Vd(e,t){switch(t.tagID){case c.HTML:be(e,t);break;case c.NOFRAMES:qe(e,t);break;default:}}function Wd(e,t){t.chars="�",e._insertCharacters(t)}function Qd(e,t){e._insertCharacters(t),e.framesetOk=!1}function ml(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==D.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function Gd(e,t){if(uh(t))ml(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===D.MATHML?Zs(t):r===D.SVG&&(hh(t),Js(t)),ui(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function Kd(e,t){if(t.tagID===c.P||t.tagID===c.BR){ml(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)===D.HTML){e._endTagOutsideForeignContent(t);break}const i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}var XA=new Set([C.AREA,C.BASE,C.BASEFONT,C.BGSOUND,C.BR,C.COL,C.EMBED,C.FRAME,C.HR,C.IMG,C.INPUT,C.KEYGEN,C.LINK,C.META,C.PARAM,C.SOURCE,C.TRACK,C.WBR]),sr=gl("end"),Xe=gl("start");function gl(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 El(e){const t=Xe(e),n=sr(e);if(t&&n)return{start:t,end:n}}var Xd=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,Zd=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),da={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function Tl(e,t){const n=cf(e),r=js("type",{handlers:{root:Jd,element:ef,text:tf,comment:kl,doctype:nf,raw:af},unknown:sf}),i={parser:n?new ca(da):ca.getFragmentParser(void 0,da),handle(s){r(s,i)},stitches:!1,options:t||{}};r(e,i),Yt(i,Xe());const a=cu(n?i.parser.document:i.parser.getFragment(),{file:i.options.file});return i.stitches&&Ke(a,"comment",function(s,o,l){const u=s;if(u.value.stitch&&l&&o!==void 0){const h=l.children;return h[o]=u.value.stitch,o}}),a.type==="root"&&a.children.length===1&&a.children[0].type===e.type?a.children[0]:a}function bl(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function Jd(e,t){bl(e.children,t)}function ef(e,t){lf(e,t),bl(e.children,t),of(e,t)}function tf(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:K.CHARACTER,chars:e.value,location:Cn(e)};Yt(t,Xe(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function nf(e,t){const n={type:K.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:Cn(e)};Yt(t,Xe(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function rf(e,t){t.stitches=!0;const n=uf(e);"children"in e&&"children"in n&&(n.children=Tl({type:"root",children:e.children},t.options).children),kl({type:"comment",value:{stitch:n}},t)}function kl(e,t){const n=e.value,r={type:K.COMMENT,data:n,location:Cn(e)};Yt(t,Xe(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function af(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,_l(t,Xe(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(Xd,"<$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 sf(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))rf(n,t);else{let r="";throw Zd.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 Yt(e,t){_l(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=de.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 _l(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 lf(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===de.PLAINTEXT)return;Yt(t,Xe(e));const r=t.parser.openElements.current;let i="namespaceURI"in r?r.namespaceURI:_t.html;i===_t.html&&n==="svg"&&(i=_t.svg);const a=pu({...e,children:[]},{space:i===_t.svg?"svg":"html"}),s={type:K.START_TAG,tagName:n,tagID:$t(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:Cn(e)};t.parser.currentToken=s,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function of(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&Au.includes(n)||t.parser.tokenizer.state===de.PLAINTEXT)return;Yt(t,sr(e));const r={type:K.END_TAG,tagName:n,tagID:$t(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:Cn(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===de.RCDATA||t.parser.tokenizer.state===de.RAWTEXT||t.parser.tokenizer.state===de.SCRIPT_DATA)&&(t.parser.tokenizer.state=de.DATA)}function cf(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function Cn(e){const t=Xe(e)||{line:void 0,column:void 0,offset:void 0},n=sr(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 uf(e){return"children"in e?Ct({...e,children:[]}):Ct(e)}function zr(e){return function(t,n){return Tl(t,{...e,file:n})}}var Et=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],bt={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Et,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Et],h2:[["className","sr-only"]],img:[...Et,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Et,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Et],table:[...Et],ul:[...Et,["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"]},ct={}.hasOwnProperty;function hf(e,t){let n={type:"root",children:[]};const r=Al({schema:t?{...bt,...t}:bt,stack:[]},e);return r&&(Array.isArray(r)?r.length===1?n=r[0]:n.children=r:n=r),n}function Al(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return df(e,n);case"doctype":return ff(e,n);case"element":return pf(e,n);case"root":return mf(e,n);case"text":return gf(e,n);default:}}}function df(e,t){if(e.schema.allowComments){const n=typeof t.value=="string"?t.value:"",r=n.indexOf("-->"),i={type:"comment",value:r<0?n:n.slice(0,r)};return yn(i,t),i}}function ff(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return yn(n,t),n}}function pf(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=Cl(e,t.children),i=Ef(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&&ct.call(e.schema.ancestors,n))){const o=e.schema.ancestors[n];let l=-1;for(a=!1;++l<o.length;)e.stack.includes(o[l])&&(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 yn(s,t),s}function mf(e,t){const n={type:"root",children:Cl(e,t.children)};return yn(n,t),n}function gf(e,t){const n={type:"text",value:typeof t.value=="string"?t.value:""};return yn(n,t),n}function Cl(e,t){const n=[];if(Array.isArray(t)){const r=t;let i=-1;for(;++i<r.length;){const a=Al(e,r[i]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function Ef(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,i=e.schema.required,a=r&&ct.call(r,n)?r[n]:void 0,s=r&&ct.call(r,"*")?r["*"]:void 0,o=t&&typeof t=="object"?t:{},l={};let u;for(u in o)if(ct.call(o,u)){const h=o[u];let d=fa(e,pa(a,u),u,h);d==null&&(d=fa(e,pa(s,u),u,h)),d!=null&&(l[u]=d)}if(i&&ct.call(i,n)){const h=i[n];for(u in h)ct.call(h,u)&&!ct.call(l,u)&&(l[u]=h[u])}return l}function fa(e,t,n,r){return t?Array.isArray(r)?Tf(e,t,n,r):yl(e,t,n,r):void 0}function Tf(e,t,n,r){let i=-1;const a=[];for(;++i<r.length;){const s=yl(e,t,n,r[i]);(typeof s=="number"||typeof s=="string")&&a.push(s)}return a}function yl(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&bf(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 bf(e,t,n){const r=e.schema.protocols&&ct.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("#"),l=i.indexOf("/");if(a<0||l>-1&&a>l||s>-1&&a>s||o>-1&&a>o)return!0;let u=-1;for(;++u<r.length;){const h=r[u];if(a===h.length&&i.slice(0,h.length)===h)return!0}return!1}function yn(e,t){const n=El(t);t.data&&(e.data=Ct(t.data)),n&&(e.position=n)}function pa(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 xl(e){return function(t){return hf(t,e)}}function ma(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}var ye=pt(/[A-Za-z]/),Te=pt(/[\dA-Za-z]/),kf=pt(/[#-'*+\--9=?A-Z^-~]/);function Wn(e){return e!==null&&(e<32||e===127)}var $r=pt(/\d/),_f=pt(/[\dA-Fa-f]/),Af=pt(/[!-/:-@[-`{-~]/);function Y(e){return e!==null&&e<-2}function se(e){return e!==null&&(e<0||e===32)}function ee(e){return e===-2||e===-1||e===32}var lr=pt(/\p{P}|\p{S}/u),yt=pt(/\s/);function pt(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Cf(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function yf(e,t,n){const r=Jn((n||{}).ignore||[]),i=xf(t);let a=-1;for(;++a<i.length;)si(e,"text",s);function s(l,u){let h=-1,d;for(;++h<u.length;){const p=u[h],f=d?d.children:void 0;if(r(p,f?f.indexOf(p):void 0,d))return;d=p}if(d)return o(l,u)}function o(l,u){const h=u[u.length-1],d=i[a][0],p=i[a][1];let f=0;const E=h.children.indexOf(l);let I=!1,S=[];d.lastIndex=0;let k=d.exec(l.value);for(;k;){const L=k.index,R={index:k.index,input:k.input,stack:[...u,l]};let B=p(...k,R);if(typeof B=="string"&&(B=B.length>0?{type:"text",value:B}:void 0),B===!1?d.lastIndex=L+1:(f!==L&&S.push({type:"text",value:l.value.slice(f,L)}),Array.isArray(B)?S.push(...B):B&&S.push(B),f=L+k[0].length,I=!0),!d.global)break;k=d.exec(l.value)}return I?(f<l.value.length&&S.push({type:"text",value:l.value.slice(f)}),h.children.splice(E,1,...S)):S=[l],E+S.length}}function xf(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([If(i[0]),Nf(i[1])])}return t}function If(e){return typeof e=="string"?new RegExp(Cf(e),"g"):e}function Nf(e){return typeof e=="function"?e:function(){return e}}var Tr="phrasing",br=["autolink","link","image","label"];function Sf(){return{transforms:[Pf],enter:{literalAutolink:Lf,literalAutolinkEmail:kr,literalAutolinkHttp:kr,literalAutolinkWww:kr},exit:{literalAutolink:vf,literalAutolinkEmail:Df,literalAutolinkHttp:Rf,literalAutolinkWww:Of}}}function wf(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Tr,notInConstruct:br},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Tr,notInConstruct:br},{character:":",before:"[ps]",after:"\\/",inConstruct:Tr,notInConstruct:br}]}}function Lf(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function kr(e){this.config.enter.autolinkProtocol.call(this,e)}function Rf(e){this.config.exit.autolinkProtocol.call(this,e)}function Of(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function Df(e){this.config.exit.autolinkEmail.call(this,e)}function vf(e){this.exit(e)}function Pf(e){yf(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Mf],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,Bf]],{ignore:["link","linkReference"]})}function Mf(e,t,n,r,i){let a="";if(!Il(i)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!Ff(n)))return!1;const s=Hf(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 Bf(e,t,n,r){return!Il(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function Ff(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 Hf(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=ma(e,"(");let a=ma(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 Il(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||yt(n)||lr(n))&&(!t||n!==47)}function Ye(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}Nl.peek=Qf;function Uf(){this.buffer()}function jf(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function zf(){this.buffer()}function $f(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function Yf(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Ye(this.sliceSerialize(e)).toLowerCase(),n.label=t}function qf(e){this.exit(e)}function Vf(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=Ye(this.sliceSerialize(e)).toLowerCase(),n.label=t}function Wf(e){this.exit(e)}function Qf(){return"["}function Nl(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const s=n.enter("footnoteReference"),o=n.enter("reference");return a+=i.move(n.safe(n.associationId(e),{after:"]",before:a})),o(),s(),a+=i.move("]"),a}function Gf(){return{enter:{gfmFootnoteCallString:Uf,gfmFootnoteCall:jf,gfmFootnoteDefinitionLabelString:zf,gfmFootnoteDefinition:$f},exit:{gfmFootnoteCallString:Yf,gfmFootnoteCall:qf,gfmFootnoteDefinitionLabelString:Vf,gfmFootnoteDefinition:Wf}}}function Kf(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:Nl},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,i,a,s){const o=a.createTracker(s);let l=o.move("[^");const u=a.enter("footnoteDefinition"),h=a.enter("label");return l+=o.move(a.safe(a.associationId(r),{before:l,after:"]"})),h(),l+=o.move("]:"),r.children&&r.children.length>0&&(o.shift(4),l+=o.move((t?`
|
|
4
4
|
`:" ")+a.indentLines(a.containerFlow(r,o.current()),t?Sl:Xf))),u(),l}}function Xf(e,t,n){return t===0?e:Sl(e,t,n)}function Sl(e,t,n){return(n?"":" ")+e}var Zf=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];wl.peek=rp;function Jf(){return{canContainEols:["delete"],enter:{strikethrough:tp},exit:{strikethrough:np}}}function ep(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:Zf}],handlers:{delete:wl}}}function tp(e){this.enter({type:"delete",children:[]},e)}function np(e){this.exit(e)}function wl(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 rp(){return"~"}function ip(e){return e.length}function ap(e,t){const n=t||{},r=(n.align||[]).concat(),i=n.stringLength||ip,a=[],s=[],o=[],l=[];let u=0,h=-1;for(;++h<e.length;){const I=[],S=[];let k=-1;for(e[h].length>u&&(u=e[h].length);++k<e[h].length;){const L=sp(e[h][k]);if(n.alignDelimiters!==!1){const R=i(L);S[k]=R,(l[k]===void 0||R>l[k])&&(l[k]=R)}I.push(L)}s[h]=I,o[h]=S}let d=-1;if(typeof r=="object"&&"length"in r)for(;++d<u;)a[d]=ga(r[d]);else{const I=ga(r);for(;++d<u;)a[d]=I}d=-1;const p=[],f=[];for(;++d<u;){const I=a[d];let S="",k="";I===99?(S=":",k=":"):I===108?S=":":I===114&&(k=":");let L=n.alignDelimiters===!1?1:Math.max(1,l[d]-S.length-k.length);const R=S+"-".repeat(L)+k;n.alignDelimiters!==!1&&(L=S.length+L+k.length,L>l[d]&&(l[d]=L),f[d]=L),p[d]=R}s.splice(1,0,p),o.splice(1,0,f),h=-1;const E=[];for(;++h<s.length;){const I=s[h],S=o[h];d=-1;const k=[];for(;++d<u;){const L=I[d]||"";let R="",B="";if(n.alignDelimiters!==!1){const P=l[d]-(S[d]||0),N=a[d];N===114?R=" ".repeat(P):N===99?P%2?(R=" ".repeat(P/2+.5),B=" ".repeat(P/2-.5)):(R=" ".repeat(P/2),B=R):B=" ".repeat(P)}n.delimiterStart!==!1&&!d&&k.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&L==="")&&(n.delimiterStart!==!1||d)&&k.push(" "),n.alignDelimiters!==!1&&k.push(R),k.push(L),n.alignDelimiters!==!1&&k.push(B),n.padding!==!1&&k.push(" "),(n.delimiterEnd!==!1||d!==u-1)&&k.push("|")}E.push(n.delimiterEnd===!1?k.join("").replace(/ +$/,""):k.join(""))}return E.join(`
|
|
5
5
|
`)}function sp(e){return e==null?"":String(e)}function ga(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 lp(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()),op);return i(),s}function op(e,t,n){return">"+(n?"":" ")+e}function cp(e,t){return Ea(e,t.inConstruct,!0)&&!Ea(e,t.notInConstruct,!1)}function Ea(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 Ta(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
|
|
@@ -109,14 +109,14 @@ ${e}</tr>
|
|
|
109
109
|
`}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>${We(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=ts(e);if(i===null)return r;e=i;let a='<a href="'+e+'"';return t&&(a+=' title="'+We(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=ts(e);if(i===null)return We(n);e=i;let a=`<img src="${e}" alt="${We(n)}"`;return t&&(a+=` title="${We(t)}"`),a+=">",a}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:We(e.text)}},Di=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}},$e=class Zr{options;renderer;textRenderer;constructor(t){this.options=t||wt,this.options.renderer=this.options.renderer||new Xn,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Di}static parse(t,n){return new Zr(n).parse(t)}static parseInline(t,n){return new Zr(n).parseInline(t)}parse(t){this.renderer.parser=this;let n="";for(let r=0;r<t.length;r++){let i=t[r];if(this.options.extensions?.renderers?.[i.type]){let s=i,o=this.options.extensions.renderers[s.type].call({parser:this},s);if(o!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(s.type)){n+=o||"";continue}}let a=i;switch(a.type){case"space":n+=this.renderer.space(a);break;case"hr":n+=this.renderer.hr(a);break;case"heading":n+=this.renderer.heading(a);break;case"code":n+=this.renderer.code(a);break;case"table":n+=this.renderer.table(a);break;case"blockquote":n+=this.renderer.blockquote(a);break;case"list":n+=this.renderer.list(a);break;case"checkbox":n+=this.renderer.checkbox(a);break;case"html":n+=this.renderer.html(a);break;case"def":n+=this.renderer.def(a);break;case"paragraph":n+=this.renderer.paragraph(a);break;case"text":n+=this.renderer.text(a);break;default:{let s='Token with "'+a.type+'" type was not found.';if(this.options.silent)return console.error(s),"";throw new Error(s)}}}return n}parseInline(t,n=this.renderer){this.renderer.parser=this;let r="";for(let i=0;i<t.length;i++){let a=t[i];if(this.options.extensions?.renderers?.[a.type]){let o=this.options.extensions.renderers[a.type].call({parser:this},a);if(o!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(a.type)){r+=o||"";continue}}let s=a;switch(s.type){case"escape":r+=n.text(s);break;case"html":r+=n.html(s);break;case"link":r+=n.link(s);break;case"image":r+=n.image(s);break;case"checkbox":r+=n.checkbox(s);break;case"strong":r+=n.strong(s);break;case"em":r+=n.em(s);break;case"codespan":r+=n.codespan(s);break;case"br":r+=n.br(s);break;case"del":r+=n.del(s);break;case"text":r+=n.text(s);break;default:{let o='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(o),"";throw new Error(o)}}}return r}},an=class{options;block;constructor(e){this.options=e||wt}static passThroughHooks=new Set(["preprocess","postprocess","processAllTokens","emStrongMask"]);static passThroughHooksRespectAsync=new Set(["preprocess","postprocess","processAllTokens"]);preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}emStrongMask(e){return e}provideLexer(e=this.block){return e?Ue.lex:Ue.lexInline}provideParser(e=this.block){return e?$e.parse:$e.parseInline}},s_=class{defaults=xi();options=this.setOptions;parse=this.parseMarkdown(!0);parseInline=this.parseMarkdown(!1);Parser=$e;Renderer=Xn;TextRenderer=Di;Lexer=Ue;Tokenizer=Kn;Hooks=an;constructor(...e){this.use(...e)}walkTokens(e,t){let n=[];for(let r of e)switch(n=n.concat(t.call(this,r)),r.type){case"table":{let i=r;for(let a of i.header)n=n.concat(this.walkTokens(a.tokens,t));for(let a of i.rows)for(let s of a)n=n.concat(this.walkTokens(s.tokens,t));break}case"list":{let i=r;n=n.concat(this.walkTokens(i.items,t));break}default:{let i=r;this.defaults.extensions?.childTokens?.[i.type]?this.defaults.extensions.childTokens[i.type].forEach(a=>{let s=i[a].flat(1/0);n=n.concat(this.walkTokens(s,t))}):i.tokens&&(n=n.concat(this.walkTokens(i.tokens,t)))}}return n}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(n=>{let r={...n};if(r.async=this.defaults.async||r.async||!1,n.extensions&&(n.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if("renderer"in i){let a=t.renderers[i.name];a?t.renderers[i.name]=function(...s){let o=i.renderer.apply(this,s);return o===!1&&(o=a.apply(this,s)),o}:t.renderers[i.name]=i.renderer}if("tokenizer"in i){if(!i.level||i.level!=="block"&&i.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let a=t[i.level];a?a.unshift(i.tokenizer):t[i.level]=[i.tokenizer],i.start&&(i.level==="block"?t.startBlock?t.startBlock.push(i.start):t.startBlock=[i.start]:i.level==="inline"&&(t.startInline?t.startInline.push(i.start):t.startInline=[i.start]))}"childTokens"in i&&i.childTokens&&(t.childTokens[i.name]=i.childTokens)}),r.extensions=t),n.renderer){let i=this.defaults.renderer||new Xn(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],l=i[s];i[s]=(...u)=>{let h=o.apply(i,u);return h===!1&&(h=l.apply(i,u)),h||""}}r.renderer=i}if(n.tokenizer){let i=this.defaults.tokenizer||new Kn(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],l=i[s];i[s]=(...u)=>{let h=o.apply(i,u);return h===!1&&(h=l.apply(i,u)),h}}r.tokenizer=i}if(n.hooks){let i=this.defaults.hooks||new an;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],l=i[s];an.passThroughHooks.has(a)?i[s]=u=>{if(this.defaults.async&&an.passThroughHooksRespectAsync.has(a))return(async()=>{let d=await o.call(i,u);return l.call(i,d)})();let h=o.call(i,u);return l.call(i,h)}:i[s]=(...u)=>{if(this.defaults.async)return(async()=>{let d=await o.apply(i,u);return d===!1&&(d=await l.apply(i,u)),d})();let h=o.apply(i,u);return h===!1&&(h=l.apply(i,u)),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 Ue.lex(e,t??this.defaults)}parser(e,t){return $e.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):e?Ue.lex:Ue.lexInline)(s,i),l=i.hooks?await i.hooks.processAllTokens(o):o;i.walkTokens&&await Promise.all(this.walkTokens(l,i.walkTokens));let u=await(i.hooks?await i.hooks.provideParser(e):e?$e.parse:$e.parseInline)(l,i);return i.hooks?await i.hooks.postprocess(u):u})().catch(a);try{i.hooks&&(t=i.hooks.preprocess(t));let s=(i.hooks?i.hooks.provideLexer(e):e?Ue.lex:Ue.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):e?$e.parse:$e.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+=`
|
|
110
110
|
Please report this to https://github.com/markedjs/marked.`,e){let r="<p>An error occurred:</p><pre>"+We(n.message+"",!0)+"</pre>";return t?Promise.resolve(r):r}if(t)return Promise.reject(n);throw n}}},xt=new s_;function ae(e,t){return xt.parse(e,t)}ae.options=ae.setOptions=function(e){return xt.setOptions(e),ae.defaults=xt.defaults,No(ae.defaults),ae};ae.getDefaults=xi;ae.defaults=wt;ae.use=function(...e){return xt.use(...e),ae.defaults=xt.defaults,No(ae.defaults),ae};ae.walkTokens=function(e,t){return xt.walkTokens(e,t)};ae.parseInline=xt.parseInline;ae.Parser=$e;ae.parser=$e.parse;ae.Renderer=Xn;ae.TextRenderer=Di;ae.Lexer=Ue;ae.lexer=Ue.lex;ae.Tokenizer=Kn;ae.Hooks=an;ae.parse=ae;var ZA=ae.options,JA=ae.setOptions,eC=ae.use,tC=ae.walkTokens,nC=ae.parseInline;var rC=$e.parse,iC=Ue.lex,l_=300,o_="300px",c_=500;function u_(e={}){let{immediate:t=!1,debounceDelay:n=l_,rootMargin:r=o_,idleTimeout:i=c_}=e,[a,s]=(0,y.useState)(!1),o=(0,y.useRef)(null),l=(0,y.useRef)(null),u=(0,y.useRef)(null),h=(0,y.useMemo)(()=>f=>{let E=Date.now();return window.setTimeout(()=>{f({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-E))})},1)},[]),d=(0,y.useMemo)(()=>typeof window<"u"&&window.requestIdleCallback?(f,E)=>window.requestIdleCallback(f,E):h,[h]),p=(0,y.useMemo)(()=>typeof window<"u"&&window.cancelIdleCallback?f=>window.cancelIdleCallback(f):f=>{clearTimeout(f)},[]);return(0,y.useEffect)(()=>{if(t){s(!0);return}let f=o.current;if(!f)return;l.current&&(clearTimeout(l.current),l.current=null),u.current&&(p(u.current),u.current=null);let E=()=>{l.current&&(clearTimeout(l.current),l.current=null),u.current&&(p(u.current),u.current=null)},I=R=>{u.current=d(B=>{B.timeRemaining()>0||B.didTimeout?(s(!0),R.disconnect()):u.current=d(()=>{s(!0),R.disconnect()},{timeout:i/2})},{timeout:i})},S=R=>{E(),l.current=window.setTimeout(()=>{var B,P;let N=R.takeRecords();(N.length===0||(P=(B=N.at(-1))==null?void 0:B.isIntersecting)!=null&&P)&&I(R)},n)},k=(R,B)=>{R.isIntersecting?S(B):E()},L=new IntersectionObserver(R=>{for(let B of R)k(B,L)},{rootMargin:r,threshold:0});return L.observe(f),()=>{l.current&&clearTimeout(l.current),u.current&&p(u.current),L.disconnect()}},[t,n,r,i,p,d]),{shouldRender:a,containerRef:o}}var Mo=/\s/,h_=/^\s+$/,d_=new Set(["code","pre","svg","math","annotation"]),f_=e=>typeof e=="object"&&e!==null&&"type"in e&&e.type==="element",p_=e=>e.some(t=>f_(t)&&d_.has(t.tagName)),m_=e=>{let t=[],n="",r=!1;for(let i of e){let a=Mo.test(i);a!==r&&n&&(t.push(n),n=""),n+=i,r=a}return n&&t.push(n),t},g_=e=>{let t=[],n="";for(let r of e)Mo.test(r)?n+=r:(n&&(t.push(n),n=""),t.push(r));return n&&t.push(n),t},E_=(e,t,n,r,i,a)=>{let s=`--sd-animation:sd-${t};--sd-duration:${i?0:n}ms;--sd-easing:${r}`;return a&&(s+=`;--sd-delay:${a}ms`),{type:"element",tagName:"span",properties:{"data-sd-animate":!0,style:s},children:[{type:"text",value:e}]}},T_=(e,t,n,r,i)=>{let a=t.at(-1);if(!(a&&"children"in a))return;if(p_(t))return nn;let s=a,o=s.children.indexOf(e);if(o===-1)return;let l=e.value;if(!l.trim()){i.count+=l.length;return}let u=n.sep==="char"?g_(l):m_(l),h=r.prevContentLength,d=u.map(p=>{let f=i.count;if(i.count+=p.length,h_.test(p))return{type:"text",value:p};let E=h>0&&f<h,I=E?0:i.newIndex++*n.stagger;return E_(p,n.animation,n.duration,n.easing,E,I)});return s.children.splice(o,1,...d),o+d.length},b_=0;function Jr(e){var t,n,r,i,a;let s={animation:(t=e?.animation)!=null?t:"fadeIn",duration:(n=e?.duration)!=null?n:150,easing:(r=e?.easing)!=null?r:"ease",sep:(i=e?.sep)!=null?i:"word",stagger:(a=e?.stagger)!=null?a:40},o={prevContentLength:0,lastRenderCharCount:0},l=b_++,u=()=>h=>{let d={count:0,newIndex:0};si(h,"text",(p,f)=>T_(p,f,s,o,d)),o.lastRenderCharCount=d.count,o.prevContentLength=0};return Object.defineProperty(u,"name",{value:`rehypeAnimate$${l}`}),{name:"animate",type:"animate",rehypePlugin:u,setPrevContentLength(h){o.prevContentLength=h},getLastRenderCharCount(){let h=o.lastRenderCharCount;return o.lastRenderCharCount=0,h}}}Jr();var Bo=(0,y.createContext)(!1),k_=()=>(0,y.useContext)(Bo),vi=(...e)=>xs(ys(e)),__=(e,t)=>{if(!e||!t)return t;let n=`${e}:`;return t.split(/\s+/).filter(Boolean).map(r=>r.startsWith(n)?r:`${e}:${r}`).join(" ")},A_=e=>e?(...t)=>__(e,xs(ys(t))):vi,Bt=(e,t,n)=>{let r=typeof t=="string"&&n.startsWith("text/csv")?"\uFEFF":"",i=typeof t=="string"?new Blob([r+t],{type:n}):t,a=URL.createObjectURL(i),s=document.createElement("a");s.href=a,s.download=e,document.body.appendChild(s),s.click(),document.body.removeChild(s),URL.revokeObjectURL(a)},ei=(0,y.createContext)(vi),X=()=>(0,y.useContext)(ei),C_=vi("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"),y_=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},x_=(0,y.memo)(({children:e,result:t,language:n,className:r,startLine:i,lineNumbers:a=!0,...s})=>{let o=X(),l=(0,y.useMemo)(()=>o(C_),[o]),u=(0,y.useMemo)(()=>{let h={};return t.bg&&(h["--sdm-bg"]=t.bg),t.fg&&(h["--sdm-fg"]=t.fg),t.rootStyle&&Object.assign(h,y_(t.rootStyle)),h},[t.bg,t.fg,t.rootStyle]);return(0,b.jsx)("div",{className:o(r,"overflow-x-auto rounded-md border border-border bg-background p-4 text-sm"),"data-language":n,"data-streamdown":"code-block-body",...s,children:(0,b.jsx)("pre",{className:o(r,"bg-[var(--sdm-bg,inherit]","dark:bg-[var(--shiki-dark-bg,var(--sdm-bg,inherit)]"),style:u,children:(0,b.jsx)("code",{className:a?o("[counter-increment:line_0] [counter-reset:line]"):void 0,style:a&&i&&i>1?{counterReset:`line ${i-1}`}:void 0,children:t.tokens.map((h,d)=>(0,b.jsx)("span",{className:a?l:void 0,children:h.length===0||h.length===1&&h[0].content===""?`
|
|
111
111
|
`:h.map((p,f)=>{let E={},I=!!p.bgColor;if(p.color&&(E["--sdm-c"]=p.color),p.bgColor&&(E["--sdm-tbg"]=p.bgColor),p.htmlStyle)for(let[S,k]of Object.entries(p.htmlStyle))S==="color"?E["--sdm-c"]=k:S==="background-color"?(E["--sdm-tbg"]=k,I=!0):E[S]=k;return(0,b.jsx)("span",{className:o("text-[var(--sdm-c,inherit)]","dark:text-[var(--shiki-dark,var(--sdm-c,inherit))]",I&&"bg-[var(--sdm-tbg)]",I&&"dark:bg-[var(--shiki-dark-bg,var(--sdm-tbg))]"),style:E,...p.htmlAttrs,children:p.content},f)})},d))})})})},(e,t)=>e.result===t.result&&e.language===t.language&&e.className===t.className&&e.startLine===t.startLine&&e.lineNumbers===t.lineNumbers),I_=({className:e,language:t,style:n,isIncomplete:r,...i})=>(0,b.jsx)("div",{className:X()("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}),Fo=(0,y.createContext)({code:""}),Ho=()=>(0,y.useContext)(Fo),N_=({language:e})=>{let t=X();return(0,b.jsx)("div",{className:t("flex h-8 items-center text-muted-foreground text-xs"),"data-language":e,"data-streamdown":"code-block-header",children:(0,b.jsx)("span",{className:t("ml-1 font-mono lowercase"),children:e})})},S_=e=>{let t=e.length;for(;t>0&&e[t-1]===`
|
|
112
|
-
`;)t--;return e.slice(0,t)},w_=(0,y.lazy)(()=>Is(()=>import("./highlighted-body-OFNGDK62-
|
|
112
|
+
`;)t--;return e.slice(0,t)},w_=(0,y.lazy)(()=>Is(()=>import("./highlighted-body-OFNGDK62-BEkQLPsL.js").then(e=>({default:e.HighlightedCodeBlockBody})),__vite__mapDeps([0,1,2,3]))),L_=({code:e,language:t,className:n,children:r,isIncomplete:i=!1,startLine:a,lineNumbers:s,...o})=>{let l=X(),u=(0,y.useMemo)(()=>S_(e),[e]),h=(0,y.useMemo)(()=>({bg:"transparent",fg:"inherit",tokens:u.split(`
|
|
113
113
|
`).map(d=>[{content:d,color:"inherit",bgColor:"transparent",htmlStyle:{},offset:0}])}),[u]);return(0,b.jsx)(Fo.Provider,{value:{code:e},children:(0,b.jsxs)(I_,{isIncomplete:i,language:t,children:[(0,b.jsx)(N_,{language:t}),r?(0,b.jsx)("div",{className:l("pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end"),children:(0,b.jsx)("div",{className:l("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,(0,b.jsx)(y.Suspense,{fallback:(0,b.jsx)(x_,{className:n,language:t,lineNumbers:s,result:h,startLine:a,...o}),children:(0,b.jsx)(w_,{className:n,code:u,language:t,lineNumbers:s,raw:h,startLine:a,...o})})]})})},R_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),O_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),D_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),v_=e=>(0,b.jsxs)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:[(0,b.jsx)("path",{d:"M8 0V4",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M8 16V12",opacity:"0.5",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M3.29773 1.52783L5.64887 4.7639",opacity:"0.9",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M12.7023 1.52783L10.3511 4.7639",opacity:"0.1",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M12.7023 14.472L10.3511 11.236",opacity:"0.4",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M3.29773 14.472L5.64887 11.236",opacity:"0.6",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M15.6085 5.52783L11.8043 6.7639",opacity:"0.2",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M0.391602 10.472L4.19583 9.23598",opacity:"0.7",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M15.6085 10.4722L11.8043 9.2361",opacity:"0.3",stroke:"currentColor",strokeWidth:"1.5"}),(0,b.jsx)("path",{d:"M0.391602 5.52783L4.19583 6.7639",opacity:"0.8",stroke:"currentColor",strokeWidth:"1.5"})]}),P_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),M_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),B_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),F_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),H_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),U_=e=>(0,b.jsx)("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:(0,b.jsx)("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"})}),sn={CheckIcon:R_,CopyIcon:O_,DownloadIcon:D_,ExternalLinkIcon:F_,Loader2Icon:v_,Maximize2Icon:P_,RotateCcwIcon:M_,XIcon:B_,ZoomInIcon:H_,ZoomOutIcon:U_},Uo=(0,y.createContext)(sn),j_=(e,t)=>{if(e===t)return!0;if(!(e&&t))return e===t;let n=Object.keys(e),r=Object.keys(t);return n.length!==r.length?!1:n.every(i=>e[i]===t[i])},is=({icons:e,children:t})=>{let n=(0,y.useRef)(e),r=(0,y.useRef)(e?{...sn,...e}:sn);j_(n.current,e)||(n.current=e,r.current=e?{...sn,...e}:sn);let i=r.current;return(0,b.jsx)(Uo.Provider,{value:i,children:t})},Ve=()=>(0,y.useContext)(Uo),jo={copyCode:"Copy Code",downloadFile:"Download file",downloadDiagram:"Download diagram",downloadDiagramAsSvg:"Download diagram as SVG",downloadDiagramAsPng:"Download diagram as PNG",downloadDiagramAsMmd:"Download diagram as MMD",viewFullscreen:"View fullscreen",exitFullscreen:"Exit fullscreen",mermaidFormatSvg:"SVG",mermaidFormatPng:"PNG",mermaidFormatMmd:"MMD",copyTable:"Copy table",copyTableAsMarkdown:"Copy table as Markdown",copyTableAsCsv:"Copy table as CSV",copyTableAsTsv:"Copy table as TSV",downloadTable:"Download table",downloadTableAsCsv:"Download table as CSV",downloadTableAsMarkdown:"Download table as Markdown",tableFormatMarkdown:"Markdown",tableFormatCsv:"CSV",tableFormatTsv:"TSV",imageNotAvailable:"Image not available",downloadImage:"Download image",openExternalLink:"Open external link?",externalLinkWarning:"You're about to visit an external website.",close:"Close",copyLink:"Copy link",copied:"Copied",openLink:"Open link"},ti=(0,y.createContext)(jo),it=()=>(0,y.useContext)(ti),as=({onCopy:e,onError:t,timeout:n=2e3,children:r,className:i,code:a,...s})=>{let o=X(),[l,u]=(0,y.useState)(!1),h=(0,y.useRef)(0),{code:d}=Ho(),{isAnimating:p}=(0,y.useContext)(Me),f=it(),E=a??d,I=async()=>{var L;if(typeof window>"u"||!((L=navigator?.clipboard)!=null&&L.writeText)){t?.(new Error("Clipboard API not available"));return}try{l||(await navigator.clipboard.writeText(E),u(!0),e?.(),h.current=window.setTimeout(()=>u(!1),n))}catch(R){t?.(R)}};(0,y.useEffect)(()=>()=>{window.clearTimeout(h.current)},[]);let S=Ve(),k=l?S.CheckIcon:S.CopyIcon;return(0,b.jsx)("button",{className:o("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:p,onClick:I,title:f.copyCode,type:"button",...s,children:r??(0,b.jsx)(k,{size:14})})},ss={"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"},z_=({onDownload:e,onError:t,language:n,children:r,className:i,code:a,...s})=>{let o=X(),{code:l}=Ho(),{isAnimating:u}=(0,y.useContext)(Me),h=it(),d=Ve(),p=a??l,f=`file.${n&&n in ss?ss[n]:"txt"}`,E="text/plain",I=()=>{try{Bt(f,p,E),e?.()}catch(S){t?.(S)}};return(0,b.jsx)("button",{className:o("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:I,title:h.downloadFile,type:"button",...s,children:r??(0,b.jsx)(d.DownloadIcon,{size:14})})},ls=()=>{let{Loader2Icon:e}=Ve(),t=X();return(0,b.jsxs)("div",{className:t("w-full divide-y divide-border overflow-hidden rounded-xl border border-border"),children:[(0,b.jsx)("div",{className:t("h-[46px] w-full bg-muted/80")}),(0,b.jsx)("div",{className:t("flex w-full items-center justify-center p-4"),children:(0,b.jsx)(e,{className:t("size-4 animate-spin")})})]})},$_=/\.[^/.]+$/,Y_=({node:e,className:t,src:n,alt:r,onLoad:i,onError:a,...s})=>{let{DownloadIcon:o}=Ve(),l=X(),u=(0,y.useRef)(null),[h,d]=(0,y.useState)(!1),[p,f]=(0,y.useState)(!1),E=it(),I=s.width!=null||s.height!=null,S=(h||I)&&!p,k=p&&!I;(0,y.useEffect)(()=>{let P=u.current;if(P!=null&&P.complete){let N=P.naturalWidth>0;d(N),f(!N)}},[]);let L=(0,y.useCallback)(P=>{d(!0),f(!1),i?.(P)},[i]),R=(0,y.useCallback)(P=>{d(!1),f(!0),a?.(P)},[a]),B=async()=>{if(n)try{let P=await(await fetch(n)).blob(),N=new URL(n,window.location.origin).pathname.split("/").pop()||"",$=N.split(".").pop(),V=N.includes(".")&&$!==void 0&&$.length<=4,q="";if(V)q=N;else{let x=P.type,U="png";x.includes("jpeg")||x.includes("jpg")?U="jpg":x.includes("png")?U="png":x.includes("svg")?U="svg":x.includes("gif")?U="gif":x.includes("webp")&&(U="webp"),q=`${(r||N||"image").replace($_,"")}.${U}`}Bt(q,P,P.type)}catch{window.open(n,"_blank")}};return n?(0,b.jsxs)("div",{className:l("group relative my-4 inline-block"),"data-streamdown":"image-wrapper",children:[(0,b.jsx)("img",{alt:r,className:l("max-w-full rounded-lg",k&&"hidden",t),"data-streamdown":"image",onError:R,onLoad:L,ref:u,src:n,...s}),k&&(0,b.jsx)("span",{className:l("text-muted-foreground text-xs italic"),"data-streamdown":"image-fallback",children:E.imageNotAvailable}),(0,b.jsx)("div",{className:l("pointer-events-none absolute inset-0 hidden rounded-lg bg-black/10 group-hover:block")}),S&&(0,b.jsx)("button",{className:l("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:B,title:E.downloadImage,type:"button",children:(0,b.jsx)(o,{size:14})})]}):null},pn=0,Pi=()=>{pn+=1,pn===1&&(document.body.style.overflow="hidden")},Mi=()=>{pn=Math.max(0,pn-1),pn===0&&(document.body.style.overflow="")},q_=({url:e,isOpen:t,onClose:n,onConfirm:r})=>{let{CheckIcon:i,CopyIcon:a,ExternalLinkIcon:s,XIcon:o}=Ve(),l=X(),[u,h]=(0,y.useState)(!1),d=it(),p=(0,y.useCallback)(async()=>{try{await navigator.clipboard.writeText(e),h(!0),setTimeout(()=>h(!1),2e3)}catch{}},[e]),f=(0,y.useCallback)(()=>{r(),n()},[r,n]);return(0,y.useEffect)(()=>{if(t){Pi();let E=I=>{I.key==="Escape"&&n()};return document.addEventListener("keydown",E),()=>{document.removeEventListener("keydown",E),Mi()}}},[t,n]),t?(0,b.jsx)("div",{className:l("fixed inset-0 z-50 flex items-center justify-center bg-background/50 backdrop-blur-sm"),"data-streamdown":"link-safety-modal",onClick:n,onKeyDown:E=>{E.key==="Escape"&&n()},role:"button",tabIndex:0,children:(0,b.jsxs)("div",{className:l("relative mx-4 flex w-full max-w-md flex-col gap-4 rounded-xl border bg-background p-6 shadow-lg"),onClick:E=>E.stopPropagation(),onKeyDown:E=>E.stopPropagation(),role:"presentation",children:[(0,b.jsx)("button",{className:l("absolute top-4 right-4 rounded-md p-1 text-muted-foreground transition-all hover:bg-muted hover:text-foreground"),onClick:n,title:d.close,type:"button",children:(0,b.jsx)(o,{size:16})}),(0,b.jsxs)("div",{className:l("flex flex-col gap-2"),children:[(0,b.jsxs)("div",{className:l("flex items-center gap-2 font-semibold text-lg"),children:[(0,b.jsx)(s,{size:20}),(0,b.jsx)("span",{children:d.openExternalLink})]}),(0,b.jsx)("p",{className:l("text-muted-foreground text-sm"),children:d.externalLinkWarning})]}),(0,b.jsx)("div",{className:l("break-all rounded-md bg-muted p-3 font-mono text-sm",e.length>100&&"max-h-32 overflow-y-auto"),children:e}),(0,b.jsxs)("div",{className:l("flex gap-2"),children:[(0,b.jsx)("button",{className:l("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:p,type:"button",children:u?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)(i,{size:14}),(0,b.jsx)("span",{children:d.copied})]}):(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)(a,{size:14}),(0,b.jsx)("span",{children:d.copyLink})]})}),(0,b.jsxs)("button",{className:l("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:f,type:"button",children:[(0,b.jsx)(s,{size:14}),(0,b.jsx)("span",{children:d.openLink})]})]})]})}):null},ni=(0,y.createContext)(null),Bi=()=>(0,y.useContext)(ni),aC=()=>{var e;let t=Bi();return(e=t?.code)!=null?e:null},Fi=()=>{var e;let t=Bi();return(e=t?.mermaid)!=null?e:null},V_=e=>{var t;let n=Bi();return n!=null&&n.renderers&&e&&(t=n.renderers.find(r=>Array.isArray(r.language)?r.language.includes(e):r.language===e))!=null?t:null},W_=(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 l=document.createElement("canvas"),u=o.width*r,h=o.height*r;l.width=u,l.height=h;let d=l.getContext("2d");if(!d){a(new Error("Failed to create 2D canvas context for PNG export"));return}d.drawImage(o,0,0,u,h),l.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})},Q_=({chart:e,children:t,className:n,onDownload:r,config:i,onError:a})=>{let s=X(),[o,l]=(0,y.useState)(!1),u=(0,y.useRef)(null),{isAnimating:h}=(0,y.useContext)(Me),d=Ve(),p=Fi(),f=it(),E=async I=>{try{if(I==="mmd"){Bt("diagram.mmd",e,"text/plain"),l(!1),r?.(I);return}if(!p){a?.(new Error("Mermaid plugin not available"));return}let S=p.getMermaid(i),k=e.split("").reduce((B,P)=>(B<<5)-B+P.charCodeAt(0)|0,0),L=`mermaid-${Math.abs(k)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:R}=await S.render(L,e);if(!R){a?.(new Error("SVG not found. Please wait for the diagram to render."));return}if(I==="svg"){Bt("diagram.svg",R,"image/svg+xml"),l(!1),r?.(I);return}if(I==="png"){Bt("diagram.png",await W_(R),"image/png"),r?.(I),l(!1);return}}catch(S){a?.(S)}};return(0,y.useEffect)(()=>{let I=S=>{let k=S.composedPath();u.current&&!k.includes(u.current)&&l(!1)};return document.addEventListener("mousedown",I),()=>{document.removeEventListener("mousedown",I)}},[]),(0,b.jsxs)("div",{className:s("relative"),ref:u,children:[(0,b.jsx)("button",{className:s("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",n),disabled:h,onClick:()=>l(!o),title:f.downloadDiagram,type:"button",children:t??(0,b.jsx)(d.DownloadIcon,{size:14})}),o?(0,b.jsxs)("div",{className:s("absolute top-full right-0 z-10 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg"),children:[(0,b.jsx)("button",{className:s("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("svg"),title:f.downloadDiagramAsSvg,type:"button",children:f.mermaidFormatSvg}),(0,b.jsx)("button",{className:s("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("png"),title:f.downloadDiagramAsPng,type:"button",children:f.mermaidFormatPng}),(0,b.jsx)("button",{className:s("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("mmd"),title:f.downloadDiagramAsMmd,type:"button",children:f.mermaidFormatMmd})]}):null]})},G_=({chart:e,config:t,onFullscreen:n,onExit:r,className:i,...a})=>{let{Maximize2Icon:s,XIcon:o}=Ve(),l=X(),[u,h]=(0,y.useState)(!1),{isAnimating:d,controls:p}=(0,y.useContext)(Me),f=it(),E=(()=>{if(typeof p=="boolean")return p;let S=p.mermaid;return S===!1?!1:S===!0||S===void 0?!0:S.panZoom!==!1})(),I=()=>{h(!u)};return(0,y.useEffect)(()=>{if(u){Pi();let S=k=>{k.key==="Escape"&&h(!1)};return document.addEventListener("keydown",S),()=>{document.removeEventListener("keydown",S),Mi()}}},[u]),(0,y.useEffect)(()=>{u?n?.():r&&r()},[u,n,r]),(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("button",{className:l("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",i),disabled:d,onClick:I,title:f.viewFullscreen,type:"button",...a,children:(0,b.jsx)(s,{size:14})}),u?(0,Io.createPortal)((0,b.jsxs)("div",{className:l("fixed inset-0 z-50 flex items-center justify-center bg-background/95 backdrop-blur-sm"),onClick:I,onKeyDown:S=>{S.key==="Escape"&&I()},role:"button",tabIndex:0,children:[(0,b.jsx)("button",{className:l("absolute top-4 right-4 z-10 rounded-md p-2 text-muted-foreground transition-all hover:bg-muted hover:text-foreground"),onClick:I,title:f.exitFullscreen,type:"button",children:(0,b.jsx)(o,{size:20})}),(0,b.jsx)("div",{className:l("flex size-full items-center justify-center p-4"),onClick:S=>S.stopPropagation(),onKeyDown:S=>S.stopPropagation(),role:"presentation",children:(0,b.jsx)($A,{chart:e,className:l("size-full [&_svg]:h-auto [&_svg]:w-auto"),config:t,fullscreen:!0,showControls:E})})]}),document.body):null]})},zo=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 l=[],u=o.querySelectorAll("td");for(let h of u)l.push(((n=h.textContent)==null?void 0:n.trim())||"");i.push(l)}return{headers:r,rows:i}},$o=e=>{let{headers:t,rows:n}=e,r=o=>{let l=!1,u=!1;for(let h of o){if(h==='"'){l=!0,u=!0;break}(h===","||h===`
|
|
114
114
|
`)&&(l=!0)}return l?u?`"${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(`
|
|
115
115
|
`)},K_=e=>{let{headers:t,rows:n}=e,r=o=>{let l=!1;for(let h of o)if(h===" "||h===`
|
|
116
116
|
`||h==="\r"){l=!0;break}if(!l)return o;let u=[];for(let h of o)h===" "?u.push("\\t"):h===`
|
|
117
117
|
`?u.push("\\n"):h==="\r"?u.push("\\r"):u.push(h);return u.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(`
|
|
118
118
|
`)},Dr=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("")},ri=e=>{let{headers:t,rows:n}=e;if(t.length===0)return"";let r=new Array(n.length+2),i=0;r[i]=`| ${t.map(s=>Dr(s)).join(" | ")} |`,i+=1;let a=new Array(t.length);for(let s=0;s<t.length;s+=1)a[s]="---";r[i]=`| ${a.join(" | ")} |`,i+=1;for(let s of n)if(s.length<t.length){let o=new Array(t.length);for(let l=0;l<t.length;l+=1)o[l]=l<s.length?Dr(s[l]):"";r[i]=`| ${o.join(" | ")} |`,i+=1}else r[i]=`| ${s.map(o=>Dr(o)).join(" | ")} |`,i+=1;return r.join(`
|
|
119
|
-
`)},Yo=({children:e,className:t,onCopy:n,onError:r,timeout:i=2e3})=>{let a=X(),[s,o]=(0,y.useState)(!1),[l,u]=(0,y.useState)(!1),h=(0,y.useRef)(null),d=(0,y.useRef)(0),{isAnimating:p}=(0,y.useContext)(Me),f=it(),E=async k=>{var L,R;if(typeof window>"u"||!((L=navigator?.clipboard)!=null&&L.write)){r?.(new Error("Clipboard API not available"));return}try{let B=(R=h.current)==null?void 0:R.closest('[data-streamdown="table-wrapper"]'),P=B?.querySelector("table");if(!P){r?.(new Error("Table not found"));return}let N=zo(P),$=({csv:$o,tsv:K_,md:ri}[k]||ri)(N),V=new ClipboardItem({"text/plain":new Blob([$],{type:"text/plain"}),"text/html":new Blob([P.outerHTML],{type:"text/html"})});await navigator.clipboard.write([V]),u(!0),o(!1),n?.(k),d.current=window.setTimeout(()=>u(!1),i)}catch(B){r?.(B)}};(0,y.useEffect)(()=>{let k=L=>{let R=L.composedPath();h.current&&!R.includes(h.current)&&o(!1)};return document.addEventListener("mousedown",k),()=>{document.removeEventListener("mousedown",k),window.clearTimeout(d.current)}},[]);let I=Ve(),S=l?I.CheckIcon:I.CopyIcon;return(0,b.jsxs)("div",{className:a("relative"),ref:h,children:[(0,b.jsx)("button",{className:a("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:p,onClick:()=>o(!s),title:f.copyTable,type:"button",children:e??(0,b.jsx)(S,{height:14,width:14})}),s?(0,b.jsxs)("div",{className:a("absolute top-full right-0 z-20 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg"),children:[(0,b.jsx)("button",{className:a("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("md"),title:f.copyTableAsMarkdown,type:"button",children:f.tableFormatMarkdown}),(0,b.jsx)("button",{className:a("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("csv"),title:f.copyTableAsCsv,type:"button",children:f.tableFormatCsv}),(0,b.jsx)("button",{className:a("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("tsv"),title:f.copyTableAsTsv,type:"button",children:f.tableFormatTsv})]}):null]})};var qo=({children:e,className:t,onDownload:n,onError:r})=>{let i=X(),[a,s]=(0,y.useState)(!1),o=(0,y.useRef)(null),{isAnimating:l}=(0,y.useContext)(Me),u=it(),h=Ve(),d=p=>{var f;try{let E=(f=o.current)==null?void 0:f.closest('[data-streamdown="table-wrapper"]'),I=E?.querySelector("table");if(!I){r?.(new Error("Table not found"));return}let S=zo(I),k=p==="csv"?$o(S):ri(S);Bt(`table.${p==="csv"?"csv":"md"}`,k,p==="csv"?"text/csv":"text/markdown"),s(!1),n?.(p)}catch(E){r?.(E)}};return(0,y.useEffect)(()=>{let p=f=>{let E=f.composedPath();o.current&&!E.includes(o.current)&&s(!1)};return document.addEventListener("mousedown",p),()=>{document.removeEventListener("mousedown",p)}},[]),(0,b.jsxs)("div",{className:i("relative"),ref:o,children:[(0,b.jsx)("button",{className:i("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:l,onClick:()=>s(!a),title:u.downloadTable,type:"button",children:e??(0,b.jsx)(h.DownloadIcon,{size:14})}),a?(0,b.jsxs)("div",{className:i("absolute top-full right-0 z-20 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg"),children:[(0,b.jsx)("button",{className:i("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>d("csv"),title:u.downloadTableAsCsv,type:"button",children:u.tableFormatCsv}),(0,b.jsx)("button",{className:i("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>d("markdown"),title:u.downloadTableAsMarkdown,type:"button",children:u.tableFormatMarkdown})]}):null]})},X_=({children:e,className:t,showCopy:n=!0,showDownload:r=!0})=>{let{Maximize2Icon:i,XIcon:a}=Ve(),s=X(),[o,l]=(0,y.useState)(!1),{isAnimating:u}=(0,y.useContext)(Me),h=it(),d=()=>{l(!0)},p=()=>{l(!1)};return(0,y.useEffect)(()=>{if(o){Pi();let f=E=>{E.key==="Escape"&&l(!1)};return document.addEventListener("keydown",f),()=>{document.removeEventListener("keydown",f),Mi()}}},[o]),(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("button",{className:s("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:u,onClick:d,title:h.viewFullscreen,type:"button",children:(0,b.jsx)(i,{size:14})}),o?(0,Io.createPortal)((0,b.jsx)("div",{"aria-label":h.viewFullscreen,"aria-modal":"true",className:s("fixed inset-0 z-50 flex flex-col bg-background"),"data-streamdown":"table-fullscreen",onClick:p,onKeyDown:f=>{f.key==="Escape"&&p()},role:"dialog",children:(0,b.jsxs)("div",{className:s("flex h-full flex-col"),onClick:f=>f.stopPropagation(),onKeyDown:f=>f.stopPropagation(),role:"presentation",children:[(0,b.jsxs)("div",{className:s("flex items-center justify-end gap-1 p-4"),children:[n?(0,b.jsx)(Yo,{}):null,r?(0,b.jsx)(qo,{}):null,(0,b.jsx)("button",{className:s("rounded-md p-1 text-muted-foreground transition-all hover:bg-muted hover:text-foreground"),onClick:p,title:h.exitFullscreen,type:"button",children:(0,b.jsx)(a,{size:20})})]}),(0,b.jsx)("div",{className:s("flex-1 overflow-auto p-4 pt-0 [&_thead]:sticky [&_thead]:top-0 [&_thead]:z-10"),children:(0,b.jsx)("table",{className:s("w-full border-collapse border border-border"),"data-streamdown":"table",children:e})})]})}),document.body):null]})},Z_=({children:e,className:t,showControls:n,showCopy:r=!0,showDownload:i=!0,showFullscreen:a=!0,...s})=>{let o=X(),l=n&&r,u=n&&i,h=n&&a,d=l||u||h;return(0,b.jsxs)("div",{className:o("my-4 flex flex-col gap-2 rounded-lg border border-border bg-sidebar p-2"),"data-streamdown":"table-wrapper",children:[d?(0,b.jsxs)("div",{className:o("flex items-center justify-end gap-1"),children:[l?(0,b.jsx)(Yo,{}):null,u?(0,b.jsx)(qo,{}):null,h?(0,b.jsx)(X_,{showCopy:l,showDownload:u,children:e}):null]}):null,(0,b.jsx)("div",{className:o("border-collapse overflow-x-auto overflow-y-auto rounded-md border border-border bg-background"),children:(0,b.jsx)("table",{className:o("w-full divide-y divide-border",t),"data-streamdown":"table",...s,children:e})})]})},J_=/startLine=(\d+)/,eA=/\bnoLineNumbers\b/,tA=(0,y.lazy)(()=>Is(()=>import("./mermaid-GHXKKRXX--wNt23Qo.js").then(e=>({default:e.Mermaid})),[])),nA=/language-([^\s]+)/;function dr(e,t){if(!(e!=null&&e.position||t!=null&&t.position))return!0;if(!(e!=null&&e.position&&t!=null&&t.position))return!1;let n=e.position.start,r=t.position.start,i=e.position.end,a=t.position.end;return n?.line===r?.line&&n?.column===r?.column&&i?.line===a?.line&&i?.column===a?.column}function he(e,t){return e.className===t.className&&dr(e.node,t.node)}var ii=(e,t)=>typeof e=="boolean"?e:e[t]!==!1,vr=(e,t)=>{if(typeof e=="boolean")return e;let n=e.table;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},os=(e,t)=>{if(typeof e=="boolean")return e;let n=e.code;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},Fn=(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},Hi=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("ol",{className:X()("list-inside list-decimal whitespace-normal [li_&]:pl-6",t),"data-streamdown":"ordered-list",...r,children:e}),(e,t)=>he(e,t));Hi.displayName="MarkdownOl";var Vo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("li",{className:X()("py-1 [&>p]:inline",t),"data-streamdown":"list-item",...r,children:e}),(e,t)=>e.className===t.className&&dr(e.node,t.node));Vo.displayName="MarkdownLi";var Wo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("ul",{className:X()("list-inside list-disc whitespace-normal [li_&]:pl-6",t),"data-streamdown":"unordered-list",...r,children:e}),(e,t)=>he(e,t));Wo.displayName="MarkdownUl";var Qo=(0,y.memo)(({className:e,node:t,...n})=>(0,b.jsx)("hr",{className:X()("my-6 border-border",e),"data-streamdown":"horizontal-rule",...n}),(e,t)=>he(e,t));Qo.displayName="MarkdownHr";var Go=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("span",{className:X()("font-semibold",t),"data-streamdown":"strong",...r,children:e}),(e,t)=>he(e,t));Go.displayName="MarkdownStrong";var rA=({children:e,className:t,href:n,node:r,...i})=>{let a=X(),{linkSafety:s}=(0,y.useContext)(Me),[o,l]=(0,y.useState)(!1),u=n==="streamdown:incomplete-link",h=(0,y.useCallback)(async E=>{if(!(!(s!=null&&s.enabled&&n)||u)){if(E.preventDefault(),s.onLinkCheck&&await s.onLinkCheck(n)){window.open(n,"_blank","noreferrer");return}l(!0)}},[s,n,u]),d=(0,y.useCallback)(()=>{n&&window.open(n,"_blank","noreferrer")},[n]),p=(0,y.useCallback)(()=>{l(!1)},[]),f={url:n??"",isOpen:o,onClose:p,onConfirm:d};return s!=null&&s.enabled&&n?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("button",{className:a("wrap-anywhere appearance-none text-left font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",onClick:h,type:"button",children:e}),s.renderModal?s.renderModal(f):(0,b.jsx)(q_,{...f})]}):(0,b.jsx)("a",{className:a("wrap-anywhere font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",href:n,rel:"noreferrer",target:"_blank",...i,children:e})},Ko=(0,y.memo)(rA,(e,t)=>he(e,t)&&e.href===t.href);Ko.displayName="MarkdownA";var Xo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h1",{className:X()("mt-6 mb-2 font-semibold text-3xl",t),"data-streamdown":"heading-1",...r,children:e}),(e,t)=>he(e,t));Xo.displayName="MarkdownH1";var Zo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h2",{className:X()("mt-6 mb-2 font-semibold text-2xl",t),"data-streamdown":"heading-2",...r,children:e}),(e,t)=>he(e,t));Zo.displayName="MarkdownH2";var Jo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h3",{className:X()("mt-6 mb-2 font-semibold text-xl",t),"data-streamdown":"heading-3",...r,children:e}),(e,t)=>he(e,t));Jo.displayName="MarkdownH3";var ec=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h4",{className:X()("mt-6 mb-2 font-semibold text-lg",t),"data-streamdown":"heading-4",...r,children:e}),(e,t)=>he(e,t));ec.displayName="MarkdownH4";var tc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h5",{className:X()("mt-6 mb-2 font-semibold text-base",t),"data-streamdown":"heading-5",...r,children:e}),(e,t)=>he(e,t));tc.displayName="MarkdownH5";var nc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h6",{className:X()("mt-6 mb-2 font-semibold text-sm",t),"data-streamdown":"heading-6",...r,children:e}),(e,t)=>he(e,t));nc.displayName="MarkdownH6";var rc=(0,y.memo)(({children:e,className:t,node:n,...r})=>{let{controls:i}=(0,y.useContext)(Me);return(0,b.jsx)(Z_,{className:t,showControls:ii(i,"table"),showCopy:vr(i,"copy"),showDownload:vr(i,"download"),showFullscreen:vr(i,"fullscreen"),...r,children:e})},(e,t)=>he(e,t));rc.displayName="MarkdownTable";var ic=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("thead",{className:X()("bg-muted/80",t),"data-streamdown":"table-header",...r,children:e}),(e,t)=>he(e,t));ic.displayName="MarkdownThead";var ac=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("tbody",{className:X()("divide-y divide-border",t),"data-streamdown":"table-body",...r,children:e}),(e,t)=>he(e,t));ac.displayName="MarkdownTbody";var sc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("tr",{className:X()("border-border",t),"data-streamdown":"table-row",...r,children:e}),(e,t)=>he(e,t));sc.displayName="MarkdownTr";var lc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("th",{className:X()("whitespace-nowrap px-4 py-2 text-left font-semibold text-sm",t),"data-streamdown":"table-header-cell",...r,children:e}),(e,t)=>he(e,t));lc.displayName="MarkdownTh";var oc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("td",{className:X()("px-4 py-2 text-sm",t),"data-streamdown":"table-cell",...r,children:e}),(e,t)=>he(e,t));oc.displayName="MarkdownTd";var cc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("blockquote",{className:X()("my-4 border-muted-foreground/30 border-l-4 pl-4 text-muted-foreground italic",t),"data-streamdown":"blockquote",...r,children:e}),(e,t)=>he(e,t));cc.displayName="MarkdownBlockquote";var uc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("sup",{className:X()("text-sm",t),"data-streamdown":"superscript",...r,children:e}),(e,t)=>he(e,t));uc.displayName="MarkdownSup";var hc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("sub",{className:X()("text-sm",t),"data-streamdown":"subscript",...r,children:e}),(e,t)=>he(e,t));hc.displayName="MarkdownSub";var dc=(0,y.memo)(({children:e,className:t,node:n,...r})=>{if("data-footnotes"in r){let i=s=>{var o,l;if(!(0,y.isValidElement)(s))return!1;let u=Array.isArray(s.props.children)?s.props.children:[s.props.children],h=!1,d=!1;for(let p of u)if(p){if(typeof p=="string")p.trim()!==""&&(h=!0);else if((0,y.isValidElement)(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 E of f){if(typeof E=="string"&&E.trim()!==""){h=!0;break}if((0,y.isValidElement)(E)&&((l=E.props)==null?void 0:l["data-footnote-backref"])===void 0){h=!0;break}}}}return d&&!h},a=Array.isArray(e)?e.map(s=>{if(!(0,y.isValidElement)(s))return s;if(s.type===Hi){let o=(Array.isArray(s.props.children)?s.props.children:[s.props.children]).filter(l=>!i(l));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)?(0,b.jsx)("section",{className:t,...r,children:a}):null}return(0,b.jsx)("section",{className:t,...r,children:e})},(e,t)=>he(e,t));dc.displayName="MarkdownSection";var iA=({node:e,className:t,children:n,...r})=>{var i,a;let s=X(),o=!("data-block"in r),{mermaid:l,controls:u,lineNumbers:h}=(0,y.useContext)(Me),d=Fi(),p=k_(),f=t?.match(nA),E=(i=f?.at(1))!=null?i:"",I=V_(E);if(o)return(0,b.jsx)("code",{className:s("rounded bg-muted px-1.5 py-0.5 font-mono text-sm",t),"data-streamdown":"inline-code",...r,children:n});let S=(a=e?.properties)==null?void 0:a.metastring,k=S?.match(J_),L=k?Number.parseInt(k[1],10):void 0,R=L!==void 0&&L>=1?L:void 0,B=!(S&&eA.test(S))&&h!==!1,P="";if((0,y.isValidElement)(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),I){let q=I.component;return(0,b.jsx)(y.Suspense,{fallback:(0,b.jsx)(ls,{}),children:(0,b.jsx)(q,{code:P,isIncomplete:p,language:E,meta:S})})}if(E==="mermaid"&&d){let q=ii(u,"mermaid"),x=Fn(u,"download"),U=Fn(u,"copy"),j=Fn(u,"fullscreen"),Z=Fn(u,"panZoom"),re=q&&(x||U||j);return(0,b.jsx)(y.Suspense,{fallback:(0,b.jsx)(ls,{}),children:(0,b.jsxs)("div",{className:s("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:[(0,b.jsx)("div",{className:s("flex h-8 items-center text-muted-foreground text-xs"),children:(0,b.jsx)("span",{className:s("ml-1 font-mono lowercase"),children:"mermaid"})}),re?(0,b.jsx)("div",{className:s("pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end"),children:(0,b.jsxs)("div",{className:s("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:[x?(0,b.jsx)(Q_,{chart:P,config:l?.config}):null,U?(0,b.jsx)(as,{code:P}):null,j?(0,b.jsx)(G_,{chart:P,config:l?.config}):null]})}):null,(0,b.jsx)("div",{className:s("rounded-md border border-border bg-background"),children:(0,b.jsx)(tA,{chart:P,config:l?.config,showControls:Z})})]})})}let N=ii(u,"code"),$=os(u,"download"),V=os(u,"copy");return(0,b.jsx)(L_,{className:t,code:P,isIncomplete:p,language:E,lineNumbers:B,startLine:R,children:N?(0,b.jsxs)(b.Fragment,{children:[$?(0,b.jsx)(z_,{code:P,language:E}):null,V?(0,b.jsx)(as,{}):null]}):null})},fc=(0,y.memo)(iA,(e,t)=>e.className===t.className&&dr(e.node,t.node));fc.displayName="MarkdownCode";var pc=(0,y.memo)(Y_,(e,t)=>e.className===t.className&&dr(e.node,t.node));pc.displayName="MarkdownImg";var mc=(0,y.memo)(({children:e,node:t,...n})=>{let r=(Array.isArray(e)?e:[e]).filter(i=>i!=null&&i!=="");if(r.length===1&&(0,y.isValidElement)(r[0])){let i=r[0].props.node,a=i?.tagName;if(a==="img")return(0,b.jsx)(b.Fragment,{children:e});if(a==="code"&&"data-block"in r[0].props)return(0,b.jsx)(b.Fragment,{children:e})}return(0,b.jsx)("p",{...n,children:e})},(e,t)=>he(e,t));mc.displayName="MarkdownParagraph";var aA={ol:Hi,li:Vo,ul:Wo,hr:Qo,strong:Go,a:Ko,h1:Xo,h2:Zo,h3:Jo,h4:ec,h5:tc,h6:nc,table:rc,thead:ic,tbody:ac,tr:sc,th:lc,td:oc,blockquote:cc,code:fc,img:pc,pre:({children:e})=>(0,y.isValidElement)(e)?(0,y.cloneElement)(e,{"data-block":"true"}):e,sup:uc,sub:hc,p:mc,section:dc},sA=/[\u0590-\u08FF\uFB1D-\uFDFF\uFE70-\uFEFF]/,lA=/\p{L}/u;function cs(e){let t=e.replace(/^#{1,6}\s+/gm,"").replace(/(\*{1,3}|_{1,3})/g,"").replace(/`[^`]*`/g,"").replace(/\[([^\]]*)\]\([^)]*\)/g,"$1").replace(/^[\s>*\-+\d.]+/gm,"");for(let n of t){if(sA.test(n))return"rtl";if(lA.test(n))return"ltr"}return"ltr"}var oA=/^[ \t]{0,3}(`{3,}|~{3,})/,cA=/^\|?[ \t]*:?-{1,}:?[ \t]*(\|[ \t]*:?-{1,}:?[ \t]*)*\|?$/,us=e=>{let t=e.split(`
|
|
119
|
+
`)},Yo=({children:e,className:t,onCopy:n,onError:r,timeout:i=2e3})=>{let a=X(),[s,o]=(0,y.useState)(!1),[l,u]=(0,y.useState)(!1),h=(0,y.useRef)(null),d=(0,y.useRef)(0),{isAnimating:p}=(0,y.useContext)(Me),f=it(),E=async k=>{var L,R;if(typeof window>"u"||!((L=navigator?.clipboard)!=null&&L.write)){r?.(new Error("Clipboard API not available"));return}try{let B=(R=h.current)==null?void 0:R.closest('[data-streamdown="table-wrapper"]'),P=B?.querySelector("table");if(!P){r?.(new Error("Table not found"));return}let N=zo(P),$=({csv:$o,tsv:K_,md:ri}[k]||ri)(N),V=new ClipboardItem({"text/plain":new Blob([$],{type:"text/plain"}),"text/html":new Blob([P.outerHTML],{type:"text/html"})});await navigator.clipboard.write([V]),u(!0),o(!1),n?.(k),d.current=window.setTimeout(()=>u(!1),i)}catch(B){r?.(B)}};(0,y.useEffect)(()=>{let k=L=>{let R=L.composedPath();h.current&&!R.includes(h.current)&&o(!1)};return document.addEventListener("mousedown",k),()=>{document.removeEventListener("mousedown",k),window.clearTimeout(d.current)}},[]);let I=Ve(),S=l?I.CheckIcon:I.CopyIcon;return(0,b.jsxs)("div",{className:a("relative"),ref:h,children:[(0,b.jsx)("button",{className:a("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:p,onClick:()=>o(!s),title:f.copyTable,type:"button",children:e??(0,b.jsx)(S,{height:14,width:14})}),s?(0,b.jsxs)("div",{className:a("absolute top-full right-0 z-20 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg"),children:[(0,b.jsx)("button",{className:a("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("md"),title:f.copyTableAsMarkdown,type:"button",children:f.tableFormatMarkdown}),(0,b.jsx)("button",{className:a("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("csv"),title:f.copyTableAsCsv,type:"button",children:f.tableFormatCsv}),(0,b.jsx)("button",{className:a("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>E("tsv"),title:f.copyTableAsTsv,type:"button",children:f.tableFormatTsv})]}):null]})};var qo=({children:e,className:t,onDownload:n,onError:r})=>{let i=X(),[a,s]=(0,y.useState)(!1),o=(0,y.useRef)(null),{isAnimating:l}=(0,y.useContext)(Me),u=it(),h=Ve(),d=p=>{var f;try{let E=(f=o.current)==null?void 0:f.closest('[data-streamdown="table-wrapper"]'),I=E?.querySelector("table");if(!I){r?.(new Error("Table not found"));return}let S=zo(I),k=p==="csv"?$o(S):ri(S);Bt(`table.${p==="csv"?"csv":"md"}`,k,p==="csv"?"text/csv":"text/markdown"),s(!1),n?.(p)}catch(E){r?.(E)}};return(0,y.useEffect)(()=>{let p=f=>{let E=f.composedPath();o.current&&!E.includes(o.current)&&s(!1)};return document.addEventListener("mousedown",p),()=>{document.removeEventListener("mousedown",p)}},[]),(0,b.jsxs)("div",{className:i("relative"),ref:o,children:[(0,b.jsx)("button",{className:i("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:l,onClick:()=>s(!a),title:u.downloadTable,type:"button",children:e??(0,b.jsx)(h.DownloadIcon,{size:14})}),a?(0,b.jsxs)("div",{className:i("absolute top-full right-0 z-20 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg"),children:[(0,b.jsx)("button",{className:i("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>d("csv"),title:u.downloadTableAsCsv,type:"button",children:u.tableFormatCsv}),(0,b.jsx)("button",{className:i("w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40"),onClick:()=>d("markdown"),title:u.downloadTableAsMarkdown,type:"button",children:u.tableFormatMarkdown})]}):null]})},X_=({children:e,className:t,showCopy:n=!0,showDownload:r=!0})=>{let{Maximize2Icon:i,XIcon:a}=Ve(),s=X(),[o,l]=(0,y.useState)(!1),{isAnimating:u}=(0,y.useContext)(Me),h=it(),d=()=>{l(!0)},p=()=>{l(!1)};return(0,y.useEffect)(()=>{if(o){Pi();let f=E=>{E.key==="Escape"&&l(!1)};return document.addEventListener("keydown",f),()=>{document.removeEventListener("keydown",f),Mi()}}},[o]),(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("button",{className:s("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:u,onClick:d,title:h.viewFullscreen,type:"button",children:(0,b.jsx)(i,{size:14})}),o?(0,Io.createPortal)((0,b.jsx)("div",{"aria-label":h.viewFullscreen,"aria-modal":"true",className:s("fixed inset-0 z-50 flex flex-col bg-background"),"data-streamdown":"table-fullscreen",onClick:p,onKeyDown:f=>{f.key==="Escape"&&p()},role:"dialog",children:(0,b.jsxs)("div",{className:s("flex h-full flex-col"),onClick:f=>f.stopPropagation(),onKeyDown:f=>f.stopPropagation(),role:"presentation",children:[(0,b.jsxs)("div",{className:s("flex items-center justify-end gap-1 p-4"),children:[n?(0,b.jsx)(Yo,{}):null,r?(0,b.jsx)(qo,{}):null,(0,b.jsx)("button",{className:s("rounded-md p-1 text-muted-foreground transition-all hover:bg-muted hover:text-foreground"),onClick:p,title:h.exitFullscreen,type:"button",children:(0,b.jsx)(a,{size:20})})]}),(0,b.jsx)("div",{className:s("flex-1 overflow-auto p-4 pt-0 [&_thead]:sticky [&_thead]:top-0 [&_thead]:z-10"),children:(0,b.jsx)("table",{className:s("w-full border-collapse border border-border"),"data-streamdown":"table",children:e})})]})}),document.body):null]})},Z_=({children:e,className:t,showControls:n,showCopy:r=!0,showDownload:i=!0,showFullscreen:a=!0,...s})=>{let o=X(),l=n&&r,u=n&&i,h=n&&a,d=l||u||h;return(0,b.jsxs)("div",{className:o("my-4 flex flex-col gap-2 rounded-lg border border-border bg-sidebar p-2"),"data-streamdown":"table-wrapper",children:[d?(0,b.jsxs)("div",{className:o("flex items-center justify-end gap-1"),children:[l?(0,b.jsx)(Yo,{}):null,u?(0,b.jsx)(qo,{}):null,h?(0,b.jsx)(X_,{showCopy:l,showDownload:u,children:e}):null]}):null,(0,b.jsx)("div",{className:o("border-collapse overflow-x-auto overflow-y-auto rounded-md border border-border bg-background"),children:(0,b.jsx)("table",{className:o("w-full divide-y divide-border",t),"data-streamdown":"table",...s,children:e})})]})},J_=/startLine=(\d+)/,eA=/\bnoLineNumbers\b/,tA=(0,y.lazy)(()=>Is(()=>import("./mermaid-GHXKKRXX-Cey0AJ6z.js").then(e=>({default:e.Mermaid})),[])),nA=/language-([^\s]+)/;function dr(e,t){if(!(e!=null&&e.position||t!=null&&t.position))return!0;if(!(e!=null&&e.position&&t!=null&&t.position))return!1;let n=e.position.start,r=t.position.start,i=e.position.end,a=t.position.end;return n?.line===r?.line&&n?.column===r?.column&&i?.line===a?.line&&i?.column===a?.column}function he(e,t){return e.className===t.className&&dr(e.node,t.node)}var ii=(e,t)=>typeof e=="boolean"?e:e[t]!==!1,vr=(e,t)=>{if(typeof e=="boolean")return e;let n=e.table;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},os=(e,t)=>{if(typeof e=="boolean")return e;let n=e.code;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},Fn=(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},Hi=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("ol",{className:X()("list-inside list-decimal whitespace-normal [li_&]:pl-6",t),"data-streamdown":"ordered-list",...r,children:e}),(e,t)=>he(e,t));Hi.displayName="MarkdownOl";var Vo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("li",{className:X()("py-1 [&>p]:inline",t),"data-streamdown":"list-item",...r,children:e}),(e,t)=>e.className===t.className&&dr(e.node,t.node));Vo.displayName="MarkdownLi";var Wo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("ul",{className:X()("list-inside list-disc whitespace-normal [li_&]:pl-6",t),"data-streamdown":"unordered-list",...r,children:e}),(e,t)=>he(e,t));Wo.displayName="MarkdownUl";var Qo=(0,y.memo)(({className:e,node:t,...n})=>(0,b.jsx)("hr",{className:X()("my-6 border-border",e),"data-streamdown":"horizontal-rule",...n}),(e,t)=>he(e,t));Qo.displayName="MarkdownHr";var Go=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("span",{className:X()("font-semibold",t),"data-streamdown":"strong",...r,children:e}),(e,t)=>he(e,t));Go.displayName="MarkdownStrong";var rA=({children:e,className:t,href:n,node:r,...i})=>{let a=X(),{linkSafety:s}=(0,y.useContext)(Me),[o,l]=(0,y.useState)(!1),u=n==="streamdown:incomplete-link",h=(0,y.useCallback)(async E=>{if(!(!(s!=null&&s.enabled&&n)||u)){if(E.preventDefault(),s.onLinkCheck&&await s.onLinkCheck(n)){window.open(n,"_blank","noreferrer");return}l(!0)}},[s,n,u]),d=(0,y.useCallback)(()=>{n&&window.open(n,"_blank","noreferrer")},[n]),p=(0,y.useCallback)(()=>{l(!1)},[]),f={url:n??"",isOpen:o,onClose:p,onConfirm:d};return s!=null&&s.enabled&&n?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("button",{className:a("wrap-anywhere appearance-none text-left font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",onClick:h,type:"button",children:e}),s.renderModal?s.renderModal(f):(0,b.jsx)(q_,{...f})]}):(0,b.jsx)("a",{className:a("wrap-anywhere font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",href:n,rel:"noreferrer",target:"_blank",...i,children:e})},Ko=(0,y.memo)(rA,(e,t)=>he(e,t)&&e.href===t.href);Ko.displayName="MarkdownA";var Xo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h1",{className:X()("mt-6 mb-2 font-semibold text-3xl",t),"data-streamdown":"heading-1",...r,children:e}),(e,t)=>he(e,t));Xo.displayName="MarkdownH1";var Zo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h2",{className:X()("mt-6 mb-2 font-semibold text-2xl",t),"data-streamdown":"heading-2",...r,children:e}),(e,t)=>he(e,t));Zo.displayName="MarkdownH2";var Jo=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h3",{className:X()("mt-6 mb-2 font-semibold text-xl",t),"data-streamdown":"heading-3",...r,children:e}),(e,t)=>he(e,t));Jo.displayName="MarkdownH3";var ec=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h4",{className:X()("mt-6 mb-2 font-semibold text-lg",t),"data-streamdown":"heading-4",...r,children:e}),(e,t)=>he(e,t));ec.displayName="MarkdownH4";var tc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h5",{className:X()("mt-6 mb-2 font-semibold text-base",t),"data-streamdown":"heading-5",...r,children:e}),(e,t)=>he(e,t));tc.displayName="MarkdownH5";var nc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("h6",{className:X()("mt-6 mb-2 font-semibold text-sm",t),"data-streamdown":"heading-6",...r,children:e}),(e,t)=>he(e,t));nc.displayName="MarkdownH6";var rc=(0,y.memo)(({children:e,className:t,node:n,...r})=>{let{controls:i}=(0,y.useContext)(Me);return(0,b.jsx)(Z_,{className:t,showControls:ii(i,"table"),showCopy:vr(i,"copy"),showDownload:vr(i,"download"),showFullscreen:vr(i,"fullscreen"),...r,children:e})},(e,t)=>he(e,t));rc.displayName="MarkdownTable";var ic=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("thead",{className:X()("bg-muted/80",t),"data-streamdown":"table-header",...r,children:e}),(e,t)=>he(e,t));ic.displayName="MarkdownThead";var ac=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("tbody",{className:X()("divide-y divide-border",t),"data-streamdown":"table-body",...r,children:e}),(e,t)=>he(e,t));ac.displayName="MarkdownTbody";var sc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("tr",{className:X()("border-border",t),"data-streamdown":"table-row",...r,children:e}),(e,t)=>he(e,t));sc.displayName="MarkdownTr";var lc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("th",{className:X()("whitespace-nowrap px-4 py-2 text-left font-semibold text-sm",t),"data-streamdown":"table-header-cell",...r,children:e}),(e,t)=>he(e,t));lc.displayName="MarkdownTh";var oc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("td",{className:X()("px-4 py-2 text-sm",t),"data-streamdown":"table-cell",...r,children:e}),(e,t)=>he(e,t));oc.displayName="MarkdownTd";var cc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("blockquote",{className:X()("my-4 border-muted-foreground/30 border-l-4 pl-4 text-muted-foreground italic",t),"data-streamdown":"blockquote",...r,children:e}),(e,t)=>he(e,t));cc.displayName="MarkdownBlockquote";var uc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("sup",{className:X()("text-sm",t),"data-streamdown":"superscript",...r,children:e}),(e,t)=>he(e,t));uc.displayName="MarkdownSup";var hc=(0,y.memo)(({children:e,className:t,node:n,...r})=>(0,b.jsx)("sub",{className:X()("text-sm",t),"data-streamdown":"subscript",...r,children:e}),(e,t)=>he(e,t));hc.displayName="MarkdownSub";var dc=(0,y.memo)(({children:e,className:t,node:n,...r})=>{if("data-footnotes"in r){let i=s=>{var o,l;if(!(0,y.isValidElement)(s))return!1;let u=Array.isArray(s.props.children)?s.props.children:[s.props.children],h=!1,d=!1;for(let p of u)if(p){if(typeof p=="string")p.trim()!==""&&(h=!0);else if((0,y.isValidElement)(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 E of f){if(typeof E=="string"&&E.trim()!==""){h=!0;break}if((0,y.isValidElement)(E)&&((l=E.props)==null?void 0:l["data-footnote-backref"])===void 0){h=!0;break}}}}return d&&!h},a=Array.isArray(e)?e.map(s=>{if(!(0,y.isValidElement)(s))return s;if(s.type===Hi){let o=(Array.isArray(s.props.children)?s.props.children:[s.props.children]).filter(l=>!i(l));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)?(0,b.jsx)("section",{className:t,...r,children:a}):null}return(0,b.jsx)("section",{className:t,...r,children:e})},(e,t)=>he(e,t));dc.displayName="MarkdownSection";var iA=({node:e,className:t,children:n,...r})=>{var i,a;let s=X(),o=!("data-block"in r),{mermaid:l,controls:u,lineNumbers:h}=(0,y.useContext)(Me),d=Fi(),p=k_(),f=t?.match(nA),E=(i=f?.at(1))!=null?i:"",I=V_(E);if(o)return(0,b.jsx)("code",{className:s("rounded bg-muted px-1.5 py-0.5 font-mono text-sm",t),"data-streamdown":"inline-code",...r,children:n});let S=(a=e?.properties)==null?void 0:a.metastring,k=S?.match(J_),L=k?Number.parseInt(k[1],10):void 0,R=L!==void 0&&L>=1?L:void 0,B=!(S&&eA.test(S))&&h!==!1,P="";if((0,y.isValidElement)(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),I){let q=I.component;return(0,b.jsx)(y.Suspense,{fallback:(0,b.jsx)(ls,{}),children:(0,b.jsx)(q,{code:P,isIncomplete:p,language:E,meta:S})})}if(E==="mermaid"&&d){let q=ii(u,"mermaid"),x=Fn(u,"download"),U=Fn(u,"copy"),j=Fn(u,"fullscreen"),Z=Fn(u,"panZoom"),re=q&&(x||U||j);return(0,b.jsx)(y.Suspense,{fallback:(0,b.jsx)(ls,{}),children:(0,b.jsxs)("div",{className:s("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:[(0,b.jsx)("div",{className:s("flex h-8 items-center text-muted-foreground text-xs"),children:(0,b.jsx)("span",{className:s("ml-1 font-mono lowercase"),children:"mermaid"})}),re?(0,b.jsx)("div",{className:s("pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end"),children:(0,b.jsxs)("div",{className:s("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:[x?(0,b.jsx)(Q_,{chart:P,config:l?.config}):null,U?(0,b.jsx)(as,{code:P}):null,j?(0,b.jsx)(G_,{chart:P,config:l?.config}):null]})}):null,(0,b.jsx)("div",{className:s("rounded-md border border-border bg-background"),children:(0,b.jsx)(tA,{chart:P,config:l?.config,showControls:Z})})]})})}let N=ii(u,"code"),$=os(u,"download"),V=os(u,"copy");return(0,b.jsx)(L_,{className:t,code:P,isIncomplete:p,language:E,lineNumbers:B,startLine:R,children:N?(0,b.jsxs)(b.Fragment,{children:[$?(0,b.jsx)(z_,{code:P,language:E}):null,V?(0,b.jsx)(as,{}):null]}):null})},fc=(0,y.memo)(iA,(e,t)=>e.className===t.className&&dr(e.node,t.node));fc.displayName="MarkdownCode";var pc=(0,y.memo)(Y_,(e,t)=>e.className===t.className&&dr(e.node,t.node));pc.displayName="MarkdownImg";var mc=(0,y.memo)(({children:e,node:t,...n})=>{let r=(Array.isArray(e)?e:[e]).filter(i=>i!=null&&i!=="");if(r.length===1&&(0,y.isValidElement)(r[0])){let i=r[0].props.node,a=i?.tagName;if(a==="img")return(0,b.jsx)(b.Fragment,{children:e});if(a==="code"&&"data-block"in r[0].props)return(0,b.jsx)(b.Fragment,{children:e})}return(0,b.jsx)("p",{...n,children:e})},(e,t)=>he(e,t));mc.displayName="MarkdownParagraph";var aA={ol:Hi,li:Vo,ul:Wo,hr:Qo,strong:Go,a:Ko,h1:Xo,h2:Zo,h3:Jo,h4:ec,h5:tc,h6:nc,table:rc,thead:ic,tbody:ac,tr:sc,th:lc,td:oc,blockquote:cc,code:fc,img:pc,pre:({children:e})=>(0,y.isValidElement)(e)?(0,y.cloneElement)(e,{"data-block":"true"}):e,sup:uc,sub:hc,p:mc,section:dc},sA=/[\u0590-\u08FF\uFB1D-\uFDFF\uFE70-\uFEFF]/,lA=/\p{L}/u;function cs(e){let t=e.replace(/^#{1,6}\s+/gm,"").replace(/(\*{1,3}|_{1,3})/g,"").replace(/`[^`]*`/g,"").replace(/\[([^\]]*)\]\([^)]*\)/g,"$1").replace(/^[\s>*\-+\d.]+/gm,"");for(let n of t){if(sA.test(n))return"rtl";if(lA.test(n))return"ltr"}return"ltr"}var oA=/^[ \t]{0,3}(`{3,}|~{3,})/,cA=/^\|?[ \t]*:?-{1,}:?[ \t]*(\|[ \t]*:?-{1,}:?[ \t]*)*\|?$/,us=e=>{let t=e.split(`
|
|
120
120
|
`),n=null,r=0;for(let i of t){let a=oA.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],l=s.length;o===n&&l>=r&&(n=null,r=0)}}return n!==null},uA=e=>{let t=e.split(`
|
|
121
121
|
`);for(let n of t){let r=n.trim();if(r.length>0&&r.includes("|")&&cA.test(r))return!0}return!1},hA=()=>e=>{Ke(e,"html",(t,n,r)=>{!r||typeof n!="number"||(r.children[n]={type:"text",value:t.value})})},hs=[],ds={allowDangerousHtml:!0},Hn=new WeakMap,dA=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 l="default";return this.keyCache.set(e,l),l}let a=l=>{if(!l||l.length===0)return"";let u="";for(let h=0;h<l.length;h+=1){let d=l[h];if(h>0&&(u+=","),Array.isArray(d)){let[p,f]=d;if(typeof p=="function"){let E=Hn.get(p);E||(E=p.name,Hn.set(p,E)),u+=E}else u+=String(p);u+=":",u+=JSON.stringify(f)}else if(typeof d=="function"){let p=Hn.get(d);p||(p=d.name,Hn.set(d,p)),u+=p}else u+=String(d)}return u},s=a(n),o=`${a(r)}::${s}::${i?JSON.stringify(i):""}`;return this.keyCache.set(e,o),o}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()}},fs=new dA,gc=e=>{let t=fA(e),n=e.children||"";return kA(t.runSync(t.parse(n),n),e)},fA=e=>{let t=fs.get(e);if(t)return t;let n=mA(e);return fs.set(e,n),n},pA=e=>e.some(t=>Array.isArray(t)?t[0]===zr:t===zr),mA=e=>{let t=e.rehypePlugins||hs,n=e.remarkPlugins||hs,r=pA(t)?n:[...n,hA],i=e.remarkRehypeOptions?{...ds,...e.remarkRehypeOptions}:ds;return Tk().use(Eb).use(r).use(Jb,i).use(t)},gA=e=>e,EA=(e,t,n,r)=>{n?e.children.splice(t,1):e.children[t]={type:"text",value:r}},TA=(e,t)=>{var n;for(let r in xr)if(Object.hasOwn(xr,r)&&Object.hasOwn(e.properties,r)){let i=e.properties[r],a=xr[r];(a===null||a.includes(e.tagName))&&(e.properties[r]=(n=t(String(i||""),r,e))!=null?n:void 0)}},bA=(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},kA=(e,t)=>{let{allowElement:n,allowedElements:r,disallowedElements:i,skipHtml:a,unwrapDisallowed:s,urlTransform:o}=t;if(n||r||i||a||o){let l=o||gA;Ke(e,(u,h,d)=>{if(u.type==="raw"&&d&&typeof h=="number")return EA(d,h,a,u.value),h;if(u.type==="element"&&(TA(u,l),bA(u,h,d,r,i,n)&&d&&typeof h=="number"))return s&&u.children?d.children.splice(h,1,...u.children):d.children.splice(h,1),h})}return xT(e,{Fragment:b.Fragment,components:t.components,ignoreInvalidStyle:!0,jsx:b.jsx,jsxs:b.jsxs,passKeys:!0,passNode:!0})},_A=/\[\^[\w-]{1,200}\](?!:)/,AA=/\[\^[\w-]{1,200}\]:/,CA=/<(\w+)[\s>]/,yA=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]),ps=new Map,ms=new Map,xA=e=>{let t=e.toLowerCase(),n=ps.get(t);if(n)return n;let r=new RegExp(`<${t}(?=[\\s>/])[^>]*>`,"gi");return ps.set(t,r),r},IA=e=>{let t=e.toLowerCase(),n=ms.get(t);if(n)return n;let r=new RegExp(`</${t}(?=[\\s>])[^>]*>`,"gi");return ms.set(t,r),r},gs=(e,t)=>{if(yA.has(t.toLowerCase()))return 0;let n=e.match(xA(t));if(!n)return 0;let r=0;for(let i of n)i.trimEnd().endsWith("/>")||(r+=1);return r},Es=(e,t)=>{let n=e.match(IA(t));return n?n.length:0},NA=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},SA=e=>{let t=_A.test(e),n=AA.test(e);if(t||n)return[e];let r=Ue.lex(e,{gfm:!0}),i=[],a=[],s=!1;for(let o of r){let l=o.raw,u=i.length;if(a.length>0){i[u-1]+=l;let h=a.at(-1),d=gs(l,h),p=Es(l,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=l.match(CA);if(h){let d=h[1];gs(l,d)>Es(l,d)&&a.push(d)}}if(u>0&&!s){let h=i[u-1];if(NA(h)%2===1){i[u-1]=h+l;continue}}i.push(l),o.type!=="space"&&(s=o.type==="code")}return i},wA=(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,l)=>{if(!o.includes(`
|
|
122
122
|
|