@inkeep/open-knowledge 0.46.0-beta.8 → 0.46.0-beta.9

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.
Files changed (49) hide show
  1. package/dist/{acp-harness-probe-4DjqrOhu.mjs → acp-harness-probe-B3zP-iU3.mjs} +2 -2
  2. package/dist/cli.mjs +7 -7
  3. package/dist/constants-DJEQ5lbI.mjs +2 -0
  4. package/dist/git-handle-CZCF5f5x.mjs +1 -0
  5. package/dist/{git-handle-CUCj-M_k.mjs → git-handle-bsekfuqb.mjs} +3 -3
  6. package/dist/index.mjs +1 -1
  7. package/dist/{init-DWCsIT2Y.mjs → init-BSRAJcxJ.mjs} +3 -3
  8. package/dist/init-Nj3Qfja6.mjs +1 -0
  9. package/dist/{launch-json-removal-BCxhJz-M.mjs → launch-json-removal-Z49VHJab.mjs} +2 -2
  10. package/dist/{loader-84N4YMxM.mjs → loader-7F0JSi2o.mjs} +2 -2
  11. package/dist/loader-DEoi209o.mjs +1 -0
  12. package/dist/md-manager-DbwR9qMJ.mjs +2 -0
  13. package/dist/{open-browser-D-fJ9iwf.mjs → open-browser-DOh4nE9t.mjs} +2 -2
  14. package/dist/parse-worker.mjs +1 -1
  15. package/dist/{preview-Ce0jIM-0.mjs → preview-CI4qefY8.mjs} +2 -2
  16. package/dist/preview-rMognm1O.mjs +1 -0
  17. package/dist/public/assets/FeedbackForm-Dx8ISPUC.js +1 -0
  18. package/dist/public/assets/ShareBranchSwitchDialog-BOn9pwt8.js +1 -0
  19. package/dist/public/assets/{worktree-store-Cn9IFis3.js → auth-prompt-store-CmyRhcKh.js} +1 -1
  20. package/dist/public/assets/{globals-B5uVOYYT.js → globals-IzHn2MUy.js} +1 -1
  21. package/dist/public/assets/{index-DoyHoCFU.js → index-BW1cVj8N.js} +108 -108
  22. package/dist/public/assets/{uninstall-m1tFru3-.js → uninstall-BCLudTra.js} +1 -1
  23. package/dist/public/index.html +3 -3
  24. package/dist/public/uninstall.html +2 -2
  25. package/dist/{repair-launch-json-DKnGHC3s.mjs → repair-launch-json-Chs2wXL5.mjs} +2 -2
  26. package/dist/{repair-mcp-configs-BNqk430t.mjs → repair-mcp-configs-DC_Nk6wf.mjs} +2 -2
  27. package/dist/{repair-skills-HLaZ-M-Y.mjs → repair-skills-BW5UCBvh.mjs} +2 -2
  28. package/dist/repair-skills-v_TK3DOo.mjs +1 -0
  29. package/dist/server-lock-9cnBGhAH.mjs +1 -0
  30. package/dist/{server-lock-N4bxkmqA.mjs → server-lock-Cdm6cZ-8.mjs} +2 -2
  31. package/dist/{src-BldBF2Y_.mjs → src-2ftHD8eU.mjs} +1 -1
  32. package/dist/{src-B9fZz8CV.mjs → src-DrNAleIl.mjs} +2 -2
  33. package/dist/{src-BAuCUhtO.mjs → src-tAuEvoB8.mjs} +2 -2
  34. package/dist/{src-CBxmkYgG.mjs → src-zLMYDmwT.mjs} +4 -4
  35. package/dist/{start-CGRdHb1G.mjs → start-Bx6I5bEA.mjs} +3 -3
  36. package/dist/start-MnLPFpd0.mjs +1 -0
  37. package/dist/{write-project-skill-DZsw6Rkw.mjs → write-project-skill-xt4ohzdz.mjs} +2 -2
  38. package/package.json +4 -4
  39. package/dist/constants-GWFx-UC8.mjs +0 -2
  40. package/dist/git-handle-c0ljFZis.mjs +0 -1
  41. package/dist/init-ZV2BMIkj.mjs +0 -1
  42. package/dist/loader-gOaiaXCo.mjs +0 -1
  43. package/dist/md-manager-usiCjUg4.mjs +0 -2
  44. package/dist/preview-TJlA1vTS.mjs +0 -1
  45. package/dist/public/assets/FeedbackForm-YYOLAdPR.js +0 -1
  46. package/dist/public/assets/ShareBranchSwitchDialog-BT-R1a5Z.js +0 -1
  47. package/dist/repair-skills-COiT9pxq.mjs +0 -1
  48. package/dist/server-lock-DTx_HmnT.mjs +0 -1
  49. package/dist/start-uD8bt0wq.mjs +0 -1
@@ -144,7 +144,7 @@ ${t.slice(l+2)}`,d+=1;else break}t.push({indent:l,number:parseInt(s,10),content:
144
144
  `):``,markdownTokenizer:{name:`orderedList`,level:`block`,start:e=>{let t=e.match(/^(\s*)(\d+)\.\s+/)?.index;return t===void 0?-1:t},tokenize:(e,t,n)=>{let r=e.split(`
145
145
  `),[i,a]=N_(r);if(i.length===0)return;let o=P_(i,0,n);if(o.length!==0)return{type:`list`,ordered:!0,start:i[0]?.number||1,items:o,raw:r.slice(0,a).join(`
146
146
  `)}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleOrderedList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(I_,this.editor.getAttributes(L_)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addInputRules(){let e=xp({find:R_,type:this.type,getAttributes:e=>({start:+e[1]}),joinPredicate:(e,t)=>t.childCount+t.attrs.start===+e[1]});return(this.options.keepMarks||this.options.keepAttributes)&&(e=xp({find:R_,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:e=>({start:+e[1],...this.editor.getAttributes(L_)}),joinPredicate:(e,t)=>t.childCount+t.attrs.start===+e[1],editor:this.editor})),[e]}}),B_=/^\s*(\[([( |x])?\])\s$/,V_=Fp.create({name:`taskItem`,addOptions(){return{nested:!1,HTMLAttributes:{},taskListTypeName:`taskList`,a11y:void 0}},content(){return this.options.nested?`paragraph block*`:`paragraph+`},defining:!0,addAttributes(){return{checked:{default:!1,keepOnSplit:!1,parseHTML:e=>{let t=e.getAttribute(`data-checked`);return t===``||t===`true`},renderHTML:e=>({"data-checked":e.checked})}}},parseHTML(){return[{tag:`li[data-type="${this.name}"]`,priority:51}]},renderHTML({node:e,HTMLAttributes:t}){return[`li`,Vd(this.options.HTMLAttributes,t,{"data-type":this.name}),[`label`,[`input`,{type:`checkbox`,checked:e.attrs.checked?`checked`:null}],[`span`]],[`div`,0]]},parseMarkdown:(e,t)=>{let n=[];if(e.tokens&&e.tokens.length>0?n.push(t.createNode(`paragraph`,{},t.parseInline(e.tokens))):e.text?n.push(t.createNode(`paragraph`,{},[t.createNode(`text`,{text:e.text})])):n.push(t.createNode(`paragraph`,{},[])),e.nestedTokens&&e.nestedTokens.length>0){let r=t.parseChildren(e.nestedTokens);n.push(...r)}return t.createNode(`taskItem`,{checked:e.checked||!1},n)},renderMarkdown:(e,t)=>Np(e,t,`- [${e.attrs?.checked?`x`:` `}] `),addKeyboardShortcuts(){let e={Enter:()=>this.editor.commands.splitListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)};return this.options.nested?{...e,Tab:()=>this.editor.commands.sinkListItem(this.name)}:e},addNodeView(){return({node:e,HTMLAttributes:t,getPos:n,editor:r})=>{let i=document.createElement(`li`),a=document.createElement(`label`),o=document.createElement(`span`),s=document.createElement(`input`),c=document.createElement(`div`),l=e=>{var t;s.ariaLabel=((t=this.options.a11y)?.checkboxLabel)?.call(t,e,s.checked)||`Task item checkbox for ${e.textContent||`empty task item`}`};l(e),a.contentEditable=`false`,s.type=`checkbox`,s.addEventListener(`mousedown`,e=>e.preventDefault()),s.addEventListener(`change`,t=>{if(!r.isEditable&&!this.options.onReadOnlyChecked){s.checked=!s.checked;return}let{checked:i}=t.target;r.isEditable&&typeof n==`function`&&r.chain().focus(void 0,{scrollIntoView:!1}).command(({tr:e})=>{let t=n();if(typeof t!=`number`)return!1;let r=e.doc.nodeAt(t);return e.setNodeMarkup(t,void 0,{...r?.attrs,checked:i}),!0}).run(),!r.isEditable&&this.options.onReadOnlyChecked&&(this.options.onReadOnlyChecked(e,i)||(s.checked=!s.checked))}),Object.entries(this.options.HTMLAttributes).forEach(([e,t])=>{i.setAttribute(e,t)}),i.dataset.checked=e.attrs.checked,s.checked=e.attrs.checked,a.append(s,o),i.append(a,c),Object.entries(t).forEach(([e,t])=>{i.setAttribute(e,t)});let u=new Set(Object.keys(t));return{dom:i,contentDOM:c,update:e=>{if(e.type!==this.type)return!1;i.dataset.checked=e.attrs.checked,s.checked=e.attrs.checked,l(e);let t=r.extensionManager.attributes,n=Hd(e,t),a=new Set(Object.keys(n)),o=this.options.HTMLAttributes;return u.forEach(e=>{a.has(e)||(e in o?i.setAttribute(e,o[e]):i.removeAttribute(e))}),Object.entries(n).forEach(([e,t])=>{t==null?e in o?i.setAttribute(e,o[e]):i.removeAttribute(e):i.setAttribute(e,t)}),u=a,!0}}}},addInputRules(){return[xp({find:B_,type:this.type,getAttributes:e=>({checked:e[e.length-1]===`x`})})]}}),H_=Fp.create({name:`taskList`,addOptions(){return{itemTypeName:`taskItem`,HTMLAttributes:{}}},group:`block list`,content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:`ul[data-type="${this.name}"]`,priority:51}]},renderHTML({HTMLAttributes:e}){return[`ul`,Vd(this.options.HTMLAttributes,e,{"data-type":this.name}),0]},parseMarkdown:(e,t)=>t.createNode(`taskList`,{},t.parseChildren(e.items||[])),renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,`
147
- `):``,markdownTokenizer:{name:`taskList`,level:`block`,start(e){let t=e.match(/^\s*[-+*]\s+\[([ xX])\]\s+/)?.index;return t===void 0?-1:t},tokenize(e,t,n){let r=e=>{let t=Mp(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:e[3].toLowerCase()===`x`}),createToken:(e,t)=>({type:`taskItem`,raw:``,mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);return t?[{type:`taskList`,raw:t.raw,items:t.items}]:n.blockTokens(e)},i=Mp(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:e[3].toLowerCase()===`x`}),createToken:(e,t)=>({type:`taskItem`,raw:``,mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);if(i)return{type:`taskList`,raw:i.raw,items:i.items}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleTaskList:()=>({commands:e})=>e.toggleList(this.name,this.options.itemTypeName)}},addKeyboardShortcuts(){return{"Mod-Shift-9":()=>this.editor.commands.toggleTaskList()}}});op.create({name:`listKit`,addExtensions(){let e=[];return this.options.bulletList!==!1&&e.push(v_.configure(this.options.bulletList)),this.options.listItem!==!1&&e.push(y_.configure(this.options.listItem)),this.options.listKeymap!==!1&&e.push(A_.configure(this.options.listKeymap)),this.options.orderedList!==!1&&e.push(z_.configure(this.options.orderedList)),this.options.taskItem!==!1&&e.push(V_.configure(this.options.taskItem)),this.options.taskList!==!1&&e.push(H_.configure(this.options.taskList)),e}});var U_=`&nbsp;`,W_=`\xA0`,G_=Fp.create({name:`paragraph`,priority:1e3,addOptions(){return{HTMLAttributes:{}}},group:`block`,content:`inline*`,parseHTML(){return[{tag:`p`}]},renderHTML({HTMLAttributes:e}){return[`p`,Vd(this.options.HTMLAttributes,e),0]},parseMarkdown:(e,t)=>{let n=e.tokens||[];if(n.length===1&&n[0].type===`image`)return t.parseChildren([n[0]]);let r=t.parseInline(n);return n.length===1&&n[0].type===`text`&&(n[0].raw===U_||n[0].text===U_||n[0].raw===W_||n[0].text===W_)&&r.length===1&&r[0].type===`text`&&(r[0].text===U_||r[0].text===W_)?t.createNode(`paragraph`,void 0,[]):t.createNode(`paragraph`,void 0,r)},renderMarkdown:(e,t,n)=>{if(!e)return``;let r=Array.isArray(e.content)?e.content:[];if(r.length===0){let e=Array.isArray(n?.previousNode?.content)?n.previousNode.content:[];return n?.previousNode?.type===`paragraph`&&e.length===0?U_:``}return t.renderChildren(r)},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),K_=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/,q_=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g,J_=Zf.create({name:`strike`,addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:`s`},{tag:`del`},{tag:`strike`},{style:`text-decoration`,consuming:!1,getAttrs:e=>e.includes(`line-through`)?{}:!1}]},renderHTML({HTMLAttributes:e}){return[`s`,Vd(this.options.HTMLAttributes,e),0]},markdownTokenName:`del`,parseMarkdown:(e,t)=>t.applyMark(`strike`,t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>`~~${t.renderChildren(e)}~~`,addCommands(){return{setStrike:()=>({commands:e})=>e.setMark(this.name),toggleStrike:()=>({commands:e})=>e.toggleMark(this.name),unsetStrike:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-s":()=>this.editor.commands.toggleStrike()}},addInputRules(){return[vp({find:K_,type:this.type})]},addPasteRules(){return[Ip({find:q_,type:this.type})]}}),Y_=J_,X_=Fp.create({name:`text`,group:`inline`,parseMarkdown:e=>({type:`text`,text:e.text||``}),renderMarkdown:e=>e.text||``}),Z_=Zf.create({name:`underline`,addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:`u`},{style:`text-decoration`,consuming:!1,getAttrs:e=>e.includes(`underline`)?{}:!1}]},renderHTML({HTMLAttributes:e}){return[`u`,Vd(this.options.HTMLAttributes,e),0]},parseMarkdown(e,t){return t.applyMark(this.name||`underline`,t.parseInline(e.tokens||[]))},renderMarkdown(e,t){return`++${t.renderChildren(e)}++`},markdownTokenizer:{name:`underline`,level:`inline`,start(e){return e.indexOf(`++`)},tokenize(e,t,n){let r=/^(\+\+)([\s\S]+?)(\+\+)/.exec(e);if(!r)return;let i=r[2].trim();return{type:`underline`,raw:r[0],text:i,tokens:n.inlineTokens(i)}}},addCommands(){return{setUnderline:()=>({commands:e})=>e.setMark(this.name),toggleUnderline:()=>({commands:e})=>e.toggleMark(this.name),unsetUnderline:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-u":()=>this.editor.commands.toggleUnderline(),"Mod-U":()=>this.editor.commands.toggleUnderline()}}}),Q_=Z_;function $_(e={}){return new Ii({view(t){return new ev(t,e)}})}var ev=class{constructor(e,t){this.editorView=e,this.cursorPos=null,this.element=null,this.timeout=-1,this.lastDragEvent=null,this.width=t.width??1,this.color=t.color===!1?void 0:t.color||`black`,this.class=t.class,this.handlers=[`dragover`,`dragend`,`drop`,`dragleave`].map(t=>{let n=e=>{this[t](e)};return e.dom.addEventListener(t,n),{name:t,handler:n}})}destroy(){this.handlers.forEach(({name:e,handler:t})=>this.editorView.dom.removeEventListener(e,t))}update(e,t){if(this.cursorPos!=null&&t.doc!=e.state.doc)if(this.lastDragEvent){let e=this.computeTarget(this.lastDragEvent);e==this.cursorPos?this.updateOverlay():this.setCursor(e)}else this.updateOverlay()}setCursor(e){e!=this.cursorPos&&(this.cursorPos=e,e==null?(this.element.parentNode.removeChild(this.element),this.element=null):this.updateOverlay())}updateOverlay(){let e=this.editorView.state.doc.resolve(this.cursorPos),t=!e.parent.inlineContent,n,r=this.editorView.dom,i=r.getBoundingClientRect(),a=i.width/r.offsetWidth,o=i.height/r.offsetHeight;if(t){let t=e.nodeBefore,r=e.nodeAfter;if(t||r){let e=this.editorView.nodeDOM(this.cursorPos-(t?t.nodeSize:0));if(e){let i=e.getBoundingClientRect(),a=t?i.bottom:i.top;t&&r&&(a=(a+this.editorView.nodeDOM(this.cursorPos).getBoundingClientRect().top)/2);let s=this.width/2*o;n={left:i.left,right:i.right,top:a-s,bottom:a+s}}}}if(!n){let e=this.editorView.coordsAtPos(this.cursorPos),t=this.width/2*a;n={left:e.left-t,right:e.left+t,top:e.top,bottom:e.bottom}}let s=this.editorView.dom.offsetParent;this.element||(this.element=s.appendChild(document.createElement(`div`)),this.class&&(this.element.className=this.class),this.element.style.cssText=`position: absolute; z-index: 50; pointer-events: none;`,this.color&&(this.element.style.backgroundColor=this.color)),this.element.classList.toggle(`prosemirror-dropcursor-block`,t),this.element.classList.toggle(`prosemirror-dropcursor-inline`,!t);let c,l;if(!s||s==document.body&&getComputedStyle(s).position==`static`)c=-pageXOffset,l=-pageYOffset;else{let e=s.getBoundingClientRect(),t=e.width/s.offsetWidth,n=e.height/s.offsetHeight;c=e.left-s.scrollLeft*t,l=e.top-s.scrollTop*n}this.element.style.left=(n.left-c)/a+`px`,this.element.style.top=(n.top-l)/o+`px`,this.element.style.width=(n.right-n.left)/a+`px`,this.element.style.height=(n.bottom-n.top)/o+`px`}scheduleRemoval(e){clearTimeout(this.timeout),this.timeout=setTimeout(()=>this.setCursor(null),e)}computeTarget(e){let t=this.editorView.posAtCoords({left:e.clientX,top:e.clientY}),n=t&&t.inside>=0&&this.editorView.state.doc.nodeAt(t.inside),r=n&&n.type.spec.disableDropCursor,i=typeof r==`function`?r(this.editorView,t,e):r;if(!t||i)return null;let a=t.pos;if(this.editorView.dragging&&this.editorView.dragging.slice){let e=ni(this.editorView.state.doc,a,this.editorView.dragging.slice);e!=null&&(a=e)}return a}dragover(e){if(!this.editorView.editable)return;this.lastDragEvent=e;let t=this.computeTarget(e);t!=null&&(this.setCursor(t),this.scheduleRemoval(5e3))}dragend(){this.scheduleRemoval(20)}drop(){this.scheduleRemoval(20)}dragleave(e){this.editorView.dom.contains(e.relatedTarget)||this.setCursor(null)}},tv=class e extends Ci{constructor(e){super(e,e)}map(t,n){let r=t.resolve(n.map(this.head));return e.valid(r)?new e(r):Ci.near(r)}content(){return I.empty}eq(t){return t instanceof e&&t.head==this.head}toJSON(){return{type:`gapcursor`,pos:this.head}}static fromJSON(t,n){if(typeof n.pos!=`number`)throw RangeError(`Invalid input for GapCursor.fromJSON`);return new e(t.resolve(n.pos))}getBookmark(){return new nv(this.anchor)}static valid(e){let t=e.parent;if(t.inlineContent||!iv(e)||!av(e))return!1;let n=t.type.spec.allowGapCursor;if(n!=null)return n;let r=t.contentMatchAt(e.index()).defaultType;return r&&r.isTextblock}static findGapCursorFrom(t,n,r=!1){search:for(;;){if(!r&&e.valid(t))return t;let i=t.pos,a=null;for(let r=t.depth;;r--){let o=t.node(r);if(n>0?t.indexAfter(r)<o.childCount:t.index(r)>0){a=o.child(n>0?t.indexAfter(r):t.index(r)-1);break}else if(r==0)return null;i+=n;let s=t.doc.resolve(i);if(e.valid(s))return s}for(;;){let o=n>0?a.firstChild:a.lastChild;if(!o){if(a.isAtom&&!a.isText&&!R.isSelectable(a)){t=t.doc.resolve(i+a.nodeSize*n),r=!1;continue search}break}a=o,i+=n;let s=t.doc.resolve(i);if(e.valid(s))return s}return null}}};tv.prototype.visible=!1,tv.findFrom=tv.findGapCursorFrom,Ci.jsonID(`gapcursor`,tv);var nv=class e{constructor(e){this.pos=e}map(t){return new e(t.map(this.pos))}resolve(e){let t=e.resolve(this.pos);return tv.valid(t)?new tv(t):Ci.near(t)}};function rv(e){return e.isAtom||e.spec.isolating||e.spec.createGapCursor}function iv(e){for(let t=e.depth;t>=0;t--){let n=e.index(t),r=e.node(t);if(n==0){if(r.type.spec.isolating)return!0;continue}for(let e=r.child(n-1);;e=e.lastChild){if(e.childCount==0&&!e.inlineContent||rv(e.type))return!0;if(e.inlineContent)return!1}}return!0}function av(e){for(let t=e.depth;t>=0;t--){let n=e.indexAfter(t),r=e.node(t);if(n==r.childCount){if(r.type.spec.isolating)return!0;continue}for(let e=r.child(n);;e=e.firstChild){if(e.childCount==0&&!e.inlineContent||rv(e.type))return!0;if(e.inlineContent)return!1}}return!0}function ov(){return new Ii({props:{decorations:dv,createSelectionBetween(e,t,n){return t.pos==n.pos&&tv.valid(n)?new tv(n):null},handleClick:lv,handleKeyDown:sv,handleDOMEvents:{beforeinput:uv}}})}const sv=uu({ArrowLeft:cv(`horiz`,-1),ArrowRight:cv(`horiz`,1),ArrowUp:cv(`vert`,-1),ArrowDown:cv(`vert`,1)});function cv(e,t){let n=e==`vert`?t>0?`down`:`up`:t>0?`right`:`left`;return function(e,r,i){let a=e.selection,o=t>0?a.$to:a.$from,s=a.empty;if(a instanceof L){if(!i.endOfTextblock(n)||o.depth==0)return!1;s=!1,o=e.doc.resolve(t>0?o.after():o.before())}let c=tv.findGapCursorFrom(o,t,s);return c?(r&&r(e.tr.setSelection(new tv(c))),!0):!1}}function lv(e,t,n){if(!e||!e.editable)return!1;let r=e.state.doc.resolve(t);if(!tv.valid(r))return!1;let i=e.posAtCoords({left:n.clientX,top:n.clientY});return i&&i.inside>-1&&R.isSelectable(e.state.doc.nodeAt(i.inside))?!1:(e.dispatch(e.state.tr.setSelection(new tv(r))),!0)}function uv(e,t){if(t.inputType!=`insertCompositionText`||!(e.state.selection instanceof tv))return!1;let{$from:n}=e.state.selection,r=n.parent.contentMatchAt(n.index()).findWrapping(e.state.schema.nodes.text);if(!r)return!1;let i=F.empty;for(let e=r.length-1;e>=0;e--)i=F.from(r[e].createAndFill(null,i));let a=e.state.tr.replace(n.pos,n.pos,new I(i,0,0));return a.setSelection(L.near(a.doc.resolve(n.pos+1))),e.dispatch(a),!1}function dv(e){if(!(e.selection instanceof tv))return null;let t=document.createElement(`div`);return t.className=`ProseMirror-gapcursor`,ll.create(e.doc,[ol.widget(e.selection.head,t,{key:`gapcursor`})])}var fv=200,pv=function(){};pv.prototype.append=function(e){return e.length?(e=pv.from(e),!this.length&&e||e.length<fv&&this.leafAppend(e)||this.length<fv&&e.leafPrepend(this)||this.appendInner(e)):this},pv.prototype.prepend=function(e){return e.length?pv.from(e).append(this):this},pv.prototype.appendInner=function(e){return new hv(this,e)},pv.prototype.slice=function(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.length),e>=t?pv.empty:this.sliceInner(Math.max(0,e),Math.min(this.length,t))},pv.prototype.get=function(e){if(!(e<0||e>=this.length))return this.getInner(e)},pv.prototype.forEach=function(e,t,n){t===void 0&&(t=0),n===void 0&&(n=this.length),t<=n?this.forEachInner(e,t,n,0):this.forEachInvertedInner(e,t,n,0)},pv.prototype.map=function(e,t,n){t===void 0&&(t=0),n===void 0&&(n=this.length);var r=[];return this.forEach(function(t,n){return r.push(e(t,n))},t,n),r},pv.from=function(e){return e instanceof pv?e:e&&e.length?new mv(e):pv.empty};var mv=function(e){function t(t){e.call(this),this.values=t}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(e,n){return e==0&&n==this.length?this:new t(this.values.slice(e,n))},t.prototype.getInner=function(e){return this.values[e]},t.prototype.forEachInner=function(e,t,n,r){for(var i=t;i<n;i++)if(e(this.values[i],r+i)===!1)return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){for(var i=t-1;i>=n;i--)if(e(this.values[i],r+i)===!1)return!1},t.prototype.leafAppend=function(e){if(this.length+e.length<=fv)return new t(this.values.concat(e.flatten()))},t.prototype.leafPrepend=function(e){if(this.length+e.length<=fv)return new t(e.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(t.prototype,n),t}(pv);pv.empty=new mv([]);var hv=function(e){function t(t,n){e.call(this),this.left=t,this.right=n,this.length=t.length+n.length,this.depth=Math.max(t.depth,n.depth)+1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},t.prototype.getInner=function(e){return e<this.left.length?this.left.get(e):this.right.get(e-this.left.length)},t.prototype.forEachInner=function(e,t,n,r){var i=this.left.length;if(t<i&&this.left.forEachInner(e,t,Math.min(n,i),r)===!1||n>i&&this.right.forEachInner(e,Math.max(t-i,0),Math.min(this.length,n)-i,r+i)===!1)return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){var i=this.left.length;if(t>i&&this.right.forEachInvertedInner(e,t-i,Math.max(n,i)-i,r+i)===!1||n<i&&this.left.forEachInvertedInner(e,Math.min(t,i),n,r)===!1)return!1},t.prototype.sliceInner=function(e,t){if(e==0&&t==this.length)return this;var n=this.left.length;return t<=n?this.left.slice(e,t):e>=n?this.right.slice(e-n,t-n):this.left.slice(e,n).append(this.right.slice(0,t-n))},t.prototype.leafAppend=function(e){var n=this.right.leafAppend(e);if(n)return new t(this.left,n)},t.prototype.leafPrepend=function(e){var n=this.left.leafPrepend(e);if(n)return new t(n,this.right)},t.prototype.appendInner=function(e){return this.left.depth>=Math.max(this.right.depth,e.depth)+1?new t(this.left,new t(this.right,e)):new t(this,e)},t}(pv),gv=class e{constructor(e,t){this.items=e,this.eventCount=t}popEvent(t,n){if(this.eventCount==0)return null;let r=this.items.length;for(;;r--)if(this.items.get(r-1).selection){--r;break}let i,a;n&&(i=this.remapping(r,this.items.length),a=i.maps.length);let o=t.tr,s,c,l=[],u=[];return this.items.forEach((t,n)=>{if(!t.step){i||(i=this.remapping(r,n+1),a=i.maps.length),a--,u.push(t);return}if(i){u.push(new vv(t.map));let e=t.step.map(i.slice(a)),n;e&&o.maybeStep(e).doc&&(n=o.mapping.maps[o.mapping.maps.length-1],l.push(new vv(n,void 0,void 0,l.length+u.length))),a--,n&&i.appendMap(n,a)}else o.maybeStep(t.step);if(t.selection)return s=i?t.selection.map(i.slice(a)):t.selection,c=new e(this.items.slice(0,r).append(u.reverse().concat(l)),this.eventCount-1),!1},this.items.length,0),{remaining:c,transform:o,selection:s}}addTransform(t,n,r,i){let a=[],o=this.eventCount,s=this.items,c=!i&&s.length?s.get(s.length-1):null;for(let e=0;e<t.steps.length;e++){let r=t.steps[e].invert(t.docs[e]),l=new vv(t.mapping.maps[e],r,n),u;(u=c&&c.merge(l))&&(l=u,e?a.pop():s=s.slice(0,s.length-1)),a.push(l),n&&=(o++,void 0),i||(c=l)}let l=o-r.depth;return l>bv&&(s=_v(s,l),o-=l),new e(s.append(a),o)}remapping(e,t){let n=new br;return this.items.forEach((t,r)=>{let i=t.mirrorOffset!=null&&r-t.mirrorOffset>=e?n.maps.length-t.mirrorOffset:void 0;n.appendMap(t.map,i)},e,t),n}addMaps(t){return this.eventCount==0?this:new e(this.items.append(t.map(e=>new vv(e))),this.eventCount)}rebased(t,n){if(!this.eventCount)return this;let r=[],i=Math.max(0,this.items.length-n),a=t.mapping,o=t.steps.length,s=this.eventCount;this.items.forEach(e=>{e.selection&&s--},i);let c=n;this.items.forEach(e=>{let n=a.getMirror(--c);if(n==null)return;o=Math.min(o,n);let i=a.maps[n];if(e.step){let o=t.steps[n].invert(t.docs[n]),l=e.selection&&e.selection.map(a.slice(c+1,n));l&&s++,r.push(new vv(i,o,l))}else r.push(new vv(i))},i);let l=[];for(let e=n;e<o;e++)l.push(new vv(a.maps[e]));let u=new e(this.items.slice(0,i).append(l).append(r),s);return u.emptyItemCount()>500&&(u=u.compress(this.items.length-r.length)),u}emptyItemCount(){let e=0;return this.items.forEach(t=>{t.step||e++}),e}compress(t=this.items.length){let n=this.remapping(0,t),r=n.maps.length,i=[],a=0;return this.items.forEach((e,o)=>{if(o>=t)i.push(e),e.selection&&a++;else if(e.step){let t=e.step.map(n.slice(r)),o=t&&t.getMap();if(r--,o&&n.appendMap(o,r),t){let s=e.selection&&e.selection.map(n.slice(r));s&&a++;let c=new vv(o.invert(),t,s),l,u=i.length-1;(l=i.length&&i[u].merge(c))?i[u]=l:i.push(c)}}else e.map&&r--},this.items.length,0),new e(pv.from(i.reverse()),a)}};gv.empty=new gv(pv.empty,0);function _v(e,t){let n;return e.forEach((e,r)=>{if(e.selection&&t--==0)return n=r,!1}),e.slice(n)}var vv=class e{constructor(e,t,n,r){this.map=e,this.step=t,this.selection=n,this.mirrorOffset=r}merge(t){if(this.step&&t.step&&!t.selection){let n=t.step.merge(this.step);if(n)return new e(n.getMap().invert(),n,this.selection)}}},yv=class{constructor(e,t,n,r,i){this.done=e,this.undone=t,this.prevRanges=n,this.prevTime=r,this.prevComposition=i}};const bv=20;function xv(e,t,n,r){let i=n.getMeta(kv),a;if(i)return i.historyState;n.getMeta(Av)&&(e=new yv(e.done,e.undone,null,0,-1));let o=n.getMeta(`appendedTransaction`);if(n.steps.length==0)return e;if(o&&o.getMeta(kv))return o.getMeta(kv).redo?new yv(e.done.addTransform(n,void 0,r,Ov(t)),e.undone,Cv(n.mapping.maps),e.prevTime,e.prevComposition):new yv(e.done,e.undone.addTransform(n,void 0,r,Ov(t)),null,e.prevTime,e.prevComposition);if(n.getMeta(`addToHistory`)!==!1&&!(o&&o.getMeta(`addToHistory`)===!1)){let i=n.getMeta(`composition`),a=e.prevTime==0||!o&&e.prevComposition!=i&&(e.prevTime<(n.time||0)-r.newGroupDelay||!Sv(n,e.prevRanges)),s=o?wv(e.prevRanges,n.mapping):Cv(n.mapping.maps);return new yv(e.done.addTransform(n,a?t.selection.getBookmark():void 0,r,Ov(t)),gv.empty,s,n.time,i??e.prevComposition)}else if(a=n.getMeta(`rebased`))return new yv(e.done.rebased(n,a),e.undone.rebased(n,a),wv(e.prevRanges,n.mapping),e.prevTime,e.prevComposition);else return new yv(e.done.addMaps(n.mapping.maps),e.undone.addMaps(n.mapping.maps),wv(e.prevRanges,n.mapping),e.prevTime,e.prevComposition)}function Sv(e,t){if(!t)return!1;if(!e.docChanged)return!0;let n=!1;return e.mapping.maps[0].forEach((e,r)=>{for(let i=0;i<t.length;i+=2)e<=t[i+1]&&r>=t[i]&&(n=!0)}),n}function Cv(e){let t=[];for(let n=e.length-1;n>=0&&t.length==0;n--)e[n].forEach((e,n,r,i)=>t.push(r,i));return t}function wv(e,t){if(!e)return null;let n=[];for(let r=0;r<e.length;r+=2){let i=t.map(e[r],1),a=t.map(e[r+1],-1);i<=a&&n.push(i,a)}return n}function Tv(e,t,n){let r=Ov(t),i=kv.get(t).spec.config,a=(n?e.undone:e.done).popEvent(t,r);if(!a)return null;let o=a.selection.resolve(a.transform.doc),s=(n?e.done:e.undone).addTransform(a.transform,t.selection.getBookmark(),i,r),c=new yv(n?s:a.remaining,n?a.remaining:s,null,0,-1);return a.transform.setSelection(o).setMeta(kv,{redo:n,historyState:c})}let Ev=!1,Dv=null;function Ov(e){let t=e.plugins;if(Dv!=t){Ev=!1,Dv=t;for(let e=0;e<t.length;e++)if(t[e].spec.historyPreserveItems){Ev=!0;break}}return Ev}const kv=new zi(`history`),Av=new zi(`closeHistory`);function jv(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new Ii({key:kv,state:{init(){return new yv(gv.empty,gv.empty,null,0,-1)},apply(t,n,r){return xv(n,r,t,e)}},config:e,props:{handleDOMEvents:{beforeinput(e,t){let n=t.inputType,r=n==`historyUndo`?Nv:n==`historyRedo`?Pv:null;return!r||!e.editable?!1:(t.preventDefault(),r(e.state,e.dispatch))}}}})}function Mv(e,t){return(n,r)=>{let i=kv.getState(n);if(!i||(e?i.undone:i.done).eventCount==0)return!1;if(r){let a=Tv(i,n,e);a&&r(t?a.scrollIntoView():a)}return!0}}const Nv=Mv(!1,!0),Pv=Mv(!0,!0);op.create({name:`characterCount`,addOptions(){return{limit:null,mode:`textSize`,textCounter:e=>e.length,wordCounter:e=>e.split(` `).filter(e=>e!==``).length}},addStorage(){return{characters:()=>0,words:()=>0}},onBeforeCreate(){this.storage.characters=e=>{let t=e?.node||this.editor.state.doc;if((e?.mode||this.options.mode)===`textSize`){let e=t.textBetween(0,t.content.size,void 0,` `);return this.options.textCounter(e)}return t.nodeSize},this.storage.words=e=>{let t=e?.node||this.editor.state.doc,n=t.textBetween(0,t.content.size,` `,` `);return this.options.wordCounter(n)}},addProseMirrorPlugins(){let e=!1;return[new Ii({key:new zi(`characterCount`),appendTransaction:(t,n,r)=>{if(e)return;let i=this.options.limit;if(i==null||i===0){e=!0;return}let a=this.storage.characters({node:r.doc});if(a>i){let t=a-i;console.warn(`[CharacterCount] Initial content exceeded limit of ${i} characters. Content was automatically trimmed.`);let n=r.tr.deleteRange(0,t);return e=!0,n}e=!0},filterTransaction:(e,t)=>{let n=this.options.limit;if(!e.docChanged||n===0||n==null)return!0;let r=this.storage.characters({node:t.doc}),i=this.storage.characters({node:e.doc});if(i<=n||r>n&&i>n&&i<=r)return!0;if(r>n&&i>n&&i>r||!e.getMeta(`paste`))return!1;let a=e.selection.$head.pos,o=a-(i-n),s=a;return e.deleteRange(o,s),!(this.storage.characters({node:e.doc})>n)}})]}});var Fv=op.create({name:`dropCursor`,addOptions(){return{color:`currentColor`,width:1,class:void 0}},addProseMirrorPlugins(){return[$_(this.options)]}});op.create({name:`focus`,addOptions(){return{className:`has-focus`,mode:`all`}},addProseMirrorPlugins(){return[new Ii({key:new zi(`focus`),props:{decorations:({doc:e,selection:t})=>{let{isEditable:n,isFocused:r}=this.editor,{anchor:i}=t,a=[];if(!n||!r)return ll.create(e,[]);let o=0;this.options.mode===`deepest`&&e.descendants((e,t)=>{if(!e.isText){if(!(i>=t&&i<=t+e.nodeSize-1))return!1;o+=1}});let s=0;return e.descendants((e,t)=>{if(e.isText||!(i>=t&&i<=t+e.nodeSize-1))return!1;if(s+=1,this.options.mode===`deepest`&&o-s>0||this.options.mode===`shallowest`&&s>1)return this.options.mode===`deepest`;a.push(ol.node(t,t+e.nodeSize,{class:this.options.className}))}),ll.create(e,a)}}})]}});var Iv=op.create({name:`gapCursor`,addProseMirrorPlugins(){return[ov()]},extendNodeSchema(e){return{allowGapCursor:Fd(z(e,`allowGapCursor`,{name:e.name,options:e.options,storage:e.storage}))??null}}}),Lv=`placeholder`;function Rv(e){return e.replace(/\s+/g,`-`).replace(/[^a-zA-Z0-9-]/g,``).replace(/^[0-9-]+/,``).replace(/^-+/,``).toLowerCase()}op.create({name:`placeholder`,addOptions(){return{emptyEditorClass:`is-editor-empty`,emptyNodeClass:`is-empty`,dataAttribute:Lv,placeholder:`Write something …`,showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}},addProseMirrorPlugins(){let e=this.options.dataAttribute?`data-${Rv(this.options.dataAttribute)}`:`data-${Lv}`;return[new Ii({key:new zi(`placeholder`),props:{decorations:({doc:t,selection:n})=>{let r=this.editor.isEditable||!this.options.showOnlyWhenEditable,{anchor:i}=n,a=[];if(!r)return null;let o=this.editor.isEmpty;return t.descendants((t,n)=>{let r=i>=n&&i<=n+t.nodeSize,s=!t.isLeaf&&gf(t);if(!t.type.isTextblock)return this.options.includeChildren;if((r||!this.options.showOnlyCurrent)&&s){let i=[this.options.emptyNodeClass];o&&i.push(this.options.emptyEditorClass);let s=ol.node(n,n+t.nodeSize,{class:i.join(` `),[e]:typeof this.options.placeholder==`function`?this.options.placeholder({editor:this.editor,node:t,pos:n,hasAnchor:r}):this.options.placeholder});a.push(s)}return this.options.includeChildren}),ll.create(t,a)}}})]}}),op.create({name:`selection`,addOptions(){return{className:`selection`}},addProseMirrorPlugins(){let{editor:e,options:t}=this;return[new Ii({key:new zi(`selection`),props:{decorations(n){return n.selection.empty||e.isFocused||!e.isEditable||_f(n.selection)||e.view.dragging?null:ll.create(n.doc,[ol.inline(n.selection.from,n.selection.to,{class:t.className})])}}})]}});function zv({types:e,node:t}){return t&&Array.isArray(e)&&e.includes(t.type)||t?.type===e}var Bv=op.create({name:`trailingNode`,addOptions(){return{node:void 0,notAfter:[]}},addProseMirrorPlugins(){let e=new zi(this.name),t=this.options.node||this.editor.schema.topNodeType.contentMatch.defaultType?.name||`paragraph`,n=Object.entries(this.editor.schema.nodes).map(([,e])=>e).filter(e=>(this.options.notAfter||[]).concat(t).includes(e.name));return[new Ii({key:e,appendTransaction:(n,r,i)=>{let{doc:a,tr:o,schema:s}=i,c=e.getState(i),l=a.content.size,u=s.nodes[t];if(!n.some(e=>e.getMeta(`skipTrailingNode`))&&c)return o.insert(l,u.create())},state:{init:(e,t)=>{let r=t.tr.doc.lastChild;return!zv({node:r,types:n})},apply:(e,t)=>{if(!e.docChanged||e.getMeta(`__uniqueIDTransaction`))return t;let r=e.doc.lastChild;return!zv({node:r,types:n})}}})]}}),Vv=op.create({name:`undoRedo`,addOptions(){return{depth:100,newGroupDelay:500}},addCommands(){return{undo:()=>({state:e,dispatch:t})=>Nv(e,t),redo:()=>({state:e,dispatch:t})=>Pv(e,t)}},addProseMirrorPlugins(){return[jv(this.options)]},addKeyboardShortcuts(){return{"Mod-z":()=>this.editor.commands.undo(),"Shift-Mod-z":()=>this.editor.commands.redo(),"Mod-y":()=>this.editor.commands.redo(),"Mod-я":()=>this.editor.commands.undo(),"Shift-Mod-я":()=>this.editor.commands.redo()}}}),Hv=op.create({name:`starterKit`,addExtensions(){let e=[];return this.options.bold!==!1&&e.push(qp.configure(this.options.bold)),this.options.blockquote!==!1&&e.push(i_.configure(this.options.blockquote)),this.options.bulletList!==!1&&e.push(v_.configure(this.options.bulletList)),this.options.code!==!1&&e.push(c_.configure(this.options.code)),this.options.codeBlock!==!1&&e.push(Bp.configure(this.options.codeBlock)),this.options.document!==!1&&e.push(u_.configure(this.options.document)),this.options.dropcursor!==!1&&e.push(Fv.configure(this.options.dropcursor)),this.options.gapcursor!==!1&&e.push(Iv.configure(this.options.gapcursor)),this.options.hardBreak!==!1&&e.push(lm.configure(this.options.hardBreak)),this.options.heading!==!1&&e.push(dm.configure(this.options.heading)),this.options.undoRedo!==!1&&e.push(Vv.configure(this.options.undoRedo)),this.options.horizontalRule!==!1&&e.push(d_.configure(this.options.horizontalRule)),this.options.italic!==!1&&e.push($p.configure(this.options.italic)),this.options.listItem!==!1&&e.push(y_.configure(this.options.listItem)),this.options.listKeymap!==!1&&e.push(A_.configure(this.options?.listKeymap)),this.options.link!==!1&&e.push(Am.configure(this.options?.link)),this.options.orderedList!==!1&&e.push(z_.configure(this.options.orderedList)),this.options.paragraph!==!1&&e.push(G_.configure(this.options.paragraph)),this.options.strike!==!1&&e.push(J_.configure(this.options.strike)),this.options.text!==!1&&e.push(X_.configure(this.options.text)),this.options.underline!==!1&&e.push(Z_.configure(this.options?.underline)),this.options.trailingNode!==!1&&e.push(Bv.configure(this.options?.trailingNode)),e}});const Uv=a_.extend({priority:60,addAttributes(){return{...this.parent?.(),sourceMarkerSpacings:{default:null}}}}),Wv=l_.extend({excludes:``,addAttributes(){return{...this.parent?.(),sourceFenceChar:{default:"`"},sourceFenceLength:{default:1},sourcePadded:{default:!1,rendered:!1}}}}),Gv=Fp.create({name:`commentBlock`,group:`block`,content:`block+`,defining:!0,priority:60,addAttributes(){return{sourceForm:{default:`percent`,parseHTML:e=>e.getAttribute(`data-source-form`)===`html`?`html`:`percent`,renderHTML:e=>e.sourceForm===`html`?{"data-source-form":`html`}:{}},sourceLayout:{default:`block`,parseHTML:e=>e.getAttribute(`data-source-layout`)===`inline`?`inline`:`block`,renderHTML:e=>e.sourceLayout===`inline`?{"data-source-layout":`inline`}:{}}}},parseHTML(){return[{tag:`aside[data-comment-block]`},{tag:`aside.comment-block`}]},renderHTML({HTMLAttributes:e}){return[`aside`,{"data-comment-block":``,"data-clipboard-omit":`true`,class:`comment-block`,...e},0]},addCommands(){return{setCommentBlock:()=>({commands:e})=>e.wrapIn(this.name),toggleCommentBlock:()=>({commands:e})=>e.toggleWrap(this.name),unsetCommentBlock:()=>({commands:e})=>e.lift(this.name)}}}),Kv=Zf.create({name:`comment`,priority:10,excludes:``,inclusive:!1,addAttributes(){return{sourceForm:{default:`percent`,parseHTML:e=>e.getAttribute(`data-source-form`)===`html`?`html`:`percent`,renderHTML:e=>e.sourceForm===`html`?{"data-source-form":`html`}:{}}}},parseHTML(){return[{tag:`span[data-comment-mark]`}]},renderHTML({HTMLAttributes:e}){return[`span`,{"data-comment-mark":``,"data-clipboard-omit":`true`,class:`comment-mark`,...e},0]},addCommands(){return{setComment:()=>({commands:e})=>e.setMark(this.name),toggleComment:()=>({commands:e})=>e.toggleMark(this.name),unsetComment:()=>({commands:e})=>e.unsetMark(this.name)}}}),qv=op.create({name:`docFidelity`,addGlobalAttributes(){return[{types:[`doc`],attributes:{sourceDocBoundary:{default:null,rendered:!1}}}]}}),Jv=Fp.create({name:`imageReference`,marks:`_`,group:`inline`,inline:!0,atom:!0,priority:60,addAttributes(){return{alt:{default:``},label:{default:``},identifier:{default:``},referenceType:{default:`shortcut`}}},parseHTML(){return[{tag:`img[data-image-reference]`}]},renderHTML({node:e}){let{alt:t,label:n,referenceType:r}=e.attrs;return[`img`,{"data-image-reference":``,"data-reference-type":r,"data-label":n,alt:t||n}]}});function Yv(e){for(let t=e.depth;t>0;t--)if(e.node(t).type.name===`listItem`)return t;return null}function Xv(e){let t=!1;return e.descendants(e=>t?!1:(e.type.name===`list`&&(t=!0),!t)),t}function Zv(e){let{selection:t}=e;return t instanceof L?t.$cursor:null}function Qv(e){let t=Zv(e);if(!t||t.parentOffset!==0)return!1;let n=Yv(t);if(n===null||t.depth!==n+1||t.index(n)!==0)return!1;let r=t.index(n-1);return r===0?!1:Xv(t.node(n-1).child(r-1))}function $v(e,t){for(let n=t-1;n>=0;n--){let t=e.node(n),r=e.index(n);if(r<t.childCount-1){let e=t.child(r+1),i=n+1;for(;e.type.name===`list`&&e.firstChild;)e=e.firstChild,i+=1;return e.type.name===`listItem`?i:null}}return null}function ey(e){let t=Zv(e);if(!t||t.parentOffset!==t.parent.content.size)return!1;let n=Yv(t);if(n===null)return!1;for(let e=t.depth;e>n;e--)if(t.index(e-1)!==t.node(e-1).childCount-1)return!1;let r=$v(t,n);return r!==null&&r<n}const ty=op.create({name:`listBoundaryMerge`,addKeyboardShortcuts(){let e=()=>{let{editor:e}=this;if(!Qv(e.state))return!1;if(e.commands.undoInputRule())return!0;let{state:t,view:n}=e;return Ui(t,n.dispatch,n)},t=()=>{let{editor:e}=this;if(!ey(e.state))return!1;let{state:t,view:n}=e;return Wi(t,n.dispatch,n)};return{Backspace:e,"Mod-Backspace":e,Delete:t,"Mod-Delete":t}}}),ny=new Map([[32,` `],[9,` `],[160,`\xA0`]]);function ry(e){let t=/^&#(x[0-9A-Fa-f]+|X[0-9A-Fa-f]+|[0-9]+);$/.exec(e);if(!t)return null;let n=t[1],r=n[0]===`x`||n[0]===`X`,i=Number.parseInt(r?n.slice(1):n,r?16:10);return Number.isNaN(i)?null:i}function iy(e){let t=ry(e);return t!==null&&ny.has(t)}function ay(e){let t=ry(e);return t===null?null:ny.get(t)??null}const oy=/&#(?:x[0-9A-Fa-f]+|X[0-9A-Fa-f]+|[0-9]+);/g;function sy(e){oy.lastIndex=0;let t=e.match(oy);if(t===null||t.join(``)!==e)return null;let n=``;for(let e of t){let t=ay(e);if(t===null)return null;n+=t}return n}const cy=Zf.create({name:`sourceLiteral`,priority:10,excludes:``,inclusive:!1,addAttributes(){return{sourceRaw:{default:``}}},parseHTML(){return[{tag:`span[data-source-literal]`}]},renderHTML({HTMLAttributes:e}){return[`span`,{"data-source-literal":``,...e},0]}});function ly(e,t){if(typeof e!=`string`||typeof t!=`string`||/[\x00-\x1F\x7F]/.test(e))return!1;let n=e.replaceAll(`\xA0`,` `),r=t.replaceAll(`\xA0`,` `);return n===r||uy(n)===r?!0:sy(e)===t}function uy(e){return e.replace(/\\([!-/:-@[-`{-~])/g,`$1`)}const dy=Y_.extend({priority:60,addAttributes(){return{...this.parent?.(),sourceDelimiter:{default:`~~`,rendered:!1}}}}),fy=n_.extend({priority:60,addAttributes(){return{...this.parent?.(),sourceDashCounts:{default:null},sourceOuterPipes:{default:null,rendered:!1},sourceAlignmentPadding:{default:null,rendered:!1}}}}),py=Vg.extend({priority:60,addAttributes(){return{...this.parent?.(),sourcePadding:{default:null}}}}),my=Hg.extend({priority:60,addAttributes(){return{...this.parent?.(),sourcePadding:{default:null}}}}),hy=Fp.create({name:`tag`,marks:`_`,group:`inline`,inline:!0,atom:!0,selectable:!0,priority:60,addAttributes(){return{value:{default:``}}},parseHTML(){return[{tag:`a[data-tag]`,getAttrs:e=>typeof e==`string`?!1:{value:e.getAttribute(`data-tag`)||``}}]},renderHTML({node:e,HTMLAttributes:t}){let n=String(e.attrs.value??``);return[`a`,{...t,"data-tag":n,href:`#tag/${n}`,class:`tag`},`#${n}`]},addCommands(){return{insertTag:e=>({chain:t})=>t().insertContent({type:`tag`,attrs:{value:e}}).run()}}}),gy=/^(?:---|—-|___\s|\*\*\*\s)$/;function _y(e){let t=String(e[0]??``).replace(/\s+$/,``);return t===`—-`?`---`:t}const vy=f_.extend({name:`thematicBreak`,priority:60,addAttributes(){return{...this.parent?.(),sourceRaw:{default:`---`}}},addInputRules(){return[yp({find:gy,type:this.type,getAttributes:e=>({sourceRaw:_y(e)})})]}}),yy=Q_.extend({priority:60,addAttributes(){return{...this.parent?.(),sourceForm:{default:`u`,rendered:!1}}}});function by(e){if(typeof e!=`string`)return null;let t=e.trim();return t.length>0?t:null}function xy(e){return e.alias?e.alias:e.anchor?`${e.target}#${e.anchor}`:e.target}const Sy=Fp.create({name:`wikiLink`,marks:`_`,group:`inline`,inline:!0,atom:!0,priority:60,addAttributes(){return{target:{default:``},alias:{default:null},anchor:{default:null},resolved:{default:!1},sourceTarget:{default:null,rendered:!1},sourceAnchor:{default:null,rendered:!1},sourceAlias:{default:null,rendered:!1}}},parseHTML(){return[{tag:`span[data-wiki-link]`,getAttrs:e=>typeof e==`string`?!1:{target:e.getAttribute(`data-target`)||``,alias:by(e.getAttribute(`data-alias`)),anchor:by(e.getAttribute(`data-anchor`)),resolved:e.getAttribute(`data-resolved`)===`true`}},{tag:`a.wiki-link[data-target]`,priority:100,getAttrs:e=>{if(typeof e==`string`)return!1;let t=e.getAttribute(`data-target`)??``;return t?{target:t,alias:by(e.getAttribute(`data-alias`)),anchor:by(e.getAttribute(`data-anchor`)),resolved:!1}:!1}}]},renderHTML({node:e,HTMLAttributes:t}){let n=String(e.attrs.target??``),r=by(e.attrs.alias),i=by(e.attrs.anchor),a=e.attrs.resolved===!0;return[`span`,{...t,"data-wiki-link":``,"data-target":n,"data-alias":r??``,"data-anchor":i??``,"data-resolved":a?`true`:`false`},xy({target:n,alias:r,anchor:i})]}});function Cy(e){let t=e.split(`/`).pop()??e,n=t.lastIndexOf(`.`);return n<=0||n===t.length-1?``:t.slice(n+1).toLowerCase()}function wy(e){return e.alias?e.alias:e.anchor?`${e.target}#${e.anchor}`:e.target}const Ty=[vm,Jm,ym,qm,Sy,Fp.create({name:`wikiLinkEmbed`,group:`inline`,inline:!0,atom:!0,priority:60,addAttributes(){return{target:{default:``},alias:{default:null},anchor:{default:null},resolvedSrc:{default:null,rendered:!1,parseHTML:()=>null}}},parseHTML(){let e=e=>typeof e==`string`||!e.hasAttribute(`data-wiki-embed`)?!1:{target:e.getAttribute(`data-target`)||``,alias:by(e.getAttribute(`data-alias`)),anchor:by(e.getAttribute(`data-anchor`))};return[{tag:`img[data-wiki-embed]`,getAttrs:e,priority:100},{tag:`a[data-wiki-embed]`,getAttrs:e,priority:100}]},renderHTML({node:e,HTMLAttributes:t}){let n=String(e.attrs.target??``),r=by(e.attrs.alias),i=by(e.attrs.anchor),a=by(e.attrs.resolvedSrc),o=Cy(n);if(p.has(o))return[`img`,{...t,"data-wiki-embed":``,"data-target":n,"data-alias":r??``,"data-anchor":i??``,src:a??n,alt:r??n}];let s=a??n;return[`a`,{...t,"data-wiki-embed":``,"data-target":n,"data-alias":r??``,"data-anchor":i??``,href:i?`${s}#${i}`:s,target:`_blank`,rel:`noopener noreferrer`},wy({target:n,alias:r,anchor:i})]}}),hy,Gm,Km,em,tm,dy,yy,Wv,Vp,Uv,fm,vy,Lm,pm,Rm,um,nm,qv,cy,Hv.configure({undoRedo:!1,bulletList:!1,orderedList:!1,listItem:!1,listKeymap:{listTypes:[{itemName:`listItem`,wrapperNames:[`list`]}]},italic:!1,bold:!1,strike:!1,underline:!1,code:!1,codeBlock:!1,heading:!1,horizontalRule:!1,hardBreak:!1,link:!1,blockquote:!1,dropcursor:{color:`color-mix(in oklch, var(--primary) 50%, transparent)`,width:2}}),ty,fy.configure({resizable:!0}),Ug,my,py,_m.configure({inline:!0}),Jv,Zm,Kv,Gv,im,rm];function Ey(e,t){switch(e){case`darwin`:return[`/opt/homebrew/bin`,`/usr/local/bin`,`/opt/local/bin`,`${t}/.local/bin`,`${t}/.asdf/shims`,`${t}/.local/share/mise/shims`];case`win32`:return[];default:return[`/usr/local/bin`,`/home/linuxbrew/.linuxbrew/bin`,`${t}/.local/bin`,`${t}/.asdf/shims`,`${t}/.local/share/mise/shims`]}}function Dy(e,t,n){let r=n.delimiter,i=(e??``).split(r).filter(e=>e.length>0),a=new Set(i),o=[];for(let e of t)!a.has(e)&&n.isDir(e)&&(a.add(e),o.push(e));return[...i,...o].join(r)}function Oy(e,t){return Dy(e,Ey(t.platform,t.homeDir),t)}function ky(e,t){switch(e){case`darwin`:return[`${t}/Library/pnpm`,`${t}/.bun/bin`,`${t}/.volta/bin`,`${t}/.yarn/bin`,`${t}/.npm-global/bin`];case`win32`:return[];default:return[`${t}/.local/share/pnpm`,`${t}/.bun/bin`,`${t}/.volta/bin`,`${t}/.yarn/bin`,`${t}/.npm-global/bin`]}}function Ay(e,t){return Dy(e,[...Ey(t.platform,t.homeDir),...ky(t.platform,t.homeDir)],t)}function jy(e){return`'${e.replace(/'/g,`'\\''`)}'`}`${Nt}`,[`delete`,`move`,`share_link`,`install`,`import`].map(e=>`mcp__${Nt}__${e}`),`${jy(`mcp_servers.${Nt}.default_tools_approval_mode="approve"`)}`,3072-My("This is an OpenKnowledge project: load the `open-knowledge` skill and use the OpenKnowledge MCP tools for all markdown — don't probe for `.ok/` or use native file tools on `.md` / `.mdx`. ",`cursor`),new TextEncoder;function My(e,t){let n=encodeURIComponent(e);return t===`cursor`?encodeURIComponent(n).length:n.length}function Ny(e){if(e.length===0)return{ok:!1,reason:`docName must not be empty`};if(e.trim().length===0)return{ok:!1,reason:`docName must not be blank (whitespace only)`};if(e!==e.trim())return{ok:!1,reason:`docName must not have leading or trailing whitespace`};for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n<32||n===127)return{ok:!1,reason:`docName must not contain control characters`}}if(e.includes(`..`)||e.startsWith(`/`)||e.includes(`\\`))return{ok:!1,reason:`docName must not contain "..", a leading "/", or a backslash`};for(let t of e.split(`/`)){if(t.length===0)return{ok:!1,reason:`docName must not contain empty path segments (no leading, trailing, or doubled "/")`};if(t.startsWith(`.`))return{ok:!1,reason:`docName path segments must not start with "." (hidden files are not addressable)`}}return{ok:!0}}const Py=new Set([`opencode.json`]);function Fy(e){return e.split(`/`).some(e=>e.startsWith(`.`))?!0:Py.has(e.slice(e.lastIndexOf(`/`)+1))}function Iy(e,t){let n=Ny(e);n.ok||t.addIssue({code:`custom`,message:n.reason})}const Ly=x().superRefine(Iy).optional(),Ry=x().superRefine(Iy),zy={agentId:x().optional(),agentName:x().optional(),colorSeed:x().optional(),clientName:x().optional(),clientVersion:x().optional(),label:x().optional()},By=x().optional(),Vy=/^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i,Hy=S(`kind`,[y({kind:v(`doc`),docPath:x().min(1)}).loose(),y({kind:v(`folder`),folderPath:x()}).loose()]),Uy=f([`no-remote`,`detached-head`,`branch-not-on-origin`,`non-github-remote`,`invalid-path`]),Wy=f([`current`,`stale`,`absent`,`empty`]),Gy=S(`ok`,[y({ok:v(!0),shareUrl:x().min(1),sharedUrl:x().min(1),branch:x().min(1),freshness:Wy.optional().catch(void 0)}).loose(),y({ok:v(!1),error:Uy,branch:x().min(1).optional()}).loose()]),Ky=f([`user`,`org`]),qy=y({login:x().min(1),kind:Ky,avatarUrl:x().optional()}).loose(),Jy=f([`auth-required`,`network`]),Yy=S(`ok`,[y({ok:v(!0),owners:k(qy)}).loose(),y({ok:v(!1),error:Jy}).loose()]),Xy=S(`ok`,[y({ok:v(!0),available:D()}).loose(),y({ok:v(!1),error:Jy}).loose()]),Zy=f([`public`,`private`]),Qy=y({owner:x().min(1),name:x().min(1),visibility:Zy,description:x().optional()}).loose(),$y=f([`name-conflict`,`saml-sso`,`auth-required`,`push-failed`,`init-failed`,`network`,`no-project`]),eb=S(`ok`,[y({ok:v(!0),ownerLogin:x().min(1),repoName:x().min(1),cloneUrl:x().min(1),defaultBranch:x().min(1)}).loose(),y({ok:v(!1),error:$y}).loose()]);function tb(e){return!(typeof e!=`string`||e.length===0||e.startsWith(`-`)||/[\x00-\x1F\x7F]/.test(e)||/\s/.test(e)||e.includes(`:`)||e.split(`/`).includes(`..`))}const nb=e=>e.refine(tb,`invalid branch name`);function rb(e){if(e==null)return!1;let t=e instanceof Error?e.message:String(e);return/couldn'?t find remote ref|Remote branch .+ not found/i.test(t)}const ib=[/could not read (username|password)/i,/terminal prompts disabled/i],ab=[/insufficient scopes/i,/missing.*scope/i,/required scope/i],ob=[/permission denied.*\(publickey\)/i,/host key verification failed/i],sb=[/\b(401|403)\b/,/authentication failed/i,/authorization failed/i,/invalid credentials/i,/credential helper/i,/bad credentials/i,/token.*expired/i,/expired.*token/i,/fatal:.*repository.*not found/i];function cb(e){if(typeof e!=`object`||!e)return``;let t=e.git;return t==null?``:String(t)}function lb(e){if(e==null)return{kind:`non-auth`};let t=`${e instanceof Error?e.message:String(e)}\n${cb(e)}`;return ib.some(e=>e.test(t))?{kind:`auth`,subclass:`no-credential`}:ab.some(e=>e.test(t))?{kind:`auth`,subclass:`scope-mismatch`}:ob.some(e=>e.test(t))?{kind:`auth`,subclass:`ssh-auth`}:sb.some(e=>e.test(t))?/\b401\b/.test(t)||/token.*expired/i.test(t)?{kind:`auth`,subclass:`401`}:/\b403\b/.test(t)?{kind:`auth`,subclass:`403`}:{kind:`auth`,subclass:`unknown-auth`}:{kind:`non-auth`}}function ub(e){return e.kind===`auth`?e.subclass===`no-credential`||e.subclass===`401`||e.subclass===`unknown-auth`:!1}const db={shareTargetExists:D(),dirtyConflicts:y({conflicts:D(),files:k(x().min(1))}).loose(),branchIsLocal:D(),shareTargetOnOriginBranch:D().optional()},fb=S(`detached`,[y({detached:v(!1),currentBranch:x().min(1).nullable(),currentHeadSha:i(),...db}).loose(),y({detached:v(!0),currentBranch:i(),currentHeadSha:x().min(1),...db}).loose()]),pb=y({branch:nb(x().min(1)),principalId:x().optional(),fastForward:D().optional()}).loose(),mb=f([`dirty-conflict`,`branch-not-found`,`fetch-failed`,`checkout-failed`,`branch-in-other-worktree`,`ff-diverged`]),hb=S(`ok`,[y({ok:v(!0)}).loose(),y({ok:v(!1),reason:mb,files:k(x().min(1)).optional(),otherWorktreePath:x().min(1).optional()}).loose()]);f([`on-origin`,`renamed`,`deleted`,`never-on-branch`,`changed-locally`,`unknown`]);const gb=y({branch:nb(x().min(1)),path:x(),kind:f([`doc`,`folder`])}).loose(),_b=S(`verdict`,[y({verdict:v(`on-origin`)}).loose(),y({verdict:v(`renamed`),renamedTo:x().min(1)}).loose(),y({verdict:v(`deleted`)}).loose(),y({verdict:v(`never-on-branch`)}).loose(),y({verdict:v(`changed-locally`)}).loose(),y({verdict:v(`unknown`)}).loose()]).catch({verdict:`unknown`}),vb=y({startedAt:x().min(1),httpListenMs:A().nonnegative().optional(),seedWalkMs:A().nonnegative().optional(),indexesMs:A().nonnegative().optional(),readyMs:A().nonnegative().optional(),fileCount:A().nonnegative().optional()}),yb=y({serverInstanceId:x().min(1),currentBranch:x().min(1).optional(),currentDiskAckSVs:E(x().min(1),x().min(1)).optional(),boot:vb.optional()}).loose(),bb=y({id:x().min(1),display_name:x().min(1),display_email:x(),source:f([`git-config`,`synthesized`]),created_at:x().min(1)}).loose(),xb=y({collabUrl:x().nullable(),previewUrl:x().nullable(),port:A(),singleFile:D().default(!1)}).loose(),Sb=f(`urn:ok:error:malformed-upload.urn:ok:error:collision-exhaustion.urn:ok:error:storage-full.urn:ok:error:storage-readonly.urn:ok:error:storage-error.urn:ok:error:no-file-received.urn:ok:error:path-escape.urn:ok:error:method-not-allowed.urn:ok:error:invalid-request.urn:ok:error:payload-too-large.urn:ok:error:request-timeout.urn:ok:error:internal-server-error.urn:ok:error:derived-index-unavailable.urn:ok:error:loopback-required.urn:ok:error:invalid-origin.urn:ok:error:url-not-allowed.urn:ok:error:dir-outside-home.urn:ok:error:concurrent-operation.urn:ok:error:clone-failed.urn:ok:error:clone-timeout.urn:ok:error:server-start-failed.urn:ok:error:reserved-doc-name.urn:ok:error:target-not-found.urn:ok:error:stale-target.urn:ok:error:frontmatter-edit-not-supported.urn:ok:error:invalid-frontmatter-patch.urn:ok:error:frontmatter-malformed.urn:ok:error:no-active-session.urn:ok:error:too-many-agent-sessions.urn:ok:error:disk-divergence.urn:ok:error:doc-not-found.urn:ok:error:doc-already-exists.urn:ok:error:doc-not-open.urn:ok:error:rollback-not-configured.urn:ok:error:doc-not-available.urn:ok:error:backlink-index-not-configured.urn:ok:error:file-rescan-not-configured.urn:ok:error:shadow-not-configured.urn:ok:error:host-not-allowed.urn:ok:error:principal-not-available.urn:ok:error:not-found.urn:ok:error:auth-failed.urn:ok:error:no-project-dir.urn:ok:error:server-open-failed.urn:ok:error:doc-in-conflict.urn:ok:error:no-conflict-tracked.urn:ok:error:sync-not-active.urn:ok:error:project-repo-not-configured.urn:ok:error:seed-prerequisite-missing.urn:ok:error:seed-invalid-root.urn:ok:error:tag-index-not-configured.urn:ok:error:template-not-found.urn:ok:error:unsupported-asset-type.urn:ok:error:asset-not-found.urn:ok:error:single-file-mode.urn:ok:error:collab-server-not-running.urn:ok:error:gateway-timeout.urn:ok:error:cursor-not-installed.urn:ok:error:cursor-spawn-timeout.urn:ok:error:cursor-spawn-failed.urn:ok:error:handoff-target-not-installed.urn:ok:error:handoff-spawn-timeout.urn:ok:error:handoff-spawn-failed.urn:ok:error:registry-unreachable.urn:ok:error:config-not-writable.urn:ok:error:audit-superseded`.split(`.`));function Cb(e){throw Error(`Unexpected ProblemType variant: ${JSON.stringify(e)}`)}const wb=y({type:Sb,title:x().min(1),status:A().int().min(400).max(599),instance:x().regex(Vy,`instance must be urn:uuid:<uuid>`).optional(),detail:x().optional()}).loose(),Tb=y({parentDocName:x().min(1),placement:f([`configured-attachments`,`parent-dir`]).default(`configured-attachments`),agentId:x().min(1).optional(),agentName:x().min(1).optional()}).loose(),Eb=y({src:x().min(1),path:x().min(1).optional(),deduped:D().optional()}).loose(),Db=y({url:x().min(1),dir:x().min(1),branch:x().min(1).refine(tb,`invalid branch name`).optional()}).loose(),Ob=y({type:v(`error`),problem:wb}).loose();function kb(e,t,n=3){let r=RegExp(`^ {0,3}(\\${e}+)[ \\t]*$`),i=Math.max(3,n);for(let e of t.split(`
147
+ `):``,markdownTokenizer:{name:`taskList`,level:`block`,start(e){let t=e.match(/^\s*[-+*]\s+\[([ xX])\]\s+/)?.index;return t===void 0?-1:t},tokenize(e,t,n){let r=e=>{let t=Mp(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:e[3].toLowerCase()===`x`}),createToken:(e,t)=>({type:`taskItem`,raw:``,mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);return t?[{type:`taskList`,raw:t.raw,items:t.items}]:n.blockTokens(e)},i=Mp(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:e[3].toLowerCase()===`x`}),createToken:(e,t)=>({type:`taskItem`,raw:``,mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);if(i)return{type:`taskList`,raw:i.raw,items:i.items}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleTaskList:()=>({commands:e})=>e.toggleList(this.name,this.options.itemTypeName)}},addKeyboardShortcuts(){return{"Mod-Shift-9":()=>this.editor.commands.toggleTaskList()}}});op.create({name:`listKit`,addExtensions(){let e=[];return this.options.bulletList!==!1&&e.push(v_.configure(this.options.bulletList)),this.options.listItem!==!1&&e.push(y_.configure(this.options.listItem)),this.options.listKeymap!==!1&&e.push(A_.configure(this.options.listKeymap)),this.options.orderedList!==!1&&e.push(z_.configure(this.options.orderedList)),this.options.taskItem!==!1&&e.push(V_.configure(this.options.taskItem)),this.options.taskList!==!1&&e.push(H_.configure(this.options.taskList)),e}});var U_=`&nbsp;`,W_=`\xA0`,G_=Fp.create({name:`paragraph`,priority:1e3,addOptions(){return{HTMLAttributes:{}}},group:`block`,content:`inline*`,parseHTML(){return[{tag:`p`}]},renderHTML({HTMLAttributes:e}){return[`p`,Vd(this.options.HTMLAttributes,e),0]},parseMarkdown:(e,t)=>{let n=e.tokens||[];if(n.length===1&&n[0].type===`image`)return t.parseChildren([n[0]]);let r=t.parseInline(n);return n.length===1&&n[0].type===`text`&&(n[0].raw===U_||n[0].text===U_||n[0].raw===W_||n[0].text===W_)&&r.length===1&&r[0].type===`text`&&(r[0].text===U_||r[0].text===W_)?t.createNode(`paragraph`,void 0,[]):t.createNode(`paragraph`,void 0,r)},renderMarkdown:(e,t,n)=>{if(!e)return``;let r=Array.isArray(e.content)?e.content:[];if(r.length===0){let e=Array.isArray(n?.previousNode?.content)?n.previousNode.content:[];return n?.previousNode?.type===`paragraph`&&e.length===0?U_:``}return t.renderChildren(r)},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),K_=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/,q_=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g,J_=Zf.create({name:`strike`,addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:`s`},{tag:`del`},{tag:`strike`},{style:`text-decoration`,consuming:!1,getAttrs:e=>e.includes(`line-through`)?{}:!1}]},renderHTML({HTMLAttributes:e}){return[`s`,Vd(this.options.HTMLAttributes,e),0]},markdownTokenName:`del`,parseMarkdown:(e,t)=>t.applyMark(`strike`,t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>`~~${t.renderChildren(e)}~~`,addCommands(){return{setStrike:()=>({commands:e})=>e.setMark(this.name),toggleStrike:()=>({commands:e})=>e.toggleMark(this.name),unsetStrike:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-s":()=>this.editor.commands.toggleStrike()}},addInputRules(){return[vp({find:K_,type:this.type})]},addPasteRules(){return[Ip({find:q_,type:this.type})]}}),Y_=J_,X_=Fp.create({name:`text`,group:`inline`,parseMarkdown:e=>({type:`text`,text:e.text||``}),renderMarkdown:e=>e.text||``}),Z_=Zf.create({name:`underline`,addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:`u`},{style:`text-decoration`,consuming:!1,getAttrs:e=>e.includes(`underline`)?{}:!1}]},renderHTML({HTMLAttributes:e}){return[`u`,Vd(this.options.HTMLAttributes,e),0]},parseMarkdown(e,t){return t.applyMark(this.name||`underline`,t.parseInline(e.tokens||[]))},renderMarkdown(e,t){return`++${t.renderChildren(e)}++`},markdownTokenizer:{name:`underline`,level:`inline`,start(e){return e.indexOf(`++`)},tokenize(e,t,n){let r=/^(\+\+)([\s\S]+?)(\+\+)/.exec(e);if(!r)return;let i=r[2].trim();return{type:`underline`,raw:r[0],text:i,tokens:n.inlineTokens(i)}}},addCommands(){return{setUnderline:()=>({commands:e})=>e.setMark(this.name),toggleUnderline:()=>({commands:e})=>e.toggleMark(this.name),unsetUnderline:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-u":()=>this.editor.commands.toggleUnderline(),"Mod-U":()=>this.editor.commands.toggleUnderline()}}}),Q_=Z_;function $_(e={}){return new Ii({view(t){return new ev(t,e)}})}var ev=class{constructor(e,t){this.editorView=e,this.cursorPos=null,this.element=null,this.timeout=-1,this.lastDragEvent=null,this.width=t.width??1,this.color=t.color===!1?void 0:t.color||`black`,this.class=t.class,this.handlers=[`dragover`,`dragend`,`drop`,`dragleave`].map(t=>{let n=e=>{this[t](e)};return e.dom.addEventListener(t,n),{name:t,handler:n}})}destroy(){this.handlers.forEach(({name:e,handler:t})=>this.editorView.dom.removeEventListener(e,t))}update(e,t){if(this.cursorPos!=null&&t.doc!=e.state.doc)if(this.lastDragEvent){let e=this.computeTarget(this.lastDragEvent);e==this.cursorPos?this.updateOverlay():this.setCursor(e)}else this.updateOverlay()}setCursor(e){e!=this.cursorPos&&(this.cursorPos=e,e==null?(this.element.parentNode.removeChild(this.element),this.element=null):this.updateOverlay())}updateOverlay(){let e=this.editorView.state.doc.resolve(this.cursorPos),t=!e.parent.inlineContent,n,r=this.editorView.dom,i=r.getBoundingClientRect(),a=i.width/r.offsetWidth,o=i.height/r.offsetHeight;if(t){let t=e.nodeBefore,r=e.nodeAfter;if(t||r){let e=this.editorView.nodeDOM(this.cursorPos-(t?t.nodeSize:0));if(e){let i=e.getBoundingClientRect(),a=t?i.bottom:i.top;t&&r&&(a=(a+this.editorView.nodeDOM(this.cursorPos).getBoundingClientRect().top)/2);let s=this.width/2*o;n={left:i.left,right:i.right,top:a-s,bottom:a+s}}}}if(!n){let e=this.editorView.coordsAtPos(this.cursorPos),t=this.width/2*a;n={left:e.left-t,right:e.left+t,top:e.top,bottom:e.bottom}}let s=this.editorView.dom.offsetParent;this.element||(this.element=s.appendChild(document.createElement(`div`)),this.class&&(this.element.className=this.class),this.element.style.cssText=`position: absolute; z-index: 50; pointer-events: none;`,this.color&&(this.element.style.backgroundColor=this.color)),this.element.classList.toggle(`prosemirror-dropcursor-block`,t),this.element.classList.toggle(`prosemirror-dropcursor-inline`,!t);let c,l;if(!s||s==document.body&&getComputedStyle(s).position==`static`)c=-pageXOffset,l=-pageYOffset;else{let e=s.getBoundingClientRect(),t=e.width/s.offsetWidth,n=e.height/s.offsetHeight;c=e.left-s.scrollLeft*t,l=e.top-s.scrollTop*n}this.element.style.left=(n.left-c)/a+`px`,this.element.style.top=(n.top-l)/o+`px`,this.element.style.width=(n.right-n.left)/a+`px`,this.element.style.height=(n.bottom-n.top)/o+`px`}scheduleRemoval(e){clearTimeout(this.timeout),this.timeout=setTimeout(()=>this.setCursor(null),e)}computeTarget(e){let t=this.editorView.posAtCoords({left:e.clientX,top:e.clientY}),n=t&&t.inside>=0&&this.editorView.state.doc.nodeAt(t.inside),r=n&&n.type.spec.disableDropCursor,i=typeof r==`function`?r(this.editorView,t,e):r;if(!t||i)return null;let a=t.pos;if(this.editorView.dragging&&this.editorView.dragging.slice){let e=ni(this.editorView.state.doc,a,this.editorView.dragging.slice);e!=null&&(a=e)}return a}dragover(e){if(!this.editorView.editable)return;this.lastDragEvent=e;let t=this.computeTarget(e);t!=null&&(this.setCursor(t),this.scheduleRemoval(5e3))}dragend(){this.scheduleRemoval(20)}drop(){this.scheduleRemoval(20)}dragleave(e){this.editorView.dom.contains(e.relatedTarget)||this.setCursor(null)}},tv=class e extends Ci{constructor(e){super(e,e)}map(t,n){let r=t.resolve(n.map(this.head));return e.valid(r)?new e(r):Ci.near(r)}content(){return I.empty}eq(t){return t instanceof e&&t.head==this.head}toJSON(){return{type:`gapcursor`,pos:this.head}}static fromJSON(t,n){if(typeof n.pos!=`number`)throw RangeError(`Invalid input for GapCursor.fromJSON`);return new e(t.resolve(n.pos))}getBookmark(){return new nv(this.anchor)}static valid(e){let t=e.parent;if(t.inlineContent||!iv(e)||!av(e))return!1;let n=t.type.spec.allowGapCursor;if(n!=null)return n;let r=t.contentMatchAt(e.index()).defaultType;return r&&r.isTextblock}static findGapCursorFrom(t,n,r=!1){search:for(;;){if(!r&&e.valid(t))return t;let i=t.pos,a=null;for(let r=t.depth;;r--){let o=t.node(r);if(n>0?t.indexAfter(r)<o.childCount:t.index(r)>0){a=o.child(n>0?t.indexAfter(r):t.index(r)-1);break}else if(r==0)return null;i+=n;let s=t.doc.resolve(i);if(e.valid(s))return s}for(;;){let o=n>0?a.firstChild:a.lastChild;if(!o){if(a.isAtom&&!a.isText&&!R.isSelectable(a)){t=t.doc.resolve(i+a.nodeSize*n),r=!1;continue search}break}a=o,i+=n;let s=t.doc.resolve(i);if(e.valid(s))return s}return null}}};tv.prototype.visible=!1,tv.findFrom=tv.findGapCursorFrom,Ci.jsonID(`gapcursor`,tv);var nv=class e{constructor(e){this.pos=e}map(t){return new e(t.map(this.pos))}resolve(e){let t=e.resolve(this.pos);return tv.valid(t)?new tv(t):Ci.near(t)}};function rv(e){return e.isAtom||e.spec.isolating||e.spec.createGapCursor}function iv(e){for(let t=e.depth;t>=0;t--){let n=e.index(t),r=e.node(t);if(n==0){if(r.type.spec.isolating)return!0;continue}for(let e=r.child(n-1);;e=e.lastChild){if(e.childCount==0&&!e.inlineContent||rv(e.type))return!0;if(e.inlineContent)return!1}}return!0}function av(e){for(let t=e.depth;t>=0;t--){let n=e.indexAfter(t),r=e.node(t);if(n==r.childCount){if(r.type.spec.isolating)return!0;continue}for(let e=r.child(n);;e=e.firstChild){if(e.childCount==0&&!e.inlineContent||rv(e.type))return!0;if(e.inlineContent)return!1}}return!0}function ov(){return new Ii({props:{decorations:dv,createSelectionBetween(e,t,n){return t.pos==n.pos&&tv.valid(n)?new tv(n):null},handleClick:lv,handleKeyDown:sv,handleDOMEvents:{beforeinput:uv}}})}const sv=uu({ArrowLeft:cv(`horiz`,-1),ArrowRight:cv(`horiz`,1),ArrowUp:cv(`vert`,-1),ArrowDown:cv(`vert`,1)});function cv(e,t){let n=e==`vert`?t>0?`down`:`up`:t>0?`right`:`left`;return function(e,r,i){let a=e.selection,o=t>0?a.$to:a.$from,s=a.empty;if(a instanceof L){if(!i.endOfTextblock(n)||o.depth==0)return!1;s=!1,o=e.doc.resolve(t>0?o.after():o.before())}let c=tv.findGapCursorFrom(o,t,s);return c?(r&&r(e.tr.setSelection(new tv(c))),!0):!1}}function lv(e,t,n){if(!e||!e.editable)return!1;let r=e.state.doc.resolve(t);if(!tv.valid(r))return!1;let i=e.posAtCoords({left:n.clientX,top:n.clientY});return i&&i.inside>-1&&R.isSelectable(e.state.doc.nodeAt(i.inside))?!1:(e.dispatch(e.state.tr.setSelection(new tv(r))),!0)}function uv(e,t){if(t.inputType!=`insertCompositionText`||!(e.state.selection instanceof tv))return!1;let{$from:n}=e.state.selection,r=n.parent.contentMatchAt(n.index()).findWrapping(e.state.schema.nodes.text);if(!r)return!1;let i=F.empty;for(let e=r.length-1;e>=0;e--)i=F.from(r[e].createAndFill(null,i));let a=e.state.tr.replace(n.pos,n.pos,new I(i,0,0));return a.setSelection(L.near(a.doc.resolve(n.pos+1))),e.dispatch(a),!1}function dv(e){if(!(e.selection instanceof tv))return null;let t=document.createElement(`div`);return t.className=`ProseMirror-gapcursor`,ll.create(e.doc,[ol.widget(e.selection.head,t,{key:`gapcursor`})])}var fv=200,pv=function(){};pv.prototype.append=function(e){return e.length?(e=pv.from(e),!this.length&&e||e.length<fv&&this.leafAppend(e)||this.length<fv&&e.leafPrepend(this)||this.appendInner(e)):this},pv.prototype.prepend=function(e){return e.length?pv.from(e).append(this):this},pv.prototype.appendInner=function(e){return new hv(this,e)},pv.prototype.slice=function(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.length),e>=t?pv.empty:this.sliceInner(Math.max(0,e),Math.min(this.length,t))},pv.prototype.get=function(e){if(!(e<0||e>=this.length))return this.getInner(e)},pv.prototype.forEach=function(e,t,n){t===void 0&&(t=0),n===void 0&&(n=this.length),t<=n?this.forEachInner(e,t,n,0):this.forEachInvertedInner(e,t,n,0)},pv.prototype.map=function(e,t,n){t===void 0&&(t=0),n===void 0&&(n=this.length);var r=[];return this.forEach(function(t,n){return r.push(e(t,n))},t,n),r},pv.from=function(e){return e instanceof pv?e:e&&e.length?new mv(e):pv.empty};var mv=function(e){function t(t){e.call(this),this.values=t}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(e,n){return e==0&&n==this.length?this:new t(this.values.slice(e,n))},t.prototype.getInner=function(e){return this.values[e]},t.prototype.forEachInner=function(e,t,n,r){for(var i=t;i<n;i++)if(e(this.values[i],r+i)===!1)return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){for(var i=t-1;i>=n;i--)if(e(this.values[i],r+i)===!1)return!1},t.prototype.leafAppend=function(e){if(this.length+e.length<=fv)return new t(this.values.concat(e.flatten()))},t.prototype.leafPrepend=function(e){if(this.length+e.length<=fv)return new t(e.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(t.prototype,n),t}(pv);pv.empty=new mv([]);var hv=function(e){function t(t,n){e.call(this),this.left=t,this.right=n,this.length=t.length+n.length,this.depth=Math.max(t.depth,n.depth)+1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},t.prototype.getInner=function(e){return e<this.left.length?this.left.get(e):this.right.get(e-this.left.length)},t.prototype.forEachInner=function(e,t,n,r){var i=this.left.length;if(t<i&&this.left.forEachInner(e,t,Math.min(n,i),r)===!1||n>i&&this.right.forEachInner(e,Math.max(t-i,0),Math.min(this.length,n)-i,r+i)===!1)return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){var i=this.left.length;if(t>i&&this.right.forEachInvertedInner(e,t-i,Math.max(n,i)-i,r+i)===!1||n<i&&this.left.forEachInvertedInner(e,Math.min(t,i),n,r)===!1)return!1},t.prototype.sliceInner=function(e,t){if(e==0&&t==this.length)return this;var n=this.left.length;return t<=n?this.left.slice(e,t):e>=n?this.right.slice(e-n,t-n):this.left.slice(e,n).append(this.right.slice(0,t-n))},t.prototype.leafAppend=function(e){var n=this.right.leafAppend(e);if(n)return new t(this.left,n)},t.prototype.leafPrepend=function(e){var n=this.left.leafPrepend(e);if(n)return new t(n,this.right)},t.prototype.appendInner=function(e){return this.left.depth>=Math.max(this.right.depth,e.depth)+1?new t(this.left,new t(this.right,e)):new t(this,e)},t}(pv),gv=class e{constructor(e,t){this.items=e,this.eventCount=t}popEvent(t,n){if(this.eventCount==0)return null;let r=this.items.length;for(;;r--)if(this.items.get(r-1).selection){--r;break}let i,a;n&&(i=this.remapping(r,this.items.length),a=i.maps.length);let o=t.tr,s,c,l=[],u=[];return this.items.forEach((t,n)=>{if(!t.step){i||(i=this.remapping(r,n+1),a=i.maps.length),a--,u.push(t);return}if(i){u.push(new vv(t.map));let e=t.step.map(i.slice(a)),n;e&&o.maybeStep(e).doc&&(n=o.mapping.maps[o.mapping.maps.length-1],l.push(new vv(n,void 0,void 0,l.length+u.length))),a--,n&&i.appendMap(n,a)}else o.maybeStep(t.step);if(t.selection)return s=i?t.selection.map(i.slice(a)):t.selection,c=new e(this.items.slice(0,r).append(u.reverse().concat(l)),this.eventCount-1),!1},this.items.length,0),{remaining:c,transform:o,selection:s}}addTransform(t,n,r,i){let a=[],o=this.eventCount,s=this.items,c=!i&&s.length?s.get(s.length-1):null;for(let e=0;e<t.steps.length;e++){let r=t.steps[e].invert(t.docs[e]),l=new vv(t.mapping.maps[e],r,n),u;(u=c&&c.merge(l))&&(l=u,e?a.pop():s=s.slice(0,s.length-1)),a.push(l),n&&=(o++,void 0),i||(c=l)}let l=o-r.depth;return l>bv&&(s=_v(s,l),o-=l),new e(s.append(a),o)}remapping(e,t){let n=new br;return this.items.forEach((t,r)=>{let i=t.mirrorOffset!=null&&r-t.mirrorOffset>=e?n.maps.length-t.mirrorOffset:void 0;n.appendMap(t.map,i)},e,t),n}addMaps(t){return this.eventCount==0?this:new e(this.items.append(t.map(e=>new vv(e))),this.eventCount)}rebased(t,n){if(!this.eventCount)return this;let r=[],i=Math.max(0,this.items.length-n),a=t.mapping,o=t.steps.length,s=this.eventCount;this.items.forEach(e=>{e.selection&&s--},i);let c=n;this.items.forEach(e=>{let n=a.getMirror(--c);if(n==null)return;o=Math.min(o,n);let i=a.maps[n];if(e.step){let o=t.steps[n].invert(t.docs[n]),l=e.selection&&e.selection.map(a.slice(c+1,n));l&&s++,r.push(new vv(i,o,l))}else r.push(new vv(i))},i);let l=[];for(let e=n;e<o;e++)l.push(new vv(a.maps[e]));let u=new e(this.items.slice(0,i).append(l).append(r),s);return u.emptyItemCount()>500&&(u=u.compress(this.items.length-r.length)),u}emptyItemCount(){let e=0;return this.items.forEach(t=>{t.step||e++}),e}compress(t=this.items.length){let n=this.remapping(0,t),r=n.maps.length,i=[],a=0;return this.items.forEach((e,o)=>{if(o>=t)i.push(e),e.selection&&a++;else if(e.step){let t=e.step.map(n.slice(r)),o=t&&t.getMap();if(r--,o&&n.appendMap(o,r),t){let s=e.selection&&e.selection.map(n.slice(r));s&&a++;let c=new vv(o.invert(),t,s),l,u=i.length-1;(l=i.length&&i[u].merge(c))?i[u]=l:i.push(c)}}else e.map&&r--},this.items.length,0),new e(pv.from(i.reverse()),a)}};gv.empty=new gv(pv.empty,0);function _v(e,t){let n;return e.forEach((e,r)=>{if(e.selection&&t--==0)return n=r,!1}),e.slice(n)}var vv=class e{constructor(e,t,n,r){this.map=e,this.step=t,this.selection=n,this.mirrorOffset=r}merge(t){if(this.step&&t.step&&!t.selection){let n=t.step.merge(this.step);if(n)return new e(n.getMap().invert(),n,this.selection)}}},yv=class{constructor(e,t,n,r,i){this.done=e,this.undone=t,this.prevRanges=n,this.prevTime=r,this.prevComposition=i}};const bv=20;function xv(e,t,n,r){let i=n.getMeta(kv),a;if(i)return i.historyState;n.getMeta(Av)&&(e=new yv(e.done,e.undone,null,0,-1));let o=n.getMeta(`appendedTransaction`);if(n.steps.length==0)return e;if(o&&o.getMeta(kv))return o.getMeta(kv).redo?new yv(e.done.addTransform(n,void 0,r,Ov(t)),e.undone,Cv(n.mapping.maps),e.prevTime,e.prevComposition):new yv(e.done,e.undone.addTransform(n,void 0,r,Ov(t)),null,e.prevTime,e.prevComposition);if(n.getMeta(`addToHistory`)!==!1&&!(o&&o.getMeta(`addToHistory`)===!1)){let i=n.getMeta(`composition`),a=e.prevTime==0||!o&&e.prevComposition!=i&&(e.prevTime<(n.time||0)-r.newGroupDelay||!Sv(n,e.prevRanges)),s=o?wv(e.prevRanges,n.mapping):Cv(n.mapping.maps);return new yv(e.done.addTransform(n,a?t.selection.getBookmark():void 0,r,Ov(t)),gv.empty,s,n.time,i??e.prevComposition)}else if(a=n.getMeta(`rebased`))return new yv(e.done.rebased(n,a),e.undone.rebased(n,a),wv(e.prevRanges,n.mapping),e.prevTime,e.prevComposition);else return new yv(e.done.addMaps(n.mapping.maps),e.undone.addMaps(n.mapping.maps),wv(e.prevRanges,n.mapping),e.prevTime,e.prevComposition)}function Sv(e,t){if(!t)return!1;if(!e.docChanged)return!0;let n=!1;return e.mapping.maps[0].forEach((e,r)=>{for(let i=0;i<t.length;i+=2)e<=t[i+1]&&r>=t[i]&&(n=!0)}),n}function Cv(e){let t=[];for(let n=e.length-1;n>=0&&t.length==0;n--)e[n].forEach((e,n,r,i)=>t.push(r,i));return t}function wv(e,t){if(!e)return null;let n=[];for(let r=0;r<e.length;r+=2){let i=t.map(e[r],1),a=t.map(e[r+1],-1);i<=a&&n.push(i,a)}return n}function Tv(e,t,n){let r=Ov(t),i=kv.get(t).spec.config,a=(n?e.undone:e.done).popEvent(t,r);if(!a)return null;let o=a.selection.resolve(a.transform.doc),s=(n?e.done:e.undone).addTransform(a.transform,t.selection.getBookmark(),i,r),c=new yv(n?s:a.remaining,n?a.remaining:s,null,0,-1);return a.transform.setSelection(o).setMeta(kv,{redo:n,historyState:c})}let Ev=!1,Dv=null;function Ov(e){let t=e.plugins;if(Dv!=t){Ev=!1,Dv=t;for(let e=0;e<t.length;e++)if(t[e].spec.historyPreserveItems){Ev=!0;break}}return Ev}const kv=new zi(`history`),Av=new zi(`closeHistory`);function jv(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new Ii({key:kv,state:{init(){return new yv(gv.empty,gv.empty,null,0,-1)},apply(t,n,r){return xv(n,r,t,e)}},config:e,props:{handleDOMEvents:{beforeinput(e,t){let n=t.inputType,r=n==`historyUndo`?Nv:n==`historyRedo`?Pv:null;return!r||!e.editable?!1:(t.preventDefault(),r(e.state,e.dispatch))}}}})}function Mv(e,t){return(n,r)=>{let i=kv.getState(n);if(!i||(e?i.undone:i.done).eventCount==0)return!1;if(r){let a=Tv(i,n,e);a&&r(t?a.scrollIntoView():a)}return!0}}const Nv=Mv(!1,!0),Pv=Mv(!0,!0);op.create({name:`characterCount`,addOptions(){return{limit:null,mode:`textSize`,textCounter:e=>e.length,wordCounter:e=>e.split(` `).filter(e=>e!==``).length}},addStorage(){return{characters:()=>0,words:()=>0}},onBeforeCreate(){this.storage.characters=e=>{let t=e?.node||this.editor.state.doc;if((e?.mode||this.options.mode)===`textSize`){let e=t.textBetween(0,t.content.size,void 0,` `);return this.options.textCounter(e)}return t.nodeSize},this.storage.words=e=>{let t=e?.node||this.editor.state.doc,n=t.textBetween(0,t.content.size,` `,` `);return this.options.wordCounter(n)}},addProseMirrorPlugins(){let e=!1;return[new Ii({key:new zi(`characterCount`),appendTransaction:(t,n,r)=>{if(e)return;let i=this.options.limit;if(i==null||i===0){e=!0;return}let a=this.storage.characters({node:r.doc});if(a>i){let t=a-i;console.warn(`[CharacterCount] Initial content exceeded limit of ${i} characters. Content was automatically trimmed.`);let n=r.tr.deleteRange(0,t);return e=!0,n}e=!0},filterTransaction:(e,t)=>{let n=this.options.limit;if(!e.docChanged||n===0||n==null)return!0;let r=this.storage.characters({node:t.doc}),i=this.storage.characters({node:e.doc});if(i<=n||r>n&&i>n&&i<=r)return!0;if(r>n&&i>n&&i>r||!e.getMeta(`paste`))return!1;let a=e.selection.$head.pos,o=a-(i-n),s=a;return e.deleteRange(o,s),!(this.storage.characters({node:e.doc})>n)}})]}});var Fv=op.create({name:`dropCursor`,addOptions(){return{color:`currentColor`,width:1,class:void 0}},addProseMirrorPlugins(){return[$_(this.options)]}});op.create({name:`focus`,addOptions(){return{className:`has-focus`,mode:`all`}},addProseMirrorPlugins(){return[new Ii({key:new zi(`focus`),props:{decorations:({doc:e,selection:t})=>{let{isEditable:n,isFocused:r}=this.editor,{anchor:i}=t,a=[];if(!n||!r)return ll.create(e,[]);let o=0;this.options.mode===`deepest`&&e.descendants((e,t)=>{if(!e.isText){if(!(i>=t&&i<=t+e.nodeSize-1))return!1;o+=1}});let s=0;return e.descendants((e,t)=>{if(e.isText||!(i>=t&&i<=t+e.nodeSize-1))return!1;if(s+=1,this.options.mode===`deepest`&&o-s>0||this.options.mode===`shallowest`&&s>1)return this.options.mode===`deepest`;a.push(ol.node(t,t+e.nodeSize,{class:this.options.className}))}),ll.create(e,a)}}})]}});var Iv=op.create({name:`gapCursor`,addProseMirrorPlugins(){return[ov()]},extendNodeSchema(e){return{allowGapCursor:Fd(z(e,`allowGapCursor`,{name:e.name,options:e.options,storage:e.storage}))??null}}}),Lv=`placeholder`;function Rv(e){return e.replace(/\s+/g,`-`).replace(/[^a-zA-Z0-9-]/g,``).replace(/^[0-9-]+/,``).replace(/^-+/,``).toLowerCase()}op.create({name:`placeholder`,addOptions(){return{emptyEditorClass:`is-editor-empty`,emptyNodeClass:`is-empty`,dataAttribute:Lv,placeholder:`Write something …`,showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}},addProseMirrorPlugins(){let e=this.options.dataAttribute?`data-${Rv(this.options.dataAttribute)}`:`data-${Lv}`;return[new Ii({key:new zi(`placeholder`),props:{decorations:({doc:t,selection:n})=>{let r=this.editor.isEditable||!this.options.showOnlyWhenEditable,{anchor:i}=n,a=[];if(!r)return null;let o=this.editor.isEmpty;return t.descendants((t,n)=>{let r=i>=n&&i<=n+t.nodeSize,s=!t.isLeaf&&gf(t);if(!t.type.isTextblock)return this.options.includeChildren;if((r||!this.options.showOnlyCurrent)&&s){let i=[this.options.emptyNodeClass];o&&i.push(this.options.emptyEditorClass);let s=ol.node(n,n+t.nodeSize,{class:i.join(` `),[e]:typeof this.options.placeholder==`function`?this.options.placeholder({editor:this.editor,node:t,pos:n,hasAnchor:r}):this.options.placeholder});a.push(s)}return this.options.includeChildren}),ll.create(t,a)}}})]}}),op.create({name:`selection`,addOptions(){return{className:`selection`}},addProseMirrorPlugins(){let{editor:e,options:t}=this;return[new Ii({key:new zi(`selection`),props:{decorations(n){return n.selection.empty||e.isFocused||!e.isEditable||_f(n.selection)||e.view.dragging?null:ll.create(n.doc,[ol.inline(n.selection.from,n.selection.to,{class:t.className})])}}})]}});function zv({types:e,node:t}){return t&&Array.isArray(e)&&e.includes(t.type)||t?.type===e}var Bv=op.create({name:`trailingNode`,addOptions(){return{node:void 0,notAfter:[]}},addProseMirrorPlugins(){let e=new zi(this.name),t=this.options.node||this.editor.schema.topNodeType.contentMatch.defaultType?.name||`paragraph`,n=Object.entries(this.editor.schema.nodes).map(([,e])=>e).filter(e=>(this.options.notAfter||[]).concat(t).includes(e.name));return[new Ii({key:e,appendTransaction:(n,r,i)=>{let{doc:a,tr:o,schema:s}=i,c=e.getState(i),l=a.content.size,u=s.nodes[t];if(!n.some(e=>e.getMeta(`skipTrailingNode`))&&c)return o.insert(l,u.create())},state:{init:(e,t)=>{let r=t.tr.doc.lastChild;return!zv({node:r,types:n})},apply:(e,t)=>{if(!e.docChanged||e.getMeta(`__uniqueIDTransaction`))return t;let r=e.doc.lastChild;return!zv({node:r,types:n})}}})]}}),Vv=op.create({name:`undoRedo`,addOptions(){return{depth:100,newGroupDelay:500}},addCommands(){return{undo:()=>({state:e,dispatch:t})=>Nv(e,t),redo:()=>({state:e,dispatch:t})=>Pv(e,t)}},addProseMirrorPlugins(){return[jv(this.options)]},addKeyboardShortcuts(){return{"Mod-z":()=>this.editor.commands.undo(),"Shift-Mod-z":()=>this.editor.commands.redo(),"Mod-y":()=>this.editor.commands.redo(),"Mod-я":()=>this.editor.commands.undo(),"Shift-Mod-я":()=>this.editor.commands.redo()}}}),Hv=op.create({name:`starterKit`,addExtensions(){let e=[];return this.options.bold!==!1&&e.push(qp.configure(this.options.bold)),this.options.blockquote!==!1&&e.push(i_.configure(this.options.blockquote)),this.options.bulletList!==!1&&e.push(v_.configure(this.options.bulletList)),this.options.code!==!1&&e.push(c_.configure(this.options.code)),this.options.codeBlock!==!1&&e.push(Bp.configure(this.options.codeBlock)),this.options.document!==!1&&e.push(u_.configure(this.options.document)),this.options.dropcursor!==!1&&e.push(Fv.configure(this.options.dropcursor)),this.options.gapcursor!==!1&&e.push(Iv.configure(this.options.gapcursor)),this.options.hardBreak!==!1&&e.push(lm.configure(this.options.hardBreak)),this.options.heading!==!1&&e.push(dm.configure(this.options.heading)),this.options.undoRedo!==!1&&e.push(Vv.configure(this.options.undoRedo)),this.options.horizontalRule!==!1&&e.push(d_.configure(this.options.horizontalRule)),this.options.italic!==!1&&e.push($p.configure(this.options.italic)),this.options.listItem!==!1&&e.push(y_.configure(this.options.listItem)),this.options.listKeymap!==!1&&e.push(A_.configure(this.options?.listKeymap)),this.options.link!==!1&&e.push(Am.configure(this.options?.link)),this.options.orderedList!==!1&&e.push(z_.configure(this.options.orderedList)),this.options.paragraph!==!1&&e.push(G_.configure(this.options.paragraph)),this.options.strike!==!1&&e.push(J_.configure(this.options.strike)),this.options.text!==!1&&e.push(X_.configure(this.options.text)),this.options.underline!==!1&&e.push(Z_.configure(this.options?.underline)),this.options.trailingNode!==!1&&e.push(Bv.configure(this.options?.trailingNode)),e}});const Uv=a_.extend({priority:60,addAttributes(){return{...this.parent?.(),sourceMarkerSpacings:{default:null}}}}),Wv=l_.extend({excludes:``,addAttributes(){return{...this.parent?.(),sourceFenceChar:{default:"`"},sourceFenceLength:{default:1},sourcePadded:{default:!1,rendered:!1}}}}),Gv=Fp.create({name:`commentBlock`,group:`block`,content:`block+`,defining:!0,priority:60,addAttributes(){return{sourceForm:{default:`percent`,parseHTML:e=>e.getAttribute(`data-source-form`)===`html`?`html`:`percent`,renderHTML:e=>e.sourceForm===`html`?{"data-source-form":`html`}:{}},sourceLayout:{default:`block`,parseHTML:e=>e.getAttribute(`data-source-layout`)===`inline`?`inline`:`block`,renderHTML:e=>e.sourceLayout===`inline`?{"data-source-layout":`inline`}:{}}}},parseHTML(){return[{tag:`aside[data-comment-block]`},{tag:`aside.comment-block`}]},renderHTML({HTMLAttributes:e}){return[`aside`,{"data-comment-block":``,"data-clipboard-omit":`true`,class:`comment-block`,...e},0]},addCommands(){return{setCommentBlock:()=>({commands:e})=>e.wrapIn(this.name),toggleCommentBlock:()=>({commands:e})=>e.toggleWrap(this.name),unsetCommentBlock:()=>({commands:e})=>e.lift(this.name)}}}),Kv=Zf.create({name:`comment`,priority:10,excludes:``,inclusive:!1,addAttributes(){return{sourceForm:{default:`percent`,parseHTML:e=>e.getAttribute(`data-source-form`)===`html`?`html`:`percent`,renderHTML:e=>e.sourceForm===`html`?{"data-source-form":`html`}:{}}}},parseHTML(){return[{tag:`span[data-comment-mark]`}]},renderHTML({HTMLAttributes:e}){return[`span`,{"data-comment-mark":``,"data-clipboard-omit":`true`,class:`comment-mark`,...e},0]},addCommands(){return{setComment:()=>({commands:e})=>e.setMark(this.name),toggleComment:()=>({commands:e})=>e.toggleMark(this.name),unsetComment:()=>({commands:e})=>e.unsetMark(this.name)}}}),qv=op.create({name:`docFidelity`,addGlobalAttributes(){return[{types:[`doc`],attributes:{sourceDocBoundary:{default:null,rendered:!1}}}]}}),Jv=Fp.create({name:`imageReference`,marks:`_`,group:`inline`,inline:!0,atom:!0,priority:60,addAttributes(){return{alt:{default:``},label:{default:``},identifier:{default:``},referenceType:{default:`shortcut`}}},parseHTML(){return[{tag:`img[data-image-reference]`}]},renderHTML({node:e}){let{alt:t,label:n,referenceType:r}=e.attrs;return[`img`,{"data-image-reference":``,"data-reference-type":r,"data-label":n,alt:t||n}]}});function Yv(e){for(let t=e.depth;t>0;t--)if(e.node(t).type.name===`listItem`)return t;return null}function Xv(e){let t=!1;return e.descendants(e=>t?!1:(e.type.name===`list`&&(t=!0),!t)),t}function Zv(e){let{selection:t}=e;return t instanceof L?t.$cursor:null}function Qv(e){let t=Zv(e);if(!t||t.parentOffset!==0)return!1;let n=Yv(t);if(n===null||t.depth!==n+1||t.index(n)!==0)return!1;let r=t.index(n-1);return r===0?!1:Xv(t.node(n-1).child(r-1))}function $v(e,t){for(let n=t-1;n>=0;n--){let t=e.node(n),r=e.index(n);if(r<t.childCount-1){let e=t.child(r+1),i=n+1;for(;e.type.name===`list`&&e.firstChild;)e=e.firstChild,i+=1;return e.type.name===`listItem`?i:null}}return null}function ey(e){let t=Zv(e);if(!t||t.parentOffset!==t.parent.content.size)return!1;let n=Yv(t);if(n===null)return!1;for(let e=t.depth;e>n;e--)if(t.index(e-1)!==t.node(e-1).childCount-1)return!1;let r=$v(t,n);return r!==null&&r<n}const ty=op.create({name:`listBoundaryMerge`,addKeyboardShortcuts(){let e=()=>{let{editor:e}=this;if(!Qv(e.state))return!1;if(e.commands.undoInputRule())return!0;let{state:t,view:n}=e;return Ui(t,n.dispatch,n)},t=()=>{let{editor:e}=this;if(!ey(e.state))return!1;let{state:t,view:n}=e;return Wi(t,n.dispatch,n)};return{Backspace:e,"Mod-Backspace":e,Delete:t,"Mod-Delete":t}}}),ny=new Map([[32,` `],[9,` `],[160,`\xA0`]]);function ry(e){let t=/^&#(x[0-9A-Fa-f]+|X[0-9A-Fa-f]+|[0-9]+);$/.exec(e);if(!t)return null;let n=t[1],r=n[0]===`x`||n[0]===`X`,i=Number.parseInt(r?n.slice(1):n,r?16:10);return Number.isNaN(i)?null:i}function iy(e){let t=ry(e);return t!==null&&ny.has(t)}function ay(e){let t=ry(e);return t===null?null:ny.get(t)??null}const oy=/&#(?:x[0-9A-Fa-f]+|X[0-9A-Fa-f]+|[0-9]+);/g;function sy(e){oy.lastIndex=0;let t=e.match(oy);if(t===null||t.join(``)!==e)return null;let n=``;for(let e of t){let t=ay(e);if(t===null)return null;n+=t}return n}const cy=Zf.create({name:`sourceLiteral`,priority:10,excludes:``,inclusive:!1,addAttributes(){return{sourceRaw:{default:``}}},parseHTML(){return[{tag:`span[data-source-literal]`}]},renderHTML({HTMLAttributes:e}){return[`span`,{"data-source-literal":``,...e},0]}});function ly(e,t){if(typeof e!=`string`||typeof t!=`string`||/[\x00-\x1F\x7F]/.test(e))return!1;let n=e.replaceAll(`\xA0`,` `),r=t.replaceAll(`\xA0`,` `);return n===r||uy(n)===r?!0:sy(e)===t}function uy(e){return e.replace(/\\([!-/:-@[-`{-~])/g,`$1`)}const dy=Y_.extend({priority:60,addAttributes(){return{...this.parent?.(),sourceDelimiter:{default:`~~`,rendered:!1}}}}),fy=n_.extend({priority:60,addAttributes(){return{...this.parent?.(),sourceDashCounts:{default:null},sourceOuterPipes:{default:null,rendered:!1},sourceAlignmentPadding:{default:null,rendered:!1}}}}),py=Vg.extend({priority:60,addAttributes(){return{...this.parent?.(),sourcePadding:{default:null}}}}),my=Hg.extend({priority:60,addAttributes(){return{...this.parent?.(),sourcePadding:{default:null}}}}),hy=Fp.create({name:`tag`,marks:`_`,group:`inline`,inline:!0,atom:!0,selectable:!0,priority:60,addAttributes(){return{value:{default:``}}},parseHTML(){return[{tag:`a[data-tag]`,getAttrs:e=>typeof e==`string`?!1:{value:e.getAttribute(`data-tag`)||``}}]},renderHTML({node:e,HTMLAttributes:t}){let n=String(e.attrs.value??``);return[`a`,{...t,"data-tag":n,href:`#tag/${n}`,class:`tag`},`#${n}`]},addCommands(){return{insertTag:e=>({chain:t})=>t().insertContent({type:`tag`,attrs:{value:e}}).run()}}}),gy=/^(?:---|—-|___\s|\*\*\*\s)$/;function _y(e){let t=String(e[0]??``).replace(/\s+$/,``);return t===`—-`?`---`:t}const vy=f_.extend({name:`thematicBreak`,priority:60,addAttributes(){return{...this.parent?.(),sourceRaw:{default:`---`}}},addInputRules(){return[yp({find:gy,type:this.type,getAttributes:e=>({sourceRaw:_y(e)})})]}}),yy=Q_.extend({priority:60,addAttributes(){return{...this.parent?.(),sourceForm:{default:`u`,rendered:!1}}}});function by(e){if(typeof e!=`string`)return null;let t=e.trim();return t.length>0?t:null}function xy(e){return e.alias?e.alias:e.anchor?`${e.target}#${e.anchor}`:e.target}const Sy=Fp.create({name:`wikiLink`,marks:`_`,group:`inline`,inline:!0,atom:!0,priority:60,addAttributes(){return{target:{default:``},alias:{default:null},anchor:{default:null},resolved:{default:!1},sourceTarget:{default:null,rendered:!1},sourceAnchor:{default:null,rendered:!1},sourceAlias:{default:null,rendered:!1}}},parseHTML(){return[{tag:`span[data-wiki-link]`,getAttrs:e=>typeof e==`string`?!1:{target:e.getAttribute(`data-target`)||``,alias:by(e.getAttribute(`data-alias`)),anchor:by(e.getAttribute(`data-anchor`)),resolved:e.getAttribute(`data-resolved`)===`true`}},{tag:`a.wiki-link[data-target]`,priority:100,getAttrs:e=>{if(typeof e==`string`)return!1;let t=e.getAttribute(`data-target`)??``;return t?{target:t,alias:by(e.getAttribute(`data-alias`)),anchor:by(e.getAttribute(`data-anchor`)),resolved:!1}:!1}}]},renderHTML({node:e,HTMLAttributes:t}){let n=String(e.attrs.target??``),r=by(e.attrs.alias),i=by(e.attrs.anchor),a=e.attrs.resolved===!0;return[`span`,{...t,"data-wiki-link":``,"data-target":n,"data-alias":r??``,"data-anchor":i??``,"data-resolved":a?`true`:`false`},xy({target:n,alias:r,anchor:i})]}});function Cy(e){let t=e.split(`/`).pop()??e,n=t.lastIndexOf(`.`);return n<=0||n===t.length-1?``:t.slice(n+1).toLowerCase()}function wy(e){return e.alias?e.alias:e.anchor?`${e.target}#${e.anchor}`:e.target}const Ty=[vm,Jm,ym,qm,Sy,Fp.create({name:`wikiLinkEmbed`,group:`inline`,inline:!0,atom:!0,priority:60,addAttributes(){return{target:{default:``},alias:{default:null},anchor:{default:null},resolvedSrc:{default:null,rendered:!1,parseHTML:()=>null}}},parseHTML(){let e=e=>typeof e==`string`||!e.hasAttribute(`data-wiki-embed`)?!1:{target:e.getAttribute(`data-target`)||``,alias:by(e.getAttribute(`data-alias`)),anchor:by(e.getAttribute(`data-anchor`))};return[{tag:`img[data-wiki-embed]`,getAttrs:e,priority:100},{tag:`a[data-wiki-embed]`,getAttrs:e,priority:100}]},renderHTML({node:e,HTMLAttributes:t}){let n=String(e.attrs.target??``),r=by(e.attrs.alias),i=by(e.attrs.anchor),a=by(e.attrs.resolvedSrc),o=Cy(n);if(p.has(o))return[`img`,{...t,"data-wiki-embed":``,"data-target":n,"data-alias":r??``,"data-anchor":i??``,src:a??n,alt:r??n}];let s=a??n;return[`a`,{...t,"data-wiki-embed":``,"data-target":n,"data-alias":r??``,"data-anchor":i??``,href:i?`${s}#${i}`:s,target:`_blank`,rel:`noopener noreferrer`},wy({target:n,alias:r,anchor:i})]}}),hy,Gm,Km,em,tm,dy,yy,Wv,Vp,Uv,fm,vy,Lm,pm,Rm,um,nm,qv,cy,Hv.configure({undoRedo:!1,bulletList:!1,orderedList:!1,listItem:!1,listKeymap:{listTypes:[{itemName:`listItem`,wrapperNames:[`list`]}]},italic:!1,bold:!1,strike:!1,underline:!1,code:!1,codeBlock:!1,heading:!1,horizontalRule:!1,hardBreak:!1,link:!1,blockquote:!1,dropcursor:{color:`color-mix(in oklch, var(--primary) 50%, transparent)`,width:2}}),ty,fy.configure({resizable:!0}),Ug,my,py,_m.configure({inline:!0}),Jv,Zm,Kv,Gv,im,rm];function Ey(e,t){switch(e){case`darwin`:return[`/opt/homebrew/bin`,`/usr/local/bin`,`/opt/local/bin`,`${t}/.local/bin`,`${t}/.asdf/shims`,`${t}/.local/share/mise/shims`];case`win32`:return[];default:return[`/usr/local/bin`,`/home/linuxbrew/.linuxbrew/bin`,`${t}/.local/bin`,`${t}/.asdf/shims`,`${t}/.local/share/mise/shims`]}}function Dy(e,t,n){let r=n.delimiter,i=(e??``).split(r).filter(e=>e.length>0),a=new Set(i),o=[];for(let e of t)!a.has(e)&&n.isDir(e)&&(a.add(e),o.push(e));return[...i,...o].join(r)}function Oy(e,t){return Dy(e,Ey(t.platform,t.homeDir),t)}function ky(e,t){switch(e){case`darwin`:return[`${t}/Library/pnpm`,`${t}/.bun/bin`,`${t}/.volta/bin`,`${t}/.yarn/bin`,`${t}/.npm-global/bin`];case`win32`:return[];default:return[`${t}/.local/share/pnpm`,`${t}/.bun/bin`,`${t}/.volta/bin`,`${t}/.yarn/bin`,`${t}/.npm-global/bin`]}}function Ay(e,t){return Dy(e,[...Ey(t.platform,t.homeDir),...ky(t.platform,t.homeDir)],t)}function jy(e){return`'${e.replace(/'/g,`'\\''`)}'`}`${Nt}`,[`delete`,`move`,`share_link`,`install`,`import`].map(e=>`mcp__${Nt}__${e}`),`${jy(`mcp_servers.${Nt}.default_tools_approval_mode="approve"`)}`,3072-My("This is an OpenKnowledge project: load the `open-knowledge` skill and use the OpenKnowledge MCP tools for all markdown — don't probe for `.ok/` or use native file tools on `.md` / `.mdx`. ",`cursor`),new TextEncoder;function My(e,t){let n=encodeURIComponent(e);return t===`cursor`?encodeURIComponent(n).length:n.length}function Ny(e){if(e.length===0)return{ok:!1,reason:`docName must not be empty`};if(e.trim().length===0)return{ok:!1,reason:`docName must not be blank (whitespace only)`};if(e!==e.trim())return{ok:!1,reason:`docName must not have leading or trailing whitespace`};for(let t=0;t<e.length;t++){let n=e.charCodeAt(t);if(n<32||n===127)return{ok:!1,reason:`docName must not contain control characters`}}if(e.includes(`..`)||e.startsWith(`/`)||e.includes(`\\`))return{ok:!1,reason:`docName must not contain "..", a leading "/", or a backslash`};for(let t of e.split(`/`)){if(t.length===0)return{ok:!1,reason:`docName must not contain empty path segments (no leading, trailing, or doubled "/")`};if(t.startsWith(`.`))return{ok:!1,reason:`docName path segments must not start with "." (hidden files are not addressable)`}}return{ok:!0}}const Py=new Set([`opencode.json`]);function Fy(e){return e.split(`/`).some(e=>e.startsWith(`.`))?!0:Py.has(e.slice(e.lastIndexOf(`/`)+1))}function Iy(e,t){let n=Ny(e);n.ok||t.addIssue({code:`custom`,message:n.reason})}const Ly=x().superRefine(Iy).optional(),Ry=x().superRefine(Iy),zy={agentId:x().optional(),agentName:x().optional(),colorSeed:x().optional(),clientName:x().optional(),clientVersion:x().optional(),label:x().optional()},By=x().optional(),Vy=/^urn:uuid:[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i,Hy=S(`kind`,[y({kind:v(`doc`),docPath:x().min(1)}).loose(),y({kind:v(`folder`),folderPath:x()}).loose()]),Uy=f([`no-remote`,`detached-head`,`branch-not-on-origin`,`non-github-remote`,`invalid-path`]),Wy=f([`current`,`stale`,`absent`,`empty`]),Gy=S(`ok`,[y({ok:v(!0),shareUrl:x().min(1),sharedUrl:x().min(1),branch:x().min(1),freshness:Wy.optional().catch(void 0)}).loose(),y({ok:v(!1),error:Uy,branch:x().min(1).optional()}).loose()]),Ky=f([`user`,`org`]),qy=y({login:x().min(1),kind:Ky,avatarUrl:x().optional()}).loose(),Jy=f([`auth-required`,`network`]),Yy=S(`ok`,[y({ok:v(!0),owners:k(qy)}).loose(),y({ok:v(!1),error:Jy}).loose()]),Xy=S(`ok`,[y({ok:v(!0),available:D()}).loose(),y({ok:v(!1),error:Jy}).loose()]),Zy=f([`public`,`private`]),Qy=y({owner:x().min(1),name:x().min(1),visibility:Zy,description:x().optional()}).loose(),$y=f([`name-conflict`,`saml-sso`,`auth-required`,`push-failed`,`init-failed`,`network`,`no-project`]),eb=S(`ok`,[y({ok:v(!0),ownerLogin:x().min(1),repoName:x().min(1),cloneUrl:x().min(1),defaultBranch:x().min(1)}).loose(),y({ok:v(!1),error:$y}).loose()]);function tb(e){return!(typeof e!=`string`||e.length===0||e.startsWith(`-`)||/[\x00-\x1F\x7F]/.test(e)||/\s/.test(e)||e.includes(`:`)||e.split(`/`).includes(`..`))}const nb=e=>e.refine(tb,`invalid branch name`);function rb(e){if(e==null)return!1;let t=e instanceof Error?e.message:String(e);return/couldn'?t find remote ref|Remote branch .+ not found/i.test(t)}const ib=[/could not read (username|password)/i,/terminal prompts disabled/i,/user interactivity has been disabled/i,/unable to get password from user/i],ab=[/insufficient scopes/i,/missing.*scope/i,/required scope/i],ob=[/permission denied.*\(publickey\)/i,/host key verification failed/i],sb=[/\b(401|403)\b/,/authentication failed/i,/authorization failed/i,/invalid credentials/i,/credential helper/i,/bad credentials/i,/token.*expired/i,/expired.*token/i,/fatal:.*repository.*not found/i];function cb(e){if(typeof e!=`object`||!e)return``;let t=e.git;return t==null?``:String(t)}function lb(e){if(e==null)return{kind:`non-auth`};let t=`${e instanceof Error?e.message:String(e)}\n${cb(e)}`;return ib.some(e=>e.test(t))?{kind:`auth`,subclass:`no-credential`}:ab.some(e=>e.test(t))?{kind:`auth`,subclass:`scope-mismatch`}:ob.some(e=>e.test(t))?{kind:`auth`,subclass:`ssh-auth`}:sb.some(e=>e.test(t))?/\b401\b/.test(t)||/token.*expired/i.test(t)?{kind:`auth`,subclass:`401`}:/\b403\b/.test(t)?{kind:`auth`,subclass:`403`}:{kind:`auth`,subclass:`unknown-auth`}:{kind:`non-auth`}}function ub(e){return e.kind===`auth`?e.subclass===`no-credential`||e.subclass===`401`||e.subclass===`unknown-auth`:!1}const db={shareTargetExists:D(),dirtyConflicts:y({conflicts:D(),files:k(x().min(1))}).loose(),branchIsLocal:D(),shareTargetOnOriginBranch:D().optional()},fb=S(`detached`,[y({detached:v(!1),currentBranch:x().min(1).nullable(),currentHeadSha:i(),...db}).loose(),y({detached:v(!0),currentBranch:i(),currentHeadSha:x().min(1),...db}).loose()]),pb=y({branch:nb(x().min(1)),principalId:x().optional(),fastForward:D().optional()}).loose(),mb=f([`dirty-conflict`,`branch-not-found`,`fetch-failed`,`checkout-failed`,`branch-in-other-worktree`,`ff-diverged`]),hb=S(`ok`,[y({ok:v(!0)}).loose(),y({ok:v(!1),reason:mb,files:k(x().min(1)).optional(),otherWorktreePath:x().min(1).optional()}).loose()]);f([`on-origin`,`renamed`,`deleted`,`never-on-branch`,`changed-locally`,`unknown`]);const gb=y({branch:nb(x().min(1)),path:x(),kind:f([`doc`,`folder`])}).loose(),_b=S(`verdict`,[y({verdict:v(`on-origin`)}).loose(),y({verdict:v(`renamed`),renamedTo:x().min(1)}).loose(),y({verdict:v(`deleted`)}).loose(),y({verdict:v(`never-on-branch`)}).loose(),y({verdict:v(`changed-locally`)}).loose(),y({verdict:v(`unknown`)}).loose()]).catch({verdict:`unknown`}),vb=y({startedAt:x().min(1),httpListenMs:A().nonnegative().optional(),seedWalkMs:A().nonnegative().optional(),indexesMs:A().nonnegative().optional(),readyMs:A().nonnegative().optional(),fileCount:A().nonnegative().optional()}),yb=y({serverInstanceId:x().min(1),currentBranch:x().min(1).optional(),currentDiskAckSVs:E(x().min(1),x().min(1)).optional(),boot:vb.optional()}).loose(),bb=y({id:x().min(1),display_name:x().min(1),display_email:x(),source:f([`git-config`,`synthesized`]),created_at:x().min(1)}).loose(),xb=y({collabUrl:x().nullable(),previewUrl:x().nullable(),port:A(),singleFile:D().default(!1)}).loose(),Sb=f(`urn:ok:error:malformed-upload.urn:ok:error:collision-exhaustion.urn:ok:error:storage-full.urn:ok:error:storage-readonly.urn:ok:error:storage-error.urn:ok:error:no-file-received.urn:ok:error:path-escape.urn:ok:error:method-not-allowed.urn:ok:error:invalid-request.urn:ok:error:payload-too-large.urn:ok:error:request-timeout.urn:ok:error:internal-server-error.urn:ok:error:derived-index-unavailable.urn:ok:error:loopback-required.urn:ok:error:invalid-origin.urn:ok:error:url-not-allowed.urn:ok:error:dir-outside-home.urn:ok:error:concurrent-operation.urn:ok:error:clone-failed.urn:ok:error:clone-timeout.urn:ok:error:server-start-failed.urn:ok:error:reserved-doc-name.urn:ok:error:target-not-found.urn:ok:error:stale-target.urn:ok:error:frontmatter-edit-not-supported.urn:ok:error:invalid-frontmatter-patch.urn:ok:error:frontmatter-malformed.urn:ok:error:no-active-session.urn:ok:error:too-many-agent-sessions.urn:ok:error:disk-divergence.urn:ok:error:doc-not-found.urn:ok:error:doc-already-exists.urn:ok:error:doc-not-open.urn:ok:error:rollback-not-configured.urn:ok:error:doc-not-available.urn:ok:error:backlink-index-not-configured.urn:ok:error:file-rescan-not-configured.urn:ok:error:shadow-not-configured.urn:ok:error:host-not-allowed.urn:ok:error:principal-not-available.urn:ok:error:not-found.urn:ok:error:auth-failed.urn:ok:error:no-project-dir.urn:ok:error:server-open-failed.urn:ok:error:doc-in-conflict.urn:ok:error:no-conflict-tracked.urn:ok:error:sync-not-active.urn:ok:error:project-repo-not-configured.urn:ok:error:seed-prerequisite-missing.urn:ok:error:seed-invalid-root.urn:ok:error:tag-index-not-configured.urn:ok:error:template-not-found.urn:ok:error:unsupported-asset-type.urn:ok:error:asset-not-found.urn:ok:error:single-file-mode.urn:ok:error:collab-server-not-running.urn:ok:error:gateway-timeout.urn:ok:error:cursor-not-installed.urn:ok:error:cursor-spawn-timeout.urn:ok:error:cursor-spawn-failed.urn:ok:error:handoff-target-not-installed.urn:ok:error:handoff-spawn-timeout.urn:ok:error:handoff-spawn-failed.urn:ok:error:registry-unreachable.urn:ok:error:config-not-writable.urn:ok:error:audit-superseded`.split(`.`));function Cb(e){throw Error(`Unexpected ProblemType variant: ${JSON.stringify(e)}`)}const wb=y({type:Sb,title:x().min(1),status:A().int().min(400).max(599),instance:x().regex(Vy,`instance must be urn:uuid:<uuid>`).optional(),detail:x().optional()}).loose(),Tb=y({parentDocName:x().min(1),placement:f([`configured-attachments`,`parent-dir`]).default(`configured-attachments`),agentId:x().min(1).optional(),agentName:x().min(1).optional()}).loose(),Eb=y({src:x().min(1),path:x().min(1).optional(),deduped:D().optional()}).loose(),Db=y({url:x().min(1),dir:x().min(1),branch:x().min(1).refine(tb,`invalid branch name`).optional()}).loose(),Ob=y({type:v(`error`),problem:wb}).loose();function kb(e,t,n=3){let r=RegExp(`^ {0,3}(\\${e}+)[ \\t]*$`),i=Math.max(3,n);for(let e of t.split(`
148
148
  `)){let t=r.exec(e);t&&t[1].length>=i&&(i=t[1].length+1)}return i}var Ab=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};Ab.prototype.normal={},Ab.prototype.property={},Ab.prototype.space=void 0;function jb(e,t){let n={},r={};for(let t of e)Object.assign(n,t.property),Object.assign(r,t.normal);return new Ab(n,r,t)}function Mb(e){return e.toLowerCase()}var Nb=class{constructor(e,t){this.attribute=t,this.property=e}};Nb.prototype.attribute=``,Nb.prototype.booleanish=!1,Nb.prototype.boolean=!1,Nb.prototype.commaOrSpaceSeparated=!1,Nb.prototype.commaSeparated=!1,Nb.prototype.defined=!1,Nb.prototype.mustUseProperty=!1,Nb.prototype.number=!1,Nb.prototype.overloadedBoolean=!1,Nb.prototype.property=``,Nb.prototype.spaceSeparated=!1,Nb.prototype.space=void 0;var Pb=n({boolean:()=>Ib,booleanish:()=>Lb,commaOrSpaceSeparated:()=>Vb,commaSeparated:()=>Bb,number:()=>B,overloadedBoolean:()=>Rb,spaceSeparated:()=>zb});let Fb=0;const Ib=Hb(),Lb=Hb(),Rb=Hb(),B=Hb(),zb=Hb(),Bb=Hb(),Vb=Hb();function Hb(){return 2**++Fb}const Ub=Object.keys(Pb);var Wb=class extends Nb{constructor(e,t,n,r){let i=-1;if(super(e,t),Gb(this,`space`,r),typeof n==`number`)for(;++i<Ub.length;){let e=Ub[i];Gb(this,Ub[i],(n&Pb[e])===Pb[e])}}};Wb.prototype.defined=!0;function Gb(e,t,n){n&&(e[t]=n)}function Kb(e){let t={},n={};for(let[r,i]of Object.entries(e.properties)){let a=new Wb(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Mb(r)]=r,n[Mb(a.attribute)]=r}return new Ab(t,n,e.space)}const qb=Kb({properties:{ariaActiveDescendant:null,ariaAtomic:Lb,ariaAutoComplete:null,ariaBusy:Lb,ariaChecked:Lb,ariaColCount:B,ariaColIndex:B,ariaColSpan:B,ariaControls:zb,ariaCurrent:null,ariaDescribedBy:zb,ariaDetails:null,ariaDisabled:Lb,ariaDropEffect:zb,ariaErrorMessage:null,ariaExpanded:Lb,ariaFlowTo:zb,ariaGrabbed:Lb,ariaHasPopup:null,ariaHidden:Lb,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:zb,ariaLevel:B,ariaLive:null,ariaModal:Lb,ariaMultiLine:Lb,ariaMultiSelectable:Lb,ariaOrientation:null,ariaOwns:zb,ariaPlaceholder:null,ariaPosInSet:B,ariaPressed:Lb,ariaReadOnly:Lb,ariaRelevant:null,ariaRequired:Lb,ariaRoleDescription:zb,ariaRowCount:B,ariaRowIndex:B,ariaRowSpan:B,ariaSelected:Lb,ariaSetSize:B,ariaSort:null,ariaValueMax:B,ariaValueMin:B,ariaValueNow:B,ariaValueText:null,role:null},transform(e,t){return t===`role`?t:`aria-`+t.slice(4).toLowerCase()}});function Jb(e,t){return t in e?e[t]:t}function Yb(e,t){return Jb(e,t.toLowerCase())}const Xb=Kb({attributes:{acceptcharset:`accept-charset`,classname:`class`,htmlfor:`for`,httpequiv:`http-equiv`},mustUseProperty:[`checked`,`multiple`,`muted`,`selected`],properties:{abbr:null,accept:Bb,acceptCharset:zb,accessKey:zb,action:null,allow:null,allowFullScreen:Ib,allowPaymentRequest:Ib,allowUserMedia:Ib,alpha:Ib,alt:null,as:null,async:Ib,autoCapitalize:null,autoComplete:zb,autoFocus:Ib,autoPlay:Ib,blocking:zb,capture:null,charSet:null,checked:Ib,cite:null,className:zb,closedBy:null,colorSpace:null,cols:B,colSpan:B,command:null,commandFor:null,content:null,contentEditable:Lb,controls:Ib,controlsList:zb,coords:B|Bb,crossOrigin:null,data:null,dateTime:null,decoding:null,default:Ib,defer:Ib,dir:null,dirName:null,disabled:Ib,download:Rb,draggable:Lb,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:Ib,formTarget:null,headers:zb,height:B,hidden:Rb,high:B,href:null,hrefLang:null,htmlFor:zb,httpEquiv:zb,id:null,imageSizes:null,imageSrcSet:null,inert:Ib,inputMode:null,integrity:null,is:null,isMap:Ib,itemId:null,itemProp:zb,itemRef:zb,itemScope:Ib,itemType:zb,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:Ib,low:B,manifest:null,max:null,maxLength:B,media:null,method:null,min:null,minLength:B,multiple:Ib,muted:Ib,name:null,nonce:null,noModule:Ib,noValidate:Ib,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:Ib,optimum:B,pattern:null,ping:zb,placeholder:null,playsInline:Ib,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:Ib,referrerPolicy:null,rel:zb,required:Ib,reversed:Ib,rows:B,rowSpan:B,sandbox:zb,scope:null,scoped:Ib,seamless:Ib,selected:Ib,shadowRootClonable:Ib,shadowRootCustomElementRegistry:Ib,shadowRootDelegatesFocus:Ib,shadowRootMode:null,shadowRootSerializable:Ib,shape:null,size:B,sizes:null,slot:null,span:B,spellCheck:Lb,src:null,srcDoc:null,srcLang:null,srcSet:null,start:B,step:null,style:null,tabIndex:B,target:null,title:null,translate:null,type:null,typeMustMatch:Ib,useMap:null,value:Lb,width:B,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:zb,axis:null,background:null,bgColor:null,border:B,borderColor:null,bottomMargin:B,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:Ib,declare:Ib,event:null,face:null,frame:null,frameBorder:null,hSpace:B,leftMargin:B,link:null,longDesc:null,lowSrc:null,marginHeight:B,marginWidth:B,noResize:Ib,noHref:Ib,noShade:Ib,noWrap:Ib,object:null,profile:null,prompt:null,rev:null,rightMargin:B,rules:null,scheme:null,scrolling:Lb,standby:null,summary:null,text:null,topMargin:B,valueType:null,version:null,vAlign:null,vLink:null,vSpace:B,allowTransparency:null,autoCorrect:null,autoSave:null,credentialless:Ib,disablePictureInPicture:Ib,disableRemotePlayback:Ib,exportParts:Bb,part:zb,prefix:null,property:null,results:B,security:null,unselectable:null},space:`html`,transform:Yb}),Zb=Kb({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`,maskType:`mask-type`,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:Vb,accentHeight:B,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:B,amplitude:B,arabicForm:null,ascent:B,attributeName:null,attributeType:null,azimuth:B,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:B,by:null,calcMode:null,capHeight:B,className:zb,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:B,diffuseConstant:B,direction:null,display:null,dur:null,divisor:B,dominantBaseline:null,download:Ib,dx:null,dy:null,edgeMode:null,editable:null,elevation:B,enableBackground:null,end:null,event:null,exponent:B,externalResourcesRequired:null,fill:null,fillOpacity:B,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:Bb,g2:Bb,glyphName:Bb,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:B,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:B,horizOriginX:B,horizOriginY:B,id:null,ideographic:B,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:B,k:B,k1:B,k2:B,k3:B,k4:B,kernelMatrix:Vb,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:B,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskType:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:B,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:B,overlineThickness:B,paintOrder:null,panose1:null,path:null,pathLength:B,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:zb,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:B,pointsAtY:B,pointsAtZ:B,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Vb,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Vb,rev:Vb,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Vb,requiredFeatures:Vb,requiredFonts:Vb,requiredFormats:Vb,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:B,specularExponent:B,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:B,strikethroughThickness:B,string:null,stroke:null,strokeDashArray:Vb,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:B,strokeOpacity:B,strokeWidth:null,style:null,surfaceScale:B,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Vb,tabIndex:B,tableValues:null,target:null,targetX:B,targetY:B,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Vb,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:B,underlineThickness:B,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:B,values:null,vAlphabetic:B,vMathematical:B,vectorEffect:null,vHanging:B,vIdeographic:B,version:null,vertAdvY:B,vertOriginX:B,vertOriginY:B,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:B,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:`svg`,transform:Jb}),Qb=Kb({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()}}),$b=Kb({attributes:{xmlnsxlink:`xmlns:xlink`},properties:{xmlnsXLink:null,xmlns:null},space:`xmlns`,transform:Yb}),ex=Kb({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:`xml`,transform(e,t){return`xml:`+t.slice(3).toLowerCase()}}),tx=/[A-Z]/g,nx=/-[a-z]/g,rx=/^data[-\w.:]+$/i;function ix(e,t){let n=Mb(t),r=t,i=Nb;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)===`data`&&rx.test(t)){if(t.charAt(4)===`-`){let e=t.slice(5).replace(nx,ox);r=`data`+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!nx.test(e)){let n=e.replace(tx,ax);n.charAt(0)!==`-`&&(n=`-`+n),t=`data`+n}}i=Wb}return new i(r,t)}function ax(e){return`-`+e.toLowerCase()}function ox(e){return e.charAt(1).toUpperCase()}const sx=jb([qb,Xb,Qb,$b,ex],`html`),cx=jb([qb,Zb,Qb,$b,ex],`svg`);function lx(e){let t=[],n=String(e||``),r=n.indexOf(`,`),i=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);let e=n.slice(i,r).trim();(e||!a)&&t.push(e),i=r+1,r=n.indexOf(`,`,i)}return t}const ux=/[#.]/g;function dx(e,t){let n=e||``,r={},i=0,a,o;for(;i<n.length;){ux.lastIndex=i;let e=ux.exec(n),t=n.slice(i,e?e.index:n.length);t&&(a?a===`#`?r.id=t:Array.isArray(r.className)?r.className.push(t):r.className=[t]:o=t,i+=t.length),e&&(a=e[0],i++)}return{type:`element`,tagName:o||t||`div`,properties:r,children:[]}}function fx(e){let t=String(e||``).trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function px(e,t,n){let r=n?yx(n):void 0;function i(n,i,...a){let o;if(n==null){o={type:`root`,children:[]};let e=i;a.unshift(e)}else{o=dx(n,t);let s=o.tagName.toLowerCase(),c=r?r.get(s):void 0;if(o.tagName=c||s,mx(i))a.unshift(i);else for(let[t,n]of Object.entries(i))hx(e,o.properties,t,n)}for(let e of a)gx(o.children,e);return o.type===`element`&&o.tagName===`template`&&(o.content={type:`root`,children:o.children},o.children=[]),o}return i}function mx(e){if(typeof e!=`object`||!e||Array.isArray(e))return!0;if(typeof e.type!=`string`)return!1;let t=e,n=Object.keys(e);for(let e of n){let n=t[e];if(n&&typeof n==`object`){if(!Array.isArray(n))return!0;let e=n;for(let t of e)if(typeof t!=`number`&&typeof t!=`string`)return!0}}return!!(`children`in e&&Array.isArray(e.children))}function hx(e,t,n,r){let i=ix(e,n),a;if(r!=null){if(typeof r==`number`){if(Number.isNaN(r))return;a=r}else a=typeof r==`boolean`?r:typeof r==`string`?i.spaceSeparated?fx(r):i.commaSeparated?lx(r):i.commaOrSpaceSeparated?fx(lx(r).join(` `)):_x(i,i.property,r):Array.isArray(r)?[...r]:i.property===`style`?vx(r):String(r);if(Array.isArray(a)){let e=[];for(let t of a)e.push(_x(i,i.property,t));a=e}i.property===`className`&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[i.property]=a}}function gx(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(let n of t)gx(e,n);else if(typeof t==`object`&&`type`in t)t.type===`root`?gx(e,t.children):e.push(t);else throw Error("Expected node, nodes, or string, got `"+t+"`")}function _x(e,t,n){if(typeof n==`string`){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===``||Mb(n)===Mb(t)))return!0}return n}function vx(e){let t=[];for(let[n,r]of Object.entries(e))t.push([n,r].join(`: `));return t.join(`; `)}function yx(e){let t=new Map;for(let n of e)t.set(n.toLowerCase(),n);return t}const bx=`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`.split(`.`),xx=px(sx,`div`),Sx=px(cx,`g`,bx);function Cx(e){let t=String(e),n=[];return{toOffset:i,toPoint:r};function r(e){if(typeof e==`number`&&e>-1&&e<=t.length){let r=0;for(;;){let i=n[r];if(i===void 0){let e=wx(t,n[r-1]);i=e===-1?t.length+1:e+1,n[r]=i}if(i>e)return{line:r+1,column:e-(r>0?n[r-1]:0)+1,offset:e};r++}}}function i(e){if(e&&typeof e.line==`number`&&typeof e.column==`number`&&!Number.isNaN(e.line)&&!Number.isNaN(e.column)){for(;n.length<e.line;){let e=n[n.length-1],r=wx(t,e),i=r===-1?t.length+1:r+1;if(e===i)break;n.push(i)}let r=(e.line>1?n[e.line-2]:0)+e.column-1;if(r<n[e.line-1])return r}}}function wx(e,t){let n=e.indexOf(`\r`,t),r=e.indexOf(`
149
149
  `,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Tx={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/`},Ex={}.hasOwnProperty,Dx=Object.prototype;function Ox(e,t){let n=t||{};return kx({file:n.file||void 0,location:!1,schema:n.space===`svg`?cx:sx,verbose:n.verbose||!1},e)}function kx(e,t){let n;switch(t.nodeName){case`#comment`:{let r=t;return n={type:`comment`,value:r.data},Mx(e,r,n),n}case`#document`:case`#document-fragment`:{let r=t,i=`mode`in r?r.mode===`quirks`||r.mode===`limited-quirks`:!1;if(n={type:`root`,children:Ax(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){let t=String(e.file),r=Cx(t),i=r.toPoint(0),a=r.toPoint(t.length);n.position={start:i,end:a}}return n}case`#documentType`:{let r=t;return n={type:`doctype`},Mx(e,r,n),n}case`#text`:{let r=t;return n={type:`text`,value:r.value},Mx(e,r,n),n}default:return n=jx(e,t),n}}function Ax(e,t){let n=-1,r=[];for(;++n<t.length;){let i=kx(e,t[n]);r.push(i)}return r}function jx(e,t){let n=e.schema;e.schema=t.namespaceURI===Tx.svg?cx:sx;let r=-1,i={};for(;++r<t.attrs.length;){let e=t.attrs[r],n=(e.prefix?e.prefix+`:`:``)+e.name;Ex.call(Dx,n)||(i[n]=e.value)}let a=(e.schema.space===`svg`?Sx:xx)(t.tagName,i,Ax(e,t.childNodes));if(Mx(e,t,a),a.tagName===`template`){let n=t,r=n.sourceCodeLocation,i=r&&r.startTag&&Px(r.startTag),o=r&&r.endTag&&Px(r.endTag),s=kx(e,n.content);i&&o&&e.file&&(s.position={start:i.end,end:o.start}),a.content=s}return e.schema=n,a}function Mx(e,t,n){if(`sourceCodeLocation`in t&&t.sourceCodeLocation&&e.file){let r=Nx(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function Nx(e,t,n){let r=Px(n);if(t.type===`element`){let 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){let r={},i;if(n.attrs)for(i in n.attrs)Ex.call(n.attrs,i)&&(r[ix(e.schema,i).property]=Px(n.attrs[i]));n.startTag;let a=Px(n.startTag),o=n.endTag?Px(n.endTag):void 0,s={opening:a};o&&(s.closing=o),s.properties=r,t.data={position:s}}}return r}function Px(e){let t=Fx({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=Fx({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function Fx(e){return e.line&&e.column?e:void 0}const Ix=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 V;(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`})(V||={});const Lx={DASH_DASH:`--`,CDATA_START:`[CDATA[`,DOCTYPE:`doctype`,SCRIPT:`script`,PUBLIC:`public`,SYSTEM:`system`};function Rx(e){return e>=55296&&e<=57343}function zx(e){return e>=56320&&e<=57343}function Bx(e,t){return(e-55296)*1024+9216+t}function Vx(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function Hx(e){return e>=64976&&e<=65007||Ix.has(e)}var H;(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`})(H||={});var Ux=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=65536,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+Number(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(e,t){let{line:n,col:r,offset:i}=this,a=r+t,o=i+t;return{code:e,startLine:n,endLine:n,startCol:a,endCol:a,startOffset:o,endOffset:o}}_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){let t=this.html.charCodeAt(this.pos+1);if(zx(t))return this.pos++,this._addGap(),Bx(e,t)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,V.EOF;return this._err(H.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 t=0;t<e.length;t++)if((this.html.charCodeAt(this.pos+t)|32)!==e.charCodeAt(t))return!1;return!0}peek(e){let t=this.pos+e;if(t>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,V.EOF;let n=this.html.charCodeAt(t);return n===V.CARRIAGE_RETURN?V.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,V.EOF;let e=this.html.charCodeAt(this.pos);return e===V.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,V.LINE_FEED):e===V.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,Rx(e)&&(e=this._processSurrogate(e)),this.handler.onParseError===null||e>31&&e<127||e===V.LINE_FEED||e===V.CARRIAGE_RETURN||e>159&&e<64976||this._checkForProblematicCharacters(e),e)}_checkForProblematicCharacters(e){Vx(e)?this._err(H.controlCharacterInInputStream):Hx(e)&&this._err(H.noncharacterInInputStream)}retreat(e){for(this.pos-=e;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}},Wx;(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`})(Wx||={});function Gx(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const Kx=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୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢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;怳Ādp໩໮uct;戏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ǣጓ\0጖y;䐎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Ā;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀ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Ā;e᜚᜜lƀ;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\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩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ↄⅪ←ٖ↛ǰ↉\0↎proø₞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肻\xA0ଷ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;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\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\0⹻m;櫳;櫽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))),qx=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]]);String.fromCodePoint;function Jx(e){return e>=55296&&e<=57343||e>1114111?65533:qx.get(e)??e}var Yx;(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`})(Yx||={});var Xx;(function(e){e[e.VALUE_LENGTH=49152]=`VALUE_LENGTH`,e[e.BRANCH_LENGTH=16256]=`BRANCH_LENGTH`,e[e.JUMP_TABLE=127]=`JUMP_TABLE`})(Xx||={});function Zx(e){return e>=Yx.ZERO&&e<=Yx.NINE}function Qx(e){return e>=Yx.UPPER_A&&e<=Yx.UPPER_F||e>=Yx.LOWER_A&&e<=Yx.LOWER_F}function $x(e){return e>=Yx.UPPER_A&&e<=Yx.UPPER_Z||e>=Yx.LOWER_A&&e<=Yx.LOWER_Z||Zx(e)}function eS(e){return e===Yx.EQUALS||$x(e)}var tS;(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`})(tS||={});var nS;(function(e){e[e.Legacy=0]=`Legacy`,e[e.Strict=1]=`Strict`,e[e.Attribute=2]=`Attribute`})(nS||={});var rS=class{constructor(e,t,n){this.decodeTree=e,this.emitCodePoint=t,this.errors=n,this.state=tS.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=nS.Strict}startEntity(e){this.decodeMode=e,this.state=tS.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(e,t){switch(this.state){case tS.EntityStart:return e.charCodeAt(t)===Yx.NUM?(this.state=tS.NumericStart,this.consumed+=1,this.stateNumericStart(e,t+1)):(this.state=tS.NamedEntity,this.stateNamedEntity(e,t));case tS.NumericStart:return this.stateNumericStart(e,t);case tS.NumericDecimal:return this.stateNumericDecimal(e,t);case tS.NumericHex:return this.stateNumericHex(e,t);case tS.NamedEntity:return this.stateNamedEntity(e,t)}}stateNumericStart(e,t){return t>=e.length?-1:(e.charCodeAt(t)|32)===Yx.LOWER_X?(this.state=tS.NumericHex,this.consumed+=1,this.stateNumericHex(e,t+1)):(this.state=tS.NumericDecimal,this.stateNumericDecimal(e,t))}addToNumericResult(e,t,n,r){if(t!==n){let i=n-t;this.result=this.result*r**+i+Number.parseInt(e.substr(t,i),r),this.consumed+=i}}stateNumericHex(e,t){let n=t;for(;t<e.length;){let r=e.charCodeAt(t);if(Zx(r)||Qx(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){let n=t;for(;t<e.length;){let r=e.charCodeAt(t);if(Zx(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.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(e===Yx.SEMI)this.consumed+=1;else if(this.decodeMode===nS.Strict)return 0;return this.emitCodePoint(Jx(this.result),this.consumed),this.errors&&(e!==Yx.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(e,t){let{decodeTree:n}=this,r=n[this.treeIndex],i=(r&Xx.VALUE_LENGTH)>>14;for(;t<e.length;t++,this.excess++){let a=e.charCodeAt(t);if(this.treeIndex=iS(n,r,this.treeIndex+Math.max(1,i),a),this.treeIndex<0)return this.result===0||this.decodeMode===nS.Attribute&&(i===0||eS(a))?0:this.emitNotTerminatedNamedEntity();if(r=n[this.treeIndex],i=(r&Xx.VALUE_LENGTH)>>14,i!==0){if(a===Yx.SEMI)return this.emitNamedEntityData(this.treeIndex,i,this.consumed+this.excess);this.decodeMode!==nS.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var e;let{result:t,decodeTree:n}=this,r=(n[t]&Xx.VALUE_LENGTH)>>14;return this.emitNamedEntityData(t,r,this.consumed),(e=this.errors)==null||e.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(e,t,n){let{decodeTree:r}=this;return this.emitCodePoint(t===1?r[e]&~Xx.VALUE_LENGTH:r[e+1],n),t===3&&this.emitCodePoint(r[e+2],n),n}end(){var e;switch(this.state){case tS.NamedEntity:return this.result!==0&&(this.decodeMode!==nS.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case tS.NumericDecimal:return this.emitNumericEntity(0,2);case tS.NumericHex:return this.emitNumericEntity(0,3);case tS.NumericStart:return(e=this.errors)==null||e.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case tS.EntityStart:return 0}}};function iS(e,t,n,r){let i=(t&Xx.BRANCH_LENGTH)>>7,a=t&Xx.JUMP_TABLE;if(i===0)return a!==0&&r===a?n:-1;if(a){let t=r-a;return t<0||t>=i?-1:e[n+t]-1}let o=n,s=o+i-1;for(;o<=s;){let t=o+s>>>1,n=e[t];if(n<r)o=t+1;else if(n>r)s=t-1;else return e[t+i]}return-1}var U;(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/`})(U||={});var aS;(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`})(aS||={});var oS;(function(e){e.NO_QUIRKS=`no-quirks`,e.QUIRKS=`quirks`,e.LIMITED_QUIRKS=`limited-quirks`})(oS||={});var W;(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`})(W||={});var G;(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`})(G||={});const sS=new Map([[W.A,G.A],[W.ADDRESS,G.ADDRESS],[W.ANNOTATION_XML,G.ANNOTATION_XML],[W.APPLET,G.APPLET],[W.AREA,G.AREA],[W.ARTICLE,G.ARTICLE],[W.ASIDE,G.ASIDE],[W.B,G.B],[W.BASE,G.BASE],[W.BASEFONT,G.BASEFONT],[W.BGSOUND,G.BGSOUND],[W.BIG,G.BIG],[W.BLOCKQUOTE,G.BLOCKQUOTE],[W.BODY,G.BODY],[W.BR,G.BR],[W.BUTTON,G.BUTTON],[W.CAPTION,G.CAPTION],[W.CENTER,G.CENTER],[W.CODE,G.CODE],[W.COL,G.COL],[W.COLGROUP,G.COLGROUP],[W.DD,G.DD],[W.DESC,G.DESC],[W.DETAILS,G.DETAILS],[W.DIALOG,G.DIALOG],[W.DIR,G.DIR],[W.DIV,G.DIV],[W.DL,G.DL],[W.DT,G.DT],[W.EM,G.EM],[W.EMBED,G.EMBED],[W.FIELDSET,G.FIELDSET],[W.FIGCAPTION,G.FIGCAPTION],[W.FIGURE,G.FIGURE],[W.FONT,G.FONT],[W.FOOTER,G.FOOTER],[W.FOREIGN_OBJECT,G.FOREIGN_OBJECT],[W.FORM,G.FORM],[W.FRAME,G.FRAME],[W.FRAMESET,G.FRAMESET],[W.H1,G.H1],[W.H2,G.H2],[W.H3,G.H3],[W.H4,G.H4],[W.H5,G.H5],[W.H6,G.H6],[W.HEAD,G.HEAD],[W.HEADER,G.HEADER],[W.HGROUP,G.HGROUP],[W.HR,G.HR],[W.HTML,G.HTML],[W.I,G.I],[W.IMG,G.IMG],[W.IMAGE,G.IMAGE],[W.INPUT,G.INPUT],[W.IFRAME,G.IFRAME],[W.KEYGEN,G.KEYGEN],[W.LABEL,G.LABEL],[W.LI,G.LI],[W.LINK,G.LINK],[W.LISTING,G.LISTING],[W.MAIN,G.MAIN],[W.MALIGNMARK,G.MALIGNMARK],[W.MARQUEE,G.MARQUEE],[W.MATH,G.MATH],[W.MENU,G.MENU],[W.META,G.META],[W.MGLYPH,G.MGLYPH],[W.MI,G.MI],[W.MO,G.MO],[W.MN,G.MN],[W.MS,G.MS],[W.MTEXT,G.MTEXT],[W.NAV,G.NAV],[W.NOBR,G.NOBR],[W.NOFRAMES,G.NOFRAMES],[W.NOEMBED,G.NOEMBED],[W.NOSCRIPT,G.NOSCRIPT],[W.OBJECT,G.OBJECT],[W.OL,G.OL],[W.OPTGROUP,G.OPTGROUP],[W.OPTION,G.OPTION],[W.P,G.P],[W.PARAM,G.PARAM],[W.PLAINTEXT,G.PLAINTEXT],[W.PRE,G.PRE],[W.RB,G.RB],[W.RP,G.RP],[W.RT,G.RT],[W.RTC,G.RTC],[W.RUBY,G.RUBY],[W.S,G.S],[W.SCRIPT,G.SCRIPT],[W.SEARCH,G.SEARCH],[W.SECTION,G.SECTION],[W.SELECT,G.SELECT],[W.SOURCE,G.SOURCE],[W.SMALL,G.SMALL],[W.SPAN,G.SPAN],[W.STRIKE,G.STRIKE],[W.STRONG,G.STRONG],[W.STYLE,G.STYLE],[W.SUB,G.SUB],[W.SUMMARY,G.SUMMARY],[W.SUP,G.SUP],[W.TABLE,G.TABLE],[W.TBODY,G.TBODY],[W.TEMPLATE,G.TEMPLATE],[W.TEXTAREA,G.TEXTAREA],[W.TFOOT,G.TFOOT],[W.TD,G.TD],[W.TH,G.TH],[W.THEAD,G.THEAD],[W.TITLE,G.TITLE],[W.TR,G.TR],[W.TRACK,G.TRACK],[W.TT,G.TT],[W.U,G.U],[W.UL,G.UL],[W.SVG,G.SVG],[W.VAR,G.VAR],[W.WBR,G.WBR],[W.XMP,G.XMP]]);function cS(e){return sS.get(e)??G.UNKNOWN}const K=G,lS={[U.HTML]:new Set([K.ADDRESS,K.APPLET,K.AREA,K.ARTICLE,K.ASIDE,K.BASE,K.BASEFONT,K.BGSOUND,K.BLOCKQUOTE,K.BODY,K.BR,K.BUTTON,K.CAPTION,K.CENTER,K.COL,K.COLGROUP,K.DD,K.DETAILS,K.DIR,K.DIV,K.DL,K.DT,K.EMBED,K.FIELDSET,K.FIGCAPTION,K.FIGURE,K.FOOTER,K.FORM,K.FRAME,K.FRAMESET,K.H1,K.H2,K.H3,K.H4,K.H5,K.H6,K.HEAD,K.HEADER,K.HGROUP,K.HR,K.HTML,K.IFRAME,K.IMG,K.INPUT,K.LI,K.LINK,K.LISTING,K.MAIN,K.MARQUEE,K.MENU,K.META,K.NAV,K.NOEMBED,K.NOFRAMES,K.NOSCRIPT,K.OBJECT,K.OL,K.P,K.PARAM,K.PLAINTEXT,K.PRE,K.SCRIPT,K.SECTION,K.SELECT,K.SOURCE,K.STYLE,K.SUMMARY,K.TABLE,K.TBODY,K.TD,K.TEMPLATE,K.TEXTAREA,K.TFOOT,K.TH,K.THEAD,K.TITLE,K.TR,K.TRACK,K.UL,K.WBR,K.XMP]),[U.MATHML]:new Set([K.MI,K.MO,K.MN,K.MS,K.MTEXT,K.ANNOTATION_XML]),[U.SVG]:new Set([K.TITLE,K.FOREIGN_OBJECT,K.DESC]),[U.XLINK]:new Set,[U.XML]:new Set,[U.XMLNS]:new Set},uS=new Set([K.H1,K.H2,K.H3,K.H4,K.H5,K.H6]);new Set([W.STYLE,W.SCRIPT,W.XMP,W.IFRAME,W.NOEMBED,W.NOFRAMES,W.PLAINTEXT]);var q;(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`})(q||={});const dS={DATA:q.DATA,RCDATA:q.RCDATA,RAWTEXT:q.RAWTEXT,SCRIPT_DATA:q.SCRIPT_DATA,PLAINTEXT:q.PLAINTEXT,CDATA_SECTION:q.CDATA_SECTION};function fS(e){return e>=V.DIGIT_0&&e<=V.DIGIT_9}function pS(e){return e>=V.LATIN_CAPITAL_A&&e<=V.LATIN_CAPITAL_Z}function mS(e){return e>=V.LATIN_SMALL_A&&e<=V.LATIN_SMALL_Z}function hS(e){return mS(e)||pS(e)}function gS(e){return hS(e)||fS(e)}function _S(e){return e+32}function vS(e){return e===V.SPACE||e===V.LINE_FEED||e===V.TABULATION||e===V.FORM_FEED}function yS(e){return vS(e)||e===V.SOLIDUS||e===V.GREATER_THAN_SIGN}function bS(e){return e===V.NULL?H.nullCharacterReference:e>1114111?H.characterReferenceOutsideUnicodeRange:Rx(e)?H.surrogateCharacterReference:Hx(e)?H.noncharacterCharacterReference:Vx(e)||e===V.CARRIAGE_RETURN?H.controlCharacterReference:null}var xS=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=q.DATA,this.returnState=q.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:``,value:``},this.preprocessor=new Ux(t),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new rS(Kx,(e,t)=>{this.preprocessor.pos=this.entityStartPos+t-1,this._flushCodePointConsumedAsCharacterReference(e)},t.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(H.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:e=>{this._err(H.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+e)},validateNumericCharacterReference:e=>{let t=bS(e);t&&this._err(t,1)}}:void 0)}_err(e,t=0){var n,r;(r=(n=this.handler).onParseError)==null||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;let e=this._consume();this._ensureHibernation()||this._callState(e)}this.inLoop=!1}}pause(){this.paused=!0}resume(e){if(!this.paused)throw 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:Wx.START_TAG,tagName:``,tagID:G.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:Wx.END_TAG,tagName:``,tagID:G.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(e){this.currentToken={type:Wx.COMMENT,data:``,location:this.getCurrentLocation(e)}}_createDoctypeToken(e){this.currentToken={type:Wx.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;let t=this.currentToken;if(Gx(t,this.currentAttr.name)===null){if(t.attrs.push(this.currentAttr),t.location&&this.currentLocation){let n=(e=t.location).attrs??(e.attrs=Object.create(null));n[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(H.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(){let e=this.currentToken;this.prepareToken(e),e.tagID=cS(e.tagName),e.type===Wx.START_TAG?(this.lastStartTagName=e.tagName,this.handler.onStartTag(e)):(e.attrs.length>0&&this._err(H.endTagWithAttributes),e.selfClosing&&this._err(H.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 Wx.CHARACTER:this.handler.onCharacter(this.currentCharacterToken);break;case Wx.NULL_CHARACTER:this.handler.onNullCharacter(this.currentCharacterToken);break;case Wx.WHITESPACE_CHARACTER:this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}this.currentCharacterToken=null}}_emitEOFToken(){let e=this.getCurrentLocation(0);e&&(e.endLine=e.startLine,e.endCol=e.startCol,e.endOffset=e.startOffset),this._emitCurrentCharacterToken(e),this.handler.onEof({type:Wx.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){let t=vS(e)?Wx.WHITESPACE_CHARACTER:e===V.NULL?Wx.NULL_CHARACTER:Wx.CHARACTER;this._appendCharToCurrentCharacterToken(t,String.fromCodePoint(e))}_emitChars(e){this._appendCharToCurrentCharacterToken(Wx.CHARACTER,e)}_startCharacterReference(){this.returnState=this.state,this.state=q.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?nS.Attribute:nS.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===q.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===q.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===q.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(e){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(e):this._emitCodePoint(e)}_callState(e){switch(this.state){case q.DATA:this._stateData(e);break;case q.RCDATA:this._stateRcdata(e);break;case q.RAWTEXT:this._stateRawtext(e);break;case q.SCRIPT_DATA:this._stateScriptData(e);break;case q.PLAINTEXT:this._statePlaintext(e);break;case q.TAG_OPEN:this._stateTagOpen(e);break;case q.END_TAG_OPEN:this._stateEndTagOpen(e);break;case q.TAG_NAME:this._stateTagName(e);break;case q.RCDATA_LESS_THAN_SIGN:this._stateRcdataLessThanSign(e);break;case q.RCDATA_END_TAG_OPEN:this._stateRcdataEndTagOpen(e);break;case q.RCDATA_END_TAG_NAME:this._stateRcdataEndTagName(e);break;case q.RAWTEXT_LESS_THAN_SIGN:this._stateRawtextLessThanSign(e);break;case q.RAWTEXT_END_TAG_OPEN:this._stateRawtextEndTagOpen(e);break;case q.RAWTEXT_END_TAG_NAME:this._stateRawtextEndTagName(e);break;case q.SCRIPT_DATA_LESS_THAN_SIGN:this._stateScriptDataLessThanSign(e);break;case q.SCRIPT_DATA_END_TAG_OPEN:this._stateScriptDataEndTagOpen(e);break;case q.SCRIPT_DATA_END_TAG_NAME:this._stateScriptDataEndTagName(e);break;case q.SCRIPT_DATA_ESCAPE_START:this._stateScriptDataEscapeStart(e);break;case q.SCRIPT_DATA_ESCAPE_START_DASH:this._stateScriptDataEscapeStartDash(e);break;case q.SCRIPT_DATA_ESCAPED:this._stateScriptDataEscaped(e);break;case q.SCRIPT_DATA_ESCAPED_DASH:this._stateScriptDataEscapedDash(e);break;case q.SCRIPT_DATA_ESCAPED_DASH_DASH:this._stateScriptDataEscapedDashDash(e);break;case q.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:this._stateScriptDataEscapedLessThanSign(e);break;case q.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:this._stateScriptDataEscapedEndTagOpen(e);break;case q.SCRIPT_DATA_ESCAPED_END_TAG_NAME:this._stateScriptDataEscapedEndTagName(e);break;case q.SCRIPT_DATA_DOUBLE_ESCAPE_START:this._stateScriptDataDoubleEscapeStart(e);break;case q.SCRIPT_DATA_DOUBLE_ESCAPED:this._stateScriptDataDoubleEscaped(e);break;case q.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:this._stateScriptDataDoubleEscapedDash(e);break;case q.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:this._stateScriptDataDoubleEscapedDashDash(e);break;case q.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:this._stateScriptDataDoubleEscapedLessThanSign(e);break;case q.SCRIPT_DATA_DOUBLE_ESCAPE_END:this._stateScriptDataDoubleEscapeEnd(e);break;case q.BEFORE_ATTRIBUTE_NAME:this._stateBeforeAttributeName(e);break;case q.ATTRIBUTE_NAME:this._stateAttributeName(e);break;case q.AFTER_ATTRIBUTE_NAME:this._stateAfterAttributeName(e);break;case q.BEFORE_ATTRIBUTE_VALUE:this._stateBeforeAttributeValue(e);break;case q.ATTRIBUTE_VALUE_DOUBLE_QUOTED:this._stateAttributeValueDoubleQuoted(e);break;case q.ATTRIBUTE_VALUE_SINGLE_QUOTED:this._stateAttributeValueSingleQuoted(e);break;case q.ATTRIBUTE_VALUE_UNQUOTED:this._stateAttributeValueUnquoted(e);break;case q.AFTER_ATTRIBUTE_VALUE_QUOTED:this._stateAfterAttributeValueQuoted(e);break;case q.SELF_CLOSING_START_TAG:this._stateSelfClosingStartTag(e);break;case q.BOGUS_COMMENT:this._stateBogusComment(e);break;case q.MARKUP_DECLARATION_OPEN:this._stateMarkupDeclarationOpen(e);break;case q.COMMENT_START:this._stateCommentStart(e);break;case q.COMMENT_START_DASH:this._stateCommentStartDash(e);break;case q.COMMENT:this._stateComment(e);break;case q.COMMENT_LESS_THAN_SIGN:this._stateCommentLessThanSign(e);break;case q.COMMENT_LESS_THAN_SIGN_BANG:this._stateCommentLessThanSignBang(e);break;case q.COMMENT_LESS_THAN_SIGN_BANG_DASH:this._stateCommentLessThanSignBangDash(e);break;case q.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:this._stateCommentLessThanSignBangDashDash(e);break;case q.COMMENT_END_DASH:this._stateCommentEndDash(e);break;case q.COMMENT_END:this._stateCommentEnd(e);break;case q.COMMENT_END_BANG:this._stateCommentEndBang(e);break;case q.DOCTYPE:this._stateDoctype(e);break;case q.BEFORE_DOCTYPE_NAME:this._stateBeforeDoctypeName(e);break;case q.DOCTYPE_NAME:this._stateDoctypeName(e);break;case q.AFTER_DOCTYPE_NAME:this._stateAfterDoctypeName(e);break;case q.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._stateAfterDoctypePublicKeyword(e);break;case q.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:this._stateBeforeDoctypePublicIdentifier(e);break;case q.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:this._stateDoctypePublicIdentifierDoubleQuoted(e);break;case q.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:this._stateDoctypePublicIdentifierSingleQuoted(e);break;case q.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:this._stateAfterDoctypePublicIdentifier(e);break;case q.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:this._stateBetweenDoctypePublicAndSystemIdentifiers(e);break;case q.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._stateAfterDoctypeSystemKeyword(e);break;case q.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:this._stateBeforeDoctypeSystemIdentifier(e);break;case q.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:this._stateDoctypeSystemIdentifierDoubleQuoted(e);break;case q.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:this._stateDoctypeSystemIdentifierSingleQuoted(e);break;case q.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:this._stateAfterDoctypeSystemIdentifier(e);break;case q.BOGUS_DOCTYPE:this._stateBogusDoctype(e);break;case q.CDATA_SECTION:this._stateCdataSection(e);break;case q.CDATA_SECTION_BRACKET:this._stateCdataSectionBracket(e);break;case q.CDATA_SECTION_END:this._stateCdataSectionEnd(e);break;case q.CHARACTER_REFERENCE:this._stateCharacterReference();break;case q.AMBIGUOUS_AMPERSAND:this._stateAmbiguousAmpersand(e);break;default:throw Error(`Unknown state`)}}_stateData(e){switch(e){case V.LESS_THAN_SIGN:this.state=q.TAG_OPEN;break;case V.AMPERSAND:this._startCharacterReference();break;case V.NULL:this._err(H.unexpectedNullCharacter),this._emitCodePoint(e);break;case V.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateRcdata(e){switch(e){case V.AMPERSAND:this._startCharacterReference();break;case V.LESS_THAN_SIGN:this.state=q.RCDATA_LESS_THAN_SIGN;break;case V.NULL:this._err(H.unexpectedNullCharacter),this._emitChars(`�`);break;case V.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateRawtext(e){switch(e){case V.LESS_THAN_SIGN:this.state=q.RAWTEXT_LESS_THAN_SIGN;break;case V.NULL:this._err(H.unexpectedNullCharacter),this._emitChars(`�`);break;case V.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptData(e){switch(e){case V.LESS_THAN_SIGN:this.state=q.SCRIPT_DATA_LESS_THAN_SIGN;break;case V.NULL:this._err(H.unexpectedNullCharacter),this._emitChars(`�`);break;case V.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_statePlaintext(e){switch(e){case V.NULL:this._err(H.unexpectedNullCharacter),this._emitChars(`�`);break;case V.EOF:this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateTagOpen(e){if(hS(e))this._createStartTagToken(),this.state=q.TAG_NAME,this._stateTagName(e);else switch(e){case V.EXCLAMATION_MARK:this.state=q.MARKUP_DECLARATION_OPEN;break;case V.SOLIDUS:this.state=q.END_TAG_OPEN;break;case V.QUESTION_MARK:this._err(H.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=q.BOGUS_COMMENT,this._stateBogusComment(e);break;case V.EOF:this._err(H.eofBeforeTagName),this._emitChars(`<`),this._emitEOFToken();break;default:this._err(H.invalidFirstCharacterOfTagName),this._emitChars(`<`),this.state=q.DATA,this._stateData(e)}}_stateEndTagOpen(e){if(hS(e))this._createEndTagToken(),this.state=q.TAG_NAME,this._stateTagName(e);else switch(e){case V.GREATER_THAN_SIGN:this._err(H.missingEndTagName),this.state=q.DATA;break;case V.EOF:this._err(H.eofBeforeTagName),this._emitChars(`</`),this._emitEOFToken();break;default:this._err(H.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=q.BOGUS_COMMENT,this._stateBogusComment(e)}}_stateTagName(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:this.state=q.BEFORE_ATTRIBUTE_NAME;break;case V.SOLIDUS:this.state=q.SELF_CLOSING_START_TAG;break;case V.GREATER_THAN_SIGN:this.state=q.DATA,this.emitCurrentTagToken();break;case V.NULL:this._err(H.unexpectedNullCharacter),t.tagName+=`�`;break;case V.EOF:this._err(H.eofInTag),this._emitEOFToken();break;default:t.tagName+=String.fromCodePoint(pS(e)?_S(e):e)}}_stateRcdataLessThanSign(e){e===V.SOLIDUS?this.state=q.RCDATA_END_TAG_OPEN:(this._emitChars(`<`),this.state=q.RCDATA,this._stateRcdata(e))}_stateRcdataEndTagOpen(e){hS(e)?(this.state=q.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(e)):(this._emitChars(`</`),this.state=q.RCDATA,this._stateRcdata(e))}handleSpecialEndTag(e){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();let t=this.currentToken;switch(t.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=q.BEFORE_ATTRIBUTE_NAME,!1;case V.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=q.SELF_CLOSING_START_TAG,!1;case V.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=q.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars(`</`),this.state=q.RCDATA,this._stateRcdata(e))}_stateRawtextLessThanSign(e){e===V.SOLIDUS?this.state=q.RAWTEXT_END_TAG_OPEN:(this._emitChars(`<`),this.state=q.RAWTEXT,this._stateRawtext(e))}_stateRawtextEndTagOpen(e){hS(e)?(this.state=q.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(e)):(this._emitChars(`</`),this.state=q.RAWTEXT,this._stateRawtext(e))}_stateRawtextEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars(`</`),this.state=q.RAWTEXT,this._stateRawtext(e))}_stateScriptDataLessThanSign(e){switch(e){case V.SOLIDUS:this.state=q.SCRIPT_DATA_END_TAG_OPEN;break;case V.EXCLAMATION_MARK:this.state=q.SCRIPT_DATA_ESCAPE_START,this._emitChars(`<!`);break;default:this._emitChars(`<`),this.state=q.SCRIPT_DATA,this._stateScriptData(e)}}_stateScriptDataEndTagOpen(e){hS(e)?(this.state=q.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(e)):(this._emitChars(`</`),this.state=q.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars(`</`),this.state=q.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscapeStart(e){e===V.HYPHEN_MINUS?(this.state=q.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars(`-`)):(this.state=q.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscapeStartDash(e){e===V.HYPHEN_MINUS?(this.state=q.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars(`-`)):(this.state=q.SCRIPT_DATA,this._stateScriptData(e))}_stateScriptDataEscaped(e){switch(e){case V.HYPHEN_MINUS:this.state=q.SCRIPT_DATA_ESCAPED_DASH,this._emitChars(`-`);break;case V.LESS_THAN_SIGN:this.state=q.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case V.NULL:this._err(H.unexpectedNullCharacter),this._emitChars(`�`);break;case V.EOF:this._err(H.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptDataEscapedDash(e){switch(e){case V.HYPHEN_MINUS:this.state=q.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars(`-`);break;case V.LESS_THAN_SIGN:this.state=q.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case V.NULL:this._err(H.unexpectedNullCharacter),this.state=q.SCRIPT_DATA_ESCAPED,this._emitChars(`�`);break;case V.EOF:this._err(H.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=q.SCRIPT_DATA_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataEscapedDashDash(e){switch(e){case V.HYPHEN_MINUS:this._emitChars(`-`);break;case V.LESS_THAN_SIGN:this.state=q.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break;case V.GREATER_THAN_SIGN:this.state=q.SCRIPT_DATA,this._emitChars(`>`);break;case V.NULL:this._err(H.unexpectedNullCharacter),this.state=q.SCRIPT_DATA_ESCAPED,this._emitChars(`�`);break;case V.EOF:this._err(H.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=q.SCRIPT_DATA_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataEscapedLessThanSign(e){e===V.SOLIDUS?this.state=q.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:hS(e)?(this._emitChars(`<`),this.state=q.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(e)):(this._emitChars(`<`),this.state=q.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataEscapedEndTagOpen(e){hS(e)?(this.state=q.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(e)):(this._emitChars(`</`),this.state=q.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataEscapedEndTagName(e){this.handleSpecialEndTag(e)&&(this._emitChars(`</`),this.state=q.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataDoubleEscapeStart(e){if(this.preprocessor.startsWith(Lx.SCRIPT,!1)&&yS(this.preprocessor.peek(Lx.SCRIPT.length))){this._emitCodePoint(e);for(let e=0;e<Lx.SCRIPT.length;e++)this._emitCodePoint(this._consume());this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=q.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(e))}_stateScriptDataDoubleEscaped(e){switch(e){case V.HYPHEN_MINUS:this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars(`-`);break;case V.LESS_THAN_SIGN:this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars(`<`);break;case V.NULL:this._err(H.unexpectedNullCharacter),this._emitChars(`�`);break;case V.EOF:this._err(H.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedDash(e){switch(e){case V.HYPHEN_MINUS:this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars(`-`);break;case V.LESS_THAN_SIGN:this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars(`<`);break;case V.NULL:this._err(H.unexpectedNullCharacter),this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(`�`);break;case V.EOF:this._err(H.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedDashDash(e){switch(e){case V.HYPHEN_MINUS:this._emitChars(`-`);break;case V.LESS_THAN_SIGN:this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars(`<`);break;case V.GREATER_THAN_SIGN:this.state=q.SCRIPT_DATA,this._emitChars(`>`);break;case V.NULL:this._err(H.unexpectedNullCharacter),this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(`�`);break;case V.EOF:this._err(H.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break;default:this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(e)}}_stateScriptDataDoubleEscapedLessThanSign(e){e===V.SOLIDUS?(this.state=q.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars(`/`)):(this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(e))}_stateScriptDataDoubleEscapeEnd(e){if(this.preprocessor.startsWith(Lx.SCRIPT,!1)&&yS(this.preprocessor.peek(Lx.SCRIPT.length))){this._emitCodePoint(e);for(let e=0;e<Lx.SCRIPT.length;e++)this._emitCodePoint(this._consume());this.state=q.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=q.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(e))}_stateBeforeAttributeName(e){switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.SOLIDUS:case V.GREATER_THAN_SIGN:case V.EOF:this.state=q.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(e);break;case V.EQUALS_SIGN:this._err(H.unexpectedEqualsSignBeforeAttributeName),this._createAttr(`=`),this.state=q.ATTRIBUTE_NAME;break;default:this._createAttr(``),this.state=q.ATTRIBUTE_NAME,this._stateAttributeName(e)}}_stateAttributeName(e){switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:case V.SOLIDUS:case V.GREATER_THAN_SIGN:case V.EOF:this._leaveAttrName(),this.state=q.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(e);break;case V.EQUALS_SIGN:this._leaveAttrName(),this.state=q.BEFORE_ATTRIBUTE_VALUE;break;case V.QUOTATION_MARK:case V.APOSTROPHE:case V.LESS_THAN_SIGN:this._err(H.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(e);break;case V.NULL:this._err(H.unexpectedNullCharacter),this.currentAttr.name+=`�`;break;default:this.currentAttr.name+=String.fromCodePoint(pS(e)?_S(e):e)}}_stateAfterAttributeName(e){switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.SOLIDUS:this.state=q.SELF_CLOSING_START_TAG;break;case V.EQUALS_SIGN:this.state=q.BEFORE_ATTRIBUTE_VALUE;break;case V.GREATER_THAN_SIGN:this.state=q.DATA,this.emitCurrentTagToken();break;case V.EOF:this._err(H.eofInTag),this._emitEOFToken();break;default:this._createAttr(``),this.state=q.ATTRIBUTE_NAME,this._stateAttributeName(e)}}_stateBeforeAttributeValue(e){switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.QUOTATION_MARK:this.state=q.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break;case V.APOSTROPHE:this.state=q.ATTRIBUTE_VALUE_SINGLE_QUOTED;break;case V.GREATER_THAN_SIGN:this._err(H.missingAttributeValue),this.state=q.DATA,this.emitCurrentTagToken();break;default:this.state=q.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(e)}}_stateAttributeValueDoubleQuoted(e){switch(e){case V.QUOTATION_MARK:this.state=q.AFTER_ATTRIBUTE_VALUE_QUOTED;break;case V.AMPERSAND:this._startCharacterReference();break;case V.NULL:this._err(H.unexpectedNullCharacter),this.currentAttr.value+=`�`;break;case V.EOF:this._err(H.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAttributeValueSingleQuoted(e){switch(e){case V.APOSTROPHE:this.state=q.AFTER_ATTRIBUTE_VALUE_QUOTED;break;case V.AMPERSAND:this._startCharacterReference();break;case V.NULL:this._err(H.unexpectedNullCharacter),this.currentAttr.value+=`�`;break;case V.EOF:this._err(H.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAttributeValueUnquoted(e){switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:this._leaveAttrValue(),this.state=q.BEFORE_ATTRIBUTE_NAME;break;case V.AMPERSAND:this._startCharacterReference();break;case V.GREATER_THAN_SIGN:this._leaveAttrValue(),this.state=q.DATA,this.emitCurrentTagToken();break;case V.NULL:this._err(H.unexpectedNullCharacter),this.currentAttr.value+=`�`;break;case V.QUOTATION_MARK:case V.APOSTROPHE:case V.LESS_THAN_SIGN:case V.EQUALS_SIGN:case V.GRAVE_ACCENT:this._err(H.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(e);break;case V.EOF:this._err(H.eofInTag),this._emitEOFToken();break;default:this.currentAttr.value+=String.fromCodePoint(e)}}_stateAfterAttributeValueQuoted(e){switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:this._leaveAttrValue(),this.state=q.BEFORE_ATTRIBUTE_NAME;break;case V.SOLIDUS:this._leaveAttrValue(),this.state=q.SELF_CLOSING_START_TAG;break;case V.GREATER_THAN_SIGN:this._leaveAttrValue(),this.state=q.DATA,this.emitCurrentTagToken();break;case V.EOF:this._err(H.eofInTag),this._emitEOFToken();break;default:this._err(H.missingWhitespaceBetweenAttributes),this.state=q.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(e)}}_stateSelfClosingStartTag(e){switch(e){case V.GREATER_THAN_SIGN:{let e=this.currentToken;e.selfClosing=!0,this.state=q.DATA,this.emitCurrentTagToken();break}case V.EOF:this._err(H.eofInTag),this._emitEOFToken();break;default:this._err(H.unexpectedSolidusInTag),this.state=q.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(e)}}_stateBogusComment(e){let t=this.currentToken;switch(e){case V.GREATER_THAN_SIGN:this.state=q.DATA,this.emitCurrentComment(t);break;case V.EOF:this.emitCurrentComment(t),this._emitEOFToken();break;case V.NULL:this._err(H.unexpectedNullCharacter),t.data+=`�`;break;default:t.data+=String.fromCodePoint(e)}}_stateMarkupDeclarationOpen(e){this._consumeSequenceIfMatch(Lx.DASH_DASH,!0)?(this._createCommentToken(Lx.DASH_DASH.length+1),this.state=q.COMMENT_START):this._consumeSequenceIfMatch(Lx.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(Lx.DOCTYPE.length+1),this.state=q.DOCTYPE):this._consumeSequenceIfMatch(Lx.CDATA_START,!0)?this.inForeignNode?this.state=q.CDATA_SECTION:(this._err(H.cdataInHtmlContent),this._createCommentToken(Lx.CDATA_START.length+1),this.currentToken.data=`[CDATA[`,this.state=q.BOGUS_COMMENT):this._ensureHibernation()||(this._err(H.incorrectlyOpenedComment),this._createCommentToken(2),this.state=q.BOGUS_COMMENT,this._stateBogusComment(e))}_stateCommentStart(e){switch(e){case V.HYPHEN_MINUS:this.state=q.COMMENT_START_DASH;break;case V.GREATER_THAN_SIGN:{this._err(H.abruptClosingOfEmptyComment),this.state=q.DATA;let e=this.currentToken;this.emitCurrentComment(e);break}default:this.state=q.COMMENT,this._stateComment(e)}}_stateCommentStartDash(e){let t=this.currentToken;switch(e){case V.HYPHEN_MINUS:this.state=q.COMMENT_END;break;case V.GREATER_THAN_SIGN:this._err(H.abruptClosingOfEmptyComment),this.state=q.DATA,this.emitCurrentComment(t);break;case V.EOF:this._err(H.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=`-`,this.state=q.COMMENT,this._stateComment(e)}}_stateComment(e){let t=this.currentToken;switch(e){case V.HYPHEN_MINUS:this.state=q.COMMENT_END_DASH;break;case V.LESS_THAN_SIGN:t.data+=`<`,this.state=q.COMMENT_LESS_THAN_SIGN;break;case V.NULL:this._err(H.unexpectedNullCharacter),t.data+=`�`;break;case V.EOF:this._err(H.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=String.fromCodePoint(e)}}_stateCommentLessThanSign(e){let t=this.currentToken;switch(e){case V.EXCLAMATION_MARK:t.data+=`!`,this.state=q.COMMENT_LESS_THAN_SIGN_BANG;break;case V.LESS_THAN_SIGN:t.data+=`<`;break;default:this.state=q.COMMENT,this._stateComment(e)}}_stateCommentLessThanSignBang(e){e===V.HYPHEN_MINUS?this.state=q.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=q.COMMENT,this._stateComment(e))}_stateCommentLessThanSignBangDash(e){e===V.HYPHEN_MINUS?this.state=q.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=q.COMMENT_END_DASH,this._stateCommentEndDash(e))}_stateCommentLessThanSignBangDashDash(e){e!==V.GREATER_THAN_SIGN&&e!==V.EOF&&this._err(H.nestedComment),this.state=q.COMMENT_END,this._stateCommentEnd(e)}_stateCommentEndDash(e){let t=this.currentToken;switch(e){case V.HYPHEN_MINUS:this.state=q.COMMENT_END;break;case V.EOF:this._err(H.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=`-`,this.state=q.COMMENT,this._stateComment(e)}}_stateCommentEnd(e){let t=this.currentToken;switch(e){case V.GREATER_THAN_SIGN:this.state=q.DATA,this.emitCurrentComment(t);break;case V.EXCLAMATION_MARK:this.state=q.COMMENT_END_BANG;break;case V.HYPHEN_MINUS:t.data+=`-`;break;case V.EOF:this._err(H.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=`--`,this.state=q.COMMENT,this._stateComment(e)}}_stateCommentEndBang(e){let t=this.currentToken;switch(e){case V.HYPHEN_MINUS:t.data+=`--!`,this.state=q.COMMENT_END_DASH;break;case V.GREATER_THAN_SIGN:this._err(H.incorrectlyClosedComment),this.state=q.DATA,this.emitCurrentComment(t);break;case V.EOF:this._err(H.eofInComment),this.emitCurrentComment(t),this._emitEOFToken();break;default:t.data+=`--!`,this.state=q.COMMENT,this._stateComment(e)}}_stateDoctype(e){switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:this.state=q.BEFORE_DOCTYPE_NAME;break;case V.GREATER_THAN_SIGN:this.state=q.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(e);break;case V.EOF:{this._err(H.eofInDoctype),this._createDoctypeToken(null);let e=this.currentToken;e.forceQuirks=!0,this.emitCurrentDoctype(e),this._emitEOFToken();break}default:this._err(H.missingWhitespaceBeforeDoctypeName),this.state=q.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(e)}}_stateBeforeDoctypeName(e){if(pS(e))this._createDoctypeToken(String.fromCharCode(_S(e))),this.state=q.DOCTYPE_NAME;else switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.NULL:this._err(H.unexpectedNullCharacter),this._createDoctypeToken(`�`),this.state=q.DOCTYPE_NAME;break;case V.GREATER_THAN_SIGN:{this._err(H.missingDoctypeName),this._createDoctypeToken(null);let e=this.currentToken;e.forceQuirks=!0,this.emitCurrentDoctype(e),this.state=q.DATA;break}case V.EOF:{this._err(H.eofInDoctype),this._createDoctypeToken(null);let e=this.currentToken;e.forceQuirks=!0,this.emitCurrentDoctype(e),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(e)),this.state=q.DOCTYPE_NAME}}_stateDoctypeName(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:this.state=q.AFTER_DOCTYPE_NAME;break;case V.GREATER_THAN_SIGN:this.state=q.DATA,this.emitCurrentDoctype(t);break;case V.NULL:this._err(H.unexpectedNullCharacter),t.name+=`�`;break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.name+=String.fromCodePoint(pS(e)?_S(e):e)}}_stateAfterDoctypeName(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.GREATER_THAN_SIGN:this.state=q.DATA,this.emitCurrentDoctype(t);break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._consumeSequenceIfMatch(Lx.PUBLIC,!1)?this.state=q.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(Lx.SYSTEM,!1)?this.state=q.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(H.invalidCharacterSequenceAfterDoctypeName),t.forceQuirks=!0,this.state=q.BOGUS_DOCTYPE,this._stateBogusDoctype(e))}}_stateAfterDoctypePublicKeyword(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:this.state=q.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break;case V.QUOTATION_MARK:this._err(H.missingWhitespaceAfterDoctypePublicKeyword),t.publicId=``,this.state=q.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break;case V.APOSTROPHE:this._err(H.missingWhitespaceAfterDoctypePublicKeyword),t.publicId=``,this.state=q.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break;case V.GREATER_THAN_SIGN:this._err(H.missingDoctypePublicIdentifier),t.forceQuirks=!0,this.state=q.DATA,this.emitCurrentDoctype(t);break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(H.missingQuoteBeforeDoctypePublicIdentifier),t.forceQuirks=!0,this.state=q.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBeforeDoctypePublicIdentifier(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.QUOTATION_MARK:t.publicId=``,this.state=q.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break;case V.APOSTROPHE:t.publicId=``,this.state=q.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break;case V.GREATER_THAN_SIGN:this._err(H.missingDoctypePublicIdentifier),t.forceQuirks=!0,this.state=q.DATA,this.emitCurrentDoctype(t);break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(H.missingQuoteBeforeDoctypePublicIdentifier),t.forceQuirks=!0,this.state=q.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateDoctypePublicIdentifierDoubleQuoted(e){let t=this.currentToken;switch(e){case V.QUOTATION_MARK:this.state=q.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break;case V.NULL:this._err(H.unexpectedNullCharacter),t.publicId+=`�`;break;case V.GREATER_THAN_SIGN:this._err(H.abruptDoctypePublicIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=q.DATA;break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.publicId+=String.fromCodePoint(e)}}_stateDoctypePublicIdentifierSingleQuoted(e){let t=this.currentToken;switch(e){case V.APOSTROPHE:this.state=q.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break;case V.NULL:this._err(H.unexpectedNullCharacter),t.publicId+=`�`;break;case V.GREATER_THAN_SIGN:this._err(H.abruptDoctypePublicIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=q.DATA;break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.publicId+=String.fromCodePoint(e)}}_stateAfterDoctypePublicIdentifier(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:this.state=q.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break;case V.GREATER_THAN_SIGN:this.state=q.DATA,this.emitCurrentDoctype(t);break;case V.QUOTATION_MARK:this._err(H.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),t.systemId=``,this.state=q.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case V.APOSTROPHE:this._err(H.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),t.systemId=``,this.state=q.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(H.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=q.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBetweenDoctypePublicAndSystemIdentifiers(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=q.DATA;break;case V.QUOTATION_MARK:t.systemId=``,this.state=q.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case V.APOSTROPHE:t.systemId=``,this.state=q.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(H.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=q.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateAfterDoctypeSystemKeyword(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:this.state=q.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break;case V.QUOTATION_MARK:this._err(H.missingWhitespaceAfterDoctypeSystemKeyword),t.systemId=``,this.state=q.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case V.APOSTROPHE:this._err(H.missingWhitespaceAfterDoctypeSystemKeyword),t.systemId=``,this.state=q.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case V.GREATER_THAN_SIGN:this._err(H.missingDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=q.DATA,this.emitCurrentDoctype(t);break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(H.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=q.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBeforeDoctypeSystemIdentifier(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.QUOTATION_MARK:t.systemId=``,this.state=q.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break;case V.APOSTROPHE:t.systemId=``,this.state=q.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break;case V.GREATER_THAN_SIGN:this._err(H.missingDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=q.DATA,this.emitCurrentDoctype(t);break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(H.missingQuoteBeforeDoctypeSystemIdentifier),t.forceQuirks=!0,this.state=q.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateDoctypeSystemIdentifierDoubleQuoted(e){let t=this.currentToken;switch(e){case V.QUOTATION_MARK:this.state=q.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break;case V.NULL:this._err(H.unexpectedNullCharacter),t.systemId+=`�`;break;case V.GREATER_THAN_SIGN:this._err(H.abruptDoctypeSystemIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=q.DATA;break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.systemId+=String.fromCodePoint(e)}}_stateDoctypeSystemIdentifierSingleQuoted(e){let t=this.currentToken;switch(e){case V.APOSTROPHE:this.state=q.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break;case V.NULL:this._err(H.unexpectedNullCharacter),t.systemId+=`�`;break;case V.GREATER_THAN_SIGN:this._err(H.abruptDoctypeSystemIdentifier),t.forceQuirks=!0,this.emitCurrentDoctype(t),this.state=q.DATA;break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:t.systemId+=String.fromCodePoint(e)}}_stateAfterDoctypeSystemIdentifier(e){let t=this.currentToken;switch(e){case V.SPACE:case V.LINE_FEED:case V.TABULATION:case V.FORM_FEED:break;case V.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=q.DATA;break;case V.EOF:this._err(H.eofInDoctype),t.forceQuirks=!0,this.emitCurrentDoctype(t),this._emitEOFToken();break;default:this._err(H.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=q.BOGUS_DOCTYPE,this._stateBogusDoctype(e)}}_stateBogusDoctype(e){let t=this.currentToken;switch(e){case V.GREATER_THAN_SIGN:this.emitCurrentDoctype(t),this.state=q.DATA;break;case V.NULL:this._err(H.unexpectedNullCharacter);break;case V.EOF:this.emitCurrentDoctype(t),this._emitEOFToken();break;default:}}_stateCdataSection(e){switch(e){case V.RIGHT_SQUARE_BRACKET:this.state=q.CDATA_SECTION_BRACKET;break;case V.EOF:this._err(H.eofInCdata),this._emitEOFToken();break;default:this._emitCodePoint(e)}}_stateCdataSectionBracket(e){e===V.RIGHT_SQUARE_BRACKET?this.state=q.CDATA_SECTION_END:(this._emitChars(`]`),this.state=q.CDATA_SECTION,this._stateCdataSection(e))}_stateCdataSectionEnd(e){switch(e){case V.GREATER_THAN_SIGN:this.state=q.DATA;break;case V.RIGHT_SQUARE_BRACKET:this._emitChars(`]`);break;default:this._emitChars(`]]`),this.state=q.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(V.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&gS(this.preprocessor.peek(1))?q.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(e){gS(e)?this._flushCodePointConsumedAsCharacterReference(e):(e===V.SEMICOLON&&this._err(H.unknownNamedCharacterReference),this.state=this.returnState,this._callState(e))}};const SS=new Set([G.DD,G.DT,G.LI,G.OPTGROUP,G.OPTION,G.P,G.RB,G.RP,G.RT,G.RTC]),CS=new Set([...SS,G.CAPTION,G.COLGROUP,G.TBODY,G.TD,G.TFOOT,G.TH,G.THEAD,G.TR]),wS=new Set([G.APPLET,G.CAPTION,G.HTML,G.MARQUEE,G.OBJECT,G.TABLE,G.TD,G.TEMPLATE,G.TH]),TS=new Set([...wS,G.OL,G.UL]),ES=new Set([...wS,G.BUTTON]),DS=new Set([G.ANNOTATION_XML,G.MI,G.MN,G.MO,G.MS,G.MTEXT]),OS=new Set([G.DESC,G.FOREIGN_OBJECT,G.TITLE]),kS=new Set([G.TR,G.TEMPLATE,G.HTML]),AS=new Set([G.TBODY,G.TFOOT,G.THEAD,G.TEMPLATE,G.HTML]),jS=new Set([G.TABLE,G.TEMPLATE,G.HTML]),MS=new Set([G.TD,G.TH]);var NS=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=G.UNKNOWN,this.current=e}_indexOf(e){return this.items.lastIndexOf(e,this.stackTop)}_isInTemplate(){return this.currentTagId===G.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===U.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(){let e=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(e,!0)}replace(e,t){let n=this._indexOf(e);this.items[n]=t,n===this.stackTop&&(this.current=t)}insertAfter(e,t,n){let 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])!==U.HTML);this.shortenToLength(Math.max(t,0))}shortenToLength(e){for(;this.stackTop>=e;){let t=this.current;this.tmplCount>0&&this._isInTemplate()&&--this.tmplCount,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,this.stackTop<e)}}popUntilElementPopped(e){let t=this._indexOf(e);this.shortenToLength(Math.max(t,0))}popUntilPopped(e,t){let n=this._indexOfTagNames(e,t);this.shortenToLength(Math.max(n,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(uS,U.HTML)}popUntilTableCellPopped(){this.popUntilPopped(MS,U.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){let n=this._indexOfTagNames(e,t);this.shortenToLength(n+1)}clearBackToTableContext(){this.clearBackTo(jS,U.HTML)}clearBackToTableBodyContext(){this.clearBackTo(AS,U.HTML)}clearBackToTableRowContext(){this.clearBackTo(kS,U.HTML)}remove(e){let 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]===G.BODY?this.items[1]:null}contains(e){return this._indexOf(e)>-1}getCommonAncestor(e){let t=this._indexOf(e)-1;return t>=0?this.items[t]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===G.HTML}hasInDynamicScope(e,t){for(let n=this.stackTop;n>=0;n--){let r=this.tagIDs[n];switch(this.treeAdapter.getNamespaceURI(this.items[n])){case U.HTML:if(r===e)return!0;if(t.has(r))return!1;break;case U.SVG:if(OS.has(r))return!1;break;case U.MATHML:if(DS.has(r))return!1;break}}return!0}hasInScope(e){return this.hasInDynamicScope(e,wS)}hasInListItemScope(e){return this.hasInDynamicScope(e,TS)}hasInButtonScope(e){return this.hasInDynamicScope(e,ES)}hasNumberedHeaderInScope(){for(let e=this.stackTop;e>=0;e--){let t=this.tagIDs[e];switch(this.treeAdapter.getNamespaceURI(this.items[e])){case U.HTML:if(uS.has(t))return!0;if(wS.has(t))return!1;break;case U.SVG:if(OS.has(t))return!1;break;case U.MATHML:if(DS.has(t))return!1;break}}return!0}hasInTableScope(e){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===U.HTML)switch(this.tagIDs[t]){case e:return!0;case G.TABLE:case G.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let e=this.stackTop;e>=0;e--)if(this.treeAdapter.getNamespaceURI(this.items[e])===U.HTML)switch(this.tagIDs[e]){case G.TBODY:case G.THEAD:case G.TFOOT:return!0;case G.TABLE:case G.HTML:return!1}return!0}hasInSelectScope(e){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===U.HTML)switch(this.tagIDs[t]){case e:return!0;case G.OPTION:case G.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&SS.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&CS.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(e){for(;this.currentTagId!==void 0&&this.currentTagId!==e&&CS.has(this.currentTagId);)this.pop()}},PS;(function(e){e[e.Marker=0]=`Marker`,e[e.Element=1]=`Element`})(PS||={});const FS={type:PS.Marker};var IS=class{constructor(e){this.treeAdapter=e,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(e,t){let n=[],r=t.length,i=this.treeAdapter.getTagName(e),a=this.treeAdapter.getNamespaceURI(e);for(let e=0;e<this.entries.length;e++){let t=this.entries[e];if(t.type===PS.Marker)break;let{element:o}=t;if(this.treeAdapter.getTagName(o)===i&&this.treeAdapter.getNamespaceURI(o)===a){let t=this.treeAdapter.getAttrList(o);t.length===r&&n.push({idx:e,attrs:t})}}return n}_ensureNoahArkCondition(e){if(this.entries.length<3)return;let t=this.treeAdapter.getAttrList(e),n=this._getNoahArkConditionCandidates(e,t);if(n.length<3)return;let r=new Map(t.map(e=>[e.name,e.value])),i=0;for(let e=0;e<n.length;e++){let t=n[e];t.attrs.every(e=>r.get(e.name)===e.value)&&(i+=1,i>=3&&this.entries.splice(t.idx,1))}}insertMarker(){this.entries.unshift(FS)}pushElement(e,t){this._ensureNoahArkCondition(e),this.entries.unshift({type:PS.Element,element:e,token:t})}insertElementAfterBookmark(e,t){let n=this.entries.indexOf(this.bookmark);this.entries.splice(n,0,{type:PS.Element,element:e,token:t})}removeEntry(e){let t=this.entries.indexOf(e);t!==-1&&this.entries.splice(t,1)}clearToLastMarker(){let e=this.entries.indexOf(FS);e===-1?this.entries.length=0:this.entries.splice(0,e+1)}getElementEntryInScopeWithTagName(e){let t=this.entries.find(t=>t.type===PS.Marker||this.treeAdapter.getTagName(t.element)===e);return t&&t.type===PS.Element?t:null}getElementEntry(e){return this.entries.find(t=>t.type===PS.Element&&t.element===e)}};const LS={createDocument(){return{nodeName:`#document`,mode:oS.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){let 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){let i=e.childNodes.find(e=>e.nodeName===`#documentType`);if(i)i.name=t,i.publicId=n,i.systemId=r;else{let i={nodeName:`#documentType`,name:t,publicId:n,systemId:r,parentNode:null};LS.appendChild(e,i)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){let t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){let n=e.childNodes[e.childNodes.length-1];if(LS.isTextNode(n)){n.value+=t;return}}LS.appendChild(e,LS.createTextNode(t))},insertTextBefore(e,t,n){let r=e.childNodes[e.childNodes.indexOf(n)-1];r&&LS.isTextNode(r)?r.value+=t:LS.insertBefore(e,LS.createTextNode(t),n)},adoptAttributes(e,t){let n=new Set(e.attrs.map(e=>e.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}}},RS=`html`,zS=`+//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//`.split(`,`),BS=[...zS,`-//w3c//dtd html 4.01 frameset//`,`-//w3c//dtd html 4.01 transitional//`],VS=new Set([`-//w3o//dtd w3 html strict 3.0//en//`,`-/w3c/dtd html 4.0 transitional/en`,`html`]),HS=[`-//w3c//dtd xhtml 1.0 frameset//`,`-//w3c//dtd xhtml 1.0 transitional//`],US=[...HS,`-//w3c//dtd html 4.01 frameset//`,`-//w3c//dtd html 4.01 transitional//`];function WS(e,t){return t.some(t=>e.startsWith(t))}function GS(e){return e.name===RS&&e.publicId===null&&(e.systemId===null||e.systemId===`about:legacy-compat`)}function KS(e){if(e.name!==RS)return oS.QUIRKS;let{systemId:t}=e;if(t&&t.toLowerCase()===`http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd`)return oS.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),VS.has(n))return oS.QUIRKS;let e=t===null?BS:zS;if(WS(n,e))return oS.QUIRKS;if(e=t===null?HS:US,WS(n,e))return oS.LIMITED_QUIRKS}return oS.NO_QUIRKS}const qS={TEXT_HTML:`text/html`,APPLICATION_XML:`application/xhtml+xml`},JS=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`.split(`.`).map(e=>[e.toLowerCase(),e])),YS=new Map([[`xlink:actuate`,{prefix:`xlink`,name:`actuate`,namespace:U.XLINK}],[`xlink:arcrole`,{prefix:`xlink`,name:`arcrole`,namespace:U.XLINK}],[`xlink:href`,{prefix:`xlink`,name:`href`,namespace:U.XLINK}],[`xlink:role`,{prefix:`xlink`,name:`role`,namespace:U.XLINK}],[`xlink:show`,{prefix:`xlink`,name:`show`,namespace:U.XLINK}],[`xlink:title`,{prefix:`xlink`,name:`title`,namespace:U.XLINK}],[`xlink:type`,{prefix:`xlink`,name:`type`,namespace:U.XLINK}],[`xml:lang`,{prefix:`xml`,name:`lang`,namespace:U.XML}],[`xml:space`,{prefix:`xml`,name:`space`,namespace:U.XML}],[`xmlns`,{prefix:``,name:`xmlns`,namespace:U.XMLNS}],[`xmlns:xlink`,{prefix:`xmlns`,name:`xlink`,namespace:U.XMLNS}]]),XS=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`.split(`.`).map(e=>[e.toLowerCase(),e])),ZS=new Set([G.B,G.BIG,G.BLOCKQUOTE,G.BODY,G.BR,G.CENTER,G.CODE,G.DD,G.DIV,G.DL,G.DT,G.EM,G.EMBED,G.H1,G.H2,G.H3,G.H4,G.H5,G.H6,G.HEAD,G.HR,G.I,G.IMG,G.LI,G.LISTING,G.MENU,G.META,G.NOBR,G.OL,G.P,G.PRE,G.RUBY,G.S,G.SMALL,G.SPAN,G.STRONG,G.STRIKE,G.SUB,G.SUP,G.TABLE,G.TT,G.U,G.UL,G.VAR]);function QS(e){let t=e.tagID;return t===G.FONT&&e.attrs.some(({name:e})=>e===aS.COLOR||e===aS.SIZE||e===aS.FACE)||ZS.has(t)}function $S(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===`definitionurl`){e.attrs[t].name=`definitionURL`;break}}function eC(e){for(let t=0;t<e.attrs.length;t++){let n=JS.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function tC(e){for(let t=0;t<e.attrs.length;t++){let n=YS.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 nC(e){let t=XS.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=cS(e.tagName))}function rC(e,t){return t===U.MATHML&&(e===G.MI||e===G.MO||e===G.MN||e===G.MS||e===G.MTEXT)}function iC(e,t,n){if(t===U.MATHML&&e===G.ANNOTATION_XML){for(let e=0;e<n.length;e++)if(n[e].name===aS.ENCODING){let t=n[e].value.toLowerCase();return t===qS.TEXT_HTML||t===qS.APPLICATION_XML}}return t===U.SVG&&(e===G.FOREIGN_OBJECT||e===G.DESC||e===G.TITLE)}function aC(e,t,n,r){return(!r||r===U.HTML)&&iC(e,t,n)||(!r||r===U.MATHML)&&rC(e,t)}var J;(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`})(J||={});const oC={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},sC=new Set([G.TABLE,G.TBODY,G.TFOOT,G.THEAD,G.TR]),cC={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:LS,onParseError:null};var lC=class{constructor(e,t,n=null,r=null){this.fragmentContext=n,this.scriptHandler=r,this.currentToken=null,this.stopped=!1,this.insertionMode=J.INITIAL,this.originalInsertionMode=J.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={...cC,...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 xS(this.options,this),this.activeFormattingElements=new IS(this.treeAdapter),this.fragmentContextID=n?cS(this.treeAdapter.getTagName(n)):G.UNKNOWN,this._setContextModes(n??this.document,this.fragmentContextID),this.openElements=new NS(this.document,this.treeAdapter,this)}static parse(e,t){let n=new this(t);return n.tokenizer.write(e,!0),n.document}static getFragmentParser(e,t){let n={...cC,...t};e??=n.treeAdapter.createElement(W.TEMPLATE,U.HTML,[]);let r=n.treeAdapter.createElement(`documentmock`,U.HTML,[]),i=new this(n,r,e);return i.fragmentContextID===G.TEMPLATE&&i.tmplInsertionModeStack.unshift(J.IN_TEMPLATE),i._initTokenizerForFragmentParsing(),i._insertFakeRootElement(),i._resetInsertionMode(),i._findFormInFragmentContext(),i}getFragment(){let e=this.treeAdapter.getFirstChild(this.document),t=this.treeAdapter.createDocumentFragment();return this._adoptNodes(e,t),t}_err(e,t,n){if(!this.onParseError)return;let r=e.location??oC,i={code:t,startLine:r.startLine,startCol:r.startCol,startOffset:r.startOffset,endLine:n?r.startLine:r.endLine,endCol:n?r.startCol:r.endCol,endOffset:n?r.startOffset:r.endOffset};this.onParseError(i)}onItemPush(e,t,n){var r,i;(i=(r=this.treeAdapter).onItemPush)==null||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.call(n,e,this.openElements.current),t){let e,t;this.openElements.stackTop===0&&this.fragmentContext?(e=this.fragmentContext,t=this.fragmentContextID):{current:e,currentTagId:t}=this.openElements,this._setContextModes(e,t)}}_setContextModes(e,t){let n=e===this.document||e&&this.treeAdapter.getNamespaceURI(e)===U.HTML;this.currentNotInHTML=!n,this.tokenizer.inForeignNode=!n&&e!==void 0&&t!==void 0&&!this._isIntegrationPoint(t,e)}_switchToTextParsing(e,t){this._insertElement(e,U.HTML),this.tokenizer.state=t,this.originalInsertionMode=this.insertionMode,this.insertionMode=J.TEXT}switchToPlaintextParsing(){this.insertionMode=J.TEXT,this.originalInsertionMode=J.IN_BODY,this.tokenizer.state=dS.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)===W.FORM){this.formElement=e;break}e=this.treeAdapter.getParentNode(e)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==U.HTML))switch(this.fragmentContextID){case G.TITLE:case G.TEXTAREA:this.tokenizer.state=dS.RCDATA;break;case G.STYLE:case G.XMP:case G.IFRAME:case G.NOEMBED:case G.NOFRAMES:case G.NOSCRIPT:this.tokenizer.state=dS.RAWTEXT;break;case G.SCRIPT:this.tokenizer.state=dS.SCRIPT_DATA;break;case G.PLAINTEXT:this.tokenizer.state=dS.PLAINTEXT;break;default:}}_setDocumentType(e){let t=e.name||``,n=e.publicId||``,r=e.systemId||``;if(this.treeAdapter.setDocumentType(this.document,t,n,r),e.location){let t=this.treeAdapter.getChildNodes(this.document).find(e=>this.treeAdapter.isDocumentTypeNode(e));t&&this.treeAdapter.setNodeSourceCodeLocation(t,e.location)}}_attachElementToTree(e,t){if(this.options.sourceCodeLocationInfo){let n=t&&{...t,startTag:t};this.treeAdapter.setNodeSourceCodeLocation(e,n)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(e);else{let t=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(t??this.document,e)}}_appendElement(e,t){let n=this.treeAdapter.createElement(e.tagName,t,e.attrs);this._attachElementToTree(n,e.location)}_insertElement(e,t){let n=this.treeAdapter.createElement(e.tagName,t,e.attrs);this._attachElementToTree(n,e.location),this.openElements.push(n,e.tagID)}_insertFakeElement(e,t){let n=this.treeAdapter.createElement(e,U.HTML,[]);this._attachElementToTree(n,null),this.openElements.push(n,t)}_insertTemplate(e){let t=this.treeAdapter.createElement(e.tagName,U.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(){let e=this.treeAdapter.createElement(W.HTML,U.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(e,null),this.treeAdapter.appendChild(this.openElements.current,e),this.openElements.push(e,G.HTML)}_appendCommentNode(e,t){let 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;let r=this.treeAdapter.getChildNodes(t),i=r[(n?r.lastIndexOf(n):r.length)-1];if(this.treeAdapter.getNodeSourceCodeLocation(i)){let{endLine:t,endCol:n,endOffset:r}=e.location;this.treeAdapter.updateNodeSourceCodeLocation(i,{endLine:t,endCol:n,endOffset:r})}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){let n=t.location,r=this.treeAdapter.getTagName(e),i=t.type===Wx.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===G.SVG&&this.treeAdapter.getTagName(t)===W.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(t)===U.MATHML?!1:this.tokenizer.inForeignNode||(e.tagID===G.MGLYPH||e.tagID===G.MALIGNMARK)&&n!==void 0&&!this._isIntegrationPoint(n,t,U.HTML)}_processToken(e){switch(e.type){case Wx.CHARACTER:this.onCharacter(e);break;case Wx.NULL_CHARACTER:this.onNullCharacter(e);break;case Wx.COMMENT:this.onComment(e);break;case Wx.DOCTYPE:this.onDoctype(e);break;case Wx.START_TAG:this._processStartTag(e);break;case Wx.END_TAG:this.onEndTag(e);break;case Wx.EOF:this.onEof(e);break;case Wx.WHITESPACE_CHARACTER:this.onWhitespaceCharacter(e);break}}_isIntegrationPoint(e,t,n){return aC(e,this.treeAdapter.getNamespaceURI(t),this.treeAdapter.getAttrList(t),n)}_reconstructActiveFormattingElements(){let e=this.activeFormattingElements.entries.length;if(e){let t=this.activeFormattingElements.entries.findIndex(e=>e.type===PS.Marker||this.openElements.contains(e.element)),n=t===-1?e-1:t-1;for(let e=n;e>=0;e--){let t=this.activeFormattingElements.entries[e];this._insertElement(t.token,this.treeAdapter.getNamespaceURI(t.element)),t.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=J.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(G.P),this.openElements.popUntilTagNamePopped(G.P)}_resetInsertionMode(){for(let e=this.openElements.stackTop;e>=0;e--)switch(e===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[e]){case G.TR:this.insertionMode=J.IN_ROW;return;case G.TBODY:case G.THEAD:case G.TFOOT:this.insertionMode=J.IN_TABLE_BODY;return;case G.CAPTION:this.insertionMode=J.IN_CAPTION;return;case G.COLGROUP:this.insertionMode=J.IN_COLUMN_GROUP;return;case G.TABLE:this.insertionMode=J.IN_TABLE;return;case G.BODY:this.insertionMode=J.IN_BODY;return;case G.FRAMESET:this.insertionMode=J.IN_FRAMESET;return;case G.SELECT:this._resetInsertionModeForSelect(e);return;case G.TEMPLATE:this.insertionMode=this.tmplInsertionModeStack[0];return;case G.HTML:this.insertionMode=this.headElement?J.AFTER_HEAD:J.BEFORE_HEAD;return;case G.TD:case G.TH:if(e>0){this.insertionMode=J.IN_CELL;return}break;case G.HEAD:if(e>0){this.insertionMode=J.IN_HEAD;return}break}this.insertionMode=J.IN_BODY}_resetInsertionModeForSelect(e){if(e>0)for(let t=e-1;t>0;t--){let e=this.openElements.tagIDs[t];if(e===G.TEMPLATE)break;if(e===G.TABLE){this.insertionMode=J.IN_SELECT_IN_TABLE;return}}this.insertionMode=J.IN_SELECT}_isElementCausesFosterParenting(e){return sC.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--){let t=this.openElements.items[e];switch(this.openElements.tagIDs[e]){case G.TEMPLATE:if(this.treeAdapter.getNamespaceURI(t)===U.HTML)return{parent:this.treeAdapter.getTemplateContent(t),beforeElement:null};break;case G.TABLE:{let 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){let t=this._findFosterParentingLocation();t.beforeElement?this.treeAdapter.insertBefore(t.parent,e,t.beforeElement):this.treeAdapter.appendChild(t.parent,e)}_isSpecialElement(e,t){return lS[this.treeAdapter.getNamespaceURI(e)].has(t)}onCharacter(e){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){DT(this,e);return}switch(this.insertionMode){case J.INITIAL:SC(this,e);break;case J.BEFORE_HTML:TC(this,e);break;case J.BEFORE_HEAD:OC(this,e);break;case J.IN_HEAD:MC(this,e);break;case J.IN_HEAD_NO_SCRIPT:FC(this,e);break;case J.AFTER_HEAD:RC(this,e);break;case J.IN_BODY:case J.IN_CAPTION:case J.IN_CELL:case J.IN_TEMPLATE:VC(this,e);break;case J.TEXT:case J.IN_SELECT:case J.IN_SELECT_IN_TABLE:this._insertCharacters(e);break;case J.IN_TABLE:case J.IN_TABLE_BODY:case J.IN_ROW:Iw(this,e);break;case J.IN_TABLE_TEXT:Yw(this,e);break;case J.IN_COLUMN_GROUP:nT(this,e);break;case J.AFTER_BODY:vT(this,e);break;case J.AFTER_AFTER_BODY:wT(this,e);break;default:}}onNullCharacter(e){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){ET(this,e);return}switch(this.insertionMode){case J.INITIAL:SC(this,e);break;case J.BEFORE_HTML:TC(this,e);break;case J.BEFORE_HEAD:OC(this,e);break;case J.IN_HEAD:MC(this,e);break;case J.IN_HEAD_NO_SCRIPT:FC(this,e);break;case J.AFTER_HEAD:RC(this,e);break;case J.TEXT:this._insertCharacters(e);break;case J.IN_TABLE:case J.IN_TABLE_BODY:case J.IN_ROW:Iw(this,e);break;case J.IN_COLUMN_GROUP:nT(this,e);break;case J.AFTER_BODY:vT(this,e);break;case J.AFTER_AFTER_BODY:wT(this,e);break;default:}}onComment(e){if(this.skipNextNewLine=!1,this.currentNotInHTML){_C(this,e);return}switch(this.insertionMode){case J.INITIAL:case J.BEFORE_HTML:case J.BEFORE_HEAD:case J.IN_HEAD:case J.IN_HEAD_NO_SCRIPT:case J.AFTER_HEAD:case J.IN_BODY:case J.IN_TABLE:case J.IN_CAPTION:case J.IN_COLUMN_GROUP:case J.IN_TABLE_BODY:case J.IN_ROW:case J.IN_CELL:case J.IN_SELECT:case J.IN_SELECT_IN_TABLE:case J.IN_TEMPLATE:case J.IN_FRAMESET:case J.AFTER_FRAMESET:_C(this,e);break;case J.IN_TABLE_TEXT:Xw(this,e);break;case J.AFTER_BODY:vC(this,e);break;case J.AFTER_AFTER_BODY:case J.AFTER_AFTER_FRAMESET:yC(this,e);break;default:}}onDoctype(e){switch(this.skipNextNewLine=!1,this.insertionMode){case J.INITIAL:xC(this,e);break;case J.BEFORE_HEAD:case J.IN_HEAD:case J.IN_HEAD_NO_SCRIPT:case J.AFTER_HEAD:this._err(e,H.misplacedDoctype);break;case J.IN_TABLE_TEXT:Xw(this,e);break;default:}}onStartTag(e){this.skipNextNewLine=!1,this.currentToken=e,this._processStartTag(e),e.selfClosing&&!e.ackSelfClosing&&this._err(e,H.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(e){this.shouldProcessStartTagTokenInForeignContent(e)?kT(this,e):this._startTagOutsideForeignContent(e)}_startTagOutsideForeignContent(e){switch(this.insertionMode){case J.INITIAL:SC(this,e);break;case J.BEFORE_HTML:CC(this,e);break;case J.BEFORE_HEAD:EC(this,e);break;case J.IN_HEAD:kC(this,e);break;case J.IN_HEAD_NO_SCRIPT:NC(this,e);break;case J.AFTER_HEAD:IC(this,e);break;case J.IN_BODY:bw(this,e);break;case J.IN_TABLE:Gw(this,e);break;case J.IN_TABLE_TEXT:Xw(this,e);break;case J.IN_CAPTION:Qw(this,e);break;case J.IN_COLUMN_GROUP:eT(this,e);break;case J.IN_TABLE_BODY:rT(this,e);break;case J.IN_ROW:aT(this,e);break;case J.IN_CELL:sT(this,e);break;case J.IN_SELECT:lT(this,e);break;case J.IN_SELECT_IN_TABLE:dT(this,e);break;case J.IN_TEMPLATE:pT(this,e);break;case J.AFTER_BODY:gT(this,e);break;case J.IN_FRAMESET:yT(this,e);break;case J.AFTER_FRAMESET:xT(this,e);break;case J.AFTER_AFTER_BODY:CT(this,e);break;case J.AFTER_AFTER_FRAMESET:TT(this,e);break;default:}}onEndTag(e){this.skipNextNewLine=!1,this.currentToken=e,this.currentNotInHTML?AT(this,e):this._endTagOutsideForeignContent(e)}_endTagOutsideForeignContent(e){switch(this.insertionMode){case J.INITIAL:SC(this,e);break;case J.BEFORE_HTML:wC(this,e);break;case J.BEFORE_HEAD:DC(this,e);break;case J.IN_HEAD:AC(this,e);break;case J.IN_HEAD_NO_SCRIPT:PC(this,e);break;case J.AFTER_HEAD:LC(this,e);break;case J.IN_BODY:Mw(this,e);break;case J.TEXT:Pw(this,e);break;case J.IN_TABLE:Kw(this,e);break;case J.IN_TABLE_TEXT:Xw(this,e);break;case J.IN_CAPTION:$w(this,e);break;case J.IN_COLUMN_GROUP:tT(this,e);break;case J.IN_TABLE_BODY:iT(this,e);break;case J.IN_ROW:oT(this,e);break;case J.IN_CELL:cT(this,e);break;case J.IN_SELECT:uT(this,e);break;case J.IN_SELECT_IN_TABLE:fT(this,e);break;case J.IN_TEMPLATE:mT(this,e);break;case J.AFTER_BODY:_T(this,e);break;case J.IN_FRAMESET:bT(this,e);break;case J.AFTER_FRAMESET:ST(this,e);break;case J.AFTER_AFTER_BODY:wT(this,e);break;default:}}onEof(e){switch(this.insertionMode){case J.INITIAL:SC(this,e);break;case J.BEFORE_HTML:TC(this,e);break;case J.BEFORE_HEAD:OC(this,e);break;case J.IN_HEAD:MC(this,e);break;case J.IN_HEAD_NO_SCRIPT:FC(this,e);break;case J.AFTER_HEAD:RC(this,e);break;case J.IN_BODY:case J.IN_TABLE:case J.IN_CAPTION:case J.IN_COLUMN_GROUP:case J.IN_TABLE_BODY:case J.IN_ROW:case J.IN_CELL:case J.IN_SELECT:case J.IN_SELECT_IN_TABLE:Nw(this,e);break;case J.TEXT:Fw(this,e);break;case J.IN_TABLE_TEXT:Xw(this,e);break;case J.IN_TEMPLATE:hT(this,e);break;case J.AFTER_BODY:case J.IN_FRAMESET:case J.AFTER_FRAMESET:case J.AFTER_AFTER_BODY:case J.AFTER_AFTER_FRAMESET:bC(this,e);break;default:}}onWhitespaceCharacter(e){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,e.chars.charCodeAt(0)===V.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 J.IN_HEAD:case J.IN_HEAD_NO_SCRIPT:case J.AFTER_HEAD:case J.TEXT:case J.IN_COLUMN_GROUP:case J.IN_SELECT:case J.IN_SELECT_IN_TABLE:case J.IN_FRAMESET:case J.AFTER_FRAMESET:this._insertCharacters(e);break;case J.IN_BODY:case J.IN_CAPTION:case J.IN_CELL:case J.IN_TEMPLATE:case J.AFTER_BODY:case J.AFTER_AFTER_BODY:case J.AFTER_AFTER_FRAMESET:BC(this,e);break;case J.IN_TABLE:case J.IN_TABLE_BODY:case J.IN_ROW:Iw(this,e);break;case J.IN_TABLE_TEXT:Jw(this,e);break;default:}}};function uC(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):jw(e,t),n}function dC(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){let 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 fC(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let a=0,o=i;o!==n;a++,o=i){i=e.openElements.getCommonAncestor(o);let n=e.activeFormattingElements.getElementEntry(o),s=n&&a>=3;!n||s?(s&&e.activeFormattingElements.removeEntry(n),e.openElements.remove(o)):(o=pC(e,n),r===t&&(e.activeFormattingElements.bookmark=n),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(o,r),r=o)}return r}function pC(e,t){let 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 mC(e,t,n){let r=cS(e.treeAdapter.getTagName(t));if(e._isElementCausesFosterParenting(r))e._fosterParentElement(n);else{let i=e.treeAdapter.getNamespaceURI(t);r===G.TEMPLATE&&i===U.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function hC(e,t,n){let 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 gC(e,t){for(let n=0;n<8;n++){let n=uC(e,t);if(!n)break;let r=dC(e,n);if(!r)break;e.activeFormattingElements.bookmark=n;let i=fC(e,r,n.element),a=e.openElements.getCommonAncestor(n.element);e.treeAdapter.detachNode(i),a&&mC(e,a,i),hC(e,r,n)}}function _C(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function vC(e,t){e._appendCommentNode(t,e.openElements.items[0])}function yC(e,t){e._appendCommentNode(t,e.document)}function bC(e,t){if(e.stopped=!0,t.location){let 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){let n=e.openElements.items[0],r=e.treeAdapter.getNodeSourceCodeLocation(n);if(r&&!r.endTag&&(e._setEndLocation(n,t),e.openElements.stackTop>=1)){let n=e.openElements.items[1],r=e.treeAdapter.getNodeSourceCodeLocation(n);r&&!r.endTag&&e._setEndLocation(n,t)}}}}function xC(e,t){e._setDocumentType(t);let n=t.forceQuirks?oS.QUIRKS:KS(t);GS(t)||e._err(t,H.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=J.BEFORE_HTML}function SC(e,t){e._err(t,H.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,oS.QUIRKS),e.insertionMode=J.BEFORE_HTML,e._processToken(t)}function CC(e,t){t.tagID===G.HTML?(e._insertElement(t,U.HTML),e.insertionMode=J.BEFORE_HEAD):TC(e,t)}function wC(e,t){let n=t.tagID;(n===G.HTML||n===G.HEAD||n===G.BODY||n===G.BR)&&TC(e,t)}function TC(e,t){e._insertFakeRootElement(),e.insertionMode=J.BEFORE_HEAD,e._processToken(t)}function EC(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.HEAD:e._insertElement(t,U.HTML),e.headElement=e.openElements.current,e.insertionMode=J.IN_HEAD;break;default:OC(e,t)}}function DC(e,t){let n=t.tagID;n===G.HEAD||n===G.BODY||n===G.HTML||n===G.BR?OC(e,t):e._err(t,H.endTagWithoutMatchingOpenElement)}function OC(e,t){e._insertFakeElement(W.HEAD,G.HEAD),e.headElement=e.openElements.current,e.insertionMode=J.IN_HEAD,e._processToken(t)}function kC(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.BASE:case G.BASEFONT:case G.BGSOUND:case G.LINK:case G.META:e._appendElement(t,U.HTML),t.ackSelfClosing=!0;break;case G.TITLE:e._switchToTextParsing(t,dS.RCDATA);break;case G.NOSCRIPT:e.options.scriptingEnabled?e._switchToTextParsing(t,dS.RAWTEXT):(e._insertElement(t,U.HTML),e.insertionMode=J.IN_HEAD_NO_SCRIPT);break;case G.NOFRAMES:case G.STYLE:e._switchToTextParsing(t,dS.RAWTEXT);break;case G.SCRIPT:e._switchToTextParsing(t,dS.SCRIPT_DATA);break;case G.TEMPLATE:e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=J.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(J.IN_TEMPLATE);break;case G.HEAD:e._err(t,H.misplacedStartTagForHeadElement);break;default:MC(e,t)}}function AC(e,t){switch(t.tagID){case G.HEAD:e.openElements.pop(),e.insertionMode=J.AFTER_HEAD;break;case G.BODY:case G.BR:case G.HTML:MC(e,t);break;case G.TEMPLATE:jC(e,t);break;default:e._err(t,H.endTagWithoutMatchingOpenElement)}}function jC(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==G.TEMPLATE&&e._err(t,H.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(G.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,H.endTagWithoutMatchingOpenElement)}function MC(e,t){e.openElements.pop(),e.insertionMode=J.AFTER_HEAD,e._processToken(t)}function NC(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.BASEFONT:case G.BGSOUND:case G.HEAD:case G.LINK:case G.META:case G.NOFRAMES:case G.STYLE:kC(e,t);break;case G.NOSCRIPT:e._err(t,H.nestedNoscriptInHead);break;default:FC(e,t)}}function PC(e,t){switch(t.tagID){case G.NOSCRIPT:e.openElements.pop(),e.insertionMode=J.IN_HEAD;break;case G.BR:FC(e,t);break;default:e._err(t,H.endTagWithoutMatchingOpenElement)}}function FC(e,t){let n=t.type===Wx.EOF?H.openElementsLeftAfterEof:H.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=J.IN_HEAD,e._processToken(t)}function IC(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.BODY:e._insertElement(t,U.HTML),e.framesetOk=!1,e.insertionMode=J.IN_BODY;break;case G.FRAMESET:e._insertElement(t,U.HTML),e.insertionMode=J.IN_FRAMESET;break;case G.BASE:case G.BASEFONT:case G.BGSOUND:case G.LINK:case G.META:case G.NOFRAMES:case G.SCRIPT:case G.STYLE:case G.TEMPLATE:case G.TITLE:e._err(t,H.abandonedHeadElementChild),e.openElements.push(e.headElement,G.HEAD),kC(e,t),e.openElements.remove(e.headElement);break;case G.HEAD:e._err(t,H.misplacedStartTagForHeadElement);break;default:RC(e,t)}}function LC(e,t){switch(t.tagID){case G.BODY:case G.HTML:case G.BR:RC(e,t);break;case G.TEMPLATE:jC(e,t);break;default:e._err(t,H.endTagWithoutMatchingOpenElement)}}function RC(e,t){e._insertFakeElement(W.BODY,G.BODY),e.insertionMode=J.IN_BODY,zC(e,t)}function zC(e,t){switch(t.type){case Wx.CHARACTER:VC(e,t);break;case Wx.WHITESPACE_CHARACTER:BC(e,t);break;case Wx.COMMENT:_C(e,t);break;case Wx.START_TAG:bw(e,t);break;case Wx.END_TAG:Mw(e,t);break;case Wx.EOF:Nw(e,t);break;default:}}function BC(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function VC(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function HC(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function UC(e,t){let n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function WC(e,t){let n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,U.HTML),e.insertionMode=J.IN_FRAMESET)}function GC(e,t){e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e._insertElement(t,U.HTML)}function KC(e,t){e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&uS.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,U.HTML)}function qC(e,t){e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e._insertElement(t,U.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function JC(e,t){let n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e._insertElement(t,U.HTML),n||(e.formElement=e.openElements.current))}function YC(e,t){e.framesetOk=!1;let n=t.tagID;for(let t=e.openElements.stackTop;t>=0;t--){let r=e.openElements.tagIDs[t];if(n===G.LI&&r===G.LI||(n===G.DD||n===G.DT)&&(r===G.DD||r===G.DT)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.popUntilTagNamePopped(r);break}if(r!==G.ADDRESS&&r!==G.DIV&&r!==G.P&&e._isSpecialElement(e.openElements.items[t],r))break}e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e._insertElement(t,U.HTML)}function XC(e,t){e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e._insertElement(t,U.HTML),e.tokenizer.state=dS.PLAINTEXT}function ZC(e,t){e.openElements.hasInScope(G.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(G.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,U.HTML),e.framesetOk=!1}function QC(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(W.A);n&&(gC(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,U.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function $C(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,U.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function ew(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(G.NOBR)&&(gC(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,U.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function tw(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,U.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function nw(e,t){e.treeAdapter.getDocumentMode(e.document)!==oS.QUIRKS&&e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e._insertElement(t,U.HTML),e.framesetOk=!1,e.insertionMode=J.IN_TABLE}function rw(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,U.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function iw(e){let t=Gx(e,aS.TYPE);return t!=null&&t.toLowerCase()===`hidden`}function aw(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,U.HTML),iw(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function ow(e,t){e._appendElement(t,U.HTML),t.ackSelfClosing=!0}function sw(e,t){e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e._appendElement(t,U.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function cw(e,t){t.tagName=W.IMG,t.tagID=G.IMG,rw(e,t)}function lw(e,t){e._insertElement(t,U.HTML),e.skipNextNewLine=!0,e.tokenizer.state=dS.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=J.TEXT}function uw(e,t){e.openElements.hasInButtonScope(G.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,dS.RAWTEXT)}function dw(e,t){e.framesetOk=!1,e._switchToTextParsing(t,dS.RAWTEXT)}function fw(e,t){e._switchToTextParsing(t,dS.RAWTEXT)}function pw(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,U.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===J.IN_TABLE||e.insertionMode===J.IN_CAPTION||e.insertionMode===J.IN_TABLE_BODY||e.insertionMode===J.IN_ROW||e.insertionMode===J.IN_CELL?J.IN_SELECT_IN_TABLE:J.IN_SELECT}function mw(e,t){e.openElements.currentTagId===G.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,U.HTML)}function hw(e,t){e.openElements.hasInScope(G.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,U.HTML)}function gw(e,t){e.openElements.hasInScope(G.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(G.RTC),e._insertElement(t,U.HTML)}function _w(e,t){e._reconstructActiveFormattingElements(),$S(t),tC(t),t.selfClosing?e._appendElement(t,U.MATHML):e._insertElement(t,U.MATHML),t.ackSelfClosing=!0}function vw(e,t){e._reconstructActiveFormattingElements(),eC(t),tC(t),t.selfClosing?e._appendElement(t,U.SVG):e._insertElement(t,U.SVG),t.ackSelfClosing=!0}function yw(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,U.HTML)}function bw(e,t){switch(t.tagID){case G.I:case G.S:case G.B:case G.U:case G.EM:case G.TT:case G.BIG:case G.CODE:case G.FONT:case G.SMALL:case G.STRIKE:case G.STRONG:$C(e,t);break;case G.A:QC(e,t);break;case G.H1:case G.H2:case G.H3:case G.H4:case G.H5:case G.H6:KC(e,t);break;case G.P:case G.DL:case G.OL:case G.UL:case G.DIV:case G.DIR:case G.NAV:case G.MAIN:case G.MENU:case G.ASIDE:case G.CENTER:case G.FIGURE:case G.FOOTER:case G.HEADER:case G.HGROUP:case G.DIALOG:case G.DETAILS:case G.ADDRESS:case G.ARTICLE:case G.SEARCH:case G.SECTION:case G.SUMMARY:case G.FIELDSET:case G.BLOCKQUOTE:case G.FIGCAPTION:GC(e,t);break;case G.LI:case G.DD:case G.DT:YC(e,t);break;case G.BR:case G.IMG:case G.WBR:case G.AREA:case G.EMBED:case G.KEYGEN:rw(e,t);break;case G.HR:sw(e,t);break;case G.RB:case G.RTC:hw(e,t);break;case G.RT:case G.RP:gw(e,t);break;case G.PRE:case G.LISTING:qC(e,t);break;case G.XMP:uw(e,t);break;case G.SVG:vw(e,t);break;case G.HTML:HC(e,t);break;case G.BASE:case G.LINK:case G.META:case G.STYLE:case G.TITLE:case G.SCRIPT:case G.BGSOUND:case G.BASEFONT:case G.TEMPLATE:kC(e,t);break;case G.BODY:UC(e,t);break;case G.FORM:JC(e,t);break;case G.NOBR:ew(e,t);break;case G.MATH:_w(e,t);break;case G.TABLE:nw(e,t);break;case G.INPUT:aw(e,t);break;case G.PARAM:case G.TRACK:case G.SOURCE:ow(e,t);break;case G.IMAGE:cw(e,t);break;case G.BUTTON:ZC(e,t);break;case G.APPLET:case G.OBJECT:case G.MARQUEE:tw(e,t);break;case G.IFRAME:dw(e,t);break;case G.SELECT:pw(e,t);break;case G.OPTION:case G.OPTGROUP:mw(e,t);break;case G.NOEMBED:case G.NOFRAMES:fw(e,t);break;case G.FRAMESET:WC(e,t);break;case G.TEXTAREA:lw(e,t);break;case G.NOSCRIPT:e.options.scriptingEnabled?fw(e,t):yw(e,t);break;case G.PLAINTEXT:XC(e,t);break;case G.COL:case G.TH:case G.TD:case G.TR:case G.HEAD:case G.FRAME:case G.TBODY:case G.TFOOT:case G.THEAD:case G.CAPTION:case G.COLGROUP:break;default:yw(e,t)}}function xw(e,t){if(e.openElements.hasInScope(G.BODY)&&(e.insertionMode=J.AFTER_BODY,e.options.sourceCodeLocationInfo)){let n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function Sw(e,t){e.openElements.hasInScope(G.BODY)&&(e.insertionMode=J.AFTER_BODY,_T(e,t))}function Cw(e,t){let n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function ww(e){let t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(G.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(G.FORM):n&&e.openElements.remove(n))}function Tw(e){e.openElements.hasInButtonScope(G.P)||e._insertFakeElement(W.P,G.P),e._closePElement()}function Ew(e){e.openElements.hasInListItemScope(G.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(G.LI),e.openElements.popUntilTagNamePopped(G.LI))}function Dw(e,t){let n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function Ow(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function kw(e,t){let n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function Aw(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(W.BR,G.BR),e.openElements.pop(),e.framesetOk=!1}function jw(e,t){let n=t.tagName,r=t.tagID;for(let t=e.openElements.stackTop;t>0;t--){let i=e.openElements.items[t],a=e.openElements.tagIDs[t];if(r===a&&(r!==G.UNKNOWN||e.treeAdapter.getTagName(i)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=t&&e.openElements.shortenToLength(t);break}if(e._isSpecialElement(i,a))break}}function Mw(e,t){switch(t.tagID){case G.A:case G.B:case G.I:case G.S:case G.U:case G.EM:case G.TT:case G.BIG:case G.CODE:case G.FONT:case G.NOBR:case G.SMALL:case G.STRIKE:case G.STRONG:gC(e,t);break;case G.P:Tw(e);break;case G.DL:case G.UL:case G.OL:case G.DIR:case G.DIV:case G.NAV:case G.PRE:case G.MAIN:case G.MENU:case G.ASIDE:case G.BUTTON:case G.CENTER:case G.FIGURE:case G.FOOTER:case G.HEADER:case G.HGROUP:case G.DIALOG:case G.ADDRESS:case G.ARTICLE:case G.DETAILS:case G.SEARCH:case G.SECTION:case G.SUMMARY:case G.LISTING:case G.FIELDSET:case G.BLOCKQUOTE:case G.FIGCAPTION:Cw(e,t);break;case G.LI:Ew(e);break;case G.DD:case G.DT:Dw(e,t);break;case G.H1:case G.H2:case G.H3:case G.H4:case G.H5:case G.H6:Ow(e);break;case G.BR:Aw(e);break;case G.BODY:xw(e,t);break;case G.HTML:Sw(e,t);break;case G.FORM:ww(e);break;case G.APPLET:case G.OBJECT:case G.MARQUEE:kw(e,t);break;case G.TEMPLATE:jC(e,t);break;default:jw(e,t)}}function Nw(e,t){e.tmplInsertionModeStack.length>0?hT(e,t):bC(e,t)}function Pw(e,t){var n;t.tagID===G.SCRIPT&&((n=e.scriptHandler)==null||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function Fw(e,t){e._err(t,H.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Iw(e,t){if(e.openElements.currentTagId!==void 0&&sC.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=J.IN_TABLE_TEXT,t.type){case Wx.CHARACTER:Yw(e,t);break;case Wx.WHITESPACE_CHARACTER:Jw(e,t);break}else qw(e,t)}function Lw(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,U.HTML),e.insertionMode=J.IN_CAPTION}function Rw(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,U.HTML),e.insertionMode=J.IN_COLUMN_GROUP}function zw(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(W.COLGROUP,G.COLGROUP),e.insertionMode=J.IN_COLUMN_GROUP,eT(e,t)}function Bw(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,U.HTML),e.insertionMode=J.IN_TABLE_BODY}function Vw(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(W.TBODY,G.TBODY),e.insertionMode=J.IN_TABLE_BODY,rT(e,t)}function Hw(e,t){e.openElements.hasInTableScope(G.TABLE)&&(e.openElements.popUntilTagNamePopped(G.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function Uw(e,t){iw(t)?e._appendElement(t,U.HTML):qw(e,t),t.ackSelfClosing=!0}function Ww(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,U.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function Gw(e,t){switch(t.tagID){case G.TD:case G.TH:case G.TR:Vw(e,t);break;case G.STYLE:case G.SCRIPT:case G.TEMPLATE:kC(e,t);break;case G.COL:zw(e,t);break;case G.FORM:Ww(e,t);break;case G.TABLE:Hw(e,t);break;case G.TBODY:case G.TFOOT:case G.THEAD:Bw(e,t);break;case G.INPUT:Uw(e,t);break;case G.CAPTION:Lw(e,t);break;case G.COLGROUP:Rw(e,t);break;default:qw(e,t)}}function Kw(e,t){switch(t.tagID){case G.TABLE:e.openElements.hasInTableScope(G.TABLE)&&(e.openElements.popUntilTagNamePopped(G.TABLE),e._resetInsertionMode());break;case G.TEMPLATE:jC(e,t);break;case G.BODY:case G.CAPTION:case G.COL:case G.COLGROUP:case G.HTML:case G.TBODY:case G.TD:case G.TFOOT:case G.TH:case G.THEAD:case G.TR:break;default:qw(e,t)}}function qw(e,t){let n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,zC(e,t),e.fosterParentingEnabled=n}function Jw(e,t){e.pendingCharacterTokens.push(t)}function Yw(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Xw(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)qw(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const Zw=new Set([G.CAPTION,G.COL,G.COLGROUP,G.TBODY,G.TD,G.TFOOT,G.TH,G.THEAD,G.TR]);function Qw(e,t){let n=t.tagID;Zw.has(n)?e.openElements.hasInTableScope(G.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(G.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=J.IN_TABLE,Gw(e,t)):bw(e,t)}function $w(e,t){let n=t.tagID;switch(n){case G.CAPTION:case G.TABLE:e.openElements.hasInTableScope(G.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(G.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=J.IN_TABLE,n===G.TABLE&&Kw(e,t));break;case G.BODY:case G.COL:case G.COLGROUP:case G.HTML:case G.TBODY:case G.TD:case G.TFOOT:case G.TH:case G.THEAD:case G.TR:break;default:Mw(e,t)}}function eT(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.COL:e._appendElement(t,U.HTML),t.ackSelfClosing=!0;break;case G.TEMPLATE:kC(e,t);break;default:nT(e,t)}}function tT(e,t){switch(t.tagID){case G.COLGROUP:e.openElements.currentTagId===G.COLGROUP&&(e.openElements.pop(),e.insertionMode=J.IN_TABLE);break;case G.TEMPLATE:jC(e,t);break;case G.COL:break;default:nT(e,t)}}function nT(e,t){e.openElements.currentTagId===G.COLGROUP&&(e.openElements.pop(),e.insertionMode=J.IN_TABLE,e._processToken(t))}function rT(e,t){switch(t.tagID){case G.TR:e.openElements.clearBackToTableBodyContext(),e._insertElement(t,U.HTML),e.insertionMode=J.IN_ROW;break;case G.TH:case G.TD:e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(W.TR,G.TR),e.insertionMode=J.IN_ROW,aT(e,t);break;case G.CAPTION:case G.COL:case G.COLGROUP:case G.TBODY:case G.TFOOT:case G.THEAD:e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=J.IN_TABLE,Gw(e,t));break;default:Gw(e,t)}}function iT(e,t){let n=t.tagID;switch(t.tagID){case G.TBODY:case G.TFOOT:case G.THEAD:e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=J.IN_TABLE);break;case G.TABLE:e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=J.IN_TABLE,Kw(e,t));break;case G.BODY:case G.CAPTION:case G.COL:case G.COLGROUP:case G.HTML:case G.TD:case G.TH:case G.TR:break;default:Kw(e,t)}}function aT(e,t){switch(t.tagID){case G.TH:case G.TD:e.openElements.clearBackToTableRowContext(),e._insertElement(t,U.HTML),e.insertionMode=J.IN_CELL,e.activeFormattingElements.insertMarker();break;case G.CAPTION:case G.COL:case G.COLGROUP:case G.TBODY:case G.TFOOT:case G.THEAD:case G.TR:e.openElements.hasInTableScope(G.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=J.IN_TABLE_BODY,rT(e,t));break;default:Gw(e,t)}}function oT(e,t){switch(t.tagID){case G.TR:e.openElements.hasInTableScope(G.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=J.IN_TABLE_BODY);break;case G.TABLE:e.openElements.hasInTableScope(G.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=J.IN_TABLE_BODY,iT(e,t));break;case G.TBODY:case G.TFOOT:case G.THEAD:(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(G.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=J.IN_TABLE_BODY,iT(e,t));break;case G.BODY:case G.CAPTION:case G.COL:case G.COLGROUP:case G.HTML:case G.TD:case G.TH:break;default:Kw(e,t)}}function sT(e,t){let n=t.tagID;Zw.has(n)?(e.openElements.hasInTableScope(G.TD)||e.openElements.hasInTableScope(G.TH))&&(e._closeTableCell(),aT(e,t)):bw(e,t)}function cT(e,t){let n=t.tagID;switch(n){case G.TD:case G.TH:e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=J.IN_ROW);break;case G.TABLE:case G.TBODY:case G.TFOOT:case G.THEAD:case G.TR:e.openElements.hasInTableScope(n)&&(e._closeTableCell(),oT(e,t));break;case G.BODY:case G.CAPTION:case G.COL:case G.COLGROUP:case G.HTML:break;default:Mw(e,t)}}function lT(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.OPTION:e.openElements.currentTagId===G.OPTION&&e.openElements.pop(),e._insertElement(t,U.HTML);break;case G.OPTGROUP:e.openElements.currentTagId===G.OPTION&&e.openElements.pop(),e.openElements.currentTagId===G.OPTGROUP&&e.openElements.pop(),e._insertElement(t,U.HTML);break;case G.HR:e.openElements.currentTagId===G.OPTION&&e.openElements.pop(),e.openElements.currentTagId===G.OPTGROUP&&e.openElements.pop(),e._appendElement(t,U.HTML),t.ackSelfClosing=!0;break;case G.INPUT:case G.KEYGEN:case G.TEXTAREA:case G.SELECT:e.openElements.hasInSelectScope(G.SELECT)&&(e.openElements.popUntilTagNamePopped(G.SELECT),e._resetInsertionMode(),t.tagID!==G.SELECT&&e._processStartTag(t));break;case G.SCRIPT:case G.TEMPLATE:kC(e,t);break;default:}}function uT(e,t){switch(t.tagID){case G.OPTGROUP:e.openElements.stackTop>0&&e.openElements.currentTagId===G.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===G.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===G.OPTGROUP&&e.openElements.pop();break;case G.OPTION:e.openElements.currentTagId===G.OPTION&&e.openElements.pop();break;case G.SELECT:e.openElements.hasInSelectScope(G.SELECT)&&(e.openElements.popUntilTagNamePopped(G.SELECT),e._resetInsertionMode());break;case G.TEMPLATE:jC(e,t);break;default:}}function dT(e,t){let n=t.tagID;n===G.CAPTION||n===G.TABLE||n===G.TBODY||n===G.TFOOT||n===G.THEAD||n===G.TR||n===G.TD||n===G.TH?(e.openElements.popUntilTagNamePopped(G.SELECT),e._resetInsertionMode(),e._processStartTag(t)):lT(e,t)}function fT(e,t){let n=t.tagID;n===G.CAPTION||n===G.TABLE||n===G.TBODY||n===G.TFOOT||n===G.THEAD||n===G.TR||n===G.TD||n===G.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(G.SELECT),e._resetInsertionMode(),e.onEndTag(t)):uT(e,t)}function pT(e,t){switch(t.tagID){case G.BASE:case G.BASEFONT:case G.BGSOUND:case G.LINK:case G.META:case G.NOFRAMES:case G.SCRIPT:case G.STYLE:case G.TEMPLATE:case G.TITLE:kC(e,t);break;case G.CAPTION:case G.COLGROUP:case G.TBODY:case G.TFOOT:case G.THEAD:e.tmplInsertionModeStack[0]=J.IN_TABLE,e.insertionMode=J.IN_TABLE,Gw(e,t);break;case G.COL:e.tmplInsertionModeStack[0]=J.IN_COLUMN_GROUP,e.insertionMode=J.IN_COLUMN_GROUP,eT(e,t);break;case G.TR:e.tmplInsertionModeStack[0]=J.IN_TABLE_BODY,e.insertionMode=J.IN_TABLE_BODY,rT(e,t);break;case G.TD:case G.TH:e.tmplInsertionModeStack[0]=J.IN_ROW,e.insertionMode=J.IN_ROW,aT(e,t);break;default:e.tmplInsertionModeStack[0]=J.IN_BODY,e.insertionMode=J.IN_BODY,bw(e,t)}}function mT(e,t){t.tagID===G.TEMPLATE&&jC(e,t)}function hT(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(G.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):bC(e,t)}function gT(e,t){t.tagID===G.HTML?bw(e,t):vT(e,t)}function _T(e,t){if(t.tagID===G.HTML){if(e.fragmentContext||(e.insertionMode=J.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===G.HTML){e._setEndLocation(e.openElements.items[0],t);let n=e.openElements.items[1];n&&!e.treeAdapter.getNodeSourceCodeLocation(n)?.endTag&&e._setEndLocation(n,t)}}else vT(e,t)}function vT(e,t){e.insertionMode=J.IN_BODY,zC(e,t)}function yT(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.FRAMESET:e._insertElement(t,U.HTML);break;case G.FRAME:e._appendElement(t,U.HTML),t.ackSelfClosing=!0;break;case G.NOFRAMES:kC(e,t);break;default:}}function bT(e,t){t.tagID===G.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==G.FRAMESET&&(e.insertionMode=J.AFTER_FRAMESET))}function xT(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.NOFRAMES:kC(e,t);break;default:}}function ST(e,t){t.tagID===G.HTML&&(e.insertionMode=J.AFTER_AFTER_FRAMESET)}function CT(e,t){t.tagID===G.HTML?bw(e,t):wT(e,t)}function wT(e,t){e.insertionMode=J.IN_BODY,zC(e,t)}function TT(e,t){switch(t.tagID){case G.HTML:bw(e,t);break;case G.NOFRAMES:kC(e,t);break;default:}}function ET(e,t){t.chars=`�`,e._insertCharacters(t)}function DT(e,t){e._insertCharacters(t),e.framesetOk=!1}function OT(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==U.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function kT(e,t){if(QS(t))OT(e),e._startTagOutsideForeignContent(t);else{let n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===U.MATHML?$S(t):r===U.SVG&&(nC(t),eC(t)),tC(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function AT(e,t){if(t.tagID===G.P||t.tagID===G.BR){OT(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){let r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===U.HTML){e._endTagOutsideForeignContent(t);break}let i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}new Set([W.AREA,W.BASE,W.BASEFONT,W.BGSOUND,W.BR,W.COL,W.EMBED,W.FRAME,W.HR,W.IMG,W.INPUT,W.KEYGEN,W.LINK,W.META,W.PARAM,W.SOURCE,W.TRACK,W.WBR]);function jT(e,t){return lC.parse(e,t)}function MT(e,t,n){typeof e==`string`&&(n=t,t=e,e=null);let r=lC.getFragmentParser(e,n);return r.tokenizer.write(t,!0),r.getFragment()}function NT(e){return!!(typeof e==`object`&&e&&`href`in e&&e.href&&`protocol`in e&&e.protocol&&e.auth===void 0)}const PT=[`history`,`path`,`basename`,`stem`,`extname`,`dirname`];var FT=class{constructor(e){let t;t=e?NT(e)?{path:e}:typeof e==`string`||zT(e)?{value:e}:e:{},this.cwd=`cwd`in t?``:ue.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n=-1;for(;++n<PT.length;){let e=PT[n];e in t&&t[e]!==void 0&&t[e]!==null&&(this[e]=e===`history`?[...t[e]]:t[e])}let r;for(r in t)PT.includes(r)||(this[r]=t[r])}get basename(){return typeof this.path==`string`?j.basename(this.path):void 0}set basename(e){LT(e,`basename`),IT(e,`basename`),this.path=j.join(this.dirname||``,e)}get dirname(){return typeof this.path==`string`?j.dirname(this.path):void 0}set dirname(e){RT(this.basename,`dirname`),this.path=j.join(e||``,this.basename)}get extname(){return typeof this.path==`string`?j.extname(this.path):void 0}set extname(e){if(IT(e,`extname`),RT(this.dirname,`extname`),e){if(e.codePointAt(0)!==46)throw Error("`extname` must start with `.`");if(e.includes(`.`,1))throw Error("`extname` cannot contain multiple dots")}this.path=j.join(this.dirname,this.stem+(e||``))}get path(){return this.history[this.history.length-1]}set path(e){NT(e)&&(e=de(e)),LT(e,`path`),this.path!==e&&this.history.push(e)}get stem(){return typeof this.path==`string`?j.basename(this.path,this.extname):void 0}set stem(e){LT(e,`stem`),IT(e,`stem`),this.path=j.join(this.dirname||``,e+(this.extname||``))}fail(e,t,n){let r=this.message(e,t,n);throw r.fatal=!0,r}info(e,t,n){let r=this.message(e,t,n);return r.fatal=void 0,r}message(e,t,n){let r=new je(e,t,n);return this.path&&(r.name=this.path+`:`+r.name,r.file=this.path),r.fatal=!1,this.messages.push(r),r}toString(e){return this.value===void 0?``:typeof this.value==`string`?this.value:new TextDecoder(e||void 0).decode(this.value)}};function IT(e,t){if(e&&e.includes(j.sep))throw Error("`"+t+"` cannot be a path: did not expect `"+j.sep+"`")}function LT(e,t){if(!e)throw Error("`"+t+"` cannot be empty")}function RT(e,t){if(!e)throw Error("Setting `"+t+"` requires `path` to be set too")}function zT(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}const BT={abandonedHeadElementChild:{reason:`Unexpected metadata element after head`,description:"Unexpected element after head. Expected the element before `</head>`",url:!1},abruptClosingOfEmptyComment:{reason:`Unexpected abruptly closed empty comment`,description:"Unexpected `>` or `->`. Expected `-->` to close comments"},abruptDoctypePublicIdentifier:{reason:`Unexpected abruptly closed public identifier`,description:"Unexpected `>`. Expected a closing `\"` or `'` after the public identifier"},abruptDoctypeSystemIdentifier:{reason:`Unexpected abruptly closed system identifier`,description:"Unexpected `>`. Expected a closing `\"` or `'` after the identifier identifier"},absenceOfDigitsInNumericCharacterReference:{reason:`Unexpected non-digit at start of numeric character reference`,description:"Unexpected `%c`. Expected `[0-9]` for decimal references or `[0-9a-fA-F]` for hexadecimal references"},cdataInHtmlContent:{reason:`Unexpected CDATA section in HTML`,description:"Unexpected `<![CDATA[` in HTML. Remove it, use a comment, or encode special characters instead"},characterReferenceOutsideUnicodeRange:{reason:`Unexpected too big numeric character reference`,description:`Unexpectedly high character reference. Expected character references to be at most hexadecimal 10ffff (or decimal 1114111)`},closingOfElementWithOpenChildElements:{reason:`Unexpected closing tag with open child elements`,description:`Unexpectedly closing tag. Expected other tags to be closed first`,url:!1},controlCharacterInInputStream:{reason:`Unexpected control character`,description:"Unexpected control character `%x`. Expected a non-control code point, 0x00, or ASCII whitespace"},controlCharacterReference:{reason:`Unexpected control character reference`,description:`Unexpectedly control character in reference. Expected a non-control code point, 0x00, or ASCII whitespace`},disallowedContentInNoscriptInHead:{reason:"Disallowed content inside `<noscript>` in `<head>`",description:"Unexpected text character `%c`. Only use text in `<noscript>`s in `<body>`",url:!1},duplicateAttribute:{reason:`Unexpected duplicate attribute`,description:`Unexpectedly double attribute. Expected attributes to occur only once`},endTagWithAttributes:{reason:`Unexpected attribute on closing tag`,description:"Unexpected attribute. Expected `>` instead"},endTagWithTrailingSolidus:{reason:`Unexpected slash at end of closing tag`,description:"Unexpected `%c-1`. Expected `>` instead"},endTagWithoutMatchingOpenElement:{reason:`Unexpected unopened end tag`,description:`Unexpected end tag. Expected no end tag or another end tag`,url:!1},eofBeforeTagName:{reason:`Unexpected end of file`,description:`Unexpected end of file. Expected tag name instead`},eofInCdata:{reason:`Unexpected end of file in CDATA`,description:"Unexpected end of file. Expected `]]>` to close the CDATA"},eofInComment:{reason:`Unexpected end of file in comment`,description:"Unexpected end of file. Expected `-->` to close the comment"},eofInDoctype:{reason:`Unexpected end of file in doctype`,description:"Unexpected end of file. Expected a valid doctype (such as `<!doctype html>`)"},eofInElementThatCanContainOnlyText:{reason:`Unexpected end of file in element that can only contain text`,description:`Unexpected end of file. Expected text or a closing tag`,url:!1},eofInScriptHtmlCommentLikeText:{reason:`Unexpected end of file in comment inside script`,description:"Unexpected end of file. Expected `-->` to close the comment"},eofInTag:{reason:`Unexpected end of file in tag`,description:"Unexpected end of file. Expected `>` to close the tag"},incorrectlyClosedComment:{reason:`Incorrectly closed comment`,description:"Unexpected `%c-1`. Expected `-->` to close the comment"},incorrectlyOpenedComment:{reason:`Incorrectly opened comment`,description:"Unexpected `%c`. Expected `<!--` to open the comment"},invalidCharacterSequenceAfterDoctypeName:{reason:`Invalid sequence after doctype name`,description:"Unexpected sequence at `%c`. Expected `public` or `system`"},invalidFirstCharacterOfTagName:{reason:`Invalid first character in tag name`,description:"Unexpected `%c`. Expected an ASCII letter instead"},misplacedDoctype:{reason:`Misplaced doctype`,description:`Unexpected doctype. Expected doctype before head`,url:!1},misplacedStartTagForHeadElement:{reason:"Misplaced `<head>` start tag",description:"Unexpected start tag `<head>`. Expected `<head>` directly after doctype",url:!1},missingAttributeValue:{reason:`Missing attribute value`,description:"Unexpected `%c-1`. Expected an attribute value or no `%c-1` instead"},missingDoctype:{reason:`Missing doctype before other content`,description:"Expected a `<!doctype html>` before anything else",url:!1},missingDoctypeName:{reason:`Missing doctype name`,description:"Unexpected doctype end at `%c`. Expected `html` instead"},missingDoctypePublicIdentifier:{reason:`Missing public identifier in doctype`,description:"Unexpected `%c`. Expected identifier for `public` instead"},missingDoctypeSystemIdentifier:{reason:`Missing system identifier in doctype`,description:'Unexpected `%c`. Expected identifier for `system` instead (suggested: `"about:legacy-compat"`)'},missingEndTagName:{reason:`Missing name in end tag`,description:"Unexpected `%c`. Expected an ASCII letter instead"},missingQuoteBeforeDoctypePublicIdentifier:{reason:`Missing quote before public identifier in doctype`,description:"Unexpected `%c`. Expected `\"` or `'` instead"},missingQuoteBeforeDoctypeSystemIdentifier:{reason:`Missing quote before system identifier in doctype`,description:"Unexpected `%c`. Expected `\"` or `'` instead"},missingSemicolonAfterCharacterReference:{reason:`Missing semicolon after character reference`,description:"Unexpected `%c`. Expected `;` instead"},missingWhitespaceAfterDoctypePublicKeyword:{reason:`Missing whitespace after public identifier in doctype`,description:"Unexpected `%c`. Expected ASCII whitespace instead"},missingWhitespaceAfterDoctypeSystemKeyword:{reason:`Missing whitespace after system identifier in doctype`,description:"Unexpected `%c`. Expected ASCII whitespace instead"},missingWhitespaceBeforeDoctypeName:{reason:`Missing whitespace before doctype name`,description:"Unexpected `%c`. Expected ASCII whitespace instead"},missingWhitespaceBetweenAttributes:{reason:`Missing whitespace between attributes`,description:"Unexpected `%c`. Expected ASCII whitespace instead"},missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers:{reason:`Missing whitespace between public and system identifiers in doctype`,description:"Unexpected `%c`. Expected ASCII whitespace instead"},nestedComment:{reason:`Unexpected nested comment`,description:"Unexpected `<!--`. Expected `-->`"},nestedNoscriptInHead:{reason:"Unexpected nested `<noscript>` in `<head>`",description:"Unexpected `<noscript>`. Expected a closing tag or a meta element",url:!1},nonConformingDoctype:{reason:`Unexpected non-conforming doctype declaration`,description:'Expected `<!doctype html>` or `<!doctype html system "about:legacy-compat">`',url:!1},nonVoidHtmlElementStartTagWithTrailingSolidus:{reason:`Unexpected trailing slash on start tag of non-void element`,description:"Unexpected `/`. Expected `>` instead"},noncharacterCharacterReference:{reason:`Unexpected noncharacter code point referenced by character reference`,description:`Unexpected code point. Do not use noncharacters in HTML`},noncharacterInInputStream:{reason:`Unexpected noncharacter character`,description:"Unexpected code point `%x`. Do not use noncharacters in HTML"},nullCharacterReference:{reason:`Unexpected NULL character referenced by character reference`,description:`Unexpected code point. Do not use NULL characters in HTML`},openElementsLeftAfterEof:{reason:`Unexpected end of file`,description:`Unexpected end of file. Expected closing tag instead`,url:!1},surrogateCharacterReference:{reason:`Unexpected surrogate character referenced by character reference`,description:`Unexpected code point. Do not use lone surrogate characters in HTML`},surrogateInInputStream:{reason:`Unexpected surrogate character`,description:"Unexpected code point `%x`. Do not use lone surrogate characters in HTML"},unexpectedCharacterAfterDoctypeSystemIdentifier:{reason:`Invalid character after system identifier in doctype`,description:"Unexpected character at `%c`. Expected `>`"},unexpectedCharacterInAttributeName:{reason:`Unexpected character in attribute name`,description:"Unexpected `%c`. Expected whitespace, `/`, `>`, `=`, or probably an ASCII letter"},unexpectedCharacterInUnquotedAttributeValue:{reason:`Unexpected character in unquoted attribute value`,description:"Unexpected `%c`. Quote the attribute value to include it"},unexpectedEqualsSignBeforeAttributeName:{reason:`Unexpected equals sign before attribute name`,description:"Unexpected `%c`. Add an attribute name before it"},unexpectedNullCharacter:{reason:`Unexpected NULL character`,description:"Unexpected code point `%x`. Do not use NULL characters in HTML"},unexpectedQuestionMarkInsteadOfTagName:{reason:`Unexpected question mark instead of tag name`,description:"Unexpected `%c`. Expected an ASCII letter instead"},unexpectedSolidusInTag:{reason:`Unexpected slash in tag`,description:"Unexpected `%c-1`. Expected it followed by `>` or in a quoted attribute value"},unknownNamedCharacterReference:{reason:`Unexpected unknown named character reference`,description:`Unexpected character reference. Expected known named character references`}},VT=/-[a-z]/g,HT=/%c(?:([-+])(\d+))?/g,UT=/%x/g,WT={2:!0,1:!1,0:null},GT={};function KT(e,t){let n=t||GT,r=n.onerror,i=e instanceof FT?e:new FT(e),a=n.fragment?MT:jT,o=String(i);return Ox(a(o,{sourceCodeLocationInfo:!0,onParseError:n.onerror?s:null,scriptingEnabled:!1}),{file:i,space:n.space,verbose:n.verbose});function s(e){let t=e.code,a=qT(t),s=n[a]??!0,c=typeof s==`number`?s:+!!s;if(c){let n=BT[a],o=new je(l(n.reason),{place:{start:{line:e.startLine,column:e.startCol,offset:e.startOffset},end:{line:e.endLine,column:e.endCol,offset:e.endOffset}},ruleId:t,source:`hast-util-from-html`});i.path&&(o.file=i.path,o.name=i.path+`:`+o.name),o.fatal=WT[c],o.note=l(n.description),o.url=n.url===!1?void 0:`https://html.spec.whatwg.org/multipage/parsing.html#parse-error-`+t,r(o)}function l(t){return t.replace(HT,n).replace(UT,r);function n(t,n,r){let i=(r?Number.parseInt(r,10):0)*(n===`-`?-1:1);return YT(o.charAt(e.startOffset+i))}function r(){return XT(o.charCodeAt(e.startOffset))}}}}function qT(e){return e.replace(VT,JT)}function JT(e){return e.charAt(1).toUpperCase()}function YT(e){return e==="`"?"` ` `":e}function XT(e){return`0x`+e.toString(16).toUpperCase()}const ZT=(function(e,t,n,r,i){let a=QT(t);if(n!=null&&(typeof n!=`number`||n<0||n===1/0))throw Error(`Expected positive finite index`);if(r!=null&&(!ZT(r)||!r.children))throw Error(`Expected parent node`);if(r==null!=(n==null))throw Error(`Expected both parent and index`);return iE(e)?a.call(i,e,n,r):!1}),QT=(function(e){if(e==null)return rE;if(typeof e==`function`)return nE(e);if(typeof e==`object`)return Array.isArray(e)?$T(e):eE(e);if(typeof e==`string`)return tE(e);throw Error(`Expected function, string, or object as test`)});function $T(e){let t=[],n=-1;for(;++n<e.length;)t[n]=QT(e[n]);return nE(r);function r(...e){let n=-1;for(;++n<t.length;)if(t[n].apply(this,e))return!0;return!1}}function eE(e){let t=e;return nE(n);function n(n){let r=n,i;for(i in e)if(r[i]!==t[i])return!1;return!0}}function tE(e){return nE(t);function t(t){return t&&t.type===e}}function nE(e){return t;function t(t,n,r){return!!(iE(t)&&e.call(this,t,typeof n==`number`?n:void 0,r||void 0))}}function rE(){return!0}function iE(e){return typeof e==`object`&&!!e&&`type`in e}function aE(e){return`\x1B[33m`+e+`\x1B[39m`}const oE=[],sE=`skip`;function cE(e,t,n,r){let i;typeof t==`function`&&typeof n!=`function`?(r=n,n=t):i=t;let a=QT(i),o=r?-1:1;s(e,void 0,[])();function s(e,i,c){let l=e&&typeof e==`object`?e:{};if(typeof l.type==`string`){let t=typeof l.tagName==`string`?l.tagName:typeof l.name==`string`?l.name:void 0;Object.defineProperty(u,`name`,{value:`node (`+aE(e.type+(t?`<`+t+`>`:``))+`)`})}return u;function u(){let l=oE,u,d,f;if((!t||a(e,i,c[c.length-1]||void 0))&&(l=lE(n(e,c)),l[0]===!1))return l;if(`children`in e&&e.children){let t=e;if(t.children&&l[0]!==`skip`)for(d=(r?t.children.length:-1)+o,f=c.concat(t);d>-1&&d<t.children.length;){let e=t.children[d];if(u=s(e,d,f)(),u[0]===!1)return u;d=typeof u[1]==`number`?u[1]:d+o}}return l}}}function lE(e){return Array.isArray(e)?e:typeof e==`number`?[!0,e]:e==null?oE:[e]}function uE(e,t,n,r){let i,a,o;typeof t==`function`&&typeof n!=`function`?(a=void 0,o=t,i=n):(a=t,o=n,i=r),cE(e,a,s,i);function s(e,t){let n=t[t.length-1],r=n?n.children.indexOf(e):void 0;return o(e,r,n)}}const dE={};function fE(e,t){let n=t||dE;return pE(e,typeof n.includeImageAlt==`boolean`?n.includeImageAlt:!0,typeof n.includeHtml==`boolean`?n.includeHtml:!0)}function pE(e,t,n){if(hE(e)){if(`value`in e)return e.type===`html`&&!n?``:e.value;if(t&&`alt`in e&&e.alt)return e.alt;if(`children`in e)return mE(e.children,t,n)}return Array.isArray(e)?mE(e,t,n):``}function mE(e,t,n){let r=[],i=-1;for(;++i<e.length;)r[i]=pE(e[i],t,n);return r.join(``)}function hE(e){return!!(e&&typeof e==`object`)}const gE=QT([`break`,`delete`,`emphasis`,`footnote`,`footnoteReference`,`image`,`imageReference`,`inlineCode`,`inlineMath`,`link`,`linkReference`,`mdxJsxTextElement`,`mdxTextExpression`,`strong`,`text`,`textDirective`]);function _E(e,t){let n=String(e);if(typeof t!=`string`)throw TypeError(`Expected character`);let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}const vE=OE(/[A-Za-z]/),yE=OE(/[\dA-Za-z]/),bE=OE(/[#-'*+\--9=?A-Z^-~]/);function xE(e){return e!==null&&(e<32||e===127)}const SE=OE(/\d/),CE=OE(/[\dA-Fa-f]/),wE=OE(/[!-/:-@[-`{-~]/);function Y(e){return e!==null&&e<-2}function TE(e){return e!==null&&(e<0||e===32)}function X(e){return e===-2||e===-1||e===32}const EE=OE(/\p{P}|\p{S}/u),DE=OE(/\s/);function OE(e){return t;function t(t){return t!==null&&t>-1&&e.test(String.fromCharCode(t))}}function kE(e){if(typeof e!=`string`)throw TypeError(`Expected a string`);return e.replace(/[|\\{}()[\]^$+*?.]/g,`\\$&`).replace(/-/g,`\\x2d`)}function AE(e,t,n){let r=QT((n||{}).ignore||[]),i=jE(t),a=-1;for(;++a<i.length;)cE(e,`text`,o);function o(e,t){let n=-1,i;for(;++n<t.length;){let e=t[n],a=i?i.children:void 0;if(r(e,a?a.indexOf(e):void 0,i))return;i=e}if(i)return s(e,t)}function s(e,t){let n=t[t.length-1],r=i[a][0],o=i[a][1],s=0,c=n.children.indexOf(e),l=!1,u=[];r.lastIndex=0;let d=r.exec(e.value);for(;d;){let n=d.index,i={index:d.index,input:d.input,stack:[...t,e]},a=o(...d,i);if(typeof a==`string`&&(a=a.length>0?{type:`text`,value:a}:void 0),a===!1?r.lastIndex=n+1:(s!==n&&u.push({type:`text`,value:e.value.slice(s,n)}),Array.isArray(a)?u.push(...a):a&&u.push(a),s=n+d[0].length,l=!0),!r.global)break;d=r.exec(e.value)}return l?(s<e.value.length&&u.push({type:`text`,value:e.value.slice(s)}),n.children.splice(c,1,...u)):u=[e],c+u.length}}function jE(e){let t=[];if(!Array.isArray(e))throw TypeError(`Expected find and replace tuple or list of tuples`);let n=!e[0]||Array.isArray(e[0])?e:[e],r=-1;for(;++r<n.length;){let e=n[r];t.push([ME(e[0]),NE(e[1])])}return t}function ME(e){return typeof e==`string`?new RegExp(kE(e),`g`):e}function NE(e){return typeof e==`function`?e:function(){return e}}const PE=`phrasing`,FE=[`autolink`,`link`,`image`,`label`];function IE(){return{transforms:[WE],enter:{literalAutolink:RE,literalAutolinkEmail:zE,literalAutolinkHttp:zE,literalAutolinkWww:zE},exit:{literalAutolink:UE,literalAutolinkEmail:HE,literalAutolinkHttp:BE,literalAutolinkWww:VE}}}function LE(){return{unsafe:[{character:`@`,before:`[+\\-.\\w]`,after:`[\\-.\\w]`,inConstruct:PE,notInConstruct:FE},{character:`.`,before:`[Ww]`,after:`[\\-.\\w]`,inConstruct:PE,notInConstruct:FE},{character:`:`,before:`[ps]`,after:`\\/`,inConstruct:PE,notInConstruct:FE}]}}function RE(e){this.enter({type:`link`,title:null,url:``,children:[]},e)}function zE(e){this.config.enter.autolinkProtocol.call(this,e)}function BE(e){this.config.exit.autolinkProtocol.call(this,e)}function VE(e){this.config.exit.data.call(this,e);let t=this.stack[this.stack.length-1];t.type,t.url=`http://`+this.sliceSerialize(e)}function HE(e){this.config.exit.autolinkEmail.call(this,e)}function UE(e){this.exit(e)}function WE(e){AE(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,GE],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,KE]],{ignore:[`link`,`linkReference`]})}function GE(e,t,n,r,i){let a=``;if(!YE(i)||(/^w/i.test(t)&&(n=t+n,t=``,a=`http://`),!qE(n)))return!1;let o=JE(n+r);if(!o[0])return!1;let s={type:`link`,title:null,url:a+t+o[0],children:[{type:`text`,value:t+o[0]}]};return o[1]?[s,{type:`text`,value:o[1]}]:s}function KE(e,t,n,r){return!YE(r,!0)||/[-\d_]$/.test(n)?!1:{type:`link`,title:null,url:`mailto:`+t+`@`+n,children:[{type:`text`,value:t+`@`+n}]}}function qE(e){let 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 JE(e){let t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(`)`),i=_E(e,`(`),a=_E(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 YE(e,t){let n=e.input.charCodeAt(e.index-1);return(e.index===0||DE(n)||EE(n))&&(!t||n!==47)}function XE(e){return e.replace(/[\t\n\r ]+/g,` `).replace(/^ | $/g,``).toLowerCase().toUpperCase()}oD.peek=aD;function ZE(){this.buffer()}function QE(e){this.enter({type:`footnoteReference`,identifier:``,label:``},e)}function $E(){this.buffer()}function eD(e){this.enter({type:`footnoteDefinition`,identifier:``,label:``,children:[]},e)}function tD(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=XE(this.sliceSerialize(e)).toLowerCase(),n.label=t}function nD(e){this.exit(e)}function rD(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=XE(this.sliceSerialize(e)).toLowerCase(),n.label=t}function iD(e){this.exit(e)}function aD(){return`[`}function oD(e,t,n,r){let i=n.createTracker(r),a=i.move(`[^`),o=n.enter(`footnoteReference`),s=n.enter(`reference`);return a+=i.move(n.safe(n.associationId(e),{after:`]`,before:a})),s(),o(),a+=i.move(`]`),a}function sD(){return{enter:{gfmFootnoteCallString:ZE,gfmFootnoteCall:QE,gfmFootnoteDefinitionLabelString:$E,gfmFootnoteDefinition:eD},exit:{gfmFootnoteCallString:tD,gfmFootnoteCall:nD,gfmFootnoteDefinitionLabelString:rD,gfmFootnoteDefinition:iD}}}function cD(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:oD},unsafe:[{character:`[`,inConstruct:[`label`,`phrasing`,`reference`]}]};function n(e,n,r,i){let a=r.createTracker(i),o=a.move(`[^`),s=r.enter(`footnoteDefinition`),c=r.enter(`label`);return o+=a.move(r.safe(r.associationId(e),{before:o,after:`]`})),c(),o+=a.move(`]:`),e.children&&e.children.length>0&&(a.shift(4),o+=a.move((t?`
150
150
  `:` `)+r.indentLines(r.containerFlow(e,a.current()),t?uD:lD))),s(),o}}function lD(e,t,n){return t===0?e:uD(e,t,n)}function uD(e,t,n){return(n?``:` `)+e}const dD=[`autolink`,`destinationLiteral`,`destinationRaw`,`reference`,`titleQuote`,`titleApostrophe`];gD.peek=_D;function fD(){return{canContainEols:[`delete`],enter:{strikethrough:mD},exit:{strikethrough:hD}}}function pD(){return{unsafe:[{character:`~`,inConstruct:`phrasing`,notInConstruct:dD}],handlers:{delete:gD}}}function mD(e){this.enter({type:`delete`,children:[]},e)}function hD(e){this.exit(e)}function gD(e,t,n,r){let i=n.createTracker(r),a=n.enter(`strikethrough`),o=i.move(`~~`);return o+=n.containerPhrasing(e,{...i.current(),before:o,after:`~`}),o+=i.move(`~~`),a(),o}function _D(){return`~`}function vD(e){return e.length}function yD(e,t){let n=t||{},r=(n.align||[]).concat(),i=n.stringLength||vD,a=[],o=[],s=[],c=[],l=0,u=-1;for(;++u<e.length;){let t=[],r=[],a=-1;for(e[u].length>l&&(l=e[u].length);++a<e[u].length;){let o=bD(e[u][a]);if(n.alignDelimiters!==!1){let e=i(o);r[a]=e,(c[a]===void 0||e>c[a])&&(c[a]=e)}t.push(o)}o[u]=t,s[u]=r}let d=-1;if(typeof r==`object`&&`length`in r)for(;++d<l;)a[d]=xD(r[d]);else{let e=xD(r);for(;++d<l;)a[d]=e}d=-1;let f=[],p=[];for(;++d<l;){let e=a[d],t=``,r=``;e===99?(t=`:`,r=`:`):e===108?t=`:`:e===114&&(r=`:`);let i=n.alignDelimiters===!1?1:Math.max(1,c[d]-t.length-r.length),o=t+`-`.repeat(i)+r;n.alignDelimiters!==!1&&(i=t.length+i+r.length,i>c[d]&&(c[d]=i),p[d]=i),f[d]=o}o.splice(1,0,f),s.splice(1,0,p),u=-1;let m=[];for(;++u<o.length;){let e=o[u],t=s[u];d=-1;let r=[];for(;++d<l;){let i=e[d]||``,o=``,s=``;if(n.alignDelimiters!==!1){let e=c[d]-(t[d]||0),n=a[d];n===114?o=` `.repeat(e):n===99?e%2?(o=` `.repeat(e/2+.5),s=` `.repeat(e/2-.5)):(o=` `.repeat(e/2),s=o):s=` `.repeat(e)}n.delimiterStart!==!1&&!d&&r.push(`|`),n.padding!==!1&&!(n.alignDelimiters===!1&&i===``)&&(n.delimiterStart!==!1||d)&&r.push(` `),n.alignDelimiters!==!1&&r.push(o),r.push(i),n.alignDelimiters!==!1&&r.push(s),n.padding!==!1&&r.push(` `),(n.delimiterEnd!==!1||d!==l-1)&&r.push(`|`)}m.push(n.delimiterEnd===!1?r.join(``).replace(/ +$/,``):r.join(``))}return m.join(`
@@ -342,4 +342,4 @@ Read more at https://docs.orama.com/docs/orama-js/plugins/plugin-secure-proxy#pl
342
342
  `);if(!(t[0]??``).startsWith(`template:`))return null;let n=[t[0]??``],r=1;for(;r<t.length;){let e=t[r]??``;if(/^[ \t]/.test(e)){n.push(e),r++;continue}if(e.trim()===``){let i=r+1;for(;i<t.length&&(t[i]??``).trim()===``;)i++;if(i<t.length&&/^[ \t]/.test(t[i]??``)){n.push(e),r++;continue}}break}let i=m5(n.join(`
343
343
  `))[p5];return{identity:typeof i==`object`&&i&&!Array.isArray(i)?i:{},docFrontmatterText:t.slice(r).join(`
344
344
  `).replace(/\n+$/,``)}}function v5(e){let t=e.charCodeAt(0)===65279?e.slice(1):e,{frontmatter:n,body:r}=om(t);if(n===``)return{identity:{},starterContent:t};let i=cm(n),a=_5(i);if(a)return{identity:a.identity,starterContent:h5(a.docFrontmatterText,r)};let{frontmatter:o}=om(r);if(o!==``)return{identity:m5(i),starterContent:r};let s=m5(i);return typeof s.title==`string`?{identity:s,starterContent:r}:{identity:{},starterContent:h5(i,r)}}function y5(e,t){let{docFrontmatterText:n,markdown:r}=g5(t),i={};for(let[t,n]of Object.entries(e))n!==void 0&&(i[t]=n);let a=(0,ze.stringify)({[p5]:i});return`---\n${n.trim()===``?a:`${a}${n}\n`}---\n${r}`}function b5(e){return v5(e).starterContent}const x5=`(agent thread)`;function S5(){let e=!1,t=``,n=0;return r=>{let i=C5(r);return e?(i&&i.char===t&&i.len>=n&&!i.hasInfo&&(e=!1,t=``,n=0),!0):i?(e=!0,t=i.char,n=i.len,!0):!1}}function C5(e){let t=(e.endsWith(`\r`)?e.slice(0,-1):e).match(/^ {0,3}([`~])(\1{2,})(.*)$/);return t?{char:t[1],len:1+t[2].length,hasInfo:t[3].trim()!==``}:null}const w5=/^(#{1,6})\s+(.+)$/;function T5(e,t){let n=(e.endsWith(`\r`)?e.slice(0,-1):e).match(w5);if(!n)return null;let r=n[2].trim(),i=gY(r,t);return i?{level:n[1].length,text:r,slug:i}:null}const E5=[`#D97757`,`#1B1912`,`#F9F3E9`,`#7A9DFF`,`#8534F3`,`#9663F0`,`#727CF3`],D5={claude:`#D97757`,cursor:`#1B1912`,windsurf:`#0B100F`,openai:`#7A9DFF`,github:`#8534F3`,cline:`#9663F0`,bot:`#727CF3`};function O5(e,t=E5){let n=0;for(let t of e)n=(n<<5)-n+t.charCodeAt(0)|0;return t[Math.abs(n)%t.length]}const k5={"claude-code":`claude`,"claude-ai":`claude`,cursor:`cursor`,"cursor-vscode":`cursor`,cascade:`windsurf`,codex:`openai`,"codex-mcp-client":`openai`,copilot:`github`,cline:`cline`};function A5(e){return e?k5[e]||(e.startsWith(`local-agent-mode-`)?`claude`:`bot`):`bot`}const j5={claude:`Claude`,cursor:`Cursor`,windsurf:`Windsurf`,openai:`Codex`,github:`Copilot`,cline:`Cline`};function M5(e){let t=e?.trim();return t?j5[A5(t)]??t:`Agent`}function N5(e,t){let n=e.trim();if(!n||/^[a-zA-Z][a-zA-Z\d+\-.]*:/.test(n)||n.startsWith(`//`)||n.startsWith(`#`))return null;let r=n.indexOf(`#`),i=r>=0?n.slice(0,r):n,a=r>=0?n.slice(r+1):null,o=(i.split(`?`)[0]??``).trim();if(!o)return null;let s=(o.split(`/`).pop()??``).match(/\.([a-z0-9]+)$/i);if(s){let e=(s[1]??``).toLowerCase();if(e!==`md`&&e!==`mdx`)return null}let c=o.toLowerCase(),l=c.endsWith(`.mdx`)?o.slice(0,-4):c.endsWith(`.md`)?o.slice(0,-3):o,u=l.startsWith(`/`),d=u?l.slice(1):l,f=u?[]:t.includes(`/`)?t.split(`/`).slice(0,-1):[];for(let e of d.split(`/`))if(e===`..`){if(f.length===0)return null;f.pop()}else e!==`.`&&e!==``&&f.push(e);return f.length===0?null:{docName:f.join(`/`),anchor:a||null}}const P5=/^[a-zA-Z][a-zA-Z\d+\-.]*:/;function F5(e){let t=(e.split(/[?#]/)[0]??e).match(/\.([a-z0-9]+)$/i);return t?(t[1]??``).toLowerCase():null}function I5(e){let t=e.trim();return P5.test(t)||t.startsWith(`//`)}function L5(e,t){let n=e.trim();if(!n)return null;if(n.startsWith(`#`)){let e=n.slice(1).trim();return e?{kind:`anchor`,anchor:e}:null}if(I5(n))return{kind:`external`,url:n};let r=n.indexOf(`#`),i=r<0?n:n.slice(0,r),a=at(i,t);if(a)return{kind:`doc`,docName:a,anchor:r<0?null:n.slice(r+1)};let o=it(i,t);if(o)return{kind:`doc`,docName:o,anchor:r<0?null:n.slice(r+1)};let s=N5(n,t);if(s)return{kind:`doc`,docName:s.docName,anchor:s.anchor};let c=F5(n);return c&&c!==`md`&&c!==`mdx`?{kind:`asset`,url:n,ext:c}:null}function R5(e,t){let n=e.trim();if(!n)return null;if(I5(n))return{kind:`external`,url:t?`${n}#${t}`:n};let r=F5(n);return r&&r!==`md`&&r!==`mdx`?{kind:`asset`,url:n,ext:r}:{kind:`doc`,docName:n,anchor:t?.trim()||null}}function z5(e,t){let n=e.trim();if(!n||P5.test(n)||n.startsWith(`//`)||n.startsWith(`#`))return null;let r=n.indexOf(`#`),i=((r>=0?n.slice(0,r):n).split(`?`)[0]??``).trim();if(!i)return null;let a=i.startsWith(`/`),o=a?i.slice(1):i,s=a?[]:t.includes(`/`)?t.split(`/`).slice(0,-1):[];for(let e of o.split(`/`))if(e===`..`){if(s.length===0)return null;s.pop()}else e!==`.`&&e!==``&&s.push(e);return s.length===0?null:s.join(`/`)}function B5(e){let t=e;return t.startsWith(`./`)&&(t=t.slice(2)),t.startsWith(`/`)&&(t=t.slice(1)),t}function V5(e){let t=e.lastIndexOf(`/`);return t===-1?e:e.slice(t+1)}function H5(e){let t=e.lastIndexOf(`/`);return t===-1?``:e.slice(0,t)}function U5(e){return e.split(`/`).filter(e=>e!==``)}function W5(e,t){let n=H5(t);return e===``||n===e?!0:n.startsWith(`${e}/`)}function G5(e,t){let n=H5(t);if(e===n)return 0;let r=e===``?n:n.slice(e.length+1);return r===``?0:U5(r).length}function K5(e,t){let n=U5(e),r=U5(t),i=0;for(;i<n.length&&i<r.length&&n[i]===r[i];)i++;return n.length-i+(r.length-i)}function q5(){let e=new Map;function t(t){let n=B5(t);if(n===``)return;let r=V5(n);if(r===``)return;let i=r.toLowerCase(),a=e.get(i);if(!a){e.set(i,[n]);return}a.includes(n)||a.push(n)}function n(t){let n=B5(t),r=V5(n).toLowerCase(),i=e.get(r);if(!i)return;let a=i.indexOf(n);a!==-1&&(i.splice(a,1),i.length===0&&e.delete(r))}function r(e,r){n(e),t(r)}function i(t,n){let r=t.toLowerCase(),i=e.get(r);if(!i||i.length===0)return null;if(i.length===1)return i[0];let a=H5(B5(n)),o=[],s=[];for(let e of i)W5(a,e)?o.push(e):s.push(e);return o.length>0?(e=>{let t=e[0],n=G5(a,t);for(let r=1;r<e.length;r++){let i=e[r],o=G5(a,i);(o<n||o===n&&i<t)&&(t=i,n=o)}return t})(o):(e=>{let t=e[0],n=K5(a,H5(t));for(let r=1;r<e.length;r++){let i=e[r],o=K5(a,H5(i));(o<n||o===n&&i<t)&&(t=i,n=o)}return t})(s)}function a(){let t=new Map;for(let[n,r]of e)t.set(n,[...r]);return t}function o(){e.clear()}return{add:t,remove:n,rename:r,resolveEmbed:i,clear:o,snapshot:a,size:()=>e.size}}function J5(e){if(!e)return[];let t=e.split(`/`),n=[],r=``;for(let e of t)r=r?`${r}/${e}`:e,n.push(r);return n}function Y5(e,t){if(e.size===0)return new Set;if(t===``)return new Set(e);let n=new Set,r=`${t}/`;for(let i of e)(i===t||i.startsWith(r))&&n.add(i);return n}export{J0 as $,lb as $a,JJ as $i,_Q as $n,Xe as $o,QX as $r,u$ as $t,Y8 as A,dP as Aa,WY as Ai,A$ as An,At as Ao,kZ as Ar,l1 as At,n8 as B,Cb as Ba,uX as Bi,NQ as Bn,Ct as Bo,gZ as Br,q$ as Bt,i5 as C,aW as Ca,SX as Ci,j$ as Cn,Pt as Co,tQ as Cr,me as Cs,A1 as Ct,n5 as D,LV as Da,ZY as Di,HQ as Dn,Mt as Do,xZ as Dr,h1 as Dt,Z8 as E,YV as Ea,fX as Ei,n$ as En,jt as Eo,bZ as Er,D1 as Et,F8 as F,wb as Fa,nX as Fi,XQ as Fn,bt as Fo,TZ as Fr,e1 as Ft,c2 as G,Gy as Ga,NY as Gi,FQ as Gn,qe as Go,mZ as Gr,C$ as Gt,c8 as H,pb as Ha,BY as Hi,RQ as Hn,gt as Ho,sZ as Hr,kQ as Ht,R8 as I,yb as Ia,VY as Ii,KQ as In,xt as Io,CZ as Ir,Z$ as It,$0 as J,Yy as Ja,uY as Ji,GQ as Jn,Ge as Jo,fZ as Jr,L$ as Jt,l2 as K,Wy as Ka,MY as Ki,IQ as Kn,Ke as Ko,uZ as Kr,UQ as Kt,B8 as L,Ob as La,tX as Li,OQ as Ln,Tt as Lo,wZ as Lr,K$ as Lt,H8 as M,xb as Ma,aX as Mi,E$ as Mn,vt as Mo,EZ as Mr,n1 as Mt,M8 as N,Db as Na,cX as Ni,V$ as Nn,yt as No,MZ as Nr,t1 as Nt,Q8 as O,IV as Oa,UY as Oi,D$ as On,Ot as Oo,NZ as Or,m1 as Ot,N8 as P,bb as Pa,HY as Pi,H$ as Pn,Et as Po,PZ as Pr,$$ as Pt,X0 as Q,_b as Qa,sY as Qi,gQ as Qn,Ye as Qo,$X as Qr,l$ as Qt,z8 as R,Eb as Ra,$Y as Ri,EQ as Rn,St as Ro,SZ as Rr,Y$ as Rt,f5 as S,iW as Sa,wX as Si,e$ as Sn,It as So,eQ as Sr,P as Ss,k1 as St,X8 as T,uU as Ta,dX as Ti,t$ as Tn,Nt as To,$Z as Tr,E1 as Tt,i2 as U,hb as Ua,SY as Ui,BQ as Un,ht as Uo,cZ as Ur,AQ as Ut,E8 as V,fb as Va,LY as Vi,LQ as Vn,_t as Vo,oZ as Vr,G$ as Vt,s2 as W,Hy as Wa,jY as Wi,VQ as Wn,He as Wo,pZ as Wr,jQ as Wt,Q0 as X,eb as Xa,cY as Xi,xQ as Xn,tt as Xo,aZ as Xr,r$ as Xt,Y0 as Y,Qy as Ya,lY as Yi,TQ as Yn,We as Yo,rZ as Yr,I$ as Yt,Z0 as Z,gb as Za,oY as Zi,CQ as Zn,Je as Zo,tZ as Zr,c$ as Zt,b5 as _,sW as _a,RX as _i,s$ as _n,zt as _o,LZ as _r,xe as _s,W1 as _t,R5 as a,MJ as aa,KX as ai,h$ as an,jy as ao,pQ as ar,lt as as,P0 as at,l5 as b,xW as ba,CX as bi,QQ as bn,Gt as bo,JZ as br,he as bs,P1 as bt,D5 as c,kJ as ca,UX as ci,JQ as cn,Ty as co,uQ as cr,nt as cs,m0 as ct,A5 as d,WJ as da,MX as di,S$ as dn,om as do,RZ as dr,Be as ds,$1 as dt,ZJ as ea,nZ as ei,d$ as en,rb as eo,bQ as er,Ve as es,q0 as et,T5 as f,jJ as fa,jX as fi,z$ as fn,cm as fo,zZ as fr,Re as fs,e0 as ft,y5 as g,EJ as ga,FX as gi,o$ as gn,Kt as go,UZ as gr,Ce as gs,K1 as gt,p5 as h,DJ as ha,OX as hi,i$ as hn,F as ho,HZ as hr,Se as hs,q1 as ht,L5 as i,rY as ia,GX as ii,m$ as in,Ny as io,fQ as ir,$e as is,N0 as it,V8 as j,rN as ja,iX as ji,T$ as jn,Dt as jo,DZ as jr,Q$ as jt,J8 as k,yR as ka,rX as ki,k$ as kn,kt as ko,jZ as kr,i1 as kt,O5 as l,LJ as la,qX as li,B$ as ln,xy as lo,BZ as lr,at as ls,o0 as lt,x5 as m,BJ as ma,kX as mi,x$ as mn,zi as mo,ZZ as mr,Ee as ms,J1 as mt,Y5 as n,qJ as na,XX as ni,_$ as nn,tb as no,mQ as nr,Ze as ns,F0 as nt,z5 as o,NJ as oa,JX as oi,g$ as on,Ay as oo,cQ as or,ft as os,j0 as ot,S5 as p,HJ as pa,NX as pi,w$ as pn,Zd as po,XZ as pr,Te as ps,Z1 as pt,r2 as q,Xy as qa,mY as qi,PQ as qn,Ue as qo,lZ as qr,N$ as qt,q5 as r,nY as ra,ZX as ri,p$ as rn,Fy as ro,dQ as rr,mt as rs,V0 as rt,N5 as s,RJ as sa,HX as si,O$ as sn,Oy as so,lQ as sr,st as ss,u0 as st,J5 as t,GJ as ta,YX as ti,v$ as tn,ub as to,hQ as tr,Qe as ts,H0 as tt,M5 as u,UJ as ua,VX as ui,W$ as un,sm as uo,VZ as ur,ut as us,c0 as ut,v5 as v,lW as va,_X as vi,a$ as vn,Rt as vo,KZ as vr,_e as vs,U1 as vt,o5 as w,GU as wa,xX as wi,M$ as wn,Ft as wo,QZ as wr,fe as ws,N1 as wt,u5 as x,pW as xa,TX as xi,$Q as xn,Lt as xo,YZ as xr,ve as xs,L1 as xt,d5 as y,cW as ya,EX as yi,ZQ as yn,Wt as yo,WZ as yr,ge as ys,H1 as yt,i8 as z,Tb as za,lX as zi,zQ as zn,wt as zo,hZ as zr,J$ as zt};
345
- //# sourceMappingURL=src-BAuCUhtO.mjs.map
345
+ //# sourceMappingURL=src-tAuEvoB8.mjs.map