@opencx/widget 3.0.76 → 3.0.77
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/designs.cjs +3 -3
- package/dist/designs.cjs.map +1 -1
- package/dist/designs.js +10 -9
- package/dist/designs.js.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/react.cjs +1 -1
- package/dist/react.js +2 -2
- package/dist/src/headless/core/__tests__/test-utils.d.ts +36 -0
- package/dist/src/headless/core/api/api-caller.d.ts +37 -1
- package/dist/src/headless/core/api/schema.d.ts +51 -0
- package/dist/src/headless/core/context/active-session-polling.ctx.d.ts +1 -1
- package/dist/src/headless/core/context/message.ctx.d.ts +1 -1
- package/dist/src/headless/core/context/session.ctx.d.ts +2 -1
- package/dist/src/headless/core/index.d.ts +1 -1
- package/dist/src/headless/core/types/{schemas.d.ts → dtos.d.ts} +1 -0
- package/dist/src/headless/core/types/messages.d.ts +1 -1
- package/dist/{useWidgetTrigger-D-OdmCtY.cjs → useWidgetTrigger-Bj4tpdxy.cjs} +2 -2
- package/dist/{useWidgetTrigger-D-OdmCtY.cjs.map → useWidgetTrigger-Bj4tpdxy.cjs.map} +1 -1
- package/dist/{useWidgetTrigger-CJFrgKrO.js → useWidgetTrigger-TmZa8JFh.js} +3 -3
- package/dist/{useWidgetTrigger-CJFrgKrO.js.map → useWidgetTrigger-TmZa8JFh.js.map} +1 -1
- package/dist/{widget.ctx-W1JQt9cl.js → widget.ctx-DRC-z8Ql.js} +112 -102
- package/dist/widget.ctx-DRC-z8Ql.js.map +1 -0
- package/dist/widget.ctx-sL-dW2kY.cjs +5 -0
- package/dist/widget.ctx-sL-dW2kY.cjs.map +1 -0
- package/dist-embed/script.js +5 -5
- package/dist-embed/script.js.map +1 -1
- package/package.json +1 -1
- package/dist/widget.ctx-D_eeZ2xk.cjs +0 -5
- package/dist/widget.ctx-D_eeZ2xk.cjs.map +0 -1
- package/dist/widget.ctx-W1JQt9cl.js.map +0 -1
package/dist/designs.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("react/jsx-runtime"),uu=require("@radix-ui/react-popover"),X=require("react"),W=require("./useWidgetTrigger-D-OdmCtY.cjs"),lu=require("@radix-ui/react-dialog"),le=require("lucide-react"),va=require("clsx"),fr=require("react-dom"),cu=require("@radix-ui/react-slot"),be=require("framer-motion"),du=require("@radix-ui/react-avatar"),hu=require("@radix-ui/react-tooltip"),hi=require("tinycolor2"),fu=require("react-dropzone"),pu=require("@radix-ui/react-dropdown-menu"),Gn=require("zod");function It(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Dn=It(uu),ye=It(X),ze=It(lu),St=It(du),sn=It(hu),me=It(pu);function fi(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}const Ne=st(/[A-Za-z]/),Ae=st(/[\dA-Za-z]/),mu=st(/[#-'*+\--9=?A-Z^-~]/);function Cn(e){return e!==null&&(e<32||e===127)}const pr=st(/\d/),gu=st(/[\dA-Fa-f]/),bu=st(/[!-/:-@[-`{-~]/);function Y(e){return e!==null&&e<-2}function se(e){return e!==null&&(e<0||e===32)}function J(e){return e===-2||e===-1||e===32}const vn=st(new RegExp("\\p{P}|\\p{S}","u")),pt=st(/\s/);function st(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Eu(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}const Pn=function(e){if(e==null)return yu;if(typeof e=="function")return Mn(e);if(typeof e=="object")return Array.isArray(e)?Tu(e):xu(e);if(typeof e=="string")return wu(e);throw new Error("Expected function, string, or object as test")};function Tu(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Pn(e[n]);return Mn(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function xu(e){const t=e;return Mn(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function wu(e){return Mn(t);function t(n){return n&&n.type===e}}function Mn(e){return t;function t(n,r,i){return!!(_u(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function yu(){return!0}function _u(e){return e!==null&&typeof e=="object"&&"type"in e}const Pa=[],Au=!0,mr=!1,Cu="skip";function Ma(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=Pn(i),s=r?-1:1;u(e,void 0,[])();function u(l,c,d){const h=l&&typeof l=="object"?l:{};if(typeof h.type=="string"){const p=typeof h.tagName=="string"?h.tagName:typeof h.name=="string"?h.name:void 0;Object.defineProperty(g,"name",{value:"node ("+(l.type+(p?"<"+p+">":""))+")"})}return g;function g(){let p=Pa,E,y,k;if((!t||a(l,c,d[d.length-1]||void 0))&&(p=ku(n(l,d)),p[0]===mr))return p;if("children"in l&&l.children){const _=l;if(_.children&&p[0]!==Cu)for(y=(r?_.children.length:-1)+s,k=d.concat(_);y>-1&&y<_.children.length;){const S=_.children[y];if(E=u(S,y,k)(),E[0]===mr)return E;y=typeof E[1]=="number"?E[1]:y+s}}return p}}}function ku(e){return Array.isArray(e)?e:typeof e=="number"?[Au,e]:e==null?Pa:[e]}function Nu(e,t,n){const i=Pn((n||{}).ignore||[]),a=Iu(t);let s=-1;for(;++s<a.length;)Ma(e,"text",u);function u(c,d){let h=-1,g;for(;++h<d.length;){const p=d[h],E=g?g.children:void 0;if(i(p,E?E.indexOf(p):void 0,g))return;g=p}if(g)return l(c,d)}function l(c,d){const h=d[d.length-1],g=a[s][0],p=a[s][1];let E=0;const k=h.children.indexOf(c);let _=!1,S=[];g.lastIndex=0;let L=g.exec(c.value);for(;L;){const M=L.index,F={index:L.index,input:L.input,stack:[...d,c]};let I=p(...L,F);if(typeof I=="string"&&(I=I.length>0?{type:"text",value:I}:void 0),I===!1?g.lastIndex=M+1:(E!==M&&S.push({type:"text",value:c.value.slice(E,M)}),Array.isArray(I)?S.push(...I):I&&S.push(I),E=M+L[0].length,_=!0),!g.global)break;L=g.exec(c.value)}return _?(E<c.value.length&&S.push({type:"text",value:c.value.slice(E)}),h.children.splice(k,1,...S)):S=[c],k+S.length}}function Iu(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const i=n[r];t.push([Su(i[0]),Ou(i[1])])}return t}function Su(e){return typeof e=="string"?new RegExp(Eu(e),"g"):e}function Ou(e){return typeof e=="function"?e:function(){return e}}const Qn="phrasing",Xn=["autolink","link","image","label"];function Lu(){return{transforms:[Fu],enter:{literalAutolink:Du,literalAutolinkEmail:Kn,literalAutolinkHttp:Kn,literalAutolinkWww:Kn},exit:{literalAutolink:Bu,literalAutolinkEmail:Mu,literalAutolinkHttp:vu,literalAutolinkWww:Pu}}}function Ru(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Qn,notInConstruct:Xn},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Qn,notInConstruct:Xn},{character:":",before:"[ps]",after:"\\/",inConstruct:Qn,notInConstruct:Xn}]}}function Du(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Kn(e){this.config.enter.autolinkProtocol.call(this,e)}function vu(e){this.config.exit.autolinkProtocol.call(this,e)}function Pu(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function Mu(e){this.config.exit.autolinkEmail.call(this,e)}function Bu(e){this.exit(e)}function Fu(e){Nu(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Hu],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),Uu]],{ignore:["link","linkReference"]})}function Hu(e,t,n,r,i){let a="";if(!Ba(i)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!zu(n)))return!1;const s=ju(n+r);if(!s[0])return!1;const u={type:"link",title:null,url:a+t+s[0],children:[{type:"text",value:t+s[0]}]};return s[1]?[u,{type:"text",value:s[1]}]:u}function Uu(e,t,n,r){return!Ba(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function zu(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function ju(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const i=fi(e,"(");let a=fi(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 Ba(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||pt(n)||vn(n))&&(!t||n!==47)}function Ue(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}Fa.peek=Zu;function Yu(){return{enter:{gfmFootnoteDefinition:qu,gfmFootnoteDefinitionLabelString:Vu,gfmFootnoteCall:Xu,gfmFootnoteCallString:Ku},exit:{gfmFootnoteDefinition:Qu,gfmFootnoteDefinitionLabelString:Gu,gfmFootnoteCall:Ju,gfmFootnoteCallString:$u}}}function Wu(){return{unsafe:[{character:"[",inConstruct:["phrasing","label","reference"]}],handlers:{footnoteDefinition:el,footnoteReference:Fa}}}function qu(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function Vu(){this.buffer()}function Gu(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=Ue(this.sliceSerialize(e)).toLowerCase()}function Qu(e){this.exit(e)}function Xu(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function Ku(){this.buffer()}function $u(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=Ue(this.sliceSerialize(e)).toLowerCase()}function Ju(e){this.exit(e)}function Fa(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const s=n.enter("footnoteReference"),u=n.enter("reference");return a+=i.move(n.safe(n.associationId(e),{...i.current(),before:a,after:"]"})),u(),s(),a+=i.move("]"),a}function Zu(){return"["}function el(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const s=n.enter("footnoteDefinition"),u=n.enter("label");return a+=i.move(n.safe(n.associationId(e),{...i.current(),before:a,after:"]"})),u(),a+=i.move("]:"+(e.children&&e.children.length>0?" ":"")),i.shift(4),a+=i.move(n.indentLines(n.containerFlow(e,i.current()),tl)),s(),a}function tl(e,t,n){return t===0?e:(n?"":" ")+e}const nl=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];Ha.peek=ol;function rl(){return{canContainEols:["delete"],enter:{strikethrough:al},exit:{strikethrough:sl}}}function il(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:nl}],handlers:{delete:Ha}}}function al(e){this.enter({type:"delete",children:[]},e)}function sl(e){this.exit(e)}function Ha(e,t,n,r){const i=n.createTracker(r),a=n.enter("strikethrough");let s=i.move("~~");return s+=n.containerPhrasing(e,{...i.current(),before:s,after:"~"}),s+=i.move("~~"),a(),s}function ol(){return"~"}function ul(e,t={}){const n=(t.align||[]).concat(),r=t.stringLength||cl,i=[],a=[],s=[],u=[];let l=0,c=-1;for(;++c<e.length;){const E=[],y=[];let k=-1;for(e[c].length>l&&(l=e[c].length);++k<e[c].length;){const _=ll(e[c][k]);if(t.alignDelimiters!==!1){const S=r(_);y[k]=S,(u[k]===void 0||S>u[k])&&(u[k]=S)}E.push(_)}a[c]=E,s[c]=y}let d=-1;if(typeof n=="object"&&"length"in n)for(;++d<l;)i[d]=pi(n[d]);else{const E=pi(n);for(;++d<l;)i[d]=E}d=-1;const h=[],g=[];for(;++d<l;){const E=i[d];let y="",k="";E===99?(y=":",k=":"):E===108?y=":":E===114&&(k=":");let _=t.alignDelimiters===!1?1:Math.max(1,u[d]-y.length-k.length);const S=y+"-".repeat(_)+k;t.alignDelimiters!==!1&&(_=y.length+_+k.length,_>u[d]&&(u[d]=_),g[d]=_),h[d]=S}a.splice(1,0,h),s.splice(1,0,g),c=-1;const p=[];for(;++c<a.length;){const E=a[c],y=s[c];d=-1;const k=[];for(;++d<l;){const _=E[d]||"";let S="",L="";if(t.alignDelimiters!==!1){const M=u[d]-(y[d]||0),F=i[d];F===114?S=" ".repeat(M):F===99?M%2?(S=" ".repeat(M/2+.5),L=" ".repeat(M/2-.5)):(S=" ".repeat(M/2),L=S):L=" ".repeat(M)}t.delimiterStart!==!1&&!d&&k.push("|"),t.padding!==!1&&!(t.alignDelimiters===!1&&_==="")&&(t.delimiterStart!==!1||d)&&k.push(" "),t.alignDelimiters!==!1&&k.push(S),k.push(_),t.alignDelimiters!==!1&&k.push(L),t.padding!==!1&&k.push(" "),(t.delimiterEnd!==!1||d!==l-1)&&k.push("|")}p.push(t.delimiterEnd===!1?k.join("").replace(/ +$/,""):k.join(""))}return p.join(`
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("react/jsx-runtime"),uu=require("@radix-ui/react-popover"),X=require("react"),W=require("./useWidgetTrigger-Bj4tpdxy.cjs"),lu=require("@radix-ui/react-dialog"),le=require("lucide-react"),va=require("clsx"),fr=require("react-dom"),cu=require("@radix-ui/react-slot"),be=require("framer-motion"),du=require("@radix-ui/react-avatar"),hu=require("@radix-ui/react-tooltip"),hi=require("tinycolor2"),fu=require("react-dropzone"),pu=require("@radix-ui/react-dropdown-menu"),Gn=require("zod");function It(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Dn=It(uu),ye=It(X),ze=It(lu),St=It(du),sn=It(hu),me=It(pu);function fi(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}const Ne=st(/[A-Za-z]/),Ae=st(/[\dA-Za-z]/),mu=st(/[#-'*+\--9=?A-Z^-~]/);function Cn(e){return e!==null&&(e<32||e===127)}const pr=st(/\d/),gu=st(/[\dA-Fa-f]/),bu=st(/[!-/:-@[-`{-~]/);function Y(e){return e!==null&&e<-2}function se(e){return e!==null&&(e<0||e===32)}function J(e){return e===-2||e===-1||e===32}const vn=st(new RegExp("\\p{P}|\\p{S}","u")),pt=st(/\s/);function st(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Eu(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}const Pn=function(e){if(e==null)return yu;if(typeof e=="function")return Mn(e);if(typeof e=="object")return Array.isArray(e)?Tu(e):xu(e);if(typeof e=="string")return wu(e);throw new Error("Expected function, string, or object as test")};function Tu(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Pn(e[n]);return Mn(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function xu(e){const t=e;return Mn(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function wu(e){return Mn(t);function t(n){return n&&n.type===e}}function Mn(e){return t;function t(n,r,i){return!!(_u(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function yu(){return!0}function _u(e){return e!==null&&typeof e=="object"&&"type"in e}const Pa=[],Au=!0,mr=!1,Cu="skip";function Ma(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=Pn(i),s=r?-1:1;u(e,void 0,[])();function u(l,c,d){const h=l&&typeof l=="object"?l:{};if(typeof h.type=="string"){const p=typeof h.tagName=="string"?h.tagName:typeof h.name=="string"?h.name:void 0;Object.defineProperty(g,"name",{value:"node ("+(l.type+(p?"<"+p+">":""))+")"})}return g;function g(){let p=Pa,E,y,k;if((!t||a(l,c,d[d.length-1]||void 0))&&(p=ku(n(l,d)),p[0]===mr))return p;if("children"in l&&l.children){const _=l;if(_.children&&p[0]!==Cu)for(y=(r?_.children.length:-1)+s,k=d.concat(_);y>-1&&y<_.children.length;){const S=_.children[y];if(E=u(S,y,k)(),E[0]===mr)return E;y=typeof E[1]=="number"?E[1]:y+s}}return p}}}function ku(e){return Array.isArray(e)?e:typeof e=="number"?[Au,e]:e==null?Pa:[e]}function Nu(e,t,n){const i=Pn((n||{}).ignore||[]),a=Iu(t);let s=-1;for(;++s<a.length;)Ma(e,"text",u);function u(c,d){let h=-1,g;for(;++h<d.length;){const p=d[h],E=g?g.children:void 0;if(i(p,E?E.indexOf(p):void 0,g))return;g=p}if(g)return l(c,d)}function l(c,d){const h=d[d.length-1],g=a[s][0],p=a[s][1];let E=0;const k=h.children.indexOf(c);let _=!1,S=[];g.lastIndex=0;let L=g.exec(c.value);for(;L;){const M=L.index,F={index:L.index,input:L.input,stack:[...d,c]};let I=p(...L,F);if(typeof I=="string"&&(I=I.length>0?{type:"text",value:I}:void 0),I===!1?g.lastIndex=M+1:(E!==M&&S.push({type:"text",value:c.value.slice(E,M)}),Array.isArray(I)?S.push(...I):I&&S.push(I),E=M+L[0].length,_=!0),!g.global)break;L=g.exec(c.value)}return _?(E<c.value.length&&S.push({type:"text",value:c.value.slice(E)}),h.children.splice(k,1,...S)):S=[c],k+S.length}}function Iu(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const i=n[r];t.push([Su(i[0]),Ou(i[1])])}return t}function Su(e){return typeof e=="string"?new RegExp(Eu(e),"g"):e}function Ou(e){return typeof e=="function"?e:function(){return e}}const Qn="phrasing",Xn=["autolink","link","image","label"];function Lu(){return{transforms:[Fu],enter:{literalAutolink:Du,literalAutolinkEmail:Kn,literalAutolinkHttp:Kn,literalAutolinkWww:Kn},exit:{literalAutolink:Bu,literalAutolinkEmail:Mu,literalAutolinkHttp:vu,literalAutolinkWww:Pu}}}function Ru(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Qn,notInConstruct:Xn},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Qn,notInConstruct:Xn},{character:":",before:"[ps]",after:"\\/",inConstruct:Qn,notInConstruct:Xn}]}}function Du(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Kn(e){this.config.enter.autolinkProtocol.call(this,e)}function vu(e){this.config.exit.autolinkProtocol.call(this,e)}function Pu(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function Mu(e){this.config.exit.autolinkEmail.call(this,e)}function Bu(e){this.exit(e)}function Fu(e){Nu(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Hu],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),Uu]],{ignore:["link","linkReference"]})}function Hu(e,t,n,r,i){let a="";if(!Ba(i)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!zu(n)))return!1;const s=ju(n+r);if(!s[0])return!1;const u={type:"link",title:null,url:a+t+s[0],children:[{type:"text",value:t+s[0]}]};return s[1]?[u,{type:"text",value:s[1]}]:u}function Uu(e,t,n,r){return!Ba(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function zu(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function ju(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const i=fi(e,"(");let a=fi(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 Ba(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||pt(n)||vn(n))&&(!t||n!==47)}function Ue(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}Fa.peek=Zu;function Yu(){return{enter:{gfmFootnoteDefinition:qu,gfmFootnoteDefinitionLabelString:Vu,gfmFootnoteCall:Xu,gfmFootnoteCallString:Ku},exit:{gfmFootnoteDefinition:Qu,gfmFootnoteDefinitionLabelString:Gu,gfmFootnoteCall:Ju,gfmFootnoteCallString:$u}}}function Wu(){return{unsafe:[{character:"[",inConstruct:["phrasing","label","reference"]}],handlers:{footnoteDefinition:el,footnoteReference:Fa}}}function qu(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function Vu(){this.buffer()}function Gu(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=Ue(this.sliceSerialize(e)).toLowerCase()}function Qu(e){this.exit(e)}function Xu(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function Ku(){this.buffer()}function $u(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=Ue(this.sliceSerialize(e)).toLowerCase()}function Ju(e){this.exit(e)}function Fa(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const s=n.enter("footnoteReference"),u=n.enter("reference");return a+=i.move(n.safe(n.associationId(e),{...i.current(),before:a,after:"]"})),u(),s(),a+=i.move("]"),a}function Zu(){return"["}function el(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const s=n.enter("footnoteDefinition"),u=n.enter("label");return a+=i.move(n.safe(n.associationId(e),{...i.current(),before:a,after:"]"})),u(),a+=i.move("]:"+(e.children&&e.children.length>0?" ":"")),i.shift(4),a+=i.move(n.indentLines(n.containerFlow(e,i.current()),tl)),s(),a}function tl(e,t,n){return t===0?e:(n?"":" ")+e}const nl=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];Ha.peek=ol;function rl(){return{canContainEols:["delete"],enter:{strikethrough:al},exit:{strikethrough:sl}}}function il(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:nl}],handlers:{delete:Ha}}}function al(e){this.enter({type:"delete",children:[]},e)}function sl(e){this.exit(e)}function Ha(e,t,n,r){const i=n.createTracker(r),a=n.enter("strikethrough");let s=i.move("~~");return s+=n.containerPhrasing(e,{...i.current(),before:s,after:"~"}),s+=i.move("~~"),a(),s}function ol(){return"~"}function ul(e,t={}){const n=(t.align||[]).concat(),r=t.stringLength||cl,i=[],a=[],s=[],u=[];let l=0,c=-1;for(;++c<e.length;){const E=[],y=[];let k=-1;for(e[c].length>l&&(l=e[c].length);++k<e[c].length;){const _=ll(e[c][k]);if(t.alignDelimiters!==!1){const S=r(_);y[k]=S,(u[k]===void 0||S>u[k])&&(u[k]=S)}E.push(_)}a[c]=E,s[c]=y}let d=-1;if(typeof n=="object"&&"length"in n)for(;++d<l;)i[d]=pi(n[d]);else{const E=pi(n);for(;++d<l;)i[d]=E}d=-1;const h=[],g=[];for(;++d<l;){const E=i[d];let y="",k="";E===99?(y=":",k=":"):E===108?y=":":E===114&&(k=":");let _=t.alignDelimiters===!1?1:Math.max(1,u[d]-y.length-k.length);const S=y+"-".repeat(_)+k;t.alignDelimiters!==!1&&(_=y.length+_+k.length,_>u[d]&&(u[d]=_),g[d]=_),h[d]=S}a.splice(1,0,h),s.splice(1,0,g),c=-1;const p=[];for(;++c<a.length;){const E=a[c],y=s[c];d=-1;const k=[];for(;++d<l;){const _=E[d]||"";let S="",L="";if(t.alignDelimiters!==!1){const M=u[d]-(y[d]||0),F=i[d];F===114?S=" ".repeat(M):F===99?M%2?(S=" ".repeat(M/2+.5),L=" ".repeat(M/2-.5)):(S=" ".repeat(M/2),L=S):L=" ".repeat(M)}t.delimiterStart!==!1&&!d&&k.push("|"),t.padding!==!1&&!(t.alignDelimiters===!1&&_==="")&&(t.delimiterStart!==!1||d)&&k.push(" "),t.alignDelimiters!==!1&&k.push(S),k.push(_),t.alignDelimiters!==!1&&k.push(L),t.padding!==!1&&k.push(" "),(t.delimiterEnd!==!1||d!==l-1)&&k.push("|")}p.push(t.delimiterEnd===!1?k.join("").replace(/ +$/,""):k.join(""))}return p.join(`
|
|
2
2
|
`)}function ll(e){return e==null?"":String(e)}function cl(e){return e.length}function pi(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}const mi={}.hasOwnProperty;function Ua(e,t){const n=t||{};function r(i,...a){let s=r.invalid;const u=r.handlers;if(i&&mi.call(i,e)){const l=String(i[e]);s=mi.call(u,l)?u[l]:r.unknown}if(s)return s.call(this,i,...a)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}function dl(e,t,n,r){const i=n.enter("blockquote"),a=n.createTracker(r);a.move("> "),a.shift(2);const s=n.indentLines(n.containerFlow(e,a.current()),hl);return i(),s}function hl(e,t,n){return">"+(n?"":" ")+e}function fl(e,t){return gi(e,t.inConstruct,!0)&&!gi(e,t.notInConstruct,!1)}function gi(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function bi(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
|
|
3
3
|
`&&fl(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?"":" ";return`\\
|
|
4
4
|
`}function pl(e,t){const n=String(e);let r=n.indexOf(t),i=r,a=0,s=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===i?++a>s&&(s=a):a=1,i=r+t.length,r=n.indexOf(t,i);return s}function ml(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function gl(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function bl(e,t,n,r){const i=gl(n),a=e.value||"",s=i==="`"?"GraveAccent":"Tilde";if(ml(e,n)){const h=n.enter("codeIndented"),g=n.indentLines(a,El);return h(),g}const u=n.createTracker(r),l=i.repeat(Math.max(pl(a,i)+1,3)),c=n.enter("codeFenced");let d=u.move(l);if(e.lang){const h=n.enter(`codeFencedLang${s}`);d+=u.move(n.safe(e.lang,{before:d,after:" ",encode:["`"],...u.current()})),h()}if(e.lang&&e.meta){const h=n.enter(`codeFencedMeta${s}`);d+=u.move(" "),d+=u.move(n.safe(e.meta,{before:d,after:`
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
`}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
|
|
27
27
|
`}),n}function $i(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function Ji(e,t){const n=ff(e,t),r=n.one(e,void 0),i=df(n),a=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return i&&a.children.push({type:"text",value:`
|
|
28
28
|
`},i),a}function Ef(e,t){return e&&"run"in e?async function(n,r){const i=Ji(n,{file:r,...t});await e.run(i,r)}:function(n,r){return Ji(n,{file:r,...e||t})}}function Zi(e){if(e)throw e}var wn=Object.prototype.hasOwnProperty,js=Object.prototype.toString,ea=Object.defineProperty,ta=Object.getOwnPropertyDescriptor,na=function(t){return typeof Array.isArray=="function"?Array.isArray(t):js.call(t)==="[object Array]"},ra=function(t){if(!t||js.call(t)!=="[object Object]")return!1;var n=wn.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&wn.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var i;for(i in t);return typeof i>"u"||wn.call(t,i)},ia=function(t,n){ea&&n.name==="__proto__"?ea(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},aa=function(t,n){if(n==="__proto__")if(wn.call(t,n)){if(ta)return ta(t,n).value}else return;return t[n]},Tf=function e(){var t,n,r,i,a,s,u=arguments[0],l=1,c=arguments.length,d=!1;for(typeof u=="boolean"&&(d=u,u=arguments[1]||{},l=2),(u==null||typeof u!="object"&&typeof u!="function")&&(u={});l<c;++l)if(t=arguments[l],t!=null)for(n in t)r=aa(u,n),i=aa(t,n),u!==i&&(d&&i&&(ra(i)||(a=na(i)))?(a?(a=!1,s=r&&na(r)?r:[]):s=r&&ra(r)?r:{},ia(u,{name:n,newValue:e(d,s,i)})):typeof i<"u"&&ia(u,{name:n,newValue:i}));return u};const nr=W.getDefaultExportFromCjs(Tf);function wr(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function xf(){const e=[],t={run:n,use:r};return t;function n(...i){let a=-1;const s=i.pop();if(typeof s!="function")throw new TypeError("Expected function as last argument, not "+s);u(null,...i);function u(l,...c){const d=e[++a];let h=-1;if(l){s(l);return}for(;++h<i.length;)(c[h]===null||c[h]===void 0)&&(c[h]=i[h]);i=c,d?wf(d,u)(...c):s(null,...c)}}function r(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function wf(e,t){let n;return r;function r(...s){const u=e.length>s.length;let l;u&&s.push(i);try{l=e.apply(this,s)}catch(c){const d=c;if(u&&n)throw d;return i(d)}u||(l&&l.then&&typeof l.then=="function"?l.then(a,i):l instanceof Error?i(l):a(l))}function i(s,...u){n||(n=!0,t(s,...u))}function a(s){i(null,s)}}const Ye={basename:yf,dirname:_f,extname:Af,join:Cf,sep:"/"};function yf(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');cn(e);let n=0,r=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else r<0&&(a=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let s=-1,u=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else s<0&&(a=!0,s=i+1),u>-1&&(e.codePointAt(i)===t.codePointAt(u--)?u<0&&(r=i):(u=-1,r=s));return n===r?r=s:r<0&&(r=e.length),e.slice(n,r)}function _f(e){if(cn(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function Af(e){cn(e);let t=e.length,n=-1,r=0,i=-1,a=0,s;for(;t--;){const u=e.codePointAt(t);if(u===47){if(s){r=t+1;break}continue}n<0&&(s=!0,n=t+1),u===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||n<0||a===0||a===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function Cf(...e){let t=-1,n;for(;++t<e.length;)cn(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":kf(n)}function kf(e){cn(e);const t=e.codePointAt(0)===47;let n=Nf(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function Nf(e,t){let n="",r=0,i=-1,a=0,s=-1,u,l;for(;++s<=e.length;){if(s<e.length)u=e.codePointAt(s);else{if(u===47)break;u=47}if(u===47){if(!(i===s-1||a===1))if(i!==s-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(l=n.lastIndexOf("/"),l!==n.length-1){l<0?(n="",r=0):(n=n.slice(0,l),r=n.length-1-n.lastIndexOf("/")),i=s,a=0;continue}}else if(n.length>0){n="",r=0,i=s,a=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,s):n=e.slice(i+1,s),r=s-i-1;i=s,a=0}else u===46&&a>-1?a++:a=-1}return n}function cn(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const If={cwd:Sf};function Sf(){return"/"}function yr(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function Of(e){if(typeof e=="string")e=new URL(e);else if(!yr(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return Lf(e)}function Lf(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const r=t.codePointAt(n+2);if(r===70||r===102){const i=new TypeError("File URL path must not include encoded / characters");throw i.code="ERR_INVALID_FILE_URL_PATH",i}}return decodeURIComponent(t)}const rr=["history","path","basename","stem","extname","dirname"];class Ys{constructor(t){let n;t?yr(t)?n={path:t}:typeof t=="string"||Rf(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":If.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<rr.length;){const a=rr[r];a in n&&n[a]!==void 0&&n[a]!==null&&(this[a]=a==="history"?[...n[a]]:n[a])}let i;for(i in n)rr.includes(i)||(this[i]=n[i])}get basename(){return typeof this.path=="string"?Ye.basename(this.path):void 0}set basename(t){ar(t,"basename"),ir(t,"basename"),this.path=Ye.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?Ye.dirname(this.path):void 0}set dirname(t){sa(this.basename,"dirname"),this.path=Ye.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?Ye.extname(this.path):void 0}set extname(t){if(ir(t,"extname"),sa(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Ye.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){yr(t)&&(t=Of(t)),ar(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?Ye.basename(this.path,this.extname):void 0}set stem(t){ar(t,"stem"),ir(t,"stem"),this.path=Ye.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const i=this.message(t,n,r);throw i.fatal=!0,i}info(t,n,r){const i=this.message(t,n,r);return i.fatal=void 0,i}message(t,n,r){const i=new Ce(t,n,r);return this.path&&(i.name=this.path+":"+i.name,i.file=this.path),i.fatal=!1,this.messages.push(i),i}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function ir(e,t){if(e&&e.includes(Ye.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Ye.sep+"`")}function ar(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function sa(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function Rf(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Df=function(e){const r=this.constructor.prototype,i=r[e],a=function(){return i.apply(a,arguments)};return Object.setPrototypeOf(a,r),a},vf={}.hasOwnProperty;class Vr extends Df{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=xf()}copy(){const t=new Vr;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(nr(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(ur("data",this.frozen),this.namespace[t]=n,this):vf.call(this.namespace,t)&&this.namespace[t]||void 0:t?(ur("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);const i=n.call(t,...r);typeof i=="function"&&this.transformers.use(i)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=En(t),r=this.parser||this.Parser;return sr("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),sr("process",this.parser||this.Parser),or("process",this.compiler||this.Compiler),n?i(void 0,n):new Promise(i);function i(a,s){const u=En(t),l=r.parse(u);r.run(l,u,function(d,h,g){if(d||!h||!g)return c(d);const p=h,E=r.stringify(p,g);Bf(E)?g.value=E:g.result=E,c(d,g)});function c(d,h){d||!h?s(d):a?a(h):n(void 0,h)}}}processSync(t){let n=!1,r;return this.freeze(),sr("processSync",this.parser||this.Parser),or("processSync",this.compiler||this.Compiler),this.process(t,i),ua("processSync","process",n),r;function i(a,s){n=!0,Zi(a),r=s}}run(t,n,r){oa(t),this.freeze();const i=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?a(void 0,r):new Promise(a);function a(s,u){const l=En(n);i.run(t,l,c);function c(d,h,g){const p=h||t;d?u(d):s?s(p):r(void 0,p,g)}}}runSync(t,n){let r=!1,i;return this.run(t,n,a),ua("runSync","run",r),i;function a(s,u){Zi(s),i=u,r=!0}}stringify(t,n){this.freeze();const r=En(n),i=this.compiler||this.Compiler;return or("stringify",i),oa(t),i(t,r)}use(t,...n){const r=this.attachers,i=this.namespace;if(ur("use",this.frozen),t!=null)if(typeof t=="function")l(t,n);else if(typeof t=="object")Array.isArray(t)?u(t):s(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function a(c){if(typeof c=="function")l(c,[]);else if(typeof c=="object")if(Array.isArray(c)){const[d,...h]=c;l(d,h)}else s(c);else throw new TypeError("Expected usable value, not `"+c+"`")}function s(c){if(!("plugins"in c)&&!("settings"in c))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");u(c.plugins),c.settings&&(i.settings=nr(!0,i.settings,c.settings))}function u(c){let d=-1;if(c!=null)if(Array.isArray(c))for(;++d<c.length;){const h=c[d];a(h)}else throw new TypeError("Expected a list of plugins, not `"+c+"`")}function l(c,d){let h=-1,g=-1;for(;++h<r.length;)if(r[h][0]===c){g=h;break}if(g===-1)r.push([c,...d]);else if(d.length>0){let[p,...E]=d;const y=r[g][1];wr(y)&&wr(p)&&(p=nr(!0,y,p)),r[g]=[c,p,...E]}}}}const Pf=new Vr().freeze();function sr(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function or(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function ur(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function oa(e){if(!wr(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function ua(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function En(e){return Mf(e)?e:new Ys(e)}function Mf(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function Bf(e){return typeof e=="string"||Ff(e)}function Ff(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Hf="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",la=[],ca={allowDangerousHtml:!0},Uf=/^(https?|ircs?|mailto|xmpp)$/i,zf=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function jf(e){const t=e.allowedElements,n=e.allowElement,r=e.children||"",i=e.className,a=e.components,s=e.disallowedElements,u=e.rehypePlugins||la,l=e.remarkPlugins||la,c=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...ca}:ca,d=e.skipHtml,h=e.unwrapDisallowed,g=e.urlTransform||Yf,p=Pf().use(L0).use(l).use(Ef,c).use(u),E=new Ys;typeof r=="string"&&(E.value=r);for(const S of zf)Object.hasOwn(e,S.from)&&(""+S.from+(S.to?"use `"+S.to+"` instead":"remove it")+Hf+S.id,void 0);const y=p.parse(E);let k=p.runSync(y,E);return i&&(k={type:"element",tagName:"div",properties:{className:i},children:k.type==="root"?k.children:[k]}),Bn(k,_),Fh(k,{Fragment:f.Fragment,components:a,ignoreInvalidStyle:!0,jsx:f.jsx,jsxs:f.jsxs,passKeys:!0,passNode:!0});function _(S,L,M){if(S.type==="raw"&&M&&typeof L=="number")return d?M.children.splice(L,1):M.children[L]={type:"text",value:S.value},L;if(S.type==="element"){let F;for(F in tr)if(Object.hasOwn(tr,F)&&Object.hasOwn(S.properties,F)){const I=S.properties[F],j=tr[F];(j===null||j.includes(S.tagName))&&(S.properties[F]=g(String(I||""),F,S))}}if(S.type==="element"){let F=t?!t.includes(S.tagName):s?s.includes(S.tagName):!1;if(!F&&n&&typeof L=="number"&&(F=!n(S,L,M)),F&&M&&typeof L=="number")return h&&S.children?M.children.splice(L,1,...S.children):M.children.splice(L,1),L}}}function Yf(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),i=e.indexOf("/");return t<0||i>-1&&t>i||n>-1&&t>n||r>-1&&t>r||Uf.test(e.slice(0,t))?e:""}const Ws=X.memo(jf,(e,t)=>e.children===t.children&&e.className===t.className),da=/[#.]/g;function Wf(e,t){const n=e||"",r={};let i=0,a,s;for(;i<n.length;){da.lastIndex=i;const u=da.exec(n),l=n.slice(i,u?u.index:n.length);l&&(a?a==="#"?r.id=l:Array.isArray(r.className)?r.className.push(l):r.className=[l]:s=l,i+=l.length),u&&(a=u[0],i++)}return{type:"element",tagName:s||t||"div",properties:r,children:[]}}const _r={}.hasOwnProperty;function qs(e,t,n){const r=n&&Qf(n);function i(a,s,...u){let l=-1,c;if(a==null){c={type:"root",children:[]};const d=s;u.unshift(d)}else if(c=Wf(a,t),c.tagName=c.tagName.toLowerCase(),r&&_r.call(r,c.tagName)&&(c.tagName=r[c.tagName]),qf(s))u.unshift(s);else{let d;for(d in s)_r.call(s,d)&&Vf(e,c.properties,d,s[d])}for(;++l<u.length;)Ar(c.children,u[l]);return c.type==="element"&&c.tagName==="template"&&(c.content={type:"root",children:c.children},c.children=[]),c}return i}function qf(e){if(e===null||typeof e!="object"||Array.isArray(e))return!0;if(typeof e.type!="string")return!1;const t=e,n=Object.keys(e);for(const r of n){const i=t[r];if(i&&typeof i=="object"){if(!Array.isArray(i))return!0;const a=i;for(const s of a)if(typeof s!="number"&&typeof s!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function Vf(e,t,n,r){const i=Hn(e,n);let a=-1,s;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;s=r}else typeof r=="boolean"?s=r:typeof r=="string"?i.spaceSeparated?s=vi(r):i.commaSeparated?s=Si(r):i.commaOrSpaceSeparated?s=vi(Si(r).join(" ")):s=ha(i,i.property,r):Array.isArray(r)?s=r.concat():s=i.property==="style"?Gf(r):String(r);if(Array.isArray(s)){const u=[];for(;++a<s.length;){const l=ha(i,i.property,s[a]);u[a]=l}s=u}if(i.property==="className"&&Array.isArray(t.className)){const u=s;s=t.className.concat(u)}t[i.property]=s}}function Ar(e,t){let n=-1;if(t!=null)if(typeof t=="string"||typeof t=="number")e.push({type:"text",value:String(t)});else if(Array.isArray(t))for(;++n<t.length;)Ar(e,t[n]);else if(typeof t=="object"&&"type"in t)t.type==="root"?Ar(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function ha(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||tn(n)===tn(t)))return!0}return n}function Gf(e){const t=[];let n;for(n in e)_r.call(e,n)&&t.push([n,e[n]].join(": "));return t.join("; ")}function Qf(e){const t={};let n=-1;for(;++n<e.length;)t[e[n].toLowerCase()]=e[n];return t}const Xf=["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"],Kf=qs(ln,"div"),$f=qs(ot,"g",Xf);function Jf(e){const t=String(e),n=[];return{toOffset:i,toPoint:r};function r(a){if(typeof a=="number"&&a>-1&&a<=t.length){let s=0;for(;;){let u=n[s];if(u===void 0){const l=fa(t,n[s-1]);u=l===-1?t.length+1:l+1,n[s]=u}if(u>a)return{line:s+1,column:a-(s>0?n[s-1]:0)+1,offset:a};s++}}}function i(a){if(a&&typeof a.line=="number"&&typeof a.column=="number"&&!Number.isNaN(a.line)&&!Number.isNaN(a.column)){for(;n.length<a.line;){const u=n[n.length-1],l=fa(t,u),c=l===-1?t.length+1:l+1;if(u===c)break;n.push(c)}const s=(a.line>1?n[a.line-2]:0)+a.column-1;if(s<n[a.line-1])return s}}}function fa(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
|
|
29
|
-
`,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const ht={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/"},Vs={}.hasOwnProperty,Zf=Object.prototype;function ep(e,t){const n=t||{};return Gr({file:n.file||void 0,location:!1,schema:n.space==="svg"?ot:ln,verbose:n.verbose||!1},e)}function Gr(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},yn(e,r,n),n}case"#document":case"#document-fragment":{const r=t,i="mode"in r?r.mode==="quirks"||r.mode==="limited-quirks":!1;if(n={type:"root",children:Gs(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){const a=String(e.file),s=Jf(a),u=s.toPoint(0),l=s.toPoint(a.length);n.position={start:u,end:l}}return n}case"#documentType":{const r=t;return n={type:"doctype"},yn(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},yn(e,r,n),n}default:return n=tp(e,t),n}}function Gs(e,t){let n=-1;const r=[];for(;++n<t.length;){const i=Gr(e,t[n]);r.push(i)}return r}function tp(e,t){const n=e.schema;e.schema=t.namespaceURI===ht.svg?ot:ln;let r=-1;const i={};for(;++r<t.attrs.length;){const u=t.attrs[r],l=(u.prefix?u.prefix+":":"")+u.name;Vs.call(Zf,l)||(i[l]=u.value)}const s=(e.schema.space==="svg"?$f:Kf)(t.tagName,i,Gs(e,t.childNodes));if(yn(e,t,s),s.tagName==="template"){const u=t,l=u.sourceCodeLocation,c=l&&l.startTag&&yt(l.startTag),d=l&&l.endTag&&yt(l.endTag),h=Gr(e,u.content);c&&d&&e.file&&(h.position={start:c.end,end:d.start}),s.content=h}return e.schema=n,s}function yn(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=np(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function np(e,t,n){const r=yt(n);if(t.type==="element"){const i=t.children[t.children.length-1];if(r&&!n.endTag&&i&&i.position&&i.position.end&&(r.end=Object.assign({},i.position.end)),e.verbose){const a={};let s;if(n.attrs)for(s in n.attrs)Vs.call(n.attrs,s)&&(a[Hn(e.schema,s).property]=yt(n.attrs[s]));n.startTag;const u=yt(n.startTag),l=n.endTag?yt(n.endTag):void 0,c={opening:u};l&&(c.closing=l),c.properties=a,t.data={position:c}}}return r}function yt(e){const t=pa({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=pa({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function pa(e){return e.line&&e.column?e:void 0}const rp={},ip={}.hasOwnProperty,Qs=Ua("type",{handlers:{root:sp,element:dp,text:lp,comment:cp,doctype:up}});function ap(e,t){const r=(t||rp).space;return Qs(e,r==="svg"?ot:ln)}function sp(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=Qr(e.children,n,t),Rt(e,n),n}function op(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=Qr(e.children,n,t),Rt(e,n),n}function up(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return Rt(e,t),t}function lp(e){const t={nodeName:"#text",value:e.value,parentNode:null};return Rt(e,t),t}function cp(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return Rt(e,t),t}function dp(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=ot);const i=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&ip.call(e.properties,a)){const l=hp(r,a,e.properties[a]);l&&i.push(l)}}const s=r.space,u={nodeName:e.tagName,tagName:e.tagName,attrs:i,namespaceURI:ht[s],childNodes:[],parentNode:null};return u.childNodes=Qr(e.children,u,r),Rt(e,u),e.tagName==="template"&&e.content&&(u.content=op(e.content,r)),u}function hp(e,t,n){const r=Hn(e,t);if(n===!1||n===null||n===void 0||typeof n=="number"&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?bs(n):ks(n));const i={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=i.name.indexOf(":");a<0?i.prefix="":(i.name=i.name.slice(a+1),i.prefix=r.attribute.slice(0,a)),i.namespace=ht[r.space]}return i}function Qr(e,t,n){let r=-1;const i=[];if(e)for(;++r<e.length;){const a=Qs(e[r],n);a.parentNode=t,i.push(a)}return i}function Rt(e,t){const n=e.position;n&&n.start&&n.end&&(n.start.offset,n.end.offset,t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}const fp=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],pp=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]),he="�";var m;(function(e){e[e.EOF=-1]="EOF",e[e.NULL=0]="NULL",e[e.TABULATION=9]="TABULATION",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.LINE_FEED=10]="LINE_FEED",e[e.FORM_FEED=12]="FORM_FEED",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_0=48]="DIGIT_0",e[e.DIGIT_9=57]="DIGIT_9",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",e[e.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_A=97]="LATIN_SMALL_A",e[e.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(m||(m={}));const Ie={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function Xs(e){return e>=55296&&e<=57343}function mp(e){return e>=56320&&e<=57343}function gp(e,t){return(e-55296)*1024+9216+t}function Ks(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function $s(e){return e>=64976&&e<=65007||pp.has(e)}var N;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(N||(N={}));const bp=65536;class Ep{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=bp,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t,n){const{line:r,col:i,offset:a}=this,s=i+n,u=a+n;return{code:t,startLine:r,endLine:r,startCol:s,endCol:s,startOffset:u,endOffset:u}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(mp(n))return this.pos++,this._addGap(),gp(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,m.EOF;return this._err(N.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r<t.length;r++)if((this.html.charCodeAt(this.pos+r)|32)!==t.charCodeAt(r))return!1;return!0}peek(t){const n=this.pos+t;if(n>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,m.EOF;const r=this.html.charCodeAt(n);return r===m.CARRIAGE_RETURN?m.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,m.EOF;let t=this.html.charCodeAt(this.pos);return t===m.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,m.LINE_FEED):t===m.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,Xs(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===m.LINE_FEED||t===m.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){Ks(t)?this._err(N.controlCharacterInInputStream):$s(t)&&this._err(N.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var $;(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"})($||($={}));function Js(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 Zs=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏઑඡ༉༦ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲϏϢϸontourIntegraìȹoɴ\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲy;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱còJTabcdfgorstרׯؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ߂ߐĀiyޱrc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣসে্ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४ĀnrࢃgleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpwਖਛgȀLRlr৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼અઋp;椅y;䐜Ādl੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑඞcy;䐊cute;䅃ƀaeyહાron;䅇dil;䅅;䐝ƀgswે૰ativeƀMTV૨ediumSpace;怋hiĀcn૦ëeryThiîtedĀGLଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷreak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪௫ఄ಄ದൡඅ櫬Āoungruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater;EFGLSTஶஷ扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨setĀ;Eೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂෛ෧ขภยา฿ไlig;䅒cute耻Ó䃓Āiyීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲcr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬืde耻Õ䃕es;樷ml耻Ö䃖erĀBP๋Āar๐๓r;怾acĀek๚;揞et;掴arenthesis;揜ҀacfhilorsງຊຏຒດຝະrtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ檻cedesȀ;EST່້扺qual;檯lantEqual;扼ilde;找me;怳Ādpuct;戏ortionĀ;aȥl;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL憒ar;懥eftArrow;懄eiling;按oǵ\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄቕቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHcቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗ĀeiቻDzኀ\0ኇefore;戴a;䎘ĀcnኘkSpace;쀀 Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtèa;䎖r;愨pf;愤cr;쀀𝒵ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒;Eaeiopᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;eᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;eᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰᝃᝈ០៦ᠹᡐᜍ᥈ᥰot;櫭ĀcrᛶkȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;tbrk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯᝳ;䎲;愶een;扬r;쀀𝔟gcostuvwឍឝឳេ៕៛ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀakoᠦᠵĀcn៲ᠣkƀlst֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ;敛;敘;攘;攔;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģbar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;elƀ;bhᥨᥩᥫ䁜;槅sub;柈ŬᥴlĀ;e怢t»pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭒\0᯽\0ᰌƀcprᦲute;䄇̀;abcdsᦿᧀᧄ᧕᧙戩nd;橄rcup;橉Āau᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r;Ecefms᩠ᩢᩫ᪤᪪旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ\0\0aĀ;t䀬;䁀ƀ;fl戁îᅠeĀmxent»eóɍǧ\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯delprvw᭠᭬᭷ᮂᮬᯔarrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;pᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰻᰿ᱝᱩᱵᲞᲬᲷᴍᵻᶑᶫᶻ᷆᷍ròar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂᳖᳜᳠mƀ;oș᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄĀDoḆᴴoôĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»ṺƀaeiἒἚls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧\0耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₥₰₴⃰℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽ƀ;qsؾٌlanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqrⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0proør;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼ròòΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonóquigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roøurĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨íistĀ;sடr;쀀𝔫ȀEest⩦⩹⩼ƀ;qs⩭ƀ;qs⩴lanôií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast⭕⭚⭟lleìl;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖchimpqu⮽⯍⯙⬄⯤⯯Ȁ;cerല⯆ഷ⯉uå;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭ååഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñĀ;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;cⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācrir;榿;쀀𝔬ͯ\0\0\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕⶥⶨrò᪀Āirⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔǒr;榷rp;榹;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ\0\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ脀¶;l䂶leìЃɩ\0\0m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳ᤈ⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t⾴ïrel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⋢⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔ABHabcdefhilmnoprstuxけさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstwガクシスゼゾダッデナp;極Ā;fゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ìâヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘rrowĀ;tㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowóarpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓ròaòՑ;怏oustĀ;a㈞掱che»mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì耻䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;qኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫwar;椪lig耻ß䃟㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rëƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproøim»ኬsðኞĀas㚺㚮ðrn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈadempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xôheadĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roðtré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜtré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),Tp=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(e=>e.charCodeAt(0)));var lr;const xp=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]]),wp=(lr=String.fromCodePoint)!==null&&lr!==void 0?lr:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|e&1023),t+=String.fromCharCode(e),t};function yp(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=xp.get(e))!==null&&t!==void 0?t:e}var we;(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"})(we||(we={}));const _p=32;var at;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(at||(at={}));function Cr(e){return e>=we.ZERO&&e<=we.NINE}function Ap(e){return e>=we.UPPER_A&&e<=we.UPPER_F||e>=we.LOWER_A&&e<=we.LOWER_F}function Cp(e){return e>=we.UPPER_A&&e<=we.UPPER_Z||e>=we.LOWER_A&&e<=we.LOWER_Z||Cr(e)}function kp(e){return e===we.EQUALS||Cp(e)}var xe;(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"})(xe||(xe={}));var Ke;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Ke||(Ke={}));class eo{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=xe.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Ke.Strict}startEntity(t){this.decodeMode=t,this.state=xe.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case xe.EntityStart:return t.charCodeAt(n)===we.NUM?(this.state=xe.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=xe.NamedEntity,this.stateNamedEntity(t,n));case xe.NumericStart:return this.stateNumericStart(t,n);case xe.NumericDecimal:return this.stateNumericDecimal(t,n);case xe.NumericHex:return this.stateNumericHex(t,n);case xe.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|_p)===we.LOWER_X?(this.state=xe.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=xe.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,i){if(n!==r){const a=r-n;this.result=this.result*Math.pow(i,a)+parseInt(t.substr(n,a),i),this.consumed+=a}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(Cr(i)||Ap(i))n+=1;else return this.addToNumericResult(t,r,n,16),this.emitNumericEntity(i,3)}return this.addToNumericResult(t,r,n,16),-1}stateNumericDecimal(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(Cr(i))n+=1;else return this.addToNumericResult(t,r,n,10),this.emitNumericEntity(i,2)}return this.addToNumericResult(t,r,n,10),-1}emitNumericEntity(t,n){var r;if(this.consumed<=n)return(r=this.errors)===null||r===void 0||r.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===we.SEMI)this.consumed+=1;else if(this.decodeMode===Ke.Strict)return 0;return this.emitCodePoint(yp(this.result),this.consumed),this.errors&&(t!==we.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let i=r[this.treeIndex],a=(i&at.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const s=t.charCodeAt(n);if(this.treeIndex=Np(r,i,this.treeIndex+Math.max(1,a),s),this.treeIndex<0)return this.result===0||this.decodeMode===Ke.Attribute&&(a===0||kp(s))?0:this.emitNotTerminatedNamedEntity();if(i=r[this.treeIndex],a=(i&at.VALUE_LENGTH)>>14,a!==0){if(s===we.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==Ke.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,i=(r[n]&at.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,i,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:i}=this;return this.emitCodePoint(n===1?i[t]&~at.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case xe.NamedEntity:return this.result!==0&&(this.decodeMode!==Ke.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case xe.NumericDecimal:return this.emitNumericEntity(0,2);case xe.NumericHex:return this.emitNumericEntity(0,3);case xe.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case xe.EntityStart:return 0}}}function to(e){let t="";const n=new eo(e,r=>t+=wp(r));return function(i,a){let s=0,u=0;for(;(u=i.indexOf("&",u))>=0;){t+=i.slice(s,u),n.startEntity(a);const c=n.write(i,u+1);if(c<0){s=u+n.end();break}s=u+c,u=c===0?s+1:s}const l=t+i.slice(s);return t="",l}}function Np(e,t,n,r){const i=(t&at.BRANCH_LENGTH)>>7,a=t&at.JUMP_TABLE;if(i===0)return a!==0&&r===a?n:-1;if(a){const l=r-a;return l<0||l>=i?-1:e[n+l]-1}let s=n,u=s+i-1;for(;s<=u;){const l=s+u>>>1,c=e[l];if(c<r)s=l+1;else if(c>r)u=l-1;else return e[l+i]}return-1}to(Zs);to(Tp);var R;(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/"})(R||(R={}));var ft;(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"})(ft||(ft={}));var Me;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Me||(Me={}));var A;(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"})(A||(A={}));var o;(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"})(o||(o={}));const Ip=new Map([[A.A,o.A],[A.ADDRESS,o.ADDRESS],[A.ANNOTATION_XML,o.ANNOTATION_XML],[A.APPLET,o.APPLET],[A.AREA,o.AREA],[A.ARTICLE,o.ARTICLE],[A.ASIDE,o.ASIDE],[A.B,o.B],[A.BASE,o.BASE],[A.BASEFONT,o.BASEFONT],[A.BGSOUND,o.BGSOUND],[A.BIG,o.BIG],[A.BLOCKQUOTE,o.BLOCKQUOTE],[A.BODY,o.BODY],[A.BR,o.BR],[A.BUTTON,o.BUTTON],[A.CAPTION,o.CAPTION],[A.CENTER,o.CENTER],[A.CODE,o.CODE],[A.COL,o.COL],[A.COLGROUP,o.COLGROUP],[A.DD,o.DD],[A.DESC,o.DESC],[A.DETAILS,o.DETAILS],[A.DIALOG,o.DIALOG],[A.DIR,o.DIR],[A.DIV,o.DIV],[A.DL,o.DL],[A.DT,o.DT],[A.EM,o.EM],[A.EMBED,o.EMBED],[A.FIELDSET,o.FIELDSET],[A.FIGCAPTION,o.FIGCAPTION],[A.FIGURE,o.FIGURE],[A.FONT,o.FONT],[A.FOOTER,o.FOOTER],[A.FOREIGN_OBJECT,o.FOREIGN_OBJECT],[A.FORM,o.FORM],[A.FRAME,o.FRAME],[A.FRAMESET,o.FRAMESET],[A.H1,o.H1],[A.H2,o.H2],[A.H3,o.H3],[A.H4,o.H4],[A.H5,o.H5],[A.H6,o.H6],[A.HEAD,o.HEAD],[A.HEADER,o.HEADER],[A.HGROUP,o.HGROUP],[A.HR,o.HR],[A.HTML,o.HTML],[A.I,o.I],[A.IMG,o.IMG],[A.IMAGE,o.IMAGE],[A.INPUT,o.INPUT],[A.IFRAME,o.IFRAME],[A.KEYGEN,o.KEYGEN],[A.LABEL,o.LABEL],[A.LI,o.LI],[A.LINK,o.LINK],[A.LISTING,o.LISTING],[A.MAIN,o.MAIN],[A.MALIGNMARK,o.MALIGNMARK],[A.MARQUEE,o.MARQUEE],[A.MATH,o.MATH],[A.MENU,o.MENU],[A.META,o.META],[A.MGLYPH,o.MGLYPH],[A.MI,o.MI],[A.MO,o.MO],[A.MN,o.MN],[A.MS,o.MS],[A.MTEXT,o.MTEXT],[A.NAV,o.NAV],[A.NOBR,o.NOBR],[A.NOFRAMES,o.NOFRAMES],[A.NOEMBED,o.NOEMBED],[A.NOSCRIPT,o.NOSCRIPT],[A.OBJECT,o.OBJECT],[A.OL,o.OL],[A.OPTGROUP,o.OPTGROUP],[A.OPTION,o.OPTION],[A.P,o.P],[A.PARAM,o.PARAM],[A.PLAINTEXT,o.PLAINTEXT],[A.PRE,o.PRE],[A.RB,o.RB],[A.RP,o.RP],[A.RT,o.RT],[A.RTC,o.RTC],[A.RUBY,o.RUBY],[A.S,o.S],[A.SCRIPT,o.SCRIPT],[A.SEARCH,o.SEARCH],[A.SECTION,o.SECTION],[A.SELECT,o.SELECT],[A.SOURCE,o.SOURCE],[A.SMALL,o.SMALL],[A.SPAN,o.SPAN],[A.STRIKE,o.STRIKE],[A.STRONG,o.STRONG],[A.STYLE,o.STYLE],[A.SUB,o.SUB],[A.SUMMARY,o.SUMMARY],[A.SUP,o.SUP],[A.TABLE,o.TABLE],[A.TBODY,o.TBODY],[A.TEMPLATE,o.TEMPLATE],[A.TEXTAREA,o.TEXTAREA],[A.TFOOT,o.TFOOT],[A.TD,o.TD],[A.TH,o.TH],[A.THEAD,o.THEAD],[A.TITLE,o.TITLE],[A.TR,o.TR],[A.TRACK,o.TRACK],[A.TT,o.TT],[A.U,o.U],[A.UL,o.UL],[A.SVG,o.SVG],[A.VAR,o.VAR],[A.WBR,o.WBR],[A.XMP,o.XMP]]);function Dt(e){var t;return(t=Ip.get(e))!==null&&t!==void 0?t:o.UNKNOWN}const D=o,Sp={[R.HTML]:new Set([D.ADDRESS,D.APPLET,D.AREA,D.ARTICLE,D.ASIDE,D.BASE,D.BASEFONT,D.BGSOUND,D.BLOCKQUOTE,D.BODY,D.BR,D.BUTTON,D.CAPTION,D.CENTER,D.COL,D.COLGROUP,D.DD,D.DETAILS,D.DIR,D.DIV,D.DL,D.DT,D.EMBED,D.FIELDSET,D.FIGCAPTION,D.FIGURE,D.FOOTER,D.FORM,D.FRAME,D.FRAMESET,D.H1,D.H2,D.H3,D.H4,D.H5,D.H6,D.HEAD,D.HEADER,D.HGROUP,D.HR,D.HTML,D.IFRAME,D.IMG,D.INPUT,D.LI,D.LINK,D.LISTING,D.MAIN,D.MARQUEE,D.MENU,D.META,D.NAV,D.NOEMBED,D.NOFRAMES,D.NOSCRIPT,D.OBJECT,D.OL,D.P,D.PARAM,D.PLAINTEXT,D.PRE,D.SCRIPT,D.SECTION,D.SELECT,D.SOURCE,D.STYLE,D.SUMMARY,D.TABLE,D.TBODY,D.TD,D.TEMPLATE,D.TEXTAREA,D.TFOOT,D.TH,D.THEAD,D.TITLE,D.TR,D.TRACK,D.UL,D.WBR,D.XMP]),[R.MATHML]:new Set([D.MI,D.MO,D.MN,D.MS,D.MTEXT,D.ANNOTATION_XML]),[R.SVG]:new Set([D.TITLE,D.FOREIGN_OBJECT,D.DESC]),[R.XLINK]:new Set,[R.XML]:new Set,[R.XMLNS]:new Set},kr=new Set([D.H1,D.H2,D.H3,D.H4,D.H5,D.H6]);A.STYLE,A.SCRIPT,A.XMP,A.IFRAME,A.NOEMBED,A.NOFRAMES,A.PLAINTEXT;var b;(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"})(b||(b={}));const pe={DATA:b.DATA,RCDATA:b.RCDATA,RAWTEXT:b.RAWTEXT,SCRIPT_DATA:b.SCRIPT_DATA,PLAINTEXT:b.PLAINTEXT,CDATA_SECTION:b.CDATA_SECTION};function Op(e){return e>=m.DIGIT_0&&e<=m.DIGIT_9}function Gt(e){return e>=m.LATIN_CAPITAL_A&&e<=m.LATIN_CAPITAL_Z}function Lp(e){return e>=m.LATIN_SMALL_A&&e<=m.LATIN_SMALL_Z}function rt(e){return Lp(e)||Gt(e)}function ma(e){return rt(e)||Op(e)}function Tn(e){return e+32}function no(e){return e===m.SPACE||e===m.LINE_FEED||e===m.TABULATION||e===m.FORM_FEED}function ga(e){return no(e)||e===m.SOLIDUS||e===m.GREATER_THAN_SIGN}function Rp(e){return e===m.NULL?N.nullCharacterReference:e>1114111?N.characterReferenceOutsideUnicodeRange:Xs(e)?N.surrogateCharacterReference:$s(e)?N.noncharacterCharacterReference:Ks(e)||e===m.CARRIAGE_RETURN?N.controlCharacterReference:null}class Dp{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=b.DATA,this.returnState=b.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new Ep(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new eo(Zs,(r,i)=>{this.preprocessor.pos=this.entityStartPos+i-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(N.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(N.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const i=Rp(r);i&&this._err(i,1)}}:void 0)}_err(t,n=0){var r,i;(i=(r=this.handler).onParseError)===null||i===void 0||i.call(r,this.preprocessor.getError(t,n))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||r()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n<t;n++)this.preprocessor.advance()}_consumeSequenceIfMatch(t,n){return this.preprocessor.startsWith(t,n)?(this._advanceBy(t.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:$.START_TAG,tagName:"",tagID:o.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:$.END_TAG,tagName:"",tagID:o.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:$.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:$.DOCTYPE,name:t,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n,location:this.currentLocation}}_createAttr(t){this.currentAttr={name:t,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var t,n;const r=this.currentToken;if(Js(r,this.currentAttr.name)===null){if(r.attrs.push(this.currentAttr),r.location&&this.currentLocation){const i=(t=(n=r.location).attrs)!==null&&t!==void 0?t:n.attrs=Object.create(null);i[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(N.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=Dt(t.tagName),t.type===$.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(N.endTagWithAttributes),t.selfClosing&&this._err(N.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case $.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case $.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case $.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:$.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type===t){this.currentCharacterToken.chars+=n;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(t,n)}_emitCodePoint(t){const n=no(t)?$.WHITESPACE_CHARACTER:t===m.NULL?$.NULL_CHARACTER:$.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken($.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=b.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?Ke.Attribute:Ke.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===b.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===b.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===b.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case b.DATA:{this._stateData(t);break}case b.RCDATA:{this._stateRcdata(t);break}case b.RAWTEXT:{this._stateRawtext(t);break}case b.SCRIPT_DATA:{this._stateScriptData(t);break}case b.PLAINTEXT:{this._statePlaintext(t);break}case b.TAG_OPEN:{this._stateTagOpen(t);break}case b.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case b.TAG_NAME:{this._stateTagName(t);break}case b.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case b.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case b.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case b.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case b.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case b.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case b.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case b.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case b.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case b.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case b.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case b.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case b.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case b.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case b.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case b.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case b.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case b.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case b.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case b.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case b.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case b.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case b.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case b.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case b.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case b.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case b.BOGUS_COMMENT:{this._stateBogusComment(t);break}case b.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case b.COMMENT_START:{this._stateCommentStart(t);break}case b.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case b.COMMENT:{this._stateComment(t);break}case b.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case b.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case b.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case b.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case b.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case b.COMMENT_END:{this._stateCommentEnd(t);break}case b.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case b.DOCTYPE:{this._stateDoctype(t);break}case b.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case b.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case b.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case b.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case b.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case b.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case b.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case b.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case b.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case b.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case b.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case b.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case b.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case b.CDATA_SECTION:{this._stateCdataSection(t);break}case b.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case b.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case b.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case b.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case m.LESS_THAN_SIGN:{this.state=b.TAG_OPEN;break}case m.AMPERSAND:{this._startCharacterReference();break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitCodePoint(t);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case m.AMPERSAND:{this._startCharacterReference();break}case m.LESS_THAN_SIGN:{this.state=b.RCDATA_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case m.LESS_THAN_SIGN:{this.state=b.RAWTEXT_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(rt(t))this._createStartTagToken(),this.state=b.TAG_NAME,this._stateTagName(t);else switch(t){case m.EXCLAMATION_MARK:{this.state=b.MARKUP_DECLARATION_OPEN;break}case m.SOLIDUS:{this.state=b.END_TAG_OPEN;break}case m.QUESTION_MARK:{this._err(N.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=b.BOGUS_COMMENT,this._stateBogusComment(t);break}case m.EOF:{this._err(N.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(N.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=b.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(rt(t))this._createEndTagToken(),this.state=b.TAG_NAME,this._stateTagName(t);else switch(t){case m.GREATER_THAN_SIGN:{this._err(N.missingEndTagName),this.state=b.DATA;break}case m.EOF:{this._err(N.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(N.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=b.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BEFORE_ATTRIBUTE_NAME;break}case m.SOLIDUS:{this.state=b.SELF_CLOSING_START_TAG;break}case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentTagToken();break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.tagName+=he;break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(Gt(t)?Tn(t):t)}}_stateRcdataLessThanSign(t){t===m.SOLIDUS?this.state=b.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=b.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){rt(t)?(this.state=b.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=b.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=b.BEFORE_ATTRIBUTE_NAME,!1;case m.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=b.SELF_CLOSING_START_TAG,!1;case m.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=b.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=b.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===m.SOLIDUS?this.state=b.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=b.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){rt(t)?(this.state=b.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=b.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=b.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case m.SOLIDUS:{this.state=b.SCRIPT_DATA_END_TAG_OPEN;break}case m.EXCLAMATION_MARK:{this.state=b.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=b.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){rt(t)?(this.state=b.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=b.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=b.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===m.HYPHEN_MINUS?(this.state=b.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=b.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===m.HYPHEN_MINUS?(this.state=b.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=b.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.state=b.SCRIPT_DATA_ESCAPED,this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=b.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case m.HYPHEN_MINUS:{this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case m.GREATER_THAN_SIGN:{this.state=b.SCRIPT_DATA,this._emitChars(">");break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.state=b.SCRIPT_DATA_ESCAPED,this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=b.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===m.SOLIDUS?this.state=b.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:rt(t)?(this._emitChars("<"),this.state=b.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=b.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){rt(t)?(this.state=b.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=b.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=b.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(Ie.SCRIPT,!1)&&ga(this.preprocessor.peek(Ie.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Ie.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=b.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case m.HYPHEN_MINUS:{this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case m.GREATER_THAN_SIGN:{this.state=b.SCRIPT_DATA,this._emitChars(">");break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===m.SOLIDUS?(this.state=b.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(Ie.SCRIPT,!1)&&ga(this.preprocessor.peek(Ie.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Ie.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=b.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.SOLIDUS:case m.GREATER_THAN_SIGN:case m.EOF:{this.state=b.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case m.EQUALS_SIGN:{this._err(N.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=b.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=b.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:case m.SOLIDUS:case m.GREATER_THAN_SIGN:case m.EOF:{this._leaveAttrName(),this.state=b.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case m.EQUALS_SIGN:{this._leaveAttrName(),this.state=b.BEFORE_ATTRIBUTE_VALUE;break}case m.QUOTATION_MARK:case m.APOSTROPHE:case m.LESS_THAN_SIGN:{this._err(N.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.name+=he;break}default:this.currentAttr.name+=String.fromCodePoint(Gt(t)?Tn(t):t)}}_stateAfterAttributeName(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.SOLIDUS:{this.state=b.SELF_CLOSING_START_TAG;break}case m.EQUALS_SIGN:{this.state=b.BEFORE_ATTRIBUTE_VALUE;break}case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentTagToken();break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=b.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:{this.state=b.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case m.APOSTROPHE:{this.state=b.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingAttributeValue),this.state=b.DATA,this.emitCurrentTagToken();break}default:this.state=b.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case m.QUOTATION_MARK:{this.state=b.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case m.AMPERSAND:{this._startCharacterReference();break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=he;break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case m.APOSTROPHE:{this.state=b.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case m.AMPERSAND:{this._startCharacterReference();break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=he;break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this._leaveAttrValue(),this.state=b.BEFORE_ATTRIBUTE_NAME;break}case m.AMPERSAND:{this._startCharacterReference();break}case m.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=b.DATA,this.emitCurrentTagToken();break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=he;break}case m.QUOTATION_MARK:case m.APOSTROPHE:case m.LESS_THAN_SIGN:case m.EQUALS_SIGN:case m.GRAVE_ACCENT:{this._err(N.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this._leaveAttrValue(),this.state=b.BEFORE_ATTRIBUTE_NAME;break}case m.SOLIDUS:{this._leaveAttrValue(),this.state=b.SELF_CLOSING_START_TAG;break}case m.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=b.DATA,this.emitCurrentTagToken();break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._err(N.missingWhitespaceBetweenAttributes),this.state=b.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case m.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=b.DATA,this.emitCurrentTagToken();break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._err(N.unexpectedSolidusInTag),this.state=b.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentComment(n);break}case m.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.data+=he;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(Ie.DASH_DASH,!0)?(this._createCommentToken(Ie.DASH_DASH.length+1),this.state=b.COMMENT_START):this._consumeSequenceIfMatch(Ie.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(Ie.DOCTYPE.length+1),this.state=b.DOCTYPE):this._consumeSequenceIfMatch(Ie.CDATA_START,!0)?this.inForeignNode?this.state=b.CDATA_SECTION:(this._err(N.cdataInHtmlContent),this._createCommentToken(Ie.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=b.BOGUS_COMMENT):this._ensureHibernation()||(this._err(N.incorrectlyOpenedComment),this._createCommentToken(2),this.state=b.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.COMMENT_START_DASH;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptClosingOfEmptyComment),this.state=b.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=b.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case m.HYPHEN_MINUS:{this.state=b.COMMENT_END;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptClosingOfEmptyComment),this.state=b.DATA,this.emitCurrentComment(n);break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=b.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case m.HYPHEN_MINUS:{this.state=b.COMMENT_END_DASH;break}case m.LESS_THAN_SIGN:{n.data+="<",this.state=b.COMMENT_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.data+=he;break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case m.EXCLAMATION_MARK:{n.data+="!",this.state=b.COMMENT_LESS_THAN_SIGN_BANG;break}case m.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=b.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===m.HYPHEN_MINUS?this.state=b.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=b.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===m.HYPHEN_MINUS?this.state=b.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=b.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==m.GREATER_THAN_SIGN&&t!==m.EOF&&this._err(N.nestedComment),this.state=b.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case m.HYPHEN_MINUS:{this.state=b.COMMENT_END;break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=b.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentComment(n);break}case m.EXCLAMATION_MARK:{this.state=b.COMMENT_END_BANG;break}case m.HYPHEN_MINUS:{n.data+="-";break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=b.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case m.HYPHEN_MINUS:{n.data+="--!",this.state=b.COMMENT_END_DASH;break}case m.GREATER_THAN_SIGN:{this._err(N.incorrectlyClosedComment),this.state=b.DATA,this.emitCurrentComment(n);break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=b.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BEFORE_DOCTYPE_NAME;break}case m.GREATER_THAN_SIGN:{this.state=b.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case m.EOF:{this._err(N.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingWhitespaceBeforeDoctypeName),this.state=b.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(Gt(t))this._createDoctypeToken(String.fromCharCode(Tn(t))),this.state=b.DOCTYPE_NAME;else switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.NULL:{this._err(N.unexpectedNullCharacter),this._createDoctypeToken(he),this.state=b.DOCTYPE_NAME;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=b.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.AFTER_DOCTYPE_NAME;break}case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.name+=he;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(Gt(t)?Tn(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(Ie.PUBLIC,!1)?this.state=b.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(Ie.SYSTEM,!1)?this.state=b.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(N.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case m.QUOTATION_MARK:{this._err(N.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=b.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{this._err(N.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=b.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:{n.publicId="",this.state=b.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{n.publicId="",this.state=b.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case m.QUOTATION_MARK:{this.state=b.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.publicId+=he;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateDoctypePublicIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case m.APOSTROPHE:{this.state=b.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.publicId+=he;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateAfterDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.QUOTATION_MARK:{this._err(N.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{this._err(N.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.QUOTATION_MARK:{n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case m.QUOTATION_MARK:{this._err(N.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{this._err(N.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:{n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case m.QUOTATION_MARK:{this.state=b.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.systemId+=he;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateDoctypeSystemIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case m.APOSTROPHE:{this.state=b.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.systemId+=he;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateAfterDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case m.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.NULL:{this._err(N.unexpectedNullCharacter);break}case m.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case m.RIGHT_SQUARE_BRACKET:{this.state=b.CDATA_SECTION_BRACKET;break}case m.EOF:{this._err(N.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===m.RIGHT_SQUARE_BRACKET?this.state=b.CDATA_SECTION_END:(this._emitChars("]"),this.state=b.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case m.GREATER_THAN_SIGN:{this.state=b.DATA;break}case m.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=b.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(m.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&ma(this.preprocessor.peek(1))?b.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){ma(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===m.SEMICOLON&&this._err(N.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const ro=new Set([o.DD,o.DT,o.LI,o.OPTGROUP,o.OPTION,o.P,o.RB,o.RP,o.RT,o.RTC]),ba=new Set([...ro,o.CAPTION,o.COLGROUP,o.TBODY,o.TD,o.TFOOT,o.TH,o.THEAD,o.TR]),Sn=new Set([o.APPLET,o.CAPTION,o.HTML,o.MARQUEE,o.OBJECT,o.TABLE,o.TD,o.TEMPLATE,o.TH]),vp=new Set([...Sn,o.OL,o.UL]),Pp=new Set([...Sn,o.BUTTON]),Ea=new Set([o.ANNOTATION_XML,o.MI,o.MN,o.MO,o.MS,o.MTEXT]),Ta=new Set([o.DESC,o.FOREIGN_OBJECT,o.TITLE]),Mp=new Set([o.TR,o.TEMPLATE,o.HTML]),Bp=new Set([o.TBODY,o.TFOOT,o.THEAD,o.TEMPLATE,o.HTML]),Fp=new Set([o.TABLE,o.TEMPLATE,o.HTML]),Hp=new Set([o.TD,o.TH]);class Up{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=o.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===o.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===R.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const i=this._indexOf(t)+1;this.items.splice(i,0,n),this.tagIDs.splice(i,0,r),this.stackTop++,i===this.stackTop&&this._updateCurrentElement(),this.handler.onItemPush(this.current,this.currentTagId,i===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==R.HTML);this.shortenToLength(n<0?0:n)}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop<t)}}popUntilElementPopped(t){const n=this._indexOf(t);this.shortenToLength(n<0?0:n)}popUntilPopped(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r<0?0:r)}popUntilNumberedHeaderPopped(){this.popUntilPopped(kr,R.HTML)}popUntilTableCellPopped(){this.popUntilPopped(Hp,R.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(t,n){for(let r=this.stackTop;r>=0;r--)if(t.has(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(Fp,R.HTML)}clearBackToTableBodyContext(){this.clearBackTo(Bp,R.HTML)}clearBackToTableRowContext(){this.clearBackTo(Mp,R.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===o.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===o.HTML}hasInDynamicScope(t,n){for(let r=this.stackTop;r>=0;r--){const i=this.tagIDs[r];switch(this.treeAdapter.getNamespaceURI(this.items[r])){case R.HTML:{if(i===t)return!0;if(n.has(i))return!1;break}case R.SVG:{if(Ta.has(i))return!1;break}case R.MATHML:{if(Ea.has(i))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Sn)}hasInListItemScope(t){return this.hasInDynamicScope(t,vp)}hasInButtonScope(t){return this.hasInDynamicScope(t,Pp)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case R.HTML:{if(kr.has(n))return!0;if(Sn.has(n))return!1;break}case R.SVG:{if(Ta.has(n))return!1;break}case R.MATHML:{if(Ea.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===R.HTML)switch(this.tagIDs[n]){case t:return!0;case o.TABLE:case o.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===R.HTML)switch(this.tagIDs[t]){case o.TBODY:case o.THEAD:case o.TFOOT:return!0;case o.TABLE:case o.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===R.HTML)switch(this.tagIDs[n]){case t:return!0;case o.OPTION:case o.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;ro.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;ba.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==t&&ba.has(this.currentTagId);)this.pop()}}const cr=3;var We;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(We||(We={}));const xa={type:We.Marker};class zp{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],i=n.length,a=this.treeAdapter.getTagName(t),s=this.treeAdapter.getNamespaceURI(t);for(let u=0;u<this.entries.length;u++){const l=this.entries[u];if(l.type===We.Marker)break;const{element:c}=l;if(this.treeAdapter.getTagName(c)===a&&this.treeAdapter.getNamespaceURI(c)===s){const d=this.treeAdapter.getAttrList(c);d.length===i&&r.push({idx:u,attrs:d})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<cr)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<cr)return;const i=new Map(n.map(s=>[s.name,s.value]));let a=0;for(let s=0;s<r.length;s++){const u=r[s];u.attrs.every(l=>i.get(l.name)===l.value)&&(a+=1,a>=cr&&this.entries.splice(u.idx,1))}}insertMarker(){this.entries.unshift(xa)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:We.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:We.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n>=0&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(xa);t>=0?this.entries.splice(0,t+1):this.entries.length=0}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===We.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===We.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===We.Element&&n.element===t)}}const it={createDocument(){return{nodeName:"#document",mode:Me.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const i=e.childNodes.find(a=>a.nodeName==="#documentType");if(i)i.name=t,i.publicId=n,i.systemId=r;else{const a={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};it.appendChild(e,a)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(it.isTextNode(n)){n.value+=t;return}}it.appendChild(e,it.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&it.isTextNode(r)?r.value+=t:it.insertBefore(e,it.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation={...e.sourceCodeLocation,...t}}},io="html",jp="about:legacy-compat",Yp="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",ao=["+//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//"],Wp=[...ao,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],qp=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),so=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],Vp=[...so,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function wa(e,t){return t.some(n=>e.startsWith(n))}function Gp(e){return e.name===io&&e.publicId===null&&(e.systemId===null||e.systemId===jp)}function Qp(e){if(e.name!==io)return Me.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===Yp)return Me.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),qp.has(n))return Me.QUIRKS;let r=t===null?Wp:ao;if(wa(n,r))return Me.QUIRKS;if(r=t===null?so:Vp,wa(n,r))return Me.LIMITED_QUIRKS}return Me.NO_QUIRKS}const ya={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},Xp="definitionurl",Kp="definitionURL",$p=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),Jp=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:R.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:R.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:R.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:R.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:R.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:R.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:R.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:R.XML}],["xml:space",{prefix:"xml",name:"space",namespace:R.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:R.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:R.XMLNS}]]),Zp=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),em=new Set([o.B,o.BIG,o.BLOCKQUOTE,o.BODY,o.BR,o.CENTER,o.CODE,o.DD,o.DIV,o.DL,o.DT,o.EM,o.EMBED,o.H1,o.H2,o.H3,o.H4,o.H5,o.H6,o.HEAD,o.HR,o.I,o.IMG,o.LI,o.LISTING,o.MENU,o.META,o.NOBR,o.OL,o.P,o.PRE,o.RUBY,o.S,o.SMALL,o.SPAN,o.STRONG,o.STRIKE,o.SUB,o.SUP,o.TABLE,o.TT,o.U,o.UL,o.VAR]);function tm(e){const t=e.tagID;return t===o.FONT&&e.attrs.some(({name:r})=>r===ft.COLOR||r===ft.SIZE||r===ft.FACE)||em.has(t)}function oo(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===Xp){e.attrs[t].name=Kp;break}}function uo(e){for(let t=0;t<e.attrs.length;t++){const n=$p.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function Xr(e){for(let t=0;t<e.attrs.length;t++){const n=Jp.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 nm(e){const t=Zp.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=Dt(e.tagName))}function rm(e,t){return t===R.MATHML&&(e===o.MI||e===o.MO||e===o.MN||e===o.MS||e===o.MTEXT)}function im(e,t,n){if(t===R.MATHML&&e===o.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===ft.ENCODING){const i=n[r].value.toLowerCase();return i===ya.TEXT_HTML||i===ya.APPLICATION_XML}}return t===R.SVG&&(e===o.FOREIGN_OBJECT||e===o.DESC||e===o.TITLE)}function am(e,t,n,r){return(!r||r===R.HTML)&&im(e,t,n)||(!r||r===R.MATHML)&&rm(e,t)}const sm="hidden",om=8,um=3;var T;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(T||(T={}));const lm={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},lo=new Set([o.TABLE,o.TBODY,o.TFOOT,o.THEAD,o.TR]),_a={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:it,onParseError:null};class Aa{constructor(t,n,r=null,i=null){this.fragmentContext=r,this.scriptHandler=i,this.currentToken=null,this.stopped=!1,this.insertionMode=T.INITIAL,this.originalInsertionMode=T.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={..._a,...t},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=n??this.treeAdapter.createDocument(),this.tokenizer=new Dp(this.options,this),this.activeFormattingElements=new zp(this.treeAdapter),this.fragmentContextID=r?Dt(this.treeAdapter.getTagName(r)):o.UNKNOWN,this._setContextModes(r??this.document,this.fragmentContextID),this.openElements=new Up(this.document,this.treeAdapter,this)}static parse(t,n){const r=new this(n);return r.tokenizer.write(t,!0),r.document}static getFragmentParser(t,n){const r={..._a,...n};t??(t=r.treeAdapter.createElement(A.TEMPLATE,R.HTML,[]));const i=r.treeAdapter.createElement("documentmock",R.HTML,[]),a=new this(r,i,t);return a.fragmentContextID===o.TEMPLATE&&a.tmplInsertionModeStack.unshift(T.IN_TEMPLATE),a._initTokenizerForFragmentParsing(),a._insertFakeRootElement(),a._resetInsertionMode(),a._findFormInFragmentContext(),a}getFragment(){const t=this.treeAdapter.getFirstChild(this.document),n=this.treeAdapter.createDocumentFragment();return this._adoptNodes(t,n),n}_err(t,n,r){var i;if(!this.onParseError)return;const a=(i=t.location)!==null&&i!==void 0?i:lm,s={code:n,startLine:a.startLine,startCol:a.startCol,startOffset:a.startOffset,endLine:r?a.startLine:a.endLine,endCol:r?a.startCol:a.endCol,endOffset:r?a.startOffset:a.endOffset};this.onParseError(s)}onItemPush(t,n,r){var i,a;(a=(i=this.treeAdapter).onItemPush)===null||a===void 0||a.call(i,t),r&&this.openElements.stackTop>0&&this._setContextModes(t,n)}onItemPop(t,n){var r,i;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(i=(r=this.treeAdapter).onItemPop)===null||i===void 0||i.call(r,t,this.openElements.current),n){let a,s;this.openElements.stackTop===0&&this.fragmentContext?(a=this.fragmentContext,s=this.fragmentContextID):{current:a,currentTagId:s}=this.openElements,this._setContextModes(a,s)}}_setContextModes(t,n){const r=t===this.document||this.treeAdapter.getNamespaceURI(t)===R.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,R.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=T.TEXT}switchToPlaintextParsing(){this.insertionMode=T.TEXT,this.originalInsertionMode=T.IN_BODY,this.tokenizer.state=pe.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===A.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==R.HTML))switch(this.fragmentContextID){case o.TITLE:case o.TEXTAREA:{this.tokenizer.state=pe.RCDATA;break}case o.STYLE:case o.XMP:case o.IFRAME:case o.NOEMBED:case o.NOFRAMES:case o.NOSCRIPT:{this.tokenizer.state=pe.RAWTEXT;break}case o.SCRIPT:{this.tokenizer.state=pe.SCRIPT_DATA;break}case o.PLAINTEXT:{this.tokenizer.state=pe.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",i=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,i),t.location){const s=this.treeAdapter.getChildNodes(this.document).find(u=>this.treeAdapter.isDocumentTypeNode(u));s&&this.treeAdapter.setNodeSourceCodeLocation(s,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&{...n,startTag:n};this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,R.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,R.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(A.HTML,R.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,o.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const i=this.treeAdapter.getChildNodes(n),a=r?i.lastIndexOf(r):i.length,s=i[a-1];if(this.treeAdapter.getNodeSourceCodeLocation(s)){const{endLine:l,endCol:c,endOffset:d}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(s,{endLine:l,endCol:c,endOffset:d})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(s,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,i=this.treeAdapter.getTagName(t),a=n.type===$.END_TAG&&i===n.tagName?{endTag:{...r},endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,a)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===o.SVG&&this.treeAdapter.getTagName(n)===A.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===R.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===o.MGLYPH||t.tagID===o.MALIGNMARK)&&!this._isIntegrationPoint(r,n,R.HTML)}_processToken(t){switch(t.type){case $.CHARACTER:{this.onCharacter(t);break}case $.NULL_CHARACTER:{this.onNullCharacter(t);break}case $.COMMENT:{this.onComment(t);break}case $.DOCTYPE:{this.onDoctype(t);break}case $.START_TAG:{this._processStartTag(t);break}case $.END_TAG:{this.onEndTag(t);break}case $.EOF:{this.onEof(t);break}case $.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return am(t,i,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===We.Marker||this.openElements.contains(i.element)),r=n<0?t-1:n-1;for(let i=r;i>=0;i--){const a=this.activeFormattingElements.entries[i];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=T.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(o.P),this.openElements.popUntilTagNamePopped(o.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case o.TR:{this.insertionMode=T.IN_ROW;return}case o.TBODY:case o.THEAD:case o.TFOOT:{this.insertionMode=T.IN_TABLE_BODY;return}case o.CAPTION:{this.insertionMode=T.IN_CAPTION;return}case o.COLGROUP:{this.insertionMode=T.IN_COLUMN_GROUP;return}case o.TABLE:{this.insertionMode=T.IN_TABLE;return}case o.BODY:{this.insertionMode=T.IN_BODY;return}case o.FRAMESET:{this.insertionMode=T.IN_FRAMESET;return}case o.SELECT:{this._resetInsertionModeForSelect(t);return}case o.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case o.HTML:{this.insertionMode=this.headElement?T.AFTER_HEAD:T.BEFORE_HEAD;return}case o.TD:case o.TH:{if(t>0){this.insertionMode=T.IN_CELL;return}break}case o.HEAD:{if(t>0){this.insertionMode=T.IN_HEAD;return}break}}this.insertionMode=T.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===o.TEMPLATE)break;if(r===o.TABLE){this.insertionMode=T.IN_SELECT_IN_TABLE;return}}this.insertionMode=T.IN_SELECT}_isElementCausesFosterParenting(t){return lo.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case o.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===R.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case o.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return Sp[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Hg(this,t);return}switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{Kt(this,t);break}case T.BEFORE_HEAD:{$t(this,t);break}case T.IN_HEAD:{Jt(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Zt(this,t);break}case T.AFTER_HEAD:{en(this,t);break}case T.IN_BODY:case T.IN_CAPTION:case T.IN_CELL:case T.IN_TEMPLATE:{ho(this,t);break}case T.TEXT:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{dr(this,t);break}case T.IN_TABLE_TEXT:{Eo(this,t);break}case T.IN_COLUMN_GROUP:{On(this,t);break}case T.AFTER_BODY:{Ln(this,t);break}case T.AFTER_AFTER_BODY:{_n(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Fg(this,t);return}switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{Kt(this,t);break}case T.BEFORE_HEAD:{$t(this,t);break}case T.IN_HEAD:{Jt(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Zt(this,t);break}case T.AFTER_HEAD:{en(this,t);break}case T.TEXT:{this._insertCharacters(t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{dr(this,t);break}case T.IN_COLUMN_GROUP:{On(this,t);break}case T.AFTER_BODY:{Ln(this,t);break}case T.AFTER_AFTER_BODY:{_n(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){Nr(this,t);return}switch(this.insertionMode){case T.INITIAL:case T.BEFORE_HTML:case T.BEFORE_HEAD:case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:case T.IN_BODY:case T.IN_TABLE:case T.IN_CAPTION:case T.IN_COLUMN_GROUP:case T.IN_TABLE_BODY:case T.IN_ROW:case T.IN_CELL:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:case T.IN_TEMPLATE:case T.IN_FRAMESET:case T.AFTER_FRAMESET:{Nr(this,t);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}case T.AFTER_BODY:{gm(this,t);break}case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{bm(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case T.INITIAL:{Em(this,t);break}case T.BEFORE_HEAD:case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:{this._err(t,N.misplacedDoctype);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,N.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?Ug(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{Tm(this,t);break}case T.BEFORE_HEAD:{wm(this,t);break}case T.IN_HEAD:{je(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Am(this,t);break}case T.AFTER_HEAD:{km(this,t);break}case T.IN_BODY:{ke(this,t);break}case T.IN_TABLE:{kt(this,t);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}case T.IN_CAPTION:{yg(this,t);break}case T.IN_COLUMN_GROUP:{Jr(this,t);break}case T.IN_TABLE_BODY:{Wn(this,t);break}case T.IN_ROW:{qn(this,t);break}case T.IN_CELL:{Cg(this,t);break}case T.IN_SELECT:{wo(this,t);break}case T.IN_SELECT_IN_TABLE:{Ng(this,t);break}case T.IN_TEMPLATE:{Sg(this,t);break}case T.AFTER_BODY:{Lg(this,t);break}case T.IN_FRAMESET:{Rg(this,t);break}case T.AFTER_FRAMESET:{vg(this,t);break}case T.AFTER_AFTER_BODY:{Mg(this,t);break}case T.AFTER_AFTER_FRAMESET:{Bg(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?zg(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{xm(this,t);break}case T.BEFORE_HEAD:{ym(this,t);break}case T.IN_HEAD:{_m(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Cm(this,t);break}case T.AFTER_HEAD:{Nm(this,t);break}case T.IN_BODY:{Yn(this,t);break}case T.TEXT:{hg(this,t);break}case T.IN_TABLE:{rn(this,t);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}case T.IN_CAPTION:{_g(this,t);break}case T.IN_COLUMN_GROUP:{Ag(this,t);break}case T.IN_TABLE_BODY:{Ir(this,t);break}case T.IN_ROW:{xo(this,t);break}case T.IN_CELL:{kg(this,t);break}case T.IN_SELECT:{yo(this,t);break}case T.IN_SELECT_IN_TABLE:{Ig(this,t);break}case T.IN_TEMPLATE:{Og(this,t);break}case T.AFTER_BODY:{Ao(this,t);break}case T.IN_FRAMESET:{Dg(this,t);break}case T.AFTER_FRAMESET:{Pg(this,t);break}case T.AFTER_AFTER_BODY:{_n(this,t);break}}}onEof(t){switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{Kt(this,t);break}case T.BEFORE_HEAD:{$t(this,t);break}case T.IN_HEAD:{Jt(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Zt(this,t);break}case T.AFTER_HEAD:{en(this,t);break}case T.IN_BODY:case T.IN_TABLE:case T.IN_CAPTION:case T.IN_COLUMN_GROUP:case T.IN_TABLE_BODY:case T.IN_ROW:case T.IN_CELL:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:{go(this,t);break}case T.TEXT:{fg(this,t);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}case T.IN_TEMPLATE:{_o(this,t);break}case T.AFTER_BODY:case T.IN_FRAMESET:case T.AFTER_FRAMESET:case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{$r(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===m.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:case T.TEXT:case T.IN_COLUMN_GROUP:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:case T.IN_FRAMESET:case T.AFTER_FRAMESET:{this._insertCharacters(t);break}case T.IN_BODY:case T.IN_CAPTION:case T.IN_CELL:case T.IN_TEMPLATE:case T.AFTER_BODY:case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{co(this,t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{dr(this,t);break}case T.IN_TABLE_TEXT:{bo(this,t);break}}}}function cm(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):mo(e,t),n}function dm(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const i=e.openElements.items[r];if(i===t.element)break;e._isSpecialElement(i,e.openElements.tagIDs[r])&&(n=i)}return n||(e.openElements.shortenToLength(r<0?0:r),e.activeFormattingElements.removeEntry(t)),n}function hm(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let a=0,s=i;s!==n;a++,s=i){i=e.openElements.getCommonAncestor(s);const u=e.activeFormattingElements.getElementEntry(s),l=u&&a>=um;!u||l?(l&&e.activeFormattingElements.removeEntry(u),e.openElements.remove(s)):(s=fm(e,u),r===t&&(e.activeFormattingElements.bookmark=u),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(s,r),r=s)}return r}function fm(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function pm(e,t,n){const r=e.treeAdapter.getTagName(t),i=Dt(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);i===o.TEMPLATE&&a===R.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function mm(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:i}=n,a=e.treeAdapter.createElement(i.tagName,r,i.attrs);e._adoptNodes(t,a),e.treeAdapter.appendChild(t,a),e.activeFormattingElements.insertElementAfterBookmark(a,i),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,a,i.tagID)}function Kr(e,t){for(let n=0;n<om;n++){const r=cm(e,t);if(!r)break;const i=dm(e,r);if(!i)break;e.activeFormattingElements.bookmark=r;const a=hm(e,i,r.element),s=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),s&&pm(e,s,a),mm(e,i,r)}}function Nr(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function gm(e,t){e._appendCommentNode(t,e.openElements.items[0])}function bm(e,t){e._appendCommentNode(t,e.document)}function $r(e,t){if(e.stopped=!0,t.location){const n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],i=e.treeAdapter.getNodeSourceCodeLocation(r);if(i&&!i.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const a=e.openElements.items[1],s=e.treeAdapter.getNodeSourceCodeLocation(a);s&&!s.endTag&&e._setEndLocation(a,t)}}}}function Em(e,t){e._setDocumentType(t);const n=t.forceQuirks?Me.QUIRKS:Qp(t);Gp(t)||e._err(t,N.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=T.BEFORE_HTML}function Yt(e,t){e._err(t,N.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Me.QUIRKS),e.insertionMode=T.BEFORE_HTML,e._processToken(t)}function Tm(e,t){t.tagID===o.HTML?(e._insertElement(t,R.HTML),e.insertionMode=T.BEFORE_HEAD):Kt(e,t)}function xm(e,t){const n=t.tagID;(n===o.HTML||n===o.HEAD||n===o.BODY||n===o.BR)&&Kt(e,t)}function Kt(e,t){e._insertFakeRootElement(),e.insertionMode=T.BEFORE_HEAD,e._processToken(t)}function wm(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.HEAD:{e._insertElement(t,R.HTML),e.headElement=e.openElements.current,e.insertionMode=T.IN_HEAD;break}default:$t(e,t)}}function ym(e,t){const n=t.tagID;n===o.HEAD||n===o.BODY||n===o.HTML||n===o.BR?$t(e,t):e._err(t,N.endTagWithoutMatchingOpenElement)}function $t(e,t){e._insertFakeElement(A.HEAD,o.HEAD),e.headElement=e.openElements.current,e.insertionMode=T.IN_HEAD,e._processToken(t)}function je(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.BASE:case o.BASEFONT:case o.BGSOUND:case o.LINK:case o.META:{e._appendElement(t,R.HTML),t.ackSelfClosing=!0;break}case o.TITLE:{e._switchToTextParsing(t,pe.RCDATA);break}case o.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,pe.RAWTEXT):(e._insertElement(t,R.HTML),e.insertionMode=T.IN_HEAD_NO_SCRIPT);break}case o.NOFRAMES:case o.STYLE:{e._switchToTextParsing(t,pe.RAWTEXT);break}case o.SCRIPT:{e._switchToTextParsing(t,pe.SCRIPT_DATA);break}case o.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=T.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(T.IN_TEMPLATE);break}case o.HEAD:{e._err(t,N.misplacedStartTagForHeadElement);break}default:Jt(e,t)}}function _m(e,t){switch(t.tagID){case o.HEAD:{e.openElements.pop(),e.insertionMode=T.AFTER_HEAD;break}case o.BODY:case o.BR:case o.HTML:{Jt(e,t);break}case o.TEMPLATE:{gt(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function gt(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==o.TEMPLATE&&e._err(t,N.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(o.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,N.endTagWithoutMatchingOpenElement)}function Jt(e,t){e.openElements.pop(),e.insertionMode=T.AFTER_HEAD,e._processToken(t)}function Am(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.BASEFONT:case o.BGSOUND:case o.HEAD:case o.LINK:case o.META:case o.NOFRAMES:case o.STYLE:{je(e,t);break}case o.NOSCRIPT:{e._err(t,N.nestedNoscriptInHead);break}default:Zt(e,t)}}function Cm(e,t){switch(t.tagID){case o.NOSCRIPT:{e.openElements.pop(),e.insertionMode=T.IN_HEAD;break}case o.BR:{Zt(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function Zt(e,t){const n=t.type===$.EOF?N.openElementsLeftAfterEof:N.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=T.IN_HEAD,e._processToken(t)}function km(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.BODY:{e._insertElement(t,R.HTML),e.framesetOk=!1,e.insertionMode=T.IN_BODY;break}case o.FRAMESET:{e._insertElement(t,R.HTML),e.insertionMode=T.IN_FRAMESET;break}case o.BASE:case o.BASEFONT:case o.BGSOUND:case o.LINK:case o.META:case o.NOFRAMES:case o.SCRIPT:case o.STYLE:case o.TEMPLATE:case o.TITLE:{e._err(t,N.abandonedHeadElementChild),e.openElements.push(e.headElement,o.HEAD),je(e,t),e.openElements.remove(e.headElement);break}case o.HEAD:{e._err(t,N.misplacedStartTagForHeadElement);break}default:en(e,t)}}function Nm(e,t){switch(t.tagID){case o.BODY:case o.HTML:case o.BR:{en(e,t);break}case o.TEMPLATE:{gt(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function en(e,t){e._insertFakeElement(A.BODY,o.BODY),e.insertionMode=T.IN_BODY,jn(e,t)}function jn(e,t){switch(t.type){case $.CHARACTER:{ho(e,t);break}case $.WHITESPACE_CHARACTER:{co(e,t);break}case $.COMMENT:{Nr(e,t);break}case $.START_TAG:{ke(e,t);break}case $.END_TAG:{Yn(e,t);break}case $.EOF:{go(e,t);break}}}function co(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function ho(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function Im(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function Sm(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function Om(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_FRAMESET)}function Lm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML)}function Rm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),kr.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,R.HTML)}function Dm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function vm(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML),n||(e.formElement=e.openElements.current))}function Pm(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const i=e.openElements.tagIDs[r];if(n===o.LI&&i===o.LI||(n===o.DD||n===o.DT)&&(i===o.DD||i===o.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==o.ADDRESS&&i!==o.DIV&&i!==o.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML)}function Mm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML),e.tokenizer.state=pe.PLAINTEXT}function Bm(e,t){e.openElements.hasInScope(o.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(o.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.framesetOk=!1}function Fm(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(A.A);n&&(Kr(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Hm(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Um(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(o.NOBR)&&(Kr(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,R.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function zm(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function jm(e,t){e.treeAdapter.getDocumentMode(e.document)!==Me.QUIRKS&&e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML),e.framesetOk=!1,e.insertionMode=T.IN_TABLE}function fo(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,R.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function po(e){const t=Js(e,ft.TYPE);return t!=null&&t.toLowerCase()===sm}function Ym(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,R.HTML),po(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function Wm(e,t){e._appendElement(t,R.HTML),t.ackSelfClosing=!0}function qm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._appendElement(t,R.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Vm(e,t){t.tagName=A.IMG,t.tagID=o.IMG,fo(e,t)}function Gm(e,t){e._insertElement(t,R.HTML),e.skipNextNewLine=!0,e.tokenizer.state=pe.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=T.TEXT}function Qm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,pe.RAWTEXT)}function Xm(e,t){e.framesetOk=!1,e._switchToTextParsing(t,pe.RAWTEXT)}function Ca(e,t){e._switchToTextParsing(t,pe.RAWTEXT)}function Km(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===T.IN_TABLE||e.insertionMode===T.IN_CAPTION||e.insertionMode===T.IN_TABLE_BODY||e.insertionMode===T.IN_ROW||e.insertionMode===T.IN_CELL?T.IN_SELECT_IN_TABLE:T.IN_SELECT}function $m(e,t){e.openElements.currentTagId===o.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML)}function Jm(e,t){e.openElements.hasInScope(o.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,R.HTML)}function Zm(e,t){e.openElements.hasInScope(o.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(o.RTC),e._insertElement(t,R.HTML)}function eg(e,t){e._reconstructActiveFormattingElements(),oo(t),Xr(t),t.selfClosing?e._appendElement(t,R.MATHML):e._insertElement(t,R.MATHML),t.ackSelfClosing=!0}function tg(e,t){e._reconstructActiveFormattingElements(),uo(t),Xr(t),t.selfClosing?e._appendElement(t,R.SVG):e._insertElement(t,R.SVG),t.ackSelfClosing=!0}function ka(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML)}function ke(e,t){switch(t.tagID){case o.I:case o.S:case o.B:case o.U:case o.EM:case o.TT:case o.BIG:case o.CODE:case o.FONT:case o.SMALL:case o.STRIKE:case o.STRONG:{Hm(e,t);break}case o.A:{Fm(e,t);break}case o.H1:case o.H2:case o.H3:case o.H4:case o.H5:case o.H6:{Rm(e,t);break}case o.P:case o.DL:case o.OL:case o.UL:case o.DIV:case o.DIR:case o.NAV:case o.MAIN:case o.MENU:case o.ASIDE:case o.CENTER:case o.FIGURE:case o.FOOTER:case o.HEADER:case o.HGROUP:case o.DIALOG:case o.DETAILS:case o.ADDRESS:case o.ARTICLE:case o.SEARCH:case o.SECTION:case o.SUMMARY:case o.FIELDSET:case o.BLOCKQUOTE:case o.FIGCAPTION:{Lm(e,t);break}case o.LI:case o.DD:case o.DT:{Pm(e,t);break}case o.BR:case o.IMG:case o.WBR:case o.AREA:case o.EMBED:case o.KEYGEN:{fo(e,t);break}case o.HR:{qm(e,t);break}case o.RB:case o.RTC:{Jm(e,t);break}case o.RT:case o.RP:{Zm(e,t);break}case o.PRE:case o.LISTING:{Dm(e,t);break}case o.XMP:{Qm(e,t);break}case o.SVG:{tg(e,t);break}case o.HTML:{Im(e,t);break}case o.BASE:case o.LINK:case o.META:case o.STYLE:case o.TITLE:case o.SCRIPT:case o.BGSOUND:case o.BASEFONT:case o.TEMPLATE:{je(e,t);break}case o.BODY:{Sm(e,t);break}case o.FORM:{vm(e,t);break}case o.NOBR:{Um(e,t);break}case o.MATH:{eg(e,t);break}case o.TABLE:{jm(e,t);break}case o.INPUT:{Ym(e,t);break}case o.PARAM:case o.TRACK:case o.SOURCE:{Wm(e,t);break}case o.IMAGE:{Vm(e,t);break}case o.BUTTON:{Bm(e,t);break}case o.APPLET:case o.OBJECT:case o.MARQUEE:{zm(e,t);break}case o.IFRAME:{Xm(e,t);break}case o.SELECT:{Km(e,t);break}case o.OPTION:case o.OPTGROUP:{$m(e,t);break}case o.NOEMBED:case o.NOFRAMES:{Ca(e,t);break}case o.FRAMESET:{Om(e,t);break}case o.TEXTAREA:{Gm(e,t);break}case o.NOSCRIPT:{e.options.scriptingEnabled?Ca(e,t):ka(e,t);break}case o.PLAINTEXT:{Mm(e,t);break}case o.COL:case o.TH:case o.TD:case o.TR:case o.HEAD:case o.FRAME:case o.TBODY:case o.TFOOT:case o.THEAD:case o.CAPTION:case o.COLGROUP:break;default:ka(e,t)}}function ng(e,t){if(e.openElements.hasInScope(o.BODY)&&(e.insertionMode=T.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function rg(e,t){e.openElements.hasInScope(o.BODY)&&(e.insertionMode=T.AFTER_BODY,Ao(e,t))}function ig(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function ag(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(o.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(o.FORM):n&&e.openElements.remove(n))}function sg(e){e.openElements.hasInButtonScope(o.P)||e._insertFakeElement(A.P,o.P),e._closePElement()}function og(e){e.openElements.hasInListItemScope(o.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(o.LI),e.openElements.popUntilTagNamePopped(o.LI))}function ug(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function lg(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function cg(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function dg(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(A.BR,o.BR),e.openElements.pop(),e.framesetOk=!1}function mo(e,t){const n=t.tagName,r=t.tagID;for(let i=e.openElements.stackTop;i>0;i--){const a=e.openElements.items[i],s=e.openElements.tagIDs[i];if(r===s&&(r!==o.UNKNOWN||e.treeAdapter.getTagName(a)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=i&&e.openElements.shortenToLength(i);break}if(e._isSpecialElement(a,s))break}}function Yn(e,t){switch(t.tagID){case o.A:case o.B:case o.I:case o.S:case o.U:case o.EM:case o.TT:case o.BIG:case o.CODE:case o.FONT:case o.NOBR:case o.SMALL:case o.STRIKE:case o.STRONG:{Kr(e,t);break}case o.P:{sg(e);break}case o.DL:case o.UL:case o.OL:case o.DIR:case o.DIV:case o.NAV:case o.PRE:case o.MAIN:case o.MENU:case o.ASIDE:case o.BUTTON:case o.CENTER:case o.FIGURE:case o.FOOTER:case o.HEADER:case o.HGROUP:case o.DIALOG:case o.ADDRESS:case o.ARTICLE:case o.DETAILS:case o.SEARCH:case o.SECTION:case o.SUMMARY:case o.LISTING:case o.FIELDSET:case o.BLOCKQUOTE:case o.FIGCAPTION:{ig(e,t);break}case o.LI:{og(e);break}case o.DD:case o.DT:{ug(e,t);break}case o.H1:case o.H2:case o.H3:case o.H4:case o.H5:case o.H6:{lg(e);break}case o.BR:{dg(e);break}case o.BODY:{ng(e,t);break}case o.HTML:{rg(e,t);break}case o.FORM:{ag(e);break}case o.APPLET:case o.OBJECT:case o.MARQUEE:{cg(e,t);break}case o.TEMPLATE:{gt(e,t);break}default:mo(e,t)}}function go(e,t){e.tmplInsertionModeStack.length>0?_o(e,t):$r(e,t)}function hg(e,t){var n;t.tagID===o.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function fg(e,t){e._err(t,N.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function dr(e,t){if(lo.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=T.IN_TABLE_TEXT,t.type){case $.CHARACTER:{Eo(e,t);break}case $.WHITESPACE_CHARACTER:{bo(e,t);break}}else dn(e,t)}function pg(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_CAPTION}function mg(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_COLUMN_GROUP}function gg(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(A.COLGROUP,o.COLGROUP),e.insertionMode=T.IN_COLUMN_GROUP,Jr(e,t)}function bg(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_TABLE_BODY}function Eg(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(A.TBODY,o.TBODY),e.insertionMode=T.IN_TABLE_BODY,Wn(e,t)}function Tg(e,t){e.openElements.hasInTableScope(o.TABLE)&&(e.openElements.popUntilTagNamePopped(o.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function xg(e,t){po(t)?e._appendElement(t,R.HTML):dn(e,t),t.ackSelfClosing=!0}function wg(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,R.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function kt(e,t){switch(t.tagID){case o.TD:case o.TH:case o.TR:{Eg(e,t);break}case o.STYLE:case o.SCRIPT:case o.TEMPLATE:{je(e,t);break}case o.COL:{gg(e,t);break}case o.FORM:{wg(e,t);break}case o.TABLE:{Tg(e,t);break}case o.TBODY:case o.TFOOT:case o.THEAD:{bg(e,t);break}case o.INPUT:{xg(e,t);break}case o.CAPTION:{pg(e,t);break}case o.COLGROUP:{mg(e,t);break}default:dn(e,t)}}function rn(e,t){switch(t.tagID){case o.TABLE:{e.openElements.hasInTableScope(o.TABLE)&&(e.openElements.popUntilTagNamePopped(o.TABLE),e._resetInsertionMode());break}case o.TEMPLATE:{gt(e,t);break}case o.BODY:case o.CAPTION:case o.COL:case o.COLGROUP:case o.HTML:case o.TBODY:case o.TD:case o.TFOOT:case o.TH:case o.THEAD:case o.TR:break;default:dn(e,t)}}function dn(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,jn(e,t),e.fosterParentingEnabled=n}function bo(e,t){e.pendingCharacterTokens.push(t)}function Eo(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Wt(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)dn(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const To=new Set([o.CAPTION,o.COL,o.COLGROUP,o.TBODY,o.TD,o.TFOOT,o.TH,o.THEAD,o.TR]);function yg(e,t){const n=t.tagID;To.has(n)?e.openElements.hasInTableScope(o.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(o.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_TABLE,kt(e,t)):ke(e,t)}function _g(e,t){const n=t.tagID;switch(n){case o.CAPTION:case o.TABLE:{e.openElements.hasInTableScope(o.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(o.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_TABLE,n===o.TABLE&&rn(e,t));break}case o.BODY:case o.COL:case o.COLGROUP:case o.HTML:case o.TBODY:case o.TD:case o.TFOOT:case o.TH:case o.THEAD:case o.TR:break;default:Yn(e,t)}}function Jr(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.COL:{e._appendElement(t,R.HTML),t.ackSelfClosing=!0;break}case o.TEMPLATE:{je(e,t);break}default:On(e,t)}}function Ag(e,t){switch(t.tagID){case o.COLGROUP:{e.openElements.currentTagId===o.COLGROUP&&(e.openElements.pop(),e.insertionMode=T.IN_TABLE);break}case o.TEMPLATE:{gt(e,t);break}case o.COL:break;default:On(e,t)}}function On(e,t){e.openElements.currentTagId===o.COLGROUP&&(e.openElements.pop(),e.insertionMode=T.IN_TABLE,e._processToken(t))}function Wn(e,t){switch(t.tagID){case o.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_ROW;break}case o.TH:case o.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(A.TR,o.TR),e.insertionMode=T.IN_ROW,qn(e,t);break}case o.CAPTION:case o.COL:case o.COLGROUP:case o.TBODY:case o.TFOOT:case o.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE,kt(e,t));break}default:kt(e,t)}}function Ir(e,t){const n=t.tagID;switch(t.tagID){case o.TBODY:case o.TFOOT:case o.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE);break}case o.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE,rn(e,t));break}case o.BODY:case o.CAPTION:case o.COL:case o.COLGROUP:case o.HTML:case o.TD:case o.TH:case o.TR:break;default:rn(e,t)}}function qn(e,t){switch(t.tagID){case o.TH:case o.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_CELL,e.activeFormattingElements.insertMarker();break}case o.CAPTION:case o.COL:case o.COLGROUP:case o.TBODY:case o.TFOOT:case o.THEAD:case o.TR:{e.openElements.hasInTableScope(o.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,Wn(e,t));break}default:kt(e,t)}}function xo(e,t){switch(t.tagID){case o.TR:{e.openElements.hasInTableScope(o.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY);break}case o.TABLE:{e.openElements.hasInTableScope(o.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,Ir(e,t));break}case o.TBODY:case o.TFOOT:case o.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(o.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,Ir(e,t));break}case o.BODY:case o.CAPTION:case o.COL:case o.COLGROUP:case o.HTML:case o.TD:case o.TH:break;default:rn(e,t)}}function Cg(e,t){const n=t.tagID;To.has(n)?(e.openElements.hasInTableScope(o.TD)||e.openElements.hasInTableScope(o.TH))&&(e._closeTableCell(),qn(e,t)):ke(e,t)}function kg(e,t){const n=t.tagID;switch(n){case o.TD:case o.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_ROW);break}case o.TABLE:case o.TBODY:case o.TFOOT:case o.THEAD:case o.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),xo(e,t));break}case o.BODY:case o.CAPTION:case o.COL:case o.COLGROUP:case o.HTML:break;default:Yn(e,t)}}function wo(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.OPTION:{e.openElements.currentTagId===o.OPTION&&e.openElements.pop(),e._insertElement(t,R.HTML);break}case o.OPTGROUP:{e.openElements.currentTagId===o.OPTION&&e.openElements.pop(),e.openElements.currentTagId===o.OPTGROUP&&e.openElements.pop(),e._insertElement(t,R.HTML);break}case o.HR:{e.openElements.currentTagId===o.OPTION&&e.openElements.pop(),e.openElements.currentTagId===o.OPTGROUP&&e.openElements.pop(),e._appendElement(t,R.HTML),t.ackSelfClosing=!0;break}case o.INPUT:case o.KEYGEN:case o.TEXTAREA:case o.SELECT:{e.openElements.hasInSelectScope(o.SELECT)&&(e.openElements.popUntilTagNamePopped(o.SELECT),e._resetInsertionMode(),t.tagID!==o.SELECT&&e._processStartTag(t));break}case o.SCRIPT:case o.TEMPLATE:{je(e,t);break}}}function yo(e,t){switch(t.tagID){case o.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===o.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===o.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===o.OPTGROUP&&e.openElements.pop();break}case o.OPTION:{e.openElements.currentTagId===o.OPTION&&e.openElements.pop();break}case o.SELECT:{e.openElements.hasInSelectScope(o.SELECT)&&(e.openElements.popUntilTagNamePopped(o.SELECT),e._resetInsertionMode());break}case o.TEMPLATE:{gt(e,t);break}}}function Ng(e,t){const n=t.tagID;n===o.CAPTION||n===o.TABLE||n===o.TBODY||n===o.TFOOT||n===o.THEAD||n===o.TR||n===o.TD||n===o.TH?(e.openElements.popUntilTagNamePopped(o.SELECT),e._resetInsertionMode(),e._processStartTag(t)):wo(e,t)}function Ig(e,t){const n=t.tagID;n===o.CAPTION||n===o.TABLE||n===o.TBODY||n===o.TFOOT||n===o.THEAD||n===o.TR||n===o.TD||n===o.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(o.SELECT),e._resetInsertionMode(),e.onEndTag(t)):yo(e,t)}function Sg(e,t){switch(t.tagID){case o.BASE:case o.BASEFONT:case o.BGSOUND:case o.LINK:case o.META:case o.NOFRAMES:case o.SCRIPT:case o.STYLE:case o.TEMPLATE:case o.TITLE:{je(e,t);break}case o.CAPTION:case o.COLGROUP:case o.TBODY:case o.TFOOT:case o.THEAD:{e.tmplInsertionModeStack[0]=T.IN_TABLE,e.insertionMode=T.IN_TABLE,kt(e,t);break}case o.COL:{e.tmplInsertionModeStack[0]=T.IN_COLUMN_GROUP,e.insertionMode=T.IN_COLUMN_GROUP,Jr(e,t);break}case o.TR:{e.tmplInsertionModeStack[0]=T.IN_TABLE_BODY,e.insertionMode=T.IN_TABLE_BODY,Wn(e,t);break}case o.TD:case o.TH:{e.tmplInsertionModeStack[0]=T.IN_ROW,e.insertionMode=T.IN_ROW,qn(e,t);break}default:e.tmplInsertionModeStack[0]=T.IN_BODY,e.insertionMode=T.IN_BODY,ke(e,t)}}function Og(e,t){t.tagID===o.TEMPLATE&>(e,t)}function _o(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(o.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):$r(e,t)}function Lg(e,t){t.tagID===o.HTML?ke(e,t):Ln(e,t)}function Ao(e,t){var n;if(t.tagID===o.HTML){if(e.fragmentContext||(e.insertionMode=T.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===o.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else Ln(e,t)}function Ln(e,t){e.insertionMode=T.IN_BODY,jn(e,t)}function Rg(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.FRAMESET:{e._insertElement(t,R.HTML);break}case o.FRAME:{e._appendElement(t,R.HTML),t.ackSelfClosing=!0;break}case o.NOFRAMES:{je(e,t);break}}}function Dg(e,t){t.tagID===o.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==o.FRAMESET&&(e.insertionMode=T.AFTER_FRAMESET))}function vg(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.NOFRAMES:{je(e,t);break}}}function Pg(e,t){t.tagID===o.HTML&&(e.insertionMode=T.AFTER_AFTER_FRAMESET)}function Mg(e,t){t.tagID===o.HTML?ke(e,t):_n(e,t)}function _n(e,t){e.insertionMode=T.IN_BODY,jn(e,t)}function Bg(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.NOFRAMES:{je(e,t);break}}}function Fg(e,t){t.chars=he,e._insertCharacters(t)}function Hg(e,t){e._insertCharacters(t),e.framesetOk=!1}function Co(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==R.HTML&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function Ug(e,t){if(tm(t))Co(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===R.MATHML?oo(t):r===R.SVG&&(nm(t),uo(t)),Xr(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function zg(e,t){if(t.tagID===o.P||t.tagID===o.BR){Co(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===R.HTML){e._endTagOutsideForeignContent(t);break}const i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}A.AREA,A.BASE,A.BASEFONT,A.BGSOUND,A.BR,A.COL,A.EMBED,A.FRAME,A.HR,A.IMG,A.INPUT,A.KEYGEN,A.LINK,A.META,A.PARAM,A.SOURCE,A.TRACK,A.WBR;const jg=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,Yg=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),Na={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function ko(e,t){const n=Zg(e),r=Ua("type",{handlers:{root:Wg,element:qg,text:Vg,comment:Io,doctype:Gg,raw:Xg},unknown:Kg}),i={parser:n?new Aa(Na):Aa.getFragmentParser(void 0,Na),handle(u){r(u,i)},stitches:!1,options:t||{}};r(e,i),vt(i,Ve());const a=n?i.parser.document:i.parser.getFragment(),s=ep(a,{file:i.options.file});return i.stitches&&Bn(s,"comment",function(u,l,c){const d=u;if(d.value.stitch&&c&&l!==void 0){const h=c.children;return h[l]=d.value.stitch,l}}),s.type==="root"&&s.children.length===1&&s.children[0].type===e.type?s.children[0]:s}function No(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function Wg(e,t){No(e.children,t)}function qg(e,t){$g(e,t),No(e.children,t),Jg(e,t)}function Vg(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:$.CHARACTER,chars:e.value,location:hn(e)};vt(t,Ve(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function Gg(e,t){const n={type:$.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:hn(e)};vt(t,Ve(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function Qg(e,t){t.stitches=!0;const n=e1(e);if("children"in e&&"children"in n){const r=ko({type:"root",children:e.children},t.options);n.children=r.children}Io({type:"comment",value:{stitch:n}},t)}function Io(e,t){const n=e.value,r={type:$.COMMENT,data:n,location:hn(e)};vt(t,Ve(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function Xg(e,t){if(t.parser.tokenizer.preprocessor.html="",t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,So(t,Ve(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(jg,"<$1$2"):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;const n=t.parser.tokenizer._consume();t.parser.tokenizer._callState(n)}}function Kg(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))Qg(n,t);else{let r="";throw Yg.has(n.type)&&(r=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),new Error("Cannot compile `"+n.type+"` node"+r)}}function vt(e,t){So(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=pe.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function So(e,t){if(t&&t.offset!==void 0){const n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function $g(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===pe.PLAINTEXT)return;vt(t,Ve(e));const r=t.parser.openElements.current;let i="namespaceURI"in r?r.namespaceURI:ht.html;i===ht.html&&n==="svg"&&(i=ht.svg);const a=ap({...e,children:[]},{space:i===ht.svg?"svg":"html"}),s={type:$.START_TAG,tagName:n,tagID:Dt(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:hn(e)};t.parser.currentToken=s,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function Jg(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&fp.includes(n)||t.parser.tokenizer.state===pe.PLAINTEXT)return;vt(t,Un(e));const r={type:$.END_TAG,tagName:n,tagID:Dt(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:hn(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===pe.RCDATA||t.parser.tokenizer.state===pe.RAWTEXT||t.parser.tokenizer.state===pe.SCRIPT_DATA)&&(t.parser.tokenizer.state=pe.DATA)}function Zg(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function hn(e){const t=Ve(e)||{line:void 0,column:void 0,offset:void 0},n=Un(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function e1(e){return"children"in e?Ct({...e,children:[]}):Ct(e)}function Oo(e){return function(t,n){return ko(t,{...e,file:n})}}const Zr="-",t1=e=>{const t=r1(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{const u=s.split(Zr);return u[0]===""&&u.length!==1&&u.shift(),Lo(u,t)||n1(s)},getConflictingClassGroupIds:(s,u)=>{const l=n[s]||[];return u&&r[s]?[...l,...r[s]]:l}}},Lo=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),i=r?Lo(e.slice(1),r):void 0;if(i)return i;if(t.validators.length===0)return;const a=e.join(Zr);return(s=t.validators.find(({validator:u})=>u(a)))==null?void 0:s.classGroupId},Ia=/^\[(.+)\]$/,n1=e=>{if(Ia.test(e)){const t=Ia.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},r1=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return a1(Object.entries(e.classGroups),n).forEach(([a,s])=>{Sr(s,r,a,t)}),r},Sr=(e,t,n,r)=>{e.forEach(i=>{if(typeof i=="string"){const a=i===""?t:Sa(t,i);a.classGroupId=n;return}if(typeof i=="function"){if(i1(i)){Sr(i(r),t,n,r);return}t.validators.push({validator:i,classGroupId:n});return}Object.entries(i).forEach(([a,s])=>{Sr(s,Sa(t,a),n,r)})})},Sa=(e,t)=>{let n=e;return t.split(Zr).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},i1=e=>e.isThemeGetter,a1=(e,t)=>t?e.map(([n,r])=>{const i=r.map(a=>typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([s,u])=>[t+s,u])):a);return[n,i]}):e,s1=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const i=(a,s)=>{n.set(a,s),t++,t>e&&(t=0,r=n,n=new Map)};return{get(a){let s=n.get(a);if(s!==void 0)return s;if((s=r.get(a))!==void 0)return i(a,s),s},set(a,s){n.has(a)?n.set(a,s):i(a,s)}}},Ro="!",o1=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,i=t[0],a=t.length,s=u=>{const l=[];let c=0,d=0,h;for(let k=0;k<u.length;k++){let _=u[k];if(c===0){if(_===i&&(r||u.slice(k,k+a)===t)){l.push(u.slice(d,k)),d=k+a;continue}if(_==="/"){h=k;continue}}_==="["?c++:_==="]"&&c--}const g=l.length===0?u:u.substring(d),p=g.startsWith(Ro),E=p?g.substring(1):g,y=h&&h>d?h-d:void 0;return{modifiers:l,hasImportantModifier:p,baseClassName:E,maybePostfixModifierPosition:y}};return n?u=>n({className:u,parseClassName:s}):s},u1=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},l1=e=>({cache:s1(e.cacheSize),parseClassName:o1(e),...t1(e)}),c1=/\s+/,d1=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i}=t,a=[],s=e.trim().split(c1);let u="";for(let l=s.length-1;l>=0;l-=1){const c=s[l],{modifiers:d,hasImportantModifier:h,baseClassName:g,maybePostfixModifierPosition:p}=n(c);let E=!!p,y=r(E?g.substring(0,p):g);if(!y){if(!E){u=c+(u.length>0?" "+u:u);continue}if(y=r(g),!y){u=c+(u.length>0?" "+u:u);continue}E=!1}const k=u1(d).join(":"),_=h?k+Ro:k,S=_+y;if(a.includes(S))continue;a.push(S);const L=i(y,E);for(let M=0;M<L.length;++M){const F=L[M];a.push(_+F)}u=c+(u.length>0?" "+u:u)}return u};function h1(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Do(t))&&(r&&(r+=" "),r+=n);return r}const Do=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Do(e[r]))&&(n&&(n+=" "),n+=t);return n};function f1(e,...t){let n,r,i,a=s;function s(l){const c=t.reduce((d,h)=>h(d),e());return n=l1(c),r=n.cache.get,i=n.cache.set,a=u,u(l)}function u(l){const c=r(l);if(c)return c;const d=d1(l,n);return i(l,d),d}return function(){return a(h1.apply(null,arguments))}}const ue=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},vo=/^\[(?:([a-z-]+):)?(.+)\]$/i,p1=/^\d+\/\d+$/,m1=new Set(["px","full","screen"]),g1=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,b1=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,E1=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,T1=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,x1=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Xe=e=>At(e)||m1.has(e)||p1.test(e),tt=e=>Pt(e,"length",I1),At=e=>!!e&&!Number.isNaN(Number(e)),hr=e=>Pt(e,"number",At),qt=e=>!!e&&Number.isInteger(Number(e)),w1=e=>e.endsWith("%")&&At(e.slice(0,-1)),Q=e=>vo.test(e),nt=e=>g1.test(e),y1=new Set(["length","size","percentage"]),_1=e=>Pt(e,y1,Po),A1=e=>Pt(e,"position",Po),C1=new Set(["image","url"]),k1=e=>Pt(e,C1,O1),N1=e=>Pt(e,"",S1),Vt=()=>!0,Pt=(e,t,n)=>{const r=vo.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},I1=e=>b1.test(e)&&!E1.test(e),Po=()=>!1,S1=e=>T1.test(e),O1=e=>x1.test(e),L1=()=>{const e=ue("colors"),t=ue("spacing"),n=ue("blur"),r=ue("brightness"),i=ue("borderColor"),a=ue("borderRadius"),s=ue("borderSpacing"),u=ue("borderWidth"),l=ue("contrast"),c=ue("grayscale"),d=ue("hueRotate"),h=ue("invert"),g=ue("gap"),p=ue("gradientColorStops"),E=ue("gradientColorStopPositions"),y=ue("inset"),k=ue("margin"),_=ue("opacity"),S=ue("padding"),L=ue("saturate"),M=ue("scale"),F=ue("sepia"),I=ue("skew"),j=ue("space"),U=ue("translate"),z=()=>["auto","contain","none"],C=()=>["auto","hidden","clip","visible","scroll"],H=()=>["auto",Q,t],P=()=>[Q,t],te=()=>["",Xe,tt],ne=()=>["auto",At,Q],K=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],ce=()=>["solid","dashed","dotted","double","none"],fe=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Ee=()=>["start","end","center","between","around","evenly","stretch"],Te=()=>["","0",Q],x=()=>["auto","avoid","all","avoid-page","page","left","right","column"],de=()=>[At,Q];return{cacheSize:500,separator:":",theme:{colors:[Vt],spacing:[Xe,tt],blur:["none","",nt,Q],brightness:de(),borderColor:[e],borderRadius:["none","","full",nt,Q],borderSpacing:P(),borderWidth:te(),contrast:de(),grayscale:Te(),hueRotate:de(),invert:Te(),gap:P(),gradientColorStops:[e],gradientColorStopPositions:[w1,tt],inset:H(),margin:H(),opacity:de(),padding:P(),saturate:de(),scale:de(),sepia:Te(),skew:de(),space:P(),translate:P()},classGroups:{aspect:[{aspect:["auto","square","video",Q]}],container:["container"],columns:[{columns:[nt]}],"break-after":[{"break-after":x()}],"break-before":[{"break-before":x()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...K(),Q]}],overflow:[{overflow:C()}],"overflow-x":[{"overflow-x":C()}],"overflow-y":[{"overflow-y":C()}],overscroll:[{overscroll:z()}],"overscroll-x":[{"overscroll-x":z()}],"overscroll-y":[{"overscroll-y":z()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[y]}],"inset-x":[{"inset-x":[y]}],"inset-y":[{"inset-y":[y]}],start:[{start:[y]}],end:[{end:[y]}],top:[{top:[y]}],right:[{right:[y]}],bottom:[{bottom:[y]}],left:[{left:[y]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",qt,Q]}],basis:[{basis:H()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Q]}],grow:[{grow:Te()}],shrink:[{shrink:Te()}],order:[{order:["first","last","none",qt,Q]}],"grid-cols":[{"grid-cols":[Vt]}],"col-start-end":[{col:["auto",{span:["full",qt,Q]},Q]}],"col-start":[{"col-start":ne()}],"col-end":[{"col-end":ne()}],"grid-rows":[{"grid-rows":[Vt]}],"row-start-end":[{row:["auto",{span:[qt,Q]},Q]}],"row-start":[{"row-start":ne()}],"row-end":[{"row-end":ne()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Q]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Q]}],gap:[{gap:[g]}],"gap-x":[{"gap-x":[g]}],"gap-y":[{"gap-y":[g]}],"justify-content":[{justify:["normal",...Ee()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Ee(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Ee(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[S]}],px:[{px:[S]}],py:[{py:[S]}],ps:[{ps:[S]}],pe:[{pe:[S]}],pt:[{pt:[S]}],pr:[{pr:[S]}],pb:[{pb:[S]}],pl:[{pl:[S]}],m:[{m:[k]}],mx:[{mx:[k]}],my:[{my:[k]}],ms:[{ms:[k]}],me:[{me:[k]}],mt:[{mt:[k]}],mr:[{mr:[k]}],mb:[{mb:[k]}],ml:[{ml:[k]}],"space-x":[{"space-x":[j]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[j]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Q,t]}],"min-w":[{"min-w":[Q,t,"min","max","fit"]}],"max-w":[{"max-w":[Q,t,"none","full","min","max","fit","prose",{screen:[nt]},nt]}],h:[{h:[Q,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Q,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Q,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Q,t,"auto","min","max","fit"]}],"font-size":[{text:["base",nt,tt]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",hr]}],"font-family":[{font:[Vt]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Q]}],"line-clamp":[{"line-clamp":["none",At,hr]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Xe,Q]}],"list-image":[{"list-image":["none",Q]}],"list-style-type":[{list:["none","disc","decimal",Q]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[_]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[_]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ce(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Xe,tt]}],"underline-offset":[{"underline-offset":["auto",Xe,Q]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:P()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Q]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Q]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[_]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...K(),A1]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",_1]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},k1]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[E]}],"gradient-via-pos":[{via:[E]}],"gradient-to-pos":[{to:[E]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[u]}],"border-w-x":[{"border-x":[u]}],"border-w-y":[{"border-y":[u]}],"border-w-s":[{"border-s":[u]}],"border-w-e":[{"border-e":[u]}],"border-w-t":[{"border-t":[u]}],"border-w-r":[{"border-r":[u]}],"border-w-b":[{"border-b":[u]}],"border-w-l":[{"border-l":[u]}],"border-opacity":[{"border-opacity":[_]}],"border-style":[{border:[...ce(),"hidden"]}],"divide-x":[{"divide-x":[u]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[u]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[_]}],"divide-style":[{divide:ce()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...ce()]}],"outline-offset":[{"outline-offset":[Xe,Q]}],"outline-w":[{outline:[Xe,tt]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:te()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[_]}],"ring-offset-w":[{"ring-offset":[Xe,tt]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",nt,N1]}],"shadow-color":[{shadow:[Vt]}],opacity:[{opacity:[_]}],"mix-blend":[{"mix-blend":[...fe(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":fe()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",nt,Q]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[h]}],saturate:[{saturate:[L]}],sepia:[{sepia:[F]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[h]}],"backdrop-opacity":[{"backdrop-opacity":[_]}],"backdrop-saturate":[{"backdrop-saturate":[L]}],"backdrop-sepia":[{"backdrop-sepia":[F]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Q]}],duration:[{duration:de()}],ease:[{ease:["linear","in","out","in-out",Q]}],delay:[{delay:de()}],animate:[{animate:["none","spin","ping","pulse","bounce",Q]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[M]}],"scale-x":[{"scale-x":[M]}],"scale-y":[{"scale-y":[M]}],rotate:[{rotate:[qt,Q]}],"translate-x":[{"translate-x":[U]}],"translate-y":[{"translate-y":[U]}],"skew-x":[{"skew-x":[I]}],"skew-y":[{"skew-y":[I]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Q]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Q]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":P()}],"scroll-mx":[{"scroll-mx":P()}],"scroll-my":[{"scroll-my":P()}],"scroll-ms":[{"scroll-ms":P()}],"scroll-me":[{"scroll-me":P()}],"scroll-mt":[{"scroll-mt":P()}],"scroll-mr":[{"scroll-mr":P()}],"scroll-mb":[{"scroll-mb":P()}],"scroll-ml":[{"scroll-ml":P()}],"scroll-p":[{"scroll-p":P()}],"scroll-px":[{"scroll-px":P()}],"scroll-py":[{"scroll-py":P()}],"scroll-ps":[{"scroll-ps":P()}],"scroll-pe":[{"scroll-pe":P()}],"scroll-pt":[{"scroll-pt":P()}],"scroll-pr":[{"scroll-pr":P()}],"scroll-pb":[{"scroll-pb":P()}],"scroll-pl":[{"scroll-pl":P()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Q]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Xe,tt,hr]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},R1=f1(L1);function q(...e){return R1(va.clsx(e))}function Or(){return Or=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Or.apply(null,arguments)}function D1(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.includes(r))continue;n[r]=e[r]}return n}var Mo,Bo;typeof document<"u"&&(Mo=document);typeof window<"u"&&(Bo=window);var Fo=X.createContext({document:Mo,window:Bo}),v1=()=>X.useContext(Fo),P1=["children","head","initialContent","src","mountTarget"],ei=X.forwardRef((e,t)=>{var{children:n,head:r,initialContent:i,src:a,mountTarget:s}=e,u=D1(e,P1),[l,c]=X.useState(!1),[d,h]=X.useState(),g=M=>{M&&h(M)};X.useImperativeHandle(t,()=>d,[d]);var p=i||"<!DOCTYPE html><html><head></head><body></body></html>",E=()=>d?d.contentDocument:null,y=()=>{var M=E();return s?M==null?void 0:M.querySelector(s):M==null?void 0:M.body},k=X.useRef(),_=X.useCallback(M=>{k.current=M;var F=()=>setInterval(()=>_(M),500);clearInterval(F()),l||c(!0)},[l]);X.useMemo(()=>{!a&&u.onLoad&&l&&u.onLoad(k.current)},[l]),X.useEffect(()=>{if(d&&!a){var M;(M=d.contentWindow)==null||M.addEventListener("DOMContentLoaded",_)}return()=>{if(d&&!a){var F;(F=d.contentWindow)==null||F.removeEventListener("DOMContentLoaded",_)}}},[d,_]);var S=()=>{var M,F=E(),I=(M=E())==null?void 0:M.head,j=y(),U=(F==null?void 0:F.defaultView)||(F==null?void 0:F.parentView),z=f.jsx(Fo.Provider,{value:{document:F,window:U},children:n});return[I&&r&&fr.createPortal(r,I),d&&j&&fr.createPortal(z,j)]},L={};return a?(delete L.srcDoc,L.src=a,L.onLoad=u.onLoad):L.srcDoc=p,f.jsx("iframe",Or({title:u.title,ref:g},u,{onLoad:_},L,{children:l&&S()}))});ei.displayName="IFrame";const Ho="opencx-widget-portal";function Vn(){return null}function M1({children:e}){var n,r;const t=(r=(n=v1())==null?void 0:n.document)==null?void 0:r.getElementById(Ho);return t?fr.createPortal(e,t):(console.error("Portal container not found!"),null)}function B1(){return f.jsx("div",{id:Ho,className:"absolute size-full top-0 left-0"})}Vn.Portal=M1;Vn.Container=B1;const Oa=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,La=va.clsx,F1=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return La(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:i,defaultVariants:a}=t,s=Object.keys(i).map(c=>{const d=n==null?void 0:n[c],h=a==null?void 0:a[c];if(d===null)return null;const g=Oa(d)||Oa(h);return i[c][g]}),u=n&&Object.entries(n).reduce((c,d)=>{let[h,g]=d;return g===void 0||(c[h]=g),c},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,d)=>{let{class:h,className:g,...p}=d;return Object.entries(p).every(E=>{let[y,k]=E;return Array.isArray(k)?k.includes({...a,...u}[y]):{...a,...u}[y]===k})?[...c,h,g]:c},[]);return La(e,s,l,n==null?void 0:n.class,n==null?void 0:n.className)},Nt={x:2,y:2},$e=X.memo(X.forwardRef(({children:e,className:t,scale:n=1.02,off:r=!1},i)=>{const[a,s]=X.useState(!1),[u,l]=X.useState({x:0,y:0});if(r||/translate/.test(e.props.className||""))return e;const d=E=>{var U,z;const{clientX:y,clientY:k}=E,_=E.currentTarget.getBoundingClientRect(),S=y-(_.left+_.width/2),L=k-(_.top+_.height/2),M=Math.max(-1,Math.min(1,S/(_.width/2))),F=Math.max(-1,Math.min(1,L/(_.height/2))),I=M*Nt.x,j=F*Nt.y;l({x:I,y:j}),(z=(U=e.props).onMouseMove)==null||z.call(U,E)},h=()=>{var E,y;s(!0),(y=(E=e.props).onMouseEnter)==null||y.call(E)},g=()=>{var E,y;s(!1),l({x:0,y:0}),(y=(E=e.props).onMouseLeave)==null||y.call(E)},p={"--wobble-x":a?`${u.x}px`:"0px","--wobble-y":a?`${u.y}px`:"0px","--scale":1-(n-1)};return X.cloneElement(e,{ref:i,onMouseMove:d,onMouseEnter:h,onMouseLeave:g,style:{...p,...e.props.style},className:q("translate-x-[var(--wobble-x)]","translate-y-[var(--wobble-y)]","hover:scale-[var(--scale)] active:hover:scale-[calc(var(--scale)-0.02)]",t,e.props.className,"transition-all ease-out")})}));$e.displayName="Wobble";function re(e){return{"data-component":e}}const H1=F1(q("inline-flex shrink-0 items-center justify-center gap-2","text-sm font-medium whitespace-nowrap","ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50","active:scale-95 hover:active:scale-95","rounded-xl","border","transition"),{variants:{variant:{default:"border-primary bg-primary text-primary-foreground",destructive:"border-destructive bg-destructive text-destructive-foreground",outline:"bg-background hover:border-primary",secondary:"bg-secondary text-secondary-foreground",ghost:"border-transparent hover:bg-secondary",link:"border-transparent text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"py-2 px-3.5 text-xs",lg:"min-h-12 px-4",icon:"h-10 w-10",fit:"size-fit p-2",free:"p-2",selfless:"p-0"}},defaultVariants:{variant:"default",size:"default"}}),Oe=ye.forwardRef(({className:e,variant:t="default",size:n,asChild:r=!1,...i},a)=>{const s=r?cu.Slot:"button";return f.jsx($e,{ref:a,children:f.jsx(s,{...re("ui_lib/btn"),"data-variant":t,className:q(H1({variant:t,size:n,className:e})),...i})})});Oe.displayName="Button";const U1=ze.Root,z1=ze.Trigger,Uo=ye.forwardRef(({className:e,...t},n)=>f.jsx(ze.Overlay,{ref:n,className:q("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));Uo.displayName=ze.Overlay.displayName;const zo=ye.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(Vn.Portal,{children:[f.jsx(Uo,{}),f.jsxs(ze.Content,{ref:r,className:q("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...n,children:[t,f.jsx(ze.Close,{asChild:!0,className:"absolute right-4 top-4 opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:f.jsxs(Oe,{size:"fit",variant:"ghost",children:[f.jsx(le.X,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"Close"})]})})]})]}));zo.displayName=ze.Content.displayName;const jo=ye.forwardRef(({className:e,...t},n)=>f.jsx(ze.Title,{ref:n,className:q("text-lg font-semibold leading-none tracking-tight",e),...t}));jo.displayName=ze.Title.displayName;const j1=ye.forwardRef(({className:e,...t},n)=>f.jsx(ze.Description,{ref:n,className:q("text-sm text-muted-foreground",e),...t}));j1.displayName=ze.Description.displayName;function Yo({attachment:e}){const{name:t,size:n,type:r,url:i}=e,a=r.startsWith("image/"),s=r.startsWith("video/"),u=r.startsWith("audio/");return u?f.jsx($e,{children:f.jsx("div",{className:"w-full shrink-0 overflow-hidden",children:f.jsxs("audio",{controls:!0,className:"w-full",children:[f.jsx("source",{src:i,type:r}),"Your browser does not support the audio tag."]})})}):s?f.jsx($e,{children:f.jsx("div",{className:"w-full border shrink-0 rounded-2xl overflow-hidden",children:f.jsxs("video",{controls:!0,children:[f.jsx("source",{src:i,type:r}),"Your browser does not support the video tag."]})})}):!a&&!s&&!u?f.jsx($e,{children:f.jsx("div",{className:"size-fit border shrink-0 rounded-2xl overflow-hidden",children:f.jsxs("div",{className:"flex items-end gap-2 p-2",children:[f.jsx("a",{href:i,target:"_blank",rel:"noopener noreferrer",className:q("text-xs text-blue-500 line-clamp-2 underline hover:text-blue-600","break-words [word-break:break-word]"),children:t}),f.jsxs("span",{className:"text-xs text-muted-foreground whitespace-nowrap",children:[(n/1024).toFixed(2)," KB"]})]})})}):f.jsxs(U1,{children:[f.jsx($e,{children:f.jsx(z1,{children:f.jsx("div",{className:"size-fit border shrink-0 rounded-2xl overflow-hidden",children:a&&f.jsx("img",{src:i,className:"object-cover size-16",alt:t})})})}),f.jsxs(zo,{"aria-describedby":void 0,className:"size-full rounded-3xl flex items-center justify-center bg-transparent backdrop-blur border-none gap-0",children:[f.jsx(jo,{className:"sr-only",children:"Image preview"}),a&&f.jsx("div",{className:"size-fit shrink-0 rounded-2xl overflow-hidden max-h-full",children:f.jsx("img",{src:i,className:"object-cover size-auto",alt:t})})]})]})}function Rn({data:e,id:t,type:n,attachments:r,isFirstInGroup:i,isLastInGroup:a,isAloneInGroup:s,dataComponentNames:u,classNames:l}){const{anchorTarget:c}=W.useConfig(),{message:d,variant:h="default"}=e;return h==="error"?f.jsx("div",{children:f.jsx("div",{className:"flex flex-row flex-wrap items-center justify-start",children:f.jsx("div",{className:"leading-snug text-sm text-destructive",children:d})})}):f.jsxs("div",{...re((u==null?void 0:u.messageContainer)??"chat/agent_msg/root"),className:q("w-5/6 flex flex-col items-start gap-1",l==null?void 0:l.messageContainer),children:[r&&r.length>0&&f.jsx("div",{className:"w-full gap-1 flex flex-row flex-wrap items-center justify-start",children:r==null?void 0:r.map(g=>f.jsx(Yo,{attachment:g},g.id))}),d.length>0&&f.jsx("div",{...re((u==null?void 0:u.message)??"chat/agent_msg/msg"),"data-first":i,"data-last":a,"data-alone":s,className:q("transition-all","w-fit py-3 px-4 rounded-3xl bg-secondary text-secondary-foreground","leading-snug text-sm prose prose-sm prose-a:decoration-primary prose-a:underline","break-words [word-break:break-word]",i&&!s&&"rounded-bl-md",a&&!s&&"rounded-tl-md",!i&&!a&&!s&&"rounded-l-md",l==null?void 0:l.message),children:f.jsx(Ws,{"data-type":n,"data-id":t,remarkPlugins:[gs],rehypePlugins:[Oo],components:{a:({children:g,...p})=>f.jsx("a",{target:c??"_top",...p,children:g})},children:d})})]})}function Y1(e){return f.jsx("div",{className:"w-full max-w-full overflow-auto shrink-0",children:f.jsx("pre",{dir:"auto",className:"text-xs leading-tight whitespace-pre-wrap break-word",children:JSON.stringify(e,null,1)})})}const ti=ye.forwardRef(({className:e,...t},n)=>f.jsx(St.Root,{ref:n,className:q("relative flex size-6 aspect-square shrink-0 overflow-hidden rounded-full bg-secondary",e),...t}));ti.displayName=St.Root.displayName;const ni=ye.forwardRef(({className:e,...t},n)=>f.jsx(St.Image,{ref:n,className:q("aspect-square h-full w-full",e),...t}));ni.displayName=St.Image.displayName;const ri=ye.forwardRef(({className:e,...t},n)=>f.jsx(St.Fallback,{ref:n,className:q("flex size-full text-xs items-center justify-center rounded-lg",e),...t}));ri.displayName=St.Fallback.displayName;function Lr({agent:e,...t}){var n,r;return f.jsxs(ti,{...t,children:[f.jsx(ni,{src:(e==null?void 0:e.avatar)??"",alt:"Agent Icon"}),(e==null?void 0:e.name)&&f.jsx(ri,{children:(r=(n=e==null?void 0:e.name)==null?void 0:n.slice(0,1))==null?void 0:r.toUpperCase()})]})}const W1=10,q1=(e,t)=>({initial:{opacity:0,x:-e,...t.initial},animate:{opacity:1,x:0,...t.animate},exit:{opacity:0,x:e,...t.exit}}),V1=(e,t)=>({initial:{opacity:0,x:e,...t.initial},animate:{opacity:1,x:0,...t.animate},exit:{opacity:0,x:-e,...t.exit}}),G1=(e,t)=>({initial:{opacity:0,y:e,...t.initial},animate:{opacity:1,y:0,...t.animate},exit:{opacity:0,y:-e,...t.exit}}),Q1=(e,t)=>({initial:{opacity:0,y:-e,...t.initial},animate:{opacity:1,y:0,...t.animate},exit:{opacity:0,y:e,...t.exit}}),X1={right:q1,left:V1,up:G1,down:Q1},ae=X.forwardRef(({fadeIn:e="down",distance:t=W1,children:n,snapExit:r=!1,overrides:i={},...a},s)=>{const u=e?X1[e](t,i):{};return r&&u.exit&&typeof u.exit=="object"&&!Array.isArray(u.exit)&&(u.exit.transition={duration:0}),f.jsx(be.motion.div,{ref:s,...a,...u,children:n})});ae.displayName="MotionDiv";function K1({agent:e}){return f.jsx(be.AnimatePresence,{children:f.jsxs(ae,{...re("chat/bot_loading/root"),className:"flex flex-row items-end w-full gap-2 animate-pulse",children:[f.jsx(Lr,{agent:e}),f.jsxs("div",{...re("chat/bot_loading/bouncing_dots_container"),className:q("flex items-center [&_span]:bg-secondary-foreground [&_span]:size-1 gap-1 p-2 rounded-xl bg-secondary"),children:[f.jsx(be.motion.span,{className:"rounded-full animate-bounce [animation-delay:-0.3s]"}),f.jsx(be.motion.span,{className:"rounded-full animate-bounce [animation-delay:-0.15s]"}),f.jsx(be.motion.span,{className:"rounded-full animate-bounce"})]})]})})}const Wo='@import"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..700;1,14..32,100..700&display=swap";@import"https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap";*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}*{-ms-overflow-style:none;scrollbar-width:none}*::-webkit-scrollbar{display:none}*{border-color:hsl(var(--opencx-border))}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.prose{color:var(--tw-prose-body);max-width:65ch}.prose :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.prose :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-lead);font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.prose :where(a):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-links);text-decoration:underline;font-weight:500}.prose :where(strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-bold);font-weight:600}.prose :where(a strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(blockquote strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(thead th strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}.prose :where(ol[type=A]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}.prose :where(ol[type=a]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}.prose :where(ol[type=A s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}.prose :where(ol[type=a s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}.prose :where(ol[type=I]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}.prose :where(ol[type=i]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}.prose :where(ol[type=I s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}.prose :where(ol[type=i s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}.prose :where(ol[type="1"]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal}.prose :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:disc;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}.prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{font-weight:400;color:var(--tw-prose-counters)}.prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{color:var(--tw-prose-bullets)}.prose :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.25em}.prose :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){border-color:var(--tw-prose-hr);border-top-width:1px;margin-top:3em;margin-bottom:3em}.prose :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-style:italic;color:var(--tw-prose-quotes);border-inline-start-width:.25rem;border-inline-start-color:var(--tw-prose-quote-borders);quotes:"“""”""‘""’";margin-top:1.6em;margin-bottom:1.6em;padding-inline-start:1em}.prose :where(blockquote p:first-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:open-quote}.prose :where(blockquote p:last-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:close-quote}.prose :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.prose :where(h1 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:900;color:inherit}.prose :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.prose :where(h2 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:800;color:inherit}.prose :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.prose :where(h3 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}.prose :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.prose :where(h4 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}.prose :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){display:block;margin-top:2em;margin-bottom:2em}.prose :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-family:inherit;color:var(--tw-prose-kbd);box-shadow:0 0 0 1px rgb(var(--tw-prose-kbd-shadows) / 10%),0 3px rgb(var(--tw-prose-kbd-shadows) / 10%);font-size:.875em;border-radius:.3125rem;padding-top:.1875em;padding-inline-end:.375em;padding-bottom:.1875em;padding-inline-start:.375em}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-code);font-weight:600;font-size:.875em}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:"`"}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:"`"}.prose :where(a code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(h1 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.875em}.prose :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.9em}.prose :where(h4 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(blockquote code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(thead th code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-pre-code);background-color:var(--tw-prose-pre-bg);overflow-x:auto;font-weight:400;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding-top:.8571429em;padding-inline-end:1.1428571em;padding-bottom:.8571429em;padding-inline-start:1.1428571em}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)){background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:inherit;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:none}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:none}.prose :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){width:100%;table-layout:auto;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.prose :where(thead):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-th-borders)}.prose :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;vertical-align:bottom;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}.prose :where(tbody tr):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-td-borders)}.prose :where(tbody tr:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:0}.prose :where(tbody td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:baseline}.prose :where(tfoot):not(:where([class~=not-prose],[class~=not-prose] *)){border-top-width:1px;border-top-color:var(--tw-prose-th-borders)}.prose :where(tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:top}.prose :where(th,td):not(:where([class~=not-prose],[class~=not-prose] *)){text-align:start}.prose :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-captions);font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.prose{--tw-prose-body: #374151;--tw-prose-headings: #111827;--tw-prose-lead: #4b5563;--tw-prose-links: #111827;--tw-prose-bold: #111827;--tw-prose-counters: #6b7280;--tw-prose-bullets: #d1d5db;--tw-prose-hr: #e5e7eb;--tw-prose-quotes: #111827;--tw-prose-quote-borders: #e5e7eb;--tw-prose-captions: #6b7280;--tw-prose-kbd: #111827;--tw-prose-kbd-shadows: 17 24 39;--tw-prose-code: #111827;--tw-prose-pre-code: #e5e7eb;--tw-prose-pre-bg: #1f2937;--tw-prose-th-borders: #d1d5db;--tw-prose-td-borders: #e5e7eb;--tw-prose-invert-body: #d1d5db;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #9ca3af;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #9ca3af;--tw-prose-invert-bullets: #4b5563;--tw-prose-invert-hr: #374151;--tw-prose-invert-quotes: #f3f4f6;--tw-prose-invert-quote-borders: #374151;--tw-prose-invert-captions: #9ca3af;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: 255 255 255;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #d1d5db;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #4b5563;--tw-prose-invert-td-borders: #374151;font-size:1rem;line-height:1.75}.prose :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;margin-bottom:.5em}.prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}.prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}.prose :where(.prose>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}.prose :where(.prose>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}.prose :where(.prose>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}.prose :where(.prose>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}.prose :where(.prose>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}.prose :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}.prose :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.prose :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;padding-inline-start:1.625em}.prose :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.5714286em;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}.prose :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(.prose>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(.prose>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}.prose-sm{font-size:.875rem;line-height:1.7142857}.prose-sm :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.prose-sm :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;line-height:1.5555556;margin-top:.8888889em;margin-bottom:.8888889em}.prose-sm :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-inline-start:1.1111111em}.prose-sm :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:2.1428571em;margin-top:0;margin-bottom:.8em;line-height:1.2}.prose-sm :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.4285714em;margin-top:1.6em;margin-bottom:.8em;line-height:1.4}.prose-sm :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;margin-top:1.5555556em;margin-bottom:.4444444em;line-height:1.5555556}.prose-sm :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.4285714em;margin-bottom:.5714286em;line-height:1.4285714}.prose-sm :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose-sm :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;border-radius:.3125rem;padding-top:.1428571em;padding-inline-end:.3571429em;padding-bottom:.1428571em;padding-inline-start:.3571429em}.prose-sm :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em}.prose-sm :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.9em}.prose-sm :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em}.prose-sm :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.6666667;margin-top:1.6666667em;margin-bottom:1.6666667em;border-radius:.25rem;padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}.prose-sm :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}.prose-sm :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;margin-bottom:.2857143em}.prose-sm :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}.prose-sm :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}.prose-sm :where(.prose-sm>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.prose-sm :where(.prose-sm>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(.prose-sm>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}.prose-sm :where(.prose-sm>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(.prose-sm>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}.prose-sm :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.prose-sm :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.prose-sm :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;padding-inline-start:1.5714286em}.prose-sm :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2.8571429em;margin-bottom:2.8571429em}.prose-sm :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.5}.prose-sm :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose-sm :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose-sm :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose-sm :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose-sm :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose-sm :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.3333333;margin-top:.6666667em}.prose-sm :where(.prose-sm>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(.prose-sm>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.invisible{visibility:hidden}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.bottom-0{bottom:0}.left-0{left:0}.left-2{left:.5rem}.left-\\[50\\%\\]{left:50%}.right-4{right:1rem}.right-6{right:1.5rem}.top-0{top:0}.top-4{top:1rem}.top-6{top:1.5rem}.top-\\[50\\%\\]{top:50%}.isolate{isolation:isolate}.z-10{z-index:10}.z-50{z-index:50}.-mx-1{margin-left:-.25rem;margin-right:-.25rem}.my-1{margin-top:.25rem;margin-bottom:.25rem}.mb-2{margin-bottom:.5rem}.ml-auto{margin-left:auto}.mt-0\\.5{margin-top:.125rem}.mt-auto{margin-top:auto}.line-clamp-1{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.contents{display:contents}.hidden{display:none}.aspect-square{aspect-ratio:1 / 1}.size-10{width:2.5rem;height:2.5rem}.size-12{width:3rem;height:3rem}.size-16{width:4rem;height:4rem}.size-3{width:.75rem;height:.75rem}.size-3\\.5{width:.875rem;height:.875rem}.size-4{width:1rem;height:1rem}.size-6{width:1.5rem;height:1.5rem}.size-8{width:2rem;height:2rem}.size-auto{width:auto;height:auto}.size-fit{width:fit-content;height:fit-content}.size-full{width:100%;height:100%}.h-10{height:2.5rem}.h-2{height:.5rem}.h-3\\.5{height:.875rem}.h-4{height:1rem}.h-5{height:1.25rem}.h-8{height:2rem}.h-full{height:100%}.h-px{height:1px}.max-h-16{max-height:4rem}.max-h-full{max-height:100%}.min-h-12{min-height:3rem}.w-1\\/2{width:50%}.w-10{width:2.5rem}.w-2{width:.5rem}.w-3\\.5{width:.875rem}.w-4{width:1rem}.w-5\\/6{width:83.333333%}.w-60{width:15rem}.w-9{width:2.25rem}.w-auto{width:auto}.w-fit{width:fit-content}.w-full{width:100%}.min-w-56{min-width:14rem}.min-w-\\[8rem\\]{min-width:8rem}.max-w-\\[320px\\]{max-width:320px}.max-w-full{max-width:100%}.max-w-lg{max-width:32rem}.max-w-xs{max-width:20rem}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.translate-x-\\[-50\\%\\]{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-\\[var\\(--wobble-x\\)\\]{--tw-translate-x: var(--wobble-x);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-\\[-50\\%\\]{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-\\[var\\(--wobble-y\\)\\]{--tw-translate-y: var(--wobble-y);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes bounce{0%,to{transform:translateY(-25%);animation-timing-function:cubic-bezier(.8,0,1,1)}50%{transform:none;animation-timing-function:cubic-bezier(0,0,.2,1)}}.animate-bounce{animation:bounce 1s infinite}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.select-none{-webkit-user-select:none;user-select:none}.resize-none{resize:none}.resize{resize:both}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-0{gap:0px}.gap-0\\.5{gap:.125rem}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-4{gap:1rem}.gap-\\[1px\\]{gap:1px}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-1\\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.scroll-smooth{scroll-behavior:smooth}.text-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.break-words{overflow-wrap:break-word}.rounded-2xl{border-radius:1rem}.rounded-3xl{border-radius:1.5rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-sm{border-radius:.125rem}.rounded-xl{border-radius:.75rem}.rounded-l-md{border-top-left-radius:.375rem;border-bottom-left-radius:.375rem}.rounded-r-md{border-top-right-radius:.375rem;border-bottom-right-radius:.375rem}.rounded-bl-md{border-bottom-left-radius:.375rem}.rounded-br-md{border-bottom-right-radius:.375rem}.rounded-tl-md{border-top-left-radius:.375rem}.rounded-tr-md{border-top-right-radius:.375rem}.border{border-width:1px}.border-2{border-width:2px}.border-none{border-style:none}.border-destructive{border-color:hsl(var(--opencx-destructive))}.border-primary{border-color:hsl(var(--opencx-primary))}.border-transparent{border-color:transparent}.bg-background{background-color:hsl(var(--opencx-background))}.bg-black\\/50{background-color:#00000080}.bg-black\\/80{background-color:#000c}.bg-destructive{background-color:hsl(var(--opencx-destructive))}.bg-muted{background-color:hsl(var(--opencx-muted))}.bg-primary{background-color:hsl(var(--opencx-primary))}.bg-secondary{background-color:hsl(var(--opencx-secondary))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity))}.fill-current{fill:currentColor}.object-contain{object-fit:contain}.object-cover{object-fit:cover}.p-0{padding:0}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-4{padding:1rem}.p-6{padding:1.5rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3\\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.py-12{padding-top:3rem;padding-bottom:3rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.pb-0{padding-bottom:0}.pl-2{padding-left:.5rem}.pl-8{padding-left:2rem}.pr-2{padding-right:.5rem}.pr-4{padding-right:1rem}.pt-0{padding-top:0}.pt-1{padding-top:.25rem}.pt-2{padding-top:.5rem}.text-center{text-align:center}.text-start{text-align:start}.align-middle{vertical-align:middle}.font-inter{font-family:Inter,Rubik,serif,sans-serif}.text-2xl{font-size:1.5rem;line-height:2rem}.text-\\[10px\\]{font-size:10px}.text-\\[16px\\]{font-size:16px}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-semibold{font-weight:600}.leading-none{line-height:1}.leading-relaxed{line-height:1.625}.leading-snug{line-height:1.375}.leading-tight{line-height:1.25}.tracking-tight{letter-spacing:-.025em}.tracking-widest{letter-spacing:.1em}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity))}.text-destructive{color:hsl(var(--opencx-destructive))}.text-destructive-foreground{color:hsl(var(--opencx-destructive-foreground))}.text-emerald-600{--tw-text-opacity: 1;color:rgb(5 150 105 / var(--tw-text-opacity))}.text-foreground{color:hsl(var(--opencx-foreground))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity))}.text-muted-foreground{color:hsl(var(--opencx-muted-foreground))}.text-muted-foreground\\/70{color:hsl(var(--opencx-muted-foreground) / .7)}.text-primary{color:hsl(var(--opencx-primary))}.text-primary-foreground{color:hsl(var(--opencx-primary-foreground))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity))}.text-secondary-foreground{color:hsl(var(--opencx-secondary-foreground))}.underline{text-decoration-line:underline}.underline-offset-4{text-underline-offset:4px}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-95{opacity:.95}.shadow-2xl{--tw-shadow: 0 25px 50px -12px rgb(0 0 0 / .25);--tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.outline-none{outline:2px solid transparent;outline-offset:2px}.outline{outline-style:solid}.outline-8{outline-width:8px}.outline-background{outline-color:hsl(var(--opencx-background))}.ring-0{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-offset-background{--tw-ring-offset-color: hsl(var(--opencx-background))}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur{--tw-backdrop-blur: blur(8px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-200{transition-duration:.2s}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity, 1);transform:translate3d(var(--tw-enter-translate-x, 0),var(--tw-enter-translate-y, 0),0) scale3d(var(--tw-enter-scale, 1),var(--tw-enter-scale, 1),var(--tw-enter-scale, 1)) rotate(var(--tw-enter-rotate, 0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity, 1);transform:translate3d(var(--tw-exit-translate-x, 0),var(--tw-exit-translate-y, 0),0) scale3d(var(--tw-exit-scale, 1),var(--tw-exit-scale, 1),var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0))}}.animate-in{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.fade-in-0{--tw-enter-opacity: 0}.zoom-in-95{--tw-enter-scale: .95}.duration-200{animation-duration:.2s}.ease-out{animation-timing-function:cubic-bezier(0,0,.2,1)}.\\[animation-delay\\:-0\\.15s\\]{animation-delay:-.15s}.\\[animation-delay\\:-0\\.3s\\]{animation-delay:-.3s}.\\[field-sizing\\:content\\;\\],.\\[field-sizing\\:content\\]{field-sizing:content}.\\[word-break\\:break-word\\]{word-break:break-word}.required:after{content:" *";color:red}.file\\:border-0::file-selector-button{border-width:0px}.file\\:bg-transparent::file-selector-button{background-color:transparent}.file\\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\\:font-medium::file-selector-button{font-weight:500}.file\\:text-primary-foreground::file-selector-button{color:hsl(var(--opencx-primary-foreground))}.placeholder\\:text-muted-foreground::placeholder{color:hsl(var(--opencx-muted-foreground))}.focus-within\\:border-primary:focus-within{border-color:hsl(var(--opencx-primary))}.hover\\:scale-\\[var\\(--scale\\)\\]:hover{--tw-scale-x: var(--scale);--tw-scale-y: var(--scale);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:border-primary:hover{border-color:hsl(var(--opencx-primary))}.hover\\:bg-green-50\\/50:hover{background-color:#f0fdf480}.hover\\:bg-red-50\\/50:hover{background-color:#fef2f280}.hover\\:bg-secondary:hover{background-color:hsl(var(--opencx-secondary))}.hover\\:text-blue-600:hover{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity))}.hover\\:text-green-500:hover{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity))}.hover\\:text-primary:hover{color:hsl(var(--opencx-primary))}.hover\\:text-red-500:hover{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity))}.hover\\:underline:hover{text-decoration-line:underline}.hover\\:opacity-100:hover{opacity:1}.focus\\:bg-accent:focus{background-color:hsl(var(--opencx-accent))}.focus\\:text-accent-foreground:focus{color:hsl(var(--opencx-accent-foreground))}.focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\\:ring-ring:focus{--tw-ring-color: hsl(var(--opencx-ring))}.focus\\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.focus-visible\\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\\:ring-2:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\\:ring-ring:focus-visible{--tw-ring-color: hsl(var(--opencx-ring))}.focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width: 2px}.focus-visible\\:ring-offset-background:focus-visible{--tw-ring-offset-color: hsl(var(--opencx-background))}.active\\:scale-95:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.active\\:hover\\:scale-\\[calc\\(var\\(--scale\\)-0\\.02\\)\\]:hover:active{--tw-scale-x: calc(var(--scale) - .02);--tw-scale-y: calc(var(--scale) - .02);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:active\\:scale-95:active:hover{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.disabled\\:pointer-events-none:disabled{pointer-events:none}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opacity-50:disabled{opacity:.5}.group:hover .group-hover\\:opacity-100{opacity:1}.group:hover .group-hover\\:active\\:scale-90:active,.group:active .group-active\\:scale-90{--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[disabled\\]\\:pointer-events-none[data-disabled]{pointer-events:none}.data-\\[state\\=checked\\]\\:translate-x-4[data-state=checked]{--tw-translate-x: 1rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[state\\=unchecked\\]\\:translate-x-0[data-state=unchecked]{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[state\\=checked\\]\\:bg-primary[data-state=checked]{background-color:hsl(var(--opencx-primary))}.data-\\[state\\=open\\]\\:bg-accent[data-state=open]{background-color:hsl(var(--opencx-accent))}.data-\\[state\\=unchecked\\]\\:bg-input[data-state=unchecked]{background-color:hsl(var(--opencx-input))}.data-\\[state\\=open\\]\\:text-muted-foreground[data-state=open]{color:hsl(var(--opencx-muted-foreground))}.data-\\[disabled\\]\\:opacity-50[data-disabled]{opacity:.5}.data-\\[state\\=open\\]\\:animate-in[data-state=open]{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.data-\\[state\\=closed\\]\\:animate-out[data-state=closed]{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}.data-\\[state\\=closed\\]\\:fade-out-0[data-state=closed]{--tw-exit-opacity: 0}.data-\\[state\\=open\\]\\:fade-in-0[data-state=open]{--tw-enter-opacity: 0}.data-\\[state\\=closed\\]\\:zoom-out-95[data-state=closed]{--tw-exit-scale: .95}.data-\\[state\\=open\\]\\:zoom-in-95[data-state=open]{--tw-enter-scale: .95}.data-\\[side\\=bottom\\]\\:slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y: -.5rem}.data-\\[side\\=left\\]\\:slide-in-from-right-2[data-side=left]{--tw-enter-translate-x: .5rem}.data-\\[side\\=right\\]\\:slide-in-from-left-2[data-side=right]{--tw-enter-translate-x: -.5rem}.data-\\[side\\=top\\]\\:slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y: .5rem}.data-\\[state\\=closed\\]\\:slide-out-to-left-1\\/2[data-state=closed]{--tw-exit-translate-x: -50%}.data-\\[state\\=closed\\]\\:slide-out-to-top-\\[48\\%\\][data-state=closed]{--tw-exit-translate-y: -48%}.data-\\[state\\=open\\]\\:slide-in-from-left-1\\/2[data-state=open]{--tw-enter-translate-x: -50%}.data-\\[state\\=open\\]\\:slide-in-from-top-\\[48\\%\\][data-state=open]{--tw-enter-translate-y: -48%}.prose-a\\:underline :is(:where(a):not(:where([class~=not-prose],[class~=not-prose] *))){text-decoration-line:underline}.prose-a\\:decoration-primary :is(:where(a):not(:where([class~=not-prose],[class~=not-prose] *))){text-decoration-color:hsl(var(--opencx-primary))}@media (min-width: 640px){.sm\\:flex-row{flex-direction:row}.sm\\:justify-end{justify-content:flex-end}.sm\\:space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.sm\\:rounded-lg{border-radius:.5rem}.sm\\:text-left{text-align:left}}.rtl\\:-scale-100:where([dir=rtl],[dir=rtl] *){--tw-scale-x: -1;--tw-scale-y: -1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rtl\\:flex-row-reverse:where([dir=rtl],[dir=rtl] *){flex-direction:row-reverse}.rtl\\:text-right:where([dir=rtl],[dir=rtl] *){text-align:right}.rtl\\:placeholder\\:text-right:where([dir=rtl],[dir=rtl] *)::placeholder{text-align:right}.\\[\\&_span\\]\\:size-1 span{width:.25rem;height:.25rem}.\\[\\&_span\\]\\:bg-secondary-foreground span{background-color:hsl(var(--opencx-secondary-foreground))}.\\[\\&_svg\\]\\:pointer-events-none svg{pointer-events:none}.\\[\\&_svg\\]\\:size-4 svg{width:1rem;height:1rem}.\\[\\&_svg\\]\\:shrink-0 svg{flex-shrink:0}.\\[\\&_svg\\]\\:text-muted-foreground\\/70 svg{color:hsl(var(--opencx-muted-foreground) / .7)}.\\[\\&_svg\\]\\:hover\\:text-primary:hover svg{color:hsl(var(--opencx-primary))}',$1=sn.Provider,J1=sn.Root,Z1=sn.Trigger,qo=ye.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(sn.Content,{ref:r,sideOffset:t,className:q("z-50 overflow-hidden max-w-xs rounded-xl bg-primary border text-primary-foreground p-2 text-center align-middle text-xs animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));qo.displayName=sn.Content.displayName;function an({children:e,content:t,side:n,align:r}){return t?f.jsxs(J1,{children:[f.jsx(Z1,{asChild:!0,children:e}),f.jsx(qo,{side:n,align:r,collisionPadding:8,avoidCollisions:!0,children:t})]}):e}const Ra=450;function Mt(){const[e,t]=X.useState(()=>(window.top||window).innerWidth<Ra);return X.useEffect(()=>{const n=window.top||window,r=()=>{t(n.innerWidth<Ra)};return r(),n.addEventListener("resize",r),()=>{n.removeEventListener("resize",r)}},[]),{isSmallScreen:e}}function fn(){var s,u,l,c,d,h,g,p,E,y,k,_,S,L,M,F,I,j,U,z,C,H,P,te,ne,K,ce,fe,Ee,Te,x,de,ve;const{isSmallScreen:e}=Mt(),{theme:t}=W.useConfig(),n=(w,Le)=>e?`100dv${w}`:Le,r={zIndex:((s=t==null?void 0:t.widgetTrigger)==null?void 0:s.zIndex)??1e7,offset:{bottom:((l=(u=t==null?void 0:t.widgetTrigger)==null?void 0:u.offset)==null?void 0:l.bottom)??20,right:((d=(c=t==null?void 0:t.widgetTrigger)==null?void 0:c.offset)==null?void 0:d.right)??20},size:{button:((g=(h=t==null?void 0:t.widgetTrigger)==null?void 0:h.size)==null?void 0:g.button)??48,icon:((E=(p=t==null?void 0:t.widgetTrigger)==null?void 0:p.size)==null?void 0:E.icon)??24}},i={palette:(t==null?void 0:t.palette)??"stone",primaryColor:(t==null?void 0:t.primaryColor)??"hsl(0 0% 9%)",widgetTrigger:r,widgetContentContainer:{borderRadius:e?"0px":((y=t==null?void 0:t.widgetContentContainer)==null?void 0:y.borderRadius)??"32px",zIndex:((k=t==null?void 0:t.widgetContentContainer)==null?void 0:k.zIndex)??r.zIndex+1,outline:((_=t==null?void 0:t.widgetContentContainer)==null?void 0:_.outline)??"none",outlineColor:((S=t==null?void 0:t.widgetContentContainer)==null?void 0:S.outlineColor)??"hsl(0 0% 50% / .5)",boxShadow:((L=t==null?void 0:t.widgetContentContainer)==null?void 0:L.boxShadow)??"0 25px 50px -12px rgb(0 0 0 / 0.25)",transitionProperty:((M=t==null?void 0:t.widgetContentContainer)==null?void 0:M.transitionProperty)??"all",transitionTimingFunction:((F=t==null?void 0:t.widgetContentContainer)==null?void 0:F.transitionTimingFunction)??"cubic-bezier(0.16, 1, 0.3, 1)",transitionDuration:((I=t==null?void 0:t.widgetContentContainer)==null?void 0:I.transitionDuration)??"800ms",offset:{side:e?0:r.offset.bottom+r.size.button+Nt.y*2+(((U=(j=t==null?void 0:t.widgetContentContainer)==null?void 0:j.offset)==null?void 0:U.side)??10),align:e?0:r.offset.right+(((C=(z=t==null?void 0:t.widgetContentContainer)==null?void 0:z.offset)==null?void 0:C.align)??0)}},screens:{welcome:{width:n("w",((P=(H=t==null?void 0:t.screens)==null?void 0:H.welcome)==null?void 0:P.width)??"375px"),minHeight:n("h",((ne=(te=t==null?void 0:t.screens)==null?void 0:te.welcome)==null?void 0:ne.minHeight)??"200px")},sessions:{width:n("w",((ce=(K=t==null?void 0:t.screens)==null?void 0:K.sessions)==null?void 0:ce.width)??"450px"),height:n("h",((Ee=(fe=t==null?void 0:t.screens)==null?void 0:fe.sessions)==null?void 0:Ee.height)??"600px")},chat:{width:n("w",((x=(Te=t==null?void 0:t.screens)==null?void 0:Te.chat)==null?void 0:x.width)??"525px"),height:n("h",((ve=(de=t==null?void 0:t.screens)==null?void 0:de.chat)==null?void 0:ve.height)??"700px")}}},a={maxHeight:n("h",`calc(
|
|
29
|
+
`,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const ht={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/"},Vs={}.hasOwnProperty,Zf=Object.prototype;function ep(e,t){const n=t||{};return Gr({file:n.file||void 0,location:!1,schema:n.space==="svg"?ot:ln,verbose:n.verbose||!1},e)}function Gr(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},yn(e,r,n),n}case"#document":case"#document-fragment":{const r=t,i="mode"in r?r.mode==="quirks"||r.mode==="limited-quirks":!1;if(n={type:"root",children:Gs(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){const a=String(e.file),s=Jf(a),u=s.toPoint(0),l=s.toPoint(a.length);n.position={start:u,end:l}}return n}case"#documentType":{const r=t;return n={type:"doctype"},yn(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},yn(e,r,n),n}default:return n=tp(e,t),n}}function Gs(e,t){let n=-1;const r=[];for(;++n<t.length;){const i=Gr(e,t[n]);r.push(i)}return r}function tp(e,t){const n=e.schema;e.schema=t.namespaceURI===ht.svg?ot:ln;let r=-1;const i={};for(;++r<t.attrs.length;){const u=t.attrs[r],l=(u.prefix?u.prefix+":":"")+u.name;Vs.call(Zf,l)||(i[l]=u.value)}const s=(e.schema.space==="svg"?$f:Kf)(t.tagName,i,Gs(e,t.childNodes));if(yn(e,t,s),s.tagName==="template"){const u=t,l=u.sourceCodeLocation,c=l&&l.startTag&&yt(l.startTag),d=l&&l.endTag&&yt(l.endTag),h=Gr(e,u.content);c&&d&&e.file&&(h.position={start:c.end,end:d.start}),s.content=h}return e.schema=n,s}function yn(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=np(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function np(e,t,n){const r=yt(n);if(t.type==="element"){const i=t.children[t.children.length-1];if(r&&!n.endTag&&i&&i.position&&i.position.end&&(r.end=Object.assign({},i.position.end)),e.verbose){const a={};let s;if(n.attrs)for(s in n.attrs)Vs.call(n.attrs,s)&&(a[Hn(e.schema,s).property]=yt(n.attrs[s]));n.startTag;const u=yt(n.startTag),l=n.endTag?yt(n.endTag):void 0,c={opening:u};l&&(c.closing=l),c.properties=a,t.data={position:c}}}return r}function yt(e){const t=pa({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=pa({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function pa(e){return e.line&&e.column?e:void 0}const rp={},ip={}.hasOwnProperty,Qs=Ua("type",{handlers:{root:sp,element:dp,text:lp,comment:cp,doctype:up}});function ap(e,t){const r=(t||rp).space;return Qs(e,r==="svg"?ot:ln)}function sp(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=Qr(e.children,n,t),Rt(e,n),n}function op(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=Qr(e.children,n,t),Rt(e,n),n}function up(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return Rt(e,t),t}function lp(e){const t={nodeName:"#text",value:e.value,parentNode:null};return Rt(e,t),t}function cp(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return Rt(e,t),t}function dp(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=ot);const i=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&ip.call(e.properties,a)){const l=hp(r,a,e.properties[a]);l&&i.push(l)}}const s=r.space,u={nodeName:e.tagName,tagName:e.tagName,attrs:i,namespaceURI:ht[s],childNodes:[],parentNode:null};return u.childNodes=Qr(e.children,u,r),Rt(e,u),e.tagName==="template"&&e.content&&(u.content=op(e.content,r)),u}function hp(e,t,n){const r=Hn(e,t);if(n===!1||n===null||n===void 0||typeof n=="number"&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?bs(n):ks(n));const i={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=i.name.indexOf(":");a<0?i.prefix="":(i.name=i.name.slice(a+1),i.prefix=r.attribute.slice(0,a)),i.namespace=ht[r.space]}return i}function Qr(e,t,n){let r=-1;const i=[];if(e)for(;++r<e.length;){const a=Qs(e[r],n);a.parentNode=t,i.push(a)}return i}function Rt(e,t){const n=e.position;n&&n.start&&n.end&&(n.start.offset,n.end.offset,t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}const fp=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],pp=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]),he="�";var m;(function(e){e[e.EOF=-1]="EOF",e[e.NULL=0]="NULL",e[e.TABULATION=9]="TABULATION",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.LINE_FEED=10]="LINE_FEED",e[e.FORM_FEED=12]="FORM_FEED",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_0=48]="DIGIT_0",e[e.DIGIT_9=57]="DIGIT_9",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",e[e.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_A=97]="LATIN_SMALL_A",e[e.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(m||(m={}));const Ie={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function Xs(e){return e>=55296&&e<=57343}function mp(e){return e>=56320&&e<=57343}function gp(e,t){return(e-55296)*1024+9216+t}function Ks(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function $s(e){return e>=64976&&e<=65007||pp.has(e)}var N;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(N||(N={}));const bp=65536;class Ep{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=bp,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t,n){const{line:r,col:i,offset:a}=this,s=i+n,u=a+n;return{code:t,startLine:r,endLine:r,startCol:s,endCol:s,startOffset:u,endOffset:u}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(mp(n))return this.pos++,this._addGap(),gp(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,m.EOF;return this._err(N.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r<t.length;r++)if((this.html.charCodeAt(this.pos+r)|32)!==t.charCodeAt(r))return!1;return!0}peek(t){const n=this.pos+t;if(n>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,m.EOF;const r=this.html.charCodeAt(n);return r===m.CARRIAGE_RETURN?m.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,m.EOF;let t=this.html.charCodeAt(this.pos);return t===m.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,m.LINE_FEED):t===m.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,Xs(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===m.LINE_FEED||t===m.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){Ks(t)?this._err(N.controlCharacterInInputStream):$s(t)&&this._err(N.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var $;(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"})($||($={}));function Js(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 Zs=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏઑඡ༉༦ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲϏϢϸontourIntegraìȹoɴ\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲy;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱còJTabcdfgorstרׯؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ߂ߐĀiyޱrc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣসে্ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४ĀnrࢃgleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpwਖਛgȀLRlr৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼અઋp;椅y;䐜Ādl੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑඞcy;䐊cute;䅃ƀaeyહાron;䅇dil;䅅;䐝ƀgswે૰ativeƀMTV૨ediumSpace;怋hiĀcn૦ëeryThiîtedĀGLଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷreak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪௫ఄ಄ದൡඅ櫬Āoungruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater;EFGLSTஶஷ扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨setĀ;Eೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂෛ෧ขภยา฿ไlig;䅒cute耻Ó䃓Āiyීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲcr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬืde耻Õ䃕es;樷ml耻Ö䃖erĀBP๋Āar๐๓r;怾acĀek๚;揞et;掴arenthesis;揜ҀacfhilorsງຊຏຒດຝະrtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ檻cedesȀ;EST່້扺qual;檯lantEqual;扼ilde;找me;怳Ādpuct;戏ortionĀ;aȥl;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL憒ar;懥eftArrow;懄eiling;按oǵ\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄቕቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHcቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗ĀeiቻDzኀ\0ኇefore;戴a;䎘ĀcnኘkSpace;쀀 Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtèa;䎖r;愨pf;愤cr;쀀𝒵ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒;Eaeiopᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;eᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;eᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰᝃᝈ០៦ᠹᡐᜍ᥈ᥰot;櫭ĀcrᛶkȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;tbrk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯᝳ;䎲;愶een;扬r;쀀𝔟gcostuvwឍឝឳេ៕៛ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀakoᠦᠵĀcn៲ᠣkƀlst֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ;敛;敘;攘;攔;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģbar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;elƀ;bhᥨᥩᥫ䁜;槅sub;柈ŬᥴlĀ;e怢t»pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭒\0᯽\0ᰌƀcprᦲute;䄇̀;abcdsᦿᧀᧄ᧕᧙戩nd;橄rcup;橉Āau᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r;Ecefms᩠ᩢᩫ᪤᪪旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ\0\0aĀ;t䀬;䁀ƀ;fl戁îᅠeĀmxent»eóɍǧ\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯delprvw᭠᭬᭷ᮂᮬᯔarrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;pᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰻᰿ᱝᱩᱵᲞᲬᲷᴍᵻᶑᶫᶻ᷆᷍ròar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂᳖᳜᳠mƀ;oș᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄĀDoḆᴴoôĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»ṺƀaeiἒἚls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧\0耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₥₰₴⃰℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽ƀ;qsؾٌlanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqrⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0proør;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼ròòΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonóquigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roøurĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨íistĀ;sடr;쀀𝔫ȀEest⩦⩹⩼ƀ;qs⩭ƀ;qs⩴lanôií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast⭕⭚⭟lleìl;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖchimpqu⮽⯍⯙⬄⯤⯯Ȁ;cerല⯆ഷ⯉uå;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭ååഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñĀ;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;cⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācrir;榿;쀀𝔬ͯ\0\0\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕⶥⶨrò᪀Āirⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔǒr;榷rp;榹;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ\0\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ脀¶;l䂶leìЃɩ\0\0m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳ᤈ⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t⾴ïrel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⋢⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔ABHabcdefhilmnoprstuxけさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstwガクシスゼゾダッデナp;極Ā;fゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ìâヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘rrowĀ;tㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowóarpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓ròaòՑ;怏oustĀ;a㈞掱che»mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì耻䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;qኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫwar;椪lig耻ß䃟㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rëƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproøim»ኬsðኞĀas㚺㚮ðrn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈadempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xôheadĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roðtré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜtré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),Tp=new Uint16Array("Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map(e=>e.charCodeAt(0)));var lr;const xp=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]]),wp=(lr=String.fromCodePoint)!==null&&lr!==void 0?lr:function(e){let t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|e&1023),t+=String.fromCharCode(e),t};function yp(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=xp.get(e))!==null&&t!==void 0?t:e}var we;(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"})(we||(we={}));const _p=32;var at;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(at||(at={}));function Cr(e){return e>=we.ZERO&&e<=we.NINE}function Ap(e){return e>=we.UPPER_A&&e<=we.UPPER_F||e>=we.LOWER_A&&e<=we.LOWER_F}function Cp(e){return e>=we.UPPER_A&&e<=we.UPPER_Z||e>=we.LOWER_A&&e<=we.LOWER_Z||Cr(e)}function kp(e){return e===we.EQUALS||Cp(e)}var xe;(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"})(xe||(xe={}));var Ke;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Ke||(Ke={}));class eo{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=xe.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Ke.Strict}startEntity(t){this.decodeMode=t,this.state=xe.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case xe.EntityStart:return t.charCodeAt(n)===we.NUM?(this.state=xe.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=xe.NamedEntity,this.stateNamedEntity(t,n));case xe.NumericStart:return this.stateNumericStart(t,n);case xe.NumericDecimal:return this.stateNumericDecimal(t,n);case xe.NumericHex:return this.stateNumericHex(t,n);case xe.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|_p)===we.LOWER_X?(this.state=xe.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=xe.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,i){if(n!==r){const a=r-n;this.result=this.result*Math.pow(i,a)+parseInt(t.substr(n,a),i),this.consumed+=a}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(Cr(i)||Ap(i))n+=1;else return this.addToNumericResult(t,r,n,16),this.emitNumericEntity(i,3)}return this.addToNumericResult(t,r,n,16),-1}stateNumericDecimal(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(Cr(i))n+=1;else return this.addToNumericResult(t,r,n,10),this.emitNumericEntity(i,2)}return this.addToNumericResult(t,r,n,10),-1}emitNumericEntity(t,n){var r;if(this.consumed<=n)return(r=this.errors)===null||r===void 0||r.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===we.SEMI)this.consumed+=1;else if(this.decodeMode===Ke.Strict)return 0;return this.emitCodePoint(yp(this.result),this.consumed),this.errors&&(t!==we.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let i=r[this.treeIndex],a=(i&at.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const s=t.charCodeAt(n);if(this.treeIndex=Np(r,i,this.treeIndex+Math.max(1,a),s),this.treeIndex<0)return this.result===0||this.decodeMode===Ke.Attribute&&(a===0||kp(s))?0:this.emitNotTerminatedNamedEntity();if(i=r[this.treeIndex],a=(i&at.VALUE_LENGTH)>>14,a!==0){if(s===we.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==Ke.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,i=(r[n]&at.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,i,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:i}=this;return this.emitCodePoint(n===1?i[t]&~at.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case xe.NamedEntity:return this.result!==0&&(this.decodeMode!==Ke.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case xe.NumericDecimal:return this.emitNumericEntity(0,2);case xe.NumericHex:return this.emitNumericEntity(0,3);case xe.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case xe.EntityStart:return 0}}}function to(e){let t="";const n=new eo(e,r=>t+=wp(r));return function(i,a){let s=0,u=0;for(;(u=i.indexOf("&",u))>=0;){t+=i.slice(s,u),n.startEntity(a);const c=n.write(i,u+1);if(c<0){s=u+n.end();break}s=u+c,u=c===0?s+1:s}const l=t+i.slice(s);return t="",l}}function Np(e,t,n,r){const i=(t&at.BRANCH_LENGTH)>>7,a=t&at.JUMP_TABLE;if(i===0)return a!==0&&r===a?n:-1;if(a){const l=r-a;return l<0||l>=i?-1:e[n+l]-1}let s=n,u=s+i-1;for(;s<=u;){const l=s+u>>>1,c=e[l];if(c<r)s=l+1;else if(c>r)u=l-1;else return e[l+i]}return-1}to(Zs);to(Tp);var R;(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/"})(R||(R={}));var ft;(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"})(ft||(ft={}));var Me;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Me||(Me={}));var A;(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"})(A||(A={}));var o;(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"})(o||(o={}));const Ip=new Map([[A.A,o.A],[A.ADDRESS,o.ADDRESS],[A.ANNOTATION_XML,o.ANNOTATION_XML],[A.APPLET,o.APPLET],[A.AREA,o.AREA],[A.ARTICLE,o.ARTICLE],[A.ASIDE,o.ASIDE],[A.B,o.B],[A.BASE,o.BASE],[A.BASEFONT,o.BASEFONT],[A.BGSOUND,o.BGSOUND],[A.BIG,o.BIG],[A.BLOCKQUOTE,o.BLOCKQUOTE],[A.BODY,o.BODY],[A.BR,o.BR],[A.BUTTON,o.BUTTON],[A.CAPTION,o.CAPTION],[A.CENTER,o.CENTER],[A.CODE,o.CODE],[A.COL,o.COL],[A.COLGROUP,o.COLGROUP],[A.DD,o.DD],[A.DESC,o.DESC],[A.DETAILS,o.DETAILS],[A.DIALOG,o.DIALOG],[A.DIR,o.DIR],[A.DIV,o.DIV],[A.DL,o.DL],[A.DT,o.DT],[A.EM,o.EM],[A.EMBED,o.EMBED],[A.FIELDSET,o.FIELDSET],[A.FIGCAPTION,o.FIGCAPTION],[A.FIGURE,o.FIGURE],[A.FONT,o.FONT],[A.FOOTER,o.FOOTER],[A.FOREIGN_OBJECT,o.FOREIGN_OBJECT],[A.FORM,o.FORM],[A.FRAME,o.FRAME],[A.FRAMESET,o.FRAMESET],[A.H1,o.H1],[A.H2,o.H2],[A.H3,o.H3],[A.H4,o.H4],[A.H5,o.H5],[A.H6,o.H6],[A.HEAD,o.HEAD],[A.HEADER,o.HEADER],[A.HGROUP,o.HGROUP],[A.HR,o.HR],[A.HTML,o.HTML],[A.I,o.I],[A.IMG,o.IMG],[A.IMAGE,o.IMAGE],[A.INPUT,o.INPUT],[A.IFRAME,o.IFRAME],[A.KEYGEN,o.KEYGEN],[A.LABEL,o.LABEL],[A.LI,o.LI],[A.LINK,o.LINK],[A.LISTING,o.LISTING],[A.MAIN,o.MAIN],[A.MALIGNMARK,o.MALIGNMARK],[A.MARQUEE,o.MARQUEE],[A.MATH,o.MATH],[A.MENU,o.MENU],[A.META,o.META],[A.MGLYPH,o.MGLYPH],[A.MI,o.MI],[A.MO,o.MO],[A.MN,o.MN],[A.MS,o.MS],[A.MTEXT,o.MTEXT],[A.NAV,o.NAV],[A.NOBR,o.NOBR],[A.NOFRAMES,o.NOFRAMES],[A.NOEMBED,o.NOEMBED],[A.NOSCRIPT,o.NOSCRIPT],[A.OBJECT,o.OBJECT],[A.OL,o.OL],[A.OPTGROUP,o.OPTGROUP],[A.OPTION,o.OPTION],[A.P,o.P],[A.PARAM,o.PARAM],[A.PLAINTEXT,o.PLAINTEXT],[A.PRE,o.PRE],[A.RB,o.RB],[A.RP,o.RP],[A.RT,o.RT],[A.RTC,o.RTC],[A.RUBY,o.RUBY],[A.S,o.S],[A.SCRIPT,o.SCRIPT],[A.SEARCH,o.SEARCH],[A.SECTION,o.SECTION],[A.SELECT,o.SELECT],[A.SOURCE,o.SOURCE],[A.SMALL,o.SMALL],[A.SPAN,o.SPAN],[A.STRIKE,o.STRIKE],[A.STRONG,o.STRONG],[A.STYLE,o.STYLE],[A.SUB,o.SUB],[A.SUMMARY,o.SUMMARY],[A.SUP,o.SUP],[A.TABLE,o.TABLE],[A.TBODY,o.TBODY],[A.TEMPLATE,o.TEMPLATE],[A.TEXTAREA,o.TEXTAREA],[A.TFOOT,o.TFOOT],[A.TD,o.TD],[A.TH,o.TH],[A.THEAD,o.THEAD],[A.TITLE,o.TITLE],[A.TR,o.TR],[A.TRACK,o.TRACK],[A.TT,o.TT],[A.U,o.U],[A.UL,o.UL],[A.SVG,o.SVG],[A.VAR,o.VAR],[A.WBR,o.WBR],[A.XMP,o.XMP]]);function Dt(e){var t;return(t=Ip.get(e))!==null&&t!==void 0?t:o.UNKNOWN}const D=o,Sp={[R.HTML]:new Set([D.ADDRESS,D.APPLET,D.AREA,D.ARTICLE,D.ASIDE,D.BASE,D.BASEFONT,D.BGSOUND,D.BLOCKQUOTE,D.BODY,D.BR,D.BUTTON,D.CAPTION,D.CENTER,D.COL,D.COLGROUP,D.DD,D.DETAILS,D.DIR,D.DIV,D.DL,D.DT,D.EMBED,D.FIELDSET,D.FIGCAPTION,D.FIGURE,D.FOOTER,D.FORM,D.FRAME,D.FRAMESET,D.H1,D.H2,D.H3,D.H4,D.H5,D.H6,D.HEAD,D.HEADER,D.HGROUP,D.HR,D.HTML,D.IFRAME,D.IMG,D.INPUT,D.LI,D.LINK,D.LISTING,D.MAIN,D.MARQUEE,D.MENU,D.META,D.NAV,D.NOEMBED,D.NOFRAMES,D.NOSCRIPT,D.OBJECT,D.OL,D.P,D.PARAM,D.PLAINTEXT,D.PRE,D.SCRIPT,D.SECTION,D.SELECT,D.SOURCE,D.STYLE,D.SUMMARY,D.TABLE,D.TBODY,D.TD,D.TEMPLATE,D.TEXTAREA,D.TFOOT,D.TH,D.THEAD,D.TITLE,D.TR,D.TRACK,D.UL,D.WBR,D.XMP]),[R.MATHML]:new Set([D.MI,D.MO,D.MN,D.MS,D.MTEXT,D.ANNOTATION_XML]),[R.SVG]:new Set([D.TITLE,D.FOREIGN_OBJECT,D.DESC]),[R.XLINK]:new Set,[R.XML]:new Set,[R.XMLNS]:new Set},kr=new Set([D.H1,D.H2,D.H3,D.H4,D.H5,D.H6]);A.STYLE,A.SCRIPT,A.XMP,A.IFRAME,A.NOEMBED,A.NOFRAMES,A.PLAINTEXT;var b;(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"})(b||(b={}));const pe={DATA:b.DATA,RCDATA:b.RCDATA,RAWTEXT:b.RAWTEXT,SCRIPT_DATA:b.SCRIPT_DATA,PLAINTEXT:b.PLAINTEXT,CDATA_SECTION:b.CDATA_SECTION};function Op(e){return e>=m.DIGIT_0&&e<=m.DIGIT_9}function Gt(e){return e>=m.LATIN_CAPITAL_A&&e<=m.LATIN_CAPITAL_Z}function Lp(e){return e>=m.LATIN_SMALL_A&&e<=m.LATIN_SMALL_Z}function rt(e){return Lp(e)||Gt(e)}function ma(e){return rt(e)||Op(e)}function Tn(e){return e+32}function no(e){return e===m.SPACE||e===m.LINE_FEED||e===m.TABULATION||e===m.FORM_FEED}function ga(e){return no(e)||e===m.SOLIDUS||e===m.GREATER_THAN_SIGN}function Rp(e){return e===m.NULL?N.nullCharacterReference:e>1114111?N.characterReferenceOutsideUnicodeRange:Xs(e)?N.surrogateCharacterReference:$s(e)?N.noncharacterCharacterReference:Ks(e)||e===m.CARRIAGE_RETURN?N.controlCharacterReference:null}class Dp{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=b.DATA,this.returnState=b.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new Ep(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new eo(Zs,(r,i)=>{this.preprocessor.pos=this.entityStartPos+i-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(N.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(N.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const i=Rp(r);i&&this._err(i,1)}}:void 0)}_err(t,n=0){var r,i;(i=(r=this.handler).onParseError)===null||i===void 0||i.call(r,this.preprocessor.getError(t,n))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t==null||t())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r==null||r()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n<t;n++)this.preprocessor.advance()}_consumeSequenceIfMatch(t,n){return this.preprocessor.startsWith(t,n)?(this._advanceBy(t.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:$.START_TAG,tagName:"",tagID:o.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:$.END_TAG,tagName:"",tagID:o.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:$.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:$.DOCTYPE,name:t,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n,location:this.currentLocation}}_createAttr(t){this.currentAttr={name:t,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var t,n;const r=this.currentToken;if(Js(r,this.currentAttr.name)===null){if(r.attrs.push(this.currentAttr),r.location&&this.currentLocation){const i=(t=(n=r.location).attrs)!==null&&t!==void 0?t:n.attrs=Object.create(null);i[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(N.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=Dt(t.tagName),t.type===$.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(N.endTagWithAttributes),t.selfClosing&&this._err(N.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case $.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case $.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case $.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:$.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type===t){this.currentCharacterToken.chars+=n;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(t,n)}_emitCodePoint(t){const n=no(t)?$.WHITESPACE_CHARACTER:t===m.NULL?$.NULL_CHARACTER:$.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken($.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=b.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?Ke.Attribute:Ke.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===b.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===b.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===b.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case b.DATA:{this._stateData(t);break}case b.RCDATA:{this._stateRcdata(t);break}case b.RAWTEXT:{this._stateRawtext(t);break}case b.SCRIPT_DATA:{this._stateScriptData(t);break}case b.PLAINTEXT:{this._statePlaintext(t);break}case b.TAG_OPEN:{this._stateTagOpen(t);break}case b.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case b.TAG_NAME:{this._stateTagName(t);break}case b.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case b.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case b.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case b.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case b.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case b.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case b.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case b.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case b.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case b.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case b.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case b.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case b.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case b.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case b.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case b.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case b.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case b.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case b.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case b.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case b.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case b.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case b.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case b.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case b.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case b.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case b.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case b.BOGUS_COMMENT:{this._stateBogusComment(t);break}case b.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case b.COMMENT_START:{this._stateCommentStart(t);break}case b.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case b.COMMENT:{this._stateComment(t);break}case b.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case b.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case b.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case b.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case b.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case b.COMMENT_END:{this._stateCommentEnd(t);break}case b.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case b.DOCTYPE:{this._stateDoctype(t);break}case b.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case b.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case b.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case b.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case b.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case b.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case b.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case b.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case b.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case b.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case b.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case b.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case b.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case b.CDATA_SECTION:{this._stateCdataSection(t);break}case b.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case b.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case b.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case b.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case m.LESS_THAN_SIGN:{this.state=b.TAG_OPEN;break}case m.AMPERSAND:{this._startCharacterReference();break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitCodePoint(t);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case m.AMPERSAND:{this._startCharacterReference();break}case m.LESS_THAN_SIGN:{this.state=b.RCDATA_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case m.LESS_THAN_SIGN:{this.state=b.RAWTEXT_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(rt(t))this._createStartTagToken(),this.state=b.TAG_NAME,this._stateTagName(t);else switch(t){case m.EXCLAMATION_MARK:{this.state=b.MARKUP_DECLARATION_OPEN;break}case m.SOLIDUS:{this.state=b.END_TAG_OPEN;break}case m.QUESTION_MARK:{this._err(N.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=b.BOGUS_COMMENT,this._stateBogusComment(t);break}case m.EOF:{this._err(N.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(N.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=b.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(rt(t))this._createEndTagToken(),this.state=b.TAG_NAME,this._stateTagName(t);else switch(t){case m.GREATER_THAN_SIGN:{this._err(N.missingEndTagName),this.state=b.DATA;break}case m.EOF:{this._err(N.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(N.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=b.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BEFORE_ATTRIBUTE_NAME;break}case m.SOLIDUS:{this.state=b.SELF_CLOSING_START_TAG;break}case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentTagToken();break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.tagName+=he;break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(Gt(t)?Tn(t):t)}}_stateRcdataLessThanSign(t){t===m.SOLIDUS?this.state=b.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=b.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){rt(t)?(this.state=b.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=b.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=b.BEFORE_ATTRIBUTE_NAME,!1;case m.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=b.SELF_CLOSING_START_TAG,!1;case m.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=b.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=b.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===m.SOLIDUS?this.state=b.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=b.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){rt(t)?(this.state=b.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=b.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=b.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case m.SOLIDUS:{this.state=b.SCRIPT_DATA_END_TAG_OPEN;break}case m.EXCLAMATION_MARK:{this.state=b.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=b.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){rt(t)?(this.state=b.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=b.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=b.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===m.HYPHEN_MINUS?(this.state=b.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=b.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===m.HYPHEN_MINUS?(this.state=b.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=b.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.state=b.SCRIPT_DATA_ESCAPED,this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=b.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case m.HYPHEN_MINUS:{this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case m.GREATER_THAN_SIGN:{this.state=b.SCRIPT_DATA,this._emitChars(">");break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.state=b.SCRIPT_DATA_ESCAPED,this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=b.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===m.SOLIDUS?this.state=b.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:rt(t)?(this._emitChars("<"),this.state=b.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=b.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){rt(t)?(this.state=b.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=b.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=b.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(Ie.SCRIPT,!1)&&ga(this.preprocessor.peek(Ie.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Ie.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=b.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case m.NULL:{this._err(N.unexpectedNullCharacter),this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case m.HYPHEN_MINUS:{this._emitChars("-");break}case m.LESS_THAN_SIGN:{this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case m.GREATER_THAN_SIGN:{this.state=b.SCRIPT_DATA,this._emitChars(">");break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(he);break}case m.EOF:{this._err(N.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===m.SOLIDUS?(this.state=b.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(Ie.SCRIPT,!1)&&ga(this.preprocessor.peek(Ie.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Ie.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=b.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=b.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.SOLIDUS:case m.GREATER_THAN_SIGN:case m.EOF:{this.state=b.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case m.EQUALS_SIGN:{this._err(N.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=b.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=b.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:case m.SOLIDUS:case m.GREATER_THAN_SIGN:case m.EOF:{this._leaveAttrName(),this.state=b.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case m.EQUALS_SIGN:{this._leaveAttrName(),this.state=b.BEFORE_ATTRIBUTE_VALUE;break}case m.QUOTATION_MARK:case m.APOSTROPHE:case m.LESS_THAN_SIGN:{this._err(N.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.name+=he;break}default:this.currentAttr.name+=String.fromCodePoint(Gt(t)?Tn(t):t)}}_stateAfterAttributeName(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.SOLIDUS:{this.state=b.SELF_CLOSING_START_TAG;break}case m.EQUALS_SIGN:{this.state=b.BEFORE_ATTRIBUTE_VALUE;break}case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentTagToken();break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=b.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:{this.state=b.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case m.APOSTROPHE:{this.state=b.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingAttributeValue),this.state=b.DATA,this.emitCurrentTagToken();break}default:this.state=b.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case m.QUOTATION_MARK:{this.state=b.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case m.AMPERSAND:{this._startCharacterReference();break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=he;break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case m.APOSTROPHE:{this.state=b.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case m.AMPERSAND:{this._startCharacterReference();break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=he;break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this._leaveAttrValue(),this.state=b.BEFORE_ATTRIBUTE_NAME;break}case m.AMPERSAND:{this._startCharacterReference();break}case m.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=b.DATA,this.emitCurrentTagToken();break}case m.NULL:{this._err(N.unexpectedNullCharacter),this.currentAttr.value+=he;break}case m.QUOTATION_MARK:case m.APOSTROPHE:case m.LESS_THAN_SIGN:case m.EQUALS_SIGN:case m.GRAVE_ACCENT:{this._err(N.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this._leaveAttrValue(),this.state=b.BEFORE_ATTRIBUTE_NAME;break}case m.SOLIDUS:{this._leaveAttrValue(),this.state=b.SELF_CLOSING_START_TAG;break}case m.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=b.DATA,this.emitCurrentTagToken();break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._err(N.missingWhitespaceBetweenAttributes),this.state=b.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case m.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=b.DATA,this.emitCurrentTagToken();break}case m.EOF:{this._err(N.eofInTag),this._emitEOFToken();break}default:this._err(N.unexpectedSolidusInTag),this.state=b.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentComment(n);break}case m.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.data+=he;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(Ie.DASH_DASH,!0)?(this._createCommentToken(Ie.DASH_DASH.length+1),this.state=b.COMMENT_START):this._consumeSequenceIfMatch(Ie.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(Ie.DOCTYPE.length+1),this.state=b.DOCTYPE):this._consumeSequenceIfMatch(Ie.CDATA_START,!0)?this.inForeignNode?this.state=b.CDATA_SECTION:(this._err(N.cdataInHtmlContent),this._createCommentToken(Ie.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=b.BOGUS_COMMENT):this._ensureHibernation()||(this._err(N.incorrectlyOpenedComment),this._createCommentToken(2),this.state=b.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case m.HYPHEN_MINUS:{this.state=b.COMMENT_START_DASH;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptClosingOfEmptyComment),this.state=b.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=b.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case m.HYPHEN_MINUS:{this.state=b.COMMENT_END;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptClosingOfEmptyComment),this.state=b.DATA,this.emitCurrentComment(n);break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=b.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case m.HYPHEN_MINUS:{this.state=b.COMMENT_END_DASH;break}case m.LESS_THAN_SIGN:{n.data+="<",this.state=b.COMMENT_LESS_THAN_SIGN;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.data+=he;break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case m.EXCLAMATION_MARK:{n.data+="!",this.state=b.COMMENT_LESS_THAN_SIGN_BANG;break}case m.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=b.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===m.HYPHEN_MINUS?this.state=b.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=b.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===m.HYPHEN_MINUS?this.state=b.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=b.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==m.GREATER_THAN_SIGN&&t!==m.EOF&&this._err(N.nestedComment),this.state=b.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case m.HYPHEN_MINUS:{this.state=b.COMMENT_END;break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=b.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentComment(n);break}case m.EXCLAMATION_MARK:{this.state=b.COMMENT_END_BANG;break}case m.HYPHEN_MINUS:{n.data+="-";break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=b.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case m.HYPHEN_MINUS:{n.data+="--!",this.state=b.COMMENT_END_DASH;break}case m.GREATER_THAN_SIGN:{this._err(N.incorrectlyClosedComment),this.state=b.DATA,this.emitCurrentComment(n);break}case m.EOF:{this._err(N.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=b.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BEFORE_DOCTYPE_NAME;break}case m.GREATER_THAN_SIGN:{this.state=b.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case m.EOF:{this._err(N.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingWhitespaceBeforeDoctypeName),this.state=b.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(Gt(t))this._createDoctypeToken(String.fromCharCode(Tn(t))),this.state=b.DOCTYPE_NAME;else switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.NULL:{this._err(N.unexpectedNullCharacter),this._createDoctypeToken(he),this.state=b.DOCTYPE_NAME;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=b.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.AFTER_DOCTYPE_NAME;break}case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.name+=he;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(Gt(t)?Tn(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(Ie.PUBLIC,!1)?this.state=b.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(Ie.SYSTEM,!1)?this.state=b.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(N.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case m.QUOTATION_MARK:{this._err(N.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=b.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{this._err(N.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=b.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:{n.publicId="",this.state=b.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{n.publicId="",this.state=b.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case m.QUOTATION_MARK:{this.state=b.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.publicId+=he;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateDoctypePublicIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case m.APOSTROPHE:{this.state=b.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.publicId+=he;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateAfterDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case m.GREATER_THAN_SIGN:{this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.QUOTATION_MARK:{this._err(N.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{this._err(N.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.QUOTATION_MARK:{n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:{this.state=b.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case m.QUOTATION_MARK:{this._err(N.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{this._err(N.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.QUOTATION_MARK:{n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case m.APOSTROPHE:{n.systemId="",this.state=b.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case m.GREATER_THAN_SIGN:{this._err(N.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.DATA,this.emitCurrentDoctype(n);break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case m.QUOTATION_MARK:{this.state=b.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.systemId+=he;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateDoctypeSystemIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case m.APOSTROPHE:{this.state=b.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case m.NULL:{this._err(N.unexpectedNullCharacter),n.systemId+=he;break}case m.GREATER_THAN_SIGN:{this._err(N.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateAfterDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case m.SPACE:case m.LINE_FEED:case m.TABULATION:case m.FORM_FEED:break;case m.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.EOF:{this._err(N.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(N.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=b.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case m.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=b.DATA;break}case m.NULL:{this._err(N.unexpectedNullCharacter);break}case m.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case m.RIGHT_SQUARE_BRACKET:{this.state=b.CDATA_SECTION_BRACKET;break}case m.EOF:{this._err(N.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===m.RIGHT_SQUARE_BRACKET?this.state=b.CDATA_SECTION_END:(this._emitChars("]"),this.state=b.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case m.GREATER_THAN_SIGN:{this.state=b.DATA;break}case m.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=b.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(m.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&ma(this.preprocessor.peek(1))?b.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){ma(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===m.SEMICOLON&&this._err(N.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const ro=new Set([o.DD,o.DT,o.LI,o.OPTGROUP,o.OPTION,o.P,o.RB,o.RP,o.RT,o.RTC]),ba=new Set([...ro,o.CAPTION,o.COLGROUP,o.TBODY,o.TD,o.TFOOT,o.TH,o.THEAD,o.TR]),Sn=new Set([o.APPLET,o.CAPTION,o.HTML,o.MARQUEE,o.OBJECT,o.TABLE,o.TD,o.TEMPLATE,o.TH]),vp=new Set([...Sn,o.OL,o.UL]),Pp=new Set([...Sn,o.BUTTON]),Ea=new Set([o.ANNOTATION_XML,o.MI,o.MN,o.MO,o.MS,o.MTEXT]),Ta=new Set([o.DESC,o.FOREIGN_OBJECT,o.TITLE]),Mp=new Set([o.TR,o.TEMPLATE,o.HTML]),Bp=new Set([o.TBODY,o.TFOOT,o.THEAD,o.TEMPLATE,o.HTML]),Fp=new Set([o.TABLE,o.TEMPLATE,o.HTML]),Hp=new Set([o.TD,o.TH]);class Up{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=o.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===o.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===R.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const i=this._indexOf(t)+1;this.items.splice(i,0,n),this.tagIDs.splice(i,0,r),this.stackTop++,i===this.stackTop&&this._updateCurrentElement(),this.handler.onItemPush(this.current,this.currentTagId,i===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==R.HTML);this.shortenToLength(n<0?0:n)}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop<t)}}popUntilElementPopped(t){const n=this._indexOf(t);this.shortenToLength(n<0?0:n)}popUntilPopped(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r<0?0:r)}popUntilNumberedHeaderPopped(){this.popUntilPopped(kr,R.HTML)}popUntilTableCellPopped(){this.popUntilPopped(Hp,R.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(t,n){for(let r=this.stackTop;r>=0;r--)if(t.has(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(Fp,R.HTML)}clearBackToTableBodyContext(){this.clearBackTo(Bp,R.HTML)}clearBackToTableRowContext(){this.clearBackTo(Mp,R.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===o.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===o.HTML}hasInDynamicScope(t,n){for(let r=this.stackTop;r>=0;r--){const i=this.tagIDs[r];switch(this.treeAdapter.getNamespaceURI(this.items[r])){case R.HTML:{if(i===t)return!0;if(n.has(i))return!1;break}case R.SVG:{if(Ta.has(i))return!1;break}case R.MATHML:{if(Ea.has(i))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Sn)}hasInListItemScope(t){return this.hasInDynamicScope(t,vp)}hasInButtonScope(t){return this.hasInDynamicScope(t,Pp)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case R.HTML:{if(kr.has(n))return!0;if(Sn.has(n))return!1;break}case R.SVG:{if(Ta.has(n))return!1;break}case R.MATHML:{if(Ea.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===R.HTML)switch(this.tagIDs[n]){case t:return!0;case o.TABLE:case o.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===R.HTML)switch(this.tagIDs[t]){case o.TBODY:case o.THEAD:case o.TFOOT:return!0;case o.TABLE:case o.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===R.HTML)switch(this.tagIDs[n]){case t:return!0;case o.OPTION:case o.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;ro.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;ba.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==t&&ba.has(this.currentTagId);)this.pop()}}const cr=3;var We;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(We||(We={}));const xa={type:We.Marker};class zp{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],i=n.length,a=this.treeAdapter.getTagName(t),s=this.treeAdapter.getNamespaceURI(t);for(let u=0;u<this.entries.length;u++){const l=this.entries[u];if(l.type===We.Marker)break;const{element:c}=l;if(this.treeAdapter.getTagName(c)===a&&this.treeAdapter.getNamespaceURI(c)===s){const d=this.treeAdapter.getAttrList(c);d.length===i&&r.push({idx:u,attrs:d})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<cr)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<cr)return;const i=new Map(n.map(s=>[s.name,s.value]));let a=0;for(let s=0;s<r.length;s++){const u=r[s];u.attrs.every(l=>i.get(l.name)===l.value)&&(a+=1,a>=cr&&this.entries.splice(u.idx,1))}}insertMarker(){this.entries.unshift(xa)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:We.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:We.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n>=0&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(xa);t>=0?this.entries.splice(0,t+1):this.entries.length=0}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===We.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===We.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===We.Element&&n.element===t)}}const it={createDocument(){return{nodeName:"#document",mode:Me.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const i=e.childNodes.find(a=>a.nodeName==="#documentType");if(i)i.name=t,i.publicId=n,i.systemId=r;else{const a={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};it.appendChild(e,a)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(it.isTextNode(n)){n.value+=t;return}}it.appendChild(e,it.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&it.isTextNode(r)?r.value+=t:it.insertBefore(e,it.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation={...e.sourceCodeLocation,...t}}},io="html",jp="about:legacy-compat",Yp="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",ao=["+//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//"],Wp=[...ao,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],qp=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),so=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],Vp=[...so,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function wa(e,t){return t.some(n=>e.startsWith(n))}function Gp(e){return e.name===io&&e.publicId===null&&(e.systemId===null||e.systemId===jp)}function Qp(e){if(e.name!==io)return Me.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===Yp)return Me.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),qp.has(n))return Me.QUIRKS;let r=t===null?Wp:ao;if(wa(n,r))return Me.QUIRKS;if(r=t===null?so:Vp,wa(n,r))return Me.LIMITED_QUIRKS}return Me.NO_QUIRKS}const ya={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},Xp="definitionurl",Kp="definitionURL",$p=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),Jp=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:R.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:R.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:R.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:R.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:R.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:R.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:R.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:R.XML}],["xml:space",{prefix:"xml",name:"space",namespace:R.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:R.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:R.XMLNS}]]),Zp=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),em=new Set([o.B,o.BIG,o.BLOCKQUOTE,o.BODY,o.BR,o.CENTER,o.CODE,o.DD,o.DIV,o.DL,o.DT,o.EM,o.EMBED,o.H1,o.H2,o.H3,o.H4,o.H5,o.H6,o.HEAD,o.HR,o.I,o.IMG,o.LI,o.LISTING,o.MENU,o.META,o.NOBR,o.OL,o.P,o.PRE,o.RUBY,o.S,o.SMALL,o.SPAN,o.STRONG,o.STRIKE,o.SUB,o.SUP,o.TABLE,o.TT,o.U,o.UL,o.VAR]);function tm(e){const t=e.tagID;return t===o.FONT&&e.attrs.some(({name:r})=>r===ft.COLOR||r===ft.SIZE||r===ft.FACE)||em.has(t)}function oo(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===Xp){e.attrs[t].name=Kp;break}}function uo(e){for(let t=0;t<e.attrs.length;t++){const n=$p.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function Xr(e){for(let t=0;t<e.attrs.length;t++){const n=Jp.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 nm(e){const t=Zp.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=Dt(e.tagName))}function rm(e,t){return t===R.MATHML&&(e===o.MI||e===o.MO||e===o.MN||e===o.MS||e===o.MTEXT)}function im(e,t,n){if(t===R.MATHML&&e===o.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===ft.ENCODING){const i=n[r].value.toLowerCase();return i===ya.TEXT_HTML||i===ya.APPLICATION_XML}}return t===R.SVG&&(e===o.FOREIGN_OBJECT||e===o.DESC||e===o.TITLE)}function am(e,t,n,r){return(!r||r===R.HTML)&&im(e,t,n)||(!r||r===R.MATHML)&&rm(e,t)}const sm="hidden",om=8,um=3;var T;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(T||(T={}));const lm={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},lo=new Set([o.TABLE,o.TBODY,o.TFOOT,o.THEAD,o.TR]),_a={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:it,onParseError:null};class Aa{constructor(t,n,r=null,i=null){this.fragmentContext=r,this.scriptHandler=i,this.currentToken=null,this.stopped=!1,this.insertionMode=T.INITIAL,this.originalInsertionMode=T.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={..._a,...t},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=n??this.treeAdapter.createDocument(),this.tokenizer=new Dp(this.options,this),this.activeFormattingElements=new zp(this.treeAdapter),this.fragmentContextID=r?Dt(this.treeAdapter.getTagName(r)):o.UNKNOWN,this._setContextModes(r??this.document,this.fragmentContextID),this.openElements=new Up(this.document,this.treeAdapter,this)}static parse(t,n){const r=new this(n);return r.tokenizer.write(t,!0),r.document}static getFragmentParser(t,n){const r={..._a,...n};t??(t=r.treeAdapter.createElement(A.TEMPLATE,R.HTML,[]));const i=r.treeAdapter.createElement("documentmock",R.HTML,[]),a=new this(r,i,t);return a.fragmentContextID===o.TEMPLATE&&a.tmplInsertionModeStack.unshift(T.IN_TEMPLATE),a._initTokenizerForFragmentParsing(),a._insertFakeRootElement(),a._resetInsertionMode(),a._findFormInFragmentContext(),a}getFragment(){const t=this.treeAdapter.getFirstChild(this.document),n=this.treeAdapter.createDocumentFragment();return this._adoptNodes(t,n),n}_err(t,n,r){var i;if(!this.onParseError)return;const a=(i=t.location)!==null&&i!==void 0?i:lm,s={code:n,startLine:a.startLine,startCol:a.startCol,startOffset:a.startOffset,endLine:r?a.startLine:a.endLine,endCol:r?a.startCol:a.endCol,endOffset:r?a.startOffset:a.endOffset};this.onParseError(s)}onItemPush(t,n,r){var i,a;(a=(i=this.treeAdapter).onItemPush)===null||a===void 0||a.call(i,t),r&&this.openElements.stackTop>0&&this._setContextModes(t,n)}onItemPop(t,n){var r,i;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(i=(r=this.treeAdapter).onItemPop)===null||i===void 0||i.call(r,t,this.openElements.current),n){let a,s;this.openElements.stackTop===0&&this.fragmentContext?(a=this.fragmentContext,s=this.fragmentContextID):{current:a,currentTagId:s}=this.openElements,this._setContextModes(a,s)}}_setContextModes(t,n){const r=t===this.document||this.treeAdapter.getNamespaceURI(t)===R.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,R.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=T.TEXT}switchToPlaintextParsing(){this.insertionMode=T.TEXT,this.originalInsertionMode=T.IN_BODY,this.tokenizer.state=pe.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===A.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==R.HTML))switch(this.fragmentContextID){case o.TITLE:case o.TEXTAREA:{this.tokenizer.state=pe.RCDATA;break}case o.STYLE:case o.XMP:case o.IFRAME:case o.NOEMBED:case o.NOFRAMES:case o.NOSCRIPT:{this.tokenizer.state=pe.RAWTEXT;break}case o.SCRIPT:{this.tokenizer.state=pe.SCRIPT_DATA;break}case o.PLAINTEXT:{this.tokenizer.state=pe.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",i=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,i),t.location){const s=this.treeAdapter.getChildNodes(this.document).find(u=>this.treeAdapter.isDocumentTypeNode(u));s&&this.treeAdapter.setNodeSourceCodeLocation(s,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&{...n,startTag:n};this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,R.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,R.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(A.HTML,R.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,o.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const i=this.treeAdapter.getChildNodes(n),a=r?i.lastIndexOf(r):i.length,s=i[a-1];if(this.treeAdapter.getNodeSourceCodeLocation(s)){const{endLine:l,endCol:c,endOffset:d}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(s,{endLine:l,endCol:c,endOffset:d})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(s,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,i=this.treeAdapter.getTagName(t),a=n.type===$.END_TAG&&i===n.tagName?{endTag:{...r},endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,a)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===o.SVG&&this.treeAdapter.getTagName(n)===A.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===R.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===o.MGLYPH||t.tagID===o.MALIGNMARK)&&!this._isIntegrationPoint(r,n,R.HTML)}_processToken(t){switch(t.type){case $.CHARACTER:{this.onCharacter(t);break}case $.NULL_CHARACTER:{this.onNullCharacter(t);break}case $.COMMENT:{this.onComment(t);break}case $.DOCTYPE:{this.onDoctype(t);break}case $.START_TAG:{this._processStartTag(t);break}case $.END_TAG:{this.onEndTag(t);break}case $.EOF:{this.onEof(t);break}case $.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return am(t,i,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===We.Marker||this.openElements.contains(i.element)),r=n<0?t-1:n-1;for(let i=r;i>=0;i--){const a=this.activeFormattingElements.entries[i];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=T.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(o.P),this.openElements.popUntilTagNamePopped(o.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case o.TR:{this.insertionMode=T.IN_ROW;return}case o.TBODY:case o.THEAD:case o.TFOOT:{this.insertionMode=T.IN_TABLE_BODY;return}case o.CAPTION:{this.insertionMode=T.IN_CAPTION;return}case o.COLGROUP:{this.insertionMode=T.IN_COLUMN_GROUP;return}case o.TABLE:{this.insertionMode=T.IN_TABLE;return}case o.BODY:{this.insertionMode=T.IN_BODY;return}case o.FRAMESET:{this.insertionMode=T.IN_FRAMESET;return}case o.SELECT:{this._resetInsertionModeForSelect(t);return}case o.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case o.HTML:{this.insertionMode=this.headElement?T.AFTER_HEAD:T.BEFORE_HEAD;return}case o.TD:case o.TH:{if(t>0){this.insertionMode=T.IN_CELL;return}break}case o.HEAD:{if(t>0){this.insertionMode=T.IN_HEAD;return}break}}this.insertionMode=T.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===o.TEMPLATE)break;if(r===o.TABLE){this.insertionMode=T.IN_SELECT_IN_TABLE;return}}this.insertionMode=T.IN_SELECT}_isElementCausesFosterParenting(t){return lo.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case o.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===R.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case o.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return Sp[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Hg(this,t);return}switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{Kt(this,t);break}case T.BEFORE_HEAD:{$t(this,t);break}case T.IN_HEAD:{Jt(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Zt(this,t);break}case T.AFTER_HEAD:{en(this,t);break}case T.IN_BODY:case T.IN_CAPTION:case T.IN_CELL:case T.IN_TEMPLATE:{ho(this,t);break}case T.TEXT:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{dr(this,t);break}case T.IN_TABLE_TEXT:{Eo(this,t);break}case T.IN_COLUMN_GROUP:{On(this,t);break}case T.AFTER_BODY:{Ln(this,t);break}case T.AFTER_AFTER_BODY:{_n(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){Fg(this,t);return}switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{Kt(this,t);break}case T.BEFORE_HEAD:{$t(this,t);break}case T.IN_HEAD:{Jt(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Zt(this,t);break}case T.AFTER_HEAD:{en(this,t);break}case T.TEXT:{this._insertCharacters(t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{dr(this,t);break}case T.IN_COLUMN_GROUP:{On(this,t);break}case T.AFTER_BODY:{Ln(this,t);break}case T.AFTER_AFTER_BODY:{_n(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){Nr(this,t);return}switch(this.insertionMode){case T.INITIAL:case T.BEFORE_HTML:case T.BEFORE_HEAD:case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:case T.IN_BODY:case T.IN_TABLE:case T.IN_CAPTION:case T.IN_COLUMN_GROUP:case T.IN_TABLE_BODY:case T.IN_ROW:case T.IN_CELL:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:case T.IN_TEMPLATE:case T.IN_FRAMESET:case T.AFTER_FRAMESET:{Nr(this,t);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}case T.AFTER_BODY:{gm(this,t);break}case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{bm(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case T.INITIAL:{Em(this,t);break}case T.BEFORE_HEAD:case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:{this._err(t,N.misplacedDoctype);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,N.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?Ug(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{Tm(this,t);break}case T.BEFORE_HEAD:{wm(this,t);break}case T.IN_HEAD:{je(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Am(this,t);break}case T.AFTER_HEAD:{km(this,t);break}case T.IN_BODY:{ke(this,t);break}case T.IN_TABLE:{kt(this,t);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}case T.IN_CAPTION:{yg(this,t);break}case T.IN_COLUMN_GROUP:{Jr(this,t);break}case T.IN_TABLE_BODY:{Wn(this,t);break}case T.IN_ROW:{qn(this,t);break}case T.IN_CELL:{Cg(this,t);break}case T.IN_SELECT:{wo(this,t);break}case T.IN_SELECT_IN_TABLE:{Ng(this,t);break}case T.IN_TEMPLATE:{Sg(this,t);break}case T.AFTER_BODY:{Lg(this,t);break}case T.IN_FRAMESET:{Rg(this,t);break}case T.AFTER_FRAMESET:{vg(this,t);break}case T.AFTER_AFTER_BODY:{Mg(this,t);break}case T.AFTER_AFTER_FRAMESET:{Bg(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?zg(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{xm(this,t);break}case T.BEFORE_HEAD:{ym(this,t);break}case T.IN_HEAD:{_m(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Cm(this,t);break}case T.AFTER_HEAD:{Nm(this,t);break}case T.IN_BODY:{Yn(this,t);break}case T.TEXT:{hg(this,t);break}case T.IN_TABLE:{rn(this,t);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}case T.IN_CAPTION:{_g(this,t);break}case T.IN_COLUMN_GROUP:{Ag(this,t);break}case T.IN_TABLE_BODY:{Ir(this,t);break}case T.IN_ROW:{xo(this,t);break}case T.IN_CELL:{kg(this,t);break}case T.IN_SELECT:{yo(this,t);break}case T.IN_SELECT_IN_TABLE:{Ig(this,t);break}case T.IN_TEMPLATE:{Og(this,t);break}case T.AFTER_BODY:{Ao(this,t);break}case T.IN_FRAMESET:{Dg(this,t);break}case T.AFTER_FRAMESET:{Pg(this,t);break}case T.AFTER_AFTER_BODY:{_n(this,t);break}}}onEof(t){switch(this.insertionMode){case T.INITIAL:{Yt(this,t);break}case T.BEFORE_HTML:{Kt(this,t);break}case T.BEFORE_HEAD:{$t(this,t);break}case T.IN_HEAD:{Jt(this,t);break}case T.IN_HEAD_NO_SCRIPT:{Zt(this,t);break}case T.AFTER_HEAD:{en(this,t);break}case T.IN_BODY:case T.IN_TABLE:case T.IN_CAPTION:case T.IN_COLUMN_GROUP:case T.IN_TABLE_BODY:case T.IN_ROW:case T.IN_CELL:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:{go(this,t);break}case T.TEXT:{fg(this,t);break}case T.IN_TABLE_TEXT:{Wt(this,t);break}case T.IN_TEMPLATE:{_o(this,t);break}case T.AFTER_BODY:case T.IN_FRAMESET:case T.AFTER_FRAMESET:case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{$r(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===m.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:case T.TEXT:case T.IN_COLUMN_GROUP:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:case T.IN_FRAMESET:case T.AFTER_FRAMESET:{this._insertCharacters(t);break}case T.IN_BODY:case T.IN_CAPTION:case T.IN_CELL:case T.IN_TEMPLATE:case T.AFTER_BODY:case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{co(this,t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{dr(this,t);break}case T.IN_TABLE_TEXT:{bo(this,t);break}}}}function cm(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):mo(e,t),n}function dm(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const i=e.openElements.items[r];if(i===t.element)break;e._isSpecialElement(i,e.openElements.tagIDs[r])&&(n=i)}return n||(e.openElements.shortenToLength(r<0?0:r),e.activeFormattingElements.removeEntry(t)),n}function hm(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let a=0,s=i;s!==n;a++,s=i){i=e.openElements.getCommonAncestor(s);const u=e.activeFormattingElements.getElementEntry(s),l=u&&a>=um;!u||l?(l&&e.activeFormattingElements.removeEntry(u),e.openElements.remove(s)):(s=fm(e,u),r===t&&(e.activeFormattingElements.bookmark=u),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(s,r),r=s)}return r}function fm(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function pm(e,t,n){const r=e.treeAdapter.getTagName(t),i=Dt(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);i===o.TEMPLATE&&a===R.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function mm(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:i}=n,a=e.treeAdapter.createElement(i.tagName,r,i.attrs);e._adoptNodes(t,a),e.treeAdapter.appendChild(t,a),e.activeFormattingElements.insertElementAfterBookmark(a,i),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,a,i.tagID)}function Kr(e,t){for(let n=0;n<om;n++){const r=cm(e,t);if(!r)break;const i=dm(e,r);if(!i)break;e.activeFormattingElements.bookmark=r;const a=hm(e,i,r.element),s=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),s&&pm(e,s,a),mm(e,i,r)}}function Nr(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function gm(e,t){e._appendCommentNode(t,e.openElements.items[0])}function bm(e,t){e._appendCommentNode(t,e.document)}function $r(e,t){if(e.stopped=!0,t.location){const n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],i=e.treeAdapter.getNodeSourceCodeLocation(r);if(i&&!i.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const a=e.openElements.items[1],s=e.treeAdapter.getNodeSourceCodeLocation(a);s&&!s.endTag&&e._setEndLocation(a,t)}}}}function Em(e,t){e._setDocumentType(t);const n=t.forceQuirks?Me.QUIRKS:Qp(t);Gp(t)||e._err(t,N.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=T.BEFORE_HTML}function Yt(e,t){e._err(t,N.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Me.QUIRKS),e.insertionMode=T.BEFORE_HTML,e._processToken(t)}function Tm(e,t){t.tagID===o.HTML?(e._insertElement(t,R.HTML),e.insertionMode=T.BEFORE_HEAD):Kt(e,t)}function xm(e,t){const n=t.tagID;(n===o.HTML||n===o.HEAD||n===o.BODY||n===o.BR)&&Kt(e,t)}function Kt(e,t){e._insertFakeRootElement(),e.insertionMode=T.BEFORE_HEAD,e._processToken(t)}function wm(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.HEAD:{e._insertElement(t,R.HTML),e.headElement=e.openElements.current,e.insertionMode=T.IN_HEAD;break}default:$t(e,t)}}function ym(e,t){const n=t.tagID;n===o.HEAD||n===o.BODY||n===o.HTML||n===o.BR?$t(e,t):e._err(t,N.endTagWithoutMatchingOpenElement)}function $t(e,t){e._insertFakeElement(A.HEAD,o.HEAD),e.headElement=e.openElements.current,e.insertionMode=T.IN_HEAD,e._processToken(t)}function je(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.BASE:case o.BASEFONT:case o.BGSOUND:case o.LINK:case o.META:{e._appendElement(t,R.HTML),t.ackSelfClosing=!0;break}case o.TITLE:{e._switchToTextParsing(t,pe.RCDATA);break}case o.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,pe.RAWTEXT):(e._insertElement(t,R.HTML),e.insertionMode=T.IN_HEAD_NO_SCRIPT);break}case o.NOFRAMES:case o.STYLE:{e._switchToTextParsing(t,pe.RAWTEXT);break}case o.SCRIPT:{e._switchToTextParsing(t,pe.SCRIPT_DATA);break}case o.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=T.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(T.IN_TEMPLATE);break}case o.HEAD:{e._err(t,N.misplacedStartTagForHeadElement);break}default:Jt(e,t)}}function _m(e,t){switch(t.tagID){case o.HEAD:{e.openElements.pop(),e.insertionMode=T.AFTER_HEAD;break}case o.BODY:case o.BR:case o.HTML:{Jt(e,t);break}case o.TEMPLATE:{gt(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function gt(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==o.TEMPLATE&&e._err(t,N.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(o.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,N.endTagWithoutMatchingOpenElement)}function Jt(e,t){e.openElements.pop(),e.insertionMode=T.AFTER_HEAD,e._processToken(t)}function Am(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.BASEFONT:case o.BGSOUND:case o.HEAD:case o.LINK:case o.META:case o.NOFRAMES:case o.STYLE:{je(e,t);break}case o.NOSCRIPT:{e._err(t,N.nestedNoscriptInHead);break}default:Zt(e,t)}}function Cm(e,t){switch(t.tagID){case o.NOSCRIPT:{e.openElements.pop(),e.insertionMode=T.IN_HEAD;break}case o.BR:{Zt(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function Zt(e,t){const n=t.type===$.EOF?N.openElementsLeftAfterEof:N.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=T.IN_HEAD,e._processToken(t)}function km(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.BODY:{e._insertElement(t,R.HTML),e.framesetOk=!1,e.insertionMode=T.IN_BODY;break}case o.FRAMESET:{e._insertElement(t,R.HTML),e.insertionMode=T.IN_FRAMESET;break}case o.BASE:case o.BASEFONT:case o.BGSOUND:case o.LINK:case o.META:case o.NOFRAMES:case o.SCRIPT:case o.STYLE:case o.TEMPLATE:case o.TITLE:{e._err(t,N.abandonedHeadElementChild),e.openElements.push(e.headElement,o.HEAD),je(e,t),e.openElements.remove(e.headElement);break}case o.HEAD:{e._err(t,N.misplacedStartTagForHeadElement);break}default:en(e,t)}}function Nm(e,t){switch(t.tagID){case o.BODY:case o.HTML:case o.BR:{en(e,t);break}case o.TEMPLATE:{gt(e,t);break}default:e._err(t,N.endTagWithoutMatchingOpenElement)}}function en(e,t){e._insertFakeElement(A.BODY,o.BODY),e.insertionMode=T.IN_BODY,jn(e,t)}function jn(e,t){switch(t.type){case $.CHARACTER:{ho(e,t);break}case $.WHITESPACE_CHARACTER:{co(e,t);break}case $.COMMENT:{Nr(e,t);break}case $.START_TAG:{ke(e,t);break}case $.END_TAG:{Yn(e,t);break}case $.EOF:{go(e,t);break}}}function co(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function ho(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function Im(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function Sm(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function Om(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_FRAMESET)}function Lm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML)}function Rm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),kr.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,R.HTML)}function Dm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function vm(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML),n||(e.formElement=e.openElements.current))}function Pm(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const i=e.openElements.tagIDs[r];if(n===o.LI&&i===o.LI||(n===o.DD||n===o.DT)&&(i===o.DD||i===o.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==o.ADDRESS&&i!==o.DIV&&i!==o.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML)}function Mm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML),e.tokenizer.state=pe.PLAINTEXT}function Bm(e,t){e.openElements.hasInScope(o.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(o.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.framesetOk=!1}function Fm(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(A.A);n&&(Kr(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Hm(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Um(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(o.NOBR)&&(Kr(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,R.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function zm(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function jm(e,t){e.treeAdapter.getDocumentMode(e.document)!==Me.QUIRKS&&e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._insertElement(t,R.HTML),e.framesetOk=!1,e.insertionMode=T.IN_TABLE}function fo(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,R.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function po(e){const t=Js(e,ft.TYPE);return t!=null&&t.toLowerCase()===sm}function Ym(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,R.HTML),po(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function Wm(e,t){e._appendElement(t,R.HTML),t.ackSelfClosing=!0}function qm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._appendElement(t,R.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Vm(e,t){t.tagName=A.IMG,t.tagID=o.IMG,fo(e,t)}function Gm(e,t){e._insertElement(t,R.HTML),e.skipNextNewLine=!0,e.tokenizer.state=pe.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=T.TEXT}function Qm(e,t){e.openElements.hasInButtonScope(o.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,pe.RAWTEXT)}function Xm(e,t){e.framesetOk=!1,e._switchToTextParsing(t,pe.RAWTEXT)}function Ca(e,t){e._switchToTextParsing(t,pe.RAWTEXT)}function Km(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===T.IN_TABLE||e.insertionMode===T.IN_CAPTION||e.insertionMode===T.IN_TABLE_BODY||e.insertionMode===T.IN_ROW||e.insertionMode===T.IN_CELL?T.IN_SELECT_IN_TABLE:T.IN_SELECT}function $m(e,t){e.openElements.currentTagId===o.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML)}function Jm(e,t){e.openElements.hasInScope(o.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,R.HTML)}function Zm(e,t){e.openElements.hasInScope(o.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(o.RTC),e._insertElement(t,R.HTML)}function eg(e,t){e._reconstructActiveFormattingElements(),oo(t),Xr(t),t.selfClosing?e._appendElement(t,R.MATHML):e._insertElement(t,R.MATHML),t.ackSelfClosing=!0}function tg(e,t){e._reconstructActiveFormattingElements(),uo(t),Xr(t),t.selfClosing?e._appendElement(t,R.SVG):e._insertElement(t,R.SVG),t.ackSelfClosing=!0}function ka(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,R.HTML)}function ke(e,t){switch(t.tagID){case o.I:case o.S:case o.B:case o.U:case o.EM:case o.TT:case o.BIG:case o.CODE:case o.FONT:case o.SMALL:case o.STRIKE:case o.STRONG:{Hm(e,t);break}case o.A:{Fm(e,t);break}case o.H1:case o.H2:case o.H3:case o.H4:case o.H5:case o.H6:{Rm(e,t);break}case o.P:case o.DL:case o.OL:case o.UL:case o.DIV:case o.DIR:case o.NAV:case o.MAIN:case o.MENU:case o.ASIDE:case o.CENTER:case o.FIGURE:case o.FOOTER:case o.HEADER:case o.HGROUP:case o.DIALOG:case o.DETAILS:case o.ADDRESS:case o.ARTICLE:case o.SEARCH:case o.SECTION:case o.SUMMARY:case o.FIELDSET:case o.BLOCKQUOTE:case o.FIGCAPTION:{Lm(e,t);break}case o.LI:case o.DD:case o.DT:{Pm(e,t);break}case o.BR:case o.IMG:case o.WBR:case o.AREA:case o.EMBED:case o.KEYGEN:{fo(e,t);break}case o.HR:{qm(e,t);break}case o.RB:case o.RTC:{Jm(e,t);break}case o.RT:case o.RP:{Zm(e,t);break}case o.PRE:case o.LISTING:{Dm(e,t);break}case o.XMP:{Qm(e,t);break}case o.SVG:{tg(e,t);break}case o.HTML:{Im(e,t);break}case o.BASE:case o.LINK:case o.META:case o.STYLE:case o.TITLE:case o.SCRIPT:case o.BGSOUND:case o.BASEFONT:case o.TEMPLATE:{je(e,t);break}case o.BODY:{Sm(e,t);break}case o.FORM:{vm(e,t);break}case o.NOBR:{Um(e,t);break}case o.MATH:{eg(e,t);break}case o.TABLE:{jm(e,t);break}case o.INPUT:{Ym(e,t);break}case o.PARAM:case o.TRACK:case o.SOURCE:{Wm(e,t);break}case o.IMAGE:{Vm(e,t);break}case o.BUTTON:{Bm(e,t);break}case o.APPLET:case o.OBJECT:case o.MARQUEE:{zm(e,t);break}case o.IFRAME:{Xm(e,t);break}case o.SELECT:{Km(e,t);break}case o.OPTION:case o.OPTGROUP:{$m(e,t);break}case o.NOEMBED:case o.NOFRAMES:{Ca(e,t);break}case o.FRAMESET:{Om(e,t);break}case o.TEXTAREA:{Gm(e,t);break}case o.NOSCRIPT:{e.options.scriptingEnabled?Ca(e,t):ka(e,t);break}case o.PLAINTEXT:{Mm(e,t);break}case o.COL:case o.TH:case o.TD:case o.TR:case o.HEAD:case o.FRAME:case o.TBODY:case o.TFOOT:case o.THEAD:case o.CAPTION:case o.COLGROUP:break;default:ka(e,t)}}function ng(e,t){if(e.openElements.hasInScope(o.BODY)&&(e.insertionMode=T.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function rg(e,t){e.openElements.hasInScope(o.BODY)&&(e.insertionMode=T.AFTER_BODY,Ao(e,t))}function ig(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function ag(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(o.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(o.FORM):n&&e.openElements.remove(n))}function sg(e){e.openElements.hasInButtonScope(o.P)||e._insertFakeElement(A.P,o.P),e._closePElement()}function og(e){e.openElements.hasInListItemScope(o.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(o.LI),e.openElements.popUntilTagNamePopped(o.LI))}function ug(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function lg(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function cg(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function dg(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(A.BR,o.BR),e.openElements.pop(),e.framesetOk=!1}function mo(e,t){const n=t.tagName,r=t.tagID;for(let i=e.openElements.stackTop;i>0;i--){const a=e.openElements.items[i],s=e.openElements.tagIDs[i];if(r===s&&(r!==o.UNKNOWN||e.treeAdapter.getTagName(a)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=i&&e.openElements.shortenToLength(i);break}if(e._isSpecialElement(a,s))break}}function Yn(e,t){switch(t.tagID){case o.A:case o.B:case o.I:case o.S:case o.U:case o.EM:case o.TT:case o.BIG:case o.CODE:case o.FONT:case o.NOBR:case o.SMALL:case o.STRIKE:case o.STRONG:{Kr(e,t);break}case o.P:{sg(e);break}case o.DL:case o.UL:case o.OL:case o.DIR:case o.DIV:case o.NAV:case o.PRE:case o.MAIN:case o.MENU:case o.ASIDE:case o.BUTTON:case o.CENTER:case o.FIGURE:case o.FOOTER:case o.HEADER:case o.HGROUP:case o.DIALOG:case o.ADDRESS:case o.ARTICLE:case o.DETAILS:case o.SEARCH:case o.SECTION:case o.SUMMARY:case o.LISTING:case o.FIELDSET:case o.BLOCKQUOTE:case o.FIGCAPTION:{ig(e,t);break}case o.LI:{og(e);break}case o.DD:case o.DT:{ug(e,t);break}case o.H1:case o.H2:case o.H3:case o.H4:case o.H5:case o.H6:{lg(e);break}case o.BR:{dg(e);break}case o.BODY:{ng(e,t);break}case o.HTML:{rg(e,t);break}case o.FORM:{ag(e);break}case o.APPLET:case o.OBJECT:case o.MARQUEE:{cg(e,t);break}case o.TEMPLATE:{gt(e,t);break}default:mo(e,t)}}function go(e,t){e.tmplInsertionModeStack.length>0?_o(e,t):$r(e,t)}function hg(e,t){var n;t.tagID===o.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function fg(e,t){e._err(t,N.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function dr(e,t){if(lo.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=T.IN_TABLE_TEXT,t.type){case $.CHARACTER:{Eo(e,t);break}case $.WHITESPACE_CHARACTER:{bo(e,t);break}}else dn(e,t)}function pg(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_CAPTION}function mg(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_COLUMN_GROUP}function gg(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(A.COLGROUP,o.COLGROUP),e.insertionMode=T.IN_COLUMN_GROUP,Jr(e,t)}function bg(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_TABLE_BODY}function Eg(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(A.TBODY,o.TBODY),e.insertionMode=T.IN_TABLE_BODY,Wn(e,t)}function Tg(e,t){e.openElements.hasInTableScope(o.TABLE)&&(e.openElements.popUntilTagNamePopped(o.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function xg(e,t){po(t)?e._appendElement(t,R.HTML):dn(e,t),t.ackSelfClosing=!0}function wg(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,R.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function kt(e,t){switch(t.tagID){case o.TD:case o.TH:case o.TR:{Eg(e,t);break}case o.STYLE:case o.SCRIPT:case o.TEMPLATE:{je(e,t);break}case o.COL:{gg(e,t);break}case o.FORM:{wg(e,t);break}case o.TABLE:{Tg(e,t);break}case o.TBODY:case o.TFOOT:case o.THEAD:{bg(e,t);break}case o.INPUT:{xg(e,t);break}case o.CAPTION:{pg(e,t);break}case o.COLGROUP:{mg(e,t);break}default:dn(e,t)}}function rn(e,t){switch(t.tagID){case o.TABLE:{e.openElements.hasInTableScope(o.TABLE)&&(e.openElements.popUntilTagNamePopped(o.TABLE),e._resetInsertionMode());break}case o.TEMPLATE:{gt(e,t);break}case o.BODY:case o.CAPTION:case o.COL:case o.COLGROUP:case o.HTML:case o.TBODY:case o.TD:case o.TFOOT:case o.TH:case o.THEAD:case o.TR:break;default:dn(e,t)}}function dn(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,jn(e,t),e.fosterParentingEnabled=n}function bo(e,t){e.pendingCharacterTokens.push(t)}function Eo(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Wt(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)dn(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const To=new Set([o.CAPTION,o.COL,o.COLGROUP,o.TBODY,o.TD,o.TFOOT,o.TH,o.THEAD,o.TR]);function yg(e,t){const n=t.tagID;To.has(n)?e.openElements.hasInTableScope(o.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(o.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_TABLE,kt(e,t)):ke(e,t)}function _g(e,t){const n=t.tagID;switch(n){case o.CAPTION:case o.TABLE:{e.openElements.hasInTableScope(o.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(o.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_TABLE,n===o.TABLE&&rn(e,t));break}case o.BODY:case o.COL:case o.COLGROUP:case o.HTML:case o.TBODY:case o.TD:case o.TFOOT:case o.TH:case o.THEAD:case o.TR:break;default:Yn(e,t)}}function Jr(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.COL:{e._appendElement(t,R.HTML),t.ackSelfClosing=!0;break}case o.TEMPLATE:{je(e,t);break}default:On(e,t)}}function Ag(e,t){switch(t.tagID){case o.COLGROUP:{e.openElements.currentTagId===o.COLGROUP&&(e.openElements.pop(),e.insertionMode=T.IN_TABLE);break}case o.TEMPLATE:{gt(e,t);break}case o.COL:break;default:On(e,t)}}function On(e,t){e.openElements.currentTagId===o.COLGROUP&&(e.openElements.pop(),e.insertionMode=T.IN_TABLE,e._processToken(t))}function Wn(e,t){switch(t.tagID){case o.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_ROW;break}case o.TH:case o.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(A.TR,o.TR),e.insertionMode=T.IN_ROW,qn(e,t);break}case o.CAPTION:case o.COL:case o.COLGROUP:case o.TBODY:case o.TFOOT:case o.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE,kt(e,t));break}default:kt(e,t)}}function Ir(e,t){const n=t.tagID;switch(t.tagID){case o.TBODY:case o.TFOOT:case o.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE);break}case o.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE,rn(e,t));break}case o.BODY:case o.CAPTION:case o.COL:case o.COLGROUP:case o.HTML:case o.TD:case o.TH:case o.TR:break;default:rn(e,t)}}function qn(e,t){switch(t.tagID){case o.TH:case o.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,R.HTML),e.insertionMode=T.IN_CELL,e.activeFormattingElements.insertMarker();break}case o.CAPTION:case o.COL:case o.COLGROUP:case o.TBODY:case o.TFOOT:case o.THEAD:case o.TR:{e.openElements.hasInTableScope(o.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,Wn(e,t));break}default:kt(e,t)}}function xo(e,t){switch(t.tagID){case o.TR:{e.openElements.hasInTableScope(o.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY);break}case o.TABLE:{e.openElements.hasInTableScope(o.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,Ir(e,t));break}case o.TBODY:case o.TFOOT:case o.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(o.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,Ir(e,t));break}case o.BODY:case o.CAPTION:case o.COL:case o.COLGROUP:case o.HTML:case o.TD:case o.TH:break;default:rn(e,t)}}function Cg(e,t){const n=t.tagID;To.has(n)?(e.openElements.hasInTableScope(o.TD)||e.openElements.hasInTableScope(o.TH))&&(e._closeTableCell(),qn(e,t)):ke(e,t)}function kg(e,t){const n=t.tagID;switch(n){case o.TD:case o.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_ROW);break}case o.TABLE:case o.TBODY:case o.TFOOT:case o.THEAD:case o.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),xo(e,t));break}case o.BODY:case o.CAPTION:case o.COL:case o.COLGROUP:case o.HTML:break;default:Yn(e,t)}}function wo(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.OPTION:{e.openElements.currentTagId===o.OPTION&&e.openElements.pop(),e._insertElement(t,R.HTML);break}case o.OPTGROUP:{e.openElements.currentTagId===o.OPTION&&e.openElements.pop(),e.openElements.currentTagId===o.OPTGROUP&&e.openElements.pop(),e._insertElement(t,R.HTML);break}case o.HR:{e.openElements.currentTagId===o.OPTION&&e.openElements.pop(),e.openElements.currentTagId===o.OPTGROUP&&e.openElements.pop(),e._appendElement(t,R.HTML),t.ackSelfClosing=!0;break}case o.INPUT:case o.KEYGEN:case o.TEXTAREA:case o.SELECT:{e.openElements.hasInSelectScope(o.SELECT)&&(e.openElements.popUntilTagNamePopped(o.SELECT),e._resetInsertionMode(),t.tagID!==o.SELECT&&e._processStartTag(t));break}case o.SCRIPT:case o.TEMPLATE:{je(e,t);break}}}function yo(e,t){switch(t.tagID){case o.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===o.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===o.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===o.OPTGROUP&&e.openElements.pop();break}case o.OPTION:{e.openElements.currentTagId===o.OPTION&&e.openElements.pop();break}case o.SELECT:{e.openElements.hasInSelectScope(o.SELECT)&&(e.openElements.popUntilTagNamePopped(o.SELECT),e._resetInsertionMode());break}case o.TEMPLATE:{gt(e,t);break}}}function Ng(e,t){const n=t.tagID;n===o.CAPTION||n===o.TABLE||n===o.TBODY||n===o.TFOOT||n===o.THEAD||n===o.TR||n===o.TD||n===o.TH?(e.openElements.popUntilTagNamePopped(o.SELECT),e._resetInsertionMode(),e._processStartTag(t)):wo(e,t)}function Ig(e,t){const n=t.tagID;n===o.CAPTION||n===o.TABLE||n===o.TBODY||n===o.TFOOT||n===o.THEAD||n===o.TR||n===o.TD||n===o.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(o.SELECT),e._resetInsertionMode(),e.onEndTag(t)):yo(e,t)}function Sg(e,t){switch(t.tagID){case o.BASE:case o.BASEFONT:case o.BGSOUND:case o.LINK:case o.META:case o.NOFRAMES:case o.SCRIPT:case o.STYLE:case o.TEMPLATE:case o.TITLE:{je(e,t);break}case o.CAPTION:case o.COLGROUP:case o.TBODY:case o.TFOOT:case o.THEAD:{e.tmplInsertionModeStack[0]=T.IN_TABLE,e.insertionMode=T.IN_TABLE,kt(e,t);break}case o.COL:{e.tmplInsertionModeStack[0]=T.IN_COLUMN_GROUP,e.insertionMode=T.IN_COLUMN_GROUP,Jr(e,t);break}case o.TR:{e.tmplInsertionModeStack[0]=T.IN_TABLE_BODY,e.insertionMode=T.IN_TABLE_BODY,Wn(e,t);break}case o.TD:case o.TH:{e.tmplInsertionModeStack[0]=T.IN_ROW,e.insertionMode=T.IN_ROW,qn(e,t);break}default:e.tmplInsertionModeStack[0]=T.IN_BODY,e.insertionMode=T.IN_BODY,ke(e,t)}}function Og(e,t){t.tagID===o.TEMPLATE&>(e,t)}function _o(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(o.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):$r(e,t)}function Lg(e,t){t.tagID===o.HTML?ke(e,t):Ln(e,t)}function Ao(e,t){var n;if(t.tagID===o.HTML){if(e.fragmentContext||(e.insertionMode=T.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===o.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else Ln(e,t)}function Ln(e,t){e.insertionMode=T.IN_BODY,jn(e,t)}function Rg(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.FRAMESET:{e._insertElement(t,R.HTML);break}case o.FRAME:{e._appendElement(t,R.HTML),t.ackSelfClosing=!0;break}case o.NOFRAMES:{je(e,t);break}}}function Dg(e,t){t.tagID===o.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==o.FRAMESET&&(e.insertionMode=T.AFTER_FRAMESET))}function vg(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.NOFRAMES:{je(e,t);break}}}function Pg(e,t){t.tagID===o.HTML&&(e.insertionMode=T.AFTER_AFTER_FRAMESET)}function Mg(e,t){t.tagID===o.HTML?ke(e,t):_n(e,t)}function _n(e,t){e.insertionMode=T.IN_BODY,jn(e,t)}function Bg(e,t){switch(t.tagID){case o.HTML:{ke(e,t);break}case o.NOFRAMES:{je(e,t);break}}}function Fg(e,t){t.chars=he,e._insertCharacters(t)}function Hg(e,t){e._insertCharacters(t),e.framesetOk=!1}function Co(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==R.HTML&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function Ug(e,t){if(tm(t))Co(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===R.MATHML?oo(t):r===R.SVG&&(nm(t),uo(t)),Xr(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function zg(e,t){if(t.tagID===o.P||t.tagID===o.BR){Co(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===R.HTML){e._endTagOutsideForeignContent(t);break}const i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}A.AREA,A.BASE,A.BASEFONT,A.BGSOUND,A.BR,A.COL,A.EMBED,A.FRAME,A.HR,A.IMG,A.INPUT,A.KEYGEN,A.LINK,A.META,A.PARAM,A.SOURCE,A.TRACK,A.WBR;const jg=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,Yg=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),Na={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function ko(e,t){const n=Zg(e),r=Ua("type",{handlers:{root:Wg,element:qg,text:Vg,comment:Io,doctype:Gg,raw:Xg},unknown:Kg}),i={parser:n?new Aa(Na):Aa.getFragmentParser(void 0,Na),handle(u){r(u,i)},stitches:!1,options:t||{}};r(e,i),vt(i,Ve());const a=n?i.parser.document:i.parser.getFragment(),s=ep(a,{file:i.options.file});return i.stitches&&Bn(s,"comment",function(u,l,c){const d=u;if(d.value.stitch&&c&&l!==void 0){const h=c.children;return h[l]=d.value.stitch,l}}),s.type==="root"&&s.children.length===1&&s.children[0].type===e.type?s.children[0]:s}function No(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function Wg(e,t){No(e.children,t)}function qg(e,t){$g(e,t),No(e.children,t),Jg(e,t)}function Vg(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:$.CHARACTER,chars:e.value,location:hn(e)};vt(t,Ve(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function Gg(e,t){const n={type:$.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:hn(e)};vt(t,Ve(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function Qg(e,t){t.stitches=!0;const n=e1(e);if("children"in e&&"children"in n){const r=ko({type:"root",children:e.children},t.options);n.children=r.children}Io({type:"comment",value:{stitch:n}},t)}function Io(e,t){const n=e.value,r={type:$.COMMENT,data:n,location:hn(e)};vt(t,Ve(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function Xg(e,t){if(t.parser.tokenizer.preprocessor.html="",t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,So(t,Ve(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(jg,"<$1$2"):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;const n=t.parser.tokenizer._consume();t.parser.tokenizer._callState(n)}}function Kg(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))Qg(n,t);else{let r="";throw Yg.has(n.type)&&(r=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),new Error("Cannot compile `"+n.type+"` node"+r)}}function vt(e,t){So(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=pe.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function So(e,t){if(t&&t.offset!==void 0){const n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function $g(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===pe.PLAINTEXT)return;vt(t,Ve(e));const r=t.parser.openElements.current;let i="namespaceURI"in r?r.namespaceURI:ht.html;i===ht.html&&n==="svg"&&(i=ht.svg);const a=ap({...e,children:[]},{space:i===ht.svg?"svg":"html"}),s={type:$.START_TAG,tagName:n,tagID:Dt(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:hn(e)};t.parser.currentToken=s,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function Jg(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&fp.includes(n)||t.parser.tokenizer.state===pe.PLAINTEXT)return;vt(t,Un(e));const r={type:$.END_TAG,tagName:n,tagID:Dt(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:hn(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===pe.RCDATA||t.parser.tokenizer.state===pe.RAWTEXT||t.parser.tokenizer.state===pe.SCRIPT_DATA)&&(t.parser.tokenizer.state=pe.DATA)}function Zg(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function hn(e){const t=Ve(e)||{line:void 0,column:void 0,offset:void 0},n=Un(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function e1(e){return"children"in e?Ct({...e,children:[]}):Ct(e)}function Oo(e){return function(t,n){return ko(t,{...e,file:n})}}const Zr="-",t1=e=>{const t=r1(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{const u=s.split(Zr);return u[0]===""&&u.length!==1&&u.shift(),Lo(u,t)||n1(s)},getConflictingClassGroupIds:(s,u)=>{const l=n[s]||[];return u&&r[s]?[...l,...r[s]]:l}}},Lo=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),i=r?Lo(e.slice(1),r):void 0;if(i)return i;if(t.validators.length===0)return;const a=e.join(Zr);return(s=t.validators.find(({validator:u})=>u(a)))==null?void 0:s.classGroupId},Ia=/^\[(.+)\]$/,n1=e=>{if(Ia.test(e)){const t=Ia.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},r1=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return a1(Object.entries(e.classGroups),n).forEach(([a,s])=>{Sr(s,r,a,t)}),r},Sr=(e,t,n,r)=>{e.forEach(i=>{if(typeof i=="string"){const a=i===""?t:Sa(t,i);a.classGroupId=n;return}if(typeof i=="function"){if(i1(i)){Sr(i(r),t,n,r);return}t.validators.push({validator:i,classGroupId:n});return}Object.entries(i).forEach(([a,s])=>{Sr(s,Sa(t,a),n,r)})})},Sa=(e,t)=>{let n=e;return t.split(Zr).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},i1=e=>e.isThemeGetter,a1=(e,t)=>t?e.map(([n,r])=>{const i=r.map(a=>typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([s,u])=>[t+s,u])):a);return[n,i]}):e,s1=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const i=(a,s)=>{n.set(a,s),t++,t>e&&(t=0,r=n,n=new Map)};return{get(a){let s=n.get(a);if(s!==void 0)return s;if((s=r.get(a))!==void 0)return i(a,s),s},set(a,s){n.has(a)?n.set(a,s):i(a,s)}}},Ro="!",o1=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,i=t[0],a=t.length,s=u=>{const l=[];let c=0,d=0,h;for(let k=0;k<u.length;k++){let _=u[k];if(c===0){if(_===i&&(r||u.slice(k,k+a)===t)){l.push(u.slice(d,k)),d=k+a;continue}if(_==="/"){h=k;continue}}_==="["?c++:_==="]"&&c--}const g=l.length===0?u:u.substring(d),p=g.startsWith(Ro),E=p?g.substring(1):g,y=h&&h>d?h-d:void 0;return{modifiers:l,hasImportantModifier:p,baseClassName:E,maybePostfixModifierPosition:y}};return n?u=>n({className:u,parseClassName:s}):s},u1=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},l1=e=>({cache:s1(e.cacheSize),parseClassName:o1(e),...t1(e)}),c1=/\s+/,d1=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i}=t,a=[],s=e.trim().split(c1);let u="";for(let l=s.length-1;l>=0;l-=1){const c=s[l],{modifiers:d,hasImportantModifier:h,baseClassName:g,maybePostfixModifierPosition:p}=n(c);let E=!!p,y=r(E?g.substring(0,p):g);if(!y){if(!E){u=c+(u.length>0?" "+u:u);continue}if(y=r(g),!y){u=c+(u.length>0?" "+u:u);continue}E=!1}const k=u1(d).join(":"),_=h?k+Ro:k,S=_+y;if(a.includes(S))continue;a.push(S);const L=i(y,E);for(let M=0;M<L.length;++M){const F=L[M];a.push(_+F)}u=c+(u.length>0?" "+u:u)}return u};function h1(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Do(t))&&(r&&(r+=" "),r+=n);return r}const Do=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Do(e[r]))&&(n&&(n+=" "),n+=t);return n};function f1(e,...t){let n,r,i,a=s;function s(l){const c=t.reduce((d,h)=>h(d),e());return n=l1(c),r=n.cache.get,i=n.cache.set,a=u,u(l)}function u(l){const c=r(l);if(c)return c;const d=d1(l,n);return i(l,d),d}return function(){return a(h1.apply(null,arguments))}}const ue=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},vo=/^\[(?:([a-z-]+):)?(.+)\]$/i,p1=/^\d+\/\d+$/,m1=new Set(["px","full","screen"]),g1=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,b1=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,E1=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,T1=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,x1=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Xe=e=>At(e)||m1.has(e)||p1.test(e),tt=e=>Pt(e,"length",I1),At=e=>!!e&&!Number.isNaN(Number(e)),hr=e=>Pt(e,"number",At),qt=e=>!!e&&Number.isInteger(Number(e)),w1=e=>e.endsWith("%")&&At(e.slice(0,-1)),Q=e=>vo.test(e),nt=e=>g1.test(e),y1=new Set(["length","size","percentage"]),_1=e=>Pt(e,y1,Po),A1=e=>Pt(e,"position",Po),C1=new Set(["image","url"]),k1=e=>Pt(e,C1,O1),N1=e=>Pt(e,"",S1),Vt=()=>!0,Pt=(e,t,n)=>{const r=vo.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},I1=e=>b1.test(e)&&!E1.test(e),Po=()=>!1,S1=e=>T1.test(e),O1=e=>x1.test(e),L1=()=>{const e=ue("colors"),t=ue("spacing"),n=ue("blur"),r=ue("brightness"),i=ue("borderColor"),a=ue("borderRadius"),s=ue("borderSpacing"),u=ue("borderWidth"),l=ue("contrast"),c=ue("grayscale"),d=ue("hueRotate"),h=ue("invert"),g=ue("gap"),p=ue("gradientColorStops"),E=ue("gradientColorStopPositions"),y=ue("inset"),k=ue("margin"),_=ue("opacity"),S=ue("padding"),L=ue("saturate"),M=ue("scale"),F=ue("sepia"),I=ue("skew"),j=ue("space"),U=ue("translate"),z=()=>["auto","contain","none"],C=()=>["auto","hidden","clip","visible","scroll"],H=()=>["auto",Q,t],P=()=>[Q,t],te=()=>["",Xe,tt],ne=()=>["auto",At,Q],K=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],ce=()=>["solid","dashed","dotted","double","none"],fe=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Ee=()=>["start","end","center","between","around","evenly","stretch"],Te=()=>["","0",Q],x=()=>["auto","avoid","all","avoid-page","page","left","right","column"],de=()=>[At,Q];return{cacheSize:500,separator:":",theme:{colors:[Vt],spacing:[Xe,tt],blur:["none","",nt,Q],brightness:de(),borderColor:[e],borderRadius:["none","","full",nt,Q],borderSpacing:P(),borderWidth:te(),contrast:de(),grayscale:Te(),hueRotate:de(),invert:Te(),gap:P(),gradientColorStops:[e],gradientColorStopPositions:[w1,tt],inset:H(),margin:H(),opacity:de(),padding:P(),saturate:de(),scale:de(),sepia:Te(),skew:de(),space:P(),translate:P()},classGroups:{aspect:[{aspect:["auto","square","video",Q]}],container:["container"],columns:[{columns:[nt]}],"break-after":[{"break-after":x()}],"break-before":[{"break-before":x()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...K(),Q]}],overflow:[{overflow:C()}],"overflow-x":[{"overflow-x":C()}],"overflow-y":[{"overflow-y":C()}],overscroll:[{overscroll:z()}],"overscroll-x":[{"overscroll-x":z()}],"overscroll-y":[{"overscroll-y":z()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[y]}],"inset-x":[{"inset-x":[y]}],"inset-y":[{"inset-y":[y]}],start:[{start:[y]}],end:[{end:[y]}],top:[{top:[y]}],right:[{right:[y]}],bottom:[{bottom:[y]}],left:[{left:[y]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",qt,Q]}],basis:[{basis:H()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Q]}],grow:[{grow:Te()}],shrink:[{shrink:Te()}],order:[{order:["first","last","none",qt,Q]}],"grid-cols":[{"grid-cols":[Vt]}],"col-start-end":[{col:["auto",{span:["full",qt,Q]},Q]}],"col-start":[{"col-start":ne()}],"col-end":[{"col-end":ne()}],"grid-rows":[{"grid-rows":[Vt]}],"row-start-end":[{row:["auto",{span:[qt,Q]},Q]}],"row-start":[{"row-start":ne()}],"row-end":[{"row-end":ne()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Q]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Q]}],gap:[{gap:[g]}],"gap-x":[{"gap-x":[g]}],"gap-y":[{"gap-y":[g]}],"justify-content":[{justify:["normal",...Ee()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Ee(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Ee(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[S]}],px:[{px:[S]}],py:[{py:[S]}],ps:[{ps:[S]}],pe:[{pe:[S]}],pt:[{pt:[S]}],pr:[{pr:[S]}],pb:[{pb:[S]}],pl:[{pl:[S]}],m:[{m:[k]}],mx:[{mx:[k]}],my:[{my:[k]}],ms:[{ms:[k]}],me:[{me:[k]}],mt:[{mt:[k]}],mr:[{mr:[k]}],mb:[{mb:[k]}],ml:[{ml:[k]}],"space-x":[{"space-x":[j]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[j]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Q,t]}],"min-w":[{"min-w":[Q,t,"min","max","fit"]}],"max-w":[{"max-w":[Q,t,"none","full","min","max","fit","prose",{screen:[nt]},nt]}],h:[{h:[Q,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Q,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Q,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Q,t,"auto","min","max","fit"]}],"font-size":[{text:["base",nt,tt]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",hr]}],"font-family":[{font:[Vt]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Q]}],"line-clamp":[{"line-clamp":["none",At,hr]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Xe,Q]}],"list-image":[{"list-image":["none",Q]}],"list-style-type":[{list:["none","disc","decimal",Q]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[_]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[_]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ce(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Xe,tt]}],"underline-offset":[{"underline-offset":["auto",Xe,Q]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:P()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Q]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Q]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[_]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...K(),A1]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",_1]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},k1]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[E]}],"gradient-via-pos":[{via:[E]}],"gradient-to-pos":[{to:[E]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[u]}],"border-w-x":[{"border-x":[u]}],"border-w-y":[{"border-y":[u]}],"border-w-s":[{"border-s":[u]}],"border-w-e":[{"border-e":[u]}],"border-w-t":[{"border-t":[u]}],"border-w-r":[{"border-r":[u]}],"border-w-b":[{"border-b":[u]}],"border-w-l":[{"border-l":[u]}],"border-opacity":[{"border-opacity":[_]}],"border-style":[{border:[...ce(),"hidden"]}],"divide-x":[{"divide-x":[u]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[u]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[_]}],"divide-style":[{divide:ce()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...ce()]}],"outline-offset":[{"outline-offset":[Xe,Q]}],"outline-w":[{outline:[Xe,tt]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:te()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[_]}],"ring-offset-w":[{"ring-offset":[Xe,tt]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",nt,N1]}],"shadow-color":[{shadow:[Vt]}],opacity:[{opacity:[_]}],"mix-blend":[{"mix-blend":[...fe(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":fe()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",nt,Q]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[h]}],saturate:[{saturate:[L]}],sepia:[{sepia:[F]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[h]}],"backdrop-opacity":[{"backdrop-opacity":[_]}],"backdrop-saturate":[{"backdrop-saturate":[L]}],"backdrop-sepia":[{"backdrop-sepia":[F]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Q]}],duration:[{duration:de()}],ease:[{ease:["linear","in","out","in-out",Q]}],delay:[{delay:de()}],animate:[{animate:["none","spin","ping","pulse","bounce",Q]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[M]}],"scale-x":[{"scale-x":[M]}],"scale-y":[{"scale-y":[M]}],rotate:[{rotate:[qt,Q]}],"translate-x":[{"translate-x":[U]}],"translate-y":[{"translate-y":[U]}],"skew-x":[{"skew-x":[I]}],"skew-y":[{"skew-y":[I]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Q]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Q]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":P()}],"scroll-mx":[{"scroll-mx":P()}],"scroll-my":[{"scroll-my":P()}],"scroll-ms":[{"scroll-ms":P()}],"scroll-me":[{"scroll-me":P()}],"scroll-mt":[{"scroll-mt":P()}],"scroll-mr":[{"scroll-mr":P()}],"scroll-mb":[{"scroll-mb":P()}],"scroll-ml":[{"scroll-ml":P()}],"scroll-p":[{"scroll-p":P()}],"scroll-px":[{"scroll-px":P()}],"scroll-py":[{"scroll-py":P()}],"scroll-ps":[{"scroll-ps":P()}],"scroll-pe":[{"scroll-pe":P()}],"scroll-pt":[{"scroll-pt":P()}],"scroll-pr":[{"scroll-pr":P()}],"scroll-pb":[{"scroll-pb":P()}],"scroll-pl":[{"scroll-pl":P()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Q]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Xe,tt,hr]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},R1=f1(L1);function q(...e){return R1(va.clsx(e))}function Or(){return Or=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Or.apply(null,arguments)}function D1(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.includes(r))continue;n[r]=e[r]}return n}var Mo,Bo;typeof document<"u"&&(Mo=document);typeof window<"u"&&(Bo=window);var Fo=X.createContext({document:Mo,window:Bo}),v1=()=>X.useContext(Fo),P1=["children","head","initialContent","src","mountTarget"],ei=X.forwardRef((e,t)=>{var{children:n,head:r,initialContent:i,src:a,mountTarget:s}=e,u=D1(e,P1),[l,c]=X.useState(!1),[d,h]=X.useState(),g=M=>{M&&h(M)};X.useImperativeHandle(t,()=>d,[d]);var p=i||"<!DOCTYPE html><html><head></head><body></body></html>",E=()=>d?d.contentDocument:null,y=()=>{var M=E();return s?M==null?void 0:M.querySelector(s):M==null?void 0:M.body},k=X.useRef(),_=X.useCallback(M=>{k.current=M;var F=()=>setInterval(()=>_(M),500);clearInterval(F()),l||c(!0)},[l]);X.useMemo(()=>{!a&&u.onLoad&&l&&u.onLoad(k.current)},[l]),X.useEffect(()=>{if(d&&!a){var M;(M=d.contentWindow)==null||M.addEventListener("DOMContentLoaded",_)}return()=>{if(d&&!a){var F;(F=d.contentWindow)==null||F.removeEventListener("DOMContentLoaded",_)}}},[d,_]);var S=()=>{var M,F=E(),I=(M=E())==null?void 0:M.head,j=y(),U=(F==null?void 0:F.defaultView)||(F==null?void 0:F.parentView),z=f.jsx(Fo.Provider,{value:{document:F,window:U},children:n});return[I&&r&&fr.createPortal(r,I),d&&j&&fr.createPortal(z,j)]},L={};return a?(delete L.srcDoc,L.src=a,L.onLoad=u.onLoad):L.srcDoc=p,f.jsx("iframe",Or({title:u.title,ref:g},u,{onLoad:_},L,{children:l&&S()}))});ei.displayName="IFrame";const Ho="opencx-widget-portal";function Vn(){return null}function M1({children:e}){var n,r;const t=(r=(n=v1())==null?void 0:n.document)==null?void 0:r.getElementById(Ho);return t?fr.createPortal(e,t):(console.error("Portal container not found!"),null)}function B1(){return f.jsx("div",{id:Ho,className:"absolute size-full top-0 left-0"})}Vn.Portal=M1;Vn.Container=B1;const Oa=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,La=va.clsx,F1=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return La(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:i,defaultVariants:a}=t,s=Object.keys(i).map(c=>{const d=n==null?void 0:n[c],h=a==null?void 0:a[c];if(d===null)return null;const g=Oa(d)||Oa(h);return i[c][g]}),u=n&&Object.entries(n).reduce((c,d)=>{let[h,g]=d;return g===void 0||(c[h]=g),c},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,d)=>{let{class:h,className:g,...p}=d;return Object.entries(p).every(E=>{let[y,k]=E;return Array.isArray(k)?k.includes({...a,...u}[y]):{...a,...u}[y]===k})?[...c,h,g]:c},[]);return La(e,s,l,n==null?void 0:n.class,n==null?void 0:n.className)},Nt={x:2,y:2},$e=X.memo(X.forwardRef(({children:e,className:t,scale:n=1.02,off:r=!1},i)=>{const[a,s]=X.useState(!1),[u,l]=X.useState({x:0,y:0});if(r||/translate/.test(e.props.className||""))return e;const d=E=>{var U,z;const{clientX:y,clientY:k}=E,_=E.currentTarget.getBoundingClientRect(),S=y-(_.left+_.width/2),L=k-(_.top+_.height/2),M=Math.max(-1,Math.min(1,S/(_.width/2))),F=Math.max(-1,Math.min(1,L/(_.height/2))),I=M*Nt.x,j=F*Nt.y;l({x:I,y:j}),(z=(U=e.props).onMouseMove)==null||z.call(U,E)},h=()=>{var E,y;s(!0),(y=(E=e.props).onMouseEnter)==null||y.call(E)},g=()=>{var E,y;s(!1),l({x:0,y:0}),(y=(E=e.props).onMouseLeave)==null||y.call(E)},p={"--wobble-x":a?`${u.x}px`:"0px","--wobble-y":a?`${u.y}px`:"0px","--scale":1-(n-1)};return X.cloneElement(e,{ref:i,onMouseMove:d,onMouseEnter:h,onMouseLeave:g,style:{...p,...e.props.style},className:q("translate-x-[var(--wobble-x)]","translate-y-[var(--wobble-y)]","hover:scale-[var(--scale)] active:hover:scale-[calc(var(--scale)-0.02)]",t,e.props.className,"transition-all ease-out")})}));$e.displayName="Wobble";function re(e){return{"data-component":e}}const H1=F1(q("inline-flex shrink-0 items-center justify-center gap-2","text-sm font-medium whitespace-nowrap","ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50","active:scale-95 hover:active:scale-95","rounded-xl","border","transition"),{variants:{variant:{default:"border-primary bg-primary text-primary-foreground",destructive:"border-destructive bg-destructive text-destructive-foreground",outline:"bg-background hover:border-primary",secondary:"bg-secondary text-secondary-foreground",ghost:"border-transparent hover:bg-secondary",link:"border-transparent text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"py-2 px-3.5 text-xs",lg:"min-h-12 px-4 rounded-[20px]",icon:"h-10 w-10",fit:"size-fit p-2",free:"p-2",selfless:"p-0"}},defaultVariants:{variant:"default",size:"default"}}),Oe=ye.forwardRef(({className:e,variant:t="default",size:n,asChild:r=!1,...i},a)=>{const s=r?cu.Slot:"button";return f.jsx($e,{ref:a,children:f.jsx(s,{...re("ui_lib/btn"),"data-variant":t,className:q(H1({variant:t,size:n,className:e})),...i})})});Oe.displayName="Button";const U1=ze.Root,z1=ze.Trigger,Uo=ye.forwardRef(({className:e,...t},n)=>f.jsx(ze.Overlay,{ref:n,className:q("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));Uo.displayName=ze.Overlay.displayName;const zo=ye.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(Vn.Portal,{children:[f.jsx(Uo,{}),f.jsxs(ze.Content,{ref:r,className:q("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...n,children:[t,f.jsx(ze.Close,{asChild:!0,className:"absolute right-4 top-4 opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:f.jsxs(Oe,{size:"fit",variant:"ghost",children:[f.jsx(le.X,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"Close"})]})})]})]}));zo.displayName=ze.Content.displayName;const jo=ye.forwardRef(({className:e,...t},n)=>f.jsx(ze.Title,{ref:n,className:q("text-lg font-semibold leading-none tracking-tight",e),...t}));jo.displayName=ze.Title.displayName;const j1=ye.forwardRef(({className:e,...t},n)=>f.jsx(ze.Description,{ref:n,className:q("text-sm text-muted-foreground",e),...t}));j1.displayName=ze.Description.displayName;function Yo({attachment:e}){const{name:t,size:n,type:r,url:i}=e,a=r.startsWith("image/"),s=r.startsWith("video/"),u=r.startsWith("audio/");return u?f.jsx($e,{children:f.jsx("div",{className:"w-full shrink-0 overflow-hidden",children:f.jsxs("audio",{controls:!0,className:"w-full",children:[f.jsx("source",{src:i,type:r}),"Your browser does not support the audio tag."]})})}):s?f.jsx($e,{children:f.jsx("div",{className:"w-full border shrink-0 rounded-2xl overflow-hidden",children:f.jsxs("video",{controls:!0,children:[f.jsx("source",{src:i,type:r}),"Your browser does not support the video tag."]})})}):!a&&!s&&!u?f.jsx($e,{children:f.jsx("div",{className:"size-fit border shrink-0 rounded-2xl overflow-hidden",children:f.jsxs("div",{className:"flex items-end gap-2 p-2",children:[f.jsx("a",{href:i,target:"_blank",rel:"noopener noreferrer",className:q("text-xs text-blue-500 line-clamp-2 underline hover:text-blue-600","break-words [word-break:break-word]"),children:t}),f.jsxs("span",{className:"text-xs text-muted-foreground whitespace-nowrap",children:[(n/1024).toFixed(2)," KB"]})]})})}):f.jsxs(U1,{children:[f.jsx($e,{children:f.jsx(z1,{children:f.jsx("div",{className:"size-fit border shrink-0 rounded-2xl overflow-hidden",children:a&&f.jsx("img",{src:i,className:"object-cover size-16",alt:t})})})}),f.jsxs(zo,{"aria-describedby":void 0,className:"size-full rounded-3xl flex items-center justify-center bg-transparent backdrop-blur border-none gap-0",children:[f.jsx(jo,{className:"sr-only",children:"Image preview"}),a&&f.jsx("div",{className:"size-fit shrink-0 rounded-2xl overflow-hidden max-h-full",children:f.jsx("img",{src:i,className:"object-cover size-auto",alt:t})})]})]})}function Rn({data:e,id:t,type:n,attachments:r,isFirstInGroup:i,isLastInGroup:a,isAloneInGroup:s,dataComponentNames:u,classNames:l}){const{anchorTarget:c}=W.useConfig(),{message:d,variant:h="default"}=e;return h==="error"?f.jsx("div",{children:f.jsx("div",{className:"flex flex-row flex-wrap items-center justify-start",children:f.jsx("div",{className:"leading-snug text-sm text-destructive",children:d})})}):f.jsxs("div",{...re((u==null?void 0:u.messageContainer)??"chat/agent_msg/root"),className:q("w-5/6 flex flex-col items-start gap-1",l==null?void 0:l.messageContainer),children:[r&&r.length>0&&f.jsx("div",{className:"w-full gap-1 flex flex-row flex-wrap items-center justify-start",children:r==null?void 0:r.map(g=>f.jsx(Yo,{attachment:g},g.id))}),d.length>0&&f.jsx("div",{...re((u==null?void 0:u.message)??"chat/agent_msg/msg"),"data-first":i,"data-last":a,"data-alone":s,className:q("transition-all","w-fit py-3 px-4 rounded-3xl bg-secondary text-secondary-foreground","leading-snug text-sm prose prose-sm prose-a:decoration-primary prose-a:underline","break-words [word-break:break-word]",i&&!s&&"rounded-bl-md",a&&!s&&"rounded-tl-md",!i&&!a&&!s&&"rounded-l-md",l==null?void 0:l.message),children:f.jsx(Ws,{"data-type":n,"data-id":t,remarkPlugins:[gs],rehypePlugins:[Oo],components:{a:({children:g,...p})=>f.jsx("a",{target:c??"_top",...p,children:g})},children:d})})]})}function Y1(e){return f.jsx("div",{className:"w-full max-w-full overflow-auto shrink-0",children:f.jsx("pre",{dir:"auto",className:"text-xs leading-tight whitespace-pre-wrap break-word",children:JSON.stringify(e,null,1)})})}const ti=ye.forwardRef(({className:e,...t},n)=>f.jsx(St.Root,{ref:n,className:q("relative flex size-6 aspect-square shrink-0 overflow-hidden rounded-full bg-secondary",e),...t}));ti.displayName=St.Root.displayName;const ni=ye.forwardRef(({className:e,...t},n)=>f.jsx(St.Image,{ref:n,className:q("aspect-square h-full w-full",e),...t}));ni.displayName=St.Image.displayName;const ri=ye.forwardRef(({className:e,...t},n)=>f.jsx(St.Fallback,{ref:n,className:q("flex size-full text-xs items-center justify-center rounded-lg",e),...t}));ri.displayName=St.Fallback.displayName;function Lr({agent:e,...t}){var n,r;return f.jsxs(ti,{...t,children:[f.jsx(ni,{src:(e==null?void 0:e.avatar)??"",alt:"Agent Icon"}),(e==null?void 0:e.name)&&f.jsx(ri,{children:(r=(n=e==null?void 0:e.name)==null?void 0:n.slice(0,1))==null?void 0:r.toUpperCase()})]})}const W1=10,q1=(e,t)=>({initial:{opacity:0,x:-e,...t.initial},animate:{opacity:1,x:0,...t.animate},exit:{opacity:0,x:e,...t.exit}}),V1=(e,t)=>({initial:{opacity:0,x:e,...t.initial},animate:{opacity:1,x:0,...t.animate},exit:{opacity:0,x:-e,...t.exit}}),G1=(e,t)=>({initial:{opacity:0,y:e,...t.initial},animate:{opacity:1,y:0,...t.animate},exit:{opacity:0,y:-e,...t.exit}}),Q1=(e,t)=>({initial:{opacity:0,y:-e,...t.initial},animate:{opacity:1,y:0,...t.animate},exit:{opacity:0,y:e,...t.exit}}),X1={right:q1,left:V1,up:G1,down:Q1},ae=X.forwardRef(({fadeIn:e="down",distance:t=W1,children:n,snapExit:r=!1,overrides:i={},...a},s)=>{const u=e?X1[e](t,i):{};return r&&u.exit&&typeof u.exit=="object"&&!Array.isArray(u.exit)&&(u.exit.transition={duration:0}),f.jsx(be.motion.div,{ref:s,...a,...u,children:n})});ae.displayName="MotionDiv";function K1({agent:e}){return f.jsx(be.AnimatePresence,{children:f.jsxs(ae,{...re("chat/bot_loading/root"),className:"flex flex-row items-end w-full gap-2 animate-pulse",children:[f.jsx(Lr,{agent:e}),f.jsxs("div",{...re("chat/bot_loading/bouncing_dots_container"),className:q("flex items-center [&_span]:bg-secondary-foreground [&_span]:size-1 gap-1 p-2 rounded-xl bg-secondary"),children:[f.jsx(be.motion.span,{className:"rounded-full animate-bounce [animation-delay:-0.3s]"}),f.jsx(be.motion.span,{className:"rounded-full animate-bounce [animation-delay:-0.15s]"}),f.jsx(be.motion.span,{className:"rounded-full animate-bounce"})]})]})})}const Wo='@import"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..700;1,14..32,100..700&display=swap";@import"https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap";*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}*{-ms-overflow-style:none;scrollbar-width:none}*::-webkit-scrollbar{display:none}*{border-color:hsl(var(--opencx-border))}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.prose{color:var(--tw-prose-body);max-width:65ch}.prose :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.prose :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-lead);font-size:1.25em;line-height:1.6;margin-top:1.2em;margin-bottom:1.2em}.prose :where(a):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-links);text-decoration:underline;font-weight:500}.prose :where(strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-bold);font-weight:600}.prose :where(a strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(blockquote strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(thead th strong):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}.prose :where(ol[type=A]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}.prose :where(ol[type=a]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}.prose :where(ol[type=A s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-alpha}.prose :where(ol[type=a s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-alpha}.prose :where(ol[type=I]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}.prose :where(ol[type=i]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}.prose :where(ol[type=I s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:upper-roman}.prose :where(ol[type=i s]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:lower-roman}.prose :where(ol[type="1"]):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:decimal}.prose :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){list-style-type:disc;margin-top:1.25em;margin-bottom:1.25em;padding-inline-start:1.625em}.prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{font-weight:400;color:var(--tw-prose-counters)}.prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *))::marker{color:var(--tw-prose-bullets)}.prose :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.25em}.prose :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){border-color:var(--tw-prose-hr);border-top-width:1px;margin-top:3em;margin-bottom:3em}.prose :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-style:italic;color:var(--tw-prose-quotes);border-inline-start-width:.25rem;border-inline-start-color:var(--tw-prose-quote-borders);quotes:"“""”""‘""’";margin-top:1.6em;margin-bottom:1.6em;padding-inline-start:1em}.prose :where(blockquote p:first-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:open-quote}.prose :where(blockquote p:last-of-type):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:close-quote}.prose :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:800;font-size:2.25em;margin-top:0;margin-bottom:.8888889em;line-height:1.1111111}.prose :where(h1 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:900;color:inherit}.prose :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:700;font-size:1.5em;margin-top:2em;margin-bottom:1em;line-height:1.3333333}.prose :where(h2 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:800;color:inherit}.prose :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;font-size:1.25em;margin-top:1.6em;margin-bottom:.6em;line-height:1.6}.prose :where(h3 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}.prose :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;margin-top:1.5em;margin-bottom:.5em;line-height:1.5}.prose :where(h4 strong):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:700;color:inherit}.prose :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){display:block;margin-top:2em;margin-bottom:2em}.prose :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-weight:500;font-family:inherit;color:var(--tw-prose-kbd);box-shadow:0 0 0 1px rgb(var(--tw-prose-kbd-shadows) / 10%),0 3px rgb(var(--tw-prose-kbd-shadows) / 10%);font-size:.875em;border-radius:.3125rem;padding-top:.1875em;padding-inline-end:.375em;padding-bottom:.1875em;padding-inline-start:.375em}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-code);font-weight:600;font-size:.875em}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:"`"}.prose :where(code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:"`"}.prose :where(a code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(h1 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.875em}.prose :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit;font-size:.9em}.prose :where(h4 code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(blockquote code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(thead th code):not(:where([class~=not-prose],[class~=not-prose] *)){color:inherit}.prose :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-pre-code);background-color:var(--tw-prose-pre-bg);overflow-x:auto;font-weight:400;font-size:.875em;line-height:1.7142857;margin-top:1.7142857em;margin-bottom:1.7142857em;border-radius:.375rem;padding-top:.8571429em;padding-inline-end:1.1428571em;padding-bottom:.8571429em;padding-inline-start:1.1428571em}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)){background-color:transparent;border-width:0;border-radius:0;padding:0;font-weight:inherit;color:inherit;font-size:inherit;font-family:inherit;line-height:inherit}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):before{content:none}.prose :where(pre code):not(:where([class~=not-prose],[class~=not-prose] *)):after{content:none}.prose :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){width:100%;table-layout:auto;margin-top:2em;margin-bottom:2em;font-size:.875em;line-height:1.7142857}.prose :where(thead):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-th-borders)}.prose :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-headings);font-weight:600;vertical-align:bottom;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}.prose :where(tbody tr):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:1px;border-bottom-color:var(--tw-prose-td-borders)}.prose :where(tbody tr:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){border-bottom-width:0}.prose :where(tbody td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:baseline}.prose :where(tfoot):not(:where([class~=not-prose],[class~=not-prose] *)){border-top-width:1px;border-top-color:var(--tw-prose-th-borders)}.prose :where(tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){vertical-align:top}.prose :where(th,td):not(:where([class~=not-prose],[class~=not-prose] *)){text-align:start}.prose :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){color:var(--tw-prose-captions);font-size:.875em;line-height:1.4285714;margin-top:.8571429em}.prose{--tw-prose-body: #374151;--tw-prose-headings: #111827;--tw-prose-lead: #4b5563;--tw-prose-links: #111827;--tw-prose-bold: #111827;--tw-prose-counters: #6b7280;--tw-prose-bullets: #d1d5db;--tw-prose-hr: #e5e7eb;--tw-prose-quotes: #111827;--tw-prose-quote-borders: #e5e7eb;--tw-prose-captions: #6b7280;--tw-prose-kbd: #111827;--tw-prose-kbd-shadows: 17 24 39;--tw-prose-code: #111827;--tw-prose-pre-code: #e5e7eb;--tw-prose-pre-bg: #1f2937;--tw-prose-th-borders: #d1d5db;--tw-prose-td-borders: #e5e7eb;--tw-prose-invert-body: #d1d5db;--tw-prose-invert-headings: #fff;--tw-prose-invert-lead: #9ca3af;--tw-prose-invert-links: #fff;--tw-prose-invert-bold: #fff;--tw-prose-invert-counters: #9ca3af;--tw-prose-invert-bullets: #4b5563;--tw-prose-invert-hr: #374151;--tw-prose-invert-quotes: #f3f4f6;--tw-prose-invert-quote-borders: #374151;--tw-prose-invert-captions: #9ca3af;--tw-prose-invert-kbd: #fff;--tw-prose-invert-kbd-shadows: 255 255 255;--tw-prose-invert-code: #fff;--tw-prose-invert-pre-code: #d1d5db;--tw-prose-invert-pre-bg: rgb(0 0 0 / 50%);--tw-prose-invert-th-borders: #4b5563;--tw-prose-invert-td-borders: #374151;font-size:1rem;line-height:1.75}.prose :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;margin-bottom:.5em}.prose :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}.prose :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.375em}.prose :where(.prose>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}.prose :where(.prose>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}.prose :where(.prose>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}.prose :where(.prose>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em}.prose :where(.prose>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.25em}.prose :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.75em;margin-bottom:.75em}.prose :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.25em;margin-bottom:1.25em}.prose :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5em;padding-inline-start:1.625em}.prose :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.5714286em;padding-inline-end:.5714286em;padding-bottom:.5714286em;padding-inline-start:.5714286em}.prose :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2em;margin-bottom:2em}.prose :where(.prose>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose :where(.prose>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}.prose-sm{font-size:.875rem;line-height:1.7142857}.prose-sm :where(p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.prose-sm :where([class~=lead]):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;line-height:1.5555556;margin-top:.8888889em;margin-bottom:.8888889em}.prose-sm :where(blockquote):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.3333333em;margin-bottom:1.3333333em;padding-inline-start:1.1111111em}.prose-sm :where(h1):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:2.1428571em;margin-top:0;margin-bottom:.8em;line-height:1.2}.prose-sm :where(h2):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.4285714em;margin-top:1.6em;margin-bottom:.8em;line-height:1.4}.prose-sm :where(h3):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:1.2857143em;margin-top:1.5555556em;margin-bottom:.4444444em;line-height:1.5555556}.prose-sm :where(h4):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.4285714em;margin-bottom:.5714286em;line-height:1.4285714}.prose-sm :where(img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(picture):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(picture>img):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose-sm :where(video):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(kbd):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;border-radius:.3125rem;padding-top:.1428571em;padding-inline-end:.3571429em;padding-bottom:.1428571em;padding-inline-start:.3571429em}.prose-sm :where(code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em}.prose-sm :where(h2 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.9em}.prose-sm :where(h3 code):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8888889em}.prose-sm :where(pre):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.6666667;margin-top:1.6666667em;margin-bottom:1.6666667em;border-radius:.25rem;padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}.prose-sm :where(ul):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em;padding-inline-start:1.5714286em}.prose-sm :where(li):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;margin-bottom:.2857143em}.prose-sm :where(ol>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}.prose-sm :where(ul>li):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:.4285714em}.prose-sm :where(.prose-sm>ul>li p):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.prose-sm :where(.prose-sm>ul>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(.prose-sm>ul>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}.prose-sm :where(.prose-sm>ol>li>p:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(.prose-sm>ol>li>p:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:1.1428571em}.prose-sm :where(ul ul,ul ol,ol ul,ol ol):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.5714286em;margin-bottom:.5714286em}.prose-sm :where(dl):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em;margin-bottom:1.1428571em}.prose-sm :where(dt):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.1428571em}.prose-sm :where(dd):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:.2857143em;padding-inline-start:1.5714286em}.prose-sm :where(hr):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:2.8571429em;margin-bottom:2.8571429em}.prose-sm :where(hr+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h2+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h3+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(h4+*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(table):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.5}.prose-sm :where(thead th):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(thead th:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose-sm :where(thead th:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose-sm :where(tbody td,tfoot td):not(:where([class~=not-prose],[class~=not-prose] *)){padding-top:.6666667em;padding-inline-end:1em;padding-bottom:.6666667em;padding-inline-start:1em}.prose-sm :where(tbody td:first-child,tfoot td:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-start:0}.prose-sm :where(tbody td:last-child,tfoot td:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){padding-inline-end:0}.prose-sm :where(figure):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:1.7142857em;margin-bottom:1.7142857em}.prose-sm :where(figure>*):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0;margin-bottom:0}.prose-sm :where(figcaption):not(:where([class~=not-prose],[class~=not-prose] *)){font-size:.8571429em;line-height:1.3333333;margin-top:.6666667em}.prose-sm :where(.prose-sm>:first-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-top:0}.prose-sm :where(.prose-sm>:last-child):not(:where([class~=not-prose],[class~=not-prose] *)){margin-bottom:0}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.invisible{visibility:hidden}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.bottom-0{bottom:0}.left-0{left:0}.left-2{left:.5rem}.left-\\[50\\%\\]{left:50%}.right-4{right:1rem}.right-6{right:1.5rem}.top-0{top:0}.top-4{top:1rem}.top-6{top:1.5rem}.top-\\[50\\%\\]{top:50%}.isolate{isolation:isolate}.z-10{z-index:10}.z-50{z-index:50}.-mx-1{margin-left:-.25rem;margin-right:-.25rem}.my-1{margin-top:.25rem;margin-bottom:.25rem}.mb-2{margin-bottom:.5rem}.ml-auto{margin-left:auto}.mt-0\\.5{margin-top:.125rem}.mt-auto{margin-top:auto}.line-clamp-1{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.grid{display:grid}.contents{display:contents}.hidden{display:none}.aspect-square{aspect-ratio:1 / 1}.size-10{width:2.5rem;height:2.5rem}.size-12{width:3rem;height:3rem}.size-16{width:4rem;height:4rem}.size-3{width:.75rem;height:.75rem}.size-3\\.5{width:.875rem;height:.875rem}.size-4{width:1rem;height:1rem}.size-6{width:1.5rem;height:1.5rem}.size-8{width:2rem;height:2rem}.size-auto{width:auto;height:auto}.size-fit{width:fit-content;height:fit-content}.size-full{width:100%;height:100%}.h-10{height:2.5rem}.h-2{height:.5rem}.h-3\\.5{height:.875rem}.h-4{height:1rem}.h-5{height:1.25rem}.h-8{height:2rem}.h-full{height:100%}.h-px{height:1px}.max-h-16{max-height:4rem}.max-h-full{max-height:100%}.min-h-12{min-height:3rem}.w-1\\/2{width:50%}.w-10{width:2.5rem}.w-2{width:.5rem}.w-3\\.5{width:.875rem}.w-4{width:1rem}.w-5\\/6{width:83.333333%}.w-60{width:15rem}.w-9{width:2.25rem}.w-auto{width:auto}.w-fit{width:fit-content}.w-full{width:100%}.min-w-56{min-width:14rem}.min-w-\\[8rem\\]{min-width:8rem}.max-w-\\[320px\\]{max-width:320px}.max-w-full{max-width:100%}.max-w-lg{max-width:32rem}.max-w-xs{max-width:20rem}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.translate-x-\\[-50\\%\\]{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-\\[var\\(--wobble-x\\)\\]{--tw-translate-x: var(--wobble-x);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-\\[-50\\%\\]{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-\\[var\\(--wobble-y\\)\\]{--tw-translate-y: var(--wobble-y);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes bounce{0%,to{transform:translateY(-25%);animation-timing-function:cubic-bezier(.8,0,1,1)}50%{transform:none;animation-timing-function:cubic-bezier(0,0,.2,1)}}.animate-bounce{animation:bounce 1s infinite}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.select-none{-webkit-user-select:none;user-select:none}.resize-none{resize:none}.resize{resize:both}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-col-reverse{flex-direction:column-reverse}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-0{gap:0px}.gap-0\\.5{gap:.125rem}.gap-1{gap:.25rem}.gap-2{gap:.5rem}.gap-4{gap:1rem}.gap-\\[1px\\]{gap:1px}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-1\\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.scroll-smooth{scroll-behavior:smooth}.text-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.break-words{overflow-wrap:break-word}.rounded-2xl{border-radius:1rem}.rounded-3xl{border-radius:1.5rem}.rounded-\\[20px\\]{border-radius:20px}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-sm{border-radius:.125rem}.rounded-xl{border-radius:.75rem}.rounded-l-md{border-top-left-radius:.375rem;border-bottom-left-radius:.375rem}.rounded-r-md{border-top-right-radius:.375rem;border-bottom-right-radius:.375rem}.rounded-bl-md{border-bottom-left-radius:.375rem}.rounded-br-md{border-bottom-right-radius:.375rem}.rounded-tl-md{border-top-left-radius:.375rem}.rounded-tr-md{border-top-right-radius:.375rem}.border{border-width:1px}.border-2{border-width:2px}.border-none{border-style:none}.border-destructive{border-color:hsl(var(--opencx-destructive))}.border-primary{border-color:hsl(var(--opencx-primary))}.border-transparent{border-color:transparent}.bg-background{background-color:hsl(var(--opencx-background))}.bg-black\\/50{background-color:#00000080}.bg-black\\/80{background-color:#000c}.bg-destructive{background-color:hsl(var(--opencx-destructive))}.bg-muted{background-color:hsl(var(--opencx-muted))}.bg-primary{background-color:hsl(var(--opencx-primary))}.bg-secondary{background-color:hsl(var(--opencx-secondary))}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity))}.fill-current{fill:currentColor}.object-contain{object-fit:contain}.object-cover{object-fit:cover}.p-0{padding:0}.p-1{padding:.25rem}.p-2{padding:.5rem}.p-4{padding:1rem}.p-6{padding:1.5rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-3\\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.py-12{padding-top:3rem;padding-bottom:3rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.pb-0{padding-bottom:0}.pl-2{padding-left:.5rem}.pl-8{padding-left:2rem}.pr-2{padding-right:.5rem}.pr-4{padding-right:1rem}.pt-0{padding-top:0}.pt-1{padding-top:.25rem}.pt-2{padding-top:.5rem}.text-center{text-align:center}.text-start{text-align:start}.align-middle{vertical-align:middle}.font-inter{font-family:Inter,Rubik,serif,sans-serif}.text-2xl{font-size:1.5rem;line-height:2rem}.text-\\[10px\\]{font-size:10px}.text-\\[16px\\]{font-size:16px}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-semibold{font-weight:600}.leading-none{line-height:1}.leading-relaxed{line-height:1.625}.leading-snug{line-height:1.375}.leading-tight{line-height:1.25}.tracking-tight{letter-spacing:-.025em}.tracking-widest{letter-spacing:.1em}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity))}.text-destructive{color:hsl(var(--opencx-destructive))}.text-destructive-foreground{color:hsl(var(--opencx-destructive-foreground))}.text-emerald-600{--tw-text-opacity: 1;color:rgb(5 150 105 / var(--tw-text-opacity))}.text-foreground{color:hsl(var(--opencx-foreground))}.text-green-500{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity))}.text-muted-foreground{color:hsl(var(--opencx-muted-foreground))}.text-muted-foreground\\/70{color:hsl(var(--opencx-muted-foreground) / .7)}.text-primary{color:hsl(var(--opencx-primary))}.text-primary-foreground{color:hsl(var(--opencx-primary-foreground))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity))}.text-secondary-foreground{color:hsl(var(--opencx-secondary-foreground))}.underline{text-decoration-line:underline}.underline-offset-4{text-underline-offset:4px}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.opacity-0{opacity:0}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-95{opacity:.95}.shadow-2xl{--tw-shadow: 0 25px 50px -12px rgb(0 0 0 / .25);--tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.outline-none{outline:2px solid transparent;outline-offset:2px}.outline{outline-style:solid}.outline-8{outline-width:8px}.outline-background{outline-color:hsl(var(--opencx-background))}.ring-0{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-offset-background{--tw-ring-offset-color: hsl(var(--opencx-background))}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur{--tw-backdrop-blur: blur(8px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-200{transition-duration:.2s}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}@keyframes enter{0%{opacity:var(--tw-enter-opacity, 1);transform:translate3d(var(--tw-enter-translate-x, 0),var(--tw-enter-translate-y, 0),0) scale3d(var(--tw-enter-scale, 1),var(--tw-enter-scale, 1),var(--tw-enter-scale, 1)) rotate(var(--tw-enter-rotate, 0))}}@keyframes exit{to{opacity:var(--tw-exit-opacity, 1);transform:translate3d(var(--tw-exit-translate-x, 0),var(--tw-exit-translate-y, 0),0) scale3d(var(--tw-exit-scale, 1),var(--tw-exit-scale, 1),var(--tw-exit-scale, 1)) rotate(var(--tw-exit-rotate, 0))}}.animate-in{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.fade-in-0{--tw-enter-opacity: 0}.zoom-in-95{--tw-enter-scale: .95}.duration-200{animation-duration:.2s}.ease-out{animation-timing-function:cubic-bezier(0,0,.2,1)}.\\[animation-delay\\:-0\\.15s\\]{animation-delay:-.15s}.\\[animation-delay\\:-0\\.3s\\]{animation-delay:-.3s}.\\[field-sizing\\:content\\;\\],.\\[field-sizing\\:content\\]{field-sizing:content}.\\[word-break\\:break-word\\]{word-break:break-word}.required:after{content:" *";color:red}.file\\:border-0::file-selector-button{border-width:0px}.file\\:bg-transparent::file-selector-button{background-color:transparent}.file\\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\\:font-medium::file-selector-button{font-weight:500}.file\\:text-primary-foreground::file-selector-button{color:hsl(var(--opencx-primary-foreground))}.placeholder\\:text-muted-foreground::placeholder{color:hsl(var(--opencx-muted-foreground))}.focus-within\\:border-primary:focus-within{border-color:hsl(var(--opencx-primary))}.hover\\:scale-\\[var\\(--scale\\)\\]:hover{--tw-scale-x: var(--scale);--tw-scale-y: var(--scale);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:border-primary:hover{border-color:hsl(var(--opencx-primary))}.hover\\:bg-green-50\\/50:hover{background-color:#f0fdf480}.hover\\:bg-red-50\\/50:hover{background-color:#fef2f280}.hover\\:bg-secondary:hover{background-color:hsl(var(--opencx-secondary))}.hover\\:text-blue-600:hover{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity))}.hover\\:text-green-500:hover{--tw-text-opacity: 1;color:rgb(34 197 94 / var(--tw-text-opacity))}.hover\\:text-primary:hover{color:hsl(var(--opencx-primary))}.hover\\:text-red-500:hover{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity))}.hover\\:underline:hover{text-decoration-line:underline}.hover\\:opacity-100:hover{opacity:1}.focus\\:bg-accent:focus{background-color:hsl(var(--opencx-accent))}.focus\\:text-accent-foreground:focus{color:hsl(var(--opencx-accent-foreground))}.focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\\:ring-ring:focus{--tw-ring-color: hsl(var(--opencx-ring))}.focus\\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.focus-visible\\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\\:ring-2:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\\:ring-ring:focus-visible{--tw-ring-color: hsl(var(--opencx-ring))}.focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width: 2px}.focus-visible\\:ring-offset-background:focus-visible{--tw-ring-offset-color: hsl(var(--opencx-background))}.active\\:scale-95:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.active\\:hover\\:scale-\\[calc\\(var\\(--scale\\)-0\\.02\\)\\]:hover:active{--tw-scale-x: calc(var(--scale) - .02);--tw-scale-y: calc(var(--scale) - .02);transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.hover\\:active\\:scale-95:active:hover{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.disabled\\:pointer-events-none:disabled{pointer-events:none}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opacity-50:disabled{opacity:.5}.group:hover .group-hover\\:opacity-100{opacity:1}.group:hover .group-hover\\:active\\:scale-90:active,.group:active .group-active\\:scale-90{--tw-scale-x: .9;--tw-scale-y: .9;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[disabled\\]\\:pointer-events-none[data-disabled]{pointer-events:none}.data-\\[state\\=checked\\]\\:translate-x-4[data-state=checked]{--tw-translate-x: 1rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[state\\=unchecked\\]\\:translate-x-0[data-state=unchecked]{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.data-\\[state\\=checked\\]\\:bg-primary[data-state=checked]{background-color:hsl(var(--opencx-primary))}.data-\\[state\\=open\\]\\:bg-accent[data-state=open]{background-color:hsl(var(--opencx-accent))}.data-\\[state\\=unchecked\\]\\:bg-input[data-state=unchecked]{background-color:hsl(var(--opencx-input))}.data-\\[state\\=open\\]\\:text-muted-foreground[data-state=open]{color:hsl(var(--opencx-muted-foreground))}.data-\\[disabled\\]\\:opacity-50[data-disabled]{opacity:.5}.data-\\[state\\=open\\]\\:animate-in[data-state=open]{animation-name:enter;animation-duration:.15s;--tw-enter-opacity: initial;--tw-enter-scale: initial;--tw-enter-rotate: initial;--tw-enter-translate-x: initial;--tw-enter-translate-y: initial}.data-\\[state\\=closed\\]\\:animate-out[data-state=closed]{animation-name:exit;animation-duration:.15s;--tw-exit-opacity: initial;--tw-exit-scale: initial;--tw-exit-rotate: initial;--tw-exit-translate-x: initial;--tw-exit-translate-y: initial}.data-\\[state\\=closed\\]\\:fade-out-0[data-state=closed]{--tw-exit-opacity: 0}.data-\\[state\\=open\\]\\:fade-in-0[data-state=open]{--tw-enter-opacity: 0}.data-\\[state\\=closed\\]\\:zoom-out-95[data-state=closed]{--tw-exit-scale: .95}.data-\\[state\\=open\\]\\:zoom-in-95[data-state=open]{--tw-enter-scale: .95}.data-\\[side\\=bottom\\]\\:slide-in-from-top-2[data-side=bottom]{--tw-enter-translate-y: -.5rem}.data-\\[side\\=left\\]\\:slide-in-from-right-2[data-side=left]{--tw-enter-translate-x: .5rem}.data-\\[side\\=right\\]\\:slide-in-from-left-2[data-side=right]{--tw-enter-translate-x: -.5rem}.data-\\[side\\=top\\]\\:slide-in-from-bottom-2[data-side=top]{--tw-enter-translate-y: .5rem}.data-\\[state\\=closed\\]\\:slide-out-to-left-1\\/2[data-state=closed]{--tw-exit-translate-x: -50%}.data-\\[state\\=closed\\]\\:slide-out-to-top-\\[48\\%\\][data-state=closed]{--tw-exit-translate-y: -48%}.data-\\[state\\=open\\]\\:slide-in-from-left-1\\/2[data-state=open]{--tw-enter-translate-x: -50%}.data-\\[state\\=open\\]\\:slide-in-from-top-\\[48\\%\\][data-state=open]{--tw-enter-translate-y: -48%}.prose-a\\:underline :is(:where(a):not(:where([class~=not-prose],[class~=not-prose] *))){text-decoration-line:underline}.prose-a\\:decoration-primary :is(:where(a):not(:where([class~=not-prose],[class~=not-prose] *))){text-decoration-color:hsl(var(--opencx-primary))}@media (min-width: 640px){.sm\\:flex-row{flex-direction:row}.sm\\:justify-end{justify-content:flex-end}.sm\\:space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.sm\\:rounded-lg{border-radius:.5rem}.sm\\:text-left{text-align:left}}.rtl\\:-scale-100:where([dir=rtl],[dir=rtl] *){--tw-scale-x: -1;--tw-scale-y: -1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rtl\\:flex-row-reverse:where([dir=rtl],[dir=rtl] *){flex-direction:row-reverse}.rtl\\:text-right:where([dir=rtl],[dir=rtl] *){text-align:right}.rtl\\:placeholder\\:text-right:where([dir=rtl],[dir=rtl] *)::placeholder{text-align:right}.\\[\\&_span\\]\\:size-1 span{width:.25rem;height:.25rem}.\\[\\&_span\\]\\:bg-secondary-foreground span{background-color:hsl(var(--opencx-secondary-foreground))}.\\[\\&_svg\\]\\:pointer-events-none svg{pointer-events:none}.\\[\\&_svg\\]\\:size-4 svg{width:1rem;height:1rem}.\\[\\&_svg\\]\\:shrink-0 svg{flex-shrink:0}.\\[\\&_svg\\]\\:text-muted-foreground\\/70 svg{color:hsl(var(--opencx-muted-foreground) / .7)}.\\[\\&_svg\\]\\:hover\\:text-primary:hover svg{color:hsl(var(--opencx-primary))}',$1=sn.Provider,J1=sn.Root,Z1=sn.Trigger,qo=ye.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(sn.Content,{ref:r,sideOffset:t,className:q("z-50 overflow-hidden max-w-xs rounded-xl bg-primary border text-primary-foreground p-2 text-center align-middle text-xs animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));qo.displayName=sn.Content.displayName;function an({children:e,content:t,side:n,align:r}){return t?f.jsxs(J1,{children:[f.jsx(Z1,{asChild:!0,children:e}),f.jsx(qo,{side:n,align:r,collisionPadding:8,avoidCollisions:!0,children:t})]}):e}const Ra=450;function Mt(){const[e,t]=X.useState(()=>(window.top||window).innerWidth<Ra);return X.useEffect(()=>{const n=window.top||window,r=()=>{t(n.innerWidth<Ra)};return r(),n.addEventListener("resize",r),()=>{n.removeEventListener("resize",r)}},[]),{isSmallScreen:e}}function fn(){var s,u,l,c,d,h,g,p,E,y,k,_,S,L,M,F,I,j,U,z,C,H,P,te,ne,K,ce,fe,Ee,Te,x,de,ve;const{isSmallScreen:e}=Mt(),{theme:t}=W.useConfig(),n=(w,Le)=>e?`100dv${w}`:Le,r={zIndex:((s=t==null?void 0:t.widgetTrigger)==null?void 0:s.zIndex)??1e7,offset:{bottom:((l=(u=t==null?void 0:t.widgetTrigger)==null?void 0:u.offset)==null?void 0:l.bottom)??20,right:((d=(c=t==null?void 0:t.widgetTrigger)==null?void 0:c.offset)==null?void 0:d.right)??20},size:{button:((g=(h=t==null?void 0:t.widgetTrigger)==null?void 0:h.size)==null?void 0:g.button)??48,icon:((E=(p=t==null?void 0:t.widgetTrigger)==null?void 0:p.size)==null?void 0:E.icon)??24}},i={palette:(t==null?void 0:t.palette)??"stone",primaryColor:(t==null?void 0:t.primaryColor)??"hsl(0 0% 9%)",widgetTrigger:r,widgetContentContainer:{borderRadius:e?"0px":((y=t==null?void 0:t.widgetContentContainer)==null?void 0:y.borderRadius)??"32px",zIndex:((k=t==null?void 0:t.widgetContentContainer)==null?void 0:k.zIndex)??r.zIndex+1,outline:((_=t==null?void 0:t.widgetContentContainer)==null?void 0:_.outline)??"none",outlineColor:((S=t==null?void 0:t.widgetContentContainer)==null?void 0:S.outlineColor)??"hsl(0 0% 50% / .5)",boxShadow:((L=t==null?void 0:t.widgetContentContainer)==null?void 0:L.boxShadow)??"0 0px 100px 0px rgb(0 0 0 / 0.25)",transitionProperty:((M=t==null?void 0:t.widgetContentContainer)==null?void 0:M.transitionProperty)??"all",transitionTimingFunction:((F=t==null?void 0:t.widgetContentContainer)==null?void 0:F.transitionTimingFunction)??"cubic-bezier(0.16, 1, 0.3, 1)",transitionDuration:((I=t==null?void 0:t.widgetContentContainer)==null?void 0:I.transitionDuration)??"800ms",offset:{side:e?0:r.offset.bottom+r.size.button+Nt.y*2+(((U=(j=t==null?void 0:t.widgetContentContainer)==null?void 0:j.offset)==null?void 0:U.side)??10),align:e?0:r.offset.right+(((C=(z=t==null?void 0:t.widgetContentContainer)==null?void 0:z.offset)==null?void 0:C.align)??0)}},screens:{welcome:{width:n("w",((P=(H=t==null?void 0:t.screens)==null?void 0:H.welcome)==null?void 0:P.width)??"375px"),minHeight:n("h",((ne=(te=t==null?void 0:t.screens)==null?void 0:te.welcome)==null?void 0:ne.minHeight)??"1px")},sessions:{width:n("w",((ce=(K=t==null?void 0:t.screens)==null?void 0:K.sessions)==null?void 0:ce.width)??"450px"),height:n("h",((Ee=(fe=t==null?void 0:t.screens)==null?void 0:fe.sessions)==null?void 0:Ee.height)??"600px")},chat:{width:n("w",((x=(Te=t==null?void 0:t.screens)==null?void 0:Te.chat)==null?void 0:x.width)??"525px"),height:n("h",((ve=(de=t==null?void 0:t.screens)==null?void 0:de.chat)==null?void 0:ve.height)??"700px")}}},a={maxHeight:n("h",`calc(
|
|
30
30
|
100vh
|
|
31
31
|
- ${i.widgetTrigger.offset.bottom}px
|
|
32
32
|
- ${i.widgetContentContainer.offset.side}px
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
${i.screens.welcome.width},
|
|
43
43
|
${i.screens.sessions.width},
|
|
44
44
|
${i.screens.chat.width}
|
|
45
|
-
)`)};return{theme:i,computed:a,cssVars:eb({palette:i.palette,primary:i.primaryColor})}}function eb({palette:e,primary:t}){const n=tb(e),r=hi(t).toHsl(),i=hi(t).isLight()?n[950]:n[50];return{"--opencx-primary":`${r.h} ${r.s*100}% ${r.l*100}%`,"--opencx-primary-foreground":i,"--opencx-background":n[100],"--opencx-foreground":n[950],"--opencx-destructive":"0 72.2% 50.6%","--opencx-destructive-foreground":n[50],"--opencx-accent":n[200],"--opencx-accent-foreground":"var(--opencx-foreground)","--opencx-secondary":n[200],"--opencx-secondary-foreground":"var(--opencx-foreground)","--opencx-muted":n[200],"--opencx-muted-foreground":n[500],"--opencx-input":n[300],"--opencx-border":n[300],"--opencx-ring":"var(--opencx-foreground)"}}function tb(e){const t={50:"0 0% 98%",100:"0 0% 96.1%",200:"0 0% 89.8%",300:"0 0% 83.1%",400:"0 0% 63.9%",500:"0 0% 45.1%",600:"0 0% 32.2%",700:"0 0% 25.1%",800:"0 0% 14.9%",900:"0 0% 9%",950:"0 0% 3.9%"},n={50:"60 9.1% 97.8%",100:"60 4.8% 95.9%",200:"20 5.9% 90%",300:"24 5.7% 82.9%",400:"24 5.4% 63.9%",500:"25 5.3% 44.7%",600:"33.3 5.5% 32.4%",700:"30 6.3% 25.1%",800:"12 6.5% 15.1%",900:"24 9.8% 10%",950:"20 14.3% 4.1%"},r={50:"0 0% 98%",100:"240 4.8% 95.9%",200:"240 5.9% 90%",300:"240 4.9% 83.9%",400:"240 5% 64.9%",500:"240 3.8% 46.1%",600:"240 5.2% 33.9%",700:"240 5.3% 26.1%",800:"240 3.7% 15.9%",900:"240 5.9% 10%",950:"240 10% 3.9%"},i={50:"210 40% 98%",100:"210 40% 96.1%",200:"214.3 31.8% 91.4%",300:"212.7 26.8% 83.9%",400:"215 20.2% 65.1%",500:"215.4 16.3% 46.9%",600:"215.3 19.3% 34.5%",700:"215.3 25% 26.7%",800:"217.2 32.6% 17.5%",900:"222.2 47.4% 11.2%",950:"222.2 84% 4.9%"};switch(e){case"neutral":return t;case"stone":return n;case"zinc":return r;case"slate":return i;default:return t}}const ii=()=>{const[e,t]=X.useState("ltr");return X.useEffect(()=>{const n=()=>{typeof document>"u"||t(window.getComputedStyle(document.body).direction)};n();const r=new MutationObserver(n);return r.observe(document.documentElement,{attributes:!0,attributeFilter:["dir"]}),r.observe(document.body,{attributes:!0,attributeFilter:["dir"]}),window.addEventListener("languagechange",n),()=>{r.disconnect(),window.removeEventListener("languagechange",n)}},[]),e},nb={ok:"حسنا",yes:"نعم",no:"لا",agree:"موافق",cancel:"إلغاء","yes-exit":"نعم، اخرج","yes-reset":"نعم، إعادة تعيين","no-cancel":"لا، إلغاء","are-you-sure":"هل أنت متأكد؟",recording:"تسجيل","thank-you":"شكرا","sorry-try-again":"عذرا، حاول مرة أخرى","error-occurred":"حدث خطأ","please-try-again":"يرجى المحاولة مرة أخرى","write-a-message":"اكتب رسالة...","send-message":"إرسال رسالة",connected:"متصل",connecting:"جاري الاتصال",reconnecting:"جاري إعادة الاتصال",reconnected:"تم إعادة الاتصال",disconnecting:"جاري قطع الاتصال",disconnected:"قطع الاتصال",error:"خطأ","persist-session":"حفظ الجلسة",settings:"إعدادات",close:"إغلاق",help:"مساعدة",chat:"محادثة",send:"إرسال",copy:"نسخ",copied:"تم النسخ","sound-effects":"التاثيرات الصوتية",language:"اللغة",select:"اختر",agent:"الوكيل",user:"المستخدم",bot:"البوت","close-widget":"إغلاق الودجة","got-any-questions":"هل لديك أي أسئلة؟ تحدث معنا!","typical-response-time":"عادة ما نرد في أقل من دقيقة واحدة","session-closed-lead":"تم حل مشكلتك!",exit:"خروج","create-new-ticket":"إنشاء تذكرة جديدة","reset-conversation":"إعادة تعيين المحادثة","new-conversation":"محادثة جديدة","welcome-title":"مرحبًا بك في دردشة الدعم الخاصة بنا","welcome-description":"نحن هنا للمساعدة! ابدأ محادثة وسنرد عليك في أقرب وقت ممكن.","your-name":"اسمك","your-email":"عنوان بريدك الإلكتروني","start-chat":"تحدث إلى الدعم","starting-chat":"جاري الاتصال...","hello-greeting":"مرحبًا! كيف يمكننا مساعدتك اليوم؟","i-need-more-help":"أحتاج المزيد من المساعدة","this-was-helpful":"كان هذا مفيدًا",optional:"اختياري","no-conversations-yet":"لا يوجد محادثات"},rb={ok:"OK",yes:"Ja",no:"Nein",agree:"Zustimmen",cancel:"Stornieren","yes-exit":"Ja, beenden","yes-reset":"Ja, zurücksetzen","no-cancel":"Nein, abbrechen","are-you-sure":"Sind Sie sicher?",recording:"Aufnahme läuft","thank-you":"Vielen Dank","sorry-try-again":"Entschuldigung, bitte versuchen Sie es erneut","error-occurred":"Ein Fehler ist aufgetreten","please-try-again":"Bitte versuchen Sie es erneut","write-a-message":"Nachricht schreiben...","send-message":"Nachricht senden",connected:"Verbunden",connecting:"Verbindung wird hergestellt",reconnecting:"Verbindung wird wiederhergestellt",reconnected:"Wieder verbunden",disconnecting:"Verbindung wird getrennt",disconnected:"Verbindung getrennt",error:"Fehler","persist-session":"Sitzung beibehalten",settings:"Einstellungen",close:"Schließen",help:"Hilfe",chat:"Chat",send:"Senden",copy:"Kopieren",copied:"Kopiert","sound-effects":"Soundeffekte",language:"Sprache",select:"Auswählen",agent:"Agent",user:"Benutzer",bot:"Bot","got-any-questions":"Haben Sie Fragen? Chatten Sie mit uns!","typical-response-time":"Üblicherweise antworten wir in weniger als 1 Minute","close-widget":"Widget schließen","session-closed-lead":"Ihr Problem wurde gelöst!","create-new-ticket":"Neues Ticket erstellen",exit:"Beenden","reset-conversation":"Konversation zurücksetzen","new-conversation":"Neue Konversation","welcome-title":"Willkommen in unserem Support-Chat","welcome-description":"Wir sind hier, um zu helfen! Beginnen Sie ein Gesprách und wir werden so schnell wie mogelijk antworten.","your-name":"Ihr Name","your-email":"Ihre E-Mail-Adresse","start-chat":"Mit dem Support sprechen","starting-chat":"Verbindung wird hergestellt...","hello-greeting":"Hallo! Wie können wir Ihnen heute helfen?","i-need-more-help":"Ich brauche weitere Hilfe","this-was-helpful":"Dies war hilfreich",optional:"Optional","no-conversations-yet":"noch keine Gespräche"},ib={ok:"OK",yes:"Yes",no:"No",agree:"Agree",cancel:"Cancel","yes-exit":"Yes, exit","yes-reset":"Yes, reset","no-cancel":"No, cancel","are-you-sure":"Are you sure?",recording:"Recording...","thank-you":"Thank you","sorry-try-again":"Sorry, please try again","error-occurred":"An error occurred","please-try-again":"Please try again","write-a-message":"Write a message...","send-message":"Send message",connected:"Connected",connecting:"Connecting",reconnecting:"Reconnecting",reconnected:"Reconnected",disconnecting:"Disconnecting",disconnected:"Disconnected",error:"Error","persist-session":"Persist session",settings:"Settings",close:"Close",help:"Help",chat:"Chat",send:"Send",copy:"Copy",copied:"Copied","sound-effects":"Sound effects",language:"Language",select:"Select",agent:"Agent",user:"User",bot:"Bot","close-widget":"Close widget","got-any-questions":"Got any questions? Chat with us!","typical-response-time":"Typically respond in less than 1 minute","session-closed-lead":"Your issue has been resolved!","create-new-ticket":"Create new ticket",exit:"Exit","reset-conversation":"Reset conversation","new-conversation":"New conversation","welcome-title":"Welcome to our support chat","welcome-description":"We're here to help! Start a conversation and we'll get back to you as soon as possible.","your-name":"Your name","your-email":"Your email address","start-chat":"Talk to support","starting-chat":"Connecting...","hello-greeting":"Hi there!","i-need-more-help":"I need more help","this-was-helpful":"This was helpful",optional:"Optional","no-conversations-yet":"No conversations yet"},ab={ok:"D'accord",yes:"Oui",no:"Non",agree:"Accepter",cancel:"Annuler","yes-exit":"Oui, quitter","yes-reset":"Oui, réinitialiser","no-cancel":"Non, annuler","are-you-sure":"Êtes-vous sûr ?",recording:"Enregistrement...","thank-you":"Merci","sorry-try-again":"Désolé, veuillez réessayer","error-occurred":"Une erreur s'est produite","please-try-again":"Veuillez réessayer","write-a-message":"Écrivez un message...","send-message":"Envoyer le message",connected:"Connecté",connecting:"Connexion en cours",reconnecting:"Reconnexion en cours",reconnected:"Reconnecté",disconnecting:"Déconnexion en cours",disconnected:"Déconnecté",error:"Erreur","persist-session":"Conserver la session",settings:"Paramètres",close:"Fermer",help:"Aide",chat:"Chat",send:"Envoyer",copy:"Copier",copied:"Copié","sound-effects":"Effets sonores",language:"Langue",select:"Sélectionner",agent:"Agent",user:"Utilisateur",bot:"Bot","close-widget":"Fermer le widget","got-any-questions":"Vous avez des questions ? Chattez avec nous !","typical-response-time":"Nous répondons généralement en moins d'une minute","session-closed-lead":"Votre problème a été résolu !","create-new-ticket":"Créer un nouveau ticket",exit:"Sortie","reset-conversation":"Réinitialiser la conversation","new-conversation":"Nouvelle conversation","welcome-title":"Bienvenue dans notre chat de support","welcome-description":"Nous sommes là pour vous aider ! Commencez une conversation et nous vous répondrons dès que possible.","your-name":"Votre nom","your-email":"Votre adresse e-mail","start-chat":"Parler au support","starting-chat":"Connexion...","hello-greeting":"Bonjour ! Comment pouvons-nous vous aider aujourd'hui ?","i-need-more-help":"Je besoin d'aide plus","this-was-helpful":"C'était utile",optional:"Optionnel","no-conversations-yet":"Aucune conversation pour le moment"},sb={ok:"OK",yes:"Ja",no:"Nee",agree:"Akkoord",cancel:"Annuleren","yes-exit":"Ja, afsluiten","yes-reset":"Ja, resetten","no-cancel":"Nee, annuleren","are-you-sure":"Weet u het zeker?",recording:"Opname...","thank-you":"Dank u","sorry-try-again":"Sorry, probeer het opnieuw","error-occurred":"Er is een fout opgetreden","please-try-again":"Probeer het opnieuw","write-a-message":"Schrijf een bericht...","send-message":"Bericht verzenden",connected:"Verbonden",connecting:"Verbinding maken",reconnecting:"Opnieuw verbinding maken",reconnected:"Opnieuw verbonden",disconnecting:"Verbinding verbreken",disconnected:"Verbinding verbroken",error:"Fout","persist-session":"Sessie behouden",settings:"Instellingen",close:"Sluiten",help:"Help",chat:"Chat",send:"Verzenden",copy:"Kopiëren",copied:"Gekopieerd","sound-effects":"Geluidseffecten",language:"Taal",select:"Selecteren",agent:"Agent",user:"Gebruiker",bot:"Bot","close-widget":"Widget sluiten","got-any-questions":"Heeft u vragen? Chat met ons!","typical-response-time":"We reageren doorgaans binnen 1 minuut","session-closed-lead":"Uw probleem is opgelost!","create-new-ticket":"Nieuw ticket aanmaken",exit:"Afsluiten","reset-conversation":"Gesprek resetten","new-conversation":"Nieuw gesprek","welcome-title":"Welkom bij onze supportchat","welcome-description":"We zijn hier om te helpen! Begin een gesprek en we nemen zo snel mogelijk contact met u op.","your-name":"Uw naam","your-email":"Uw e-mailadres","start-chat":"Praat met ondersteuning","starting-chat":"Verbinding maken...","hello-greeting":"Hallo! Hoe kunnen we u vandaag helpen?","i-need-more-help":"Ik heb nog meer hulp nodig","this-was-helpful":"Mijn vraag is opgelost",optional:"Optioneel","no-conversations-yet":"Nog geen gesprekken"},ob={ok:"OK",yes:"Sim",no:"Não",agree:"Concordo",cancel:"Cancelar","yes-exit":"Sim, sair","yes-reset":"Sim, redefinir","no-cancel":"Não, cancelar","are-you-sure":"Você tem certeza?",recording:"Gravando...","thank-you":"Obrigado","sorry-try-again":"Desculpe, tente novamente","error-occurred":"Ocorreu um erro","please-try-again":"Por favor, tente novamente","write-a-message":"Escreva uma mensagem...","send-message":"Enviar mensagem",connected:"Conectado",connecting:"Conectando",reconnecting:"Reconectando",reconnected:"Reconectado",disconnecting:"Desconectando",disconnected:"Desconectado",error:"Erro","persist-session":"Persistir sessão",settings:"Configurações",close:"Fechar",help:"Ajuda",chat:"Bate-papo",send:"Enviar",copy:"Copiar",copied:"Copiado","sound-effects":"Efeitos sonoros",language:"Idioma",select:"Selecionar",agent:"Agente",user:"Usuário",bot:"Bot","close-widget":"Fechar widget","got-any-questions":"Tem alguma dúvida? Converse conosco!","typical-response-time":"Geralmente respondemos em menos de 1 minuto","session-closed-lead":"Seu problema foi resolvido!","create-new-ticket":"Criar novo ticket",exit:"Sair","reset-conversation":"Redefinir conversa","new-conversation":"Nova conversa","welcome-title":"Bem-vindo ao nosso chat de suporte","welcome-description":"Estamos aqui para ajudar! Inicie uma conversa e responderemos o mais rápido possível.","your-name":"Seu nome","your-email":"Seu endereço de email","start-chat":"Falar com o suporte","starting-chat":"Conectando...","hello-greeting":"Olá! Como podemos ajudar você hoje?","i-need-more-help":"preciso de mais ajuda","this-was-helpful":"Isso foi útil",optional:"Opcional","no-conversations-yet":"Nenhuma conversa ainda"},Vo={en:ib,ar:nb,nl:sb,fr:ab,de:rb,pt:ob},ub=Object.keys(Vo),lb=e=>ub.includes(e);function cb(e,t){const n=Vo[t];return n&&n[e]||""}function Bt(){const{widgetCtx:{config:e}}=W.useWidget();return X.useMemo(()=>{const n=lb(e.language)?e.language:"en";return{get:r=>cb(r,n),lang:n}},[e.language])}function ai({suggestion:e,className:t,...n}){const{sendMessage:r}=W.useMessages(),i=()=>{const a=e.trim();a&&r({content:a})};return f.jsx(Oe,{...re("chat/suggested_reply_btn"),size:"sm",className:q("rounded-xl w-fit",t),...n,onClick:i,children:e})}function db(){const e=Bt(),t=[e.get("i-need-more-help"),e.get("this-was-helpful")];return f.jsx("div",{...re("chat/might_solve_user_issue_suggested_replies_container"),className:"flex items-center gap-2 p-2 pb-0 flex-wrap",children:t.map(n=>f.jsx(ai,{suggestion:n,className:"flex-1"},n))})}function hb({file:{status:e,file:t,error:n},onCancel:r}){const[i,a]=X.useState(null);X.useEffect(()=>{if(!t.type.startsWith("image/"))return;const l=new FileReader;return l.onload=()=>a(l.result),l.onerror=()=>console.error("Error reading file"),l.readAsDataURL(t),()=>l.abort()},[t]);const s=()=>{switch(e){case"uploading":return f.jsx(le.Loader2,{className:"size-4 animate-spin"});case"error":return f.jsx(le.AlertCircle,{className:"size-4 text-destructive"});default:return null}},u=()=>{const l=t.type.split("/")[0];return l==="image"&&i?f.jsx("img",{src:typeof i=="string"?i:"",className:"object-cover bg-secondary size-full",alt:t.name}):l==="audio"?f.jsx(le.FileAudio2Icon,{}):l==="video"?f.jsx(le.FileVideo2Icon,{}):f.jsx(le.FileIcon,{})};return f.jsx(an,{side:"bottom",content:e==="error"?f.jsxs("span",{className:"text-destructive",children:["Failed to upload: ",n]}):t.name,children:f.jsxs("div",{className:q(e==="uploading"&&"opacity-50","group","size-12 border rounded-2xl overflow-hidden relative","flex items-center justify-center shrink-0"),children:[f.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:s()}),f.jsx("button",{type:"button",className:q("absolute bg-black/50 inset-0 size-full z-10 opacity-0","flex items-center justify-center","opacity-0 group-hover:opacity-100 transition"),onClick:r,children:f.jsx(le.XIcon,{className:"size-4 text-primary-foreground"})}),f.jsx(u,{})]})})}function fb(){var j;const{isSmallScreen:e}=Mt(),t=X.useRef(null),{sendMessage:n}=W.useMessages(),{sessionState:r}=W.useSessions(),i=Bt(),a=ii(),[s,u]=X.useState(""),{allFiles:l,emptyTheFiles:c,handleCancelUpload:d,appendFiles:h,isUploading:g,successFiles:p}=W.useUploadFiles(),E=!!((j=r.session)!=null&&j.isHandedOff),{isAwaitingBotReply:y}=W.useIsAwaitingBotReply(),k=U=>{h(U)},_=!s.trim()&&p.length===0,S=async()=>{if(y||_)return;g&&console.info("please wait for the file(s) to upload");const U=s.trim();n({content:U,attachments:p.flatMap(z=>z.fileUrl?[{url:z.fileUrl,type:z.file.type,name:z.file.name,id:z.id,size:z.file.size}]:[])}),u(""),c()},{getRootProps:L,getInputProps:M,open:F}=fu.useDropzone({onDrop:k,noClick:!0,onDropRejected(){console.error("unsupported file type, or the file is too large")},maxSize:5*1024*1024,accept:E?{"text/*":[".txt"],"image/*":[".png",".jpg",".jpeg",".gif"],"application/pdf":[".pdf"]}:{"image/png":[".png"],"image/jpeg":[".jpg",".jpeg"],"image/gif":[".gif"],"image/webp":[".webp"]}}),I=U=>{const z=U.clipboardData;z&&z.files.length>0&&k(Array.from(z.files))};return f.jsxs("div",{...re("chat/input_box/root"),className:"p-2 relative space-y-1",...L(),children:[f.jsx("input",{...M()}),f.jsxs("div",{...re("chat/input_box/inner_root"),className:q("transition-all","bg-white","relative rounded-3xl flex flex-col gap-2 p-2","hover:border-primary focus-within:border-primary"),children:[f.jsxs("div",{...re("chat/input_box/textarea_and_attachments_container"),className:"flex flex-col gap-2",children:[l.length>0&&f.jsx("div",{...re("chat/input_box/attachments_container"),className:"flex items-center gap-1",children:f.jsx(be.AnimatePresence,{mode:"popLayout",children:l.map(U=>f.jsx(ae,{snapExit:!0,children:f.jsx(hb,{onCancel:()=>d(U.id),file:U})},U.id))})}),f.jsx("textarea",{...re("chat/input_box/textarea"),onPaste:I,ref:t,id:"chat-input",dir:a,value:s,rows:3,className:q("max-h-16 [field-sizing:content]","w-full resize-none px-2",l.length===0&&"pt-1","bg-transparent outline-none","placeholder:text-muted-foreground","rtl:placeholder:text-right",e?"text-[16px]":"text-sm"),onChange:U=>u(U.target.value),onKeyDown:async U=>{U.key==="Enter"&&!U.shiftKey&&(U.preventDefault(),S())},placeholder:i.get("write-a-message")})]}),f.jsxs("div",{dir:a,className:"gap-2 flex justify-between rtl:text-right",children:[f.jsx(an,{side:"top",align:"start",content:"attach files, (maximum size 5mb)",children:f.jsx(Oe,{onClick:F,size:"fit",variant:"ghost",className:q("rounded-full size-8 flex items-center justify-center p-0 overflow-hidden"),children:f.jsx(be.AnimatePresence,{mode:"wait",children:E?f.jsx(ae,{children:f.jsx(le.PaperclipIcon,{className:"size-4"})},"paper-clip"):f.jsx(ae,{children:f.jsx(le.ImageIcon,{className:"size-4"})},"image-icon")})})}),f.jsx(an,{content:"send message",side:"top",align:"end",children:f.jsx(Oe,{size:"fit",onClick:S,disabled:y||g||_,className:"rounded-full size-8 flex items-center justify-center p-0",children:f.jsx(be.AnimatePresence,{mode:"wait",children:y||g?f.jsx(ae,{snapExit:!0,children:f.jsx(le.CircleDashed,{className:"size-4 animate-spin animate-iteration-infinite"})},"loading"):f.jsx(ae,{snapExit:!0,children:f.jsx(le.ArrowUpIcon,{className:"size-4"})},"send")})})})]})]})]})}function pb(){const{widgetCtx:e}=W.useWidget(),t=Bt();return f.jsx("div",{className:"p-2",children:f.jsxs("div",{className:"p-2 bg-muted rounded-3xl space-y-2",children:[f.jsxs("div",{className:"pl-2 flex items-center gap-1",children:[f.jsx(le.CircleCheckIcon,{className:"size-4 text-emerald-600"}),f.jsx("h2",{className:"text-sm font-medium",dir:"auto",children:t.get("session-closed-lead")})]}),f.jsx("div",{children:f.jsx(Oe,{onClick:e.resetChat,className:"rounded-2xl w-full",children:t.get("new-conversation")})})]})})}function mb(){var a;const{initialQuestions:e,initialQuestionsPosition:t}=W.useConfig(),{sessionState:n}=W.useSessions(),{messagesState:r}=W.useMessages(),i=r.messages.length===0;return f.jsx("footer",{children:f.jsx("div",{children:f.jsx(be.AnimatePresence,{mode:"wait",children:n.session&&!((a=n.session)!=null&&a.isOpened)?f.jsx(ae,{className:"overflow-hidden",overrides:{initial:{height:0},animate:{height:"auto"},exit:{height:0}},children:f.jsx(pb,{})},"session-closed"):f.jsxs(ae,{className:"overflow-hidden",overrides:{initial:{height:0},animate:{height:"auto"},exit:{height:0}},children:[r.lastAIResMightSolveUserIssue&&f.jsx(db,{}),i&&e&&t!=="below-initial-messages"&&f.jsx("div",{className:"flex items-center flex-row justify-end gap-2 flex-wrap px-2",children:e==null?void 0:e.map((s,u)=>f.jsx(ai,{suggestion:s},`${s}-${u}`))}),f.jsx(fb,{})]},"chat-input")})})})}const gb=me.Root,bb=me.Trigger,Eb=me.Group,Tb=ye.forwardRef(({className:e,inset:t,children:n,...r},i)=>f.jsxs(me.SubTrigger,{ref:i,className:q("flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...r,children:[n,f.jsx(le.ChevronRight,{className:"ml-auto"})]}));Tb.displayName=me.SubTrigger.displayName;const xb=ye.forwardRef(({className:e,...t},n)=>f.jsx(me.SubContent,{ref:n,className:q("z-50 min-w-[8rem] overflow-hidden rounded-2xl border bg-background p-1 text-foreground shadow-2xl data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t}));xb.displayName=me.SubContent.displayName;const Go=ye.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(me.Content,{ref:r,sideOffset:t,className:q("z-50 min-w-[8rem] overflow-hidden rounded-2xl border bg-background p-1 text-foreground shadow-2xl","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));Go.displayName=me.Content.displayName;const Qo=ye.forwardRef(({className:e,inset:t,...n},r)=>f.jsx(ae,{children:f.jsx(me.Item,{ref:r,className:q("relative flex cursor-default select-none items-center gap-2 rounded-xl px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...n})}));Qo.displayName=me.Item.displayName;const wb=ye.forwardRef(({className:e,children:t,checked:n,...r},i)=>f.jsxs(me.CheckboxItem,{ref:i,className:q("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,...r,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(me.ItemIndicator,{children:f.jsx(le.Check,{className:"h-4 w-4"})})}),t]}));wb.displayName=me.CheckboxItem.displayName;const yb=ye.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(me.RadioItem,{ref:r,className:q("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(me.ItemIndicator,{children:f.jsx(le.Circle,{className:"h-2 w-2 fill-current"})})}),t]}));yb.displayName=me.RadioItem.displayName;const _b=ye.forwardRef(({className:e,inset:t,...n},r)=>f.jsx(me.Label,{ref:r,className:q("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...n}));_b.displayName=me.Label.displayName;const Ab=ye.forwardRef(({className:e,...t},n)=>f.jsx(me.Separator,{ref:n,className:q("-mx-1 my-1 h-px bg-muted",e),...t}));Ab.displayName=me.Separator.displayName;function Xo({className:e,...t}){return f.jsx("div",{className:q("animate-pulse rounded-md bg-secondary",e),...t})}function Cb(){const e=Bt(),[t,n]=X.useState(!1),{toChatScreen:r}=W.useWidgetRouter();return f.jsxs(gb,{open:t,onOpenChange:n,children:[f.jsx(bb,{asChild:!0,children:f.jsx(Oe,{variant:"ghost",size:"fit",className:"rounded-full",children:f.jsx(le.EllipsisVerticalIcon,{className:"size-4"})})}),f.jsx(Go,{align:"end",className:"min-w-56",children:f.jsx(Eb,{children:f.jsxs(Qo,{onSelect:()=>{n(!1),r()},children:[f.jsx(be.motion.div,{initial:{opacity:0,x:-4,rotate:360},animate:{opacity:1,x:0,rotate:0},children:f.jsx(le.MessageCirclePlusIcon,{})}),e.get("new-conversation")]})})})]})}function kb(){const{setIsOpen:e}=W.useWidgetTrigger(),{isSmallScreen:t}=Mt();return t?f.jsx(Oe,{variant:"ghost",size:"fit",className:"rounded-full",onClick:()=>e(!1),children:f.jsx(le.XIcon,{className:"size-4"})}):null}function Nb(){var i;const{data:e}=W.usePreludeData(),{routerState:{screen:t}}=W.useWidgetRouter(),{textContent:n}=W.useConfig();return(()=>{var a,s;switch(t){case"chat":return(a=n==null?void 0:n.chatScreen)==null?void 0:a.headerTitle;case"sessions":return(s=n==null?void 0:n.sessionsScreen)==null?void 0:s.headerTitle;case"welcome":return;default:return}})()??((i=e==null?void 0:e.data)==null?void 0:i.organizationName)??"Chat"}function Ko(){const{routerState:{screen:e},toSessionsScreen:t}=W.useWidgetRouter(),{isLoading:n}=W.usePreludeData(),r=ii(),i=(()=>{switch(e){case"chat":return re("chat/header");case"sessions":return re("sessions/header");case"welcome":return;default:return}})(),a=Nb();return f.jsx("header",{...i,className:"py-2 px-4 shrink-0",children:f.jsxs("div",{dir:r,className:"flex items-center rtl:flex-row-reverse gap-2",children:[e==="chat"&&f.jsx(Oe,{variant:"ghost",size:"fit",className:"rounded-full",onClick:t,children:f.jsx(le.ChevronLeftIcon,{className:"size-4"})}),f.jsx("div",{className:q("flex-1",e==="sessions"&&"pl-2"),children:f.jsx(be.AnimatePresence,{mode:"wait",children:n?f.jsx(ae,{snapExit:!0,children:f.jsx(Xo,{className:"h-5 w-1/2"})},"skeleton"):f.jsx(ae,{children:f.jsx("h2",{className:"font-semibold",children:a})},"organization-name")})}),f.jsx(Cb,{}),f.jsx(kb,{})]})})}function Ib({isFirstInGroup:e,isLastInGroup:t,isAloneInGroup:n,...r}){const{componentStore:i}=W.useWidget();if(r.data.action){const s=i.getComponent(r.data.action.name);if(s)return f.jsx(s,{...r,id:r.id,isFirstInGroup:e,isLastInGroup:t,isAloneInGroup:n})}const a=i.getComponent(r.component);return a?f.jsx(a,{...r,id:r.id,isFirstInGroup:e,isLastInGroup:t,isAloneInGroup:n}):f.jsx(Rn,{...r,isFirstInGroup:e,isLastInGroup:t,isAloneInGroup:n})}function Da({messages:e,agent:t,suggestedReplies:n}){return f.jsxs("div",{...re("chat/agent_msg_group/root"),className:q("flex items-end gap-2"),children:[f.jsx(an,{content:t==null?void 0:t.name,side:"right",align:"end",children:f.jsx(Lr,{...re("chat/agent_msg_group/root/avatar"),agent:t,className:"hidden"})}),f.jsxs("div",{className:q("flex-1 flex flex-col gap-2"),children:[f.jsxs("div",{...re("chat/agent_msg_group/avatar_and_msgs/root"),className:q("flex items-end gap-2"),children:[f.jsx(an,{content:t==null?void 0:t.name,side:"right",align:"end",children:f.jsx(Lr,{...re("chat/agent_msg_group/avatar_and_msgs/avatar"),agent:t})}),f.jsx("div",{...re("chat/agent_msg_group/avatar_and_msgs/msgs"),className:q("flex-1 flex flex-col gap-1"),children:e.map((r,i,a)=>f.jsx(Ib,{isFirstInGroup:i===0,isLastInGroup:i===a.length-1,isAloneInGroup:a.length===1,...r},r.id))})]}),n&&n.length>0&&f.jsx("div",{...re("chat/agent_msg_group/suggestions"),className:q("flex flex-col gap-1 pl-8"),children:n==null?void 0:n.map((r,i)=>f.jsx(ai,{suggestion:r},`${r}-${i}`))})]})]})}function Sb({message:e,isFirstInGroup:t,isLastInGroup:n,isAloneInGroup:r}){var i;return f.jsxs("div",{...re("chat/user_msg/root"),className:"w-5/6 flex flex-col items-end gap-1",children:[e.attachments&&e.attachments.length>0&&f.jsx("div",{className:"w-full flex gap-1 flex-wrap justify-end",children:(i=e.attachments)==null?void 0:i.map(a=>f.jsx(Yo,{attachment:a},a.id))}),e.content.length>0&&f.jsx("div",{...re("chat/user_msg/msg"),"data-first":t,"data-last":n,"data-alone":r,className:q("transition-all","w-fit py-3 px-4 rounded-3xl text-sm","bg-primary text-primary-foreground","break-words [word-break:break-word]","whitespace-pre-wrap",t&&!r&&"rounded-br-md",n&&!r&&"rounded-tr-md",!t&&!n&&!r&&"rounded-r-md"),children:e.content})]})}function Ob({messages:e}){return f.jsx("div",{...re("chat/user_msg_group/root"),className:q("group","flex flex-col gap-1 justify-end items-end"),children:e.map((t,n,r)=>f.jsx(Sb,{message:t,isFirstInGroup:n===0,isLastInGroup:n===r.length-1,isAloneInGroup:r.length===1},t.id))})}function Lb(e){const t=[];let n=null;return e.forEach(r=>{var i,a,s,u;(!n||((i=n[0])==null?void 0:i.type)!==r.type)&&(n=[],t.push(n)),((a=n[0])==null?void 0:a.type)==="FROM_AGENT"&&r.type==="FROM_AGENT"&&((s=r.agent)==null?void 0:s.id)!==((u=n[0].agent)==null?void 0:u.id)&&(n=[],t.push(n)),n.push(r)}),t}function Rb(e){var t;return((t=e==null?void 0:e[0])==null?void 0:t.type)==="FROM_USER"}function Db(e){var t;return((t=e==null?void 0:e[0])==null?void 0:t.type)==="FROM_BOT"}function vb(e){var t;return((t=e==null?void 0:e[0])==null?void 0:t.type)==="FROM_AGENT"}function Pb(){const{messagesState:{messages:e}}=W.useMessages(),{isAwaitingBotReply:t}=W.useIsAwaitingBotReply(),{componentStore:n}=W.useWidget(),r=W.useConfig(),{initialQuestions:i,initialQuestionsPosition:a}=r,s=X.useMemo(()=>Lb(e),[e]),u=r.persistentInitialMessages||[],l=!r.initialMessages||r.initialMessages.length===0?["Hello, how can I help you?"]:r.initialMessages,c=n.getComponent("loading"),d=X.useRef(null);function h(){setTimeout(()=>{const g=d.current;g&&(g.scrollTop=g.scrollHeight)},0)}return X.useEffect(()=>{h()},[e]),f.jsxs("div",{...re("chat/msgs/root"),ref:d,className:"max-h-full scroll-smooth relative flex-1 py-2 px-4 flex flex-col gap-2 overflow-auto",children:[f.jsx("div",{...re("chat/persistent_initial_msgs/root"),children:u.map((g,p,E)=>f.jsx(Rn,{component:"bot_message",data:{message:g},id:g,type:"FROM_BOT",timestamp:Date.now().toString(),dataComponentNames:{messageContainer:"chat/persistent_initial_msg/root",message:"chat/persistent_initial_msg/msg"},classNames:{messageContainer:q("w-full flex flex-col items-center text-center"),message:"w-full bg-transparent border-none shadow-none text-xs"},isFirstInGroup:p===0,isLastInGroup:p===E.length-1,isAloneInGroup:E.length===1},`${g}-${p}`))}),e.length===0&&f.jsx(Da,{messages:l.map((g,p)=>({component:"bot_message",data:{message:g},id:`${g}-${p}`,type:"FROM_BOT",timestamp:Date.now().toString()})),suggestedReplies:a==="below-initial-messages"?i:void 0,agent:r.bot?{...r.bot,isAi:!0,id:null}:void 0}),s.map(g=>{var y,k,_;const p=(y=g==null?void 0:g[0])==null?void 0:y.type,E=(k=g[0])==null?void 0:k.id;if(!p||!E)return null;if(Rb(g))return f.jsx(Ob,{messages:g},E);if(Db(g)||vb(g)){const S=(_=g[0])==null?void 0:_.agent;return f.jsx(Da,{messages:g,agent:S},E)}return null}),t&&c&&f.jsx(c,{agent:r.bot})]})}function $o({className:e}){return f.jsx(le.LoaderIcon,{className:q("size-4 animate-spin",e)})}function si({width:e,height:t}){const{isSmallScreen:n}=Mt(),{contentIframeRef:r}=W.useWidget();X.useEffect(()=>{var i,a;e&&((i=r==null?void 0:r.current)==null||i.style.setProperty("--opencx-widget-width",e)),t&&((a=r==null?void 0:r.current)==null||a.style.setProperty("--opencx-widget-height",t))},[n,t,e,r])}function Mb(){const{messagesState:{isInitialFetchLoading:e}}=W.useMessages(),{sessionState:{session:t}}=W.useSessions(),{theme:n}=fn();si({width:n.screens.chat.width,height:n.screens.chat.height});const r=X.useRef((t==null?void 0:t.id)||"chat").current;return f.jsx("div",{...re("chat/root"),className:q("flex flex-col overflow-hidden"),style:{width:"100vw",maxWidth:"100vw",height:"100vh",maxHeight:"100vh"},children:f.jsxs("div",{className:"size-full justify-between flex flex-col",children:[f.jsx(Ko,{}),f.jsx(be.AnimatePresence,{mode:"wait",children:e?f.jsx(ae,{className:"flex flex-col items-center justify-center w-full flex-1",children:f.jsx($o,{})},"loading"):f.jsxs(ae,{className:"flex flex-col w-full flex-1 overflow-auto",snapExit:!0,children:[f.jsx(Pb,{}),f.jsx(mb,{})]},r)})]})})}const An=ye.forwardRef(({className:e,type:t,...n},r)=>{const{isSmallScreen:i}=Mt(),a=ii();return f.jsx($e,{ref:r,children:f.jsx("input",{dir:a,type:t,className:q(i?"text-[16px]":"text-sm","flex w-full rounded-xl p-2 ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-primary-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 transition","rtl:placeholder:text-right","bg-white","rounded-3xl px-4",e),...n})})});An.displayName="Input";function Bb({className:e}){return f.jsx("svg",{width:"26",height:"32",viewBox:"0 0 26 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:q("text-primary-foreground",e),children:f.jsx("path",{d:"M1.34103 25.6132H5.44245C5.74203 25.6228 6.02673 25.7462 6.23867 25.9582C6.45062 26.1703 6.5739 26.4551 6.58348 26.7548V30.8584C6.59305 31.1581 6.71634 31.443 6.92828 31.655C7.14023 31.8671 7.42492 31.9904 7.7245 32H18.2894C18.589 31.9904 18.8737 31.8671 19.0856 31.655C19.2976 31.443 19.4209 31.1581 19.4304 30.8584V26.7548C19.4401 26.4545 19.5638 26.1692 19.7765 25.957C19.9892 25.7449 20.2748 25.6219 20.5749 25.6132H24.659C24.9586 25.6036 25.2433 25.4803 25.4552 25.2682C25.6671 25.0562 25.7904 24.7713 25.8 24.4716V7.52839C25.7904 7.22865 25.6671 6.94381 25.4552 6.73176C25.2433 6.5197 24.9586 6.39635 24.659 6.38677H20.561C20.2603 6.37802 19.9742 6.25457 19.7614 6.04169C19.5487 5.82881 19.4253 5.54261 19.4165 5.24168V1.14161C19.4072 0.84419 19.2858 0.561291 19.0768 0.349589C18.8678 0.137887 18.5865 0.0130193 18.2894 0L7.7245 0C7.42492 0.00957792 7.14023 0.132929 6.92828 0.344983C6.71634 0.557036 6.59305 0.841878 6.58348 1.14161V5.24168C6.57477 5.54203 6.45187 5.82773 6.23983 6.04052C6.0278 6.25331 5.74262 6.37715 5.44245 6.38677H1.34103C1.04144 6.39635 0.756749 6.5197 0.544805 6.73176C0.332861 6.94381 0.209574 7.22865 0.200001 7.52839V24.4716C0.209574 24.7713 0.332861 25.0562 0.544805 25.2682C0.756749 25.4803 1.04144 25.6036 1.34103 25.6132ZM6.58348 24.4716V7.52839C6.59305 7.22865 6.71634 6.94381 6.92828 6.73176C7.14023 6.5197 7.42492 6.39635 7.7245 6.38677H18.2894C18.589 6.39635 18.8737 6.5197 19.0856 6.73176C19.2976 6.94381 19.4209 7.22865 19.4304 7.52839V24.4716C19.4209 24.7713 19.2976 25.0562 19.0856 25.2682C18.8737 25.4803 18.589 25.6036 18.2894 25.6132H7.7245C7.42492 25.6036 7.14023 25.4803 6.92828 25.2682C6.71634 25.0562 6.59305 24.7713 6.58348 24.4716Z",fill:"currentColor"})})}function Jo({className:e}){const{token:t}=W.useConfig();return f.jsx("div",{className:q("flex items-center justify-center gap-2 p-2 pt-0 bg-background",e),children:f.jsx($e,{children:f.jsxs("a",{href:`https://open.cx/?ref=${t}`,target:"_blank",rel:"noreferrer",className:q("text-[10px] flex items-center","text-muted-foreground/70 [&_svg]:text-muted-foreground/70","hover:text-primary [&_svg]:hover:text-primary"),children:[f.jsx("span",{children:"Powered by"}),f.jsx("span",{children:" "}),f.jsxs("span",{className:"flex items-center gap-[1px]",children:[f.jsx("span",{children:f.jsx(Bb,{className:"size-3 inline-block"})}),f.jsx("span",{className:"font-semibold",children:"open"})]})]})})})}function Fb(){const{contentIframeRef:e}=W.useWidget(),t=X.useRef(null);return X.useEffect(()=>{const n=e==null?void 0:e.current;if(n&&t.current){const r=t.current;let i;const a=new ResizeObserver(()=>{i=requestAnimationFrame(()=>{const s=r.offsetHeight;n.style.setProperty("--opencx-widget-height",`${s.toFixed(1)}px`)})});return a.observe(r),()=>{cancelAnimationFrame(i),a.unobserve(r)}}},[e]),{observedElementRef:t}}const Hb=Gn.z.object({name:Gn.z.string().min(2),email:Gn.z.string().email()});function Ub(){var _,S,L,M,F,I,j,U,z;const{setIsOpen:e}=W.useWidgetTrigger(),{createUnverifiedContact:t}=W.useContact(),{isSmallScreen:n}=Mt(),r=W.useConfig(),{theme:i}=fn(),a=Bt(),{data:s}=W.usePreludeData(),{observedElementRef:u}=Fb();si({height:void 0,width:i.screens.welcome.width});const[l,c]=X.useState(((_=r.prefillUserData)==null?void 0:_.name)||""),[d,h]=X.useState(((S=r.prefillUserData)==null?void 0:S.email)||""),g=(r.extraDataCollectionFields||[]).filter(C=>C!=="name"&&C!=="email"&&!!C),[p,E]=X.useState({}),[y,k]=W._default(async C=>{C.preventDefault();const H=Hb.safeParse({name:l,email:d});H.success&&await t({email:H.data.email,non_verified_name:H.data.name},Object.values(p).filter(Boolean).length?p:void 0)},[l,d,p]);return f.jsx("div",{style:{width:"100vw",maxWidth:"100vw",minHeight:i.screens.welcome.minHeight,height:"100vh",maxHeight:"100vh",overflowY:"auto"},children:f.jsxs("div",{ref:u,className:q("flex flex-col",n&&"h-full"),children:[f.jsxs("div",{dir:"auto",className:"flex-1 flex flex-col px-4 py-12 text-start space-y-4 relative z-10",children:[n&&f.jsx(ae,{className:"absolute top-6 right-6",children:f.jsx(Oe,{size:"selfless",onClick:()=>e(!1),children:f.jsx(le.XIcon,{className:"size-4"})})}),f.jsx("div",{className:"flex items-center justify-between w-full mb-2",children:(L=r.assets)!=null&&L.organizationLogo?f.jsx("img",{src:(M=r.assets)==null?void 0:M.organizationLogo,alt:"Company Logo",className:"h-8 w-auto object-contain"}):f.jsx("h2",{className:"font-bold text-xl",dir:"auto",children:(F=s==null?void 0:s.data)==null?void 0:F.organizationName})}),f.jsxs("div",{className:"space-y-2",children:[f.jsx("h1",{className:"text-2xl font-bold",dir:"auto",children:((j=(I=r.textContent)==null?void 0:I.welcomeScreen)==null?void 0:j.title)||a.get("welcome-title")}),f.jsx("p",{className:"/90 text-sm max-w-[320px] leading-relaxed",dir:"auto",children:((z=(U=r.textContent)==null?void 0:U.welcomeScreen)==null?void 0:z.description)||a.get("welcome-description")})]})]}),f.jsxs("div",{className:"z-10 px-2 pt-2 bp-0 bg-background space-y-2",dir:"auto",children:[f.jsxs("form",{onSubmit:k,className:"space-y-2",children:[f.jsxs("div",{className:"space-y-2",children:[f.jsx(An,{value:l,onChange:C=>c(C.target.value),required:!0,placeholder:a.get("your-name"),name:"name"}),f.jsx(An,{required:!0,value:d,onChange:C=>h(C.target.value),type:"email",placeholder:a.get("your-email"),name:"email"}),g.map(C=>f.jsx(An,{value:p[C],onChange:H=>E(P=>({...P,[C]:H.target.value})),placeholder:`${C} (${a.get("optional")})`},C))]}),f.jsxs(Oe,{disabled:y.loading,className:"w-full rounded-3xl",size:"lg",children:[y.loading?a.get("starting-chat"):a.get("start-chat"),f.jsx(le.SendHorizontal,{className:"size-4 rtl:-scale-100"})]})]}),f.jsx(Jo,{})]})]})})}function zb({session:e}){const{bot:t}=W.useConfig(),{toChatScreen:n}=W.useWidgetRouter(),r=e.assignee.kind==="human"?e.assignee.name||"Support Agent":(t==null?void 0:t.name)||"AI Support Agent",i=e.assignee.kind==="human"?e.assignee.avatarUrl||"":(t==null?void 0:t.avatar)||"";return f.jsxs(Oe,{variant:"ghost",size:"lg",className:"rounded-full p-2 pr-4 flex text-start justify-between w-full whitespace-normal",onClick:()=>n(e.id),children:[f.jsxs("div",{className:"flex-1 flex gap-2 items-center",children:[f.jsx(be.AnimatePresence,{mode:"wait",children:f.jsx(ae,{snapExit:!0,children:f.jsxs(ti,{className:"size-10",children:[f.jsx(ni,{src:i,alt:"Agent Icon"}),f.jsx(ri,{children:f.jsx(le.UserRoundIcon,{className:"size-4"})})]})})}),f.jsxs("div",{className:"flex-1",children:[f.jsx(be.AnimatePresence,{mode:"wait",children:f.jsx(ae,{snapExit:!0,children:r},r)}),f.jsx(be.AnimatePresence,{mode:"wait",children:e.lastMessage?f.jsx(ae,{snapExit:!0,children:f.jsx(Ws,{remarkPlugins:[gs],rehypePlugins:[Oo],className:"line-clamp-1 overflow-hidden text-ellipsis text-xs text-muted-foreground",children:e.lastMessage})},e.lastMessage||"content"):f.jsx(ae,{className:"w-1/2",snapExit:!0,children:f.jsx(Xo,{className:"h-4 w-full"})},"skeleton")})]})]}),f.jsx(le.ChevronRightIcon,{className:"size-4 text-muted-foreground shrink-0"})]})}function jb(){const e=Bt(),{toChatScreen:t}=W.useWidgetRouter(),{sessionsState:{data:n,isInitialFetchLoading:r}}=W.useSessions();return f.jsx("div",{className:"flex-1 flex flex-col overflow-scroll py-2 px-2",children:f.jsx(be.AnimatePresence,{mode:"wait",children:r?f.jsx(ae,{className:"flex-1 flex items-center justify-center",children:f.jsx($o,{})},"loading"):f.jsx(ae,{className:"flex-1 flex flex-col gap-2 relative",children:n.length?f.jsxs(f.Fragment,{children:[f.jsx(be.AnimatePresence,{children:n.map((i,a)=>f.jsx(ae,{snapExit:!0,children:f.jsx(zb,{session:i})},`${i.id}-${a}`))}),f.jsx("div",{className:"mt-auto w-full rounded-3xl sticky bottom-0 outline outline-8 outline-background bg-background",children:X.createElement(Oe,{...re("sessions/new_conversation_btn"),size:"lg",key:"new-session",className:"w-full rounded-3xl",onClick:()=>t()},e.get("new-conversation"))})]}):f.jsxs("div",{className:"flex-1 flex flex-col gap-2 items-center",children:[f.jsx("div",{className:"flex-1 flex items-center justify-center",children:f.jsx("p",{className:"text-muted-foreground",children:e.get("no-conversations-yet")})}),X.createElement(Oe,{...re("sessions/new_conversation_btn"),size:"lg",key:"new-session",className:"w-full rounded-3xl",onClick:()=>t()},e.get("new-conversation"))]})},"sessions")})})}function Yb(){const{theme:e}=fn();return si({width:e.screens.sessions.width,height:e.screens.sessions.height}),f.jsxs("div",{...re("sessions/root"),className:q("flex flex-col overflow-hidden bg-background"),style:{width:"100vw",maxWidth:"100vw",height:"100vh",maxHeight:"100vh"},children:[f.jsxs("div",{className:"size-full flex flex-col",children:[f.jsx(Ko,{}),f.jsx(jb,{})]}),f.jsx(Jo,{})]})}function Wb(){W.usePreludeData();const{routerState:{screen:e}}=W.useWidgetRouter();return f.jsxs("div",{className:"relative bg-background size-full",children:[f.jsx(Vn.Container,{}),f.jsx(be.AnimatePresence,{mode:"wait",children:(()=>{switch(e){case"welcome":return f.jsx(ae,{fadeIn:"right",className:"size-full",snapExit:!0,children:f.jsx(Ub,{})},e);case"sessions":return f.jsx(ae,{fadeIn:"right",className:"size-full",snapExit:!0,children:f.jsx(Yb,{})},e);case"chat":return f.jsx(ae,{fadeIn:"right",className:"size-full",snapExit:!0,children:f.jsx(Mb,{})},e);default:return null}})()})]})}const qb=`<!DOCTYPE html>
|
|
45
|
+
)`)};return{theme:i,computed:a,cssVars:eb({palette:i.palette,primary:i.primaryColor})}}function eb({palette:e,primary:t}){const n=tb(e),r=hi(t).toHsl(),i=hi(t).isLight()?n[950]:n[50];return{"--opencx-primary":`${r.h} ${r.s*100}% ${r.l*100}%`,"--opencx-primary-foreground":i,"--opencx-background":n[100],"--opencx-foreground":n[950],"--opencx-destructive":"0 72.2% 50.6%","--opencx-destructive-foreground":n[50],"--opencx-accent":n[200],"--opencx-accent-foreground":"var(--opencx-foreground)","--opencx-secondary":n[200],"--opencx-secondary-foreground":"var(--opencx-foreground)","--opencx-muted":n[200],"--opencx-muted-foreground":n[500],"--opencx-input":n[300],"--opencx-border":n[300],"--opencx-ring":"var(--opencx-foreground)"}}function tb(e){const t={50:"0 0% 98%",100:"0 0% 96.1%",200:"0 0% 89.8%",300:"0 0% 83.1%",400:"0 0% 63.9%",500:"0 0% 45.1%",600:"0 0% 32.2%",700:"0 0% 25.1%",800:"0 0% 14.9%",900:"0 0% 9%",950:"0 0% 3.9%"},n={50:"60 9.1% 97.8%",100:"60 4.8% 95.9%",200:"20 5.9% 90%",300:"24 5.7% 82.9%",400:"24 5.4% 63.9%",500:"25 5.3% 44.7%",600:"33.3 5.5% 32.4%",700:"30 6.3% 25.1%",800:"12 6.5% 15.1%",900:"24 9.8% 10%",950:"20 14.3% 4.1%"},r={50:"0 0% 98%",100:"240 4.8% 95.9%",200:"240 5.9% 90%",300:"240 4.9% 83.9%",400:"240 5% 64.9%",500:"240 3.8% 46.1%",600:"240 5.2% 33.9%",700:"240 5.3% 26.1%",800:"240 3.7% 15.9%",900:"240 5.9% 10%",950:"240 10% 3.9%"},i={50:"210 40% 98%",100:"210 40% 96.1%",200:"214.3 31.8% 91.4%",300:"212.7 26.8% 83.9%",400:"215 20.2% 65.1%",500:"215.4 16.3% 46.9%",600:"215.3 19.3% 34.5%",700:"215.3 25% 26.7%",800:"217.2 32.6% 17.5%",900:"222.2 47.4% 11.2%",950:"222.2 84% 4.9%"};switch(e){case"neutral":return t;case"stone":return n;case"zinc":return r;case"slate":return i;default:return t}}const ii=()=>{const[e,t]=X.useState("ltr");return X.useEffect(()=>{const n=()=>{typeof document>"u"||t(window.getComputedStyle(document.body).direction)};n();const r=new MutationObserver(n);return r.observe(document.documentElement,{attributes:!0,attributeFilter:["dir"]}),r.observe(document.body,{attributes:!0,attributeFilter:["dir"]}),window.addEventListener("languagechange",n),()=>{r.disconnect(),window.removeEventListener("languagechange",n)}},[]),e},nb={ok:"حسنا",yes:"نعم",no:"لا",agree:"موافق",cancel:"إلغاء","yes-exit":"نعم، اخرج","yes-reset":"نعم، إعادة تعيين","no-cancel":"لا، إلغاء","are-you-sure":"هل أنت متأكد؟",recording:"تسجيل","thank-you":"شكرا","sorry-try-again":"عذرا، حاول مرة أخرى","error-occurred":"حدث خطأ","please-try-again":"يرجى المحاولة مرة أخرى","write-a-message":"اكتب رسالة...","send-message":"إرسال رسالة",connected:"متصل",connecting:"جاري الاتصال",reconnecting:"جاري إعادة الاتصال",reconnected:"تم إعادة الاتصال",disconnecting:"جاري قطع الاتصال",disconnected:"قطع الاتصال",error:"خطأ","persist-session":"حفظ الجلسة",settings:"إعدادات",close:"إغلاق",help:"مساعدة",chat:"محادثة",send:"إرسال",copy:"نسخ",copied:"تم النسخ","sound-effects":"التاثيرات الصوتية",language:"اللغة",select:"اختر",agent:"الوكيل",user:"المستخدم",bot:"البوت","close-widget":"إغلاق الودجة","got-any-questions":"هل لديك أي أسئلة؟ تحدث معنا!","typical-response-time":"عادة ما نرد في أقل من دقيقة واحدة","session-closed-lead":"تم حل مشكلتك!",exit:"خروج","create-new-ticket":"إنشاء تذكرة جديدة","reset-conversation":"إعادة تعيين المحادثة","new-conversation":"محادثة جديدة","welcome-title":"مرحبًا بك في دردشة الدعم الخاصة بنا","welcome-description":"نحن هنا للمساعدة! ابدأ محادثة وسنرد عليك في أقرب وقت ممكن.","your-name":"اسمك","your-email":"عنوان بريدك الإلكتروني","start-chat":"تحدث إلى الدعم","starting-chat":"جاري الاتصال...","hello-greeting":"مرحبًا! كيف يمكننا مساعدتك اليوم؟","i-need-more-help":"أحتاج المزيد من المساعدة","this-was-helpful":"كان هذا مفيدًا",optional:"اختياري","no-conversations-yet":"لا يوجد محادثات"},rb={ok:"OK",yes:"Ja",no:"Nein",agree:"Zustimmen",cancel:"Stornieren","yes-exit":"Ja, beenden","yes-reset":"Ja, zurücksetzen","no-cancel":"Nein, abbrechen","are-you-sure":"Sind Sie sicher?",recording:"Aufnahme läuft","thank-you":"Vielen Dank","sorry-try-again":"Entschuldigung, bitte versuchen Sie es erneut","error-occurred":"Ein Fehler ist aufgetreten","please-try-again":"Bitte versuchen Sie es erneut","write-a-message":"Nachricht schreiben...","send-message":"Nachricht senden",connected:"Verbunden",connecting:"Verbindung wird hergestellt",reconnecting:"Verbindung wird wiederhergestellt",reconnected:"Wieder verbunden",disconnecting:"Verbindung wird getrennt",disconnected:"Verbindung getrennt",error:"Fehler","persist-session":"Sitzung beibehalten",settings:"Einstellungen",close:"Schließen",help:"Hilfe",chat:"Chat",send:"Senden",copy:"Kopieren",copied:"Kopiert","sound-effects":"Soundeffekte",language:"Sprache",select:"Auswählen",agent:"Agent",user:"Benutzer",bot:"Bot","got-any-questions":"Haben Sie Fragen? Chatten Sie mit uns!","typical-response-time":"Üblicherweise antworten wir in weniger als 1 Minute","close-widget":"Widget schließen","session-closed-lead":"Ihr Problem wurde gelöst!","create-new-ticket":"Neues Ticket erstellen",exit:"Beenden","reset-conversation":"Konversation zurücksetzen","new-conversation":"Neue Konversation","welcome-title":"Willkommen in unserem Support-Chat","welcome-description":"Wir sind hier, um zu helfen! Beginnen Sie ein Gesprách und wir werden so schnell wie mogelijk antworten.","your-name":"Ihr Name","your-email":"Ihre E-Mail-Adresse","start-chat":"Mit dem Support sprechen","starting-chat":"Verbindung wird hergestellt...","hello-greeting":"Hallo! Wie können wir Ihnen heute helfen?","i-need-more-help":"Ich brauche weitere Hilfe","this-was-helpful":"Dies war hilfreich",optional:"Optional","no-conversations-yet":"noch keine Gespräche"},ib={ok:"OK",yes:"Yes",no:"No",agree:"Agree",cancel:"Cancel","yes-exit":"Yes, exit","yes-reset":"Yes, reset","no-cancel":"No, cancel","are-you-sure":"Are you sure?",recording:"Recording...","thank-you":"Thank you","sorry-try-again":"Sorry, please try again","error-occurred":"An error occurred","please-try-again":"Please try again","write-a-message":"Write a message...","send-message":"Send message",connected:"Connected",connecting:"Connecting",reconnecting:"Reconnecting",reconnected:"Reconnected",disconnecting:"Disconnecting",disconnected:"Disconnected",error:"Error","persist-session":"Persist session",settings:"Settings",close:"Close",help:"Help",chat:"Chat",send:"Send",copy:"Copy",copied:"Copied","sound-effects":"Sound effects",language:"Language",select:"Select",agent:"Agent",user:"User",bot:"Bot","close-widget":"Close widget","got-any-questions":"Got any questions? Chat with us!","typical-response-time":"Typically respond in less than 1 minute","session-closed-lead":"Your issue has been resolved!","create-new-ticket":"Create new ticket",exit:"Exit","reset-conversation":"Reset conversation","new-conversation":"New conversation","welcome-title":"Welcome to our support chat","welcome-description":"We're here to help! Start a conversation and we'll get back to you as soon as possible.","your-name":"Your name","your-email":"Your email address","start-chat":"Talk to support","starting-chat":"Connecting...","hello-greeting":"Hi there!","i-need-more-help":"I need more help","this-was-helpful":"This was helpful",optional:"Optional","no-conversations-yet":"No conversations yet"},ab={ok:"D'accord",yes:"Oui",no:"Non",agree:"Accepter",cancel:"Annuler","yes-exit":"Oui, quitter","yes-reset":"Oui, réinitialiser","no-cancel":"Non, annuler","are-you-sure":"Êtes-vous sûr ?",recording:"Enregistrement...","thank-you":"Merci","sorry-try-again":"Désolé, veuillez réessayer","error-occurred":"Une erreur s'est produite","please-try-again":"Veuillez réessayer","write-a-message":"Écrivez un message...","send-message":"Envoyer le message",connected:"Connecté",connecting:"Connexion en cours",reconnecting:"Reconnexion en cours",reconnected:"Reconnecté",disconnecting:"Déconnexion en cours",disconnected:"Déconnecté",error:"Erreur","persist-session":"Conserver la session",settings:"Paramètres",close:"Fermer",help:"Aide",chat:"Chat",send:"Envoyer",copy:"Copier",copied:"Copié","sound-effects":"Effets sonores",language:"Langue",select:"Sélectionner",agent:"Agent",user:"Utilisateur",bot:"Bot","close-widget":"Fermer le widget","got-any-questions":"Vous avez des questions ? Chattez avec nous !","typical-response-time":"Nous répondons généralement en moins d'une minute","session-closed-lead":"Votre problème a été résolu !","create-new-ticket":"Créer un nouveau ticket",exit:"Sortie","reset-conversation":"Réinitialiser la conversation","new-conversation":"Nouvelle conversation","welcome-title":"Bienvenue dans notre chat de support","welcome-description":"Nous sommes là pour vous aider ! Commencez une conversation et nous vous répondrons dès que possible.","your-name":"Votre nom","your-email":"Votre adresse e-mail","start-chat":"Parler au support","starting-chat":"Connexion...","hello-greeting":"Bonjour ! Comment pouvons-nous vous aider aujourd'hui ?","i-need-more-help":"Je besoin d'aide plus","this-was-helpful":"C'était utile",optional:"Optionnel","no-conversations-yet":"Aucune conversation pour le moment"},sb={ok:"OK",yes:"Ja",no:"Nee",agree:"Akkoord",cancel:"Annuleren","yes-exit":"Ja, afsluiten","yes-reset":"Ja, resetten","no-cancel":"Nee, annuleren","are-you-sure":"Weet u het zeker?",recording:"Opname...","thank-you":"Dank u","sorry-try-again":"Sorry, probeer het opnieuw","error-occurred":"Er is een fout opgetreden","please-try-again":"Probeer het opnieuw","write-a-message":"Schrijf een bericht...","send-message":"Bericht verzenden",connected:"Verbonden",connecting:"Verbinding maken",reconnecting:"Opnieuw verbinding maken",reconnected:"Opnieuw verbonden",disconnecting:"Verbinding verbreken",disconnected:"Verbinding verbroken",error:"Fout","persist-session":"Sessie behouden",settings:"Instellingen",close:"Sluiten",help:"Help",chat:"Chat",send:"Verzenden",copy:"Kopiëren",copied:"Gekopieerd","sound-effects":"Geluidseffecten",language:"Taal",select:"Selecteren",agent:"Agent",user:"Gebruiker",bot:"Bot","close-widget":"Widget sluiten","got-any-questions":"Heeft u vragen? Chat met ons!","typical-response-time":"We reageren doorgaans binnen 1 minuut","session-closed-lead":"Uw probleem is opgelost!","create-new-ticket":"Nieuw ticket aanmaken",exit:"Afsluiten","reset-conversation":"Gesprek resetten","new-conversation":"Nieuw gesprek","welcome-title":"Welkom bij onze supportchat","welcome-description":"We zijn hier om te helpen! Begin een gesprek en we nemen zo snel mogelijk contact met u op.","your-name":"Uw naam","your-email":"Uw e-mailadres","start-chat":"Praat met ondersteuning","starting-chat":"Verbinding maken...","hello-greeting":"Hallo! Hoe kunnen we u vandaag helpen?","i-need-more-help":"Ik heb nog meer hulp nodig","this-was-helpful":"Mijn vraag is opgelost",optional:"Optioneel","no-conversations-yet":"Nog geen gesprekken"},ob={ok:"OK",yes:"Sim",no:"Não",agree:"Concordo",cancel:"Cancelar","yes-exit":"Sim, sair","yes-reset":"Sim, redefinir","no-cancel":"Não, cancelar","are-you-sure":"Você tem certeza?",recording:"Gravando...","thank-you":"Obrigado","sorry-try-again":"Desculpe, tente novamente","error-occurred":"Ocorreu um erro","please-try-again":"Por favor, tente novamente","write-a-message":"Escreva uma mensagem...","send-message":"Enviar mensagem",connected:"Conectado",connecting:"Conectando",reconnecting:"Reconectando",reconnected:"Reconectado",disconnecting:"Desconectando",disconnected:"Desconectado",error:"Erro","persist-session":"Persistir sessão",settings:"Configurações",close:"Fechar",help:"Ajuda",chat:"Bate-papo",send:"Enviar",copy:"Copiar",copied:"Copiado","sound-effects":"Efeitos sonoros",language:"Idioma",select:"Selecionar",agent:"Agente",user:"Usuário",bot:"Bot","close-widget":"Fechar widget","got-any-questions":"Tem alguma dúvida? Converse conosco!","typical-response-time":"Geralmente respondemos em menos de 1 minuto","session-closed-lead":"Seu problema foi resolvido!","create-new-ticket":"Criar novo ticket",exit:"Sair","reset-conversation":"Redefinir conversa","new-conversation":"Nova conversa","welcome-title":"Bem-vindo ao nosso chat de suporte","welcome-description":"Estamos aqui para ajudar! Inicie uma conversa e responderemos o mais rápido possível.","your-name":"Seu nome","your-email":"Seu endereço de email","start-chat":"Falar com o suporte","starting-chat":"Conectando...","hello-greeting":"Olá! Como podemos ajudar você hoje?","i-need-more-help":"preciso de mais ajuda","this-was-helpful":"Isso foi útil",optional:"Opcional","no-conversations-yet":"Nenhuma conversa ainda"},Vo={en:ib,ar:nb,nl:sb,fr:ab,de:rb,pt:ob},ub=Object.keys(Vo),lb=e=>ub.includes(e);function cb(e,t){const n=Vo[t];return n&&n[e]||""}function Bt(){const{widgetCtx:{config:e}}=W.useWidget();return X.useMemo(()=>{const n=lb(e.language)?e.language:"en";return{get:r=>cb(r,n),lang:n}},[e.language])}function ai({suggestion:e,className:t,...n}){const{sendMessage:r}=W.useMessages(),i=()=>{const a=e.trim();a&&r({content:a})};return f.jsx(Oe,{...re("chat/suggested_reply_btn"),size:"sm",className:q("rounded-xl w-fit",t),...n,onClick:i,children:e})}function db(){const e=Bt(),t=[e.get("i-need-more-help"),e.get("this-was-helpful")];return f.jsx("div",{...re("chat/might_solve_user_issue_suggested_replies_container"),className:"flex items-center gap-2 p-2 pb-0 flex-wrap",children:t.map(n=>f.jsx(ai,{suggestion:n,className:"flex-1"},n))})}function hb({file:{status:e,file:t,error:n},onCancel:r}){const[i,a]=X.useState(null);X.useEffect(()=>{if(!t.type.startsWith("image/"))return;const l=new FileReader;return l.onload=()=>a(l.result),l.onerror=()=>console.error("Error reading file"),l.readAsDataURL(t),()=>l.abort()},[t]);const s=()=>{switch(e){case"uploading":return f.jsx(le.Loader2,{className:"size-4 animate-spin"});case"error":return f.jsx(le.AlertCircle,{className:"size-4 text-destructive"});default:return null}},u=()=>{const l=t.type.split("/")[0];return l==="image"&&i?f.jsx("img",{src:typeof i=="string"?i:"",className:"object-cover bg-secondary size-full",alt:t.name}):l==="audio"?f.jsx(le.FileAudio2Icon,{}):l==="video"?f.jsx(le.FileVideo2Icon,{}):f.jsx(le.FileIcon,{})};return f.jsx(an,{side:"bottom",content:e==="error"?f.jsxs("span",{className:"text-destructive",children:["Failed to upload: ",n]}):t.name,children:f.jsxs("div",{className:q(e==="uploading"&&"opacity-50","group","size-12 border rounded-2xl overflow-hidden relative","flex items-center justify-center shrink-0"),children:[f.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:s()}),f.jsx("button",{type:"button",className:q("absolute bg-black/50 inset-0 size-full z-10 opacity-0","flex items-center justify-center","opacity-0 group-hover:opacity-100 transition"),onClick:r,children:f.jsx(le.XIcon,{className:"size-4 text-primary-foreground"})}),f.jsx(u,{})]})})}function fb(){var j;const{isSmallScreen:e}=Mt(),t=X.useRef(null),{sendMessage:n}=W.useMessages(),{sessionState:r}=W.useSessions(),i=Bt(),a=ii(),[s,u]=X.useState(""),{allFiles:l,emptyTheFiles:c,handleCancelUpload:d,appendFiles:h,isUploading:g,successFiles:p}=W.useUploadFiles(),E=!!((j=r.session)!=null&&j.isHandedOff),{isAwaitingBotReply:y}=W.useIsAwaitingBotReply(),k=U=>{h(U)},_=!s.trim()&&p.length===0,S=async()=>{if(y||_)return;g&&console.info("please wait for the file(s) to upload");const U=s.trim();n({content:U,attachments:p.flatMap(z=>z.fileUrl?[{url:z.fileUrl,type:z.file.type,name:z.file.name,id:z.id,size:z.file.size}]:[])}),u(""),c()},{getRootProps:L,getInputProps:M,open:F}=fu.useDropzone({onDrop:k,noClick:!0,onDropRejected(){console.error("unsupported file type, or the file is too large")},maxSize:5*1024*1024,accept:E?{"text/*":[".txt"],"image/*":[".png",".jpg",".jpeg",".gif"],"application/pdf":[".pdf"]}:{"image/png":[".png"],"image/jpeg":[".jpg",".jpeg"],"image/gif":[".gif"],"image/webp":[".webp"]}}),I=U=>{const z=U.clipboardData;z&&z.files.length>0&&k(Array.from(z.files))};return f.jsxs("div",{...re("chat/input_box/root"),className:"p-2 relative space-y-1",...L(),children:[f.jsx("input",{...M()}),f.jsxs("div",{...re("chat/input_box/inner_root"),className:q("transition-all","bg-white","relative rounded-3xl flex flex-col gap-2 p-2","hover:border-primary focus-within:border-primary"),children:[f.jsxs("div",{...re("chat/input_box/textarea_and_attachments_container"),className:"flex flex-col gap-2",children:[l.length>0&&f.jsx("div",{...re("chat/input_box/attachments_container"),className:"flex items-center gap-1",children:f.jsx(be.AnimatePresence,{mode:"popLayout",children:l.map(U=>f.jsx(ae,{snapExit:!0,children:f.jsx(hb,{onCancel:()=>d(U.id),file:U})},U.id))})}),f.jsx("textarea",{...re("chat/input_box/textarea"),onPaste:I,ref:t,id:"chat-input",dir:a,value:s,rows:3,className:q("max-h-16 [field-sizing:content]","w-full resize-none px-2",l.length===0&&"pt-1","bg-transparent outline-none","placeholder:text-muted-foreground","rtl:placeholder:text-right",e?"text-[16px]":"text-sm"),onChange:U=>u(U.target.value),onKeyDown:async U=>{U.key==="Enter"&&!U.shiftKey&&(U.preventDefault(),S())},placeholder:i.get("write-a-message")})]}),f.jsxs("div",{dir:a,className:"gap-2 flex justify-between rtl:text-right",children:[f.jsx(an,{side:"top",align:"start",content:"attach files, (maximum size 5mb)",children:f.jsx(Oe,{onClick:F,size:"fit",variant:"ghost",className:q("rounded-full size-8 flex items-center justify-center p-0 overflow-hidden"),children:f.jsx(be.AnimatePresence,{mode:"wait",children:E?f.jsx(ae,{children:f.jsx(le.PaperclipIcon,{className:"size-4"})},"paper-clip"):f.jsx(ae,{children:f.jsx(le.ImageIcon,{className:"size-4"})},"image-icon")})})}),f.jsx(an,{content:"send message",side:"top",align:"end",children:f.jsx(Oe,{size:"fit",onClick:S,disabled:y||g||_,className:"rounded-full size-8 flex items-center justify-center p-0",children:f.jsx(be.AnimatePresence,{mode:"wait",children:y||g?f.jsx(ae,{snapExit:!0,children:f.jsx(le.CircleDashed,{className:"size-4 animate-spin animate-iteration-infinite"})},"loading"):f.jsx(ae,{snapExit:!0,children:f.jsx(le.ArrowUpIcon,{className:"size-4"})},"send")})})})]})]})]})}function pb(){const{widgetCtx:e}=W.useWidget(),t=Bt();return f.jsx("div",{className:"p-2",children:f.jsxs("div",{className:"p-2 bg-muted rounded-3xl space-y-2",children:[f.jsxs("div",{className:"pl-2 flex items-center gap-1",children:[f.jsx(le.CircleCheckIcon,{className:"size-4 text-emerald-600"}),f.jsx("h2",{className:"text-sm font-medium",dir:"auto",children:t.get("session-closed-lead")})]}),f.jsx("div",{children:f.jsx(Oe,{onClick:e.resetChat,className:"rounded-2xl w-full",children:t.get("new-conversation")})})]})})}function mb(){var a;const{initialQuestions:e,initialQuestionsPosition:t}=W.useConfig(),{sessionState:n}=W.useSessions(),{messagesState:r}=W.useMessages(),i=r.messages.length===0;return f.jsx("footer",{children:f.jsx("div",{children:f.jsx(be.AnimatePresence,{mode:"wait",children:n.session&&!((a=n.session)!=null&&a.isOpened)?f.jsx(ae,{className:"overflow-hidden",overrides:{initial:{height:0},animate:{height:"auto"},exit:{height:0}},children:f.jsx(pb,{})},"session-closed"):f.jsxs(ae,{className:"overflow-hidden",overrides:{initial:{height:0},animate:{height:"auto"},exit:{height:0}},children:[r.lastAIResMightSolveUserIssue&&f.jsx(db,{}),i&&e&&t!=="below-initial-messages"&&f.jsx("div",{className:"flex items-center flex-row justify-end gap-2 flex-wrap px-2",children:e==null?void 0:e.map((s,u)=>f.jsx(ai,{suggestion:s},`${s}-${u}`))}),f.jsx(fb,{})]},"chat-input")})})})}const gb=me.Root,bb=me.Trigger,Eb=me.Group,Tb=ye.forwardRef(({className:e,inset:t,children:n,...r},i)=>f.jsxs(me.SubTrigger,{ref:i,className:q("flex cursor-default gap-2 select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...r,children:[n,f.jsx(le.ChevronRight,{className:"ml-auto"})]}));Tb.displayName=me.SubTrigger.displayName;const xb=ye.forwardRef(({className:e,...t},n)=>f.jsx(me.SubContent,{ref:n,className:q("z-50 min-w-[8rem] overflow-hidden rounded-2xl border bg-background p-1 text-foreground shadow-2xl data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t}));xb.displayName=me.SubContent.displayName;const Go=ye.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(me.Content,{ref:r,sideOffset:t,className:q("z-50 min-w-[8rem] overflow-hidden rounded-2xl border bg-background p-1 text-foreground shadow-2xl","data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));Go.displayName=me.Content.displayName;const Qo=ye.forwardRef(({className:e,inset:t,...n},r)=>f.jsx(ae,{children:f.jsx(me.Item,{ref:r,className:q("relative flex cursor-default select-none items-center gap-2 rounded-xl px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...n})}));Qo.displayName=me.Item.displayName;const wb=ye.forwardRef(({className:e,children:t,checked:n,...r},i)=>f.jsxs(me.CheckboxItem,{ref:i,className:q("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,...r,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(me.ItemIndicator,{children:f.jsx(le.Check,{className:"h-4 w-4"})})}),t]}));wb.displayName=me.CheckboxItem.displayName;const yb=ye.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(me.RadioItem,{ref:r,className:q("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(me.ItemIndicator,{children:f.jsx(le.Circle,{className:"h-2 w-2 fill-current"})})}),t]}));yb.displayName=me.RadioItem.displayName;const _b=ye.forwardRef(({className:e,inset:t,...n},r)=>f.jsx(me.Label,{ref:r,className:q("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...n}));_b.displayName=me.Label.displayName;const Ab=ye.forwardRef(({className:e,...t},n)=>f.jsx(me.Separator,{ref:n,className:q("-mx-1 my-1 h-px bg-muted",e),...t}));Ab.displayName=me.Separator.displayName;function Xo({className:e,...t}){return f.jsx("div",{className:q("animate-pulse rounded-md bg-secondary",e),...t})}function Cb(){const e=Bt(),[t,n]=X.useState(!1),{toChatScreen:r}=W.useWidgetRouter();return f.jsxs(gb,{open:t,onOpenChange:n,children:[f.jsx(bb,{asChild:!0,children:f.jsx(Oe,{variant:"ghost",size:"fit",className:"rounded-full",children:f.jsx(le.EllipsisVerticalIcon,{className:"size-4"})})}),f.jsx(Go,{align:"end",className:"min-w-56",children:f.jsx(Eb,{children:f.jsxs(Qo,{onSelect:()=>{n(!1),r()},children:[f.jsx(be.motion.div,{initial:{opacity:0,x:-4,rotate:360},animate:{opacity:1,x:0,rotate:0},children:f.jsx(le.MessageCirclePlusIcon,{})}),e.get("new-conversation")]})})})]})}function kb(){const{setIsOpen:e}=W.useWidgetTrigger(),{isSmallScreen:t}=Mt();return t?f.jsx(Oe,{variant:"ghost",size:"fit",className:"rounded-full",onClick:()=>e(!1),children:f.jsx(le.XIcon,{className:"size-4"})}):null}function Nb(){var i;const{data:e}=W.usePreludeData(),{routerState:{screen:t}}=W.useWidgetRouter(),{textContent:n}=W.useConfig();return(()=>{var a,s;switch(t){case"chat":return(a=n==null?void 0:n.chatScreen)==null?void 0:a.headerTitle;case"sessions":return(s=n==null?void 0:n.sessionsScreen)==null?void 0:s.headerTitle;case"welcome":return;default:return}})()??((i=e==null?void 0:e.data)==null?void 0:i.organizationName)??"Chat"}function Ko(){const{routerState:{screen:e},toSessionsScreen:t}=W.useWidgetRouter(),{isLoading:n}=W.usePreludeData(),r=ii(),i=(()=>{switch(e){case"chat":return re("chat/header");case"sessions":return re("sessions/header");case"welcome":return;default:return}})(),a=Nb();return f.jsx("header",{...i,className:"py-2 px-4 shrink-0",children:f.jsxs("div",{dir:r,className:"flex items-center rtl:flex-row-reverse gap-2",children:[e==="chat"&&f.jsx(Oe,{variant:"ghost",size:"fit",className:"rounded-full",onClick:t,children:f.jsx(le.ChevronLeftIcon,{className:"size-4"})}),f.jsx("div",{className:q("flex-1",e==="sessions"&&"pl-2"),children:f.jsx(be.AnimatePresence,{mode:"wait",children:n?f.jsx(ae,{snapExit:!0,children:f.jsx(Xo,{className:"h-5 w-1/2"})},"skeleton"):f.jsx(ae,{children:f.jsx("h2",{className:"font-semibold",children:a})},"organization-name")})}),f.jsx(Cb,{}),f.jsx(kb,{})]})})}function Ib({isFirstInGroup:e,isLastInGroup:t,isAloneInGroup:n,...r}){const{componentStore:i}=W.useWidget();if(r.data.action){const s=i.getComponent(r.data.action.name);if(s)return f.jsx(s,{...r,id:r.id,isFirstInGroup:e,isLastInGroup:t,isAloneInGroup:n})}const a=i.getComponent(r.component);return a?f.jsx(a,{...r,id:r.id,isFirstInGroup:e,isLastInGroup:t,isAloneInGroup:n}):f.jsx(Rn,{...r,isFirstInGroup:e,isLastInGroup:t,isAloneInGroup:n})}function Da({messages:e,agent:t,suggestedReplies:n}){return f.jsxs("div",{...re("chat/agent_msg_group/root"),className:q("flex items-end gap-2"),children:[f.jsx(an,{content:t==null?void 0:t.name,side:"right",align:"end",children:f.jsx(Lr,{...re("chat/agent_msg_group/root/avatar"),agent:t,className:"hidden"})}),f.jsxs("div",{className:q("flex-1 flex flex-col gap-2"),children:[f.jsxs("div",{...re("chat/agent_msg_group/avatar_and_msgs/root"),className:q("flex items-end gap-2"),children:[f.jsx(an,{content:t==null?void 0:t.name,side:"right",align:"end",children:f.jsx(Lr,{...re("chat/agent_msg_group/avatar_and_msgs/avatar"),agent:t})}),f.jsx("div",{...re("chat/agent_msg_group/avatar_and_msgs/msgs"),className:q("flex-1 flex flex-col gap-1"),children:e.map((r,i,a)=>f.jsx(Ib,{isFirstInGroup:i===0,isLastInGroup:i===a.length-1,isAloneInGroup:a.length===1,...r},r.id))})]}),n&&n.length>0&&f.jsx("div",{...re("chat/agent_msg_group/suggestions"),className:q("flex flex-col gap-1 pl-8"),children:n==null?void 0:n.map((r,i)=>f.jsx(ai,{suggestion:r},`${r}-${i}`))})]})]})}function Sb({message:e,isFirstInGroup:t,isLastInGroup:n,isAloneInGroup:r}){var i;return f.jsxs("div",{...re("chat/user_msg/root"),className:"w-5/6 flex flex-col items-end gap-1",children:[e.attachments&&e.attachments.length>0&&f.jsx("div",{className:"w-full flex gap-1 flex-wrap justify-end",children:(i=e.attachments)==null?void 0:i.map(a=>f.jsx(Yo,{attachment:a},a.id))}),e.content.length>0&&f.jsx("div",{...re("chat/user_msg/msg"),"data-first":t,"data-last":n,"data-alone":r,className:q("transition-all","w-fit py-3 px-4 rounded-3xl text-sm","bg-primary text-primary-foreground","break-words [word-break:break-word]","whitespace-pre-wrap",t&&!r&&"rounded-br-md",n&&!r&&"rounded-tr-md",!t&&!n&&!r&&"rounded-r-md"),children:e.content})]})}function Ob({messages:e}){return f.jsx("div",{...re("chat/user_msg_group/root"),className:q("group","flex flex-col gap-1 justify-end items-end"),children:e.map((t,n,r)=>f.jsx(Sb,{message:t,isFirstInGroup:n===0,isLastInGroup:n===r.length-1,isAloneInGroup:r.length===1},t.id))})}function Lb(e){const t=[];let n=null;return e.forEach(r=>{var i,a,s,u;(!n||((i=n[0])==null?void 0:i.type)!==r.type)&&(n=[],t.push(n)),((a=n[0])==null?void 0:a.type)==="FROM_AGENT"&&r.type==="FROM_AGENT"&&((s=r.agent)==null?void 0:s.id)!==((u=n[0].agent)==null?void 0:u.id)&&(n=[],t.push(n)),n.push(r)}),t}function Rb(e){var t;return((t=e==null?void 0:e[0])==null?void 0:t.type)==="FROM_USER"}function Db(e){var t;return((t=e==null?void 0:e[0])==null?void 0:t.type)==="FROM_BOT"}function vb(e){var t;return((t=e==null?void 0:e[0])==null?void 0:t.type)==="FROM_AGENT"}function Pb(){const{messagesState:{messages:e}}=W.useMessages(),{isAwaitingBotReply:t}=W.useIsAwaitingBotReply(),{componentStore:n}=W.useWidget(),r=W.useConfig(),{initialQuestions:i,initialQuestionsPosition:a}=r,s=X.useMemo(()=>Lb(e),[e]),u=r.persistentInitialMessages||[],l=!r.initialMessages||r.initialMessages.length===0?["Hello, how can I help you?"]:r.initialMessages,c=n.getComponent("loading"),d=X.useRef(null);function h(){setTimeout(()=>{const g=d.current;g&&(g.scrollTop=g.scrollHeight)},0)}return X.useEffect(()=>{h()},[e]),f.jsxs("div",{...re("chat/msgs/root"),ref:d,className:"max-h-full scroll-smooth relative flex-1 py-2 px-4 flex flex-col gap-2 overflow-auto",children:[f.jsx("div",{...re("chat/persistent_initial_msgs/root"),children:u.map((g,p,E)=>f.jsx(Rn,{component:"bot_message",data:{message:g},id:g,type:"FROM_BOT",timestamp:Date.now().toString(),dataComponentNames:{messageContainer:"chat/persistent_initial_msg/root",message:"chat/persistent_initial_msg/msg"},classNames:{messageContainer:q("w-full flex flex-col items-center text-center"),message:"w-full bg-transparent border-none shadow-none text-xs"},isFirstInGroup:p===0,isLastInGroup:p===E.length-1,isAloneInGroup:E.length===1},`${g}-${p}`))}),e.length===0&&f.jsx(Da,{messages:l.map((g,p)=>({component:"bot_message",data:{message:g},id:`${g}-${p}`,type:"FROM_BOT",timestamp:Date.now().toString()})),suggestedReplies:a==="below-initial-messages"?i:void 0,agent:r.bot?{...r.bot,isAi:!0,id:null}:void 0}),s.map(g=>{var y,k,_;const p=(y=g==null?void 0:g[0])==null?void 0:y.type,E=(k=g[0])==null?void 0:k.id;if(!p||!E)return null;if(Rb(g))return f.jsx(Ob,{messages:g},E);if(Db(g)||vb(g)){const S=(_=g[0])==null?void 0:_.agent;return f.jsx(Da,{messages:g,agent:S},E)}return null}),t&&c&&f.jsx(c,{agent:r.bot})]})}function $o({className:e}){return f.jsx(le.LoaderIcon,{className:q("size-4 animate-spin",e)})}function si({width:e,height:t}){const{isSmallScreen:n}=Mt(),{contentIframeRef:r}=W.useWidget();X.useEffect(()=>{var i,a;e&&((i=r==null?void 0:r.current)==null||i.style.setProperty("--opencx-widget-width",e)),t&&((a=r==null?void 0:r.current)==null||a.style.setProperty("--opencx-widget-height",t))},[n,t,e,r])}function Mb(){const{messagesState:{isInitialFetchLoading:e}}=W.useMessages(),{sessionState:{session:t}}=W.useSessions(),{theme:n}=fn();si({width:n.screens.chat.width,height:n.screens.chat.height});const r=X.useRef((t==null?void 0:t.id)||"chat").current;return f.jsx("div",{...re("chat/root"),className:q("flex flex-col overflow-hidden"),style:{width:"100vw",maxWidth:"100vw",height:"100vh",maxHeight:"100vh"},children:f.jsxs("div",{className:"size-full justify-between flex flex-col",children:[f.jsx(Ko,{}),f.jsx(be.AnimatePresence,{mode:"wait",children:e?f.jsx(ae,{className:"flex flex-col items-center justify-center w-full flex-1",children:f.jsx($o,{})},"loading"):f.jsxs(ae,{className:"flex flex-col w-full flex-1 overflow-auto",snapExit:!0,children:[f.jsx(Pb,{}),f.jsx(mb,{})]},r)})]})})}const An=ye.forwardRef(({className:e,type:t,...n},r)=>{const{isSmallScreen:i}=Mt(),a=ii();return f.jsx($e,{ref:r,children:f.jsx("input",{dir:a,type:t,className:q(i?"text-[16px]":"text-sm","flex w-full rounded-xl p-2 ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-primary-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 transition","rtl:placeholder:text-right","bg-white","rounded-2xl px-4","shadow-2xl",e),...n})})});An.displayName="Input";function Bb({className:e}){return f.jsx("svg",{width:"26",height:"32",viewBox:"0 0 26 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:q("text-primary-foreground",e),children:f.jsx("path",{d:"M1.34103 25.6132H5.44245C5.74203 25.6228 6.02673 25.7462 6.23867 25.9582C6.45062 26.1703 6.5739 26.4551 6.58348 26.7548V30.8584C6.59305 31.1581 6.71634 31.443 6.92828 31.655C7.14023 31.8671 7.42492 31.9904 7.7245 32H18.2894C18.589 31.9904 18.8737 31.8671 19.0856 31.655C19.2976 31.443 19.4209 31.1581 19.4304 30.8584V26.7548C19.4401 26.4545 19.5638 26.1692 19.7765 25.957C19.9892 25.7449 20.2748 25.6219 20.5749 25.6132H24.659C24.9586 25.6036 25.2433 25.4803 25.4552 25.2682C25.6671 25.0562 25.7904 24.7713 25.8 24.4716V7.52839C25.7904 7.22865 25.6671 6.94381 25.4552 6.73176C25.2433 6.5197 24.9586 6.39635 24.659 6.38677H20.561C20.2603 6.37802 19.9742 6.25457 19.7614 6.04169C19.5487 5.82881 19.4253 5.54261 19.4165 5.24168V1.14161C19.4072 0.84419 19.2858 0.561291 19.0768 0.349589C18.8678 0.137887 18.5865 0.0130193 18.2894 0L7.7245 0C7.42492 0.00957792 7.14023 0.132929 6.92828 0.344983C6.71634 0.557036 6.59305 0.841878 6.58348 1.14161V5.24168C6.57477 5.54203 6.45187 5.82773 6.23983 6.04052C6.0278 6.25331 5.74262 6.37715 5.44245 6.38677H1.34103C1.04144 6.39635 0.756749 6.5197 0.544805 6.73176C0.332861 6.94381 0.209574 7.22865 0.200001 7.52839V24.4716C0.209574 24.7713 0.332861 25.0562 0.544805 25.2682C0.756749 25.4803 1.04144 25.6036 1.34103 25.6132ZM6.58348 24.4716V7.52839C6.59305 7.22865 6.71634 6.94381 6.92828 6.73176C7.14023 6.5197 7.42492 6.39635 7.7245 6.38677H18.2894C18.589 6.39635 18.8737 6.5197 19.0856 6.73176C19.2976 6.94381 19.4209 7.22865 19.4304 7.52839V24.4716C19.4209 24.7713 19.2976 25.0562 19.0856 25.2682C18.8737 25.4803 18.589 25.6036 18.2894 25.6132H7.7245C7.42492 25.6036 7.14023 25.4803 6.92828 25.2682C6.71634 25.0562 6.59305 24.7713 6.58348 24.4716Z",fill:"currentColor"})})}function Jo({className:e}){const{token:t}=W.useConfig();return f.jsx("div",{className:q("flex items-center justify-center gap-2 p-2 pt-0 bg-background",e),children:f.jsx($e,{children:f.jsxs("a",{href:`https://open.cx/?ref=${t}`,target:"_blank",rel:"noreferrer",className:q("text-[10px] flex items-center","text-muted-foreground/70 [&_svg]:text-muted-foreground/70","hover:text-primary [&_svg]:hover:text-primary"),children:[f.jsx("span",{children:"Powered by"}),f.jsx("span",{children:" "}),f.jsxs("span",{className:"flex items-center gap-[1px]",children:[f.jsx("span",{children:f.jsx(Bb,{className:"size-3 inline-block"})}),f.jsx("span",{className:"font-semibold",children:"open"})]})]})})})}function Fb(){const{contentIframeRef:e}=W.useWidget(),t=X.useRef(null);return X.useEffect(()=>{const n=e==null?void 0:e.current;if(n&&t.current){const r=t.current;let i;const a=new ResizeObserver(()=>{i=requestAnimationFrame(()=>{const s=r.offsetHeight;n.style.setProperty("--opencx-widget-height",`${s.toFixed(1)}px`)})});return a.observe(r),()=>{cancelAnimationFrame(i),a.unobserve(r)}}},[e]),{observedElementRef:t}}const Hb=Gn.z.object({name:Gn.z.string().min(2),email:Gn.z.string().email()});function Ub(){var _,S,L,M,F,I,j,U,z;const{setIsOpen:e}=W.useWidgetTrigger(),{createUnverifiedContact:t}=W.useContact(),{isSmallScreen:n}=Mt(),r=W.useConfig(),{theme:i}=fn(),a=Bt(),{data:s}=W.usePreludeData(),{observedElementRef:u}=Fb();si({height:void 0,width:i.screens.welcome.width});const[l,c]=X.useState(((_=r.prefillUserData)==null?void 0:_.name)||""),[d,h]=X.useState(((S=r.prefillUserData)==null?void 0:S.email)||""),g=(r.extraDataCollectionFields||[]).filter(C=>C!=="name"&&C!=="email"&&!!C),[p,E]=X.useState({}),[y,k]=W._default(async C=>{C.preventDefault();const H=Hb.safeParse({name:l,email:d});H.success&&await t({email:H.data.email,non_verified_name:H.data.name},Object.values(p).filter(Boolean).length?p:void 0)},[l,d,p]);return f.jsx("div",{style:{width:"100vw",maxWidth:"100vw",minHeight:i.screens.welcome.minHeight,height:"100vh",maxHeight:"100vh",overflowY:"auto"},children:f.jsxs("div",{ref:u,className:q("flex flex-col",n&&"h-full"),children:[f.jsxs("div",{dir:"auto",className:"flex-1 flex flex-col px-4 py-12 text-start space-y-4 relative z-10",children:[n&&f.jsx(ae,{className:"absolute top-6 right-6",children:f.jsx(Oe,{size:"selfless",onClick:()=>e(!1),children:f.jsx(le.XIcon,{className:"size-4"})})}),f.jsx("div",{className:"flex items-center justify-between w-full mb-2",children:(L=r.assets)!=null&&L.organizationLogo?f.jsx("img",{src:(M=r.assets)==null?void 0:M.organizationLogo,alt:"Company Logo",className:"h-8 w-auto object-contain"}):f.jsx("h2",{className:"font-bold text-xl",dir:"auto",children:(F=s==null?void 0:s.data)==null?void 0:F.organizationName})}),f.jsxs("div",{className:"space-y-2",children:[f.jsx("h1",{className:"text-2xl font-bold",dir:"auto",children:((j=(I=r.textContent)==null?void 0:I.welcomeScreen)==null?void 0:j.title)||a.get("welcome-title")}),f.jsx("p",{className:"/90 text-sm max-w-[320px] leading-relaxed",dir:"auto",children:((z=(U=r.textContent)==null?void 0:U.welcomeScreen)==null?void 0:z.description)||a.get("welcome-description")})]})]}),f.jsxs("div",{className:"z-10 px-2 pt-2 bp-0 bg-background space-y-2",dir:"auto",children:[f.jsxs("form",{onSubmit:k,className:"space-y-2",children:[f.jsxs("div",{className:"space-y-2",children:[f.jsx(An,{value:l,onChange:C=>c(C.target.value),required:!0,placeholder:a.get("your-name"),name:"name"}),f.jsx(An,{required:!0,value:d,onChange:C=>h(C.target.value),type:"email",placeholder:a.get("your-email"),name:"email"}),g.map(C=>f.jsx(An,{value:p[C],onChange:H=>E(P=>({...P,[C]:H.target.value})),placeholder:`${C} (${a.get("optional")})`},C))]}),f.jsxs(Oe,{disabled:y.loading,className:"w-full",size:"lg",children:[y.loading?a.get("starting-chat"):a.get("start-chat"),f.jsx(le.SendHorizontal,{className:"size-4 rtl:-scale-100"})]})]}),f.jsx(Jo,{})]})]})})}function zb({session:e}){const{bot:t}=W.useConfig(),{toChatScreen:n}=W.useWidgetRouter(),r=e.assignee.kind==="human"?e.assignee.name||"Support Agent":(t==null?void 0:t.name)||"AI Support Agent",i=e.assignee.kind==="human"?e.assignee.avatarUrl||"":(t==null?void 0:t.avatar)||"";return f.jsxs(Oe,{variant:"ghost",size:"lg",className:"rounded-full p-2 pr-4 flex text-start justify-between w-full whitespace-normal",onClick:()=>n(e.id),children:[f.jsxs("div",{className:"flex-1 flex gap-2 items-center",children:[f.jsx(be.AnimatePresence,{mode:"wait",children:f.jsx(ae,{snapExit:!0,children:f.jsxs(ti,{className:"size-10",children:[f.jsx(ni,{src:i,alt:"Agent Icon"}),f.jsx(ri,{children:f.jsx(le.UserRoundIcon,{className:"size-4"})})]})})}),f.jsxs("div",{className:"flex-1",children:[f.jsx(be.AnimatePresence,{mode:"wait",children:f.jsx(ae,{snapExit:!0,children:r},r)}),f.jsx(be.AnimatePresence,{mode:"wait",children:e.lastMessage?f.jsx(ae,{snapExit:!0,children:f.jsx(Ws,{remarkPlugins:[gs],rehypePlugins:[Oo],className:"line-clamp-1 overflow-hidden text-ellipsis text-xs text-muted-foreground",children:e.lastMessage})},e.lastMessage||"content"):f.jsx(ae,{className:"w-1/2",snapExit:!0,children:f.jsx(Xo,{className:"h-4 w-full"})},"skeleton")})]})]}),f.jsx(le.ChevronRightIcon,{className:"size-4 text-muted-foreground shrink-0"})]})}function jb(){const e=Bt(),{toChatScreen:t}=W.useWidgetRouter(),{sessionsState:{data:n,isInitialFetchLoading:r}}=W.useSessions();return f.jsx("div",{className:"flex-1 flex flex-col overflow-scroll py-2 px-2",children:f.jsx(be.AnimatePresence,{mode:"wait",children:r?f.jsx(ae,{className:"flex-1 flex items-center justify-center",children:f.jsx($o,{})},"loading"):f.jsx(ae,{className:"flex-1 flex flex-col gap-2 relative",children:n.length?f.jsxs(f.Fragment,{children:[f.jsx(be.AnimatePresence,{children:n.map((i,a)=>f.jsx(ae,{snapExit:!0,children:f.jsx(zb,{session:i})},`${i.id}-${a}`))}),f.jsx("div",{className:"mt-auto w-full rounded-3xl sticky bottom-0 outline outline-8 outline-background bg-background",children:X.createElement(Oe,{...re("sessions/new_conversation_btn"),size:"lg",key:"new-session",className:"w-full",onClick:()=>t()},e.get("new-conversation"))})]}):f.jsxs("div",{className:"flex-1 flex flex-col gap-2 items-center",children:[f.jsx("div",{className:"flex-1 flex items-center justify-center",children:f.jsx("p",{className:"text-muted-foreground",children:e.get("no-conversations-yet")})}),X.createElement(Oe,{...re("sessions/new_conversation_btn"),size:"lg",key:"new-session",className:"w-full",onClick:()=>t()},e.get("new-conversation"))]})},"sessions")})})}function Yb(){const{theme:e}=fn();return si({width:e.screens.sessions.width,height:e.screens.sessions.height}),f.jsxs("div",{...re("sessions/root"),className:q("flex flex-col overflow-hidden bg-background"),style:{width:"100vw",maxWidth:"100vw",height:"100vh",maxHeight:"100vh"},children:[f.jsxs("div",{className:"size-full flex flex-col",children:[f.jsx(Ko,{}),f.jsx(jb,{})]}),f.jsx(Jo,{})]})}function Wb(){W.usePreludeData();const{routerState:{screen:e}}=W.useWidgetRouter();return f.jsxs("div",{className:"relative bg-background size-full",children:[f.jsx(Vn.Container,{}),f.jsx(be.AnimatePresence,{mode:"wait",children:(()=>{switch(e){case"welcome":return f.jsx(ae,{fadeIn:"right",className:"size-full",snapExit:!0,children:f.jsx(Ub,{})},e);case"sessions":return f.jsx(ae,{fadeIn:"right",className:"size-full",snapExit:!0,children:f.jsx(Yb,{})},e);case"chat":return f.jsx(ae,{fadeIn:"right",className:"size-full",snapExit:!0,children:f.jsx(Mb,{})},e);default:return null}})()})]})}const qb=`<!DOCTYPE html>
|
|
46
46
|
<html>
|
|
47
47
|
<head>
|
|
48
48
|
<style>
|