793 lines
600 KiB
JavaScript
793 lines
600 KiB
JavaScript
var Zd=Object.defineProperty;var Qd=(t,e,r)=>e in t?Zd(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var Je=(t,e,r)=>(Qd(t,typeof e!="symbol"?e+"":e,r),r);(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const a of s.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&n(a)}).observe(document,{childList:!0,subtree:!0});function r(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function n(i){if(i.ep)return;i.ep=!0;const s=r(i);fetch(i.href,s)}})();/**
|
||
* @vue/shared v3.5.20
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**//*! #__NO_SIDE_EFFECTS__ */function _a(t){const e=Object.create(null);for(const r of t.split(","))e[r]=1;return r=>r in e}const Ze={},zn=[],dr=()=>{},Kc=()=>!1,Vi=t=>t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&(t.charCodeAt(2)>122||t.charCodeAt(2)<97),La=t=>t.startsWith("onUpdate:"),Et=Object.assign,za=(t,e)=>{const r=t.indexOf(e);r>-1&&t.splice(r,1)},eh=Object.prototype.hasOwnProperty,Ve=(t,e)=>eh.call(t,e),Ce=Array.isArray,$n=t=>Wi(t)==="[object Map]",Yc=t=>Wi(t)==="[object Set]",Ne=t=>typeof t=="function",ft=t=>typeof t=="string",ln=t=>typeof t=="symbol",ot=t=>t!==null&&typeof t=="object",Xc=t=>(ot(t)||Ne(t))&&Ne(t.then)&&Ne(t.catch),Jc=Object.prototype.toString,Wi=t=>Jc.call(t),th=t=>Wi(t).slice(8,-1),Zc=t=>Wi(t)==="[object Object]",$a=t=>ft(t)&&t!=="NaN"&&t[0]!=="-"&&""+parseInt(t,10)===t,l0=_a(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Gi=t=>{const e=Object.create(null);return r=>e[r]||(e[r]=t(r))},rh=/-(\w)/g,tn=Gi(t=>t.replace(rh,(e,r)=>r?r.toUpperCase():"")),nh=/\B([A-Z])/g,cn=Gi(t=>t.replace(nh,"-$1").toLowerCase()),Qc=Gi(t=>t.charAt(0).toUpperCase()+t.slice(1)),ws=Gi(t=>t?`on${Qc(t)}`:""),en=(t,e)=>!Object.is(t,e),ci=(t,...e)=>{for(let r=0;r<t.length;r++)t[r](...e)},eu=(t,e,r,n=!1)=>{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,writable:n,value:r})},Qs=t=>{const e=parseFloat(t);return isNaN(e)?t:e};let Jo;const Ki=()=>Jo||(Jo=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function jn(t){if(Ce(t)){const e={};for(let r=0;r<t.length;r++){const n=t[r],i=ft(n)?oh(n):jn(n);if(i)for(const s in i)e[s]=i[s]}return e}else if(ft(t)||ot(t))return t}const ih=/;(?![^(]*\))/g,sh=/:([^]+)/,ah=/\/\*[^]*?\*\//g;function oh(t){const e={};return t.replace(ah,"").split(ih).forEach(r=>{if(r){const n=r.split(sh);n.length>1&&(e[n[0].trim()]=n[1].trim())}}),e}function Un(t){let e="";if(ft(t))e=t;else if(Ce(t))for(let r=0;r<t.length;r++){const n=Un(t[r]);n&&(e+=n+" ")}else if(ot(t))for(const r in t)t[r]&&(e+=r+" ");return e.trim()}const lh="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",ch=_a(lh);function tu(t){return!!t||t===""}const ru=t=>!!(t&&t.__v_isRef===!0),Zt=t=>ft(t)?t:t==null?"":Ce(t)||ot(t)&&(t.toString===Jc||!Ne(t.toString))?ru(t)?Zt(t.value):JSON.stringify(t,nu,2):String(t),nu=(t,e)=>ru(e)?nu(t,e.value):$n(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((r,[n,i],s)=>(r[xs(n,s)+" =>"]=i,r),{})}:Yc(e)?{[`Set(${e.size})`]:[...e.values()].map(r=>xs(r))}:ln(e)?xs(e):ot(e)&&!Ce(e)&&!Zc(e)?String(e):e,xs=(t,e="")=>{var r;return ln(t)?`Symbol(${(r=t.description)!=null?r:e})`:t};/**
|
||
* @vue/reactivity v3.5.20
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/let Ht;class uh{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=Ht,!e&&Ht&&(this.index=(Ht.scopes||(Ht.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,r;if(this.scopes)for(e=0,r=this.scopes.length;e<r;e++)this.scopes[e].pause();for(e=0,r=this.effects.length;e<r;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,r;if(this.scopes)for(e=0,r=this.scopes.length;e<r;e++)this.scopes[e].resume();for(e=0,r=this.effects.length;e<r;e++)this.effects[e].resume()}}run(e){if(this._active){const r=Ht;try{return Ht=this,e()}finally{Ht=r}}}on(){++this._on===1&&(this.prevScope=Ht,Ht=this)}off(){this._on>0&&--this._on===0&&(Ht=this.prevScope,this.prevScope=void 0)}stop(e){if(this._active){this._active=!1;let r,n;for(r=0,n=this.effects.length;r<n;r++)this.effects[r].stop();for(this.effects.length=0,r=0,n=this.cleanups.length;r<n;r++)this.cleanups[r]();if(this.cleanups.length=0,this.scopes){for(r=0,n=this.scopes.length;r<n;r++)this.scopes[r].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){const i=this.parent.scopes.pop();i&&i!==this&&(this.parent.scopes[this.index]=i,i.index=this.index)}this.parent=void 0}}}function dh(){return Ht}let et;const ks=new WeakSet;class iu{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,Ht&&Ht.active&&Ht.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,ks.has(this)&&(ks.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||au(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Zo(this),ou(this);const e=et,r=hr;et=this,hr=!0;try{return this.fn()}finally{lu(this),et=e,hr=r,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)Pa(e);this.deps=this.depsTail=void 0,Zo(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?ks.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){ea(this)&&this.run()}get dirty(){return ea(this)}}let su=0,c0,u0;function au(t,e=!1){if(t.flags|=8,e){t.next=u0,u0=t;return}t.next=c0,c0=t}function Fa(){su++}function Ba(){if(--su>0)return;if(u0){let e=u0;for(u0=void 0;e;){const r=e.next;e.next=void 0,e.flags&=-9,e=r}}let t;for(;c0;){let e=c0;for(c0=void 0;e;){const r=e.next;if(e.next=void 0,e.flags&=-9,e.flags&1)try{e.trigger()}catch(n){t||(t=n)}e=r}}if(t)throw t}function ou(t){for(let e=t.deps;e;e=e.nextDep)e.version=-1,e.prevActiveLink=e.dep.activeLink,e.dep.activeLink=e}function lu(t){let e,r=t.depsTail,n=r;for(;n;){const i=n.prevDep;n.version===-1?(n===r&&(r=i),Pa(n),hh(n)):e=n,n.dep.activeLink=n.prevActiveLink,n.prevActiveLink=void 0,n=i}t.deps=e,t.depsTail=r}function ea(t){for(let e=t.deps;e;e=e.nextDep)if(e.dep.version!==e.version||e.dep.computed&&(cu(e.dep.computed)||e.dep.version!==e.version))return!0;return!!t._dirty}function cu(t){if(t.flags&4&&!(t.flags&16)||(t.flags&=-17,t.globalVersion===b0)||(t.globalVersion=b0,!t.isSSR&&t.flags&128&&(!t.deps&&!t._dirty||!ea(t))))return;t.flags|=2;const e=t.dep,r=et,n=hr;et=t,hr=!0;try{ou(t);const i=t.fn(t._value);(e.version===0||en(i,t._value))&&(t.flags|=128,t._value=i,e.version++)}catch(i){throw e.version++,i}finally{et=r,hr=n,lu(t),t.flags&=-3}}function Pa(t,e=!1){const{dep:r,prevSub:n,nextSub:i}=t;if(n&&(n.nextSub=i,t.prevSub=void 0),i&&(i.prevSub=n,t.nextSub=void 0),r.subs===t&&(r.subs=n,!n&&r.computed)){r.computed.flags&=-5;for(let s=r.computed.deps;s;s=s.nextDep)Pa(s,!0)}!e&&!--r.sc&&r.map&&r.map.delete(r.key)}function hh(t){const{prevDep:e,nextDep:r}=t;e&&(e.nextDep=r,t.prevDep=void 0),r&&(r.prevDep=e,t.nextDep=void 0)}let hr=!0;const uu=[];function Br(){uu.push(hr),hr=!1}function Pr(){const t=uu.pop();hr=t===void 0?!0:t}function Zo(t){const{cleanup:e}=t;if(t.cleanup=void 0,e){const r=et;et=void 0;try{e()}finally{et=r}}}let b0=0;class fh{constructor(e,r){this.sub=e,this.dep=r,this.version=r.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class Ha{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(e){if(!et||!hr||et===this.computed)return;let r=this.activeLink;if(r===void 0||r.sub!==et)r=this.activeLink=new fh(et,this),et.deps?(r.prevDep=et.depsTail,et.depsTail.nextDep=r,et.depsTail=r):et.deps=et.depsTail=r,du(r);else if(r.version===-1&&(r.version=this.version,r.nextDep)){const n=r.nextDep;n.prevDep=r.prevDep,r.prevDep&&(r.prevDep.nextDep=n),r.prevDep=et.depsTail,r.nextDep=void 0,et.depsTail.nextDep=r,et.depsTail=r,et.deps===r&&(et.deps=n)}return r}trigger(e){this.version++,b0++,this.notify(e)}notify(e){Fa();try{for(let r=this.subs;r;r=r.prevSub)r.sub.notify()&&r.sub.dep.notify()}finally{Ba()}}}function du(t){if(t.dep.sc++,t.sub.flags&4){const e=t.dep.computed;if(e&&!t.dep.subs){e.flags|=20;for(let n=e.deps;n;n=n.nextDep)du(n)}const r=t.dep.subs;r!==t&&(t.prevSub=r,r&&(r.nextSub=t)),t.dep.subs=t}}const ta=new WeakMap,wn=Symbol(""),ra=Symbol(""),y0=Symbol("");function Ct(t,e,r){if(hr&&et){let n=ta.get(t);n||ta.set(t,n=new Map);let i=n.get(r);i||(n.set(r,i=new Ha),i.map=n,i.key=r),i.track()}}function Or(t,e,r,n,i,s){const a=ta.get(t);if(!a){b0++;return}const o=l=>{l&&l.trigger()};if(Fa(),e==="clear")a.forEach(o);else{const l=Ce(t),c=l&&$a(r);if(l&&r==="length"){const u=Number(n);a.forEach((f,p)=>{(p==="length"||p===y0||!ln(p)&&p>=u)&&o(f)})}else switch((r!==void 0||a.has(void 0))&&o(a.get(r)),c&&o(a.get(y0)),e){case"add":l?c&&o(a.get("length")):(o(a.get(wn)),$n(t)&&o(a.get(ra)));break;case"delete":l||(o(a.get(wn)),$n(t)&&o(a.get(ra)));break;case"set":$n(t)&&o(a.get(wn));break}}Ba()}function Mn(t){const e=Ue(t);return e===t?e:(Ct(e,"iterate",y0),tr(t)?e:e.map(At))}function Yi(t){return Ct(t=Ue(t),"iterate",y0),t}const ph={__proto__:null,[Symbol.iterator](){return Ss(this,Symbol.iterator,At)},concat(...t){return Mn(this).concat(...t.map(e=>Ce(e)?Mn(e):e))},entries(){return Ss(this,"entries",t=>(t[1]=At(t[1]),t))},every(t,e){return Nr(this,"every",t,e,void 0,arguments)},filter(t,e){return Nr(this,"filter",t,e,r=>r.map(At),arguments)},find(t,e){return Nr(this,"find",t,e,At,arguments)},findIndex(t,e){return Nr(this,"findIndex",t,e,void 0,arguments)},findLast(t,e){return Nr(this,"findLast",t,e,At,arguments)},findLastIndex(t,e){return Nr(this,"findLastIndex",t,e,void 0,arguments)},forEach(t,e){return Nr(this,"forEach",t,e,void 0,arguments)},includes(...t){return Ts(this,"includes",t)},indexOf(...t){return Ts(this,"indexOf",t)},join(t){return Mn(this).join(t)},lastIndexOf(...t){return Ts(this,"lastIndexOf",t)},map(t,e){return Nr(this,"map",t,e,void 0,arguments)},pop(){return Zn(this,"pop")},push(...t){return Zn(this,"push",t)},reduce(t,...e){return Qo(this,"reduce",t,e)},reduceRight(t,...e){return Qo(this,"reduceRight",t,e)},shift(){return Zn(this,"shift")},some(t,e){return Nr(this,"some",t,e,void 0,arguments)},splice(...t){return Zn(this,"splice",t)},toReversed(){return Mn(this).toReversed()},toSorted(t){return Mn(this).toSorted(t)},toSpliced(...t){return Mn(this).toSpliced(...t)},unshift(...t){return Zn(this,"unshift",t)},values(){return Ss(this,"values",At)}};function Ss(t,e,r){const n=Yi(t),i=n[e]();return n!==t&&!tr(t)&&(i._next=i.next,i.next=()=>{const s=i._next();return s.value&&(s.value=r(s.value)),s}),i}const mh=Array.prototype;function Nr(t,e,r,n,i,s){const a=Yi(t),o=a!==t&&!tr(t),l=a[e];if(l!==mh[e]){const f=l.apply(t,s);return o?At(f):f}let c=r;a!==t&&(o?c=function(f,p){return r.call(this,At(f),p,t)}:r.length>2&&(c=function(f,p){return r.call(this,f,p,t)}));const u=l.call(a,c,n);return o&&i?i(u):u}function Qo(t,e,r,n){const i=Yi(t);let s=r;return i!==t&&(tr(t)?r.length>3&&(s=function(a,o,l){return r.call(this,a,o,l,t)}):s=function(a,o,l){return r.call(this,a,At(o),l,t)}),i[e](s,...n)}function Ts(t,e,r){const n=Ue(t);Ct(n,"iterate",y0);const i=n[e](...r);return(i===-1||i===!1)&&Va(r[0])?(r[0]=Ue(r[0]),n[e](...r)):i}function Zn(t,e,r=[]){Br(),Fa();const n=Ue(t)[e].apply(t,r);return Ba(),Pr(),n}const gh=_a("__proto__,__v_isRef,__isVue"),hu=new Set(Object.getOwnPropertyNames(Symbol).filter(t=>t!=="arguments"&&t!=="caller").map(t=>Symbol[t]).filter(ln));function vh(t){ln(t)||(t=String(t));const e=Ue(this);return Ct(e,"has",t),e.hasOwnProperty(t)}class fu{constructor(e=!1,r=!1){this._isReadonly=e,this._isShallow=r}get(e,r,n){if(r==="__v_skip")return e.__v_skip;const i=this._isReadonly,s=this._isShallow;if(r==="__v_isReactive")return!i;if(r==="__v_isReadonly")return i;if(r==="__v_isShallow")return s;if(r==="__v_raw")return n===(i?s?Ch:vu:s?gu:mu).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;const a=Ce(e);if(!i){let l;if(a&&(l=ph[r]))return l;if(r==="hasOwnProperty")return vh}const o=Reflect.get(e,r,Nt(e)?e:n);return(ln(r)?hu.has(r):gh(r))||(i||Ct(e,"get",r),s)?o:Nt(o)?a&&$a(r)?o:o.value:ot(o)?i?bu(o):ja(o):o}}class pu extends fu{constructor(e=!1){super(!1,e)}set(e,r,n,i){let s=e[r];if(!this._isShallow){const l=rn(s);if(!tr(n)&&!rn(n)&&(s=Ue(s),n=Ue(n)),!Ce(e)&&Nt(s)&&!Nt(n))return l||(s.value=n),!0}const a=Ce(e)&&$a(r)?Number(r)<e.length:Ve(e,r),o=Reflect.set(e,r,n,Nt(e)?e:i);return e===Ue(i)&&(a?en(n,s)&&Or(e,"set",r,n):Or(e,"add",r,n)),o}deleteProperty(e,r){const n=Ve(e,r);e[r];const i=Reflect.deleteProperty(e,r);return i&&n&&Or(e,"delete",r,void 0),i}has(e,r){const n=Reflect.has(e,r);return(!ln(r)||!hu.has(r))&&Ct(e,"has",r),n}ownKeys(e){return Ct(e,"iterate",Ce(e)?"length":wn),Reflect.ownKeys(e)}}class bh extends fu{constructor(e=!1){super(!0,e)}set(e,r){return!0}deleteProperty(e,r){return!0}}const yh=new pu,wh=new bh,xh=new pu(!0);const na=t=>t,j0=t=>Reflect.getPrototypeOf(t);function kh(t,e,r){return function(...n){const i=this.__v_raw,s=Ue(i),a=$n(s),o=t==="entries"||t===Symbol.iterator&&a,l=t==="keys"&&a,c=i[t](...n),u=r?na:e?xi:At;return!e&&Ct(s,"iterate",l?ra:wn),{next(){const{value:f,done:p}=c.next();return p?{value:f,done:p}:{value:o?[u(f[0]),u(f[1])]:u(f),done:p}},[Symbol.iterator](){return this}}}}function U0(t){return function(...e){return t==="delete"?!1:t==="clear"?void 0:this}}function Sh(t,e){const r={get(i){const s=this.__v_raw,a=Ue(s),o=Ue(i);t||(en(i,o)&&Ct(a,"get",i),Ct(a,"get",o));const{has:l}=j0(a),c=e?na:t?xi:At;if(l.call(a,i))return c(s.get(i));if(l.call(a,o))return c(s.get(o));s!==a&&s.get(i)},get size(){const i=this.__v_raw;return!t&&Ct(Ue(i),"iterate",wn),i.size},has(i){const s=this.__v_raw,a=Ue(s),o=Ue(i);return t||(en(i,o)&&Ct(a,"has",i),Ct(a,"has",o)),i===o?s.has(i):s.has(i)||s.has(o)},forEach(i,s){const a=this,o=a.__v_raw,l=Ue(o),c=e?na:t?xi:At;return!t&&Ct(l,"iterate",wn),o.forEach((u,f)=>i.call(s,c(u),c(f),a))}};return Et(r,t?{add:U0("add"),set:U0("set"),delete:U0("delete"),clear:U0("clear")}:{add(i){!e&&!tr(i)&&!rn(i)&&(i=Ue(i));const s=Ue(this);return j0(s).has.call(s,i)||(s.add(i),Or(s,"add",i,i)),this},set(i,s){!e&&!tr(s)&&!rn(s)&&(s=Ue(s));const a=Ue(this),{has:o,get:l}=j0(a);let c=o.call(a,i);c||(i=Ue(i),c=o.call(a,i));const u=l.call(a,i);return a.set(i,s),c?en(s,u)&&Or(a,"set",i,s):Or(a,"add",i,s),this},delete(i){const s=Ue(this),{has:a,get:o}=j0(s);let l=a.call(s,i);l||(i=Ue(i),l=a.call(s,i)),o&&o.call(s,i);const c=s.delete(i);return l&&Or(s,"delete",i,void 0),c},clear(){const i=Ue(this),s=i.size!==0,a=i.clear();return s&&Or(i,"clear",void 0,void 0),a}}),["keys","values","entries",Symbol.iterator].forEach(i=>{r[i]=kh(i,t,e)}),r}function qa(t,e){const r=Sh(t,e);return(n,i,s)=>i==="__v_isReactive"?!t:i==="__v_isReadonly"?t:i==="__v_raw"?n:Reflect.get(Ve(r,i)&&i in n?r:n,i,s)}const Th={get:qa(!1,!1)},Ah={get:qa(!1,!0)},Eh={get:qa(!0,!1)};const mu=new WeakMap,gu=new WeakMap,vu=new WeakMap,Ch=new WeakMap;function Mh(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Nh(t){return t.__v_skip||!Object.isExtensible(t)?0:Mh(th(t))}function ja(t){return rn(t)?t:Ua(t,!1,yh,Th,mu)}function Ih(t){return Ua(t,!1,xh,Ah,gu)}function bu(t){return Ua(t,!0,wh,Eh,vu)}function Ua(t,e,r,n,i){if(!ot(t)||t.__v_raw&&!(e&&t.__v_isReactive))return t;const s=Nh(t);if(s===0)return t;const a=i.get(t);if(a)return a;const o=new Proxy(t,s===2?n:r);return i.set(t,o),o}function Fn(t){return rn(t)?Fn(t.__v_raw):!!(t&&t.__v_isReactive)}function rn(t){return!!(t&&t.__v_isReadonly)}function tr(t){return!!(t&&t.__v_isShallow)}function Va(t){return t?!!t.__v_raw:!1}function Ue(t){const e=t&&t.__v_raw;return e?Ue(e):t}function Rh(t){return!Ve(t,"__v_skip")&&Object.isExtensible(t)&&eu(t,"__v_skip",!0),t}const At=t=>ot(t)?ja(t):t,xi=t=>ot(t)?bu(t):t;function Nt(t){return t?t.__v_isRef===!0:!1}function De(t){return Dh(t,!1)}function Dh(t,e){return Nt(t)?t:new Oh(t,e)}class Oh{constructor(e,r){this.dep=new Ha,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=r?e:Ue(e),this._value=r?e:At(e),this.__v_isShallow=r}get value(){return this.dep.track(),this._value}set value(e){const r=this._rawValue,n=this.__v_isShallow||tr(e)||rn(e);e=n?e:Ue(e),en(e,r)&&(this._rawValue=e,this._value=n?e:At(e),this.dep.trigger())}}function _h(t){return Nt(t)?t.value:t}const Lh={get:(t,e,r)=>e==="__v_raw"?t:_h(Reflect.get(t,e,r)),set:(t,e,r,n)=>{const i=t[e];return Nt(i)&&!Nt(r)?(i.value=r,!0):Reflect.set(t,e,r,n)}};function yu(t){return Fn(t)?t:new Proxy(t,Lh)}class zh{constructor(e,r,n){this.fn=e,this.setter=r,this._value=void 0,this.dep=new Ha(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=b0-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!r,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&et!==this)return au(this,!0),!0}get value(){const e=this.dep.track();return cu(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}}function $h(t,e,r=!1){let n,i;return Ne(t)?n=t:(n=t.get,i=t.set),new zh(n,i,r)}const V0={},ki=new WeakMap;let bn;function Fh(t,e=!1,r=bn){if(r){let n=ki.get(r);n||ki.set(r,n=[]),n.push(t)}}function Bh(t,e,r=Ze){const{immediate:n,deep:i,once:s,scheduler:a,augmentJob:o,call:l}=r,c=I=>i?I:tr(I)||i===!1||i===0?_r(I,1):_r(I);let u,f,p,g,b=!1,x=!1;if(Nt(t)?(f=()=>t.value,b=tr(t)):Fn(t)?(f=()=>c(t),b=!0):Ce(t)?(x=!0,b=t.some(I=>Fn(I)||tr(I)),f=()=>t.map(I=>{if(Nt(I))return I.value;if(Fn(I))return c(I);if(Ne(I))return l?l(I,2):I()})):Ne(t)?e?f=l?()=>l(t,2):t:f=()=>{if(p){Br();try{p()}finally{Pr()}}const I=bn;bn=u;try{return l?l(t,3,[g]):t(g)}finally{bn=I}}:f=dr,e&&i){const I=f,D=i===!0?1/0:i;f=()=>_r(I(),D)}const w=dh(),N=()=>{u.stop(),w&&w.active&&za(w.effects,u)};if(s&&e){const I=e;e=(...D)=>{I(...D),N()}}let y=x?new Array(t.length).fill(V0):V0;const k=I=>{if(!(!(u.flags&1)||!u.dirty&&!I))if(e){const D=u.run();if(i||b||(x?D.some((O,z)=>en(O,y[z])):en(D,y))){p&&p();const O=bn;bn=u;try{const z=[D,y===V0?void 0:x&&y[0]===V0?[]:y,g];y=D,l?l(e,3,z):e(...z)}finally{bn=O}}}else u.run()};return o&&o(k),u=new iu(f),u.scheduler=a?()=>a(k,!1):k,g=I=>Fh(I,!1,u),p=u.onStop=()=>{const I=ki.get(u);if(I){if(l)l(I,4);else for(const D of I)D();ki.delete(u)}},e?n?k(!0):y=u.run():a?a(k.bind(null,!0),!0):u.run(),N.pause=u.pause.bind(u),N.resume=u.resume.bind(u),N.stop=N,N}function _r(t,e=1/0,r){if(e<=0||!ot(t)||t.__v_skip||(r=r||new Set,r.has(t)))return t;if(r.add(t),e--,Nt(t))_r(t.value,e,r);else if(Ce(t))for(let n=0;n<t.length;n++)_r(t[n],e,r);else if(Yc(t)||$n(t))t.forEach(n=>{_r(n,e,r)});else if(Zc(t)){for(const n in t)_r(t[n],e,r);for(const n of Object.getOwnPropertySymbols(t))Object.prototype.propertyIsEnumerable.call(t,n)&&_r(t[n],e,r)}return t}/**
|
||
* @vue/runtime-core v3.5.20
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/function C0(t,e,r,n){try{return n?t(...n):t()}catch(i){Xi(i,e,r)}}function Tr(t,e,r,n){if(Ne(t)){const i=C0(t,e,r,n);return i&&Xc(i)&&i.catch(s=>{Xi(s,e,r)}),i}if(Ce(t)){const i=[];for(let s=0;s<t.length;s++)i.push(Tr(t[s],e,r,n));return i}}function Xi(t,e,r,n=!0){const i=e?e.vnode:null,{errorHandler:s,throwUnhandledErrorInProduction:a}=e&&e.appContext.config||Ze;if(e){let o=e.parent;const l=e.proxy,c=`https://vuejs.org/error-reference/#runtime-${r}`;for(;o;){const u=o.ec;if(u){for(let f=0;f<u.length;f++)if(u[f](t,l,c)===!1)return}o=o.parent}if(s){Br(),C0(s,null,10,[t,l,c]),Pr();return}}Ph(t,r,i,n,a)}function Ph(t,e,r,n=!0,i=!1){if(i)throw t;console.error(t)}const Ot=[];let br=-1;const Bn=[];let Xr=null,Dn=0;const wu=Promise.resolve();let Si=null;function On(t){const e=Si||wu;return t?e.then(this?t.bind(this):t):e}function Hh(t){let e=br+1,r=Ot.length;for(;e<r;){const n=e+r>>>1,i=Ot[n],s=w0(i);s<t||s===t&&i.flags&2?e=n+1:r=n}return e}function Wa(t){if(!(t.flags&1)){const e=w0(t),r=Ot[Ot.length-1];!r||!(t.flags&2)&&e>=w0(r)?Ot.push(t):Ot.splice(Hh(e),0,t),t.flags|=1,xu()}}function xu(){Si||(Si=wu.then(Su))}function qh(t){Ce(t)?Bn.push(...t):Xr&&t.id===-1?Xr.splice(Dn+1,0,t):t.flags&1||(Bn.push(t),t.flags|=1),xu()}function el(t,e,r=br+1){for(;r<Ot.length;r++){const n=Ot[r];if(n&&n.flags&2){if(t&&n.id!==t.uid)continue;Ot.splice(r,1),r--,n.flags&4&&(n.flags&=-2),n(),n.flags&4||(n.flags&=-2)}}}function ku(t){if(Bn.length){const e=[...new Set(Bn)].sort((r,n)=>w0(r)-w0(n));if(Bn.length=0,Xr){Xr.push(...e);return}for(Xr=e,Dn=0;Dn<Xr.length;Dn++){const r=Xr[Dn];r.flags&4&&(r.flags&=-2),r.flags&8||r(),r.flags&=-2}Xr=null,Dn=0}}const w0=t=>t.id==null?t.flags&2?-1:1/0:t.id;function Su(t){const e=dr;try{for(br=0;br<Ot.length;br++){const r=Ot[br];r&&!(r.flags&8)&&(r.flags&4&&(r.flags&=-2),C0(r,r.i,r.i?15:14),r.flags&4||(r.flags&=-2))}}finally{for(;br<Ot.length;br++){const r=Ot[br];r&&(r.flags&=-2)}br=-1,Ot.length=0,ku(),Si=null,(Ot.length||Bn.length)&&Su()}}let Qt=null,Tu=null;function Ti(t){const e=Qt;return Qt=t,Tu=t&&t.type.__scopeId||null,e}function jh(t,e=Qt,r){if(!e||t._n)return t;const n=(...i)=>{n._d&&ll(-1);const s=Ti(e);let a;try{a=t(...i)}finally{Ti(s),n._d&&ll(1)}return a};return n._n=!0,n._c=!0,n._d=!0,n}function Ai(t,e){if(Qt===null)return t;const r=es(Qt),n=t.dirs||(t.dirs=[]);for(let i=0;i<e.length;i++){let[s,a,o,l=Ze]=e[i];s&&(Ne(s)&&(s={mounted:s,updated:s}),s.deep&&_r(a),n.push({dir:s,instance:r,value:a,oldValue:void 0,arg:o,modifiers:l}))}return t}function fn(t,e,r,n){const i=t.dirs,s=e&&e.dirs;for(let a=0;a<i.length;a++){const o=i[a];s&&(o.oldValue=s[a].value);let l=o.dir[n];l&&(Br(),Tr(l,r,8,[t.el,o,t,e]),Pr())}}const Uh=Symbol("_vte"),Vh=t=>t.__isTeleport,Wh=Symbol("_leaveCb");function Ga(t,e){t.shapeFlag&6&&t.component?(t.transition=e,Ga(t.component.subTree,e)):t.shapeFlag&128?(t.ssContent.transition=e.clone(t.ssContent),t.ssFallback.transition=e.clone(t.ssFallback)):t.transition=e}function Au(t){t.ids=[t.ids[0]+t.ids[2]+++"-",0,0]}function d0(t,e,r,n,i=!1){if(Ce(t)){t.forEach((b,x)=>d0(b,e&&(Ce(e)?e[x]:e),r,n,i));return}if(h0(n)&&!i){n.shapeFlag&512&&n.type.__asyncResolved&&n.component.subTree.component&&d0(t,e,r,n.component.subTree);return}const s=n.shapeFlag&4?es(n.component):n.el,a=i?null:s,{i:o,r:l}=t,c=e&&e.r,u=o.refs===Ze?o.refs={}:o.refs,f=o.setupState,p=Ue(f),g=f===Ze?Kc:b=>Ve(p,b);if(c!=null&&c!==l){if(ft(c))u[c]=null,g(c)&&(f[c]=null);else if(Nt(c)){c.value=null;const b=e;b.k&&(u[b.k]=null)}}if(Ne(l))C0(l,o,12,[a,u]);else{const b=ft(l),x=Nt(l);if(b||x){const w=()=>{if(t.f){const N=b?g(l)?f[l]:u[l]:l.value;if(i)Ce(N)&&za(N,s);else if(Ce(N))N.includes(s)||N.push(s);else if(b)u[l]=[s],g(l)&&(f[l]=u[l]);else{const y=[s];l.value=y,t.k&&(u[t.k]=y)}}else b?(u[l]=a,g(l)&&(f[l]=a)):x&&(l.value=a,t.k&&(u[t.k]=a))};a?(w.id=-1,Vt(w,r)):w()}}}Ki().requestIdleCallback;Ki().cancelIdleCallback;const h0=t=>!!t.type.__asyncLoader,Eu=t=>t.type.__isKeepAlive;function Gh(t,e){Cu(t,"a",e)}function Kh(t,e){Cu(t,"da",e)}function Cu(t,e,r=_t){const n=t.__wdc||(t.__wdc=()=>{let i=r;for(;i;){if(i.isDeactivated)return;i=i.parent}return t()});if(Ji(e,n,r),r){let i=r.parent;for(;i&&i.parent;)Eu(i.parent.vnode)&&Yh(n,e,r,i),i=i.parent}}function Yh(t,e,r,n){const i=Ji(e,t,n,!0);Ya(()=>{za(n[e],i)},r)}function Ji(t,e,r=_t,n=!1){if(r){const i=r[t]||(r[t]=[]),s=e.__weh||(e.__weh=(...a)=>{Br();const o=M0(r),l=Tr(e,r,t,a);return o(),Pr(),l});return n?i.unshift(s):i.push(s),s}}const Ur=t=>(e,r=_t)=>{(!k0||t==="sp")&&Ji(t,(...n)=>e(...n),r)},Xh=Ur("bm"),Ka=Ur("m"),Jh=Ur("bu"),Zh=Ur("u"),Qh=Ur("bum"),Ya=Ur("um"),ef=Ur("sp"),tf=Ur("rtg"),rf=Ur("rtc");function nf(t,e=_t){Ji("ec",t,e)}const sf=Symbol.for("v-ndc");function Mu(t,e,r,n){let i;const s=r&&r[n],a=Ce(t);if(a||ft(t)){const o=a&&Fn(t);let l=!1,c=!1;o&&(l=!tr(t),c=rn(t),t=Yi(t)),i=new Array(t.length);for(let u=0,f=t.length;u<f;u++)i[u]=e(l?c?xi(At(t[u])):At(t[u]):t[u],u,void 0,s&&s[u])}else if(typeof t=="number"){i=new Array(t);for(let o=0;o<t;o++)i[o]=e(o+1,o,void 0,s&&s[o])}else if(ot(t))if(t[Symbol.iterator])i=Array.from(t,(o,l)=>e(o,l,void 0,s&&s[l]));else{const o=Object.keys(t);i=new Array(o.length);for(let l=0,c=o.length;l<c;l++){const u=o[l];i[l]=e(t[u],u,l,s&&s[l])}}else i=[];return r&&(r[n]=i),i}const ia=t=>t?Yu(t)?es(t):ia(t.parent):null,f0=Et(Object.create(null),{$:t=>t,$el:t=>t.vnode.el,$data:t=>t.data,$props:t=>t.props,$attrs:t=>t.attrs,$slots:t=>t.slots,$refs:t=>t.refs,$parent:t=>ia(t.parent),$root:t=>ia(t.root),$host:t=>t.ce,$emit:t=>t.emit,$options:t=>Xa(t),$forceUpdate:t=>t.f||(t.f=()=>{Wa(t.update)}),$nextTick:t=>t.n||(t.n=On.bind(t.proxy)),$watch:t=>Cf.bind(t)}),As=(t,e)=>t!==Ze&&!t.__isScriptSetup&&Ve(t,e),af={get({_:t},e){if(e==="__v_skip")return!0;const{ctx:r,setupState:n,data:i,props:s,accessCache:a,type:o,appContext:l}=t;let c;if(e[0]!=="$"){const g=a[e];if(g!==void 0)switch(g){case 1:return n[e];case 2:return i[e];case 4:return r[e];case 3:return s[e]}else{if(As(n,e))return a[e]=1,n[e];if(i!==Ze&&Ve(i,e))return a[e]=2,i[e];if((c=t.propsOptions[0])&&Ve(c,e))return a[e]=3,s[e];if(r!==Ze&&Ve(r,e))return a[e]=4,r[e];sa&&(a[e]=0)}}const u=f0[e];let f,p;if(u)return e==="$attrs"&&Ct(t.attrs,"get",""),u(t);if((f=o.__cssModules)&&(f=f[e]))return f;if(r!==Ze&&Ve(r,e))return a[e]=4,r[e];if(p=l.config.globalProperties,Ve(p,e))return p[e]},set({_:t},e,r){const{data:n,setupState:i,ctx:s}=t;return As(i,e)?(i[e]=r,!0):n!==Ze&&Ve(n,e)?(n[e]=r,!0):Ve(t.props,e)||e[0]==="$"&&e.slice(1)in t?!1:(s[e]=r,!0)},has({_:{data:t,setupState:e,accessCache:r,ctx:n,appContext:i,propsOptions:s,type:a}},o){let l,c;return!!(r[o]||t!==Ze&&o[0]!=="$"&&Ve(t,o)||As(e,o)||(l=s[0])&&Ve(l,o)||Ve(n,o)||Ve(f0,o)||Ve(i.config.globalProperties,o)||(c=a.__cssModules)&&c[o])},defineProperty(t,e,r){return r.get!=null?t._.accessCache[e]=0:Ve(r,"value")&&this.set(t,e,r.value,null),Reflect.defineProperty(t,e,r)}};function tl(t){return Ce(t)?t.reduce((e,r)=>(e[r]=null,e),{}):t}let sa=!0;function of(t){const e=Xa(t),r=t.proxy,n=t.ctx;sa=!1,e.beforeCreate&&rl(e.beforeCreate,t,"bc");const{data:i,computed:s,methods:a,watch:o,provide:l,inject:c,created:u,beforeMount:f,mounted:p,beforeUpdate:g,updated:b,activated:x,deactivated:w,beforeDestroy:N,beforeUnmount:y,destroyed:k,unmounted:I,render:D,renderTracked:O,renderTriggered:z,errorCaptured:W,serverPrefetch:H,expose:oe,inheritAttrs:me,components:ye,directives:Le,filters:ze}=e;if(c&&lf(c,n,null),a)for(const ke in a){const he=a[ke];Ne(he)&&(n[ke]=he.bind(r))}if(i){const ke=i.call(r,r);ot(ke)&&(t.data=ja(ke))}if(sa=!0,s)for(const ke in s){const he=s[ke],je=Ne(he)?he.bind(r,r):Ne(he.get)?he.get.bind(r,r):dr,Ke=!Ne(he)&&Ne(he.set)?he.set.bind(r):dr,Be=Ju({get:je,set:Ke});Object.defineProperty(n,ke,{enumerable:!0,configurable:!0,get:()=>Be.value,set:ge=>Be.value=ge})}if(o)for(const ke in o)Nu(o[ke],n,r,ke);if(l){const ke=Ne(l)?l.call(r):l;Reflect.ownKeys(ke).forEach(he=>{pf(he,ke[he])})}u&&rl(u,t,"c");function Oe(ke,he){Ce(he)?he.forEach(je=>ke(je.bind(r))):he&&ke(he.bind(r))}if(Oe(Xh,f),Oe(Ka,p),Oe(Jh,g),Oe(Zh,b),Oe(Gh,x),Oe(Kh,w),Oe(nf,W),Oe(rf,O),Oe(tf,z),Oe(Qh,y),Oe(Ya,I),Oe(ef,H),Ce(oe))if(oe.length){const ke=t.exposed||(t.exposed={});oe.forEach(he=>{Object.defineProperty(ke,he,{get:()=>r[he],set:je=>r[he]=je,enumerable:!0})})}else t.exposed||(t.exposed={});D&&t.render===dr&&(t.render=D),me!=null&&(t.inheritAttrs=me),ye&&(t.components=ye),Le&&(t.directives=Le),H&&Au(t)}function lf(t,e,r=dr){Ce(t)&&(t=aa(t));for(const n in t){const i=t[n];let s;ot(i)?"default"in i?s=ui(i.from||n,i.default,!0):s=ui(i.from||n):s=ui(i),Nt(s)?Object.defineProperty(e,n,{enumerable:!0,configurable:!0,get:()=>s.value,set:a=>s.value=a}):e[n]=s}}function rl(t,e,r){Tr(Ce(t)?t.map(n=>n.bind(e.proxy)):t.bind(e.proxy),e,r)}function Nu(t,e,r,n){let i=n.includes(".")?qu(r,n):()=>r[n];if(ft(t)){const s=e[t];Ne(s)&&p0(i,s)}else if(Ne(t))p0(i,t.bind(r));else if(ot(t))if(Ce(t))t.forEach(s=>Nu(s,e,r,n));else{const s=Ne(t.handler)?t.handler.bind(r):e[t.handler];Ne(s)&&p0(i,s,t)}}function Xa(t){const e=t.type,{mixins:r,extends:n}=e,{mixins:i,optionsCache:s,config:{optionMergeStrategies:a}}=t.appContext,o=s.get(e);let l;return o?l=o:!i.length&&!r&&!n?l=e:(l={},i.length&&i.forEach(c=>Ei(l,c,a,!0)),Ei(l,e,a)),ot(e)&&s.set(e,l),l}function Ei(t,e,r,n=!1){const{mixins:i,extends:s}=e;s&&Ei(t,s,r,!0),i&&i.forEach(a=>Ei(t,a,r,!0));for(const a in e)if(!(n&&a==="expose")){const o=cf[a]||r&&r[a];t[a]=o?o(t[a],e[a]):e[a]}return t}const cf={data:nl,props:il,emits:il,methods:s0,computed:s0,beforeCreate:Dt,created:Dt,beforeMount:Dt,mounted:Dt,beforeUpdate:Dt,updated:Dt,beforeDestroy:Dt,beforeUnmount:Dt,destroyed:Dt,unmounted:Dt,activated:Dt,deactivated:Dt,errorCaptured:Dt,serverPrefetch:Dt,components:s0,directives:s0,watch:df,provide:nl,inject:uf};function nl(t,e){return e?t?function(){return Et(Ne(t)?t.call(this,this):t,Ne(e)?e.call(this,this):e)}:e:t}function uf(t,e){return s0(aa(t),aa(e))}function aa(t){if(Ce(t)){const e={};for(let r=0;r<t.length;r++)e[t[r]]=t[r];return e}return t}function Dt(t,e){return t?[...new Set([].concat(t,e))]:e}function s0(t,e){return t?Et(Object.create(null),t,e):e}function il(t,e){return t?Ce(t)&&Ce(e)?[...new Set([...t,...e])]:Et(Object.create(null),tl(t),tl(e??{})):e}function df(t,e){if(!t)return e;if(!e)return t;const r=Et(Object.create(null),t);for(const n in e)r[n]=Dt(t[n],e[n]);return r}function Iu(){return{app:null,config:{isNativeTag:Kc,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let hf=0;function ff(t,e){return function(n,i=null){Ne(n)||(n=Et({},n)),i!=null&&!ot(i)&&(i=null);const s=Iu(),a=new WeakSet,o=[];let l=!1;const c=s.app={_uid:hf++,_component:n,_props:i,_container:null,_context:s,_instance:null,version:Yf,get config(){return s.config},set config(u){},use(u,...f){return a.has(u)||(u&&Ne(u.install)?(a.add(u),u.install(c,...f)):Ne(u)&&(a.add(u),u(c,...f))),c},mixin(u){return s.mixins.includes(u)||s.mixins.push(u),c},component(u,f){return f?(s.components[u]=f,c):s.components[u]},directive(u,f){return f?(s.directives[u]=f,c):s.directives[u]},mount(u,f,p){if(!l){const g=c._ceVNode||Xt(n,i);return g.appContext=s,p===!0?p="svg":p===!1&&(p=void 0),f&&e?e(g,u):t(g,u,p),l=!0,c._container=u,u.__vue_app__=c,es(g.component)}},onUnmount(u){o.push(u)},unmount(){l&&(Tr(o,c._instance,16),t(null,c._container),delete c._container.__vue_app__)},provide(u,f){return s.provides[u]=f,c},runWithContext(u){const f=Pn;Pn=c;try{return u()}finally{Pn=f}}};return c}}let Pn=null;function pf(t,e){if(_t){let r=_t.provides;const n=_t.parent&&_t.parent.provides;n===r&&(r=_t.provides=Object.create(n)),r[t]=e}}function ui(t,e,r=!1){const n=jf();if(n||Pn){let i=Pn?Pn._context.provides:n?n.parent==null||n.ce?n.vnode.appContext&&n.vnode.appContext.provides:n.parent.provides:void 0;if(i&&t in i)return i[t];if(arguments.length>1)return r&&Ne(e)?e.call(n&&n.proxy):e}}const Ru={},Du=()=>Object.create(Ru),Ou=t=>Object.getPrototypeOf(t)===Ru;function mf(t,e,r,n=!1){const i={},s=Du();t.propsDefaults=Object.create(null),_u(t,e,i,s);for(const a in t.propsOptions[0])a in i||(i[a]=void 0);r?t.props=n?i:Ih(i):t.type.props?t.props=i:t.props=s,t.attrs=s}function gf(t,e,r,n){const{props:i,attrs:s,vnode:{patchFlag:a}}=t,o=Ue(i),[l]=t.propsOptions;let c=!1;if((n||a>0)&&!(a&16)){if(a&8){const u=t.vnode.dynamicProps;for(let f=0;f<u.length;f++){let p=u[f];if(Zi(t.emitsOptions,p))continue;const g=e[p];if(l)if(Ve(s,p))g!==s[p]&&(s[p]=g,c=!0);else{const b=tn(p);i[b]=oa(l,o,b,g,t,!1)}else g!==s[p]&&(s[p]=g,c=!0)}}}else{_u(t,e,i,s)&&(c=!0);let u;for(const f in o)(!e||!Ve(e,f)&&((u=cn(f))===f||!Ve(e,u)))&&(l?r&&(r[f]!==void 0||r[u]!==void 0)&&(i[f]=oa(l,o,f,void 0,t,!0)):delete i[f]);if(s!==o)for(const f in s)(!e||!Ve(e,f))&&(delete s[f],c=!0)}c&&Or(t.attrs,"set","")}function _u(t,e,r,n){const[i,s]=t.propsOptions;let a=!1,o;if(e)for(let l in e){if(l0(l))continue;const c=e[l];let u;i&&Ve(i,u=tn(l))?!s||!s.includes(u)?r[u]=c:(o||(o={}))[u]=c:Zi(t.emitsOptions,l)||(!(l in n)||c!==n[l])&&(n[l]=c,a=!0)}if(s){const l=Ue(r),c=o||Ze;for(let u=0;u<s.length;u++){const f=s[u];r[f]=oa(i,l,f,c[f],t,!Ve(c,f))}}return a}function oa(t,e,r,n,i,s){const a=t[r];if(a!=null){const o=Ve(a,"default");if(o&&n===void 0){const l=a.default;if(a.type!==Function&&!a.skipFactory&&Ne(l)){const{propsDefaults:c}=i;if(r in c)n=c[r];else{const u=M0(i);n=c[r]=l.call(null,e),u()}}else n=l;i.ce&&i.ce._setProp(r,n)}a[0]&&(s&&!o?n=!1:a[1]&&(n===""||n===cn(r))&&(n=!0))}return n}const vf=new WeakMap;function Lu(t,e,r=!1){const n=r?vf:e.propsCache,i=n.get(t);if(i)return i;const s=t.props,a={},o=[];let l=!1;if(!Ne(t)){const u=f=>{l=!0;const[p,g]=Lu(f,e,!0);Et(a,p),g&&o.push(...g)};!r&&e.mixins.length&&e.mixins.forEach(u),t.extends&&u(t.extends),t.mixins&&t.mixins.forEach(u)}if(!s&&!l)return ot(t)&&n.set(t,zn),zn;if(Ce(s))for(let u=0;u<s.length;u++){const f=tn(s[u]);sl(f)&&(a[f]=Ze)}else if(s)for(const u in s){const f=tn(u);if(sl(f)){const p=s[u],g=a[f]=Ce(p)||Ne(p)?{type:p}:Et({},p),b=g.type;let x=!1,w=!0;if(Ce(b))for(let N=0;N<b.length;++N){const y=b[N],k=Ne(y)&&y.name;if(k==="Boolean"){x=!0;break}else k==="String"&&(w=!1)}else x=Ne(b)&&b.name==="Boolean";g[0]=x,g[1]=w,(x||Ve(g,"default"))&&o.push(f)}}const c=[a,o];return ot(t)&&n.set(t,c),c}function sl(t){return t[0]!=="$"&&!l0(t)}const Ja=t=>t==="_"||t==="_ctx"||t==="$stable",Za=t=>Ce(t)?t.map(wr):[wr(t)],bf=(t,e,r)=>{if(e._n)return e;const n=jh((...i)=>Za(e(...i)),r);return n._c=!1,n},zu=(t,e,r)=>{const n=t._ctx;for(const i in t){if(Ja(i))continue;const s=t[i];if(Ne(s))e[i]=bf(i,s,n);else if(s!=null){const a=Za(s);e[i]=()=>a}}},$u=(t,e)=>{const r=Za(e);t.slots.default=()=>r},Fu=(t,e,r)=>{for(const n in e)(r||!Ja(n))&&(t[n]=e[n])},yf=(t,e,r)=>{const n=t.slots=Du();if(t.vnode.shapeFlag&32){const i=e._;i?(Fu(n,e,r),r&&eu(n,"_",i,!0)):zu(e,n)}else e&&$u(t,e)},wf=(t,e,r)=>{const{vnode:n,slots:i}=t;let s=!0,a=Ze;if(n.shapeFlag&32){const o=e._;o?r&&o===1?s=!1:Fu(i,e,r):(s=!e.$stable,zu(e,i)),a=e}else e&&($u(t,e),a={default:1});if(s)for(const o in i)!Ja(o)&&a[o]==null&&delete i[o]},Vt=_f;function xf(t){return kf(t)}function kf(t,e){const r=Ki();r.__VUE__=!0;const{insert:n,remove:i,patchProp:s,createElement:a,createText:o,createComment:l,setText:c,setElementText:u,parentNode:f,nextSibling:p,setScopeId:g=dr,insertStaticContent:b}=t,x=(S,C,$,q=null,B=null,U=null,Z=void 0,ee=null,re=!!C.dynamicChildren)=>{if(S===C)return;S&&!Qn(S,C)&&(q=lt(S),ge(S,B,U,!0),S=null),C.patchFlag===-2&&(re=!1,C.dynamicChildren=null);const{type:K,ref:le,shapeFlag:ae}=C;switch(K){case Qi:w(S,C,$,q);break;case nn:N(S,C,$,q);break;case di:S==null&&y(C,$,q,Z);break;case ur:ye(S,C,$,q,B,U,Z,ee,re);break;default:ae&1?D(S,C,$,q,B,U,Z,ee,re):ae&6?Le(S,C,$,q,B,U,Z,ee,re):(ae&64||ae&128)&&K.process(S,C,$,q,B,U,Z,ee,re,J)}le!=null&&B?d0(le,S&&S.ref,U,C||S,!C):le==null&&S&&S.ref!=null&&d0(S.ref,null,U,S,!0)},w=(S,C,$,q)=>{if(S==null)n(C.el=o(C.children),$,q);else{const B=C.el=S.el;C.children!==S.children&&c(B,C.children)}},N=(S,C,$,q)=>{S==null?n(C.el=l(C.children||""),$,q):C.el=S.el},y=(S,C,$,q)=>{[S.el,S.anchor]=b(S.children,C,$,q,S.el,S.anchor)},k=({el:S,anchor:C},$,q)=>{let B;for(;S&&S!==C;)B=p(S),n(S,$,q),S=B;n(C,$,q)},I=({el:S,anchor:C})=>{let $;for(;S&&S!==C;)$=p(S),i(S),S=$;i(C)},D=(S,C,$,q,B,U,Z,ee,re)=>{C.type==="svg"?Z="svg":C.type==="math"&&(Z="mathml"),S==null?O(C,$,q,B,U,Z,ee,re):H(S,C,B,U,Z,ee,re)},O=(S,C,$,q,B,U,Z,ee)=>{let re,K;const{props:le,shapeFlag:ae,transition:pe,dirs:Se}=S;if(re=S.el=a(S.type,U,le&&le.is,le),ae&8?u(re,S.children):ae&16&&W(S.children,re,null,q,B,Es(S,U),Z,ee),Se&&fn(S,null,q,"created"),z(re,S,S.scopeId,Z,q),le){for(const Ye in le)Ye!=="value"&&!l0(Ye)&&s(re,Ye,null,le[Ye],U,q);"value"in le&&s(re,"value",null,le.value,U),(K=le.onVnodeBeforeMount)&&mr(K,q,S)}Se&&fn(S,null,q,"beforeMount");const Re=Sf(B,pe);Re&&pe.beforeEnter(re),n(re,C,$),((K=le&&le.onVnodeMounted)||Re||Se)&&Vt(()=>{K&&mr(K,q,S),Re&&pe.enter(re),Se&&fn(S,null,q,"mounted")},B)},z=(S,C,$,q,B)=>{if($&&g(S,$),q)for(let U=0;U<q.length;U++)g(S,q[U]);if(B){let U=B.subTree;if(C===U||Uu(U.type)&&(U.ssContent===C||U.ssFallback===C)){const Z=B.vnode;z(S,Z,Z.scopeId,Z.slotScopeIds,B.parent)}}},W=(S,C,$,q,B,U,Z,ee,re=0)=>{for(let K=re;K<S.length;K++){const le=S[K]=ee?Jr(S[K]):wr(S[K]);x(null,le,C,$,q,B,U,Z,ee)}},H=(S,C,$,q,B,U,Z)=>{const ee=C.el=S.el;let{patchFlag:re,dynamicChildren:K,dirs:le}=C;re|=S.patchFlag&16;const ae=S.props||Ze,pe=C.props||Ze;let Se;if($&&pn($,!1),(Se=pe.onVnodeBeforeUpdate)&&mr(Se,$,C,S),le&&fn(C,S,$,"beforeUpdate"),$&&pn($,!0),(ae.innerHTML&&pe.innerHTML==null||ae.textContent&&pe.textContent==null)&&u(ee,""),K?oe(S.dynamicChildren,K,ee,$,q,Es(C,B),U):Z||he(S,C,ee,null,$,q,Es(C,B),U,!1),re>0){if(re&16)me(ee,ae,pe,$,B);else if(re&2&&ae.class!==pe.class&&s(ee,"class",null,pe.class,B),re&4&&s(ee,"style",ae.style,pe.style,B),re&8){const Re=C.dynamicProps;for(let Ye=0;Ye<Re.length;Ye++){const Pe=Re[Ye],Tt=ae[Pe],nt=pe[Pe];(nt!==Tt||Pe==="value")&&s(ee,Pe,Tt,nt,B,$)}}re&1&&S.children!==C.children&&u(ee,C.children)}else!Z&&K==null&&me(ee,ae,pe,$,B);((Se=pe.onVnodeUpdated)||le)&&Vt(()=>{Se&&mr(Se,$,C,S),le&&fn(C,S,$,"updated")},q)},oe=(S,C,$,q,B,U,Z)=>{for(let ee=0;ee<C.length;ee++){const re=S[ee],K=C[ee],le=re.el&&(re.type===ur||!Qn(re,K)||re.shapeFlag&198)?f(re.el):$;x(re,K,le,null,q,B,U,Z,!0)}},me=(S,C,$,q,B)=>{if(C!==$){if(C!==Ze)for(const U in C)!l0(U)&&!(U in $)&&s(S,U,C[U],null,B,q);for(const U in $){if(l0(U))continue;const Z=$[U],ee=C[U];Z!==ee&&U!=="value"&&s(S,U,ee,Z,B,q)}"value"in $&&s(S,"value",C.value,$.value,B)}},ye=(S,C,$,q,B,U,Z,ee,re)=>{const K=C.el=S?S.el:o(""),le=C.anchor=S?S.anchor:o("");let{patchFlag:ae,dynamicChildren:pe,slotScopeIds:Se}=C;Se&&(ee=ee?ee.concat(Se):Se),S==null?(n(K,$,q),n(le,$,q),W(C.children||[],$,le,B,U,Z,ee,re)):ae>0&&ae&64&&pe&&S.dynamicChildren?(oe(S.dynamicChildren,pe,$,B,U,Z,ee),(C.key!=null||B&&C===B.subTree)&&Bu(S,C,!0)):he(S,C,$,le,B,U,Z,ee,re)},Le=(S,C,$,q,B,U,Z,ee,re)=>{C.slotScopeIds=ee,S==null?C.shapeFlag&512?B.ctx.activate(C,$,q,Z,re):ze(C,$,q,B,U,Z,re):Ge(S,C,re)},ze=(S,C,$,q,B,U,Z)=>{const ee=S.component=qf(S,q,B);if(Eu(S)&&(ee.ctx.renderer=J),Uf(ee,!1,Z),ee.asyncDep){if(B&&B.registerDep(ee,Oe,Z),!S.el){const re=ee.subTree=Xt(nn);N(null,re,C,$),S.placeholder=re.el}}else Oe(ee,S,C,$,B,U,Z)},Ge=(S,C,$)=>{const q=C.component=S.component;if(Df(S,C,$))if(q.asyncDep&&!q.asyncResolved){ke(q,C,$);return}else q.next=C,q.update();else C.el=S.el,q.vnode=C},Oe=(S,C,$,q,B,U,Z)=>{const ee=()=>{if(S.isMounted){let{next:ae,bu:pe,u:Se,parent:Re,vnode:Ye}=S;{const wt=Pu(S);if(wt){ae&&(ae.el=Ye.el,ke(S,ae,Z)),wt.asyncDep.then(()=>{S.isUnmounted||ee()});return}}let Pe=ae,Tt;pn(S,!1),ae?(ae.el=Ye.el,ke(S,ae,Z)):ae=Ye,pe&&ci(pe),(Tt=ae.props&&ae.props.onVnodeBeforeUpdate)&&mr(Tt,Re,ae,Ye),pn(S,!0);const nt=Cs(S),gt=S.subTree;S.subTree=nt,x(gt,nt,f(gt.el),lt(gt),S,B,U),ae.el=nt.el,Pe===null&&Of(S,nt.el),Se&&Vt(Se,B),(Tt=ae.props&&ae.props.onVnodeUpdated)&&Vt(()=>mr(Tt,Re,ae,Ye),B)}else{let ae;const{el:pe,props:Se}=C,{bm:Re,m:Ye,parent:Pe,root:Tt,type:nt}=S,gt=h0(C);if(pn(S,!1),Re&&ci(Re),!gt&&(ae=Se&&Se.onVnodeBeforeMount)&&mr(ae,Pe,C),pn(S,!0),pe&&be){const wt=()=>{S.subTree=Cs(S),be(pe,S.subTree,S,B,null)};gt&&nt.__asyncHydrate?nt.__asyncHydrate(pe,S,wt):wt()}else{Tt.ce&&Tt.ce._def.shadowRoot!==!1&&Tt.ce._injectChildStyle(nt);const wt=S.subTree=Cs(S);x(null,wt,$,q,S,B,U),C.el=wt.el}if(Ye&&Vt(Ye,B),!gt&&(ae=Se&&Se.onVnodeMounted)){const wt=C;Vt(()=>mr(ae,Pe,wt),B)}(C.shapeFlag&256||Pe&&h0(Pe.vnode)&&Pe.vnode.shapeFlag&256)&&S.a&&Vt(S.a,B),S.isMounted=!0,C=$=q=null}};S.scope.on();const re=S.effect=new iu(ee);S.scope.off();const K=S.update=re.run.bind(re),le=S.job=re.runIfDirty.bind(re);le.i=S,le.id=S.uid,re.scheduler=()=>Wa(le),pn(S,!0),K()},ke=(S,C,$)=>{C.component=S;const q=S.vnode.props;S.vnode=C,S.next=null,gf(S,C.props,q,$),wf(S,C.children,$),Br(),el(S),Pr()},he=(S,C,$,q,B,U,Z,ee,re=!1)=>{const K=S&&S.children,le=S?S.shapeFlag:0,ae=C.children,{patchFlag:pe,shapeFlag:Se}=C;if(pe>0){if(pe&128){Ke(K,ae,$,q,B,U,Z,ee,re);return}else if(pe&256){je(K,ae,$,q,B,U,Z,ee,re);return}}Se&8?(le&16&&St(K,B,U),ae!==K&&u($,ae)):le&16?Se&16?Ke(K,ae,$,q,B,U,Z,ee,re):St(K,B,U,!0):(le&8&&u($,""),Se&16&&W(ae,$,q,B,U,Z,ee,re))},je=(S,C,$,q,B,U,Z,ee,re)=>{S=S||zn,C=C||zn;const K=S.length,le=C.length,ae=Math.min(K,le);let pe;for(pe=0;pe<ae;pe++){const Se=C[pe]=re?Jr(C[pe]):wr(C[pe]);x(S[pe],Se,$,null,B,U,Z,ee,re)}K>le?St(S,B,U,!0,!1,ae):W(C,$,q,B,U,Z,ee,re,ae)},Ke=(S,C,$,q,B,U,Z,ee,re)=>{let K=0;const le=C.length;let ae=S.length-1,pe=le-1;for(;K<=ae&&K<=pe;){const Se=S[K],Re=C[K]=re?Jr(C[K]):wr(C[K]);if(Qn(Se,Re))x(Se,Re,$,null,B,U,Z,ee,re);else break;K++}for(;K<=ae&&K<=pe;){const Se=S[ae],Re=C[pe]=re?Jr(C[pe]):wr(C[pe]);if(Qn(Se,Re))x(Se,Re,$,null,B,U,Z,ee,re);else break;ae--,pe--}if(K>ae){if(K<=pe){const Se=pe+1,Re=Se<le?C[Se].el:q;for(;K<=pe;)x(null,C[K]=re?Jr(C[K]):wr(C[K]),$,Re,B,U,Z,ee,re),K++}}else if(K>pe)for(;K<=ae;)ge(S[K],B,U,!0),K++;else{const Se=K,Re=K,Ye=new Map;for(K=Re;K<=pe;K++){const It=C[K]=re?Jr(C[K]):wr(C[K]);It.key!=null&&Ye.set(It.key,K)}let Pe,Tt=0;const nt=pe-Re+1;let gt=!1,wt=0;const hn=new Array(nt);for(K=0;K<nt;K++)hn[K]=0;for(K=Se;K<=ae;K++){const It=S[K];if(Tt>=nt){ge(It,B,U,!0);continue}let Bt;if(It.key!=null)Bt=Ye.get(It.key);else for(Pe=Re;Pe<=pe;Pe++)if(hn[Pe-Re]===0&&Qn(It,C[Pe])){Bt=Pe;break}Bt===void 0?ge(It,B,U,!0):(hn[Bt-Re]=K+1,Bt>=wt?wt=Bt:gt=!0,x(It,C[Bt],$,null,B,U,Z,ee,re),Tt++)}const F0=gt?Tf(hn):zn;for(Pe=F0.length-1,K=nt-1;K>=0;K--){const It=Re+K,Bt=C[It],B0=C[It+1],P0=It+1<le?B0.el||B0.placeholder:q;hn[K]===0?x(null,Bt,$,P0,B,U,Z,ee,re):gt&&(Pe<0||K!==F0[Pe]?Be(Bt,$,P0,2):Pe--)}}},Be=(S,C,$,q,B=null)=>{const{el:U,type:Z,transition:ee,children:re,shapeFlag:K}=S;if(K&6){Be(S.component.subTree,C,$,q);return}if(K&128){S.suspense.move(C,$,q);return}if(K&64){Z.move(S,C,$,J);return}if(Z===ur){n(U,C,$);for(let ae=0;ae<re.length;ae++)Be(re[ae],C,$,q);n(S.anchor,C,$);return}if(Z===di){k(S,C,$);return}if(q!==2&&K&1&&ee)if(q===0)ee.beforeEnter(U),n(U,C,$),Vt(()=>ee.enter(U),B);else{const{leave:ae,delayLeave:pe,afterLeave:Se}=ee,Re=()=>{S.ctx.isUnmounted?i(U):n(U,C,$)},Ye=()=>{U._isLeaving&&U[Wh](!0),ae(U,()=>{Re(),Se&&Se()})};pe?pe(U,Re,Ye):Ye()}else n(U,C,$)},ge=(S,C,$,q=!1,B=!1)=>{const{type:U,props:Z,ref:ee,children:re,dynamicChildren:K,shapeFlag:le,patchFlag:ae,dirs:pe,cacheIndex:Se}=S;if(ae===-2&&(B=!1),ee!=null&&(Br(),d0(ee,null,$,S,!0),Pr()),Se!=null&&(C.renderCache[Se]=void 0),le&256){C.ctx.deactivate(S);return}const Re=le&1&&pe,Ye=!h0(S);let Pe;if(Ye&&(Pe=Z&&Z.onVnodeBeforeUnmount)&&mr(Pe,C,S),le&6)yt(S.component,$,q);else{if(le&128){S.suspense.unmount($,q);return}Re&&fn(S,null,C,"beforeUnmount"),le&64?S.type.remove(S,C,$,J,q):K&&!K.hasOnce&&(U!==ur||ae>0&&ae&64)?St(K,C,$,!1,!0):(U===ur&&ae&384||!B&&le&16)&&St(re,C,$),q&&Ft(S)}(Ye&&(Pe=Z&&Z.onVnodeUnmounted)||Re)&&Vt(()=>{Pe&&mr(Pe,C,S),Re&&fn(S,null,C,"unmounted")},$)},Ft=S=>{const{type:C,el:$,anchor:q,transition:B}=S;if(C===ur){ht($,q);return}if(C===di){I(S);return}const U=()=>{i($),B&&!B.persisted&&B.afterLeave&&B.afterLeave()};if(S.shapeFlag&1&&B&&!B.persisted){const{leave:Z,delayLeave:ee}=B,re=()=>Z($,U);ee?ee(S.el,U,re):re()}else U()},ht=(S,C)=>{let $;for(;S!==C;)$=p(S),i(S),S=$;i(C)},yt=(S,C,$)=>{const{bum:q,scope:B,job:U,subTree:Z,um:ee,m:re,a:K}=S;al(re),al(K),q&&ci(q),B.stop(),U&&(U.flags|=8,ge(Z,S,C,$)),ee&&Vt(ee,C),Vt(()=>{S.isUnmounted=!0},C)},St=(S,C,$,q=!1,B=!1,U=0)=>{for(let Z=U;Z<S.length;Z++)ge(S[Z],C,$,q,B)},lt=S=>{if(S.shapeFlag&6)return lt(S.component.subTree);if(S.shapeFlag&128)return S.suspense.next();const C=p(S.anchor||S.el),$=C&&C[Uh];return $?p($):C};let j=!1;const G=(S,C,$)=>{S==null?C._vnode&&ge(C._vnode,null,null,!0):x(C._vnode||null,S,C,null,null,null,$),C._vnode=S,j||(j=!0,el(),ku(),j=!1)},J={p:x,um:ge,m:Be,r:Ft,mt:ze,mc:W,pc:he,pbc:oe,n:lt,o:t};let ne,be;return e&&([ne,be]=e(J)),{render:G,hydrate:ne,createApp:ff(G,ne)}}function Es({type:t,props:e},r){return r==="svg"&&t==="foreignObject"||r==="mathml"&&t==="annotation-xml"&&e&&e.encoding&&e.encoding.includes("html")?void 0:r}function pn({effect:t,job:e},r){r?(t.flags|=32,e.flags|=4):(t.flags&=-33,e.flags&=-5)}function Sf(t,e){return(!t||t&&!t.pendingBranch)&&e&&!e.persisted}function Bu(t,e,r=!1){const n=t.children,i=e.children;if(Ce(n)&&Ce(i))for(let s=0;s<n.length;s++){const a=n[s];let o=i[s];o.shapeFlag&1&&!o.dynamicChildren&&((o.patchFlag<=0||o.patchFlag===32)&&(o=i[s]=Jr(i[s]),o.el=a.el),!r&&o.patchFlag!==-2&&Bu(a,o)),o.type===Qi&&o.patchFlag!==-1&&(o.el=a.el),o.type===nn&&!o.el&&(o.el=a.el)}}function Tf(t){const e=t.slice(),r=[0];let n,i,s,a,o;const l=t.length;for(n=0;n<l;n++){const c=t[n];if(c!==0){if(i=r[r.length-1],t[i]<c){e[n]=i,r.push(n);continue}for(s=0,a=r.length-1;s<a;)o=s+a>>1,t[r[o]]<c?s=o+1:a=o;c<t[r[s]]&&(s>0&&(e[n]=r[s-1]),r[s]=n)}}for(s=r.length,a=r[s-1];s-- >0;)r[s]=a,a=e[a];return r}function Pu(t){const e=t.subTree.component;if(e)return e.asyncDep&&!e.asyncResolved?e:Pu(e)}function al(t){if(t)for(let e=0;e<t.length;e++)t[e].flags|=8}const Af=Symbol.for("v-scx"),Ef=()=>ui(Af);function p0(t,e,r){return Hu(t,e,r)}function Hu(t,e,r=Ze){const{immediate:n,deep:i,flush:s,once:a}=r,o=Et({},r),l=e&&n||!e&&s!=="post";let c;if(k0){if(s==="sync"){const g=Ef();c=g.__watcherHandles||(g.__watcherHandles=[])}else if(!l){const g=()=>{};return g.stop=dr,g.resume=dr,g.pause=dr,g}}const u=_t;o.call=(g,b,x)=>Tr(g,u,b,x);let f=!1;s==="post"?o.scheduler=g=>{Vt(g,u&&u.suspense)}:s!=="sync"&&(f=!0,o.scheduler=(g,b)=>{b?g():Wa(g)}),o.augmentJob=g=>{e&&(g.flags|=4),f&&(g.flags|=2,u&&(g.id=u.uid,g.i=u))};const p=Bh(t,e,o);return k0&&(c?c.push(p):l&&p()),p}function Cf(t,e,r){const n=this.proxy,i=ft(t)?t.includes(".")?qu(n,t):()=>n[t]:t.bind(n,n);let s;Ne(e)?s=e:(s=e.handler,r=e);const a=M0(this),o=Hu(i,s.bind(n),r);return a(),o}function qu(t,e){const r=e.split(".");return()=>{let n=t;for(let i=0;i<r.length&&n;i++)n=n[r[i]];return n}}const Mf=(t,e)=>e==="modelValue"||e==="model-value"?t.modelModifiers:t[`${e}Modifiers`]||t[`${tn(e)}Modifiers`]||t[`${cn(e)}Modifiers`];function Nf(t,e,...r){if(t.isUnmounted)return;const n=t.vnode.props||Ze;let i=r;const s=e.startsWith("update:"),a=s&&Mf(n,e.slice(7));a&&(a.trim&&(i=r.map(u=>ft(u)?u.trim():u)),a.number&&(i=r.map(Qs)));let o,l=n[o=ws(e)]||n[o=ws(tn(e))];!l&&s&&(l=n[o=ws(cn(e))]),l&&Tr(l,t,6,i);const c=n[o+"Once"];if(c){if(!t.emitted)t.emitted={};else if(t.emitted[o])return;t.emitted[o]=!0,Tr(c,t,6,i)}}function ju(t,e,r=!1){const n=e.emitsCache,i=n.get(t);if(i!==void 0)return i;const s=t.emits;let a={},o=!1;if(!Ne(t)){const l=c=>{const u=ju(c,e,!0);u&&(o=!0,Et(a,u))};!r&&e.mixins.length&&e.mixins.forEach(l),t.extends&&l(t.extends),t.mixins&&t.mixins.forEach(l)}return!s&&!o?(ot(t)&&n.set(t,null),null):(Ce(s)?s.forEach(l=>a[l]=null):Et(a,s),ot(t)&&n.set(t,a),a)}function Zi(t,e){return!t||!Vi(e)?!1:(e=e.slice(2).replace(/Once$/,""),Ve(t,e[0].toLowerCase()+e.slice(1))||Ve(t,cn(e))||Ve(t,e))}function Cs(t){const{type:e,vnode:r,proxy:n,withProxy:i,propsOptions:[s],slots:a,attrs:o,emit:l,render:c,renderCache:u,props:f,data:p,setupState:g,ctx:b,inheritAttrs:x}=t,w=Ti(t);let N,y;try{if(r.shapeFlag&4){const I=i||n,D=I;N=wr(c.call(D,I,u,f,g,p,b)),y=o}else{const I=e;N=wr(I.length>1?I(f,{attrs:o,slots:a,emit:l}):I(f,null)),y=e.props?o:If(o)}}catch(I){m0.length=0,Xi(I,t,1),N=Xt(nn)}let k=N;if(y&&x!==!1){const I=Object.keys(y),{shapeFlag:D}=k;I.length&&D&7&&(s&&I.some(La)&&(y=Rf(y,s)),k=Vn(k,y,!1,!0))}return r.dirs&&(k=Vn(k,null,!1,!0),k.dirs=k.dirs?k.dirs.concat(r.dirs):r.dirs),r.transition&&Ga(k,r.transition),N=k,Ti(w),N}const If=t=>{let e;for(const r in t)(r==="class"||r==="style"||Vi(r))&&((e||(e={}))[r]=t[r]);return e},Rf=(t,e)=>{const r={};for(const n in t)(!La(n)||!(n.slice(9)in e))&&(r[n]=t[n]);return r};function Df(t,e,r){const{props:n,children:i,component:s}=t,{props:a,children:o,patchFlag:l}=e,c=s.emitsOptions;if(e.dirs||e.transition)return!0;if(r&&l>=0){if(l&1024)return!0;if(l&16)return n?ol(n,a,c):!!a;if(l&8){const u=e.dynamicProps;for(let f=0;f<u.length;f++){const p=u[f];if(a[p]!==n[p]&&!Zi(c,p))return!0}}}else return(i||o)&&(!o||!o.$stable)?!0:n===a?!1:n?a?ol(n,a,c):!0:!!a;return!1}function ol(t,e,r){const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!0;for(let i=0;i<n.length;i++){const s=n[i];if(e[s]!==t[s]&&!Zi(r,s))return!0}return!1}function Of({vnode:t,parent:e},r){for(;e;){const n=e.subTree;if(n.suspense&&n.suspense.activeBranch===t&&(n.el=t.el),n===t)(t=e.vnode).el=r,e=e.parent;else break}}const Uu=t=>t.__isSuspense;function _f(t,e){e&&e.pendingBranch?Ce(t)?e.effects.push(...t):e.effects.push(t):qh(t)}const ur=Symbol.for("v-fgt"),Qi=Symbol.for("v-txt"),nn=Symbol.for("v-cmt"),di=Symbol.for("v-stc"),m0=[];let Yt=null;function Fe(t=!1){m0.push(Yt=t?null:[])}function Lf(){m0.pop(),Yt=m0[m0.length-1]||null}let x0=1;function ll(t,e=!1){x0+=t,t<0&&Yt&&e&&(Yt.hasOnce=!0)}function Vu(t){return t.dynamicChildren=x0>0?Yt||zn:null,Lf(),x0>0&&Yt&&Yt.push(t),t}function He(t,e,r,n,i,s){return Vu(Y(t,e,r,n,i,s,!0))}function zf(t,e,r,n,i){return Vu(Xt(t,e,r,n,i,!0))}function Wu(t){return t?t.__v_isVNode===!0:!1}function Qn(t,e){return t.type===e.type&&t.key===e.key}const Gu=({key:t})=>t??null,hi=({ref:t,ref_key:e,ref_for:r})=>(typeof t=="number"&&(t=""+t),t!=null?ft(t)||Nt(t)||Ne(t)?{i:Qt,r:t,k:e,f:!!r}:t:null);function Y(t,e=null,r=null,n=0,i=null,s=t===ur?0:1,a=!1,o=!1){const l={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&Gu(e),ref:e&&hi(e),scopeId:Tu,slotScopeIds:null,children:r,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:s,patchFlag:n,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Qt};return o?(Qa(l,r),s&128&&t.normalize(l)):r&&(l.shapeFlag|=ft(r)?8:16),x0>0&&!a&&Yt&&(l.patchFlag>0||s&6)&&l.patchFlag!==32&&Yt.push(l),l}const Xt=$f;function $f(t,e=null,r=null,n=0,i=null,s=!1){if((!t||t===sf)&&(t=nn),Wu(t)){const o=Vn(t,e,!0);return r&&Qa(o,r),x0>0&&!s&&Yt&&(o.shapeFlag&6?Yt[Yt.indexOf(t)]=o:Yt.push(o)),o.patchFlag=-2,o}if(Kf(t)&&(t=t.__vccOpts),e){e=Ff(e);let{class:o,style:l}=e;o&&!ft(o)&&(e.class=Un(o)),ot(l)&&(Va(l)&&!Ce(l)&&(l=Et({},l)),e.style=jn(l))}const a=ft(t)?1:Uu(t)?128:Vh(t)?64:ot(t)?4:Ne(t)?2:0;return Y(t,e,r,n,i,a,s,!0)}function Ff(t){return t?Va(t)||Ou(t)?Et({},t):t:null}function Vn(t,e,r=!1,n=!1){const{props:i,ref:s,patchFlag:a,children:o,transition:l}=t,c=e?Bf(i||{},e):i,u={__v_isVNode:!0,__v_skip:!0,type:t.type,props:c,key:c&&Gu(c),ref:e&&e.ref?r&&s?Ce(s)?s.concat(hi(e)):[s,hi(e)]:hi(e):s,scopeId:t.scopeId,slotScopeIds:t.slotScopeIds,children:o,target:t.target,targetStart:t.targetStart,targetAnchor:t.targetAnchor,staticCount:t.staticCount,shapeFlag:t.shapeFlag,patchFlag:e&&t.type!==ur?a===-1?16:a|16:a,dynamicProps:t.dynamicProps,dynamicChildren:t.dynamicChildren,appContext:t.appContext,dirs:t.dirs,transition:l,component:t.component,suspense:t.suspense,ssContent:t.ssContent&&Vn(t.ssContent),ssFallback:t.ssFallback&&Vn(t.ssFallback),placeholder:t.placeholder,el:t.el,anchor:t.anchor,ctx:t.ctx,ce:t.ce};return l&&n&&Ga(u,l.clone(u)),u}function Ku(t=" ",e=0){return Xt(Qi,null,t,e)}function cl(t,e){const r=Xt(di,null,t);return r.staticCount=e,r}function yr(t="",e=!1){return e?(Fe(),zf(nn,null,t)):Xt(nn,null,t)}function wr(t){return t==null||typeof t=="boolean"?Xt(nn):Ce(t)?Xt(ur,null,t.slice()):Wu(t)?Jr(t):Xt(Qi,null,String(t))}function Jr(t){return t.el===null&&t.patchFlag!==-1||t.memo?t:Vn(t)}function Qa(t,e){let r=0;const{shapeFlag:n}=t;if(e==null)e=null;else if(Ce(e))r=16;else if(typeof e=="object")if(n&65){const i=e.default;i&&(i._c&&(i._d=!1),Qa(t,i()),i._c&&(i._d=!0));return}else{r=32;const i=e._;!i&&!Ou(e)?e._ctx=Qt:i===3&&Qt&&(Qt.slots._===1?e._=1:(e._=2,t.patchFlag|=1024))}else Ne(e)?(e={default:e,_ctx:Qt},r=32):(e=String(e),n&64?(r=16,e=[Ku(e)]):r=8);t.children=e,t.shapeFlag|=r}function Bf(...t){const e={};for(let r=0;r<t.length;r++){const n=t[r];for(const i in n)if(i==="class")e.class!==n.class&&(e.class=Un([e.class,n.class]));else if(i==="style")e.style=jn([e.style,n.style]);else if(Vi(i)){const s=e[i],a=n[i];a&&s!==a&&!(Ce(s)&&s.includes(a))&&(e[i]=s?[].concat(s,a):a)}else i!==""&&(e[i]=n[i])}return e}function mr(t,e,r,n=null){Tr(t,e,7,[r,n])}const Pf=Iu();let Hf=0;function qf(t,e,r){const n=t.type,i=(e?e.appContext:t.appContext)||Pf,s={uid:Hf++,vnode:t,type:n,parent:e,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new uh(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:e?e.provides:Object.create(i.provides),ids:e?e.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Lu(n,i),emitsOptions:ju(n,i),emit:null,emitted:null,propsDefaults:Ze,inheritAttrs:n.inheritAttrs,ctx:Ze,data:Ze,props:Ze,attrs:Ze,slots:Ze,refs:Ze,setupState:Ze,setupContext:null,suspense:r,suspenseId:r?r.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return s.ctx={_:s},s.root=e?e.root:s,s.emit=Nf.bind(null,s),t.ce&&t.ce(s),s}let _t=null;const jf=()=>_t||Qt;let Ci,la;{const t=Ki(),e=(r,n)=>{let i;return(i=t[r])||(i=t[r]=[]),i.push(n),s=>{i.length>1?i.forEach(a=>a(s)):i[0](s)}};Ci=e("__VUE_INSTANCE_SETTERS__",r=>_t=r),la=e("__VUE_SSR_SETTERS__",r=>k0=r)}const M0=t=>{const e=_t;return Ci(t),t.scope.on(),()=>{t.scope.off(),Ci(e)}},ul=()=>{_t&&_t.scope.off(),Ci(null)};function Yu(t){return t.vnode.shapeFlag&4}let k0=!1;function Uf(t,e=!1,r=!1){e&&la(e);const{props:n,children:i}=t.vnode,s=Yu(t);mf(t,n,s,e),yf(t,i,r||e);const a=s?Vf(t,e):void 0;return e&&la(!1),a}function Vf(t,e){const r=t.type;t.accessCache=Object.create(null),t.proxy=new Proxy(t.ctx,af);const{setup:n}=r;if(n){Br();const i=t.setupContext=n.length>1?Gf(t):null,s=M0(t),a=C0(n,t,0,[t.props,i]),o=Xc(a);if(Pr(),s(),(o||t.sp)&&!h0(t)&&Au(t),o){if(a.then(ul,ul),e)return a.then(l=>{dl(t,l,e)}).catch(l=>{Xi(l,t,0)});t.asyncDep=a}else dl(t,a,e)}else Xu(t,e)}function dl(t,e,r){Ne(e)?t.type.__ssrInlineRender?t.ssrRender=e:t.render=e:ot(e)&&(t.setupState=yu(e)),Xu(t,r)}let hl;function Xu(t,e,r){const n=t.type;if(!t.render){if(!e&&hl&&!n.render){const i=n.template||Xa(t).template;if(i){const{isCustomElement:s,compilerOptions:a}=t.appContext.config,{delimiters:o,compilerOptions:l}=n,c=Et(Et({isCustomElement:s,delimiters:o},a),l);n.render=hl(i,c)}}t.render=n.render||dr}{const i=M0(t);Br();try{of(t)}finally{Pr(),i()}}}const Wf={get(t,e){return Ct(t,"get",""),t[e]}};function Gf(t){const e=r=>{t.exposed=r||{}};return{attrs:new Proxy(t.attrs,Wf),slots:t.slots,emit:t.emit,expose:e}}function es(t){return t.exposed?t.exposeProxy||(t.exposeProxy=new Proxy(yu(Rh(t.exposed)),{get(e,r){if(r in e)return e[r];if(r in f0)return f0[r](t)},has(e,r){return r in e||r in f0}})):t.proxy}function Kf(t){return Ne(t)&&"__vccOpts"in t}const Ju=(t,e)=>$h(t,e,k0),Yf="3.5.20";/**
|
||
* @vue/runtime-dom v3.5.20
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/let ca;const fl=typeof window<"u"&&window.trustedTypes;if(fl)try{ca=fl.createPolicy("vue",{createHTML:t=>t})}catch{}const Zu=ca?t=>ca.createHTML(t):t=>t,Xf="http://www.w3.org/2000/svg",Jf="http://www.w3.org/1998/Math/MathML",Rr=typeof document<"u"?document:null,pl=Rr&&Rr.createElement("template"),Zf={insert:(t,e,r)=>{e.insertBefore(t,r||null)},remove:t=>{const e=t.parentNode;e&&e.removeChild(t)},createElement:(t,e,r,n)=>{const i=e==="svg"?Rr.createElementNS(Xf,t):e==="mathml"?Rr.createElementNS(Jf,t):r?Rr.createElement(t,{is:r}):Rr.createElement(t);return t==="select"&&n&&n.multiple!=null&&i.setAttribute("multiple",n.multiple),i},createText:t=>Rr.createTextNode(t),createComment:t=>Rr.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>Rr.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},insertStaticContent(t,e,r,n,i,s){const a=r?r.previousSibling:e.lastChild;if(i&&(i===s||i.nextSibling))for(;e.insertBefore(i.cloneNode(!0),r),!(i===s||!(i=i.nextSibling)););else{pl.innerHTML=Zu(n==="svg"?`<svg>${t}</svg>`:n==="mathml"?`<math>${t}</math>`:t);const o=pl.content;if(n==="svg"||n==="mathml"){const l=o.firstChild;for(;l.firstChild;)o.appendChild(l.firstChild);o.removeChild(l)}e.insertBefore(o,r)}return[a?a.nextSibling:e.firstChild,r?r.previousSibling:e.lastChild]}},Qf=Symbol("_vtc");function ep(t,e,r){const n=t[Qf];n&&(e=(e?[e,...n]:[...n]).join(" ")),e==null?t.removeAttribute("class"):r?t.setAttribute("class",e):t.className=e}const Mi=Symbol("_vod"),Qu=Symbol("_vsh"),tp={name:"show",beforeMount(t,{value:e},{transition:r}){t[Mi]=t.style.display==="none"?"":t.style.display,r&&e?r.beforeEnter(t):e0(t,e)},mounted(t,{value:e},{transition:r}){r&&e&&r.enter(t)},updated(t,{value:e,oldValue:r},{transition:n}){!e!=!r&&(n?e?(n.beforeEnter(t),e0(t,!0),n.enter(t)):n.leave(t,()=>{e0(t,!1)}):e0(t,e))},beforeUnmount(t,{value:e}){e0(t,e)}};function e0(t,e){t.style.display=e?t[Mi]:"none",t[Qu]=!e}const rp=Symbol(""),np=/(^|;)\s*display\s*:/;function ip(t,e,r){const n=t.style,i=ft(r);let s=!1;if(r&&!i){if(e)if(ft(e))for(const a of e.split(";")){const o=a.slice(0,a.indexOf(":")).trim();r[o]==null&&fi(n,o,"")}else for(const a in e)r[a]==null&&fi(n,a,"");for(const a in r)a==="display"&&(s=!0),fi(n,a,r[a])}else if(i){if(e!==r){const a=n[rp];a&&(r+=";"+a),n.cssText=r,s=np.test(r)}}else e&&t.removeAttribute("style");Mi in t&&(t[Mi]=s?n.display:"",t[Qu]&&(n.display="none"))}const ml=/\s*!important$/;function fi(t,e,r){if(Ce(r))r.forEach(n=>fi(t,e,n));else if(r==null&&(r=""),e.startsWith("--"))t.setProperty(e,r);else{const n=sp(t,e);ml.test(r)?t.setProperty(cn(n),r.replace(ml,""),"important"):t[n]=r}}const gl=["Webkit","Moz","ms"],Ms={};function sp(t,e){const r=Ms[e];if(r)return r;let n=tn(e);if(n!=="filter"&&n in t)return Ms[e]=n;n=Qc(n);for(let i=0;i<gl.length;i++){const s=gl[i]+n;if(s in t)return Ms[e]=s}return e}const vl="http://www.w3.org/1999/xlink";function bl(t,e,r,n,i,s=ch(e)){n&&e.startsWith("xlink:")?r==null?t.removeAttributeNS(vl,e.slice(6,e.length)):t.setAttributeNS(vl,e,r):r==null||s&&!tu(r)?t.removeAttribute(e):t.setAttribute(e,s?"":ln(r)?String(r):r)}function yl(t,e,r,n,i){if(e==="innerHTML"||e==="textContent"){r!=null&&(t[e]=e==="innerHTML"?Zu(r):r);return}const s=t.tagName;if(e==="value"&&s!=="PROGRESS"&&!s.includes("-")){const o=s==="OPTION"?t.getAttribute("value")||"":t.value,l=r==null?t.type==="checkbox"?"on":"":String(r);(o!==l||!("_value"in t))&&(t.value=l),r==null&&t.removeAttribute(e),t._value=r;return}let a=!1;if(r===""||r==null){const o=typeof t[e];o==="boolean"?r=tu(r):r==null&&o==="string"?(r="",a=!0):o==="number"&&(r=0,a=!0)}try{t[e]=r}catch{}a&&t.removeAttribute(i||e)}function _n(t,e,r,n){t.addEventListener(e,r,n)}function ap(t,e,r,n){t.removeEventListener(e,r,n)}const wl=Symbol("_vei");function op(t,e,r,n,i=null){const s=t[wl]||(t[wl]={}),a=s[e];if(n&&a)a.value=n;else{const[o,l]=lp(e);if(n){const c=s[e]=dp(n,i);_n(t,o,c,l)}else a&&(ap(t,o,a,l),s[e]=void 0)}}const xl=/(?:Once|Passive|Capture)$/;function lp(t){let e;if(xl.test(t)){e={};let n;for(;n=t.match(xl);)t=t.slice(0,t.length-n[0].length),e[n[0].toLowerCase()]=!0}return[t[2]===":"?t.slice(3):cn(t.slice(2)),e]}let Ns=0;const cp=Promise.resolve(),up=()=>Ns||(cp.then(()=>Ns=0),Ns=Date.now());function dp(t,e){const r=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=r.attached)return;Tr(hp(n,r.value),e,5,[n])};return r.value=t,r.attached=up(),r}function hp(t,e){if(Ce(e)){const r=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{r.call(t),t._stopped=!0},e.map(n=>i=>!i._stopped&&n&&n(i))}else return e}const kl=t=>t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)>96&&t.charCodeAt(2)<123,fp=(t,e,r,n,i,s)=>{const a=i==="svg";e==="class"?ep(t,n,a):e==="style"?ip(t,r,n):Vi(e)?La(e)||op(t,e,r,n,s):(e[0]==="."?(e=e.slice(1),!0):e[0]==="^"?(e=e.slice(1),!1):pp(t,e,n,a))?(yl(t,e,n),!t.tagName.includes("-")&&(e==="value"||e==="checked"||e==="selected")&&bl(t,e,n,a,s,e!=="value")):t._isVueCE&&(/[A-Z]/.test(e)||!ft(n))?yl(t,tn(e),n,s,e):(e==="true-value"?t._trueValue=n:e==="false-value"&&(t._falseValue=n),bl(t,e,n,a))};function pp(t,e,r,n){if(n)return!!(e==="innerHTML"||e==="textContent"||e in t&&kl(e)&&Ne(r));if(e==="spellcheck"||e==="draggable"||e==="translate"||e==="autocorrect"||e==="form"||e==="list"&&t.tagName==="INPUT"||e==="type"&&t.tagName==="TEXTAREA")return!1;if(e==="width"||e==="height"){const i=t.tagName;if(i==="IMG"||i==="VIDEO"||i==="CANVAS"||i==="SOURCE")return!1}return kl(e)&&ft(r)?!1:e in t}const Sl=t=>{const e=t.props["onUpdate:modelValue"]||!1;return Ce(e)?r=>ci(e,r):e};function mp(t){t.target.composing=!0}function Tl(t){const e=t.target;e.composing&&(e.composing=!1,e.dispatchEvent(new Event("input")))}const Is=Symbol("_assign"),eo={created(t,{modifiers:{lazy:e,trim:r,number:n}},i){t[Is]=Sl(i);const s=n||i.props&&i.props.type==="number";_n(t,e?"change":"input",a=>{if(a.target.composing)return;let o=t.value;r&&(o=o.trim()),s&&(o=Qs(o)),t[Is](o)}),r&&_n(t,"change",()=>{t.value=t.value.trim()}),e||(_n(t,"compositionstart",mp),_n(t,"compositionend",Tl),_n(t,"change",Tl))},mounted(t,{value:e}){t.value=e??""},beforeUpdate(t,{value:e,oldValue:r,modifiers:{lazy:n,trim:i,number:s}},a){if(t[Is]=Sl(a),t.composing)return;const o=(s||t.type==="number")&&!/^0\d/.test(t.value)?Qs(t.value):t.value,l=e??"";o!==l&&(document.activeElement===t&&t.type!=="range"&&(n&&e===r||i&&t.value.trim()===l)||(t.value=l))}},gp=["ctrl","shift","alt","meta"],vp={stop:t=>t.stopPropagation(),prevent:t=>t.preventDefault(),self:t=>t.target!==t.currentTarget,ctrl:t=>!t.ctrlKey,shift:t=>!t.shiftKey,alt:t=>!t.altKey,meta:t=>!t.metaKey,left:t=>"button"in t&&t.button!==0,middle:t=>"button"in t&&t.button!==1,right:t=>"button"in t&&t.button!==2,exact:(t,e)=>gp.some(r=>t[`${r}Key`]&&!e.includes(r))},W0=(t,e)=>{const r=t._withMods||(t._withMods={}),n=e.join(".");return r[n]||(r[n]=(i,...s)=>{for(let a=0;a<e.length;a++){const o=vp[e[a]];if(o&&o(i,e))return}return t(i,...s)})},bp={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Rs=(t,e)=>{const r=t._withKeys||(t._withKeys={}),n=e.join(".");return r[n]||(r[n]=i=>{if(!("key"in i))return;const s=cn(i.key);if(e.some(a=>a===s||bp[a]===s))return t(i)})},yp=Et({patchProp:fp},Zf);let Al;function wp(){return Al||(Al=xf(yp))}const xp=(...t)=>{const e=wp().createApp(...t),{mount:r}=e;return e.mount=n=>{const i=Sp(n);if(!i)return;const s=e._component;!Ne(s)&&!s.render&&!s.template&&(s.template=i.innerHTML),i.nodeType===1&&(i.textContent="");const a=r(i,!1,kp(i));return i instanceof Element&&(i.removeAttribute("v-cloak"),i.setAttribute("data-v-app","")),a},e};function kp(t){if(t instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&t instanceof MathMLElement)return"mathml"}function Sp(t){return ft(t)?document.querySelector(t):t}var Tp=Object.defineProperty,Ap=(t,e,r)=>e in t?Tp(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,G0=(t,e,r)=>(Ap(t,typeof e!="symbol"?e+"":e,r),r);const to={name:"Latte",type:"light",palette:["#dd7878","#ea76cb","#8839ef","#e64553","#fe640b","#df8e1d","#40a02b","#209fb5","#1e66f5","#7287fd"],cssVar:{"--node-gap-x":"30px","--node-gap-y":"10px","--main-gap-x":"65px","--main-gap-y":"45px","--root-radius":"30px","--main-radius":"20px","--root-color":"#ffffff","--root-bgcolor":"#4c4f69","--root-border-color":"rgba(0, 0, 0, 0)","--main-color":"#444446","--main-bgcolor":"#ffffff","--topic-padding":"3px","--color":"#777777","--bgcolor":"#f6f6f6","--selected":"#4dc4ff","--accent-color":"#e64553","--panel-color":"#444446","--panel-bgcolor":"#ffffff","--panel-border-color":"#eaeaea","--map-padding":"50px"}},ro={name:"Dark",type:"dark",palette:["#848FA0","#748BE9","#D2F9FE","#4145A5","#789AFA","#706CF4","#EF987F","#775DD5","#FCEECF","#DA7FBC"],cssVar:{"--node-gap-x":"30px","--node-gap-y":"10px","--main-gap-x":"65px","--main-gap-y":"45px","--root-radius":"30px","--main-radius":"20px","--root-color":"#ffffff","--root-bgcolor":"#2d3748","--root-border-color":"rgba(255, 255, 255, 0.1)","--main-color":"#ffffff","--main-bgcolor":"#4c4f69","--topic-padding":"3px","--color":"#cccccc","--bgcolor":"#252526","--selected":"#4dc4ff","--accent-color":"#789AFA","--panel-color":"#ffffff","--panel-bgcolor":"#2d3748","--panel-border-color":"#696969","--map-padding":"50px 80px"}};function ua(t){return t.replace(/&/g,"&").replace(/</g,"<").replace(/"/g,""")}const Ni=function(t,e){if(e.id===t)return e;if(e.children&&e.children.length){for(let r=0;r<e.children.length;r++){const n=Ni(t,e.children[r]);if(n)return n}return null}else return null},un=(t,e)=>{if(t.parent=e,t.children)for(let r=0;r<t.children.length;r++)un(t.children[r],t)},Hn=(t,e,r)=>{if(t.expanded=e,t.children)if(r===void 0||r>0){const n=r!==void 0?r-1:void 0;t.children.forEach(i=>{Hn(i,e,n)})}else t.children.forEach(n=>{Hn(n,!1)})};function no(t){if(t.id=Tn(),t.children)for(let e=0;e<t.children.length;e++)no(t.children[e])}function Ii(t,e,r,n){const i=n-e,s=t-r;let a=Math.atan(Math.abs(i)/Math.abs(s))/3.14*180;if(isNaN(a))return;s<0&&i>0&&(a=180-a),s<0&&i<0&&(a=180+a),s>0&&i<0&&(a=360-a);const o=12,l=30,c=a+l,u=a-l;return{x1:r+Math.cos(Math.PI*c/180)*o,y1:n-Math.sin(Math.PI*c/180)*o,x2:r+Math.cos(Math.PI*u/180)*o,y2:n-Math.sin(Math.PI*u/180)*o}}function Tn(){return(new Date().getTime().toString(16)+Math.random().toString(16).substr(2)).substr(2,16)}const Ep=function(){const t=Tn();return{topic:this.newTopicName,id:t}};function io(t){return JSON.parse(JSON.stringify(t,(e,r)=>{if(e!=="parent")return r}))}const N0=(t,e)=>{let r=0,n=0;for(;e&&e!==t;)r+=e.offsetLeft,n+=e.offsetTop,e=e.offsetParent;return{offsetLeft:r,offsetTop:n}},rt=(t,e)=>{for(const r in e)t.setAttribute(r,e[r])},da=t=>t?t.tagName==="ME-TPC":!1,ts=t=>t.filter(e=>e.nodeObj.parent).filter((e,r,n)=>{for(let i=0;i<n.length;i++){if(e===n[i])continue;const{parent:s}=e.nodeObj;if(s===n[i].nodeObj)return!1}return!0}),e1=t=>{const e=/translate\(([^,]+),\s*([^)]+)\)/,r=t.match(e);return r?{x:parseFloat(r[1]),y:parseFloat(r[2])}:{x:0,y:0}},so=function(t){for(let e=0;e<t.length;e++){const{dom:r,evt:n,func:i}=t[e];r.addEventListener(n,i)}return function(){for(let e=0;e<t.length;e++){const{dom:r,evt:n,func:i}=t[e];r.removeEventListener(n,i)}}},Cp=t=>{const e=t.getBoundingClientRect();return getComputedStyle(t),{width:e.width,height:e.height,top:e.top,left:e.left,offsetWidth:t.offsetWidth,offsetHeight:t.offsetHeight,offsetTop:t.offsetTop,offsetLeft:t.offsetLeft}},ao=(t,e)=>{try{const r=t.getBoundingClientRect(),n=e.getBoundingClientRect();return{offsetLeft:n.left-r.left,offsetTop:n.top-r.top}}catch{return N0(t,e)}};var ir=(t=>(t.LHS="lhs",t.RHS="rhs",t))(ir||{});const Mp=t=>{const e=t.map.querySelectorAll(".lhs>me-wrapper>me-parent>me-tpc");t.selectNode(e[Math.ceil(e.length/2)-1])},Np=t=>{const e=t.map.querySelectorAll(".rhs>me-wrapper>me-parent>me-tpc");t.selectNode(e[Math.ceil(e.length/2)-1])},Ip=t=>{t.selectNode(t.map.querySelector("me-root>me-tpc"))},Rp=function(t,e){const r=e.parentElement.parentElement.parentElement.previousSibling;if(r){const n=r.firstChild;t.selectNode(n)}},Dp=function(t,e){const r=e.parentElement.nextSibling;if(r&&r.firstChild){const n=r.firstChild.firstChild.firstChild;t.selectNode(n)}},El=function(t,e){var r,n;const i=t.currentNode||((r=t.currentNodes)==null?void 0:r[0]);if(!i)return;const s=i.nodeObj,a=i.offsetParent.offsetParent.parentElement;s.parent?a.className===e?Dp(t,i):(n=s.parent)!=null&&n.parent?Rp(t,i):Ip(t):e===ir.LHS?Mp(t):Np(t)},Cl=function(t,e){const r=t.currentNode;if(!r||!r.nodeObj.parent)return;const n=e+"Sibling",i=r.parentElement.parentElement[n];i?t.selectNode(i.firstChild.firstChild):t.selectNode(r)},Ri=function(t,e,r){const{scaleVal:n,scaleSensitivity:i}=t;switch(e){case"in":t.scale(n+i,r);break;case"out":t.scale(n-i,r)}};function Op(t,e){e=e===!0?{}:e;const r=()=>{t.currentArrow?t.removeArrow():t.currentSummary?t.removeSummary(t.currentSummary.summaryObj.id):t.currentNodes&&t.removeNodes(t.currentNodes)};let n=!1,i=null;const s=o=>{const l=t.nodeData;if(o.key==="0")for(const c of l.children)Hn(c,!1);if(o.key==="=")for(const c of l.children)Hn(c,!0);if(["1","2","3","4","5","6","7","8","9"].includes(o.key))for(const c of l.children)Hn(c,!0,Number(o.key)-1);t.refresh(),t.toCenter(),n=!1,i&&(clearTimeout(i),i=null,t.container.removeEventListener("keydown",s))},a={Enter:o=>{o.shiftKey?t.insertSibling("before"):o.ctrlKey||o.metaKey?t.insertParent():t.insertSibling("after")},Tab:()=>{t.addChild()},F1:()=>{t.toCenter()},F2:()=>{t.beginEdit()},ArrowUp:o=>{if(o.altKey)t.moveUpNode();else{if(o.metaKey||o.ctrlKey)return t.initSide();Cl(t,"previous")}},ArrowDown:o=>{o.altKey?t.moveDownNode():Cl(t,"next")},ArrowLeft:o=>{if(o.metaKey||o.ctrlKey)return t.initLeft();El(t,ir.LHS)},ArrowRight:o=>{if(o.metaKey||o.ctrlKey)return t.initRight();El(t,ir.RHS)},PageUp:()=>t.moveUpNode(),PageDown:()=>{t.moveDownNode()},c:o=>{(o.metaKey||o.ctrlKey)&&(t.waitCopy=t.currentNodes)},x:o=>{(o.metaKey||o.ctrlKey)&&(t.waitCopy=t.currentNodes,r())},v:o=>{!t.waitCopy||!t.currentNode||(o.metaKey||o.ctrlKey)&&(t.waitCopy.length===1?t.copyNode(t.waitCopy[0],t.currentNode):t.copyNodes(t.waitCopy,t.currentNode))},"=":o=>{(o.metaKey||o.ctrlKey)&&Ri(t,"in")},"-":o=>{(o.metaKey||o.ctrlKey)&&Ri(t,"out")},0:o=>{if(o.metaKey||o.ctrlKey){if(n)return;t.scale(1)}},k:o=>{(o.metaKey||o.ctrlKey)&&(n=!0,i&&(clearTimeout(i),t.container.removeEventListener("keydown",s)),i=window.setTimeout(()=>{n=!1,i=null},2e3),t.container.addEventListener("keydown",s))},Delete:r,Backspace:r,...e};t.container.onkeydown=o=>{if(o.preventDefault(),!t.editable)return;const l=a[o.key];l&&l(o)}}function _p(t){const{dragMoveHelper:e}=t,r=p=>{var g,b,x;if(p.button!==0)return;if((g=t.helper1)!=null&&g.moved){t.helper1.clear();return}if((b=t.helper2)!=null&&b.moved){t.helper2.clear();return}if(e.moved){e.clear();return}const w=p.target;if(w.tagName==="ME-EPD")p.ctrlKey||p.metaKey?t.expandNodeAll(w.previousSibling):t.expandNode(w.previousSibling);else if(w.tagName==="ME-TPC"&&t.currentNodes.length>1)t.selectNode(w);else if(!t.editable)return;const N=(x=w.parentElement)==null?void 0:x.parentElement;N.getAttribute("class")==="topiclinks"?t.selectArrow(w.parentElement):N.getAttribute("class")==="summary"&&t.selectSummary(w.parentElement)},n=p=>{var g,b,x;const w=p.target;if(w.tagName==="IMG"){const N=w,y=N.src,k=N.alt||N.title||"";t.bus.fire("showImagePreview",y,k);return}if(da(w)){const N=w;if((g=N.nodeObj)!=null&&g.image){const k=typeof N.nodeObj.image=="string"?N.nodeObj.image:N.nodeObj.image.url;t.bus.fire("showImagePreview",k,N.nodeObj.topic||"");return}const y=N.querySelector("img");if(y){const k=y.src,I=y.alt||y.title||((b=N.nodeObj)==null?void 0:b.topic)||"";t.bus.fire("showImagePreview",k,I);return}t.editable&&t.beginEdit(w)}if(t.editable){const N=(x=w.parentElement)==null?void 0:x.parentElement;N.getAttribute("class")==="topiclinks"?t.editArrowLabel(w.parentElement):N.getAttribute("class")==="summary"&&t.editSummary(w.parentElement)}};let i=0;const s=p=>{if(p.pointerType==="mouse")return;const g=new Date().getTime(),b=g-i;b<300&&b>0&&n(p),i=g},a=p=>{e.moved=!1;const g=t.mouseSelectionButton===0?2:0;if(p.button!==g&&p.pointerType==="mouse")return;e.x=p.clientX,e.y=p.clientY;const b=p.target;b.className!=="circle"&&b.contentEditable!=="plaintext-only"&&(e.mousedown=!0,b.setPointerCapture(p.pointerId))},o=p=>{if(p.target.contentEditable!=="plaintext-only"){const g=p.clientX-e.x,b=p.clientY-e.y;e.onMove(g,b)}e.x=p.clientX,e.y=p.clientY},l=p=>{const g=t.mouseSelectionButton===0?2:0;if(p.button!==g&&p.pointerType==="mouse")return;const b=p.target;b.hasPointerCapture&&b.hasPointerCapture(p.pointerId)&&b.releasePointerCapture(p.pointerId),e.clear()},c=p=>{if(p.preventDefault(),p.button!==2||!t.editable)return;const g=p.target;da(g)&&!g.classList.contains("selected")&&t.selectNode(g),setTimeout(()=>{t.dragMoveHelper.moved||t.bus.fire("showContextMenu",p)},200)},u=p=>{p.stopPropagation(),p.preventDefault(),p.ctrlKey||p.metaKey?p.deltaY<0?Ri(t,"in",t.dragMoveHelper):t.scaleVal-t.scaleSensitivity>0&&Ri(t,"out",t.dragMoveHelper):p.shiftKey?t.move(-p.deltaY,0):t.move(-p.deltaX,-p.deltaY)},{container:f}=t;return so([{dom:f,evt:"pointerdown",func:a},{dom:f,evt:"pointermove",func:o},{dom:f,evt:"pointerup",func:l},{dom:f,evt:"pointerup",func:s},{dom:f,evt:"click",func:r},{dom:f,evt:"dblclick",func:n},{dom:f,evt:"contextmenu",func:c},{dom:f,evt:"wheel",func:typeof t.handleWheel=="function"?t.handleWheel:u}])}function Lp(){return{handlers:{},addListener:function(t,e){this.handlers[t]===void 0&&(this.handlers[t]=[]),this.handlers[t].push(e)},fire:function(t,...e){if(this.handlers[t]instanceof Array){const r=this.handlers[t];for(let n=0;n<r.length;n++)r[n](...e)}},removeListener:function(t,e){if(!this.handlers[t])return;const r=this.handlers[t];if(!e)r.length=0;else if(r.length)for(let n=0;n<r.length;n++)r[n]===e&&this.handlers[t].splice(n,1)}}}const Di=document,zp=function(){this.nodes.innerHTML="";const t=this.createTopic(this.nodeData);rs.call(this,t,this.nodeData),t.draggable=!1;const e=Di.createElement("me-root");e.appendChild(t);const r=this.nodeData.children||[];if(this.direction===2){let n=0,i=0;r.map(s=>{s.direction===0?n+=1:s.direction===1?i+=1:n<=i?(s.direction=0,n+=1):(s.direction=1,i+=1)})}$p(this,r,e)},$p=function(t,e,r){const n=Di.createElement("me-main");n.className=ir.LHS;const i=Di.createElement("me-main");i.className=ir.RHS;for(let s=0;s<e.length;s++){const a=e[s],{grp:o}=t.createWrapper(a);t.direction===2?a.direction===0?n.appendChild(o):i.appendChild(o):t.direction===0?n.appendChild(o):i.appendChild(o)}t.nodes.appendChild(n),t.nodes.appendChild(r),t.nodes.appendChild(i),t.nodes.appendChild(t.lines)},Fp=function(t,e){const r=Di.createElement("me-children");for(let n=0;n<e.length;n++){const i=e[n],{grp:s}=t.createWrapper(i);r.appendChild(s)}return r},Gt=document,t1=function(t,e){const r=(this!=null&&this.el?this.el:e||document).querySelector(`[data-nodeid="me${t}"]`);if(!r)throw new Error(`FindEle: Node ${t} not found, maybe it's collapsed.`);return r},rs=function(t,e){if(t.innerHTML="",e.style){const r=e.style;for(const n in r)t.style[n]=r[n]}if(e.dangerouslySetInnerHTML){let r=e.dangerouslySetInnerHTML;r=r.replace(/•\s*【/g,"【"),r=r.replace(/•\s*\[/g,"["),r=r.replace(/•\s*(/g,"("),r=r.replace(/•\s*\(/g,"("),t.innerHTML=r,r.includes("<img"),e.image,t.classList.add("no-image"),t.classList.remove("has-image");return}if(e.image){const r=e.image;if(r.url&&r.width&&r.height){const n=Gt.createElement("img");n.src=this.imageProxy?this.imageProxy(r.url):r.url,n.style.width=r.width+"px",n.style.height=r.height+"px",r.fit&&(n.style.objectFit=r.fit),t.appendChild(n),t.image=n}}else t.image&&(t.image=void 0);{const r=Gt.createElement("span");r.className="text";let n="";this.markdown?n=this.markdown(e.topic,e):n=e.topic||"",n=n.replace(/•\s*【/g,"【"),n=n.replace(/•\s*\[/g,"["),n=n.replace(/•\s*(/g,"("),n=n.replace(/•\s*\(/g,"("),r.innerHTML=n,t.appendChild(r),t.text=r,e.image,n.includes("<img"),t.classList.add("no-image"),t.classList.remove("has-image")}if(e.hyperLink){const r=Gt.createElement("a");r.className="hyper-link",r.target="_blank",r.innerText="🔗",r.href=e.hyperLink,t.appendChild(r),t.link=r}else t.link&&(t.link=void 0);if(e.icons&&e.icons.length){const r=Gt.createElement("span");r.className="icons",r.innerHTML=e.icons.map(n=>`<span>${ua(n)}</span>`).join(""),t.appendChild(r),t.icons=r}else t.icons&&(t.icons=void 0);if(e.tags&&e.tags.length){const r=Gt.createElement("div");r.className="tags",e.tags.forEach(n=>{const i=Gt.createElement("span");typeof n=="string"?i.textContent=n:(i.textContent=n.text,n.className&&(i.className=n.className),n.style&&Object.assign(i.style,n.style)),r.appendChild(i)}),t.appendChild(r),t.tags=r}else t.tags&&(t.tags=void 0)},Bp=function(t,e){const r=Gt.createElement("me-wrapper"),{p:n,tpc:i}=this.createParent(t);if(r.appendChild(n),!e&&t.children&&t.children.length>0){const s=oo(t.expanded);if(n.appendChild(s),t.expanded!==!1){const a=Fp(this,t.children);r.appendChild(a)}}return{grp:r,top:n,tpc:i}},Pp=function(t){const e=Gt.createElement("me-parent"),r=this.createTopic(t);return rs.call(this,r,t),e.appendChild(r),{p:e,tpc:r}},Hp=function(t){const e=Gt.createElement("me-children");return e.append(...t),e},qp=function(t){const e=Gt.createElement("me-tpc");return e.nodeObj=t,e.dataset.nodeid="me"+t.id,e.draggable=this.draggable,e};function r1(t){const e=Gt.createRange();e.selectNodeContents(t);const r=window.getSelection();r&&(r.removeAllRanges(),r.addRange(e))}const jp=function(t){if(!t)return;const e=Gt.createElement("div"),r=t.nodeObj,n=r.topic;t.appendChild(e),e.id="input-box",e.textContent=n,e.contentEditable="plaintext-only",e.spellcheck=!1;const i=getComputedStyle(t);e.style.cssText=`min-width:${t.offsetWidth-8}px;
|
||
color:${i.color};
|
||
padding:${i.padding};
|
||
margin:${i.margin};
|
||
font:${i.font};
|
||
background-color:${i.backgroundColor!=="rgba(0, 0, 0, 0)"&&i.backgroundColor};
|
||
border-radius:${i.borderRadius};`,this.direction===0&&(e.style.right="0"),r1(e),this.bus.fire("operation",{name:"beginEdit",obj:t.nodeObj}),e.addEventListener("keydown",s=>{s.stopPropagation();const a=s.key;if(a==="Enter"||a==="Tab"){if(s.shiftKey)return;s.preventDefault(),e.blur(),this.container.focus()}}),e.addEventListener("blur",()=>{var s;if(!e)return;const a=((s=e.textContent)==null?void 0:s.trim())||"";a===""?r.topic=n:(r.topic=a,this.markdown?t.text.innerHTML=this.markdown(r.topic,r):t.text.textContent=a),e.remove(),rs.call(this,t,r),a!==n&&(this.linkDiv(),this.bus.fire("operation",{name:"finishEdit",obj:r,origin:n}))})},oo=function(t){const e=Gt.createElement("me-epd");return e.expanded=t!==!1,e.className=t!==!1?"minus":"",e},xn=document,rr="http://www.w3.org/2000/svg",ha=function(t,e,r,n={}){const{anchor:i="middle",color:s,dataType:a}=n,o=document.createElementNS(rr,"text");return rt(o,{"text-anchor":i,x:e+"",y:r+"",fill:s||(i==="middle"?"rgb(235, 95, 82)":"#666")}),a&&(o.dataset.type=a),o.innerHTML=t,o},n1=function(t,e,r){const n=xn.createElementNS(rr,"path");return rt(n,{d:t,stroke:e||"#666",fill:"none","stroke-width":r}),n},a0=function(t){const e=xn.createElementNS(rr,"svg");return e.setAttribute("class",t),e.setAttribute("overflow","visible"),e},Ml=function(){const t=xn.createElementNS(rr,"line");return t.setAttribute("stroke","#4dc4ff"),t.setAttribute("fill","none"),t.setAttribute("stroke-width","2"),t.setAttribute("opacity","0.45"),t},Up=function(t,e,r,n){const i=xn.createElementNS(rr,"g");return[{name:"line",d:t},{name:"arrow1",d:e},{name:"arrow2",d:r}].forEach((s,a)=>{const o=s.d,l=xn.createElementNS(rr,"path"),c={d:o,stroke:(n==null?void 0:n.stroke)||"rgb(235, 95, 82)",fill:"none","stroke-linecap":(n==null?void 0:n.strokeLinecap)||"cap","stroke-width":String((n==null?void 0:n.strokeWidth)||"2")};(n==null?void 0:n.opacity)!==void 0&&(c.opacity=String(n.opacity)),rt(l,c),a===0&&l.setAttribute("stroke-dasharray",(n==null?void 0:n.strokeDasharray)||"8,2");const u=xn.createElementNS(rr,"path");rt(u,{d:o,stroke:"transparent",fill:"none","stroke-width":"15"}),i.appendChild(u),i.appendChild(l),i[s.name]=l}),i},i1=function(t,e,r){if(!e)return;const n=xn.createElement("div");t.nodes.appendChild(n);const i=e.innerHTML;n.id="input-box",n.textContent=i,n.contentEditable="plaintext-only",n.spellcheck=!1;const s=e.getBBox();n.style.cssText=`
|
||
min-width:${Math.max(88,s.width)}px;
|
||
position:absolute;
|
||
left:${s.x}px;
|
||
top:${s.y}px;
|
||
padding: 2px 4px;
|
||
margin: -2px -4px;
|
||
`,r1(n),t.scrollIntoView(n),n.addEventListener("keydown",a=>{a.stopPropagation();const o=a.key;if(o==="Enter"||o==="Tab"){if(a.shiftKey)return;a.preventDefault(),n.blur(),t.container.focus()}}),n.addEventListener("blur",()=>{var a;if(!n)return;const o=((a=n.textContent)==null?void 0:a.trim())||"";o===""?r.label=i:r.label=o,n.remove(),o!==i&&(e.innerHTML=r.label,"parent"in r?t.bus.fire("operation",{name:"finishEditSummary",obj:r}):t.bus.fire("operation",{name:"finishEditArrowLabel",obj:r}))})},Vp=function(t){const e=this.map.querySelector("me-root"),r=e.offsetTop,n=e.offsetLeft,i=e.offsetWidth,s=e.offsetHeight,a=this.map.querySelectorAll("me-main > me-wrapper");this.lines.innerHTML="";for(let o=0;o<a.length;o++){const l=a[o],c=l.querySelector("me-tpc"),{offsetLeft:u,offsetTop:f}=N0(this.nodes,c),p=c.offsetWidth,g=c.offsetHeight,b=l.parentNode.className,x=this.generateMainBranch({pT:r,pL:n,pW:i,pH:s,cT:f,cL:u,cW:p,cH:g,direction:b,containerHeight:this.nodes.offsetHeight}),w=this.theme.palette,N=c.nodeObj.branchColor||w[o%w.length];if(c.style.borderColor=N,this.lines.appendChild(n1(x,N,"3")),t&&t!==l)continue;const y=a0("subLines"),k=l.lastChild;k.tagName==="svg"&&k.remove(),l.appendChild(y),s1(this,y,N,l,b,!0)}this.renderArrow(),this.renderSummary(),this.bus.fire("linkDiv")},s1=function(t,e,r,n,i,s){const a=n.firstChild,o=n.children[1].children;if(o.length===0)return;const l=a.offsetTop,c=a.offsetLeft,u=a.offsetWidth,f=a.offsetHeight;for(let p=0;p<o.length;p++){const g=o[p],b=g.firstChild,x=b.offsetTop,w=b.offsetLeft,N=b.offsetWidth,y=b.offsetHeight,k=b.firstChild.nodeObj.branchColor||r,I=t.generateSubBranch({pT:l,pL:c,pW:u,pH:f,cT:x,cL:w,cW:N,cH:y,direction:i,isFirst:s});e.appendChild(n1(I,k,"2"));const D=b.children[1];if(D){if(!D.expanded)continue}else continue;s1(t,e,k,g,i)}},Nl={addChild:"插入子节点",addParent:"插入父节点",addSibling:"插入同级节点",removeNode:"删除节点",focus:"专注",cancelFocus:"取消专注",moveUp:"上移",moveDown:"下移",link:"连接",linkBidirectional:"双向连接",clickTips:"请点击目标节点",summary:"摘要"},Il={cn:Nl,zh_CN:Nl,zh_TW:{addChild:"插入子節點",addParent:"插入父節點",addSibling:"插入同級節點",removeNode:"刪除節點",focus:"專注",cancelFocus:"取消專注",moveUp:"上移",moveDown:"下移",link:"連接",linkBidirectional:"雙向連接",clickTips:"請點擊目標節點",summary:"摘要"},en:{addChild:"Add child",addParent:"Add parent",addSibling:"Add sibling",removeNode:"Remove node",focus:"Focus Mode",cancelFocus:"Cancel Focus Mode",moveUp:"Move up",moveDown:"Move down",link:"Link",linkBidirectional:"Bidirectional Link",clickTips:"Please click the target node",summary:"Summary"},ru:{addChild:"Добавить дочерний элемент",addParent:"Добавить родительский элемент",addSibling:"Добавить на этом уровне",removeNode:"Удалить узел",focus:"Режим фокусировки",cancelFocus:"Отменить режим фокусировки",moveUp:"Поднять выше",moveDown:"Опустить ниже",link:"Ссылка",linkBidirectional:"Двунаправленная ссылка",clickTips:"Пожалуйста, нажмите на целевой узел",summary:"Описание"},ja:{addChild:"子ノードを追加する",addParent:"親ノードを追加します",addSibling:"兄弟ノードを追加する",removeNode:"ノードを削除",focus:"集中",cancelFocus:"集中解除",moveUp:"上へ移動",moveDown:"下へ移動",link:"コネクト",linkBidirectional:"双方向リンク",clickTips:"ターゲットノードをクリックしてください",summary:"概要"},pt:{addChild:"Adicionar item filho",addParent:"Adicionar item pai",addSibling:"Adicionar item irmao",removeNode:"Remover item",focus:"Modo Foco",cancelFocus:"Cancelar Modo Foco",moveUp:"Mover para cima",moveDown:"Mover para baixo",link:"Link",linkBidirectional:"Link bidirecional",clickTips:"Favor clicar no item alvo",summary:"Resumo"},it:{addChild:"Aggiungi figlio",addParent:"Aggiungi genitore",addSibling:"Aggiungi fratello",removeNode:"Rimuovi nodo",focus:"Modalità Focus",cancelFocus:"Annulla Modalità Focus",moveUp:"Sposta su",moveDown:"Sposta giù",link:"Collega",linkBidirectional:"Collegamento bidirezionale",clickTips:"Si prega di fare clic sul nodo di destinazione",summary:"Unisci nodi"},es:{addChild:"Agregar hijo",addParent:"Agregar padre",addSibling:"Agregar hermano",removeNode:"Eliminar nodo",focus:"Modo Enfoque",cancelFocus:"Cancelar Modo Enfoque",moveUp:"Mover hacia arriba",moveDown:"Mover hacia abajo",link:"Enlace",linkBidirectional:"Enlace bidireccional",clickTips:"Por favor haga clic en el nodo de destino",summary:"Resumen"},fr:{addChild:"Ajout enfant",addParent:"Ajout parent",addSibling:"Ajout voisin",removeNode:"Supprimer",focus:"Cibler",cancelFocus:"Retour",moveUp:"Monter",moveDown:"Descendre",link:"Lier",linkBidirectional:"Lien bidirectionnel",clickTips:"Cliquer sur le noeud cible",summary:"Annoter"},ko:{addChild:"자식 추가",addParent:"부모 추가",addSibling:"형제 추가",removeNode:"노드 삭제",focus:"포커스 모드",cancelFocus:"포커스 모드 취소",moveUp:"위로 이동",moveDown:"아래로 이동",link:"연결",linkBidirectional:"양방향 연결",clickTips:"대상 노드를 클릭하십시오",summary:"요약"}};function Wp(t,e){e=e===!0?{focus:!0,link:!0}:e;const r=z=>{const W=document.createElement("div");return W.innerText=z,W.className="tips",W},n=(z,W,H)=>{const oe=document.createElement("li");return oe.id=z,oe.innerHTML=`<span>${ua(W)}</span><span ${H?'class="key"':""}>${ua(H)}</span>`,oe},i=Il[t.locale]?t.locale:"en",s=Il[i],a=n("cm-add_child",s.addChild,"Tab"),o=n("cm-add_parent",s.addParent,"Ctrl + Enter"),l=n("cm-add_sibling",s.addSibling,"Enter"),c=n("cm-remove_child",s.removeNode,"Delete"),u=n("cm-fucus",s.focus,""),f=n("cm-unfucus",s.cancelFocus,""),p=n("cm-up",s.moveUp,"PgUp"),g=n("cm-down",s.moveDown,"Pgdn"),b=n("cm-link",s.link,""),x=n("cm-link-bidirectional",s.linkBidirectional,""),w=n("cm-summary",s.summary,""),N=n("cm-image-preview","预览图片",""),y=document.createElement("ul");if(y.className="menu-list",y.appendChild(a),y.appendChild(o),y.appendChild(l),y.appendChild(c),e.focus&&(y.appendChild(u),y.appendChild(f)),y.appendChild(p),y.appendChild(g),y.appendChild(w),e.link&&(y.appendChild(b),y.appendChild(x)),e&&e.extend)for(let z=0;z<e.extend.length;z++){const W=e.extend[z],H=n(W.name,W.name,W.key||"");y.appendChild(H),H.onclick=oe=>{W.onclick(oe)}}const k=document.createElement("div");k.className="context-menu",k.appendChild(y),k.hidden=!0,t.container.append(k);let I=!0;const D=z=>{var W;const H=z.target;if(da(H)){H.parentElement.tagName==="ME-ROOT"?I=!0:I=!1;const oe=H;(W=oe.nodeObj)!=null&&W.image||oe.querySelector("img")?(N.style.display="block",N.className=""):N.style.display="none",I?(u.className="disabled",p.className="disabled",g.className="disabled",o.className="disabled",l.className="disabled",c.className="disabled"):(u.className="",p.className="",g.className="",o.className="",l.className="",c.className=""),k.hidden=!1,y.style.top="",y.style.bottom="",y.style.left="",y.style.right="";const me=y.getBoundingClientRect(),ye=y.offsetHeight,Le=y.offsetWidth,ze=z.clientY-me.top,Ge=z.clientX-me.left;ye+ze>window.innerHeight?(y.style.top="",y.style.bottom="0px"):(y.style.bottom="",y.style.top=ze+15+"px"),Le+Ge>window.innerWidth?(y.style.left="",y.style.right="0px"):(y.style.right="",y.style.left=Ge+10+"px")}};t.bus.addListener("showContextMenu",D),k.onclick=z=>{z.target===k&&(k.hidden=!0)},a.onclick=()=>{t.addChild(),k.hidden=!0},o.onclick=()=>{t.insertParent(),k.hidden=!0},l.onclick=()=>{I||(t.insertSibling("after"),k.hidden=!0)},c.onclick=()=>{I||(t.removeNodes(t.currentNodes||[]),k.hidden=!0)},u.onclick=()=>{I||(t.focusNode(t.currentNode),k.hidden=!0)},f.onclick=()=>{t.cancelFocus(),k.hidden=!0},p.onclick=()=>{I||(t.moveUpNode(),k.hidden=!0)},g.onclick=()=>{I||(t.moveDownNode(),k.hidden=!0)};const O=z=>{k.hidden=!0;const W=t.currentNode,H=r(s.clickTips);t.container.appendChild(H),t.map.addEventListener("click",oe=>{oe.preventDefault(),H.remove();const me=oe.target;(me.parentElement.tagName==="ME-PARENT"||me.parentElement.tagName==="ME-ROOT")&&t.createArrow(W,me,z)},{once:!0})};return b.onclick=()=>O(),x.onclick=()=>O({bidirectional:!0}),w.onclick=()=>{k.hidden=!0,t.createSummary(),t.unselectNodes(t.currentNodes)},N.onclick=()=>{var z,W;k.hidden=!0;const H=t.currentNode;if(H)if((z=H.nodeObj)!=null&&z.image){const oe=typeof H.nodeObj.image=="string"?H.nodeObj.image:H.nodeObj.image.url;t.bus.fire("showImagePreview",oe,H.nodeObj.topic||"")}else{const oe=H.querySelector("img");if(oe){const me=oe.src,ye=oe.alt||oe.title||((W=H.nodeObj)==null?void 0:W.topic)||"";t.bus.fire("showImagePreview",me,ye)}}},()=>{a.onclick=null,o.onclick=null,l.onclick=null,c.onclick=null,u.onclick=null,f.onclick=null,p.onclick=null,g.onclick=null,b.onclick=null,w.onclick=null,k.onclick=null,t.container.oncontextmenu=null}}const fa=document,Gp=function(t,e){if(!e)return pa(t),t;let r=t.querySelector(".insert-preview");const n=`insert-preview ${e} show`;return r||(r=fa.createElement("div"),t.appendChild(r)),r.className=n,t},pa=function(t){if(!t)return;const e=t.querySelectorAll(".insert-preview");for(const r of e||[])r.remove()},Rl=function(t,e){for(const r of e){const n=r.parentElement.parentElement.contains(t);if(!(t&&t.tagName==="ME-TPC"&&t!==r&&!n&&t.nodeObj.parent))return!1}return!0},Kp=function(t){const e=document.createElement("div");return e.className="mind-elixir-ghost",t.container.appendChild(e),e};class Yp{constructor(e){G0(this,"mind"),G0(this,"isMoving",!1),G0(this,"interval",null),G0(this,"speed",20),this.mind=e}move(e,r){this.isMoving||(this.isMoving=!0,this.interval=setInterval(()=>{this.mind.move(e*this.speed*this.mind.scaleVal,r*this.speed*this.mind.scaleVal)},100))}stop(){this.isMoving=!1,clearInterval(this.interval)}}function Xp(t){let e=null,r=null;const n=Kp(t),i=new Yp(t),s=l=>{t.selection.cancel();const c=l.target;if((c==null?void 0:c.tagName)!=="ME-TPC"){l.preventDefault();return}let u=t.currentNodes;u!=null&&u.includes(c)||(t.selectNode(c),u=t.currentNodes),t.dragged=u,u.length>1?n.innerHTML=u.length+"":n.innerHTML=c.innerHTML;for(const f of u)f.parentElement.parentElement.style.opacity="0.5";l.dataTransfer.setDragImage(n,0,0),l.dataTransfer.dropEffect="move",t.dragMoveHelper.clear()},a=l=>{const{dragged:c}=t;if(!c)return;i.stop();for(const f of c)f.parentElement.parentElement.style.opacity="1";const u=l.target;u.style.opacity="",r&&(pa(r),e==="before"?t.moveNodeBefore(c,r):e==="after"?t.moveNodeAfter(c,r):e==="in"&&t.moveNodeIn(c,r),t.dragged=null,n.innerHTML="")},o=l=>{l.preventDefault();const c=12*t.scaleVal,{dragged:u}=t;if(!u)return;const f=t.container.getBoundingClientRect();l.clientX<f.x+50?i.move(1,0):l.clientX>f.x+f.width-50?i.move(-1,0):l.clientY<f.y+50?i.move(0,1):l.clientY>f.y+f.height-50?i.move(0,-1):i.stop(),pa(r);const p=fa.elementFromPoint(l.clientX,l.clientY-c);if(Rl(p,u)){r=p;const g=p.getBoundingClientRect(),b=g.y;l.clientY>b+g.height?e="after":e="in"}else{const g=fa.elementFromPoint(l.clientX,l.clientY+c),b=g.getBoundingClientRect();if(Rl(g,u)){r=g;const x=b.y;l.clientY<x?e="before":e="in"}else e=r=null}r&&Gp(r,e)};return so([{dom:t.map,evt:"dragstart",func:s},{dom:t.map,evt:"dragend",func:a},{dom:t.map,evt:"dragover",func:o}])}const Jp=function(t){return["createSummary","removeSummary","finishEditSummary"].includes(t.name)?{type:"summary",value:t.obj.id}:["createArrow","removeArrow","finishEditArrowLabel"].includes(t.name)?{type:"arrow",value:t.obj.id}:["removeNodes","copyNodes","moveNodeBefore","moveNodeAfter","moveNodeIn"].includes(t.name)?{type:"nodes",value:t.objs.map(e=>e.id)}:{type:"nodes",value:[t.obj.id]}};function Zp(t){let e=[],r=-1,n=t.getData(),i=[];t.undo=function(){if(r>-1){const l=e[r];n=l.prev,t.refresh(l.prev);try{l.currentTarget.type==="nodes"&&(l.operation==="removeNodes"?t.selectNodes(l.currentTarget.value.map(c=>this.findEle(c))):t.selectNodes(l.currentSelected.map(c=>this.findEle(c))))}catch{}finally{r--}}},t.redo=function(){if(r<e.length-1){r++;const l=e[r];n=l.next,t.refresh(l.next);try{l.currentTarget.type==="nodes"&&(l.operation==="removeNodes"?t.selectNodes(l.currentSelected.map(c=>this.findEle(c))):t.selectNodes(l.currentTarget.value.map(c=>this.findEle(c))))}catch{}}};const s=function(l){if(l.name==="beginEdit")return;e=e.slice(0,r+1);const c=t.getData(),u={prev:n,operation:l.name,currentSelected:i.map(f=>f.id),currentTarget:Jp(l),next:c};e.push(u),n=c,r=e.length-1},a=function(l){(l.metaKey||l.ctrlKey)&&(l.shiftKey&&l.key==="Z"||l.key==="y")?t.redo():(l.metaKey||l.ctrlKey)&&l.key==="z"&&t.undo()},o=function(l){i=t.currentNodes.map(c=>c.nodeObj)};return t.bus.addListener("operation",s),t.bus.addListener("selectNodes",o),t.container.addEventListener("keydown",a),()=>{t.bus.removeListener("operation",s),t.bus.removeListener("selectNodes",o),t.container.removeEventListener("keydown",a)}}const Qp='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169394918" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2021" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M851.91168 328.45312c-59.97056 0-108.6208 48.47104-108.91264 108.36992l-137.92768 38.4a109.14304 109.14304 0 0 0-63.46752-46.58688l1.39264-137.11872c47.29344-11.86816 82.31936-54.66624 82.31936-105.64096 0-60.15488-48.76288-108.91776-108.91776-108.91776s-108.91776 48.76288-108.91776 108.91776c0 49.18784 32.60928 90.75712 77.38368 104.27392l-1.41312 138.87488a109.19936 109.19936 0 0 0-63.50336 48.55808l-138.93632-39.48544 0.01024-0.72704c0-60.15488-48.76288-108.91776-108.91776-108.91776s-108.91776 48.75776-108.91776 108.91776c0 60.15488 48.76288 108.91264 108.91776 108.91264 39.3984 0 73.91232-20.92032 93.03552-52.2496l139.19232 39.552-0.00512 0.2304c0 25.8304 9.00096 49.5616 24.02816 68.23424l-90.14272 132.63872a108.7488 108.7488 0 0 0-34.2528-5.504c-60.15488 0-108.91776 48.768-108.91776 108.91776 0 60.16 48.76288 108.91776 108.91776 108.91776 60.16 0 108.92288-48.75776 108.92288-108.91776 0-27.14624-9.9328-51.968-26.36288-71.04l89.04704-131.03104a108.544 108.544 0 0 0 37.6832 6.70208 108.672 108.672 0 0 0 36.48512-6.272l93.13792 132.57216a108.48256 108.48256 0 0 0-24.69888 69.0688c0 60.16 48.768 108.92288 108.91776 108.92288 60.16 0 108.91776-48.76288 108.91776-108.92288 0-60.14976-48.75776-108.91776-108.91776-108.91776a108.80512 108.80512 0 0 0-36.69504 6.3488l-93.07136-132.48a108.48768 108.48768 0 0 0 24.79616-72.22784l136.09984-37.888c18.99008 31.93856 53.84192 53.3504 93.69088 53.3504 60.16 0 108.92288-48.75776 108.92288-108.91264-0.00512-60.15488-48.77312-108.92288-108.92288-108.92288z" p-id="2022"></path></svg>',em='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169375313" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1775" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M639 463.30000001L639 285.1c0-36.90000001-26.4-68.5-61.3-68.5l-150.2 0c-1.5 0-3 0.1-4.5 0.3-10.2-38.7-45.5-67.3-87.5-67.3-50 0-90.5 40.5-90.5 90.5s40.5 90.5 90.5 90.5c42 0 77.3-28.6 87.5-67.39999999 1.4 0.3 2.9 0.4 4.5 0.39999999L577.7 263.6c6.8 0 14.3 8.9 14.3 21.49999999l0 427.00000001c0 12.7-7.40000001 21.5-14.30000001 21.5l-150.19999999 0c-1.5 0-3 0.2-4.5 0.4-10.2-38.8-45.5-67.3-87.5-67.3-50 0-90.5 40.5-90.5 90.4 0 49.9 40.5 90.6 90.5 90.59999999 42 0 77.3-28.6 87.5-67.39999999 1.4 0.2 2.9 0.4 4.49999999 0.4L577.7 780.7c34.80000001 0 61.3-31.6 61.3-68.50000001L639 510.3l79.1 0c10.4 38.5 45.49999999 67 87.4 67 50 0 90.5-40.5 90.5-90.5s-40.5-90.5-90.5-90.5c-41.79999999 0-77.00000001 28.4-87.4 67L639 463.30000001z" fill="currentColor" p-id="1776"></path></svg>',tm='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169667709" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3037" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M385 560.69999999L385 738.9c0 36.90000001 26.4 68.5 61.3 68.5l150.2 0c1.5 0 3-0.1 4.5-0.3 10.2 38.7 45.5 67.3 87.5 67.3 50 0 90.5-40.5 90.5-90.5s-40.5-90.5-90.5-90.5c-42 0-77.3 28.6-87.5 67.39999999-1.4-0.3-2.9-0.4-4.5-0.39999999L446.3 760.4c-6.8 0-14.3-8.9-14.3-21.49999999l0-427.00000001c0-12.7 7.40000001-21.5 14.30000001-21.5l150.19999999 0c1.5 0 3-0.2 4.5-0.4 10.2 38.8 45.5 67.3 87.5 67.3 50 0 90.5-40.5 90.5-90.4 0-49.9-40.5-90.6-90.5-90.59999999-42 0-77.3 28.6-87.5 67.39999999-1.4-0.2-2.9-0.4-4.49999999-0.4L446.3 243.3c-34.80000001 0-61.3 31.6-61.3 68.50000001L385 513.7l-79.1 0c-10.4-38.5-45.49999999-67-87.4-67-50 0-90.5 40.5-90.5 90.5s40.5 90.5 90.5 90.5c41.79999999 0 77.00000001-28.4 87.4-67L385 560.69999999z" fill="currentColor" p-id="3038"></path></svg>',rm='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169402629" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2170" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M639.328 416c8.032 0 16.096-3.008 22.304-9.056l202.624-197.184-0.8 143.808c-0.096 17.696 14.144 32.096 31.808 32.192 0.064 0 0.128 0 0.192 0 17.6 0 31.904-14.208 32-31.808l1.248-222.208c0-0.672-0.352-1.248-0.384-1.92 0.032-0.512 0.288-0.896 0.288-1.408 0.032-17.664-14.272-32-31.968-32.032L671.552 96l-0.032 0c-17.664 0-31.968 14.304-32 31.968C639.488 145.632 653.824 160 671.488 160l151.872 0.224-206.368 200.8c-12.672 12.32-12.928 32.608-0.64 45.248C622.656 412.736 630.976 416 639.328 416z" p-id="2171"></path><path d="M896.032 639.552 896.032 639.552c-17.696 0-32 14.304-32.032 31.968l-0.224 151.872-200.832-206.4c-12.32-12.64-32.576-12.96-45.248-0.64-12.672 12.352-12.928 32.608-0.64 45.248l197.184 202.624-143.808-0.8c-0.064 0-0.128 0-0.192 0-17.6 0-31.904 14.208-32 31.808-0.096 17.696 14.144 32.096 31.808 32.192l222.24 1.248c0.064 0 0.128 0 0.192 0 0.64 0 1.12-0.32 1.76-0.352 0.512 0.032 0.896 0.288 1.408 0.288l0.032 0c17.664 0 31.968-14.304 32-31.968L928 671.584C928.032 653.952 913.728 639.584 896.032 639.552z" p-id="2172"></path><path d="M209.76 159.744l143.808 0.8c0.064 0 0.128 0 0.192 0 17.6 0 31.904-14.208 32-31.808 0.096-17.696-14.144-32.096-31.808-32.192L131.68 95.328c-0.064 0-0.128 0-0.192 0-0.672 0-1.248 0.352-1.888 0.384-0.448 0-0.8-0.256-1.248-0.256 0 0-0.032 0-0.032 0-17.664 0-31.968 14.304-32 31.968L96 352.448c-0.032 17.664 14.272 32 31.968 32.032 0 0 0.032 0 0.032 0 17.664 0 31.968-14.304 32-31.968l0.224-151.936 200.832 206.4c6.272 6.464 14.624 9.696 22.944 9.696 8.032 0 16.096-3.008 22.304-9.056 12.672-12.32 12.96-32.608 0.64-45.248L209.76 159.744z" p-id="2173"></path><path d="M362.368 617.056l-202.624 197.184 0.8-143.808c0.096-17.696-14.144-32.096-31.808-32.192-0.064 0-0.128 0-0.192 0-17.6 0-31.904 14.208-32 31.808l-1.248 222.24c0 0.704 0.352 1.312 0.384 2.016 0 0.448-0.256 0.832-0.256 1.312-0.032 17.664 14.272 32 31.968 32.032L352.448 928c0 0 0.032 0 0.032 0 17.664 0 31.968-14.304 32-31.968s-14.272-32-31.968-32.032l-151.936-0.224 206.4-200.832c12.672-12.352 12.96-32.608 0.64-45.248S375.008 604.704 362.368 617.056z" p-id="2174"></path></svg>',nm='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169573443" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2883" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M514.133333 488.533333m-106.666666 0a106.666667 106.666667 0 1 0 213.333333 0 106.666667 106.666667 0 1 0-213.333333 0Z" fill="currentColor" p-id="2884"></path><path d="M512 64C264.533333 64 64 264.533333 64 512c0 236.8 183.466667 428.8 416 445.866667v-134.4c-53.333333-59.733333-200.533333-230.4-200.533333-334.933334 0-130.133333 104.533333-234.666667 234.666666-234.666666s234.666667 104.533333 234.666667 234.666666c0 61.866667-49.066667 153.6-145.066667 270.933334l-59.733333 68.266666V960C776.533333 942.933333 960 748.8 960 512c0-247.466667-200.533333-448-448-448z" fill="currentColor" p-id="2885"></path></svg>',im='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169419447" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2480" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M863.328 482.56l-317.344-1.12L545.984 162.816c0-17.664-14.336-32-32-32s-32 14.336-32 32l0 318.4L159.616 480.064c-0.032 0-0.064 0-0.096 0-17.632 0-31.936 14.24-32 31.904C127.424 529.632 141.728 544 159.392 544.064l322.592 1.152 0 319.168c0 17.696 14.336 32 32 32s32-14.304 32-32l0-318.944 317.088 1.12c0.064 0 0.096 0 0.128 0 17.632 0 31.936-14.24 32-31.904C895.264 496.992 880.96 482.624 863.328 482.56z" p-id="2481"></path></svg>',sm='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169426515" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2730" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M863.744 544 163.424 544c-17.664 0-32-14.336-32-32s14.336-32 32-32l700.32 0c17.696 0 32 14.336 32 32S881.44 544 863.744 544z" p-id="2731"></path></svg>',am='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169419447" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2480" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M896 128H128c-35.3 0-64 28.7-64 64v640c0 35.3 28.7 64 64 64h768c35.3 0 64-28.7 64-64V192c0-35.3-28.7-64-64-64zM832 832H192V192h640v640z" p-id="2481"></path><path d="M192 256h640v64H192v-64zM192 384h640v64H192v-64zM192 512h640v64H192v-64zM192 640h448v64H192v-64zM192 768h320v64H192v-64z" p-id="2482"></path></svg>',om=t=>async e=>{var r;try{const n=`${((r=e.nodeData)==null?void 0:r.topic)||"思维导图"}_${new Date().toISOString().slice(0,10)}`,i=`
|
||
.topic { font-family: Arial, sans-serif; font-size: 14px; color: #333; }
|
||
.markdown-content { font-size: 12px; line-height: 1.3; }
|
||
|
||
/* 表格样式 */
|
||
.markdown-table {
|
||
border-collapse: collapse;
|
||
width: 100%;
|
||
margin: 4px 0;
|
||
font-size: 11px;
|
||
border: 1px solid #e0e0e0;
|
||
border-radius: 6px;
|
||
box-shadow: 0 2px 8px rgba(0,0,0,0.08);
|
||
background-color: #fafafa;
|
||
overflow: hidden;
|
||
white-space: normal;
|
||
}
|
||
|
||
.markdown-table th,
|
||
.markdown-table td {
|
||
border: 1px solid #e0e0e0;
|
||
padding: 8px 12px;
|
||
text-align: left;
|
||
vertical-align: top;
|
||
position: relative;
|
||
white-space: normal;
|
||
}
|
||
|
||
.markdown-table th {
|
||
background-color: #f5f5f5;
|
||
font-weight: 600;
|
||
color: #333;
|
||
text-align: center;
|
||
border-bottom: 1px solid #d0d0d0;
|
||
}
|
||
|
||
.markdown-table td {
|
||
background-color: #fff;
|
||
}
|
||
|
||
.markdown-table tr:nth-child(even) td {
|
||
background-color: #f8f8f8;
|
||
}
|
||
|
||
.markdown-table tr:hover td {
|
||
background-color: #f0f8ff;
|
||
}
|
||
|
||
/* 移除多余的边框,保持简洁 */
|
||
.markdown-table th:not(:last-child),
|
||
.markdown-table td:not(:last-child) {
|
||
border-right: 1px solid #e0e0e0;
|
||
}
|
||
|
||
.markdown-table tr:not(:last-child) td {
|
||
border-bottom: 1px solid #e0e0e0;
|
||
}
|
||
`,s=await e.exportSvg(!0,i);if(!s)return;const a=URL.createObjectURL(s),o=document.createElement("a");o.href=a,o.download=`${n}.${t}`,o.click(),URL.revokeObjectURL(a)}catch{alert(`导出${t.toUpperCase()}失败,请重试`)}},lm={side:Qp,left:em,right:tm,full:rm,living:nm,zoomin:im,zoomout:sm,exportSvg:am},Zr=(t,e)=>{const r=document.createElement("span");return r.id=t,r.innerHTML=lm[e],r};function cm(t){try{const e=document.createElement("div"),r=Zr("fullscreen","full"),n=Zr("toCenter","living"),i=Zr("zoomout","zoomout"),s=Zr("zoomin","zoomin"),a=Zr("exportSvg","exportSvg");a.title="导出SVG矢量图";const o=document.createElement("span");return o.innerText="100%",e.appendChild(r),e.appendChild(n),e.appendChild(i),e.appendChild(s),e.appendChild(a),e.className="mind-elixir-toolbar rb",r.onclick=()=>{document.fullscreenElement===t.el?(document.exitFullscreen(),setTimeout(()=>{t.el.focus()},100)):(t.el.requestFullscreen(),setTimeout(()=>{},100))},n.onclick=()=>{t.toCenter()},i.onclick=()=>{t.scale(t.scaleVal-t.scaleSensitivity)},s.onclick=()=>{t.scale(t.scaleVal+t.scaleSensitivity)},a.onclick=()=>{om("svg")(t)},setTimeout(()=>{const l=document.getElementById("exportSvg")},1e3),e}catch{const e=document.createElement("div");return e.className="mind-elixir-toolbar rb",e}}function um(t){const e=document.createElement("div"),r=Zr("tbltl","left"),n=Zr("tbltr","right"),i=Zr("tblts","side");return e.appendChild(r),e.appendChild(n),e.appendChild(i),e.className="mind-elixir-toolbar lt",r.onclick=()=>{t.initLeft()},n.onclick=()=>{t.initRight()},i.onclick=()=>{t.initSide()},e}function dm(t){try{if(!t.container)return;const e=cm(t),r=um(t);t.container.append(e),t.container.append(r)}catch{}}/*! @viselect/vanilla v3.9.0 MIT | https://github.com/Simonwep/selection/tree/master/packages/vanilla */class hm{constructor(){this._listeners=new Map,this.on=this.addEventListener,this.off=this.removeEventListener,this.emit=this.dispatchEvent}addEventListener(e,r){const n=this._listeners.get(e)??new Set;return this._listeners.set(e,n),n.add(r),this}removeEventListener(e,r){var n;return(n=this._listeners.get(e))==null||n.delete(r),this}dispatchEvent(e,...r){let n=!0;for(const i of this._listeners.get(e)??[])n=i(...r)!==!1&&n;return n}unbindAllListeners(){this._listeners.clear()}}const Dl=(t,e="px")=>typeof t=="number"?t+e:t,Wr=({style:t},e,r)=>{if(typeof e=="object")for(const[n,i]of Object.entries(e))i!==void 0&&(t[n]=Dl(i));else r!==void 0&&(t[e]=Dl(r))},Ol=(t=0,e=0,r=0,n=0)=>{const i={x:t,y:e,width:r,height:n,top:e,left:t,right:t+r,bottom:e+n};return{...i,toJSON:()=>JSON.stringify(i)}},fm=t=>{let e,r=-1,n=!1;return{next:(...i)=>{e=i,n||(n=!0,r=requestAnimationFrame(()=>{t(...e),n=!1}))},cancel:()=>{cancelAnimationFrame(r),n=!1}}},_l=(t,e,r="touch")=>{switch(r){case"center":{const n=e.left+e.width/2,i=e.top+e.height/2;return n>=t.left&&n<=t.right&&i>=t.top&&i<=t.bottom}case"cover":return e.left>=t.left&&e.top>=t.top&&e.right<=t.right&&e.bottom<=t.bottom;case"touch":return t.right>=e.left&&t.left<=e.right&&t.bottom>=e.top&&t.top<=e.bottom}},pm=()=>matchMedia("(hover: none), (pointer: coarse)").matches,mm=()=>"safari"in window,ma=t=>Array.isArray(t)?t:[t],a1=t=>(e,r,n,i={})=>{(e instanceof HTMLCollection||e instanceof NodeList)&&(e=Array.from(e)),r=ma(r),e=ma(e);for(const s of e)if(s)for(const a of r)s[t](a,n,{capture:!1,...i})},Gr=a1("addEventListener"),lr=a1("removeEventListener"),K0=t=>{var e;const{clientX:r,clientY:n,target:i}=((e=t.touches)==null?void 0:e[0])??t;return{x:r,y:n,target:i}},Nn=(t,e=document)=>ma(t).map(r=>typeof r=="string"?Array.from(e.querySelectorAll(r)):r instanceof Element?r:null).flat().filter(Boolean),gm=(t,e)=>e.some(r=>typeof r=="number"?t.button===r:typeof r=="object"?r.button!==t.button?!1:r.modifiers.every(n=>{switch(n){case"alt":return t.altKey;case"ctrl":return t.ctrlKey||t.metaKey;case"shift":return t.shiftKey}}):!1),{abs:mn,max:Ll,min:zl,ceil:$l}=Math,Fl=(t=[])=>({stored:t,selected:[],touched:[],changed:{added:[],removed:[]}}),o1=class extends hm{constructor(t){var e,r,n,i,s;super(),this._selection=Fl(),this._targetBoundaryScrolled=!0,this._selectables=[],this._areaLocation={y1:0,x2:0,y2:0,x1:0},this._areaRect=Ol(),this._singleClick=!0,this._scrollAvailable=!0,this._scrollingActive=!1,this._scrollSpeed={x:0,y:0},this._scrollDelta={x:0,y:0},this._lastMousePosition={x:0,y:0},this.enable=this._toggleStartEvents,this.disable=this._toggleStartEvents.bind(this,!1),this._options={selectionAreaClass:"selection-area",selectionContainerClass:void 0,selectables:[],document:window.document,startAreas:["html"],boundaries:["html"],container:"body",...t,behaviour:{overlap:"invert",intersect:"touch",triggers:[0],...t.behaviour,startThreshold:(e=t.behaviour)!=null&&e.startThreshold?typeof t.behaviour.startThreshold=="number"?t.behaviour.startThreshold:{x:10,y:10,...t.behaviour.startThreshold}:{x:10,y:10},scrolling:{speedDivider:10,manualSpeed:750,...(r=t.behaviour)==null?void 0:r.scrolling,startScrollMargins:{x:0,y:0,...(i=(n=t.behaviour)==null?void 0:n.scrolling)==null?void 0:i.startScrollMargins}}},features:{range:!0,touch:!0,deselectOnBlur:!1,...t.features,singleTap:{allow:!0,intersect:"native",...(s=t.features)==null?void 0:s.singleTap}}};for(const c of Object.getOwnPropertyNames(Object.getPrototypeOf(this)))typeof this[c]=="function"&&(this[c]=this[c].bind(this));const{document:a,selectionAreaClass:o,selectionContainerClass:l}=this._options;this._area=a.createElement("div"),this._clippingElement=a.createElement("div"),this._clippingElement.appendChild(this._area),this._area.classList.add(o),l&&this._clippingElement.classList.add(l),Wr(this._area,{willChange:"top, left, bottom, right, width, height",top:0,left:0,position:"fixed"}),Wr(this._clippingElement,{overflow:"hidden",position:"fixed",transform:"translate3d(0, 0, 0)",pointerEvents:"none",zIndex:"1"}),this._frame=fm(c=>{this._recalculateSelectionAreaRect(),this._updateElementSelection(),this._emitEvent("move",c),this._redrawSelectionArea()}),this.enable()}_toggleStartEvents(t=!0){const{document:e,features:r}=this._options,n=t?Gr:lr;n(e,"mousedown",this._onTapStart),r.touch&&n(e,"touchstart",this._onTapStart,{passive:!1})}_onTapStart(t,e=!1){const{x:r,y:n,target:i}=K0(t),{document:s,startAreas:a,boundaries:o,features:l,behaviour:c}=this._options,u=i.getBoundingClientRect();if(t instanceof MouseEvent&&!gm(t,c.triggers))return;const f=Nn(a,s),p=Nn(o,s);this._targetElement=p.find(w=>_l(w.getBoundingClientRect(),u));const g=t.composedPath(),b=f.find(w=>g.includes(w));if(this._targetBoundary=p.find(w=>g.includes(w)),!this._targetElement||!b||!this._targetBoundary||!e&&this._emitEvent("beforestart",t)===!1)return;this._areaLocation={x1:r,y1:n,x2:0,y2:0};const x=s.scrollingElement??s.body;this._scrollDelta={x:x.scrollLeft,y:x.scrollTop},this._singleClick=!0,this.clearSelection(!1,!0),Gr(s,["touchmove","mousemove"],this._delayedTapMove,{passive:!1}),Gr(s,["mouseup","touchcancel","touchend"],this._onTapStop),Gr(s,"scroll",this._onScroll),l.deselectOnBlur&&(this._targetBoundaryScrolled=!1,Gr(this._targetBoundary,"scroll",this._onStartAreaScroll))}_onSingleTap(t){const{singleTap:{intersect:e},range:r}=this._options.features,n=K0(t);let i;if(e==="native")i=n.target;else if(e==="touch"){this.resolveSelectables();const{x:a,y:o}=n;i=this._selectables.find(l=>{const{right:c,left:u,top:f,bottom:p}=l.getBoundingClientRect();return a<c&&a>u&&o<p&&o>f})}if(!i)return;for(this.resolveSelectables();!this._selectables.includes(i);)if(i.parentElement)i=i.parentElement;else{this._targetBoundaryScrolled||this.clearSelection();return}const{stored:s}=this._selection;if(this._emitEvent("start",t),t.shiftKey&&r&&this._latestElement){const a=this._latestElement,[o,l]=a.compareDocumentPosition(i)&4?[i,a]:[a,i],c=[...this._selectables.filter(u=>u.compareDocumentPosition(o)&4&&u.compareDocumentPosition(l)&2),o,l];this.select(c),this._latestElement=a}else s.includes(i)&&(s.length===1||t.ctrlKey||s.every(a=>this._selection.stored.includes(a)))?this.deselect(i):(this.select(i),this._latestElement=i)}_delayedTapMove(t){const{container:e,document:r,behaviour:{startThreshold:n}}=this._options,{x1:i,y1:s}=this._areaLocation,{x:a,y:o}=K0(t);if(typeof n=="number"&&mn(a+o-(i+s))>=n||typeof n=="object"&&mn(a-i)>=n.x||mn(o-s)>=n.y){if(lr(r,["mousemove","touchmove"],this._delayedTapMove,{passive:!1}),this._emitEvent("beforedrag",t)===!1){lr(r,["mouseup","touchcancel","touchend"],this._onTapStop);return}Gr(r,["mousemove","touchmove"],this._onTapMove,{passive:!1}),Wr(this._area,"display","block"),Nn(e,r)[0].appendChild(this._clippingElement),this.resolveSelectables(),this._singleClick=!1,this._targetRect=this._targetElement.getBoundingClientRect(),this._scrollAvailable=this._targetElement.scrollHeight!==this._targetElement.clientHeight||this._targetElement.scrollWidth!==this._targetElement.clientWidth,this._scrollAvailable&&(Gr(this._targetElement,"wheel",this._wheelScroll,{passive:!1}),Gr(this._options.document,"keydown",this._keyboardScroll,{passive:!1}),this._selectables=this._selectables.filter(l=>this._targetElement.contains(l))),this._setupSelectionArea(),this._emitEvent("start",t),this._onTapMove(t)}this._handleMoveEvent(t)}_setupSelectionArea(){const{_clippingElement:t,_targetElement:e,_area:r}=this,n=this._targetRect=e.getBoundingClientRect();this._scrollAvailable?(Wr(t,{top:n.top,left:n.left,width:n.width,height:n.height}),Wr(r,{marginTop:-n.top,marginLeft:-n.left})):(Wr(t,{top:0,left:0,width:"100%",height:"100%"}),Wr(r,{marginTop:0,marginLeft:0}))}_onTapMove(t){const{_scrollSpeed:e,_areaLocation:r,_options:n,_frame:i}=this,{speedDivider:s}=n.behaviour.scrolling,a=this._targetElement,{x:o,y:l}=K0(t);if(r.x2=o,r.y2=l,this._lastMousePosition.x=o,this._lastMousePosition.y=l,this._scrollAvailable&&!this._scrollingActive&&(e.y||e.x)){this._scrollingActive=!0;const c=()=>{if(!e.x&&!e.y){this._scrollingActive=!1;return}const{scrollTop:u,scrollLeft:f}=a;e.y&&(a.scrollTop+=$l(e.y/s),r.y1-=a.scrollTop-u),e.x&&(a.scrollLeft+=$l(e.x/s),r.x1-=a.scrollLeft-f),i.next(t),requestAnimationFrame(c)};requestAnimationFrame(c)}else i.next(t);this._handleMoveEvent(t)}_handleMoveEvent(t){const{features:e}=this._options;(e.touch&&pm()||this._scrollAvailable&&mm())&&t.preventDefault()}_onScroll(){const{_scrollDelta:t,_options:{document:e}}=this,{scrollTop:r,scrollLeft:n}=e.scrollingElement??e.body;this._areaLocation.x1+=t.x-n,this._areaLocation.y1+=t.y-r,t.x=n,t.y=r,this._setupSelectionArea(),this._frame.next(null)}_onStartAreaScroll(){this._targetBoundaryScrolled=!0,lr(this._targetElement,"scroll",this._onStartAreaScroll)}_wheelScroll(t){const{manualSpeed:e}=this._options.behaviour.scrolling,r=t.deltaY?t.deltaY>0?1:-1:0,n=t.deltaX?t.deltaX>0?1:-1:0;this._scrollSpeed.y+=r*e,this._scrollSpeed.x+=n*e,this._onTapMove(t),t.preventDefault()}_keyboardScroll(t){const{manualSpeed:e}=this._options.behaviour.scrolling,r=t.key==="ArrowLeft"?-1:t.key==="ArrowRight"?1:0,n=t.key==="ArrowUp"?-1:t.key==="ArrowDown"?1:0;this._scrollSpeed.x+=Math.sign(r)*e,this._scrollSpeed.y+=Math.sign(n)*e,t.preventDefault(),this._onTapMove({clientX:this._lastMousePosition.x,clientY:this._lastMousePosition.y,preventDefault:()=>{}})}_recalculateSelectionAreaRect(){const{_scrollSpeed:t,_areaLocation:e,_targetElement:r,_options:n}=this,{scrollTop:i,scrollHeight:s,clientHeight:a,scrollLeft:o,scrollWidth:l,clientWidth:c}=r,u=this._targetRect,{x1:f,y1:p}=e;let{x2:g,y2:b}=e;const{behaviour:{scrolling:{startScrollMargins:x}}}=n;g<u.left+x.x?(t.x=o?-mn(u.left-g+x.x):0,g=g<u.left?u.left:g):g>u.right-x.x?(t.x=l-o-c?mn(u.left+u.width-g-x.x):0,g=g>u.right?u.right:g):t.x=0,b<u.top+x.y?(t.y=i?-mn(u.top-b+x.y):0,b=b<u.top?u.top:b):b>u.bottom-x.y?(t.y=s-i-a?mn(u.top+u.height-b-x.y):0,b=b>u.bottom?u.bottom:b):t.y=0;const w=zl(f,g),N=zl(p,b),y=Ll(f,g),k=Ll(p,b);this._areaRect=Ol(w,N,y-w,k-N)}_redrawSelectionArea(){const{x:t,y:e,width:r,height:n}=this._areaRect,{style:i}=this._area;i.left=`${t}px`,i.top=`${e}px`,i.width=`${r}px`,i.height=`${n}px`}_onTapStop(t,e){var r;const{document:n,features:i}=this._options,{_singleClick:s}=this;lr(this._targetElement,"scroll",this._onStartAreaScroll),lr(n,["mousemove","touchmove"],this._delayedTapMove),lr(n,["touchmove","mousemove"],this._onTapMove),lr(n,["mouseup","touchcancel","touchend"],this._onTapStop),lr(n,"scroll",this._onScroll),this._keepSelection(),t&&s&&i.singleTap.allow?this._onSingleTap(t):!s&&!e&&(this._updateElementSelection(),this._emitEvent("stop",t)),this._scrollSpeed.x=0,this._scrollSpeed.y=0,lr(this._targetElement,"wheel",this._wheelScroll,{passive:!0}),lr(this._options.document,"keydown",this._keyboardScroll,{passive:!0}),this._clippingElement.remove(),(r=this._frame)==null||r.cancel(),Wr(this._area,"display","none")}_updateElementSelection(){const{_selectables:t,_options:e,_selection:r,_areaRect:n}=this,{stored:i,selected:s,touched:a}=r,{intersect:o,overlap:l}=e.behaviour,c=l==="invert",u=[],f=[],p=[];for(let b=0;b<t.length;b++){const x=t[b];if(_l(n,x.getBoundingClientRect(),o)){if(s.includes(x))i.includes(x)&&!a.includes(x)&&a.push(x);else if(c&&i.includes(x)){p.push(x);continue}else f.push(x);u.push(x)}}c&&f.push(...i.filter(b=>!s.includes(b)));const g=l==="keep";for(let b=0;b<s.length;b++){const x=s[b];!u.includes(x)&&!(g&&i.includes(x))&&p.push(x)}r.selected=u,r.changed={added:f,removed:p},this._latestElement=void 0}_emitEvent(t,e){return this.emit(t,{event:e,store:this._selection,selection:this})}_keepSelection(){const{_options:t,_selection:e}=this,{selected:r,changed:n,touched:i,stored:s}=e,a=r.filter(o=>!s.includes(o));switch(t.behaviour.overlap){case"drop":{e.stored=[...a,...s.filter(o=>!i.includes(o))];break}case"invert":{e.stored=[...a,...s.filter(o=>!n.removed.includes(o))];break}case"keep":{e.stored=[...s,...r.filter(o=>!s.includes(o))];break}}}trigger(t,e=!0){this._onTapStart(t,e)}resolveSelectables(){this._selectables=Nn(this._options.selectables,this._options.document)}clearSelection(t=!0,e=!1){const{selected:r,stored:n,changed:i}=this._selection;i.added=[],i.removed.push(...r,...t?n:[]),e||(this._emitEvent("move",null),this._emitEvent("stop",null)),this._selection=Fl(t?[]:n)}getSelection(){return this._selection.stored}getSelectionArea(){return this._area}getSelectables(){return this._selectables}setAreaLocation(t){Object.assign(this._areaLocation,t),this._redrawSelectionArea()}getAreaLocation(){return this._areaLocation}cancel(t=!1){this._onTapStop(null,!t)}destroy(){this.cancel(),this.disable(),this._clippingElement.remove(),super.unbindAllListeners()}select(t,e=!1){const{changed:r,selected:n,stored:i}=this._selection,s=Nn(t,this._options.document).filter(a=>!n.includes(a)&&!i.includes(a));return i.push(...s),n.push(...s),r.added.push(...s),r.removed=[],this._latestElement=void 0,e||(this._emitEvent("move",null),this._emitEvent("stop",null)),s}deselect(t,e=!1){const{selected:r,stored:n,changed:i}=this._selection,s=Nn(t,this._options.document).filter(a=>r.includes(a)||n.includes(a));this._selection.stored=n.filter(a=>!s.includes(a)),this._selection.selected=r.filter(a=>!s.includes(a)),this._selection.changed.added=[],this._selection.changed.removed.push(...s.filter(a=>!i.removed.includes(a))),this._latestElement=void 0,e||(this._emitEvent("move",null),this._emitEvent("stop",null))}};o1.version="3.9.0";let vm=o1;function bm(t){const e=t.mouseSelectionButton===2?[2]:[0],r=new vm({selectables:[".map-container me-tpc"],boundaries:[t.container],container:t.selectionContainer,features:{touch:!1},behaviour:{triggers:e,scrolling:{speedDivider:10,manualSpeed:750,startScrollMargins:{x:10,y:10}}}}).on("beforestart",({event:n})=>{var i;const s=n.target;if(s.id==="input-box"||s.className==="circle"||(i=t.container.querySelector(".context-menu"))!=null&&i.contains(s))return!1;if(!n.ctrlKey&&!n.metaKey){if(s.tagName==="ME-TPC"&&s.classList.contains("selected"))return!1;t.clearSelection()}const a=r.getSelectionArea();return a.style.background="#4f90f22d",a.style.border="1px solid #4f90f2",a.parentElement&&(a.parentElement.style.zIndex="9999"),!0}).on("move",({store:{changed:{added:n,removed:i}}})=>{if(n.length>0||i.length>0,n.length>0){for(const s of n)s.className="selected";t.currentNodes=[...t.currentNodes,...n],t.bus.fire("selectNodes",n.map(s=>s.nodeObj))}if(i.length>0){for(const s of i)s.classList.remove("selected");t.currentNodes=t.currentNodes.filter(s=>!(i!=null&&i.includes(s))),t.bus.fire("unselectNodes",i.map(s=>s.nodeObj))}});t.selection=r}const ym=function(t,e=!0){this.theme=t;const r={...(t.type==="dark"?ro:to).cssVar,...t.cssVar},n=Object.keys(r);for(let i=0;i<n.length;i++){const s=n[i];this.container.style.setProperty(s,r[s])}e&&this.refresh()},Gn=t=>{var e;const r=(e=t.parent)==null?void 0:e.children,n=(r==null?void 0:r.indexOf(t))??0;return{siblings:r,index:n}};function wm(t){const{siblings:e,index:r}=Gn(t);if(e===void 0)return;const n=e[r];r===0?(e[r]=e[e.length-1],e[e.length-1]=n):(e[r]=e[r-1],e[r-1]=n)}function xm(t){const{siblings:e,index:r}=Gn(t);if(e===void 0)return;const n=e[r];r===e.length-1?(e[r]=e[0],e[0]=n):(e[r]=e[r+1],e[r+1]=n)}function l1(t){const{siblings:e,index:r}=Gn(t);return e===void 0?0:(e.splice(r,1),e.length)}function km(t,e,r){const{siblings:n,index:i}=Gn(r);n!==void 0&&(e==="before"?n.splice(i,0,t):n.splice(i+1,0,t))}function Sm(t,e){const{siblings:r,index:n}=Gn(t);r!==void 0&&(r[n]=e,e.children=[t])}function c1(t,e,r){var n;if(l1(e),(n=r.parent)!=null&&n.parent||(e.direction=r.direction),t==="in")r.children?r.children.push(e):r.children=[e];else{e.direction!==void 0&&(e.direction=r.direction);const{siblings:i,index:s}=Gn(r);if(i===void 0)return;t==="before"?i.splice(s,0,e):i.splice(s+1,0,e)}}const Tm=function({map:t,direction:e},r){var n,i;if(e===0)return 0;if(e===1)return 1;if(e===2){const s=((n=t.querySelector(".lhs"))==null?void 0:n.childElementCount)||0,a=((i=t.querySelector(".rhs"))==null?void 0:i.childElementCount)||0;return s<=a?(r.direction=0,0):(r.direction=1,1)}},u1=function(t,e,r){var n,i;const s=r.children[0].children[0],a=e.parentElement;if(a.tagName==="ME-PARENT"){if(I0(s),a.children[1])a.nextSibling.appendChild(r);else{const o=t.createChildren([r]);a.appendChild(oo(!0)),a.insertAdjacentElement("afterend",o)}t.linkDiv(r.offsetParent)}else a.tagName==="ME-ROOT"&&(Tm(t,s.nodeObj)===0?(n=t.container.querySelector(".lhs"))==null||n.appendChild(r):(i=t.container.querySelector(".rhs"))==null||i.appendChild(r),t.linkDiv())},Am=function(t,e){const r=t.parentNode;if(e===0){const n=r.parentNode.parentNode;n.tagName!=="ME-MAIN"&&(n.previousSibling.children[1].remove(),n.remove())}r.parentNode.remove()},d1={before:"beforebegin",after:"afterend"},I0=function(t){const e=t.parentElement.parentElement.lastElementChild;(e==null?void 0:e.tagName)==="svg"&&(e==null||e.remove())},Em=function(t,e){const r=t.nodeObj,n=io(r);n.style&&e.style&&(e.style=Object.assign(n.style,e.style));const i=Object.assign(r,e);rs.call(this,t,i),this.linkDiv(),this.bus.fire("operation",{name:"reshapeNode",obj:i,origin:n})},lo=function(t,e,r){if(!e)return null;const n=e.nodeObj;n.expanded===!1&&(t.expandNode(e,!0),e=t.findEle(n.id));const i=r||t.generateNewObj();n.children?n.children.push(i):n.children=[i],un(t.nodeData);const{grp:s,top:a}=t.createWrapper(i);return u1(t,e,s),{newTop:a,newNodeObj:i}},Cm=function(t,e,r){var n,i,s,a;const o=e||this.currentNode;if(!o)return;const l=o.nodeObj;if(l.parent){if(!((n=l.parent)!=null&&n.parent)&&((s=(i=l.parent)==null?void 0:i.children)==null?void 0:s.length)===1&&this.direction===2){this.addChild(this.findEle(l.parent.id),r);return}}else{this.addChild();return}const c=r||this.generateNewObj();if(!((a=l.parent)!=null&&a.parent)){const g=o.closest("me-main").className===ir.LHS?0:1;c.direction=g}km(c,t,l),un(this.nodeData);const u=o.parentElement,{grp:f,top:p}=this.createWrapper(c);u.parentElement.insertAdjacentElement(d1[t],f),this.linkDiv(f.offsetParent),r||this.editTopic(p.firstChild),this.bus.fire("operation",{name:"insertSibling",type:t,obj:c}),this.selectNode(p.firstChild,!0)},Mm=function(t,e){const r=t||this.currentNode;if(!r)return;I0(r);const n=r.nodeObj;if(!n.parent)return;const i=e||this.generateNewObj();Sm(n,i),un(this.nodeData);const s=r.parentElement.parentElement,{grp:a,top:o}=this.createWrapper(i,!0);o.appendChild(oo(!0)),s.insertAdjacentElement("afterend",a);const l=this.createChildren([s]);o.insertAdjacentElement("afterend",l),this.linkDiv(),e||this.editTopic(o.firstChild),this.selectNode(o.firstChild,!0),this.bus.fire("operation",{name:"insertParent",obj:i})},Nm=function(t,e){const r=t||this.currentNode;if(!r)return;const n=lo(this,r,e);if(!n)return;const{newTop:i,newNodeObj:s}=n;this.bus.fire("operation",{name:"addChild",obj:s}),e||this.editTopic(i.firstChild),this.selectNode(i.firstChild,!0)},Im=function(t,e){const r=io(t.nodeObj);no(r);const n=lo(this,e,r);if(!n)return;const{newNodeObj:i}=n;this.selectNode(this.findEle(i.id)),this.bus.fire("operation",{name:"copyNode",obj:i})},Rm=function(t,e){t=ts(t);const r=[];for(let n=0;n<t.length;n++){const i=t[n],s=io(i.nodeObj);no(s);const a=lo(this,e,s);if(!a)return;const{newNodeObj:o}=a;r.push(o)}this.unselectNodes(this.currentNodes),this.selectNodes(r.map(n=>this.findEle(n.id))),this.bus.fire("operation",{name:"copyNodes",objs:r})},Dm=function(t){const e=t||this.currentNode;if(!e)return;const r=e.nodeObj;wm(r);const n=e.parentNode.parentNode;n.parentNode.insertBefore(n,n.previousSibling),this.linkDiv(),this.bus.fire("operation",{name:"moveUpNode",obj:r})},Om=function(t){const e=t||this.currentNode;if(!e)return;const r=e.nodeObj;xm(r);const n=e.parentNode.parentNode;n.nextSibling?n.nextSibling.insertAdjacentElement("afterend",n):n.parentNode.prepend(n),this.linkDiv(),this.bus.fire("operation",{name:"moveDownNode",obj:r})},_m=function(t){if(t.length===0)return;t=ts(t);for(const r of t){const n=r.nodeObj,i=l1(n);Am(r,i)}const e=t[t.length-1];this.selectNode(this.findEle(e.nodeObj.parent.id)),this.linkDiv(),this.bus.fire("operation",{name:"removeNodes",objs:t.map(r=>r.nodeObj)})},Lm=function(t,e){t=ts(t);const r=e.nodeObj;r.expanded===!1&&(this.expandNode(e,!0),e=this.findEle(r.id));for(const n of t){const i=n.nodeObj;c1("in",i,r),un(this.nodeData);const s=n.parentElement;u1(this,e,s.parentElement)}this.linkDiv(),this.bus.fire("operation",{name:"moveNodeIn",objs:t.map(n=>n.nodeObj),toObj:r})},h1=(t,e,r,n)=>{t=ts(t),e==="after"&&(t=t.reverse());const i=r.nodeObj,s=[];for(const a of t){const o=a.nodeObj;c1(e,o,i),un(n.nodeData),I0(a);const l=a.parentElement.parentNode;s.includes(l.parentElement)||s.push(l.parentElement),r.parentElement.parentNode.insertAdjacentElement(d1[e],l)}for(const a of s)a.childElementCount===0&&a.tagName!=="ME-MAIN"&&(a.previousSibling.children[1].remove(),a.remove());n.linkDiv(),n.bus.fire("operation",{name:e==="before"?"moveNodeBefore":"moveNodeAfter",objs:t.map(a=>a.nodeObj),toObj:i})},zm=function(t,e){h1(t,"before",e,this)},$m=function(t,e){h1(t,"after",e,this)},Fm=function(t){const e=t||this.currentNode;e&&(e.nodeObj.dangerouslySetInnerHTML||this.editTopic(e))},Bm=function(t,e){t.text.textContent=e,t.nodeObj.topic=e,this.linkDiv()},f1=Object.freeze(Object.defineProperty({__proto__:null,addChild:Nm,beginEdit:Fm,copyNode:Im,copyNodes:Rm,insertParent:Mm,insertSibling:Cm,moveDownNode:Om,moveNodeAfter:$m,moveNodeBefore:zm,moveNodeIn:Lm,moveUpNode:Dm,removeNodes:_m,reshapeNode:Em,rmSubline:I0,setNodeTopic:Bm},Symbol.toStringTag,{value:"Module"}));function Pm(t){return{nodeData:t.isFocusMode?t.nodeDataBackup:t.nodeData,arrows:t.arrows,summaries:t.summaries,direction:t.direction,theme:t.theme}}const Hm=function(t){const e=this.container,r=t.getBoundingClientRect(),n=e.getBoundingClientRect();if(r.top>n.bottom||r.bottom<n.top||r.left>n.right||r.right<n.left){const i=r.left+r.width/2,s=r.top+r.height/2,a=n.left+n.width/2,o=n.top+n.height/2,l=i-a,c=s-o;this.move(-l,-c,!0)}},qm=function(t,e,r){this.clearSelection(),this.scrollIntoView(t),this.selection.select(t),e&&this.bus.fire("selectNewNode",t.nodeObj)},jm=function(t){this.selection.select(t)},Um=function(t){this.selection.deselect(t)},Vm=function(){this.unselectNodes(this.currentNodes),this.unselectSummary(),this.unselectArrow()},Wm=function(){const t=Pm(this);return JSON.stringify(t,(e,r)=>{if(!(e==="parent"&&typeof r!="string"))return r})},Gm=function(){return JSON.parse(this.getDataString())},Km=function(){this.editable=!0},Ym=function(){this.editable=!1},Xm=function(t,e={x:0,y:0}){if(t<this.scaleMin||t>this.scaleMax)return;const r=this.container.getBoundingClientRect(),n=e.x?e.x-r.left-r.width/2:0,i=e.y?e.y-r.top-r.height/2:0,{dx:s,dy:a}=p1(this),o=this.map.style.transform,{x:l,y:c}=e1(o),u=l-s,f=c-a,p=this.scaleVal,g=(-n+u)*(1-t/p),b=(-i+f)*(1-t/p);this.map.style.transform=`translate(${l-g}px, ${c-b}px) scale(${t})`,this.scaleVal=t,this.bus.fire("scale",t)},Jm=function(){const t=this.nodes.offsetHeight/this.container.offsetHeight,e=this.nodes.offsetWidth/this.container.offsetWidth,r=1/Math.max(1,Math.max(t,e));this.scaleVal=r,this.map.style.transform="scale("+r+")",this.bus.fire("scale",r)},Zm=function(t,e,r=!1){const{map:n,scaleVal:i,bus:s}=this,a=n.style.transform;let{x:o,y:l}=e1(a);o+=t,l+=e,r&&(n.style.transition="transform 0.3s",setTimeout(()=>{n.style.transition="none"},300)),n.style.transform=`translate(${o}px, ${l}px) scale(${i})`,s.fire("move",{dx:t,dy:e})},p1=t=>{const{container:e,map:r,nodes:n}=t,i=r.querySelector("me-root"),s=i.offsetTop,a=i.offsetLeft,o=i.offsetWidth,l=i.offsetHeight;let c,u;return t.alignment==="root"?(c=e.offsetWidth/2-a-o/2,u=e.offsetHeight/2-s-l/2,r.style.transformOrigin=`${a+o/2}px 50%`):(c=(e.offsetWidth-n.offsetWidth)/2,u=(e.offsetHeight-n.offsetHeight)/2,r.style.transformOrigin="50% 50%"),{dx:c,dy:u}},Qm=function(){const{map:t}=this,{dx:e,dy:r}=p1(this);t.style.transform=`translate(${e}px, ${r}px) scale(${this.scaleVal})`},e4=function(t){t(this)},t4=function(t){t.nodeObj.parent&&(this.clearSelection(),this.tempDirection===null&&(this.tempDirection=this.direction),this.isFocusMode||(this.nodeDataBackup=this.nodeData,this.isFocusMode=!0),this.nodeData=t.nodeObj,this.initRight(),this.toCenter())},r4=function(){this.isFocusMode=!1,this.tempDirection!==null&&(this.nodeData=this.nodeDataBackup,this.direction=this.tempDirection,this.tempDirection=null,this.refresh(),this.toCenter())},n4=function(){this.direction=0,this.refresh(),this.toCenter()},i4=function(){this.direction=1,this.refresh(),this.toCenter()},s4=function(){this.direction=2,this.refresh(),this.toCenter()},a4=function(t){this.locale=t,this.refresh()},o4=function(t,e){const r=t.nodeObj;typeof e=="boolean"?r.expanded=e:r.expanded!==!1?r.expanded=!1:r.expanded=!0;const n=t.getBoundingClientRect(),i={x:n.left,y:n.top},s=t.parentNode,a=s.children[1];if(a.expanded=r.expanded,a.className=r.expanded?"minus":"",I0(t),r.expanded){const f=this.createChildren(r.children.map(p=>this.createWrapper(p).grp));s.parentNode.appendChild(f)}else s.parentNode.children[1].remove();this.linkDiv(t.closest("me-main > me-wrapper"));const o=t.getBoundingClientRect(),l={x:o.left,y:o.top},c=i.x-l.x,u=i.y-l.y;this.move(c,u),this.bus.fire("expandNode",r)},l4=function(t,e){const r=t.nodeObj,n=t.getBoundingClientRect(),i={x:n.left,y:n.top};Hn(r,e??!r.expanded),this.refresh();const s=this.findEle(r.id).getBoundingClientRect(),a={x:s.left,y:s.top},o=i.x-a.x,l=i.y-a.y;this.move(o,l)},c4=function(t){this.clearSelection(),t&&(t=JSON.parse(JSON.stringify(t)),this.nodeData=t.nodeData,this.arrows=t.arrows||[],this.summaries=t.summaries||[],t.theme&&this.changeTheme(t.theme)),un(this.nodeData),this.layout(),this.linkDiv()},u4=Object.freeze(Object.defineProperty({__proto__:null,cancelFocus:r4,clearSelection:Vm,disableEdit:Ym,enableEdit:Km,expandNode:o4,expandNodeAll:l4,focusNode:t4,getData:Gm,getDataString:Wm,initLeft:n4,initRight:i4,initSide:s4,install:e4,move:Zm,refresh:c4,scale:Xm,scaleFit:Jm,scrollIntoView:Hm,selectNode:qm,selectNodes:jm,setLocale:a4,toCenter:Qm,unselectNodes:Um},Symbol.toStringTag,{value:"Module"})),d4=function(t){return{dom:t,moved:!1,pointerdown:!1,lastX:0,lastY:0,handlePointerMove(e){if(this.pointerdown){this.moved=!0;const r=e.clientX-this.lastX,n=e.clientY-this.lastY;this.lastX=e.clientX,this.lastY=e.clientY,this.cb&&this.cb(r,n)}},handlePointerDown(e){e.button===0&&(this.pointerdown=!0,this.lastX=e.clientX,this.lastY=e.clientY,this.dom.setPointerCapture(e.pointerId))},handleClear(e){this.pointerdown=!1,e.pointerId!==void 0&&this.dom.releasePointerCapture(e.pointerId)},cb:null,init(e,r){this.cb=r,this.handleClear=this.handleClear.bind(this),this.handlePointerMove=this.handlePointerMove.bind(this),this.handlePointerDown=this.handlePointerDown.bind(this),this.destroy=so([{dom:e,evt:"pointermove",func:this.handlePointerMove},{dom:e,evt:"pointerleave",func:this.handleClear},{dom:e,evt:"pointerup",func:this.handleClear},{dom:this.dom,evt:"pointerdown",func:this.handlePointerDown}])},destroy:null,clear(){this.moved=!1,this.pointerdown=!1}}},Bl={create:d4},h4="#4dc4ff";function m1(t,e,r,n,i,s,a,o){return{x:t/8+r*3/8+i*3/8+a/8,y:e/8+n*3/8+s*3/8+o/8}}function f4(t,e,r){rt(t,{x:e+"",y:r+""})}function Y0(t,e,r,n,i){rt(t,{x1:e+"",y1:r+"",x2:n+"",y2:i+""})}function Pl(t,e,r,n,i,s,a,o,l,c){var u;const f=`M ${e} ${r} C ${n} ${i} ${s} ${a} ${o} ${l}`;if(t.line.setAttribute("d",f),c.style){const w=c.style;w.stroke&&t.line.setAttribute("stroke",w.stroke),w.strokeWidth&&t.line.setAttribute("stroke-width",String(w.strokeWidth)),w.strokeDasharray&&t.line.setAttribute("stroke-dasharray",w.strokeDasharray),w.strokeLinecap&&t.line.setAttribute("stroke-linecap",w.strokeLinecap),w.opacity!==void 0&&t.line.setAttribute("opacity",String(w.opacity))}const p=t.querySelectorAll('path[stroke="transparent"]');p.length>0&&p[0].setAttribute("d",f);const g=Ii(s,a,o,l);if(g){const w=`M ${g.x1} ${g.y1} L ${o} ${l} L ${g.x2} ${g.y2}`;if(t.arrow1.setAttribute("d",w),p.length>1&&p[1].setAttribute("d",w),c.style){const N=c.style;N.stroke&&t.arrow1.setAttribute("stroke",N.stroke),N.strokeWidth&&t.arrow1.setAttribute("stroke-width",String(N.strokeWidth)),N.strokeLinecap&&t.arrow1.setAttribute("stroke-linecap",N.strokeLinecap),N.opacity!==void 0&&t.arrow1.setAttribute("opacity",String(N.opacity))}}if(c.bidirectional){const w=Ii(n,i,e,r);if(w){const N=`M ${w.x1} ${w.y1} L ${e} ${r} L ${w.x2} ${w.y2}`;if(t.arrow2.setAttribute("d",N),p.length>2&&p[2].setAttribute("d",N),c.style){const y=c.style;y.stroke&&t.arrow2.setAttribute("stroke",y.stroke),y.strokeWidth&&t.arrow2.setAttribute("stroke-width",String(y.strokeWidth)),y.strokeLinecap&&t.arrow2.setAttribute("stroke-linecap",y.strokeLinecap),y.opacity!==void 0&&t.arrow2.setAttribute("opacity",String(y.opacity))}}}const{x:b,y:x}=m1(e,r,n,i,s,a,o,l);f4(t.label,b,x),(u=c.style)!=null&&u.labelColor&&t.label.setAttribute("fill",c.style.labelColor),x4(t)}function Oi(t,e,r){const{offsetLeft:n,offsetTop:i}=N0(t.nodes,e),s=e.offsetWidth,a=e.offsetHeight,o=n+s/2,l=i+a/2,c=o+r.x,u=l+r.y;return{w:s,h:a,cx:o,cy:l,ctrlX:c,ctrlY:u}}function Ln(t){let e,r;const n=(t.cy-t.ctrlY)/(t.ctrlX-t.cx);return n>t.h/t.w||n<-t.h/t.w?t.cy-t.ctrlY<0?(e=t.cx-t.h/2/n,r=t.cy+t.h/2):(e=t.cx+t.h/2/n,r=t.cy-t.h/2):t.cx-t.ctrlX<0?(e=t.cx+t.w/2,r=t.cy-t.w*n/2):(e=t.cx-t.w/2,r=t.cy+t.w*n/2),{x:e,y:r}}const co=function(t,e,r,n,i){var s;if(!e||!r)return;const a=Oi(t,e,n.delta1),o=Oi(t,r,n.delta2),{x:l,y:c}=Ln(a),{ctrlX:u,ctrlY:f}=a,{ctrlX:p,ctrlY:g}=o,{x:b,y:x}=Ln(o),w=Ii(p,g,b,x);if(!w)return;const N=`M ${w.x1} ${w.y1} L ${b} ${x} L ${w.x2} ${w.y2}`;let y="";if(n.bidirectional){const W=Ii(u,f,l,c);if(!W)return;y=`M ${W.x1} ${W.y1} L ${l} ${c} L ${W.x2} ${W.y2}`}const k=Up(`M ${l} ${c} C ${u} ${f} ${p} ${g} ${b} ${x}`,N,y,n.style),{x:I,y:D}=m1(l,c,u,f,p,g,b,x),O=(s=n.style)==null?void 0:s.labelColor,z=ha(n.label,I,D,{anchor:"middle",color:O,dataType:"custom-link"});k.appendChild(z),k.label=z,k.arrowObj=n,k.dataset.linkid=n.id,t.linkSvgGroup.appendChild(k),i||(t.arrows.push(n),t.currentArrow=k,g1(t,n,a,o))},p4=function(t,e,r={}){const n={id:Tn(),label:"Custom Link",from:t.nodeObj.id,to:e.nodeObj.id,delta1:{x:t.offsetWidth/2+100,y:0},delta2:{x:e.offsetWidth/2+100,y:0},...r};co(this,t,e,n),this.bus.fire("operation",{name:"createArrow",obj:n})},m4=function(t){ns(this);const e={...t,id:Tn()};co(this,this.findEle(e.from),this.findEle(e.to),e),this.bus.fire("operation",{name:"createArrow",obj:e})},g4=function(t){let e;if(t?e=t:e=this.currentArrow,!e)return;ns(this);const r=e.arrowObj.id;this.arrows=this.arrows.filter(n=>n.id!==r),e.remove(),this.bus.fire("operation",{name:"removeArrow",obj:{id:r}})},v4=function(t){this.currentArrow=t;const e=t.arrowObj,r=this.findEle(e.from),n=this.findEle(e.to),i=Oi(this,r,e.delta1),s=Oi(this,n,e.delta2);g1(this,e,i,s)},b4=function(){ns(this),this.currentArrow=null},Ds=function(t,e){const r=document.createElementNS(rr,"path");return rt(r,{d:t,stroke:e,fill:"none","stroke-width":"6","stroke-linecap":"round","stroke-linejoin":"round"}),r},y4=function(t,e){const r=document.createElementNS(rr,"g");r.setAttribute("class","arrow-highlight"),r.setAttribute("opacity","0.45");const n=Ds(t.line.getAttribute("d"),e);r.appendChild(n);const i=Ds(t.arrow1.getAttribute("d"),e);if(r.appendChild(i),t.arrow2.getAttribute("d")){const s=Ds(t.arrow2.getAttribute("d"),e);r.appendChild(s)}t.insertBefore(r,t.firstChild)},w4=function(t){const e=t.querySelector(".arrow-highlight");e&&e.remove()},x4=function(t){const e=t.querySelector(".arrow-highlight");if(!e)return;const r=e.querySelectorAll("path");r.length>=1&&r[0].setAttribute("d",t.line.getAttribute("d")),r.length>=2&&r[1].setAttribute("d",t.arrow1.getAttribute("d")),r.length>=3&&t.arrow2.getAttribute("d")&&r[2].setAttribute("d",t.arrow2.getAttribute("d"))},ns=function(t){var e,r;(e=t.helper1)==null||e.destroy(),(r=t.helper2)==null||r.destroy(),t.linkController.style.display="none",t.P2.style.display="none",t.P3.style.display="none",t.currentArrow&&w4(t.currentArrow)},g1=function(t,e,r,n){const{linkController:i,P2:s,P3:a,line1:o,line2:l,nodes:c,map:u,currentArrow:f,bus:p}=t;if(!f)return;i.style.display="initial",s.style.display="initial",a.style.display="initial",c.appendChild(i),c.appendChild(s),c.appendChild(a),y4(f,h4);let{x:g,y:b}=Ln(r),{ctrlX:x,ctrlY:w}=r,{ctrlX:N,ctrlY:y}=n,{x:k,y:I}=Ln(n);s.style.cssText=`top:${w}px;left:${x}px;`,a.style.cssText=`top:${y}px;left:${N}px;`,Y0(o,g,b,x,w),Y0(l,N,y,k,I),t.helper1=Bl.create(s),t.helper2=Bl.create(a),t.helper1.init(u,(D,O)=>{x=x+D/t.scaleVal,w=w+O/t.scaleVal;const z=Ln({...r,ctrlX:x,ctrlY:w});g=z.x,b=z.y,s.style.top=w+"px",s.style.left=x+"px",Pl(f,g,b,x,w,N,y,k,I,e),Y0(o,g,b,x,w),e.delta1.x=x-r.cx,e.delta1.y=w-r.cy,p.fire("updateArrowDelta",e)}),t.helper2.init(u,(D,O)=>{N=N+D/t.scaleVal,y=y+O/t.scaleVal;const z=Ln({...n,ctrlX:N,ctrlY:y});k=z.x,I=z.y,a.style.top=y+"px",a.style.left=N+"px",Pl(f,g,b,x,w,N,y,k,I,e),Y0(l,N,y,k,I),e.delta2.x=N-n.cx,e.delta2.y=y-n.cy,p.fire("updateArrowDelta",e)})};function k4(){this.linkSvgGroup.innerHTML="";for(let t=0;t<this.arrows.length;t++){const e=this.arrows[t];try{co(this,this.findEle(e.from),this.findEle(e.to),e,!0)}catch{}}this.nodes.appendChild(this.linkSvgGroup)}function S4(t){if(ns(this),!t)return;const e=t.label;i1(this,e,t.arrowObj)}function T4(){this.arrows=this.arrows.filter(t=>Ni(t.from,this.nodeData)&&Ni(t.to,this.nodeData))}const A4=Object.freeze(Object.defineProperty({__proto__:null,createArrow:p4,createArrowFrom:m4,editArrowLabel:S4,removeArrow:g4,renderArrow:k4,selectArrow:v4,tidyArrow:T4,unselectArrow:b4},Symbol.toStringTag,{value:"Module"})),E4=function(t){var e,r;if(t.length===0)throw new Error("No selected node.");if(t.length===1){const u=t[0].nodeObj,f=t[0].nodeObj.parent;if(!f)throw new Error("Can not select root node.");const p=f.children.findIndex(g=>u===g);return{parent:f.id,start:p,end:p}}let n=0;const i=t.map(u=>{let f=u.nodeObj;const p=[];for(;f.parent;){const g=f.parent,b=g.children,x=b==null?void 0:b.indexOf(f);f=g,p.unshift({node:f,index:x})}return p.length>n&&(n=p.length),p});let s=0;e:for(;s<n;s++){const u=(e=i[0][s])==null?void 0:e.node;for(let f=1;f<i.length;f++)if(((r=i[f][s])==null?void 0:r.node)!==u)break e}if(!s)throw new Error("Can not select root node.");const a=i.map(u=>u[s-1].index).sort(),o=a[0]||0,l=a[a.length-1]||0,c=i[0][s-1].node;if(!c.parent)throw new Error("Please select nodes in the same main topic.");return{parent:c.id,start:o,end:l}},C4=function(t){const e=document.createElementNS(rr,"g");return e.setAttribute("id",t),e},Hl=function(t,e){const r=document.createElementNS(rr,"path");return rt(r,{d:t,stroke:e||"#666",fill:"none","stroke-linecap":"round","stroke-width":"2"}),r},M4=t=>t.parentElement.parentElement,N4=function(t,{parent:e,start:r}){const n=t.findEle(e),i=n.nodeObj;let s;return i.parent?s=n.closest("me-main").className:s=t.findEle(i.children[r].id).closest("me-main").className,s},uo=function(t,e){var r;const{id:n,label:i,parent:s,start:a,end:o}=e,{nodes:l,theme:c,summarySvg:u}=t,f=t.findEle(s).nodeObj,p=N4(t,e);let g=1/0,b=0,x=0,w=0;for(let W=a;W<=o;W++){const H=(r=f.children)==null?void 0:r[W];if(!H)return t.removeSummary(n),null;const oe=M4(t.findEle(H.id)),{offsetLeft:me,offsetTop:ye}=N0(l,oe),Le=a===o?10:20;W===a&&(x=ye+Le),W===o&&(w=ye+oe.offsetHeight-Le),me<g&&(g=me),oe.offsetWidth+me>b&&(b=oe.offsetWidth+me)}let N,y;const k=x+10,I=w+10,D=(k+I)/2,O=c.cssVar["--color"];p===ir.LHS?(N=Hl(`M ${g+10} ${k} c -5 0 -10 5 -10 10 L ${g} ${I-10} c 0 5 5 10 10 10 M ${g} ${D} h -10`,O),y=ha(i,g-20,D+6,{anchor:"end",color:O})):(N=Hl(`M ${b-10} ${k} c 5 0 10 5 10 10 L ${b} ${I-10} c 0 5 -5 10 -10 10 M ${b} ${D} h 10`,O),y=ha(i,b+20,D+6,{anchor:"start",color:O}));const z=C4("s-"+n);return z.appendChild(N),z.appendChild(y),z.summaryObj=e,u.appendChild(z),z},I4=function(){if(!this.currentNodes)return;const{currentNodes:t,summaries:e,bus:r}=this,{parent:n,start:i,end:s}=E4(t),a={id:Tn(),parent:n,start:i,end:s,label:"summary"},o=uo(this,a);e.push(a),this.editSummary(o),r.fire("operation",{name:"createSummary",obj:a})},R4=function(t){const e=Tn(),r={...t,id:e};uo(this,r),this.summaries.push(r),this.bus.fire("operation",{name:"createSummary",obj:r})},D4=function(t){var e;const r=this.summaries.findIndex(n=>n.id===t);r>-1&&(this.summaries.splice(r,1),(e=document.querySelector("#s-"+t))==null||e.remove()),this.bus.fire("operation",{name:"removeSummary",obj:{id:t}})},O4=function(t){const e=t.children[1].getBBox(),r=6,n=3,i=document.createElementNS(rr,"rect");rt(i,{x:e.x-r+"",y:e.y-r+"",width:e.width+r*2+"",height:e.height+r*2+"",rx:n+"",stroke:this.theme.cssVar["--selected"]||"#4dc4ff","stroke-width":"2",fill:"none"}),t.appendChild(i),this.currentSummary=t},_4=function(){var t,e;(e=(t=this.currentSummary)==null?void 0:t.querySelector("rect"))==null||e.remove(),this.currentSummary=null},L4=function(){this.summarySvg.innerHTML="",this.summaries.forEach(t=>{try{uo(this,t)}catch{}}),this.nodes.insertAdjacentElement("beforeend",this.summarySvg)},z4=function(t){if(!t)return;const e=t.childNodes[1];i1(this,e,t.summaryObj)},$4=Object.freeze(Object.defineProperty({__proto__:null,createSummary:I4,createSummaryFrom:R4,editSummary:z4,removeSummary:D4,renderSummary:L4,selectSummary:O4,unselectSummary:_4},Symbol.toStringTag,{value:"Module"})),vt="http://www.w3.org/2000/svg";function F4(t,e){const r=document.createElementNS(vt,"svg");return rt(r,{version:"1.1",xmlns:vt,height:t,width:e}),r}function v1(t,e,r,n){const i=document.createElementNS(vt,"g");let s="";t.text?s=t.text.textContent:s=t.childNodes[0].textContent;const a=s.split(`
|
||
`),o=parseFloat(e.lineHeight)||parseFloat(e.fontSize)*1.2,l=parseFloat(e.fontSize),c=parseInt(e.paddingTop)||8,u=parseInt(e.paddingLeft)||8,f=t.offsetWidth||200,p=r+u,g=(a.length-1)*o+l+c+(parseInt(e.paddingBottom)||8),b=t.offsetHeight||100,x=Math.min(g,b),w=document.createElementNS(vt,"rect");return rt(w,{x:r+"",y:n+"",rx:e.borderRadius||"8",ry:e.borderRadius||"8",width:f+"px",height:x+"px",fill:e.backgroundColor||"white",stroke:e.borderColor||"#ccc","stroke-width":e.borderWidth||"1"}),i.appendChild(w),a.forEach((N,y)=>{const k=document.createElementNS(vt,"text");rt(k,{x:p+"",y:n+c+l+o*y+"","text-anchor":"start","font-family":e.fontFamily,"font-size":`${e.fontSize}`,"font-weight":`${e.fontWeight}`,fill:`${e.color}`}),k.innerHTML=N,i.appendChild(k)}),i}function ql(t){if(!t)return t;let e=t.replace(/<td[^>]*>([^<]*)<br\s*\/?>([^<]*)<\/td>/gi,(r,n,i)=>`<td>${n} ${i}</td>`);return e=e.replace(/<th[^>]*>([^<]*)<br\s*\/?>([^<]*)<\/th>/gi,(r,n,i)=>`<th>${n} ${i}</th>`),e=e.replace(/<br\s*\/?>/gi," "),e=e.replace(/•\s*【/g,"【"),e=e.replace(/•\s*\[/g,"["),e=e.replace(/•\s*(/g,"("),e=e.replace(/•\s*\(/g,"("),e=e.replace(/<([^>]+)>/g,(r,n)=>{const i=["br","hr","img","input","meta","link"],s=n.split(" ")[0].toLowerCase();return i.includes(s)?`<${n} />`:r}),e}function Os(t,e,r,n,i=!1){const s=document.createElementNS(vt,"g");i||s.setAttribute("transform",`translate(${r}, ${n})`);const a=t;let o="";a.nodeObj&&a.nodeObj.dangerouslySetInnerHTML?o=a.nodeObj.dangerouslySetInnerHTML:a.text&&a.text.innerHTML&&(o=a.text.innerHTML);const l=o&&o!==t.textContent,c=o&&o.includes("<table");if(c){const u=t.offsetWidth||400,f=t.offsetHeight||200,p=document.createElementNS(vt,"rect");rt(p,{x:r+"",y:n+"",width:u+"",height:f+"",fill:"white",stroke:"#ccc","stroke-width":"1"}),s.appendChild(p);const g=document.createElementNS(vt,"foreignObject");rt(g,{x:i?r+"":"0",y:i?n+"":"0",width:u+"",height:f+""});const b=`
|
||
<div xmlns="http://www.w3.org/1999/xhtml" style="
|
||
width: 100%;
|
||
height: 100%;
|
||
padding: 8px;
|
||
box-sizing: border-box;
|
||
overflow: hidden;
|
||
font-family: '${(e.fontFamily||"Arial, sans-serif").replace(/"/g,""")}';
|
||
font-size: ${e.fontSize||"14px"};
|
||
line-height: 1.4;
|
||
">
|
||
${ql(o)}
|
||
</div>
|
||
`;return g.innerHTML=b,s.appendChild(g),s}if(l&&!c){const u=ql(o),f=t.getBoundingClientRect(),p=f.width,g=f.height;u.includes("<img"),a.nodeObj&&a.nodeObj.image;try{const O=document.createElement("div");O.innerHTML=u,O.style.cssText=`
|
||
position: absolute;
|
||
top: -9999px;
|
||
left: -9999px;
|
||
width: ${p}px;
|
||
font-family: '${(e.fontFamily||"Arial").replace(/"/g,""")}';
|
||
font-size: ${e.fontSize};
|
||
color: ${e.color};
|
||
`,document.body.appendChild(O);const z=(O.textContent||O.innerText||"").split(`
|
||
`).filter(W=>W.trim());if(z.length>0){const W=parseFloat(e.fontSize)||14,H=W*1.4,oe=parseInt(e.paddingTop)||8,me=parseInt(e.paddingBottom)||8,ye=parseInt(e.paddingLeft)||8,Le=(z.length-1)*H+W+oe+me,ze=Math.min(Le,g),Ge=u.includes("<img"),Oe=Ge?r+p/2:r+ye,ke=n+W+oe;z.forEach((je,Ke)=>{const Be=document.createElementNS(vt,"text");rt(Be,{x:Oe+"",y:ke+H*Ke+"","text-anchor":Ge?"middle":"start","font-family":e.fontFamily,"font-size":e.fontSize,"font-weight":e.fontWeight,fill:e.color}),Be.innerHTML=je.trim(),s.appendChild(Be)});const he=document.createElementNS(vt,"rect");return rt(he,{x:r+"",y:n+"",rx:e.borderRadius||"8",ry:e.borderRadius||"8",width:p+"px",height:ze+"px",fill:e.backgroundColor||"white",stroke:e.borderColor||"#ccc","stroke-width":e.borderWidth||"1"}),s.insertBefore(he,s.firstChild),document.body.removeChild(O),s}document.body.removeChild(O)}catch{}const b=document.createElementNS(vt,"foreignObject");rt(b,{x:r+"",y:n+"",width:p+"px",height:g+"px"});const x=document.createElement("div");x.innerHTML=u;const w=15,N=15,y=parseInt(e.paddingLeft)||8,k=parseInt(e.paddingRight)||8;x.style.cssText=`
|
||
width: 100%;
|
||
height: 100%;
|
||
font-family: '${(e.fontFamily||"Arial").replace(/"/g,""")}';
|
||
font-size: ${e.fontSize};
|
||
color: ${e.color};
|
||
background: transparent;
|
||
padding: ${w}px ${k}px ${N}px ${y}px;
|
||
box-sizing: border-box;
|
||
overflow: visible;
|
||
text-align: center !important;
|
||
display: flex;
|
||
flex-direction: column;
|
||
justify-content: center;
|
||
align-items: center;
|
||
position: relative;
|
||
`,x.querySelectorAll("table").forEach(O=>{const z=O;z.style.cssText=`
|
||
width: 100%;
|
||
border-collapse: collapse;
|
||
font-size: ${e.fontSize};
|
||
font-family: '${(e.fontFamily||"Arial").replace(/"/g,""")}';
|
||
margin: 0 auto 0px auto;
|
||
border: 1px solid #ccc;
|
||
`,O.querySelectorAll("td, th").forEach(W=>{const H=W;H.style.cssText=`
|
||
border: 1px solid #ccc;
|
||
padding: 4px 8px;
|
||
text-align: center;
|
||
vertical-align: top;
|
||
font-size: ${parseFloat(e.fontSize)*.9}px;
|
||
background: white;
|
||
`})}),x.querySelectorAll("ul, ol").forEach(O=>{const z=O;z.style.cssText=`
|
||
margin: 2px 0 4px 0 !important;
|
||
padding-left: 0 !important;
|
||
text-align: center !important;
|
||
list-style-position: inside !important;
|
||
`}),x.querySelectorAll("li").forEach(O=>{const z=O;z.style.cssText=`
|
||
margin: 1px 0 !important;
|
||
line-height: 1.2 !important;
|
||
padding: 0 !important;
|
||
text-align: center !important;
|
||
list-style-position: inside !important;
|
||
`}),x.querySelectorAll("p").forEach(O=>{const z=O;z.style.cssText=`
|
||
margin: 2px 0 !important;
|
||
line-height: 1.4 !important;
|
||
padding: 0 !important;
|
||
text-align: center !important;
|
||
`}),x.querySelectorAll("span, div, strong, em").forEach(O=>{const z=O;z.style.cssText=`
|
||
text-align: center !important;
|
||
display: block !important;
|
||
margin-left: auto !important;
|
||
margin-right: auto !important;
|
||
`});const I=document.createElement("style");I.textContent=`
|
||
* {
|
||
text-align: center !important;
|
||
margin-left: auto !important;
|
||
margin-right: auto !important;
|
||
}
|
||
`,x.appendChild(I),x.querySelectorAll("img").forEach((O,z)=>{const W=O,H=p-y-k-5,oe=Math.floor(g*.7);W.style.cssText=`
|
||
max-width: ${H}px !important;
|
||
max-height: ${oe}px !important;
|
||
width: auto !important;
|
||
height: auto !important;
|
||
display: block !important;
|
||
margin: 8px auto 0px auto !important;
|
||
border-radius: 4px;
|
||
object-fit: contain !important;
|
||
flex-shrink: 0 !important;
|
||
box-sizing: border-box !important;
|
||
position: relative !important;
|
||
top: 0 !important;
|
||
left: 0 !important;
|
||
right: 0 !important;
|
||
bottom: 0 !important;
|
||
`}),b.appendChild(x);const D=document.createElementNS(vt,"rect");rt(D,{x:r+"",y:n+"",rx:e.borderRadius||"8",ry:e.borderRadius||"8",width:p+"px",height:g+"px",fill:e.backgroundColor||"white",stroke:e.borderColor||"#ccc","stroke-width":e.borderWidth||"1"}),s.insertBefore(D,s.firstChild),s.appendChild(b)}else return v1(t,e,r,n);return s}function X0(t,e,r=!1,n){var i;const s=getComputedStyle(e);let a,o;if(n)a=n.x,o=n.y;else{const{offsetLeft:g,offsetTop:b}=ao(t.nodes,e);a=g,o=b}Cp(e);const l=e;l.nodeObj&&l.nodeObj.dangerouslySetInnerHTML&&((i=l.nodeObj.dangerouslySetInnerHTML)==null||i.includes("<img")),l.nodeObj&&l.nodeObj.image;const c=document.createElementNS(vt,"g");n||c.setAttribute("transform",`translate(${a}, ${o})`);let u=null;const f=e,p=f.nodeObj&&f.nodeObj.dangerouslySetInnerHTML&&f.nodeObj.dangerouslySetInnerHTML.includes("<table");if(f.nodeObj&&f.nodeObj.dangerouslySetInnerHTML){if(p)return Os(e,s,a,o);u=Os(e,s,a,o)}else r?u=Os(e,s,a,o):u=v1(e,s,a,o);return u&&c.appendChild(u),c}function B4(t,e){const r=getComputedStyle(e),{offsetLeft:n,offsetTop:i}=N0(t.nodes,e),s=document.createElementNS(vt,"a"),a=document.createElementNS(vt,"text");return rt(a,{x:n+"",y:i+parseInt(r.fontSize)+"","text-anchor":"start","font-family":r.fontFamily,"font-size":`${r.fontSize}`,"font-weight":`${r.fontWeight}`,fill:`${r.color}`}),a.innerHTML=e.textContent,s.appendChild(a),s.setAttribute("href",e.href),s}async function P4(t,e){const r=getComputedStyle(e),{offsetLeft:n,offsetTop:i}=ao(t.nodes,e);if(!e.nodeObj.image)return null;const s=e.nodeObj.image,a=document.createElementNS(vt,"image"),o=parseInt(r.width),l=parseInt(r.height),c=Math.min(o-10,300),u=Math.min(l*.6,150),f=Math.min(s.width||200,c),p=Math.min(s.height||150,u);let g=0;if(e.text&&e.text.textContent){const w=e.text.textContent.trim();if(w){const N=w.split(`
|
||
`).length,y=parseFloat(r.lineHeight)||parseFloat(r.fontSize)*1.2;parseFloat(r.fontSize);const k=parseInt(r.paddingTop)||8,I=parseInt(r.paddingBottom)||8;g=N*y+k+I}}const b=n+(o-f)/2,x=i+g+0;try{const w=await b1(s.url);rt(a,{x:b+"",y:x+"",width:f+"",height:p+"",href:w})}catch{rt(a,{x:b+"",y:x+"",width:f+"",height:p+"",href:s.url})}return a}async function H4(t,e){const r=getComputedStyle(e),{offsetLeft:n,offsetTop:i}=ao(t.nodes,e),s=document.createElementNS(vt,"image"),a=t.imageProxy?t.imageProxy(e.src):e.src,o=Math.min(parseInt(r.width)||300,300),l=Math.min(parseInt(r.height)||200,200);try{const c=await b1(a);rt(s,{x:n+"",y:i+"",width:o+"",height:l+"",href:c})}catch{rt(s,{x:n+"",y:i+"",width:o+"",height:l+"",href:a})}return s}function b1(t){return new Promise((e,r)=>{const n=new Image;n.crossOrigin="anonymous",n.onload=()=>{try{const i=document.createElement("canvas");i.width=n.width,i.height=n.height;const s=i.getContext("2d");if(!s){r(new Error("Failed to get canvas context"));return}s.drawImage(n,0,0);const a=i.toDataURL("image/png");e(a)}catch(i){r(i)}},n.onerror=()=>{r(new Error("Failed to load image"))},n.src=t})}const J0=100,q4='<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">',jl=(t,e)=>{const r=t.getBoundingClientRect(),n=e.getBoundingClientRect();return window.getComputedStyle(e).transform,{x:r.left-n.left,y:r.top-n.top,width:r.width,height:r.height}},j4=async()=>{await new Promise(t=>setTimeout(t,0)),await document.fonts.ready,await new Promise(t=>requestAnimationFrame(t)),await new Promise(t=>setTimeout(t,100))},U4=async(t,e=!1)=>{var r,n,i;await j4();const s=t.nodes;s.getBoundingClientRect();const a=s.offsetHeight+J0*2,o=s.offsetWidth+J0*2,l=F4(a+"px",o+"px"),c=document.createElementNS(vt,"svg"),u=document.createElementNS(vt,"rect");rt(u,{x:"0",y:"0",width:`${o}`,height:`${a}`,fill:t.theme.cssVar["--bgcolor"]}),l.appendChild(u),s.querySelectorAll(".subLines").forEach(w=>{const N=w.cloneNode(!0),y=w.parentElement,k=jl(y,s);N.setAttribute("x",`${k.x}`),N.setAttribute("y",`${k.y}`),c.appendChild(N)});const f=(r=s.querySelector(".lines"))==null?void 0:r.cloneNode(!0);f&&c.appendChild(f);const p=(n=s.querySelector(".topiclinks"))==null?void 0:n.cloneNode(!0);p&&c.appendChild(p);const g=(i=s.querySelector(".summary"))==null?void 0:i.cloneNode(!0);g&&c.appendChild(g);const b=Array.from(s.querySelectorAll("me-tpc")).map(async w=>{const N=jl(w,s),y=w.nodeObj.dangerouslySetInnerHTML,k=!!(w.text&&w.text.innerHTML&&w.text.innerHTML!==w.text.textContent),I=w.nodeObj.image;if(y||k){const D=X0(t,w,!e,N);c.appendChild(D)}else c.appendChild(X0(t,w,!1,N));if(I)try{const D=await P4(t,w);D&&c.appendChild(D)}catch{}});await Promise.all(b),s.querySelectorAll(".tags > span").forEach(w=>{c.appendChild(X0(t,w))}),s.querySelectorAll(".icons > span").forEach(w=>{c.appendChild(X0(t,w))}),s.querySelectorAll(".hyper-link").forEach(w=>{c.appendChild(B4(t,w))});const x=Array.from(s.querySelectorAll("img")).map(async(w,N)=>{const y=w.closest("me-tpc"),k=w.closest("foreignObject");return y||k?null:await H4(t,w)});return(await Promise.all(x)).filter(w=>w!==null).forEach(w=>{w&&c.appendChild(w)}),rt(c,{x:J0+"",y:J0+"",overflow:"visible"}),l.appendChild(c),l},V4=(t,e)=>(e&&t.insertAdjacentHTML("afterbegin","<style>"+e+"</style>"),q4+t.outerHTML);function W4(t){return new Promise((e,r)=>{const n=new FileReader;n.onload=i=>{e(i.target.result)},n.onerror=i=>{r(i)},n.readAsDataURL(t)})}const G4=async function(t=!1,e){const r=await U4(this,t),n=V4(r,e);return new Blob([n],{type:"image/svg+xml"})},K4=async function(t=!1,e){const r=await this.exportSvg(t,e),n=await W4(r);return new Promise((i,s)=>{const a=new Image;a.setAttribute("crossOrigin","anonymous");const o=setTimeout(()=>{s(new Error("Image loading timeout"))},1e4);a.onload=()=>{clearTimeout(o);try{const l=document.createElement("canvas");l.width=a.width,l.height=a.height;const c=l.getContext("2d");c.fillStyle="#ffffff",c.fillRect(0,0,l.width,l.height),c.drawImage(a,0,0),l.toBlob(i,"image/png",1)}catch(l){s(l)}},a.onerror=l=>{clearTimeout(o),s(l)},a.src=n})},Y4=Object.freeze(Object.defineProperty({__proto__:null,exportPng:K4,exportSvg:G4},Symbol.toStringTag,{value:"Module"}));function X4(t,e){return async function(...r){const n=this.before[e];n&&!await n.apply(this,r)||t.apply(this,r)}}const Ul=Object.keys(f1),y1={};for(let t=0;t<Ul.length;t++){const e=Ul[t];y1[e]=X4(f1[e],e)}const J4={getObjById:Ni,generateNewObj:Ep,layout:zp,linkDiv:Vp,editTopic:jp,createWrapper:Bp,createParent:Pp,createChildren:Hp,createTopic:qp,findEle:t1,changeTheme:ym,...u4,...y1,...A4,...$4,...Y4,init(t){if(t=JSON.parse(JSON.stringify(t)),!t||!t.nodeData)return new Error("MindElixir: `data` is required");t.direction!==void 0&&(this.direction=t.direction),this.changeTheme(t.theme||this.theme,!1),this.nodeData=t.nodeData,un(this.nodeData),this.arrows=t.arrows||[],this.summaries=t.summaries||[],this.tidyArrow(),this.toolBar&&dm(this),this.keypress&&Op(this,this.keypress),this.editable&&bm(this),this.contextMenu&&this.disposable.push(Wp(this,this.contextMenu)),this.draggable&&this.disposable.push(Xp(this)),this.allowUndo&&this.disposable.push(Zp(this)),this.layout(),this.linkDiv(),this.toCenter()},destroy(){var t;this.disposable.forEach(e=>e()),this.el&&(this.el.innerHTML=""),this.el=void 0,this.nodeData=void 0,this.arrows=void 0,this.summaries=void 0,this.currentArrow=void 0,this.currentNodes=void 0,this.currentSummary=void 0,this.waitCopy=void 0,this.theme=void 0,this.direction=void 0,this.bus=void 0,this.container=void 0,this.map=void 0,this.lines=void 0,this.linkController=void 0,this.linkSvgGroup=void 0,this.P2=void 0,this.P3=void 0,this.line1=void 0,this.line2=void 0,this.nodes=void 0,(t=this.selection)==null||t.destroy(),this.selection=void 0}};function Z4({pT:t,pL:e,pW:r,pH:n,cT:i,cL:s,cW:a,cH:o,direction:l,containerHeight:c}){let u=e+r/2;const f=t+n/2;let p;l===ir.LHS?p=s+a:p=s;const g=i+o/2,b=(1-Math.abs(g-f)/c)*.25*(r/2);return l===ir.LHS?u=u-r/10-b:u=u+r/10+b,`M ${u} ${f} Q ${u} ${g} ${p} ${g}`}function Q4({pT:t,pL:e,pW:r,pH:n,cT:i,cL:s,cW:a,cH:o,direction:l,isFirst:c}){let u=e+r/2;const f=t+n/2;let p;l===ir.LHS?p=s+a-31:p=s+31;const g=i+o/2,b=this.container.offsetHeight||1e3,x=(1-Math.abs(g-f)/b)*.25*(r/2);return l===ir.LHS?u=u-r/10-x:u=u+r/10+x,`M ${u} ${f} Q ${u} ${g} ${p} ${g}`}const e2="5.1.1";function t2(t){return{x:0,y:0,moved:!1,mousedown:!1,onMove(e,r){this.mousedown&&(this.moved=!0,t.move(e,r))},clear(){this.mousedown=!1}}}const t0=document;function kt({el:t,direction:e,locale:r,draggable:n,editable:i,contextMenu:s,toolBar:a,keypress:o,mouseSelectionButton:l,selectionContainer:c,before:u,newTopicName:f,allowUndo:p,generateMainBranch:g,generateSubBranch:b,overflowHidden:x,theme:w,alignment:N,scaleSensitivity:y,scaleMax:k,scaleMin:I,handleWheel:D,markdown:O,imageProxy:z,enableNodeBorder:W}){let H=null;const oe=Object.prototype.toString.call(t);if(oe==="[object HTMLDivElement]"?H=t:oe==="[object String]"&&(H=document.querySelector(t)),!H)throw new Error("MindElixir: el is not a valid element");H.style.position="relative",H.innerHTML="",this.el=H,this.disposable=[],this.before=u||{},this.locale=r||"en",this.newTopicName=f||"New Node",this.contextMenu=s??!0,this.toolBar=a??!0,this.keypress=o??!0,this.mouseSelectionButton=l??0,this.direction=e??1,this.draggable=n??!0,this.editable=i??!0,this.allowUndo=p??!0,this.scaleSensitivity=y??.1,this.scaleMax=k??1.4,this.scaleMin=I??.2,this.generateMainBranch=g||Z4,this.generateSubBranch=b||Q4,this.overflowHidden=x??!1,this.alignment=N??"root",this.handleWheel=D??!0,this.markdown=O||void 0,this.imageProxy=z||void 0,this.enableNodeBorder=W??!1,this.currentNodes=[],this.currentArrow=null,this.scaleVal=1,this.tempDirection=null,this.dragMoveHelper=t2(this),this.bus=Lp(),this.container=t0.createElement("div"),this.selectionContainer=c||this.container,this.container.className="map-container";const me=window.matchMedia("(prefers-color-scheme: dark)");this.theme=w||(me.matches?ro:to);const ye=t0.createElement("div");ye.className="map-canvas",this.map=ye,this.container.setAttribute("tabindex","0"),this.container.appendChild(this.map),this.el.appendChild(this.container),this.nodes=t0.createElement("me-nodes"),this.lines=a0("lines"),this.summarySvg=a0("summary"),this.linkController=a0("linkcontroller"),this.P2=t0.createElement("div"),this.P3=t0.createElement("div"),this.P2.className=this.P3.className="circle",this.P2.style.display=this.P3.style.display="none",this.line1=Ml(),this.line2=Ml(),this.linkController.appendChild(this.line1),this.linkController.appendChild(this.line2),this.linkSvgGroup=a0("topiclinks"),this.map.appendChild(this.nodes),this.overflowHidden?this.container.style.overflow="hidden":this.disposable.push(_p(this))}kt.prototype=J4;Object.defineProperty(kt.prototype,"currentNode",{get(){return this.currentNodes[this.currentNodes.length-1]},enumerable:!0});kt.LEFT=0;kt.RIGHT=1;kt.SIDE=2;kt.THEME=to;kt.DARK_THEME=ro;kt.version=e2;kt.E=t1;kt.new=t=>({nodeData:{id:Tn(),topic:t||"new topic",children:[]}});function w1(t,e){return function(){return t.apply(e,arguments)}}const{toString:r2}=Object.prototype,{getPrototypeOf:ho}=Object,{iterator:is,toStringTag:x1}=Symbol,ss=(t=>e=>{const r=r2.call(e);return t[r]||(t[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),pr=t=>(t=t.toLowerCase(),e=>ss(e)===t),as=t=>e=>typeof e===t,{isArray:Kn}=Array,S0=as("undefined");function R0(t){return t!==null&&!S0(t)&&t.constructor!==null&&!S0(t.constructor)&&jt(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const k1=pr("ArrayBuffer");function n2(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&k1(t.buffer),e}const i2=as("string"),jt=as("function"),S1=as("number"),D0=t=>t!==null&&typeof t=="object",s2=t=>t===!0||t===!1,pi=t=>{if(ss(t)!=="object")return!1;const e=ho(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(x1 in t)&&!(is in t)},a2=t=>{if(!D0(t)||R0(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},o2=pr("Date"),l2=pr("File"),c2=pr("Blob"),u2=pr("FileList"),d2=t=>D0(t)&&jt(t.pipe),h2=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||jt(t.append)&&((e=ss(t))==="formdata"||e==="object"&&jt(t.toString)&&t.toString()==="[object FormData]"))},f2=pr("URLSearchParams"),[p2,m2,g2,v2]=["ReadableStream","Request","Response","Headers"].map(pr),b2=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function O0(t,e,{allOwnKeys:r=!1}={}){if(t===null||typeof t>"u")return;let n,i;if(typeof t!="object"&&(t=[t]),Kn(t))for(n=0,i=t.length;n<i;n++)e.call(null,t[n],n,t);else{if(R0(t))return;const s=r?Object.getOwnPropertyNames(t):Object.keys(t),a=s.length;let o;for(n=0;n<a;n++)o=s[n],e.call(null,t[o],o,t)}}function T1(t,e){if(R0(t))return null;e=e.toLowerCase();const r=Object.keys(t);let n=r.length,i;for(;n-- >0;)if(i=r[n],e===i.toLowerCase())return i;return null}const yn=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),A1=t=>!S0(t)&&t!==yn;function ga(){const{caseless:t}=A1(this)&&this||{},e={},r=(n,i)=>{const s=t&&T1(e,i)||i;pi(e[s])&&pi(n)?e[s]=ga(e[s],n):pi(n)?e[s]=ga({},n):Kn(n)?e[s]=n.slice():e[s]=n};for(let n=0,i=arguments.length;n<i;n++)arguments[n]&&O0(arguments[n],r);return e}const y2=(t,e,r,{allOwnKeys:n}={})=>(O0(e,(i,s)=>{r&&jt(i)?t[s]=w1(i,r):t[s]=i},{allOwnKeys:n}),t),w2=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),x2=(t,e,r,n)=>{t.prototype=Object.create(e.prototype,n),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),r&&Object.assign(t.prototype,r)},k2=(t,e,r,n)=>{let i,s,a;const o={};if(e=e||{},t==null)return e;do{for(i=Object.getOwnPropertyNames(t),s=i.length;s-- >0;)a=i[s],(!n||n(a,t,e))&&!o[a]&&(e[a]=t[a],o[a]=!0);t=r!==!1&&ho(t)}while(t&&(!r||r(t,e))&&t!==Object.prototype);return e},S2=(t,e,r)=>{t=String(t),(r===void 0||r>t.length)&&(r=t.length),r-=e.length;const n=t.indexOf(e,r);return n!==-1&&n===r},T2=t=>{if(!t)return null;if(Kn(t))return t;let e=t.length;if(!S1(e))return null;const r=new Array(e);for(;e-- >0;)r[e]=t[e];return r},A2=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&ho(Uint8Array)),E2=(t,e)=>{const n=(t&&t[is]).call(t);let i;for(;(i=n.next())&&!i.done;){const s=i.value;e.call(t,s[0],s[1])}},C2=(t,e)=>{let r;const n=[];for(;(r=t.exec(e))!==null;)n.push(r);return n},M2=pr("HTMLFormElement"),N2=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,i){return n.toUpperCase()+i}),Vl=(({hasOwnProperty:t})=>(e,r)=>t.call(e,r))(Object.prototype),I2=pr("RegExp"),E1=(t,e)=>{const r=Object.getOwnPropertyDescriptors(t),n={};O0(r,(i,s)=>{let a;(a=e(i,s,t))!==!1&&(n[s]=a||i)}),Object.defineProperties(t,n)},R2=t=>{E1(t,(e,r)=>{if(jt(t)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=t[r];if(jt(n)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},D2=(t,e)=>{const r={},n=i=>{i.forEach(s=>{r[s]=!0})};return Kn(t)?n(t):n(String(t).split(e)),r},O2=()=>{},_2=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e;function L2(t){return!!(t&&jt(t.append)&&t[x1]==="FormData"&&t[is])}const z2=t=>{const e=new Array(10),r=(n,i)=>{if(D0(n)){if(e.indexOf(n)>=0)return;if(R0(n))return n;if(!("toJSON"in n)){e[i]=n;const s=Kn(n)?[]:{};return O0(n,(a,o)=>{const l=r(a,i+1);!S0(l)&&(s[o]=l)}),e[i]=void 0,s}}return n};return r(t,0)},$2=pr("AsyncFunction"),F2=t=>t&&(D0(t)||jt(t))&&jt(t.then)&&jt(t.catch),C1=((t,e)=>t?setImmediate:e?((r,n)=>(yn.addEventListener("message",({source:i,data:s})=>{i===yn&&s===r&&n.length&&n.shift()()},!1),i=>{n.push(i),yn.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",jt(yn.postMessage)),B2=typeof queueMicrotask<"u"?queueMicrotask.bind(yn):typeof process<"u"&&process.nextTick||C1,P2=t=>t!=null&&jt(t[is]),P={isArray:Kn,isArrayBuffer:k1,isBuffer:R0,isFormData:h2,isArrayBufferView:n2,isString:i2,isNumber:S1,isBoolean:s2,isObject:D0,isPlainObject:pi,isEmptyObject:a2,isReadableStream:p2,isRequest:m2,isResponse:g2,isHeaders:v2,isUndefined:S0,isDate:o2,isFile:l2,isBlob:c2,isRegExp:I2,isFunction:jt,isStream:d2,isURLSearchParams:f2,isTypedArray:A2,isFileList:u2,forEach:O0,merge:ga,extend:y2,trim:b2,stripBOM:w2,inherits:x2,toFlatObject:k2,kindOf:ss,kindOfTest:pr,endsWith:S2,toArray:T2,forEachEntry:E2,matchAll:C2,isHTMLForm:M2,hasOwnProperty:Vl,hasOwnProp:Vl,reduceDescriptors:E1,freezeMethods:R2,toObjectSet:D2,toCamelCase:N2,noop:O2,toFiniteNumber:_2,findKey:T1,global:yn,isContextDefined:A1,isSpecCompliantForm:L2,toJSONObject:z2,isAsyncFn:$2,isThenable:F2,setImmediate:C1,asap:B2,isIterable:P2};function Me(t,e,r,n,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),r&&(this.config=r),n&&(this.request=n),i&&(this.response=i,this.status=i.status?i.status:null)}P.inherits(Me,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:P.toJSONObject(this.config),code:this.code,status:this.status}}});const M1=Me.prototype,N1={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{N1[t]={value:t}});Object.defineProperties(Me,N1);Object.defineProperty(M1,"isAxiosError",{value:!0});Me.from=(t,e,r,n,i,s)=>{const a=Object.create(M1);return P.toFlatObject(t,a,function(l){return l!==Error.prototype},o=>o!=="isAxiosError"),Me.call(a,t.message,e,r,n,i),a.cause=t,a.name=t.name,s&&Object.assign(a,s),a};const H2=null;function va(t){return P.isPlainObject(t)||P.isArray(t)}function I1(t){return P.endsWith(t,"[]")?t.slice(0,-2):t}function Wl(t,e,r){return t?t.concat(e).map(function(i,s){return i=I1(i),!r&&s?"["+i+"]":i}).join(r?".":""):e}function q2(t){return P.isArray(t)&&!t.some(va)}const j2=P.toFlatObject(P,{},null,function(e){return/^is[A-Z]/.test(e)});function os(t,e,r){if(!P.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,r=P.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(x,w){return!P.isUndefined(w[x])});const n=r.metaTokens,i=r.visitor||u,s=r.dots,a=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&P.isSpecCompliantForm(e);if(!P.isFunction(i))throw new TypeError("visitor must be a function");function c(b){if(b===null)return"";if(P.isDate(b))return b.toISOString();if(P.isBoolean(b))return b.toString();if(!l&&P.isBlob(b))throw new Me("Blob is not supported. Use a Buffer instead.");return P.isArrayBuffer(b)||P.isTypedArray(b)?l&&typeof Blob=="function"?new Blob([b]):Buffer.from(b):b}function u(b,x,w){let N=b;if(b&&!w&&typeof b=="object"){if(P.endsWith(x,"{}"))x=n?x:x.slice(0,-2),b=JSON.stringify(b);else if(P.isArray(b)&&q2(b)||(P.isFileList(b)||P.endsWith(x,"[]"))&&(N=P.toArray(b)))return x=I1(x),N.forEach(function(k,I){!(P.isUndefined(k)||k===null)&&e.append(a===!0?Wl([x],I,s):a===null?x:x+"[]",c(k))}),!1}return va(b)?!0:(e.append(Wl(w,x,s),c(b)),!1)}const f=[],p=Object.assign(j2,{defaultVisitor:u,convertValue:c,isVisitable:va});function g(b,x){if(!P.isUndefined(b)){if(f.indexOf(b)!==-1)throw Error("Circular reference detected in "+x.join("."));f.push(b),P.forEach(b,function(N,y){(!(P.isUndefined(N)||N===null)&&i.call(e,N,P.isString(y)?y.trim():y,x,p))===!0&&g(N,x?x.concat(y):[y])}),f.pop()}}if(!P.isObject(t))throw new TypeError("data must be an object");return g(t),e}function Gl(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(n){return e[n]})}function fo(t,e){this._pairs=[],t&&os(t,this,e)}const R1=fo.prototype;R1.append=function(e,r){this._pairs.push([e,r])};R1.toString=function(e){const r=e?function(n){return e.call(this,n,Gl)}:Gl;return this._pairs.map(function(i){return r(i[0])+"="+r(i[1])},"").join("&")};function U2(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function D1(t,e,r){if(!e)return t;const n=r&&r.encode||U2;P.isFunction(r)&&(r={serialize:r});const i=r&&r.serialize;let s;if(i?s=i(e,r):s=P.isURLSearchParams(e)?e.toString():new fo(e,r).toString(n),s){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+s}return t}class V2{constructor(){this.handlers=[]}use(e,r,n){return this.handlers.push({fulfilled:e,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){P.forEach(this.handlers,function(n){n!==null&&e(n)})}}const Kl=V2,O1={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},W2=typeof URLSearchParams<"u"?URLSearchParams:fo,G2=typeof FormData<"u"?FormData:null,K2=typeof Blob<"u"?Blob:null,Y2={isBrowser:!0,classes:{URLSearchParams:W2,FormData:G2,Blob:K2},protocols:["http","https","file","blob","url","data"]},po=typeof window<"u"&&typeof document<"u",ba=typeof navigator=="object"&&navigator||void 0,X2=po&&(!ba||["ReactNative","NativeScript","NS"].indexOf(ba.product)<0),J2=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),Z2=po&&window.location.href||"http://localhost",Q2=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:po,hasStandardBrowserEnv:X2,hasStandardBrowserWebWorkerEnv:J2,navigator:ba,origin:Z2},Symbol.toStringTag,{value:"Module"})),Mt={...Q2,...Y2};function e3(t,e){return os(t,new Mt.classes.URLSearchParams,{visitor:function(r,n,i,s){return Mt.isNode&&P.isBuffer(r)?(this.append(n,r.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)},...e})}function t3(t){return P.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function r3(t){const e={},r=Object.keys(t);let n;const i=r.length;let s;for(n=0;n<i;n++)s=r[n],e[s]=t[s];return e}function _1(t){function e(r,n,i,s){let a=r[s++];if(a==="__proto__")return!0;const o=Number.isFinite(+a),l=s>=r.length;return a=!a&&P.isArray(i)?i.length:a,l?(P.hasOwnProp(i,a)?i[a]=[i[a],n]:i[a]=n,!o):((!i[a]||!P.isObject(i[a]))&&(i[a]=[]),e(r,n,i[a],s)&&P.isArray(i[a])&&(i[a]=r3(i[a])),!o)}if(P.isFormData(t)&&P.isFunction(t.entries)){const r={};return P.forEachEntry(t,(n,i)=>{e(t3(n),i,r,0)}),r}return null}function n3(t,e,r){if(P.isString(t))try{return(e||JSON.parse)(t),P.trim(t)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(t)}const mo={transitional:O1,adapter:["xhr","http","fetch"],transformRequest:[function(e,r){const n=r.getContentType()||"",i=n.indexOf("application/json")>-1,s=P.isObject(e);if(s&&P.isHTMLForm(e)&&(e=new FormData(e)),P.isFormData(e))return i?JSON.stringify(_1(e)):e;if(P.isArrayBuffer(e)||P.isBuffer(e)||P.isStream(e)||P.isFile(e)||P.isBlob(e)||P.isReadableStream(e))return e;if(P.isArrayBufferView(e))return e.buffer;if(P.isURLSearchParams(e))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let o;if(s){if(n.indexOf("application/x-www-form-urlencoded")>-1)return e3(e,this.formSerializer).toString();if((o=P.isFileList(e))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return os(o?{"files[]":e}:e,l&&new l,this.formSerializer)}}return s||i?(r.setContentType("application/json",!1),n3(e)):e}],transformResponse:[function(e){const r=this.transitional||mo.transitional,n=r&&r.forcedJSONParsing,i=this.responseType==="json";if(P.isResponse(e)||P.isReadableStream(e))return e;if(e&&P.isString(e)&&(n&&!this.responseType||i)){const a=!(r&&r.silentJSONParsing)&&i;try{return JSON.parse(e)}catch(o){if(a)throw o.name==="SyntaxError"?Me.from(o,Me.ERR_BAD_RESPONSE,this,null,this.response):o}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Mt.classes.FormData,Blob:Mt.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};P.forEach(["delete","get","head","post","put","patch"],t=>{mo.headers[t]={}});const go=mo,i3=P.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),s3=t=>{const e={};let r,n,i;return t&&t.split(`
|
||
`).forEach(function(a){i=a.indexOf(":"),r=a.substring(0,i).trim().toLowerCase(),n=a.substring(i+1).trim(),!(!r||e[r]&&i3[r])&&(r==="set-cookie"?e[r]?e[r].push(n):e[r]=[n]:e[r]=e[r]?e[r]+", "+n:n)}),e},Yl=Symbol("internals");function r0(t){return t&&String(t).trim().toLowerCase()}function mi(t){return t===!1||t==null?t:P.isArray(t)?t.map(mi):String(t)}function a3(t){const e=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(t);)e[n[1]]=n[2];return e}const o3=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function _s(t,e,r,n,i){if(P.isFunction(n))return n.call(this,e,r);if(i&&(e=r),!!P.isString(e)){if(P.isString(n))return e.indexOf(n)!==-1;if(P.isRegExp(n))return n.test(e)}}function l3(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,r,n)=>r.toUpperCase()+n)}function c3(t,e){const r=P.toCamelCase(" "+e);["get","set","has"].forEach(n=>{Object.defineProperty(t,n+r,{value:function(i,s,a){return this[n].call(this,e,i,s,a)},configurable:!0})})}class ls{constructor(e){e&&this.set(e)}set(e,r,n){const i=this;function s(o,l,c){const u=r0(l);if(!u)throw new Error("header name must be a non-empty string");const f=P.findKey(i,u);(!f||i[f]===void 0||c===!0||c===void 0&&i[f]!==!1)&&(i[f||l]=mi(o))}const a=(o,l)=>P.forEach(o,(c,u)=>s(c,u,l));if(P.isPlainObject(e)||e instanceof this.constructor)a(e,r);else if(P.isString(e)&&(e=e.trim())&&!o3(e))a(s3(e),r);else if(P.isObject(e)&&P.isIterable(e)){let o={},l,c;for(const u of e){if(!P.isArray(u))throw TypeError("Object iterator must return a key-value pair");o[c=u[0]]=(l=o[c])?P.isArray(l)?[...l,u[1]]:[l,u[1]]:u[1]}a(o,r)}else e!=null&&s(r,e,n);return this}get(e,r){if(e=r0(e),e){const n=P.findKey(this,e);if(n){const i=this[n];if(!r)return i;if(r===!0)return a3(i);if(P.isFunction(r))return r.call(this,i,n);if(P.isRegExp(r))return r.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,r){if(e=r0(e),e){const n=P.findKey(this,e);return!!(n&&this[n]!==void 0&&(!r||_s(this,this[n],n,r)))}return!1}delete(e,r){const n=this;let i=!1;function s(a){if(a=r0(a),a){const o=P.findKey(n,a);o&&(!r||_s(n,n[o],o,r))&&(delete n[o],i=!0)}}return P.isArray(e)?e.forEach(s):s(e),i}clear(e){const r=Object.keys(this);let n=r.length,i=!1;for(;n--;){const s=r[n];(!e||_s(this,this[s],s,e,!0))&&(delete this[s],i=!0)}return i}normalize(e){const r=this,n={};return P.forEach(this,(i,s)=>{const a=P.findKey(n,s);if(a){r[a]=mi(i),delete r[s];return}const o=e?l3(s):String(s).trim();o!==s&&delete r[s],r[o]=mi(i),n[o]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const r=Object.create(null);return P.forEach(this,(n,i)=>{n!=null&&n!==!1&&(r[i]=e&&P.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,r])=>e+": "+r).join(`
|
||
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...r){const n=new this(e);return r.forEach(i=>n.set(i)),n}static accessor(e){const n=(this[Yl]=this[Yl]={accessors:{}}).accessors,i=this.prototype;function s(a){const o=r0(a);n[o]||(c3(i,a),n[o]=!0)}return P.isArray(e)?e.forEach(s):s(e),this}}ls.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);P.reduceDescriptors(ls.prototype,({value:t},e)=>{let r=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(n){this[r]=n}}});P.freezeMethods(ls);const fr=ls;function Ls(t,e){const r=this||go,n=e||r,i=fr.from(n.headers);let s=n.data;return P.forEach(t,function(o){s=o.call(r,s,i.normalize(),e?e.status:void 0)}),i.normalize(),s}function L1(t){return!!(t&&t.__CANCEL__)}function Yn(t,e,r){Me.call(this,t??"canceled",Me.ERR_CANCELED,e,r),this.name="CanceledError"}P.inherits(Yn,Me,{__CANCEL__:!0});function z1(t,e,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?t(r):e(new Me("Request failed with status code "+r.status,[Me.ERR_BAD_REQUEST,Me.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function u3(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function d3(t,e){t=t||10;const r=new Array(t),n=new Array(t);let i=0,s=0,a;return e=e!==void 0?e:1e3,function(l){const c=Date.now(),u=n[s];a||(a=c),r[i]=l,n[i]=c;let f=s,p=0;for(;f!==i;)p+=r[f++],f=f%t;if(i=(i+1)%t,i===s&&(s=(s+1)%t),c-a<e)return;const g=u&&c-u;return g?Math.round(p*1e3/g):void 0}}function h3(t,e){let r=0,n=1e3/e,i,s;const a=(c,u=Date.now())=>{r=u,i=null,s&&(clearTimeout(s),s=null),t(...c)};return[(...c)=>{const u=Date.now(),f=u-r;f>=n?a(c,u):(i=c,s||(s=setTimeout(()=>{s=null,a(i)},n-f)))},()=>i&&a(i)]}const _i=(t,e,r=3)=>{let n=0;const i=d3(50,250);return h3(s=>{const a=s.loaded,o=s.lengthComputable?s.total:void 0,l=a-n,c=i(l),u=a<=o;n=a;const f={loaded:a,total:o,progress:o?a/o:void 0,bytes:l,rate:c||void 0,estimated:c&&o&&u?(o-a)/c:void 0,event:s,lengthComputable:o!=null,[e?"download":"upload"]:!0};t(f)},r)},Xl=(t,e)=>{const r=t!=null;return[n=>e[0]({lengthComputable:r,total:t,loaded:n}),e[1]]},Jl=t=>(...e)=>P.asap(()=>t(...e)),f3=Mt.hasStandardBrowserEnv?((t,e)=>r=>(r=new URL(r,Mt.origin),t.protocol===r.protocol&&t.host===r.host&&(e||t.port===r.port)))(new URL(Mt.origin),Mt.navigator&&/(msie|trident)/i.test(Mt.navigator.userAgent)):()=>!0,p3=Mt.hasStandardBrowserEnv?{write(t,e,r,n,i,s){const a=[t+"="+encodeURIComponent(e)];P.isNumber(r)&&a.push("expires="+new Date(r).toGMTString()),P.isString(n)&&a.push("path="+n),P.isString(i)&&a.push("domain="+i),s===!0&&a.push("secure"),document.cookie=a.join("; ")},read(t){const e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(t){this.write(t,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function m3(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function g3(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function $1(t,e,r){let n=!m3(e);return t&&(n||r==!1)?g3(t,e):e}const Zl=t=>t instanceof fr?{...t}:t;function kn(t,e){e=e||{};const r={};function n(c,u,f,p){return P.isPlainObject(c)&&P.isPlainObject(u)?P.merge.call({caseless:p},c,u):P.isPlainObject(u)?P.merge({},u):P.isArray(u)?u.slice():u}function i(c,u,f,p){if(P.isUndefined(u)){if(!P.isUndefined(c))return n(void 0,c,f,p)}else return n(c,u,f,p)}function s(c,u){if(!P.isUndefined(u))return n(void 0,u)}function a(c,u){if(P.isUndefined(u)){if(!P.isUndefined(c))return n(void 0,c)}else return n(void 0,u)}function o(c,u,f){if(f in e)return n(c,u);if(f in t)return n(void 0,c)}const l={url:s,method:s,data:s,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:o,headers:(c,u,f)=>i(Zl(c),Zl(u),f,!0)};return P.forEach(Object.keys({...t,...e}),function(u){const f=l[u]||i,p=f(t[u],e[u],u);P.isUndefined(p)&&f!==o||(r[u]=p)}),r}const F1=t=>{const e=kn({},t);let{data:r,withXSRFToken:n,xsrfHeaderName:i,xsrfCookieName:s,headers:a,auth:o}=e;e.headers=a=fr.from(a),e.url=D1($1(e.baseURL,e.url,e.allowAbsoluteUrls),t.params,t.paramsSerializer),o&&a.set("Authorization","Basic "+btoa((o.username||"")+":"+(o.password?unescape(encodeURIComponent(o.password)):"")));let l;if(P.isFormData(r)){if(Mt.hasStandardBrowserEnv||Mt.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((l=a.getContentType())!==!1){const[c,...u]=l?l.split(";").map(f=>f.trim()).filter(Boolean):[];a.setContentType([c||"multipart/form-data",...u].join("; "))}}if(Mt.hasStandardBrowserEnv&&(n&&P.isFunction(n)&&(n=n(e)),n||n!==!1&&f3(e.url))){const c=i&&s&&p3.read(s);c&&a.set(i,c)}return e},v3=typeof XMLHttpRequest<"u",b3=v3&&function(t){return new Promise(function(r,n){const i=F1(t);let s=i.data;const a=fr.from(i.headers).normalize();let{responseType:o,onUploadProgress:l,onDownloadProgress:c}=i,u,f,p,g,b;function x(){g&&g(),b&&b(),i.cancelToken&&i.cancelToken.unsubscribe(u),i.signal&&i.signal.removeEventListener("abort",u)}let w=new XMLHttpRequest;w.open(i.method.toUpperCase(),i.url,!0),w.timeout=i.timeout;function N(){if(!w)return;const k=fr.from("getAllResponseHeaders"in w&&w.getAllResponseHeaders()),D={data:!o||o==="text"||o==="json"?w.responseText:w.response,status:w.status,statusText:w.statusText,headers:k,config:t,request:w};z1(function(z){r(z),x()},function(z){n(z),x()},D),w=null}"onloadend"in w?w.onloadend=N:w.onreadystatechange=function(){!w||w.readyState!==4||w.status===0&&!(w.responseURL&&w.responseURL.indexOf("file:")===0)||setTimeout(N)},w.onabort=function(){w&&(n(new Me("Request aborted",Me.ECONNABORTED,t,w)),w=null)},w.onerror=function(){n(new Me("Network Error",Me.ERR_NETWORK,t,w)),w=null},w.ontimeout=function(){let I=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const D=i.transitional||O1;i.timeoutErrorMessage&&(I=i.timeoutErrorMessage),n(new Me(I,D.clarifyTimeoutError?Me.ETIMEDOUT:Me.ECONNABORTED,t,w)),w=null},s===void 0&&a.setContentType(null),"setRequestHeader"in w&&P.forEach(a.toJSON(),function(I,D){w.setRequestHeader(D,I)}),P.isUndefined(i.withCredentials)||(w.withCredentials=!!i.withCredentials),o&&o!=="json"&&(w.responseType=i.responseType),c&&([p,b]=_i(c,!0),w.addEventListener("progress",p)),l&&w.upload&&([f,g]=_i(l),w.upload.addEventListener("progress",f),w.upload.addEventListener("loadend",g)),(i.cancelToken||i.signal)&&(u=k=>{w&&(n(!k||k.type?new Yn(null,t,w):k),w.abort(),w=null)},i.cancelToken&&i.cancelToken.subscribe(u),i.signal&&(i.signal.aborted?u():i.signal.addEventListener("abort",u)));const y=u3(i.url);if(y&&Mt.protocols.indexOf(y)===-1){n(new Me("Unsupported protocol "+y+":",Me.ERR_BAD_REQUEST,t));return}w.send(s||null)})},y3=(t,e)=>{const{length:r}=t=t?t.filter(Boolean):[];if(e||r){let n=new AbortController,i;const s=function(c){if(!i){i=!0,o();const u=c instanceof Error?c:this.reason;n.abort(u instanceof Me?u:new Yn(u instanceof Error?u.message:u))}};let a=e&&setTimeout(()=>{a=null,s(new Me(`timeout ${e} of ms exceeded`,Me.ETIMEDOUT))},e);const o=()=>{t&&(a&&clearTimeout(a),a=null,t.forEach(c=>{c.unsubscribe?c.unsubscribe(s):c.removeEventListener("abort",s)}),t=null)};t.forEach(c=>c.addEventListener("abort",s));const{signal:l}=n;return l.unsubscribe=()=>P.asap(o),l}},w3=y3,x3=function*(t,e){let r=t.byteLength;if(!e||r<e){yield t;return}let n=0,i;for(;n<r;)i=n+e,yield t.slice(n,i),n=i},k3=async function*(t,e){for await(const r of S3(t))yield*x3(r,e)},S3=async function*(t){if(t[Symbol.asyncIterator]){yield*t;return}const e=t.getReader();try{for(;;){const{done:r,value:n}=await e.read();if(r)break;yield n}}finally{await e.cancel()}},Ql=(t,e,r,n)=>{const i=k3(t,e);let s=0,a,o=l=>{a||(a=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:c,value:u}=await i.next();if(c){o(),l.close();return}let f=u.byteLength;if(r){let p=s+=f;r(p)}l.enqueue(new Uint8Array(u))}catch(c){throw o(c),c}},cancel(l){return o(l),i.return()}},{highWaterMark:2})},cs=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",B1=cs&&typeof ReadableStream=="function",T3=cs&&(typeof TextEncoder=="function"?(t=>e=>t.encode(e))(new TextEncoder):async t=>new Uint8Array(await new Response(t).arrayBuffer())),P1=(t,...e)=>{try{return!!t(...e)}catch{return!1}},A3=B1&&P1(()=>{let t=!1;const e=new Request(Mt.origin,{body:new ReadableStream,method:"POST",get duplex(){return t=!0,"half"}}).headers.has("Content-Type");return t&&!e}),ec=64*1024,ya=B1&&P1(()=>P.isReadableStream(new Response("").body)),Li={stream:ya&&(t=>t.body)};cs&&(t=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!Li[e]&&(Li[e]=P.isFunction(t[e])?r=>r[e]():(r,n)=>{throw new Me(`Response type '${e}' is not supported`,Me.ERR_NOT_SUPPORT,n)})})})(new Response);const E3=async t=>{if(t==null)return 0;if(P.isBlob(t))return t.size;if(P.isSpecCompliantForm(t))return(await new Request(Mt.origin,{method:"POST",body:t}).arrayBuffer()).byteLength;if(P.isArrayBufferView(t)||P.isArrayBuffer(t))return t.byteLength;if(P.isURLSearchParams(t)&&(t=t+""),P.isString(t))return(await T3(t)).byteLength},C3=async(t,e)=>{const r=P.toFiniteNumber(t.getContentLength());return r??E3(e)},M3=cs&&(async t=>{let{url:e,method:r,data:n,signal:i,cancelToken:s,timeout:a,onDownloadProgress:o,onUploadProgress:l,responseType:c,headers:u,withCredentials:f="same-origin",fetchOptions:p}=F1(t);c=c?(c+"").toLowerCase():"text";let g=w3([i,s&&s.toAbortSignal()],a),b;const x=g&&g.unsubscribe&&(()=>{g.unsubscribe()});let w;try{if(l&&A3&&r!=="get"&&r!=="head"&&(w=await C3(u,n))!==0){let D=new Request(e,{method:"POST",body:n,duplex:"half"}),O;if(P.isFormData(n)&&(O=D.headers.get("content-type"))&&u.setContentType(O),D.body){const[z,W]=Xl(w,_i(Jl(l)));n=Ql(D.body,ec,z,W)}}P.isString(f)||(f=f?"include":"omit");const N="credentials"in Request.prototype;b=new Request(e,{...p,signal:g,method:r.toUpperCase(),headers:u.normalize().toJSON(),body:n,duplex:"half",credentials:N?f:void 0});let y=await fetch(b,p);const k=ya&&(c==="stream"||c==="response");if(ya&&(o||k&&x)){const D={};["status","statusText","headers"].forEach(H=>{D[H]=y[H]});const O=P.toFiniteNumber(y.headers.get("content-length")),[z,W]=o&&Xl(O,_i(Jl(o),!0))||[];y=new Response(Ql(y.body,ec,z,()=>{W&&W(),x&&x()}),D)}c=c||"text";let I=await Li[P.findKey(Li,c)||"text"](y,t);return!k&&x&&x(),await new Promise((D,O)=>{z1(D,O,{data:I,headers:fr.from(y.headers),status:y.status,statusText:y.statusText,config:t,request:b})})}catch(N){throw x&&x(),N&&N.name==="TypeError"&&/Load failed|fetch/i.test(N.message)?Object.assign(new Me("Network Error",Me.ERR_NETWORK,t,b),{cause:N.cause||N}):Me.from(N,N&&N.code,t,b)}}),wa={http:H2,xhr:b3,fetch:M3};P.forEach(wa,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const tc=t=>`- ${t}`,N3=t=>P.isFunction(t)||t===null||t===!1,H1={getAdapter:t=>{t=P.isArray(t)?t:[t];const{length:e}=t;let r,n;const i={};for(let s=0;s<e;s++){r=t[s];let a;if(n=r,!N3(r)&&(n=wa[(a=String(r)).toLowerCase()],n===void 0))throw new Me(`Unknown adapter '${a}'`);if(n)break;i[a||"#"+s]=n}if(!n){const s=Object.entries(i).map(([o,l])=>`adapter ${o} `+(l===!1?"is not supported by the environment":"is not available in the build"));let a=e?s.length>1?`since :
|
||
`+s.map(tc).join(`
|
||
`):" "+tc(s[0]):"as no adapter specified";throw new Me("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return n},adapters:wa};function zs(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new Yn(null,t)}function rc(t){return zs(t),t.headers=fr.from(t.headers),t.data=Ls.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),H1.getAdapter(t.adapter||go.adapter)(t).then(function(n){return zs(t),n.data=Ls.call(t,t.transformResponse,n),n.headers=fr.from(n.headers),n},function(n){return L1(n)||(zs(t),n&&n.response&&(n.response.data=Ls.call(t,t.transformResponse,n.response),n.response.headers=fr.from(n.response.headers))),Promise.reject(n)})}const q1="1.11.0",us={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{us[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}});const nc={};us.transitional=function(e,r,n){function i(s,a){return"[Axios v"+q1+"] Transitional option '"+s+"'"+a+(n?". "+n:"")}return(s,a,o)=>{if(e===!1)throw new Me(i(a," has been removed"+(r?" in "+r:"")),Me.ERR_DEPRECATED);return r&&!nc[a]&&(nc[a]=!0,console.warn(i(a," has been deprecated since v"+r+" and will be removed in the near future"))),e?e(s,a,o):!0}};us.spelling=function(e){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${e}`),!0)};function I3(t,e,r){if(typeof t!="object")throw new Me("options must be an object",Me.ERR_BAD_OPTION_VALUE);const n=Object.keys(t);let i=n.length;for(;i-- >0;){const s=n[i],a=e[s];if(a){const o=t[s],l=o===void 0||a(o,s,t);if(l!==!0)throw new Me("option "+s+" must be "+l,Me.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new Me("Unknown option "+s,Me.ERR_BAD_OPTION)}}const gi={assertOptions:I3,validators:us},gr=gi.validators;class zi{constructor(e){this.defaults=e||{},this.interceptors={request:new Kl,response:new Kl}}async request(e,r){try{return await this._request(e,r)}catch(n){if(n instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const s=i.stack?i.stack.replace(/^.+\n/,""):"";try{n.stack?s&&!String(n.stack).endsWith(s.replace(/^.+\n.+\n/,""))&&(n.stack+=`
|
||
`+s):n.stack=s}catch{}}throw n}}_request(e,r){typeof e=="string"?(r=r||{},r.url=e):r=e||{},r=kn(this.defaults,r);const{transitional:n,paramsSerializer:i,headers:s}=r;n!==void 0&&gi.assertOptions(n,{silentJSONParsing:gr.transitional(gr.boolean),forcedJSONParsing:gr.transitional(gr.boolean),clarifyTimeoutError:gr.transitional(gr.boolean)},!1),i!=null&&(P.isFunction(i)?r.paramsSerializer={serialize:i}:gi.assertOptions(i,{encode:gr.function,serialize:gr.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),gi.assertOptions(r,{baseUrl:gr.spelling("baseURL"),withXsrfToken:gr.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let a=s&&P.merge(s.common,s[r.method]);s&&P.forEach(["delete","get","head","post","put","patch","common"],b=>{delete s[b]}),r.headers=fr.concat(a,s);const o=[];let l=!0;this.interceptors.request.forEach(function(x){typeof x.runWhen=="function"&&x.runWhen(r)===!1||(l=l&&x.synchronous,o.unshift(x.fulfilled,x.rejected))});const c=[];this.interceptors.response.forEach(function(x){c.push(x.fulfilled,x.rejected)});let u,f=0,p;if(!l){const b=[rc.bind(this),void 0];for(b.unshift(...o),b.push(...c),p=b.length,u=Promise.resolve(r);f<p;)u=u.then(b[f++],b[f++]);return u}p=o.length;let g=r;for(f=0;f<p;){const b=o[f++],x=o[f++];try{g=b(g)}catch(w){x.call(this,w);break}}try{u=rc.call(this,g)}catch(b){return Promise.reject(b)}for(f=0,p=c.length;f<p;)u=u.then(c[f++],c[f++]);return u}getUri(e){e=kn(this.defaults,e);const r=$1(e.baseURL,e.url,e.allowAbsoluteUrls);return D1(r,e.params,e.paramsSerializer)}}P.forEach(["delete","get","head","options"],function(e){zi.prototype[e]=function(r,n){return this.request(kn(n||{},{method:e,url:r,data:(n||{}).data}))}});P.forEach(["post","put","patch"],function(e){function r(n){return function(s,a,o){return this.request(kn(o||{},{method:e,headers:n?{"Content-Type":"multipart/form-data"}:{},url:s,data:a}))}}zi.prototype[e]=r(),zi.prototype[e+"Form"]=r(!0)});const vi=zi;class vo{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(s){r=s});const n=this;this.promise.then(i=>{if(!n._listeners)return;let s=n._listeners.length;for(;s-- >0;)n._listeners[s](i);n._listeners=null}),this.promise.then=i=>{let s;const a=new Promise(o=>{n.subscribe(o),s=o}).then(i);return a.cancel=function(){n.unsubscribe(s)},a},e(function(s,a,o){n.reason||(n.reason=new Yn(s,a,o),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const r=this._listeners.indexOf(e);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const e=new AbortController,r=n=>{e.abort(n)};return this.subscribe(r),e.signal.unsubscribe=()=>this.unsubscribe(r),e.signal}static source(){let e;return{token:new vo(function(i){e=i}),cancel:e}}}const R3=vo;function D3(t){return function(r){return t.apply(null,r)}}function O3(t){return P.isObject(t)&&t.isAxiosError===!0}const xa={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(xa).forEach(([t,e])=>{xa[e]=t});const _3=xa;function j1(t){const e=new vi(t),r=w1(vi.prototype.request,e);return P.extend(r,vi.prototype,e,{allOwnKeys:!0}),P.extend(r,e,null,{allOwnKeys:!0}),r.create=function(i){return j1(kn(t,i))},r}const pt=j1(go);pt.Axios=vi;pt.CanceledError=Yn;pt.CancelToken=R3;pt.isCancel=L1;pt.VERSION=q1;pt.toFormData=os;pt.AxiosError=Me;pt.Cancel=pt.CanceledError;pt.all=function(e){return Promise.all(e)};pt.spread=D3;pt.isAxiosError=O3;pt.mergeConfig=kn;pt.AxiosHeaders=fr;pt.formToJSON=t=>_1(P.isHTMLForm(t)?new FormData(t):t);pt.getAdapter=H1.getAdapter;pt.HttpStatusCode=_3;pt.default=pt;const L3=pt,z3="http://127.0.0.1:8000/api",In=L3.create({baseURL:z3,timeout:1e4,headers:{"Content-Type":"application/json"}}),ut={createMindmap:(t="思维导图",e=null)=>In.post("/mindMaps",{title:t,data:e}),getMindmap:t=>In.get(`/mindMaps/${t}`),getAllMindmaps:()=>In.get("/mindmaps"),addNodes:(t,e)=>In.post("/mindMaps/addNodes",{mindMapId:t,nodes:e}),updateNode:(t,e)=>In.patch("/mindMaps/updateNode",{id:t,...e}),deleteNodes:t=>In.delete("/mindMaps/deleteNodes",{data:{nodeIds:t}})};function bo(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var An=bo();function U1(t){An=t}var g0={exec:()=>null};function We(t,e=""){let r=typeof t=="string"?t:t.source,n={replace:(i,s)=>{let a=typeof s=="string"?s:s.source;return a=a.replace(Lt.caret,"$1"),r=r.replace(i,a),n},getRegex:()=>new RegExp(r,e)};return n}var Lt={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:t=>new RegExp(`^( {0,3}${t})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}#`),htmlBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}<(?:[a-z].*>|!--)`,"i")},$3=/^(?:[ \t]*(?:\n|$))+/,F3=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,B3=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,_0=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,P3=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,yo=/(?:[*+-]|\d{1,9}[.)])/,V1=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,W1=We(V1).replace(/bull/g,yo).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),H3=We(V1).replace(/bull/g,yo).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),wo=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,q3=/^[^\n]+/,xo=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,j3=We(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",xo).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),U3=We(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,yo).getRegex(),ds="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",ko=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,V3=We("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",ko).replace("tag",ds).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),G1=We(wo).replace("hr",_0).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ds).getRegex(),W3=We(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",G1).getRegex(),So={blockquote:W3,code:F3,def:j3,fences:B3,heading:P3,hr:_0,html:V3,lheading:W1,list:U3,newline:$3,paragraph:G1,table:g0,text:q3},ic=We("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",_0).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ds).getRegex(),G3={...So,lheading:H3,table:ic,paragraph:We(wo).replace("hr",_0).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",ic).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ds).getRegex()},K3={...So,html:We(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",ko).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:g0,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:We(wo).replace("hr",_0).replace("heading",` *#{1,6} *[^
|
||
]`).replace("lheading",W1).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},Y3=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,X3=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,K1=/^( {2,}|\\)\n(?!\s*$)/,J3=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,hs=/[\p{P}\p{S}]/u,To=/[\s\p{P}\p{S}]/u,Y1=/[^\s\p{P}\p{S}]/u,Z3=We(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,To).getRegex(),X1=/(?!~)[\p{P}\p{S}]/u,Q3=/(?!~)[\s\p{P}\p{S}]/u,e6=/(?:[^\s\p{P}\p{S}]|~)/u,t6=/\[[^\[\]]*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)|`[^`]*?`|<(?! )[^<>]*?>/g,J1=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,r6=We(J1,"u").replace(/punct/g,hs).getRegex(),n6=We(J1,"u").replace(/punct/g,X1).getRegex(),Z1="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",i6=We(Z1,"gu").replace(/notPunctSpace/g,Y1).replace(/punctSpace/g,To).replace(/punct/g,hs).getRegex(),s6=We(Z1,"gu").replace(/notPunctSpace/g,e6).replace(/punctSpace/g,Q3).replace(/punct/g,X1).getRegex(),a6=We("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Y1).replace(/punctSpace/g,To).replace(/punct/g,hs).getRegex(),o6=We(/\\(punct)/,"gu").replace(/punct/g,hs).getRegex(),l6=We(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),c6=We(ko).replace("(?:-->|$)","-->").getRegex(),u6=We("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",c6).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),$i=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`[^`]*`|[^\[\]\\`])*?/,d6=We(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",$i).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Q1=We(/^!?\[(label)\]\[(ref)\]/).replace("label",$i).replace("ref",xo).getRegex(),ed=We(/^!?\[(ref)\](?:\[\])?/).replace("ref",xo).getRegex(),h6=We("reflink|nolink(?!\\()","g").replace("reflink",Q1).replace("nolink",ed).getRegex(),Ao={_backpedal:g0,anyPunctuation:o6,autolink:l6,blockSkip:t6,br:K1,code:X3,del:g0,emStrongLDelim:r6,emStrongRDelimAst:i6,emStrongRDelimUnd:a6,escape:Y3,link:d6,nolink:ed,punctuation:Z3,reflink:Q1,reflinkSearch:h6,tag:u6,text:J3,url:g0},f6={...Ao,link:We(/^!?\[(label)\]\((.*?)\)/).replace("label",$i).getRegex(),reflink:We(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",$i).getRegex()},ka={...Ao,emStrongRDelimAst:s6,emStrongLDelim:n6,url:We(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/},p6={...ka,br:We(K1).replace("{2,}","*").getRegex(),text:We(ka.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},Z0={normal:So,gfm:G3,pedantic:K3},n0={normal:Ao,gfm:ka,breaks:p6,pedantic:f6},m6={"&":"&","<":"<",">":">",'"':""","'":"'"},sc=t=>m6[t];function vr(t,e){if(e){if(Lt.escapeTest.test(t))return t.replace(Lt.escapeReplace,sc)}else if(Lt.escapeTestNoEncode.test(t))return t.replace(Lt.escapeReplaceNoEncode,sc);return t}function ac(t){try{t=encodeURI(t).replace(Lt.percentDecode,"%")}catch{return null}return t}function oc(t,e){var s;let r=t.replace(Lt.findPipe,(a,o,l)=>{let c=!1,u=o;for(;--u>=0&&l[u]==="\\";)c=!c;return c?"|":" |"}),n=r.split(Lt.splitPipe),i=0;if(n[0].trim()||n.shift(),n.length>0&&!((s=n.at(-1))!=null&&s.trim())&&n.pop(),e)if(n.length>e)n.splice(e);else for(;n.length<e;)n.push("");for(;i<n.length;i++)n[i]=n[i].trim().replace(Lt.slashPipe,"|");return n}function i0(t,e,r){let n=t.length;if(n===0)return"";let i=0;for(;i<n;){let s=t.charAt(n-i-1);if(s===e&&!r)i++;else if(s!==e&&r)i++;else break}return t.slice(0,n-i)}function g6(t,e){if(t.indexOf(e[1])===-1)return-1;let r=0;for(let n=0;n<t.length;n++)if(t[n]==="\\")n++;else if(t[n]===e[0])r++;else if(t[n]===e[1]&&(r--,r<0))return n;return r>0?-2:-1}function lc(t,e,r,n,i){let s=e.href,a=e.title||null,o=t[1].replace(i.other.outputLinkReplace,"$1");n.state.inLink=!0;let l={type:t[0].charAt(0)==="!"?"image":"link",raw:r,href:s,title:a,text:o,tokens:n.inlineTokens(o)};return n.state.inLink=!1,l}function v6(t,e,r){let n=t.match(r.other.indentCodeCompensation);if(n===null)return e;let i=n[1];return e.split(`
|
||
`).map(s=>{let a=s.match(r.other.beginningSpace);if(a===null)return s;let[o]=a;return o.length>=i.length?s.slice(i.length):s}).join(`
|
||
`)}var Fi=class{constructor(t){Je(this,"options");Je(this,"rules");Je(this,"lexer");this.options=t||An}space(t){let e=this.rules.block.newline.exec(t);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(t){let e=this.rules.block.code.exec(t);if(e){let r=e[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?r:i0(r,`
|
||
`)}}}fences(t){let e=this.rules.block.fences.exec(t);if(e){let r=e[0],n=v6(r,e[3]||"",this.rules);return{type:"code",raw:r,lang:e[2]?e[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):e[2],text:n}}}heading(t){let e=this.rules.block.heading.exec(t);if(e){let r=e[2].trim();if(this.rules.other.endingHash.test(r)){let n=i0(r,"#");(this.options.pedantic||!n||this.rules.other.endingSpaceChar.test(n))&&(r=n.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:r,tokens:this.lexer.inline(r)}}}hr(t){let e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:i0(e[0],`
|
||
`)}}blockquote(t){let e=this.rules.block.blockquote.exec(t);if(e){let r=i0(e[0],`
|
||
`).split(`
|
||
`),n="",i="",s=[];for(;r.length>0;){let a=!1,o=[],l;for(l=0;l<r.length;l++)if(this.rules.other.blockquoteStart.test(r[l]))o.push(r[l]),a=!0;else if(!a)o.push(r[l]);else break;r=r.slice(l);let c=o.join(`
|
||
`),u=c.replace(this.rules.other.blockquoteSetextReplace,`
|
||
$1`).replace(this.rules.other.blockquoteSetextReplace2,"");n=n?`${n}
|
||
${c}`:c,i=i?`${i}
|
||
${u}`:u;let f=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(u,s,!0),this.lexer.state.top=f,r.length===0)break;let p=s.at(-1);if((p==null?void 0:p.type)==="code")break;if((p==null?void 0:p.type)==="blockquote"){let g=p,b=g.raw+`
|
||
`+r.join(`
|
||
`),x=this.blockquote(b);s[s.length-1]=x,n=n.substring(0,n.length-g.raw.length)+x.raw,i=i.substring(0,i.length-g.text.length)+x.text;break}else if((p==null?void 0:p.type)==="list"){let g=p,b=g.raw+`
|
||
`+r.join(`
|
||
`),x=this.list(b);s[s.length-1]=x,n=n.substring(0,n.length-p.raw.length)+x.raw,i=i.substring(0,i.length-g.raw.length)+x.raw,r=b.substring(s.at(-1).raw.length).split(`
|
||
`);continue}}return{type:"blockquote",raw:n,tokens:s,text:i}}}list(t){let e=this.rules.block.list.exec(t);if(e){let r=e[1].trim(),n=r.length>1,i={type:"list",raw:"",ordered:n,start:n?+r.slice(0,-1):"",loose:!1,items:[]};r=n?`\\d{1,9}\\${r.slice(-1)}`:`\\${r}`,this.options.pedantic&&(r=n?r:"[*+-]");let s=this.rules.other.listItemRegex(r),a=!1;for(;t;){let l=!1,c="",u="";if(!(e=s.exec(t))||this.rules.block.hr.test(t))break;c=e[0],t=t.substring(c.length);let f=e[2].split(`
|
||
`,1)[0].replace(this.rules.other.listReplaceTabs,N=>" ".repeat(3*N.length)),p=t.split(`
|
||
`,1)[0],g=!f.trim(),b=0;if(this.options.pedantic?(b=2,u=f.trimStart()):g?b=e[1].length+1:(b=e[2].search(this.rules.other.nonSpaceChar),b=b>4?1:b,u=f.slice(b),b+=e[1].length),g&&this.rules.other.blankLine.test(p)&&(c+=p+`
|
||
`,t=t.substring(p.length+1),l=!0),!l){let N=this.rules.other.nextBulletRegex(b),y=this.rules.other.hrRegex(b),k=this.rules.other.fencesBeginRegex(b),I=this.rules.other.headingBeginRegex(b),D=this.rules.other.htmlBeginRegex(b);for(;t;){let O=t.split(`
|
||
`,1)[0],z;if(p=O,this.options.pedantic?(p=p.replace(this.rules.other.listReplaceNesting," "),z=p):z=p.replace(this.rules.other.tabCharGlobal," "),k.test(p)||I.test(p)||D.test(p)||N.test(p)||y.test(p))break;if(z.search(this.rules.other.nonSpaceChar)>=b||!p.trim())u+=`
|
||
`+z.slice(b);else{if(g||f.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||k.test(f)||I.test(f)||y.test(f))break;u+=`
|
||
`+p}!g&&!p.trim()&&(g=!0),c+=O+`
|
||
`,t=t.substring(O.length+1),f=z.slice(b)}}i.loose||(a?i.loose=!0:this.rules.other.doubleBlankLine.test(c)&&(a=!0));let x=null,w;this.options.gfm&&(x=this.rules.other.listIsTask.exec(u),x&&(w=x[0]!=="[ ] ",u=u.replace(this.rules.other.listReplaceTask,""))),i.items.push({type:"list_item",raw:c,task:!!x,checked:w,loose:!1,text:u,tokens:[]}),i.raw+=c}let o=i.items.at(-1);if(o)o.raw=o.raw.trimEnd(),o.text=o.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let l=0;l<i.items.length;l++)if(this.lexer.state.top=!1,i.items[l].tokens=this.lexer.blockTokens(i.items[l].text,[]),!i.loose){let c=i.items[l].tokens.filter(f=>f.type==="space"),u=c.length>0&&c.some(f=>this.rules.other.anyLine.test(f.raw));i.loose=u}if(i.loose)for(let l=0;l<i.items.length;l++)i.items[l].loose=!0;return i}}html(t){let e=this.rules.block.html.exec(t);if(e)return{type:"html",block:!0,raw:e[0],pre:e[1]==="pre"||e[1]==="script"||e[1]==="style",text:e[0]}}def(t){let e=this.rules.block.def.exec(t);if(e){let r=e[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),n=e[2]?e[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",i=e[3]?e[3].substring(1,e[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):e[3];return{type:"def",tag:r,raw:e[0],href:n,title:i}}}table(t){var a;let e=this.rules.block.table.exec(t);if(!e||!this.rules.other.tableDelimiter.test(e[2]))return;let r=oc(e[1]),n=e[2].replace(this.rules.other.tableAlignChars,"").split("|"),i=(a=e[3])!=null&&a.trim()?e[3].replace(this.rules.other.tableRowBlankLine,"").split(`
|
||
`):[],s={type:"table",raw:e[0],header:[],align:[],rows:[]};if(r.length===n.length){for(let o of n)this.rules.other.tableAlignRight.test(o)?s.align.push("right"):this.rules.other.tableAlignCenter.test(o)?s.align.push("center"):this.rules.other.tableAlignLeft.test(o)?s.align.push("left"):s.align.push(null);for(let o=0;o<r.length;o++)s.header.push({text:r[o],tokens:this.lexer.inline(r[o]),header:!0,align:s.align[o]});for(let o of i)s.rows.push(oc(o,s.header.length).map((l,c)=>({text:l,tokens:this.lexer.inline(l),header:!1,align:s.align[c]})));return s}}lheading(t){let e=this.rules.block.lheading.exec(t);if(e)return{type:"heading",raw:e[0],depth:e[2].charAt(0)==="="?1:2,text:e[1],tokens:this.lexer.inline(e[1])}}paragraph(t){let e=this.rules.block.paragraph.exec(t);if(e){let r=e[1].charAt(e[1].length-1)===`
|
||
`?e[1].slice(0,-1):e[1];return{type:"paragraph",raw:e[0],text:r,tokens:this.lexer.inline(r)}}}text(t){let e=this.rules.block.text.exec(t);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(t){let e=this.rules.inline.escape.exec(t);if(e)return{type:"escape",raw:e[0],text:e[1]}}tag(t){let e=this.rules.inline.tag.exec(t);if(e)return!this.lexer.state.inLink&&this.rules.other.startATag.test(e[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:e[0]}}link(t){let e=this.rules.inline.link.exec(t);if(e){let r=e[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(r)){if(!this.rules.other.endAngleBracket.test(r))return;let s=i0(r.slice(0,-1),"\\");if((r.length-s.length)%2===0)return}else{let s=g6(e[2],"()");if(s===-2)return;if(s>-1){let a=(e[0].indexOf("!")===0?5:4)+e[1].length+s;e[2]=e[2].substring(0,s),e[0]=e[0].substring(0,a).trim(),e[3]=""}}let n=e[2],i="";if(this.options.pedantic){let s=this.rules.other.pedanticHrefTitle.exec(n);s&&(n=s[1],i=s[3])}else i=e[3]?e[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(r)?n=n.slice(1):n=n.slice(1,-1)),lc(e,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:i&&i.replace(this.rules.inline.anyPunctuation,"$1")},e[0],this.lexer,this.rules)}}reflink(t,e){let r;if((r=this.rules.inline.reflink.exec(t))||(r=this.rules.inline.nolink.exec(t))){let n=(r[2]||r[1]).replace(this.rules.other.multipleSpaceGlobal," "),i=e[n.toLowerCase()];if(!i){let s=r[0].charAt(0);return{type:"text",raw:s,text:s}}return lc(r,i,r[0],this.lexer,this.rules)}}emStrong(t,e,r=""){let n=this.rules.inline.emStrongLDelim.exec(t);if(!(!n||n[3]&&r.match(this.rules.other.unicodeAlphaNumeric))&&(!(n[1]||n[2])||!r||this.rules.inline.punctuation.exec(r))){let i=[...n[0]].length-1,s,a,o=i,l=0,c=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,e=e.slice(-1*t.length+i);(n=c.exec(e))!=null;){if(s=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!s)continue;if(a=[...s].length,n[3]||n[4]){o+=a;continue}else if((n[5]||n[6])&&i%3&&!((i+a)%3)){l+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o+l);let u=[...n[0]][0].length,f=t.slice(0,i+n.index+u+a);if(Math.min(i,a)%2){let g=f.slice(1,-1);return{type:"em",raw:f,text:g,tokens:this.lexer.inlineTokens(g)}}let p=f.slice(2,-2);return{type:"strong",raw:f,text:p,tokens:this.lexer.inlineTokens(p)}}}}codespan(t){let e=this.rules.inline.code.exec(t);if(e){let r=e[2].replace(this.rules.other.newLineCharGlobal," "),n=this.rules.other.nonSpaceChar.test(r),i=this.rules.other.startingSpaceChar.test(r)&&this.rules.other.endingSpaceChar.test(r);return n&&i&&(r=r.substring(1,r.length-1)),{type:"codespan",raw:e[0],text:r}}}br(t){let e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}}del(t){let e=this.rules.inline.del.exec(t);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(t){let e=this.rules.inline.autolink.exec(t);if(e){let r,n;return e[2]==="@"?(r=e[1],n="mailto:"+r):(r=e[1],n=r),{type:"link",raw:e[0],text:r,href:n,tokens:[{type:"text",raw:r,text:r}]}}}url(t){var r;let e;if(e=this.rules.inline.url.exec(t)){let n,i;if(e[2]==="@")n=e[0],i="mailto:"+n;else{let s;do s=e[0],e[0]=((r=this.rules.inline._backpedal.exec(e[0]))==null?void 0:r[0])??"";while(s!==e[0]);n=e[0],e[1]==="www."?i="http://"+e[0]:i=e[0]}return{type:"link",raw:e[0],text:n,href:i,tokens:[{type:"text",raw:n,text:n}]}}}inlineText(t){let e=this.rules.inline.text.exec(t);if(e){let r=this.lexer.state.inRawBlock;return{type:"text",raw:e[0],text:e[0],escaped:r}}}},Lr=class Sa{constructor(e){Je(this,"tokens");Je(this,"options");Je(this,"state");Je(this,"tokenizer");Je(this,"inlineQueue");this.tokens=[],this.tokens.links=Object.create(null),this.options=e||An,this.options.tokenizer=this.options.tokenizer||new Fi,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let r={other:Lt,block:Z0.normal,inline:n0.normal};this.options.pedantic?(r.block=Z0.pedantic,r.inline=n0.pedantic):this.options.gfm&&(r.block=Z0.gfm,this.options.breaks?r.inline=n0.breaks:r.inline=n0.gfm),this.tokenizer.rules=r}static get rules(){return{block:Z0,inline:n0}}static lex(e,r){return new Sa(r).lex(e)}static lexInline(e,r){return new Sa(r).inlineTokens(e)}lex(e){e=e.replace(Lt.carriageReturn,`
|
||
`),this.blockTokens(e,this.tokens);for(let r=0;r<this.inlineQueue.length;r++){let n=this.inlineQueue[r];this.inlineTokens(n.src,n.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,r=[],n=!1){var i,s,a;for(this.options.pedantic&&(e=e.replace(Lt.tabCharGlobal," ").replace(Lt.spaceLine,""));e;){let o;if((s=(i=this.options.extensions)==null?void 0:i.block)!=null&&s.some(c=>(o=c.call({lexer:this},e,r))?(e=e.substring(o.raw.length),r.push(o),!0):!1))continue;if(o=this.tokenizer.space(e)){e=e.substring(o.raw.length);let c=r.at(-1);o.raw.length===1&&c!==void 0?c.raw+=`
|
||
`:r.push(o);continue}if(o=this.tokenizer.code(e)){e=e.substring(o.raw.length);let c=r.at(-1);(c==null?void 0:c.type)==="paragraph"||(c==null?void 0:c.type)==="text"?(c.raw+=(c.raw.endsWith(`
|
||
`)?"":`
|
||
`)+o.raw,c.text+=`
|
||
`+o.text,this.inlineQueue.at(-1).src=c.text):r.push(o);continue}if(o=this.tokenizer.fences(e)){e=e.substring(o.raw.length),r.push(o);continue}if(o=this.tokenizer.heading(e)){e=e.substring(o.raw.length),r.push(o);continue}if(o=this.tokenizer.hr(e)){e=e.substring(o.raw.length),r.push(o);continue}if(o=this.tokenizer.blockquote(e)){e=e.substring(o.raw.length),r.push(o);continue}if(o=this.tokenizer.list(e)){e=e.substring(o.raw.length),r.push(o);continue}if(o=this.tokenizer.html(e)){e=e.substring(o.raw.length),r.push(o);continue}if(o=this.tokenizer.def(e)){e=e.substring(o.raw.length);let c=r.at(-1);(c==null?void 0:c.type)==="paragraph"||(c==null?void 0:c.type)==="text"?(c.raw+=(c.raw.endsWith(`
|
||
`)?"":`
|
||
`)+o.raw,c.text+=`
|
||
`+o.raw,this.inlineQueue.at(-1).src=c.text):this.tokens.links[o.tag]||(this.tokens.links[o.tag]={href:o.href,title:o.title},r.push(o));continue}if(o=this.tokenizer.table(e)){e=e.substring(o.raw.length),r.push(o);continue}if(o=this.tokenizer.lheading(e)){e=e.substring(o.raw.length),r.push(o);continue}let l=e;if((a=this.options.extensions)!=null&&a.startBlock){let c=1/0,u=e.slice(1),f;this.options.extensions.startBlock.forEach(p=>{f=p.call({lexer:this},u),typeof f=="number"&&f>=0&&(c=Math.min(c,f))}),c<1/0&&c>=0&&(l=e.substring(0,c+1))}if(this.state.top&&(o=this.tokenizer.paragraph(l))){let c=r.at(-1);n&&(c==null?void 0:c.type)==="paragraph"?(c.raw+=(c.raw.endsWith(`
|
||
`)?"":`
|
||
`)+o.raw,c.text+=`
|
||
`+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=c.text):r.push(o),n=l.length!==e.length,e=e.substring(o.raw.length);continue}if(o=this.tokenizer.text(e)){e=e.substring(o.raw.length);let c=r.at(-1);(c==null?void 0:c.type)==="text"?(c.raw+=(c.raw.endsWith(`
|
||
`)?"":`
|
||
`)+o.raw,c.text+=`
|
||
`+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=c.text):r.push(o);continue}if(e){let c="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(c);break}else throw new Error(c)}}return this.state.top=!0,r}inline(e,r=[]){return this.inlineQueue.push({src:e,tokens:r}),r}inlineTokens(e,r=[]){var o,l,c;let n=e,i=null;if(this.tokens.links){let u=Object.keys(this.tokens.links);if(u.length>0)for(;(i=this.tokenizer.rules.inline.reflinkSearch.exec(n))!=null;)u.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(n=n.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(i=this.tokenizer.rules.inline.anyPunctuation.exec(n))!=null;)n=n.slice(0,i.index)+"++"+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;(i=this.tokenizer.rules.inline.blockSkip.exec(n))!=null;)n=n.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);let s=!1,a="";for(;e;){s||(a=""),s=!1;let u;if((l=(o=this.options.extensions)==null?void 0:o.inline)!=null&&l.some(p=>(u=p.call({lexer:this},e,r))?(e=e.substring(u.raw.length),r.push(u),!0):!1))continue;if(u=this.tokenizer.escape(e)){e=e.substring(u.raw.length),r.push(u);continue}if(u=this.tokenizer.tag(e)){e=e.substring(u.raw.length),r.push(u);continue}if(u=this.tokenizer.link(e)){e=e.substring(u.raw.length),r.push(u);continue}if(u=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(u.raw.length);let p=r.at(-1);u.type==="text"&&(p==null?void 0:p.type)==="text"?(p.raw+=u.raw,p.text+=u.text):r.push(u);continue}if(u=this.tokenizer.emStrong(e,n,a)){e=e.substring(u.raw.length),r.push(u);continue}if(u=this.tokenizer.codespan(e)){e=e.substring(u.raw.length),r.push(u);continue}if(u=this.tokenizer.br(e)){e=e.substring(u.raw.length),r.push(u);continue}if(u=this.tokenizer.del(e)){e=e.substring(u.raw.length),r.push(u);continue}if(u=this.tokenizer.autolink(e)){e=e.substring(u.raw.length),r.push(u);continue}if(!this.state.inLink&&(u=this.tokenizer.url(e))){e=e.substring(u.raw.length),r.push(u);continue}let f=e;if((c=this.options.extensions)!=null&&c.startInline){let p=1/0,g=e.slice(1),b;this.options.extensions.startInline.forEach(x=>{b=x.call({lexer:this},g),typeof b=="number"&&b>=0&&(p=Math.min(p,b))}),p<1/0&&p>=0&&(f=e.substring(0,p+1))}if(u=this.tokenizer.inlineText(f)){e=e.substring(u.raw.length),u.raw.slice(-1)!=="_"&&(a=u.raw.slice(-1)),s=!0;let p=r.at(-1);(p==null?void 0:p.type)==="text"?(p.raw+=u.raw,p.text+=u.text):r.push(u);continue}if(e){let p="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(p);break}else throw new Error(p)}}return r}},Bi=class{constructor(t){Je(this,"options");Je(this,"parser");this.options=t||An}space(t){return""}code({text:t,lang:e,escaped:r}){var s;let n=(s=(e||"").match(Lt.notSpaceStart))==null?void 0:s[0],i=t.replace(Lt.endingNewline,"")+`
|
||
`;return n?'<pre><code class="language-'+vr(n)+'">'+(r?i:vr(i,!0))+`</code></pre>
|
||
`:"<pre><code>"+(r?i:vr(i,!0))+`</code></pre>
|
||
`}blockquote({tokens:t}){return`<blockquote>
|
||
${this.parser.parse(t)}</blockquote>
|
||
`}html({text:t}){return t}def(t){return""}heading({tokens:t,depth:e}){return`<h${e}>${this.parser.parseInline(t)}</h${e}>
|
||
`}hr(t){return`<hr>
|
||
`}list(t){let e=t.ordered,r=t.start,n="";for(let a=0;a<t.items.length;a++){let o=t.items[a];n+=this.listitem(o)}let i=e?"ol":"ul",s=e&&r!==1?' start="'+r+'"':"";return"<"+i+s+`>
|
||
`+n+"</"+i+`>
|
||
`}listitem(t){var r;let e="";if(t.task){let n=this.checkbox({checked:!!t.checked});t.loose?((r=t.tokens[0])==null?void 0:r.type)==="paragraph"?(t.tokens[0].text=n+" "+t.tokens[0].text,t.tokens[0].tokens&&t.tokens[0].tokens.length>0&&t.tokens[0].tokens[0].type==="text"&&(t.tokens[0].tokens[0].text=n+" "+vr(t.tokens[0].tokens[0].text),t.tokens[0].tokens[0].escaped=!0)):t.tokens.unshift({type:"text",raw:n+" ",text:n+" ",escaped:!0}):e+=n+" "}return e+=this.parser.parse(t.tokens,!!t.loose),`<li>${e}</li>
|
||
`}checkbox({checked:t}){return"<input "+(t?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:t}){return`<p>${this.parser.parseInline(t)}</p>
|
||
`}table(t){let e="",r="";for(let i=0;i<t.header.length;i++)r+=this.tablecell(t.header[i]);e+=this.tablerow({text:r});let n="";for(let i=0;i<t.rows.length;i++){let s=t.rows[i];r="";for(let a=0;a<s.length;a++)r+=this.tablecell(s[a]);n+=this.tablerow({text:r})}return n&&(n=`<tbody>${n}</tbody>`),`<table>
|
||
<thead>
|
||
`+e+`</thead>
|
||
`+n+`</table>
|
||
`}tablerow({text:t}){return`<tr>
|
||
${t}</tr>
|
||
`}tablecell(t){let e=this.parser.parseInline(t.tokens),r=t.header?"th":"td";return(t.align?`<${r} align="${t.align}">`:`<${r}>`)+e+`</${r}>
|
||
`}strong({tokens:t}){return`<strong>${this.parser.parseInline(t)}</strong>`}em({tokens:t}){return`<em>${this.parser.parseInline(t)}</em>`}codespan({text:t}){return`<code>${vr(t,!0)}</code>`}br(t){return"<br>"}del({tokens:t}){return`<del>${this.parser.parseInline(t)}</del>`}link({href:t,title:e,tokens:r}){let n=this.parser.parseInline(r),i=ac(t);if(i===null)return n;t=i;let s='<a href="'+t+'"';return e&&(s+=' title="'+vr(e)+'"'),s+=">"+n+"</a>",s}image({href:t,title:e,text:r,tokens:n}){n&&(r=this.parser.parseInline(n,this.parser.textRenderer));let i=ac(t);if(i===null)return vr(r);t=i;let s=`<img src="${t}" alt="${r}"`;return e&&(s+=` title="${vr(e)}"`),s+=">",s}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:vr(t.text)}},Eo=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return""+e}image({text:e}){return""+e}br(){return""}},zr=class Ta{constructor(e){Je(this,"options");Je(this,"renderer");Je(this,"textRenderer");this.options=e||An,this.options.renderer=this.options.renderer||new Bi,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Eo}static parse(e,r){return new Ta(r).parse(e)}static parseInline(e,r){return new Ta(r).parseInline(e)}parse(e,r=!0){var i,s;let n="";for(let a=0;a<e.length;a++){let o=e[a];if((s=(i=this.options.extensions)==null?void 0:i.renderers)!=null&&s[o.type]){let c=o,u=this.options.extensions.renderers[c.type].call({parser:this},c);if(u!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(c.type)){n+=u||"";continue}}let l=o;switch(l.type){case"space":{n+=this.renderer.space(l);continue}case"hr":{n+=this.renderer.hr(l);continue}case"heading":{n+=this.renderer.heading(l);continue}case"code":{n+=this.renderer.code(l);continue}case"table":{n+=this.renderer.table(l);continue}case"blockquote":{n+=this.renderer.blockquote(l);continue}case"list":{n+=this.renderer.list(l);continue}case"html":{n+=this.renderer.html(l);continue}case"def":{n+=this.renderer.def(l);continue}case"paragraph":{n+=this.renderer.paragraph(l);continue}case"text":{let c=l,u=this.renderer.text(c);for(;a+1<e.length&&e[a+1].type==="text";)c=e[++a],u+=`
|
||
`+this.renderer.text(c);r?n+=this.renderer.paragraph({type:"paragraph",raw:u,text:u,tokens:[{type:"text",raw:u,text:u,escaped:!0}]}):n+=u;continue}default:{let c='Token with "'+l.type+'" type was not found.';if(this.options.silent)return console.error(c),"";throw new Error(c)}}}return n}parseInline(e,r=this.renderer){var i,s;let n="";for(let a=0;a<e.length;a++){let o=e[a];if((s=(i=this.options.extensions)==null?void 0:i.renderers)!=null&&s[o.type]){let c=this.options.extensions.renderers[o.type].call({parser:this},o);if(c!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(o.type)){n+=c||"";continue}}let l=o;switch(l.type){case"escape":{n+=r.text(l);break}case"html":{n+=r.html(l);break}case"link":{n+=r.link(l);break}case"image":{n+=r.image(l);break}case"strong":{n+=r.strong(l);break}case"em":{n+=r.em(l);break}case"codespan":{n+=r.codespan(l);break}case"br":{n+=r.br(l);break}case"del":{n+=r.del(l);break}case"text":{n+=r.text(l);break}default:{let c='Token with "'+l.type+'" type was not found.';if(this.options.silent)return console.error(c),"";throw new Error(c)}}}return n}},Zs,bi=(Zs=class{constructor(t){Je(this,"options");Je(this,"block");this.options=t||An}preprocess(t){return t}postprocess(t){return t}processAllTokens(t){return t}provideLexer(){return this.block?Lr.lex:Lr.lexInline}provideParser(){return this.block?zr.parse:zr.parseInline}},Je(Zs,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens"])),Zs),b6=class{constructor(...t){Je(this,"defaults",bo());Je(this,"options",this.setOptions);Je(this,"parse",this.parseMarkdown(!0));Je(this,"parseInline",this.parseMarkdown(!1));Je(this,"Parser",zr);Je(this,"Renderer",Bi);Je(this,"TextRenderer",Eo);Je(this,"Lexer",Lr);Je(this,"Tokenizer",Fi);Je(this,"Hooks",bi);this.use(...t)}walkTokens(t,e){var n,i;let r=[];for(let s of t)switch(r=r.concat(e.call(this,s)),s.type){case"table":{let a=s;for(let o of a.header)r=r.concat(this.walkTokens(o.tokens,e));for(let o of a.rows)for(let l of o)r=r.concat(this.walkTokens(l.tokens,e));break}case"list":{let a=s;r=r.concat(this.walkTokens(a.items,e));break}default:{let a=s;(i=(n=this.defaults.extensions)==null?void 0:n.childTokens)!=null&&i[a.type]?this.defaults.extensions.childTokens[a.type].forEach(o=>{let l=a[o].flat(1/0);r=r.concat(this.walkTokens(l,e))}):a.tokens&&(r=r.concat(this.walkTokens(a.tokens,e)))}}return r}use(...t){let e=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(r=>{let n={...r};if(n.async=this.defaults.async||n.async||!1,r.extensions&&(r.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if("renderer"in i){let s=e.renderers[i.name];s?e.renderers[i.name]=function(...a){let o=i.renderer.apply(this,a);return o===!1&&(o=s.apply(this,a)),o}:e.renderers[i.name]=i.renderer}if("tokenizer"in i){if(!i.level||i.level!=="block"&&i.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let s=e[i.level];s?s.unshift(i.tokenizer):e[i.level]=[i.tokenizer],i.start&&(i.level==="block"?e.startBlock?e.startBlock.push(i.start):e.startBlock=[i.start]:i.level==="inline"&&(e.startInline?e.startInline.push(i.start):e.startInline=[i.start]))}"childTokens"in i&&i.childTokens&&(e.childTokens[i.name]=i.childTokens)}),n.extensions=e),r.renderer){let i=this.defaults.renderer||new Bi(this.defaults);for(let s in r.renderer){if(!(s in i))throw new Error(`renderer '${s}' does not exist`);if(["options","parser"].includes(s))continue;let a=s,o=r.renderer[a],l=i[a];i[a]=(...c)=>{let u=o.apply(i,c);return u===!1&&(u=l.apply(i,c)),u||""}}n.renderer=i}if(r.tokenizer){let i=this.defaults.tokenizer||new Fi(this.defaults);for(let s in r.tokenizer){if(!(s in i))throw new Error(`tokenizer '${s}' does not exist`);if(["options","rules","lexer"].includes(s))continue;let a=s,o=r.tokenizer[a],l=i[a];i[a]=(...c)=>{let u=o.apply(i,c);return u===!1&&(u=l.apply(i,c)),u}}n.tokenizer=i}if(r.hooks){let i=this.defaults.hooks||new bi;for(let s in r.hooks){if(!(s in i))throw new Error(`hook '${s}' does not exist`);if(["options","block"].includes(s))continue;let a=s,o=r.hooks[a],l=i[a];bi.passThroughHooks.has(s)?i[a]=c=>{if(this.defaults.async)return Promise.resolve(o.call(i,c)).then(f=>l.call(i,f));let u=o.call(i,c);return l.call(i,u)}:i[a]=(...c)=>{let u=o.apply(i,c);return u===!1&&(u=l.apply(i,c)),u}}n.hooks=i}if(r.walkTokens){let i=this.defaults.walkTokens,s=r.walkTokens;n.walkTokens=function(a){let o=[];return o.push(s.call(this,a)),i&&(o=o.concat(i.call(this,a))),o}}this.defaults={...this.defaults,...n}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,e){return Lr.lex(t,e??this.defaults)}parser(t,e){return zr.parse(t,e??this.defaults)}parseMarkdown(t){return(e,r)=>{let n={...r},i={...this.defaults,...n},s=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&n.async===!1)return s(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof e>"u"||e===null)return s(new Error("marked(): input parameter is undefined or null"));if(typeof e!="string")return s(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected"));i.hooks&&(i.hooks.options=i,i.hooks.block=t);let a=i.hooks?i.hooks.provideLexer():t?Lr.lex:Lr.lexInline,o=i.hooks?i.hooks.provideParser():t?zr.parse:zr.parseInline;if(i.async)return Promise.resolve(i.hooks?i.hooks.preprocess(e):e).then(l=>a(l,i)).then(l=>i.hooks?i.hooks.processAllTokens(l):l).then(l=>i.walkTokens?Promise.all(this.walkTokens(l,i.walkTokens)).then(()=>l):l).then(l=>o(l,i)).then(l=>i.hooks?i.hooks.postprocess(l):l).catch(s);try{i.hooks&&(e=i.hooks.preprocess(e));let l=a(e,i);i.hooks&&(l=i.hooks.processAllTokens(l)),i.walkTokens&&this.walkTokens(l,i.walkTokens);let c=o(l,i);return i.hooks&&(c=i.hooks.postprocess(c)),c}catch(l){return s(l)}}}onError(t,e){return r=>{if(r.message+=`
|
||
Please report this to https://github.com/markedjs/marked.`,t){let n="<p>An error occurred:</p><pre>"+vr(r.message+"",!0)+"</pre>";return e?Promise.resolve(n):n}if(e)return Promise.reject(r);throw r}}},Sn=new b6;function qe(t,e){return Sn.parse(t,e)}qe.options=qe.setOptions=function(t){return Sn.setOptions(t),qe.defaults=Sn.defaults,U1(qe.defaults),qe};qe.getDefaults=bo;qe.defaults=An;qe.use=function(...t){return Sn.use(...t),qe.defaults=Sn.defaults,U1(qe.defaults),qe};qe.walkTokens=function(t,e){return Sn.walkTokens(t,e)};qe.parseInline=Sn.parseInline;qe.Parser=zr;qe.parser=zr.parse;qe.Renderer=Bi;qe.TextRenderer=Eo;qe.Lexer=Lr;qe.lexer=Lr.lex;qe.Tokenizer=Fi;qe.Hooks=bi;qe.parse=qe;qe.options;qe.setOptions;qe.use;qe.walkTokens;qe.parseInline;zr.parse;Lr.lex;var cc=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function y6(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Ug(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}),r}var td={exports:{}};(function(t){var e=typeof window<"u"?window:typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope?self:{};/**
|
||
* Prism: Lightweight, robust, elegant syntax highlighting
|
||
*
|
||
* @license MIT <https://opensource.org/licenses/MIT>
|
||
* @author Lea Verou <https://lea.verou.me>
|
||
* @namespace
|
||
* @public
|
||
*/var r=function(n){var i=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,s=0,a={},o={manual:n.Prism&&n.Prism.manual,disableWorkerMessageHandler:n.Prism&&n.Prism.disableWorkerMessageHandler,util:{encode:function y(k){return k instanceof l?new l(k.type,y(k.content),k.alias):Array.isArray(k)?k.map(y):k.replace(/&/g,"&").replace(/</g,"<").replace(/\u00a0/g," ")},type:function(y){return Object.prototype.toString.call(y).slice(8,-1)},objId:function(y){return y.__id||Object.defineProperty(y,"__id",{value:++s}),y.__id},clone:function y(k,I){I=I||{};var D,O;switch(o.util.type(k)){case"Object":if(O=o.util.objId(k),I[O])return I[O];D={},I[O]=D;for(var z in k)k.hasOwnProperty(z)&&(D[z]=y(k[z],I));return D;case"Array":return O=o.util.objId(k),I[O]?I[O]:(D=[],I[O]=D,k.forEach(function(W,H){D[H]=y(W,I)}),D);default:return k}},getLanguage:function(y){for(;y;){var k=i.exec(y.className);if(k)return k[1].toLowerCase();y=y.parentElement}return"none"},setLanguage:function(y,k){y.className=y.className.replace(RegExp(i,"gi"),""),y.classList.add("language-"+k)},currentScript:function(){if(typeof document>"u")return null;if(document.currentScript&&document.currentScript.tagName==="SCRIPT"&&1<2)return document.currentScript;try{throw new Error}catch(D){var y=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(D.stack)||[])[1];if(y){var k=document.getElementsByTagName("script");for(var I in k)if(k[I].src==y)return k[I]}return null}},isActive:function(y,k,I){for(var D="no-"+k;y;){var O=y.classList;if(O.contains(k))return!0;if(O.contains(D))return!1;y=y.parentElement}return!!I}},languages:{plain:a,plaintext:a,text:a,txt:a,extend:function(y,k){var I=o.util.clone(o.languages[y]);for(var D in k)I[D]=k[D];return I},insertBefore:function(y,k,I,D){D=D||o.languages;var O=D[y],z={};for(var W in O)if(O.hasOwnProperty(W)){if(W==k)for(var H in I)I.hasOwnProperty(H)&&(z[H]=I[H]);I.hasOwnProperty(W)||(z[W]=O[W])}var oe=D[y];return D[y]=z,o.languages.DFS(o.languages,function(me,ye){ye===oe&&me!=y&&(this[me]=z)}),z},DFS:function y(k,I,D,O){O=O||{};var z=o.util.objId;for(var W in k)if(k.hasOwnProperty(W)){I.call(k,W,k[W],D||W);var H=k[W],oe=o.util.type(H);oe==="Object"&&!O[z(H)]?(O[z(H)]=!0,y(H,I,null,O)):oe==="Array"&&!O[z(H)]&&(O[z(H)]=!0,y(H,I,W,O))}}},plugins:{},highlightAll:function(y,k){o.highlightAllUnder(document,y,k)},highlightAllUnder:function(y,k,I){var D={callback:I,container:y,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};o.hooks.run("before-highlightall",D),D.elements=Array.prototype.slice.apply(D.container.querySelectorAll(D.selector)),o.hooks.run("before-all-elements-highlight",D);for(var O=0,z;z=D.elements[O++];)o.highlightElement(z,k===!0,D.callback)},highlightElement:function(y,k,I){var D=o.util.getLanguage(y),O=o.languages[D];o.util.setLanguage(y,D);var z=y.parentElement;z&&z.nodeName.toLowerCase()==="pre"&&o.util.setLanguage(z,D);var W=y.textContent,H={element:y,language:D,grammar:O,code:W};function oe(ye){H.highlightedCode=ye,o.hooks.run("before-insert",H),H.element.innerHTML=H.highlightedCode,o.hooks.run("after-highlight",H),o.hooks.run("complete",H),I&&I.call(H.element)}if(o.hooks.run("before-sanity-check",H),z=H.element.parentElement,z&&z.nodeName.toLowerCase()==="pre"&&!z.hasAttribute("tabindex")&&z.setAttribute("tabindex","0"),!H.code){o.hooks.run("complete",H),I&&I.call(H.element);return}if(o.hooks.run("before-highlight",H),!H.grammar){oe(o.util.encode(H.code));return}if(k&&n.Worker){var me=new Worker(o.filename);me.onmessage=function(ye){oe(ye.data)},me.postMessage(JSON.stringify({language:H.language,code:H.code,immediateClose:!0}))}else oe(o.highlight(H.code,H.grammar,H.language))},highlight:function(y,k,I){var D={code:y,grammar:k,language:I};if(o.hooks.run("before-tokenize",D),!D.grammar)throw new Error('The language "'+D.language+'" has no grammar.');return D.tokens=o.tokenize(D.code,D.grammar),o.hooks.run("after-tokenize",D),l.stringify(o.util.encode(D.tokens),D.language)},tokenize:function(y,k){var I=k.rest;if(I){for(var D in I)k[D]=I[D];delete k.rest}var O=new f;return p(O,O.head,y),u(y,O,k,O.head,0),b(O)},hooks:{all:{},add:function(y,k){var I=o.hooks.all;I[y]=I[y]||[],I[y].push(k)},run:function(y,k){var I=o.hooks.all[y];if(!(!I||!I.length))for(var D=0,O;O=I[D++];)O(k)}},Token:l};n.Prism=o;function l(y,k,I,D){this.type=y,this.content=k,this.alias=I,this.length=(D||"").length|0}l.stringify=function y(k,I){if(typeof k=="string")return k;if(Array.isArray(k)){var D="";return k.forEach(function(oe){D+=y(oe,I)}),D}var O={type:k.type,content:y(k.content,I),tag:"span",classes:["token",k.type],attributes:{},language:I},z=k.alias;z&&(Array.isArray(z)?Array.prototype.push.apply(O.classes,z):O.classes.push(z)),o.hooks.run("wrap",O);var W="";for(var H in O.attributes)W+=" "+H+'="'+(O.attributes[H]||"").replace(/"/g,""")+'"';return"<"+O.tag+' class="'+O.classes.join(" ")+'"'+W+">"+O.content+"</"+O.tag+">"};function c(y,k,I,D){y.lastIndex=k;var O=y.exec(I);if(O&&D&&O[1]){var z=O[1].length;O.index+=z,O[0]=O[0].slice(z)}return O}function u(y,k,I,D,O,z){for(var W in I)if(!(!I.hasOwnProperty(W)||!I[W])){var H=I[W];H=Array.isArray(H)?H:[H];for(var oe=0;oe<H.length;++oe){if(z&&z.cause==W+","+oe)return;var me=H[oe],ye=me.inside,Le=!!me.lookbehind,ze=!!me.greedy,Ge=me.alias;if(ze&&!me.pattern.global){var Oe=me.pattern.toString().match(/[imsuy]*$/)[0];me.pattern=RegExp(me.pattern.source,Oe+"g")}for(var ke=me.pattern||me,he=D.next,je=O;he!==k.tail&&!(z&&je>=z.reach);je+=he.value.length,he=he.next){var Ke=he.value;if(k.length>y.length)return;if(!(Ke instanceof l)){var Be=1,ge;if(ze){if(ge=c(ke,je,y,Le),!ge||ge.index>=y.length)break;var St=ge.index,Ft=ge.index+ge[0].length,ht=je;for(ht+=he.value.length;St>=ht;)he=he.next,ht+=he.value.length;if(ht-=he.value.length,je=ht,he.value instanceof l)continue;for(var yt=he;yt!==k.tail&&(ht<Ft||typeof yt.value=="string");yt=yt.next)Be++,ht+=yt.value.length;Be--,Ke=y.slice(je,ht),ge.index-=je}else if(ge=c(ke,0,Ke,Le),!ge)continue;var St=ge.index,lt=ge[0],j=Ke.slice(0,St),G=Ke.slice(St+lt.length),J=je+Ke.length;z&&J>z.reach&&(z.reach=J);var ne=he.prev;j&&(ne=p(k,ne,j),je+=j.length),g(k,ne,Be);var be=new l(W,ye?o.tokenize(lt,ye):lt,Ge,lt);if(he=p(k,ne,be),G&&p(k,he,G),Be>1){var S={cause:W+","+oe,reach:J};u(y,k,I,he.prev,je,S),z&&S.reach>z.reach&&(z.reach=S.reach)}}}}}}function f(){var y={value:null,prev:null,next:null},k={value:null,prev:y,next:null};y.next=k,this.head=y,this.tail=k,this.length=0}function p(y,k,I){var D=k.next,O={value:I,prev:k,next:D};return k.next=O,D.prev=O,y.length++,O}function g(y,k,I){for(var D=k.next,O=0;O<I&&D!==y.tail;O++)D=D.next;k.next=D,D.prev=k,y.length-=O}function b(y){for(var k=[],I=y.head.next;I!==y.tail;)k.push(I.value),I=I.next;return k}if(!n.document)return n.addEventListener&&(o.disableWorkerMessageHandler||n.addEventListener("message",function(y){var k=JSON.parse(y.data),I=k.language,D=k.code,O=k.immediateClose;n.postMessage(o.highlight(D,o.languages[I],I)),O&&n.close()},!1)),o;var x=o.util.currentScript();x&&(o.filename=x.src,x.hasAttribute("data-manual")&&(o.manual=!0));function w(){o.manual||o.highlightAll()}if(!o.manual){var N=document.readyState;N==="loading"||N==="interactive"&&x&&x.defer?document.addEventListener("DOMContentLoaded",w):window.requestAnimationFrame?window.requestAnimationFrame(w):window.setTimeout(w,16)}return o}(e);t.exports&&(t.exports=r),typeof cc<"u"&&(cc.Prism=r),r.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},r.languages.markup.tag.inside["attr-value"].inside.entity=r.languages.markup.entity,r.languages.markup.doctype.inside["internal-subset"].inside=r.languages.markup,r.hooks.add("wrap",function(n){n.type==="entity"&&(n.attributes.title=n.content.replace(/&/,"&"))}),Object.defineProperty(r.languages.markup.tag,"addInlined",{value:function(i,s){var a={};a["language-"+s]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:r.languages[s]},a.cdata=/^<!\[CDATA\[|\]\]>$/i;var o={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:a}};o["language-"+s]={pattern:/[\s\S]+/,inside:r.languages[s]};var l={};l[i]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return i}),"i"),lookbehind:!0,greedy:!0,inside:o},r.languages.insertBefore("markup","cdata",l)}}),Object.defineProperty(r.languages.markup.tag,"addAttribute",{value:function(n,i){r.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+n+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[i,"language-"+i],inside:r.languages[i]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),r.languages.html=r.languages.markup,r.languages.mathml=r.languages.markup,r.languages.svg=r.languages.markup,r.languages.xml=r.languages.extend("markup",{}),r.languages.ssml=r.languages.xml,r.languages.atom=r.languages.xml,r.languages.rss=r.languages.xml,function(n){var i=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;n.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+i.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+i.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+i.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+i.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:i,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},n.languages.css.atrule.inside.rest=n.languages.css;var s=n.languages.markup;s&&(s.tag.addInlined("style","css"),s.tag.addAttribute("style","css"))}(r),r.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},r.languages.javascript=r.languages.extend("clike",{"class-name":[r.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),r.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,r.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:r.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:r.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:r.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:r.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:r.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),r.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:r.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),r.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),r.languages.markup&&(r.languages.markup.tag.addInlined("script","javascript"),r.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),r.languages.js=r.languages.javascript,function(){if(typeof r>"u"||typeof document>"u")return;Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var n="Loading…",i=function(x,w){return"✖ Error "+x+" while fetching file: "+w},s="✖ Error: File does not exist or is empty",a={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},o="data-src-status",l="loading",c="loaded",u="failed",f="pre[data-src]:not(["+o+'="'+c+'"]):not(['+o+'="'+l+'"])';function p(x,w,N){var y=new XMLHttpRequest;y.open("GET",x,!0),y.onreadystatechange=function(){y.readyState==4&&(y.status<400&&y.responseText?w(y.responseText):y.status>=400?N(i(y.status,y.statusText)):N(s))},y.send(null)}function g(x){var w=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(x||"");if(w){var N=Number(w[1]),y=w[2],k=w[3];return y?k?[N,Number(k)]:[N,void 0]:[N,N]}}r.hooks.add("before-highlightall",function(x){x.selector+=", "+f}),r.hooks.add("before-sanity-check",function(x){var w=x.element;if(w.matches(f)){x.code="",w.setAttribute(o,l);var N=w.appendChild(document.createElement("CODE"));N.textContent=n;var y=w.getAttribute("data-src"),k=x.language;if(k==="none"){var I=(/\.(\w+)$/.exec(y)||[,"none"])[1];k=a[I]||I}r.util.setLanguage(N,k),r.util.setLanguage(w,k);var D=r.plugins.autoloader;D&&D.loadLanguages(k),p(y,function(O){w.setAttribute(o,c);var z=g(w.getAttribute("data-range"));if(z){var W=O.split(/\r\n?|\n/g),H=z[0],oe=z[1]==null?W.length:z[1];H<0&&(H+=W.length),H=Math.max(0,Math.min(H-1,W.length)),oe<0&&(oe+=W.length),oe=Math.max(0,Math.min(oe,W.length)),O=W.slice(H,oe).join(`
|
||
`),w.hasAttribute("data-start")||w.setAttribute("data-start",String(H+1))}N.textContent=O,r.highlightElement(N)},function(O){w.setAttribute(o,u),N.textContent=O})}}),r.plugins.fileHighlight={highlight:function(w){for(var N=(w||document).querySelectorAll(f),y=0,k;k=N[y++];)r.highlightElement(k)}};var b=!1;r.fileHighlight=function(){b||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),b=!0),r.plugins.fileHighlight.highlight.apply(this,arguments)}}()})(td);var w6=td.exports;const uc=y6(w6);class Wt{constructor(e,r,n){this.lexer=void 0,this.start=void 0,this.end=void 0,this.lexer=e,this.start=r,this.end=n}static range(e,r){return r?!e||!e.loc||!r.loc||e.loc.lexer!==r.loc.lexer?null:new Wt(e.loc.lexer,e.loc.start,r.loc.end):e&&e.loc}}class nr{constructor(e,r){this.text=void 0,this.loc=void 0,this.noexpand=void 0,this.treatAsRelax=void 0,this.text=e,this.loc=r}range(e,r){return new nr(r,Wt.range(this,e))}}class te{constructor(e,r){this.name=void 0,this.position=void 0,this.length=void 0,this.rawMessage=void 0;var n="KaTeX parse error: "+e,i,s,a=r&&r.loc;if(a&&a.start<=a.end){var o=a.lexer.input;i=a.start,s=a.end,i===o.length?n+=" at end of input: ":n+=" at position "+(i+1)+": ";var l=o.slice(i,s).replace(/[^]/g,"$&̲"),c;i>15?c="…"+o.slice(i-15,i):c=o.slice(0,i);var u;s+15<o.length?u=o.slice(s,s+15)+"…":u=o.slice(s),n+=c+l+u}var f=new Error(n);return f.name="ParseError",f.__proto__=te.prototype,f.position=i,i!=null&&s!=null&&(f.length=s-i),f.rawMessage=e,f}}te.prototype.__proto__=Error.prototype;var x6=function(e,r){return e.indexOf(r)!==-1},k6=function(e,r){return e===void 0?r:e},S6=/([A-Z])/g,T6=function(e){return e.replace(S6,"-$1").toLowerCase()},A6={"&":"&",">":">","<":"<",'"':""","'":"'"},E6=/[&><"']/g;function C6(t){return String(t).replace(E6,e=>A6[e])}var rd=function t(e){return e.type==="ordgroup"||e.type==="color"?e.body.length===1?t(e.body[0]):e:e.type==="font"?t(e.body):e},M6=function(e){var r=rd(e);return r.type==="mathord"||r.type==="textord"||r.type==="atom"},N6=function(e){if(!e)throw new Error("Expected non-null, but got "+String(e));return e},I6=function(e){var r=/^[\x00-\x20]*([^\\/#?]*?)(:|�*58|�*3a|&colon)/i.exec(e);return r?r[2]!==":"||!/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(r[1])?null:r[1].toLowerCase():"_relative"},ve={contains:x6,deflt:k6,escape:C6,hyphenate:T6,getBaseElem:rd,isCharacterBox:M6,protocolFromUrl:I6},yi={displayMode:{type:"boolean",description:"Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.",cli:"-d, --display-mode"},output:{type:{enum:["htmlAndMathml","html","mathml"]},description:"Determines the markup language of the output.",cli:"-F, --format <type>"},leqno:{type:"boolean",description:"Render display math in leqno style (left-justified tags)."},fleqn:{type:"boolean",description:"Render display math flush left."},throwOnError:{type:"boolean",default:!0,cli:"-t, --no-throw-on-error",cliDescription:"Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error."},errorColor:{type:"string",default:"#cc0000",cli:"-c, --error-color <color>",cliDescription:"A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.",cliProcessor:t=>"#"+t},macros:{type:"object",cli:"-m, --macro <def>",cliDescription:"Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).",cliDefault:[],cliProcessor:(t,e)=>(e.push(t),e)},minRuleThickness:{type:"number",description:"Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",processor:t=>Math.max(0,t),cli:"--min-rule-thickness <size>",cliProcessor:parseFloat},colorIsTextColor:{type:"boolean",description:"Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.",cli:"-b, --color-is-text-color"},strict:{type:[{enum:["warn","ignore","error"]},"boolean","function"],description:"Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.",cli:"-S, --strict",cliDefault:!1},trust:{type:["boolean","function"],description:"Trust the input, enabling all HTML features such as \\url.",cli:"-T, --trust"},maxSize:{type:"number",default:1/0,description:"If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large",processor:t=>Math.max(0,t),cli:"-s, --max-size <n>",cliProcessor:parseInt},maxExpand:{type:"number",default:1e3,description:"Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.",processor:t=>Math.max(0,t),cli:"-e, --max-expand <n>",cliProcessor:t=>t==="Infinity"?1/0:parseInt(t)},globalGroup:{type:"boolean",cli:!1}};function R6(t){if(t.default)return t.default;var e=t.type,r=Array.isArray(e)?e[0]:e;if(typeof r!="string")return r.enum[0];switch(r){case"boolean":return!1;case"string":return"";case"number":return 0;case"object":return{}}}class Co{constructor(e){this.displayMode=void 0,this.output=void 0,this.leqno=void 0,this.fleqn=void 0,this.throwOnError=void 0,this.errorColor=void 0,this.macros=void 0,this.minRuleThickness=void 0,this.colorIsTextColor=void 0,this.strict=void 0,this.trust=void 0,this.maxSize=void 0,this.maxExpand=void 0,this.globalGroup=void 0,e=e||{};for(var r in yi)if(yi.hasOwnProperty(r)){var n=yi[r];this[r]=e[r]!==void 0?n.processor?n.processor(e[r]):e[r]:R6(n)}}reportNonstrict(e,r,n){var i=this.strict;if(typeof i=="function"&&(i=i(e,r,n)),!(!i||i==="ignore")){if(i===!0||i==="error")throw new te("LaTeX-incompatible input and strict mode is set to 'error': "+(r+" ["+e+"]"),n);i==="warn"?typeof console<"u"&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+(r+" ["+e+"]")):typeof console<"u"&&console.warn("LaTeX-incompatible input and strict mode is set to "+("unrecognized '"+i+"': "+r+" ["+e+"]"))}}useStrictBehavior(e,r,n){var i=this.strict;if(typeof i=="function")try{i=i(e,r,n)}catch{i="error"}return!i||i==="ignore"?!1:i===!0||i==="error"?!0:i==="warn"?(typeof console<"u"&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+(r+" ["+e+"]")),!1):(typeof console<"u"&&console.warn("LaTeX-incompatible input and strict mode is set to "+("unrecognized '"+i+"': "+r+" ["+e+"]")),!1)}isTrusted(e){if(e.url&&!e.protocol){var r=ve.protocolFromUrl(e.url);if(r==null)return!1;e.protocol=r}var n=typeof this.trust=="function"?this.trust(e):this.trust;return!!n}}class Kr{constructor(e,r,n){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=e,this.size=r,this.cramped=n}sup(){return xr[D6[this.id]]}sub(){return xr[O6[this.id]]}fracNum(){return xr[_6[this.id]]}fracDen(){return xr[L6[this.id]]}cramp(){return xr[z6[this.id]]}text(){return xr[$6[this.id]]}isTight(){return this.size>=2}}var Mo=0,Pi=1,qn=2,$r=3,T0=4,er=5,Wn=6,zt=7,xr=[new Kr(Mo,0,!1),new Kr(Pi,0,!0),new Kr(qn,1,!1),new Kr($r,1,!0),new Kr(T0,2,!1),new Kr(er,2,!0),new Kr(Wn,3,!1),new Kr(zt,3,!0)],D6=[T0,er,T0,er,Wn,zt,Wn,zt],O6=[er,er,er,er,zt,zt,zt,zt],_6=[qn,$r,T0,er,Wn,zt,Wn,zt],L6=[$r,$r,er,er,zt,zt,zt,zt],z6=[Pi,Pi,$r,$r,er,er,zt,zt],$6=[Mo,Pi,qn,$r,qn,$r,qn,$r],xe={DISPLAY:xr[Mo],TEXT:xr[qn],SCRIPT:xr[T0],SCRIPTSCRIPT:xr[Wn]},Aa=[{name:"latin",blocks:[[256,591],[768,879]]},{name:"cyrillic",blocks:[[1024,1279]]},{name:"armenian",blocks:[[1328,1423]]},{name:"brahmic",blocks:[[2304,4255]]},{name:"georgian",blocks:[[4256,4351]]},{name:"cjk",blocks:[[12288,12543],[19968,40879],[65280,65376]]},{name:"hangul",blocks:[[44032,55215]]}];function F6(t){for(var e=0;e<Aa.length;e++)for(var r=Aa[e],n=0;n<r.blocks.length;n++){var i=r.blocks[n];if(t>=i[0]&&t<=i[1])return r.name}return null}var wi=[];Aa.forEach(t=>t.blocks.forEach(e=>wi.push(...e)));function nd(t){for(var e=0;e<wi.length;e+=2)if(t>=wi[e]&&t<=wi[e+1])return!0;return!1}var Rn=80,B6=function(e,r){return"M95,"+(622+e+r)+`
|
||
c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14
|
||
c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54
|
||
c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10
|
||
s173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429
|
||
c69,-144,104.5,-217.7,106.5,-221
|
||
l`+e/2.075+" -"+e+`
|
||
c5.3,-9.3,12,-14,20,-14
|
||
H400000v`+(40+e)+`H845.2724
|
||
s-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7
|
||
c-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z
|
||
M`+(834+e)+" "+r+"h400000v"+(40+e)+"h-400000z"},P6=function(e,r){return"M263,"+(601+e+r)+`c0.7,0,18,39.7,52,119
|
||
c34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120
|
||
c340,-704.7,510.7,-1060.3,512,-1067
|
||
l`+e/2.084+" -"+e+`
|
||
c4.7,-7.3,11,-11,19,-11
|
||
H40000v`+(40+e)+`H1012.3
|
||
s-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232
|
||
c-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1
|
||
s-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26
|
||
c-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z
|
||
M`+(1001+e)+" "+r+"h400000v"+(40+e)+"h-400000z"},H6=function(e,r){return"M983 "+(10+e+r)+`
|
||
l`+e/3.13+" -"+e+`
|
||
c4,-6.7,10,-10,18,-10 H400000v`+(40+e)+`
|
||
H1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7
|
||
s-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744
|
||
c-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30
|
||
c26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722
|
||
c56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5
|
||
c53.7,-170.3,84.5,-266.8,92.5,-289.5z
|
||
M`+(1001+e)+" "+r+"h400000v"+(40+e)+"h-400000z"},q6=function(e,r){return"M424,"+(2398+e+r)+`
|
||
c-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514
|
||
c0,-2,-10.7,14.3,-32,49c-4.7,7.3,-9.8,15.7,-15.5,25c-5.7,9.3,-9.8,16,-12.5,20
|
||
s-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121
|
||
s209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081
|
||
l`+e/4.223+" -"+e+`c4,-6.7,10,-10,18,-10 H400000
|
||
v`+(40+e)+`H1014.6
|
||
s-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185
|
||
c-2,6,-10,9,-24,9
|
||
c-8,0,-12,-0.7,-12,-2z M`+(1001+e)+" "+r+`
|
||
h400000v`+(40+e)+"h-400000z"},j6=function(e,r){return"M473,"+(2713+e+r)+`
|
||
c339.3,-1799.3,509.3,-2700,510,-2702 l`+e/5.298+" -"+e+`
|
||
c3.3,-7.3,9.3,-11,18,-11 H400000v`+(40+e)+`H1017.7
|
||
s-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9
|
||
c-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200
|
||
c0,-1.3,-5.3,8.7,-16,30c-10.7,21.3,-21.3,42.7,-32,64s-16,33,-16,33s-26,-26,-26,-26
|
||
s76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104,
|
||
606zM`+(1001+e)+" "+r+"h400000v"+(40+e)+"H1017.7z"},U6=function(e){var r=e/2;return"M400000 "+e+" H0 L"+r+" 0 l65 45 L145 "+(e-80)+" H400000z"},V6=function(e,r,n){var i=n-54-r-e;return"M702 "+(e+r)+"H400000"+(40+e)+`
|
||
H742v`+i+`l-4 4-4 4c-.667.7 -2 1.5-4 2.5s-4.167 1.833-6.5 2.5-5.5 1-9.5 1
|
||
h-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170
|
||
c-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667
|
||
219 661 l218 661zM702 `+r+"H400000v"+(40+e)+"H742z"},W6=function(e,r,n){r=1e3*r;var i="";switch(e){case"sqrtMain":i=B6(r,Rn);break;case"sqrtSize1":i=P6(r,Rn);break;case"sqrtSize2":i=H6(r,Rn);break;case"sqrtSize3":i=q6(r,Rn);break;case"sqrtSize4":i=j6(r,Rn);break;case"sqrtTall":i=V6(r,Rn,n)}return i},G6=function(e,r){switch(e){case"⎜":return"M291 0 H417 V"+r+" H291z M291 0 H417 V"+r+" H291z";case"∣":return"M145 0 H188 V"+r+" H145z M145 0 H188 V"+r+" H145z";case"∥":return"M145 0 H188 V"+r+" H145z M145 0 H188 V"+r+" H145z"+("M367 0 H410 V"+r+" H367z M367 0 H410 V"+r+" H367z");case"⎟":return"M457 0 H583 V"+r+" H457z M457 0 H583 V"+r+" H457z";case"⎢":return"M319 0 H403 V"+r+" H319z M319 0 H403 V"+r+" H319z";case"⎥":return"M263 0 H347 V"+r+" H263z M263 0 H347 V"+r+" H263z";case"⎪":return"M384 0 H504 V"+r+" H384z M384 0 H504 V"+r+" H384z";case"⏐":return"M312 0 H355 V"+r+" H312z M312 0 H355 V"+r+" H312z";case"‖":return"M257 0 H300 V"+r+" H257z M257 0 H300 V"+r+" H257z"+("M478 0 H521 V"+r+" H478z M478 0 H521 V"+r+" H478z");default:return""}},dc={doubleleftarrow:`M262 157
|
||
l10-10c34-36 62.7-77 86-123 3.3-8 5-13.3 5-16 0-5.3-6.7-8-20-8-7.3
|
||
0-12.2.5-14.5 1.5-2.3 1-4.8 4.5-7.5 10.5-49.3 97.3-121.7 169.3-217 216-28
|
||
14-57.3 25-88 33-6.7 2-11 3.8-13 5.5-2 1.7-3 4.2-3 7.5s1 5.8 3 7.5
|
||
c2 1.7 6.3 3.5 13 5.5 68 17.3 128.2 47.8 180.5 91.5 52.3 43.7 93.8 96.2 124.5
|
||
157.5 9.3 8 15.3 12.3 18 13h6c12-.7 18-4 18-10 0-2-1.7-7-5-15-23.3-46-52-87
|
||
-86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7
|
||
-2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z
|
||
m8 0v40h399730v-40zm0 194v40h399730v-40z`,doublerightarrow:`M399738 392l
|
||
-10 10c-34 36-62.7 77-86 123-3.3 8-5 13.3-5 16 0 5.3 6.7 8 20 8 7.3 0 12.2-.5
|
||
14.5-1.5 2.3-1 4.8-4.5 7.5-10.5 49.3-97.3 121.7-169.3 217-216 28-14 57.3-25 88
|
||
-33 6.7-2 11-3.8 13-5.5 2-1.7 3-4.2 3-7.5s-1-5.8-3-7.5c-2-1.7-6.3-3.5-13-5.5-68
|
||
-17.3-128.2-47.8-180.5-91.5-52.3-43.7-93.8-96.2-124.5-157.5-9.3-8-15.3-12.3-18
|
||
-13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782
|
||
c-328 0 0 0 0 0l10 8c26.7 20 65.7 43 117 69-2.7 2-6 3.7-10 5-36.7 16-72.3 37.3
|
||
-107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z`,leftarrow:`M400000 241H110l3-3c68.7-52.7 113.7-120
|
||
135-202 4-14.7 6-23 6-25 0-7.3-7-11-21-11-8 0-13.2.8-15.5 2.5-2.3 1.7-4.2 5.8
|
||
-5.5 12.5-1.3 4.7-2.7 10.3-4 17-12 48.7-34.8 92-68.5 130S65.3 228.3 18 247
|
||
c-10 4-16 7.7-18 11 0 8.7 6 14.3 18 17 47.3 18.7 87.8 47 121.5 85S196 441.3 208
|
||
490c.7 2 1.3 5 2 9s1.2 6.7 1.5 8c.3 1.3 1 3.3 2 6s2.2 4.5 3.5 5.5c1.3 1 3.3
|
||
1.8 6 2.5s6 1 10 1c14 0 21-3.7 21-11 0-2-2-10.3-6-25-20-79.3-65-146.7-135-202
|
||
l-3-3h399890zM100 241v40h399900v-40z`,leftbrace:`M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117
|
||
-45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7
|
||
5-6 9-10 13-.7 1-7.3 1-20 1H6z`,leftbraceunder:`M0 6l6-6h17c12.688 0 19.313.3 20 1 4 4 7.313 8.3 10 13
|
||
35.313 51.3 80.813 93.8 136.5 127.5 55.688 33.7 117.188 55.8 184.5 66.5.688
|
||
0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7
|
||
-331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z`,leftgroup:`M400000 80
|
||
H435C64 80 168.3 229.4 21 260c-5.9 1.2-18 0-18 0-2 0-3-1-3-3v-38C76 61 257 0
|
||
435 0h399565z`,leftgroupunder:`M400000 262
|
||
H435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219
|
||
435 219h399565z`,leftharpoon:`M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3
|
||
-3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5
|
||
-18.3 3-21-1.3-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7
|
||
-196 228-6.7 4.7-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40z`,leftharpoonplus:`M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3-3.3 10.2-9.5
|
||
20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5-18.3 3-21-1.3
|
||
-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7-196 228-6.7 4.7
|
||
-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z
|
||
m0 0v40h400000v-40z`,leftharpoondown:`M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333
|
||
5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5
|
||
1 9 1h5c10.667 0 16.667-2 18-6 2-2.667 1-9.667-3-21-32-87.333-82.667-157.667
|
||
-152-211l-3-3h399907v-40zM93 281 H400000 v-40L7 241z`,leftharpoondownplus:`M7 435c-4 4-6.3 8.7-7 14 0 5.3.7 9 2 11s5.3 5.3 12
|
||
10c90.7 54 156 130 196 228 3.3 10.7 6.3 16.3 9 17 2 .7 5 1 9 1h5c10.7 0 16.7
|
||
-2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0
|
||
v40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z`,lefthook:`M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5
|
||
-83.5C70.8 58.2 104 47 142 47 c16.7 0 25 6.7 25 20 0 12-8.7 18.7-26 20-40 3.3
|
||
-68.7 15.7-86 37-10 12-15 25.3-15 40 0 22.7 9.8 40.7 29.5 54 19.7 13.3 43.5 21
|
||
71.5 23h399859zM103 281v-40h399897v40z`,leftlinesegment:`M40 281 V428 H0 V94 H40 V241 H400000 v40z
|
||
M40 281 V428 H0 V94 H40 V241 H400000 v40z`,leftmapsto:`M40 281 V448H0V74H40V241H400000v40z
|
||
M40 281 V448H0V74H40V241H400000v40z`,leftToFrom:`M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23
|
||
-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8
|
||
c28.7-32 52-65.7 70-101 10.7-23.3 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 265.3
|
||
68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z`,longequal:`M0 50 h400000 v40H0z m0 194h40000v40H0z
|
||
M0 50 h400000 v40H0z m0 194h40000v40H0z`,midbrace:`M200428 334
|
||
c-100.7-8.3-195.3-44-280-108-55.3-42-101.7-93-139-153l-9-14c-2.7 4-5.7 8.7-9 14
|
||
-53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7
|
||
311.7-78.3 403-201 6-8 9.7-12 11-12 .7-.7 6.7-1 18-1s17.3.3 18 1c1.3 0 5 4 11
|
||
12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z`,midbraceunder:`M199572 214
|
||
c100.7 8.3 195.3 44 280 108 55.3 42 101.7 93 139 153l9 14c2.7-4 5.7-8.7 9-14
|
||
53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3
|
||
11.7-311.7 78.3-403 201-6 8-9.7 12-11 12-.7.7-6.7 1-18 1s-17.3-.3-18-1c-1.3 0
|
||
-5-4-11-12-44.7-59.3-101.3-106.3-170-141s-145.3-54.3-229-60H0V214z`,oiintSize1:`M512.6 71.6c272.6 0 320.3 106.8 320.3 178.2 0 70.8-47.7 177.6
|
||
-320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z
|
||
m368.1 178.2c0-86.4-60.9-215.4-368.1-215.4-306.4 0-367.3 129-367.3 215.4 0 85.8
|
||
60.9 214.8 367.3 214.8 307.2 0 368.1-129 368.1-214.8z`,oiintSize2:`M757.8 100.1c384.7 0 451.1 137.6 451.1 230 0 91.3-66.4 228.8
|
||
-451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z
|
||
m502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2
|
||
c0 110 84 276 504 276s502.4-166 502.4-276z`,oiiintSize1:`M681.4 71.6c408.9 0 480.5 106.8 480.5 178.2 0 70.8-71.6 177.6
|
||
-480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z
|
||
m525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0
|
||
85.8 86.8 214.8 524.7 214.8 438.9 0 525.7-129 525.7-214.8z`,oiiintSize2:`M1021.2 53c603.6 0 707.8 165.8 707.8 277.2 0 110-104.2 275.8
|
||
-707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z
|
||
m770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1
|
||
c0 130 128.8 326.4 772.7 326.4s770.5-196.4 770.5-326.4z`,rightarrow:`M0 241v40h399891c-47.3 35.3-84 78-110 128
|
||
-16.7 32-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20
|
||
11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7
|
||
39-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85
|
||
-40.5-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5
|
||
-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67
|
||
151.7 139 205zm0 0v40h399900v-40z`,rightbrace:`M400000 542l
|
||
-6 6h-17c-12.7 0-19.3-.3-20-1-4-4-7.3-8.3-10-13-35.3-51.3-80.8-93.8-136.5-127.5
|
||
s-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1
|
||
c124.7 8 235 61.7 331 161 31.3 33.3 59.7 72.7 85 118l7 13v35z`,rightbraceunder:`M399994 0l6 6v35l-6 11c-56 104-135.3 181.3-238 232-57.3
|
||
28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237
|
||
-174 2.7-5 6-9 10-13 .7-1 7.3-1 20-1h17z`,rightgroup:`M0 80h399565c371 0 266.7 149.4 414 180 5.9 1.2 18 0 18 0 2 0
|
||
3-1 3-3v-38c-76-158-257-219-435-219H0z`,rightgroupunder:`M0 262h399565c371 0 266.7-149.4 414-180 5.9-1.2 18 0 18
|
||
0 2 0 3 1 3 3v38c-76 158-257 219-435 219H0z`,rightharpoon:`M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3
|
||
-3.7-15.3-11-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2
|
||
-10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58
|
||
69.2 92 94.5zm0 0v40h399900v-40z`,rightharpoonplus:`M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3-3.7-15.3-11
|
||
-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2-10.7 0-16.7
|
||
2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5z
|
||
m0 0v40h399900v-40z m100 194v40h399900v-40zm0 0v40h399900v-40z`,rightharpoondown:`M399747 511c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8
|
||
8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5
|
||
-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3-64.7 57-92 95
|
||
-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 241v40h399900v-40z`,rightharpoondownplus:`M399747 705c0 7.3 6.7 11 20 11 8 0 13-.8
|
||
15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3
|
||
8.5-5.8 9.5-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3
|
||
-64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z
|
||
m0-194v40h400000v-40zm0 0v40h400000v-40z`,righthook:`M399859 241c-764 0 0 0 0 0 40-3.3 68.7-15.7 86-37 10-12 15-25.3
|
||
15-40 0-22.7-9.8-40.7-29.5-54-19.7-13.3-43.5-21-71.5-23-17.3-1.3-26-8-26-20 0
|
||
-13.3 8.7-20 26-20 38 0 71 11.2 99 33.5 0 0 7 5.6 21 16.7 14 11.2 21 33.5 21
|
||
66.8s-14 61.2-42 83.5c-28 22.3-61 33.5-99 33.5L0 241z M0 281v-40h399859v40z`,rightlinesegment:`M399960 241 V94 h40 V428 h-40 V281 H0 v-40z
|
||
M399960 241 V94 h40 V428 h-40 V281 H0 v-40z`,rightToFrom:`M400000 167c-70.7-42-118-97.7-142-167h-23c-15.3 0-23 .3-23
|
||
1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32
|
||
-52 65.7-70 101-10.7 23.3-16 35.7-16 37 0 .7 7.7 1 23 1h23c24-69.3 71.3-125 142
|
||
-167z M100 147v40h399900v-40zM0 341v40h399900v-40z`,twoheadleftarrow:`M0 167c68 40
|
||
115.7 95.7 143 167h22c15.3 0 23-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69
|
||
-70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3
|
||
-40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19
|
||
-37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101
|
||
10.7-23.333 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 71.3 68 127 0 167z`,twoheadrightarrow:`M400000 167
|
||
c-68-40-115.7-95.7-143-167h-22c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3
|
||
41.3 69 70 101l7 8h-125l-9-7c-50.7-39.3-85-86-103-140h-46c0 4.7 6.3 18.7 19 42
|
||
18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333
|
||
-19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70
|
||
101-10.7 23.333-16 35.7-16 37 0 .7 7.7 1 23 1h22c27.3-71.3 75-127 143-167z`,tilde1:`M200 55.538c-77 0-168 73.953-177 73.953-3 0-7
|
||
-2.175-9-5.437L2 97c-1-2-2-4-2-6 0-4 2-7 5-9l20-12C116 12 171 0 207 0c86 0
|
||
114 68 191 68 78 0 168-68 177-68 4 0 7 2 9 5l12 19c1 2.175 2 4.35 2 6.525 0
|
||
4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128
|
||
-68.267.847-113-73.952-191-73.952z`,tilde2:`M344 55.266c-142 0-300.638 81.316-311.5 86.418
|
||
-8.01 3.762-22.5 10.91-23.5 5.562L1 120c-1-2-1-3-1-4 0-5 3-9 8-10l18.4-9C160.9
|
||
31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114
|
||
c1 2.14 1 3.21 1 4.28 0 5.347-3 9.626-7 10.696l-22.3 12.622C852.6 158.372 751
|
||
181.476 676 181.476c-149 0-189-126.21-332-126.21z`,tilde3:`M786 59C457 59 32 175.242 13 175.242c-6 0-10-3.457
|
||
-11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0
|
||
411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697
|
||
16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696
|
||
-338 0-409-156.573-744-156.573z`,tilde4:`M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345
|
||
-11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409
|
||
177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9
|
||
14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409
|
||
-175.236-744-175.236z`,vec:`M377 20c0-5.333 1.833-10 5.5-14S391 0 397 0c4.667 0 8.667 1.667 12 5
|
||
3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11
|
||
10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63
|
||
-1.333 1.333-3.167 3.5-5.5 6.5s-4 4.833-5 5.5c-1 .667-2.5 1.333-4.5 2s-4.333 1
|
||
-7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59
|
||
H213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359
|
||
c-16-25.333-24-45-24-59z`,widehat1:`M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22
|
||
c-1 5-5 9-11 9h-2L532 67 19 159h-2c-5 0-9-4-11-9l-5-22c-1-6 2-12 8-13z`,widehat2:`M1181 0h2l1171 176c6 0 10 5 10 11l-2 23c-1 6-5 10
|
||
-11 10h-1L1182 67 15 220h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widehat3:`M1181 0h2l1171 236c6 0 10 5 10 11l-2 23c-1 6-5 10
|
||
-11 10h-1L1182 67 15 280h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widehat4:`M1181 0h2l1171 296c6 0 10 5 10 11l-2 23c-1 6-5 10
|
||
-11 10h-1L1182 67 15 340h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`,widecheck1:`M529,159h5l519,-115c5,-1,9,-5,9,-10c0,-1,-1,-2,-1,-3l-4,-22c-1,
|
||
-5,-5,-9,-11,-9h-2l-512,92l-513,-92h-2c-5,0,-9,4,-11,9l-5,22c-1,6,2,12,8,13z`,widecheck2:`M1181,220h2l1171,-176c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,
|
||
-11,-10h-1l-1168,153l-1167,-153h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,widecheck3:`M1181,280h2l1171,-236c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,
|
||
-11,-10h-1l-1168,213l-1167,-213h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,widecheck4:`M1181,340h2l1171,-296c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,
|
||
-11,-10h-1l-1168,273l-1167,-273h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`,baraboveleftarrow:`M400000 620h-399890l3 -3c68.7 -52.7 113.7 -120 135 -202
|
||
c4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5
|
||
c-2.3 1.7 -4.2 5.8 -5.5 12.5c-1.3 4.7 -2.7 10.3 -4 17c-12 48.7 -34.8 92 -68.5 130
|
||
s-74.2 66.3 -121.5 85c-10 4 -16 7.7 -18 11c0 8.7 6 14.3 18 17c47.3 18.7 87.8 47
|
||
121.5 85s56.5 81.3 68.5 130c0.7 2 1.3 5 2 9s1.2 6.7 1.5 8c0.3 1.3 1 3.3 2 6
|
||
s2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21 -3.7 21 -11
|
||
c0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z
|
||
M100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z`,rightarrowabovebar:`M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32
|
||
-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0
|
||
13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39
|
||
-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85-40.5
|
||
-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5
|
||
-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67
|
||
151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z`,baraboveshortleftharpoon:`M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11
|
||
c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17
|
||
c2,0.7,5,1,9,1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21
|
||
c-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40
|
||
c-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z
|
||
M0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z`,rightharpoonaboveshortbar:`M0,241 l0,40c399126,0,399993,0,399993,0
|
||
c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,
|
||
-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6
|
||
c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z
|
||
M0 241 v40 H399908 v-40z M0 475 v-40 H399500 v40z M0 475 v-40 H399500 v40z`,shortbaraboveleftharpoon:`M7,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11
|
||
c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17c2,0.7,5,1,9,
|
||
1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21c-32,-87.3,-82.7,-157.7,
|
||
-152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z
|
||
M93 435 v40 H400000 v-40z M500 241 v40 H400000 v-40z M500 241 v40 H400000 v-40z`,shortrightharpoonabovebar:`M53,241l0,40c398570,0,399437,0,399437,0
|
||
c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,
|
||
-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6
|
||
c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z
|
||
M500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z`},K6=function(e,r){switch(e){case"lbrack":return"M403 1759 V84 H666 V0 H319 V1759 v"+r+` v1759 h347 v-84
|
||
H403z M403 1759 V0 H319 V1759 v`+r+" v1759 h84z";case"rbrack":return"M347 1759 V0 H0 V84 H263 V1759 v"+r+` v1759 H0 v84 H347z
|
||
M347 1759 V0 H263 V1759 v`+r+" v1759 h84z";case"vert":return"M145 15 v585 v"+r+` v585 c2.667,10,9.667,15,21,15
|
||
c10,0,16.667,-5,20,-15 v-585 v`+-r+` v-585 c-2.667,-10,-9.667,-15,-21,-15
|
||
c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v`+r+" v585 h43z";case"doublevert":return"M145 15 v585 v"+r+` v585 c2.667,10,9.667,15,21,15
|
||
c10,0,16.667,-5,20,-15 v-585 v`+-r+` v-585 c-2.667,-10,-9.667,-15,-21,-15
|
||
c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v`+r+` v585 h43z
|
||
M367 15 v585 v`+r+` v585 c2.667,10,9.667,15,21,15
|
||
c10,0,16.667,-5,20,-15 v-585 v`+-r+` v-585 c-2.667,-10,-9.667,-15,-21,-15
|
||
c-10,0,-16.667,5,-20,15z M410 15 H367 v585 v`+r+" v585 h43z";case"lfloor":return"M319 602 V0 H403 V602 v"+r+` v1715 h263 v84 H319z
|
||
MM319 602 V0 H403 V602 v`+r+" v1715 H319z";case"rfloor":return"M319 602 V0 H403 V602 v"+r+` v1799 H0 v-84 H319z
|
||
MM319 602 V0 H403 V602 v`+r+" v1715 H319z";case"lceil":return"M403 1759 V84 H666 V0 H319 V1759 v"+r+` v602 h84z
|
||
M403 1759 V0 H319 V1759 v`+r+" v602 h84z";case"rceil":return"M347 1759 V0 H0 V84 H263 V1759 v"+r+` v602 h84z
|
||
M347 1759 V0 h-84 V1759 v`+r+" v602 h84z";case"lparen":return`M863,9c0,-2,-2,-5,-6,-9c0,0,-17,0,-17,0c-12.7,0,-19.3,0.3,-20,1
|
||
c-5.3,5.3,-10.3,11,-15,17c-242.7,294.7,-395.3,682,-458,1162c-21.3,163.3,-33.3,349,
|
||
-36,557 l0,`+(r+84)+`c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210,
|
||
949.7,470,1265c4.7,6,9.7,11.7,15,17c0.7,0.7,7,1,19,1c0,0,18,0,18,0c4,-4,6,-7,6,-9
|
||
c0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5,
|
||
-544.7,-112.5,-882c-2,-104,-3,-167,-3,-189
|
||
l0,-`+(r+92)+`c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3,
|
||
-210,155.3,-396.3,270,-559c6.7,-9.3,10,-15.3,10,-18z`;case"rparen":return`M76,0c-16.7,0,-25,3,-25,9c0,2,2,6.3,6,13c21.3,28.7,42.3,60.3,
|
||
63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5
|
||
c11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0,`+(r+9)+`
|
||
c-3,4,-3.3,16.7,-3.3,38c0,162,-5.7,313.7,-17,455c-18.7,248,-55.8,469.3,-111.5,664
|
||
c-55.7,194.7,-131.8,370.3,-228.5,527c-20.7,34.7,-41.7,66.3,-63,95c-2,3.3,-4,7,-6,11
|
||
c0,7.3,5.7,11,17,11c0,0,11,0,11,0c9.3,0,14.3,-0.3,15,-1c5.3,-5.3,10.3,-11,15,-17
|
||
c242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558
|
||
l0,-`+(r+144)+`c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7,
|
||
-470,-1265c-4.7,-6,-9.7,-11.7,-15,-17c-0.7,-0.7,-6.7,-1,-18,-1z`;default:throw new Error("Unknown stretchy delimiter.")}};class L0{constructor(e){this.children=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.children=e,this.classes=[],this.height=0,this.depth=0,this.maxFontSize=0,this.style={}}hasClass(e){return ve.contains(this.classes,e)}toNode(){for(var e=document.createDocumentFragment(),r=0;r<this.children.length;r++)e.appendChild(this.children[r].toNode());return e}toMarkup(){for(var e="",r=0;r<this.children.length;r++)e+=this.children[r].toMarkup();return e}toText(){var e=r=>r.toText();return this.children.map(e).join("")}}var kr={"AMS-Regular":{32:[0,0,0,0,.25],65:[0,.68889,0,0,.72222],66:[0,.68889,0,0,.66667],67:[0,.68889,0,0,.72222],68:[0,.68889,0,0,.72222],69:[0,.68889,0,0,.66667],70:[0,.68889,0,0,.61111],71:[0,.68889,0,0,.77778],72:[0,.68889,0,0,.77778],73:[0,.68889,0,0,.38889],74:[.16667,.68889,0,0,.5],75:[0,.68889,0,0,.77778],76:[0,.68889,0,0,.66667],77:[0,.68889,0,0,.94445],78:[0,.68889,0,0,.72222],79:[.16667,.68889,0,0,.77778],80:[0,.68889,0,0,.61111],81:[.16667,.68889,0,0,.77778],82:[0,.68889,0,0,.72222],83:[0,.68889,0,0,.55556],84:[0,.68889,0,0,.66667],85:[0,.68889,0,0,.72222],86:[0,.68889,0,0,.72222],87:[0,.68889,0,0,1],88:[0,.68889,0,0,.72222],89:[0,.68889,0,0,.72222],90:[0,.68889,0,0,.66667],107:[0,.68889,0,0,.55556],160:[0,0,0,0,.25],165:[0,.675,.025,0,.75],174:[.15559,.69224,0,0,.94666],240:[0,.68889,0,0,.55556],295:[0,.68889,0,0,.54028],710:[0,.825,0,0,2.33334],732:[0,.9,0,0,2.33334],770:[0,.825,0,0,2.33334],771:[0,.9,0,0,2.33334],989:[.08167,.58167,0,0,.77778],1008:[0,.43056,.04028,0,.66667],8245:[0,.54986,0,0,.275],8463:[0,.68889,0,0,.54028],8487:[0,.68889,0,0,.72222],8498:[0,.68889,0,0,.55556],8502:[0,.68889,0,0,.66667],8503:[0,.68889,0,0,.44445],8504:[0,.68889,0,0,.66667],8513:[0,.68889,0,0,.63889],8592:[-.03598,.46402,0,0,.5],8594:[-.03598,.46402,0,0,.5],8602:[-.13313,.36687,0,0,1],8603:[-.13313,.36687,0,0,1],8606:[.01354,.52239,0,0,1],8608:[.01354,.52239,0,0,1],8610:[.01354,.52239,0,0,1.11111],8611:[.01354,.52239,0,0,1.11111],8619:[0,.54986,0,0,1],8620:[0,.54986,0,0,1],8621:[-.13313,.37788,0,0,1.38889],8622:[-.13313,.36687,0,0,1],8624:[0,.69224,0,0,.5],8625:[0,.69224,0,0,.5],8630:[0,.43056,0,0,1],8631:[0,.43056,0,0,1],8634:[.08198,.58198,0,0,.77778],8635:[.08198,.58198,0,0,.77778],8638:[.19444,.69224,0,0,.41667],8639:[.19444,.69224,0,0,.41667],8642:[.19444,.69224,0,0,.41667],8643:[.19444,.69224,0,0,.41667],8644:[.1808,.675,0,0,1],8646:[.1808,.675,0,0,1],8647:[.1808,.675,0,0,1],8648:[.19444,.69224,0,0,.83334],8649:[.1808,.675,0,0,1],8650:[.19444,.69224,0,0,.83334],8651:[.01354,.52239,0,0,1],8652:[.01354,.52239,0,0,1],8653:[-.13313,.36687,0,0,1],8654:[-.13313,.36687,0,0,1],8655:[-.13313,.36687,0,0,1],8666:[.13667,.63667,0,0,1],8667:[.13667,.63667,0,0,1],8669:[-.13313,.37788,0,0,1],8672:[-.064,.437,0,0,1.334],8674:[-.064,.437,0,0,1.334],8705:[0,.825,0,0,.5],8708:[0,.68889,0,0,.55556],8709:[.08167,.58167,0,0,.77778],8717:[0,.43056,0,0,.42917],8722:[-.03598,.46402,0,0,.5],8724:[.08198,.69224,0,0,.77778],8726:[.08167,.58167,0,0,.77778],8733:[0,.69224,0,0,.77778],8736:[0,.69224,0,0,.72222],8737:[0,.69224,0,0,.72222],8738:[.03517,.52239,0,0,.72222],8739:[.08167,.58167,0,0,.22222],8740:[.25142,.74111,0,0,.27778],8741:[.08167,.58167,0,0,.38889],8742:[.25142,.74111,0,0,.5],8756:[0,.69224,0,0,.66667],8757:[0,.69224,0,0,.66667],8764:[-.13313,.36687,0,0,.77778],8765:[-.13313,.37788,0,0,.77778],8769:[-.13313,.36687,0,0,.77778],8770:[-.03625,.46375,0,0,.77778],8774:[.30274,.79383,0,0,.77778],8776:[-.01688,.48312,0,0,.77778],8778:[.08167,.58167,0,0,.77778],8782:[.06062,.54986,0,0,.77778],8783:[.06062,.54986,0,0,.77778],8785:[.08198,.58198,0,0,.77778],8786:[.08198,.58198,0,0,.77778],8787:[.08198,.58198,0,0,.77778],8790:[0,.69224,0,0,.77778],8791:[.22958,.72958,0,0,.77778],8796:[.08198,.91667,0,0,.77778],8806:[.25583,.75583,0,0,.77778],8807:[.25583,.75583,0,0,.77778],8808:[.25142,.75726,0,0,.77778],8809:[.25142,.75726,0,0,.77778],8812:[.25583,.75583,0,0,.5],8814:[.20576,.70576,0,0,.77778],8815:[.20576,.70576,0,0,.77778],8816:[.30274,.79383,0,0,.77778],8817:[.30274,.79383,0,0,.77778],8818:[.22958,.72958,0,0,.77778],8819:[.22958,.72958,0,0,.77778],8822:[.1808,.675,0,0,.77778],8823:[.1808,.675,0,0,.77778],8828:[.13667,.63667,0,0,.77778],8829:[.13667,.63667,0,0,.77778],8830:[.22958,.72958,0,0,.77778],8831:[.22958,.72958,0,0,.77778],8832:[.20576,.70576,0,0,.77778],8833:[.20576,.70576,0,0,.77778],8840:[.30274,.79383,0,0,.77778],8841:[.30274,.79383,0,0,.77778],8842:[.13597,.63597,0,0,.77778],8843:[.13597,.63597,0,0,.77778],8847:[.03517,.54986,0,0,.77778],8848:[.03517,.54986,0,0,.77778],8858:[.08198,.58198,0,0,.77778],8859:[.08198,.58198,0,0,.77778],8861:[.08198,.58198,0,0,.77778],8862:[0,.675,0,0,.77778],8863:[0,.675,0,0,.77778],8864:[0,.675,0,0,.77778],8865:[0,.675,0,0,.77778],8872:[0,.69224,0,0,.61111],8873:[0,.69224,0,0,.72222],8874:[0,.69224,0,0,.88889],8876:[0,.68889,0,0,.61111],8877:[0,.68889,0,0,.61111],8878:[0,.68889,0,0,.72222],8879:[0,.68889,0,0,.72222],8882:[.03517,.54986,0,0,.77778],8883:[.03517,.54986,0,0,.77778],8884:[.13667,.63667,0,0,.77778],8885:[.13667,.63667,0,0,.77778],8888:[0,.54986,0,0,1.11111],8890:[.19444,.43056,0,0,.55556],8891:[.19444,.69224,0,0,.61111],8892:[.19444,.69224,0,0,.61111],8901:[0,.54986,0,0,.27778],8903:[.08167,.58167,0,0,.77778],8905:[.08167,.58167,0,0,.77778],8906:[.08167,.58167,0,0,.77778],8907:[0,.69224,0,0,.77778],8908:[0,.69224,0,0,.77778],8909:[-.03598,.46402,0,0,.77778],8910:[0,.54986,0,0,.76042],8911:[0,.54986,0,0,.76042],8912:[.03517,.54986,0,0,.77778],8913:[.03517,.54986,0,0,.77778],8914:[0,.54986,0,0,.66667],8915:[0,.54986,0,0,.66667],8916:[0,.69224,0,0,.66667],8918:[.0391,.5391,0,0,.77778],8919:[.0391,.5391,0,0,.77778],8920:[.03517,.54986,0,0,1.33334],8921:[.03517,.54986,0,0,1.33334],8922:[.38569,.88569,0,0,.77778],8923:[.38569,.88569,0,0,.77778],8926:[.13667,.63667,0,0,.77778],8927:[.13667,.63667,0,0,.77778],8928:[.30274,.79383,0,0,.77778],8929:[.30274,.79383,0,0,.77778],8934:[.23222,.74111,0,0,.77778],8935:[.23222,.74111,0,0,.77778],8936:[.23222,.74111,0,0,.77778],8937:[.23222,.74111,0,0,.77778],8938:[.20576,.70576,0,0,.77778],8939:[.20576,.70576,0,0,.77778],8940:[.30274,.79383,0,0,.77778],8941:[.30274,.79383,0,0,.77778],8994:[.19444,.69224,0,0,.77778],8995:[.19444,.69224,0,0,.77778],9416:[.15559,.69224,0,0,.90222],9484:[0,.69224,0,0,.5],9488:[0,.69224,0,0,.5],9492:[0,.37788,0,0,.5],9496:[0,.37788,0,0,.5],9585:[.19444,.68889,0,0,.88889],9586:[.19444,.74111,0,0,.88889],9632:[0,.675,0,0,.77778],9633:[0,.675,0,0,.77778],9650:[0,.54986,0,0,.72222],9651:[0,.54986,0,0,.72222],9654:[.03517,.54986,0,0,.77778],9660:[0,.54986,0,0,.72222],9661:[0,.54986,0,0,.72222],9664:[.03517,.54986,0,0,.77778],9674:[.11111,.69224,0,0,.66667],9733:[.19444,.69224,0,0,.94445],10003:[0,.69224,0,0,.83334],10016:[0,.69224,0,0,.83334],10731:[.11111,.69224,0,0,.66667],10846:[.19444,.75583,0,0,.61111],10877:[.13667,.63667,0,0,.77778],10878:[.13667,.63667,0,0,.77778],10885:[.25583,.75583,0,0,.77778],10886:[.25583,.75583,0,0,.77778],10887:[.13597,.63597,0,0,.77778],10888:[.13597,.63597,0,0,.77778],10889:[.26167,.75726,0,0,.77778],10890:[.26167,.75726,0,0,.77778],10891:[.48256,.98256,0,0,.77778],10892:[.48256,.98256,0,0,.77778],10901:[.13667,.63667,0,0,.77778],10902:[.13667,.63667,0,0,.77778],10933:[.25142,.75726,0,0,.77778],10934:[.25142,.75726,0,0,.77778],10935:[.26167,.75726,0,0,.77778],10936:[.26167,.75726,0,0,.77778],10937:[.26167,.75726,0,0,.77778],10938:[.26167,.75726,0,0,.77778],10949:[.25583,.75583,0,0,.77778],10950:[.25583,.75583,0,0,.77778],10955:[.28481,.79383,0,0,.77778],10956:[.28481,.79383,0,0,.77778],57350:[.08167,.58167,0,0,.22222],57351:[.08167,.58167,0,0,.38889],57352:[.08167,.58167,0,0,.77778],57353:[0,.43056,.04028,0,.66667],57356:[.25142,.75726,0,0,.77778],57357:[.25142,.75726,0,0,.77778],57358:[.41951,.91951,0,0,.77778],57359:[.30274,.79383,0,0,.77778],57360:[.30274,.79383,0,0,.77778],57361:[.41951,.91951,0,0,.77778],57366:[.25142,.75726,0,0,.77778],57367:[.25142,.75726,0,0,.77778],57368:[.25142,.75726,0,0,.77778],57369:[.25142,.75726,0,0,.77778],57370:[.13597,.63597,0,0,.77778],57371:[.13597,.63597,0,0,.77778]},"Caligraphic-Regular":{32:[0,0,0,0,.25],65:[0,.68333,0,.19445,.79847],66:[0,.68333,.03041,.13889,.65681],67:[0,.68333,.05834,.13889,.52653],68:[0,.68333,.02778,.08334,.77139],69:[0,.68333,.08944,.11111,.52778],70:[0,.68333,.09931,.11111,.71875],71:[.09722,.68333,.0593,.11111,.59487],72:[0,.68333,.00965,.11111,.84452],73:[0,.68333,.07382,0,.54452],74:[.09722,.68333,.18472,.16667,.67778],75:[0,.68333,.01445,.05556,.76195],76:[0,.68333,0,.13889,.68972],77:[0,.68333,0,.13889,1.2009],78:[0,.68333,.14736,.08334,.82049],79:[0,.68333,.02778,.11111,.79611],80:[0,.68333,.08222,.08334,.69556],81:[.09722,.68333,0,.11111,.81667],82:[0,.68333,0,.08334,.8475],83:[0,.68333,.075,.13889,.60556],84:[0,.68333,.25417,0,.54464],85:[0,.68333,.09931,.08334,.62583],86:[0,.68333,.08222,0,.61278],87:[0,.68333,.08222,.08334,.98778],88:[0,.68333,.14643,.13889,.7133],89:[.09722,.68333,.08222,.08334,.66834],90:[0,.68333,.07944,.13889,.72473],160:[0,0,0,0,.25]},"Fraktur-Regular":{32:[0,0,0,0,.25],33:[0,.69141,0,0,.29574],34:[0,.69141,0,0,.21471],38:[0,.69141,0,0,.73786],39:[0,.69141,0,0,.21201],40:[.24982,.74947,0,0,.38865],41:[.24982,.74947,0,0,.38865],42:[0,.62119,0,0,.27764],43:[.08319,.58283,0,0,.75623],44:[0,.10803,0,0,.27764],45:[.08319,.58283,0,0,.75623],46:[0,.10803,0,0,.27764],47:[.24982,.74947,0,0,.50181],48:[0,.47534,0,0,.50181],49:[0,.47534,0,0,.50181],50:[0,.47534,0,0,.50181],51:[.18906,.47534,0,0,.50181],52:[.18906,.47534,0,0,.50181],53:[.18906,.47534,0,0,.50181],54:[0,.69141,0,0,.50181],55:[.18906,.47534,0,0,.50181],56:[0,.69141,0,0,.50181],57:[.18906,.47534,0,0,.50181],58:[0,.47534,0,0,.21606],59:[.12604,.47534,0,0,.21606],61:[-.13099,.36866,0,0,.75623],63:[0,.69141,0,0,.36245],65:[0,.69141,0,0,.7176],66:[0,.69141,0,0,.88397],67:[0,.69141,0,0,.61254],68:[0,.69141,0,0,.83158],69:[0,.69141,0,0,.66278],70:[.12604,.69141,0,0,.61119],71:[0,.69141,0,0,.78539],72:[.06302,.69141,0,0,.7203],73:[0,.69141,0,0,.55448],74:[.12604,.69141,0,0,.55231],75:[0,.69141,0,0,.66845],76:[0,.69141,0,0,.66602],77:[0,.69141,0,0,1.04953],78:[0,.69141,0,0,.83212],79:[0,.69141,0,0,.82699],80:[.18906,.69141,0,0,.82753],81:[.03781,.69141,0,0,.82699],82:[0,.69141,0,0,.82807],83:[0,.69141,0,0,.82861],84:[0,.69141,0,0,.66899],85:[0,.69141,0,0,.64576],86:[0,.69141,0,0,.83131],87:[0,.69141,0,0,1.04602],88:[0,.69141,0,0,.71922],89:[.18906,.69141,0,0,.83293],90:[.12604,.69141,0,0,.60201],91:[.24982,.74947,0,0,.27764],93:[.24982,.74947,0,0,.27764],94:[0,.69141,0,0,.49965],97:[0,.47534,0,0,.50046],98:[0,.69141,0,0,.51315],99:[0,.47534,0,0,.38946],100:[0,.62119,0,0,.49857],101:[0,.47534,0,0,.40053],102:[.18906,.69141,0,0,.32626],103:[.18906,.47534,0,0,.5037],104:[.18906,.69141,0,0,.52126],105:[0,.69141,0,0,.27899],106:[0,.69141,0,0,.28088],107:[0,.69141,0,0,.38946],108:[0,.69141,0,0,.27953],109:[0,.47534,0,0,.76676],110:[0,.47534,0,0,.52666],111:[0,.47534,0,0,.48885],112:[.18906,.52396,0,0,.50046],113:[.18906,.47534,0,0,.48912],114:[0,.47534,0,0,.38919],115:[0,.47534,0,0,.44266],116:[0,.62119,0,0,.33301],117:[0,.47534,0,0,.5172],118:[0,.52396,0,0,.5118],119:[0,.52396,0,0,.77351],120:[.18906,.47534,0,0,.38865],121:[.18906,.47534,0,0,.49884],122:[.18906,.47534,0,0,.39054],160:[0,0,0,0,.25],8216:[0,.69141,0,0,.21471],8217:[0,.69141,0,0,.21471],58112:[0,.62119,0,0,.49749],58113:[0,.62119,0,0,.4983],58114:[.18906,.69141,0,0,.33328],58115:[.18906,.69141,0,0,.32923],58116:[.18906,.47534,0,0,.50343],58117:[0,.69141,0,0,.33301],58118:[0,.62119,0,0,.33409],58119:[0,.47534,0,0,.50073]},"Main-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.35],34:[0,.69444,0,0,.60278],35:[.19444,.69444,0,0,.95833],36:[.05556,.75,0,0,.575],37:[.05556,.75,0,0,.95833],38:[0,.69444,0,0,.89444],39:[0,.69444,0,0,.31944],40:[.25,.75,0,0,.44722],41:[.25,.75,0,0,.44722],42:[0,.75,0,0,.575],43:[.13333,.63333,0,0,.89444],44:[.19444,.15556,0,0,.31944],45:[0,.44444,0,0,.38333],46:[0,.15556,0,0,.31944],47:[.25,.75,0,0,.575],48:[0,.64444,0,0,.575],49:[0,.64444,0,0,.575],50:[0,.64444,0,0,.575],51:[0,.64444,0,0,.575],52:[0,.64444,0,0,.575],53:[0,.64444,0,0,.575],54:[0,.64444,0,0,.575],55:[0,.64444,0,0,.575],56:[0,.64444,0,0,.575],57:[0,.64444,0,0,.575],58:[0,.44444,0,0,.31944],59:[.19444,.44444,0,0,.31944],60:[.08556,.58556,0,0,.89444],61:[-.10889,.39111,0,0,.89444],62:[.08556,.58556,0,0,.89444],63:[0,.69444,0,0,.54305],64:[0,.69444,0,0,.89444],65:[0,.68611,0,0,.86944],66:[0,.68611,0,0,.81805],67:[0,.68611,0,0,.83055],68:[0,.68611,0,0,.88194],69:[0,.68611,0,0,.75555],70:[0,.68611,0,0,.72361],71:[0,.68611,0,0,.90416],72:[0,.68611,0,0,.9],73:[0,.68611,0,0,.43611],74:[0,.68611,0,0,.59444],75:[0,.68611,0,0,.90138],76:[0,.68611,0,0,.69166],77:[0,.68611,0,0,1.09166],78:[0,.68611,0,0,.9],79:[0,.68611,0,0,.86388],80:[0,.68611,0,0,.78611],81:[.19444,.68611,0,0,.86388],82:[0,.68611,0,0,.8625],83:[0,.68611,0,0,.63889],84:[0,.68611,0,0,.8],85:[0,.68611,0,0,.88472],86:[0,.68611,.01597,0,.86944],87:[0,.68611,.01597,0,1.18888],88:[0,.68611,0,0,.86944],89:[0,.68611,.02875,0,.86944],90:[0,.68611,0,0,.70277],91:[.25,.75,0,0,.31944],92:[.25,.75,0,0,.575],93:[.25,.75,0,0,.31944],94:[0,.69444,0,0,.575],95:[.31,.13444,.03194,0,.575],97:[0,.44444,0,0,.55902],98:[0,.69444,0,0,.63889],99:[0,.44444,0,0,.51111],100:[0,.69444,0,0,.63889],101:[0,.44444,0,0,.52708],102:[0,.69444,.10903,0,.35139],103:[.19444,.44444,.01597,0,.575],104:[0,.69444,0,0,.63889],105:[0,.69444,0,0,.31944],106:[.19444,.69444,0,0,.35139],107:[0,.69444,0,0,.60694],108:[0,.69444,0,0,.31944],109:[0,.44444,0,0,.95833],110:[0,.44444,0,0,.63889],111:[0,.44444,0,0,.575],112:[.19444,.44444,0,0,.63889],113:[.19444,.44444,0,0,.60694],114:[0,.44444,0,0,.47361],115:[0,.44444,0,0,.45361],116:[0,.63492,0,0,.44722],117:[0,.44444,0,0,.63889],118:[0,.44444,.01597,0,.60694],119:[0,.44444,.01597,0,.83055],120:[0,.44444,0,0,.60694],121:[.19444,.44444,.01597,0,.60694],122:[0,.44444,0,0,.51111],123:[.25,.75,0,0,.575],124:[.25,.75,0,0,.31944],125:[.25,.75,0,0,.575],126:[.35,.34444,0,0,.575],160:[0,0,0,0,.25],163:[0,.69444,0,0,.86853],168:[0,.69444,0,0,.575],172:[0,.44444,0,0,.76666],176:[0,.69444,0,0,.86944],177:[.13333,.63333,0,0,.89444],184:[.17014,0,0,0,.51111],198:[0,.68611,0,0,1.04166],215:[.13333,.63333,0,0,.89444],216:[.04861,.73472,0,0,.89444],223:[0,.69444,0,0,.59722],230:[0,.44444,0,0,.83055],247:[.13333,.63333,0,0,.89444],248:[.09722,.54167,0,0,.575],305:[0,.44444,0,0,.31944],338:[0,.68611,0,0,1.16944],339:[0,.44444,0,0,.89444],567:[.19444,.44444,0,0,.35139],710:[0,.69444,0,0,.575],711:[0,.63194,0,0,.575],713:[0,.59611,0,0,.575],714:[0,.69444,0,0,.575],715:[0,.69444,0,0,.575],728:[0,.69444,0,0,.575],729:[0,.69444,0,0,.31944],730:[0,.69444,0,0,.86944],732:[0,.69444,0,0,.575],733:[0,.69444,0,0,.575],915:[0,.68611,0,0,.69166],916:[0,.68611,0,0,.95833],920:[0,.68611,0,0,.89444],923:[0,.68611,0,0,.80555],926:[0,.68611,0,0,.76666],928:[0,.68611,0,0,.9],931:[0,.68611,0,0,.83055],933:[0,.68611,0,0,.89444],934:[0,.68611,0,0,.83055],936:[0,.68611,0,0,.89444],937:[0,.68611,0,0,.83055],8211:[0,.44444,.03194,0,.575],8212:[0,.44444,.03194,0,1.14999],8216:[0,.69444,0,0,.31944],8217:[0,.69444,0,0,.31944],8220:[0,.69444,0,0,.60278],8221:[0,.69444,0,0,.60278],8224:[.19444,.69444,0,0,.51111],8225:[.19444,.69444,0,0,.51111],8242:[0,.55556,0,0,.34444],8407:[0,.72444,.15486,0,.575],8463:[0,.69444,0,0,.66759],8465:[0,.69444,0,0,.83055],8467:[0,.69444,0,0,.47361],8472:[.19444,.44444,0,0,.74027],8476:[0,.69444,0,0,.83055],8501:[0,.69444,0,0,.70277],8592:[-.10889,.39111,0,0,1.14999],8593:[.19444,.69444,0,0,.575],8594:[-.10889,.39111,0,0,1.14999],8595:[.19444,.69444,0,0,.575],8596:[-.10889,.39111,0,0,1.14999],8597:[.25,.75,0,0,.575],8598:[.19444,.69444,0,0,1.14999],8599:[.19444,.69444,0,0,1.14999],8600:[.19444,.69444,0,0,1.14999],8601:[.19444,.69444,0,0,1.14999],8636:[-.10889,.39111,0,0,1.14999],8637:[-.10889,.39111,0,0,1.14999],8640:[-.10889,.39111,0,0,1.14999],8641:[-.10889,.39111,0,0,1.14999],8656:[-.10889,.39111,0,0,1.14999],8657:[.19444,.69444,0,0,.70277],8658:[-.10889,.39111,0,0,1.14999],8659:[.19444,.69444,0,0,.70277],8660:[-.10889,.39111,0,0,1.14999],8661:[.25,.75,0,0,.70277],8704:[0,.69444,0,0,.63889],8706:[0,.69444,.06389,0,.62847],8707:[0,.69444,0,0,.63889],8709:[.05556,.75,0,0,.575],8711:[0,.68611,0,0,.95833],8712:[.08556,.58556,0,0,.76666],8715:[.08556,.58556,0,0,.76666],8722:[.13333,.63333,0,0,.89444],8723:[.13333,.63333,0,0,.89444],8725:[.25,.75,0,0,.575],8726:[.25,.75,0,0,.575],8727:[-.02778,.47222,0,0,.575],8728:[-.02639,.47361,0,0,.575],8729:[-.02639,.47361,0,0,.575],8730:[.18,.82,0,0,.95833],8733:[0,.44444,0,0,.89444],8734:[0,.44444,0,0,1.14999],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.31944],8741:[.25,.75,0,0,.575],8743:[0,.55556,0,0,.76666],8744:[0,.55556,0,0,.76666],8745:[0,.55556,0,0,.76666],8746:[0,.55556,0,0,.76666],8747:[.19444,.69444,.12778,0,.56875],8764:[-.10889,.39111,0,0,.89444],8768:[.19444,.69444,0,0,.31944],8771:[.00222,.50222,0,0,.89444],8773:[.027,.638,0,0,.894],8776:[.02444,.52444,0,0,.89444],8781:[.00222,.50222,0,0,.89444],8801:[.00222,.50222,0,0,.89444],8804:[.19667,.69667,0,0,.89444],8805:[.19667,.69667,0,0,.89444],8810:[.08556,.58556,0,0,1.14999],8811:[.08556,.58556,0,0,1.14999],8826:[.08556,.58556,0,0,.89444],8827:[.08556,.58556,0,0,.89444],8834:[.08556,.58556,0,0,.89444],8835:[.08556,.58556,0,0,.89444],8838:[.19667,.69667,0,0,.89444],8839:[.19667,.69667,0,0,.89444],8846:[0,.55556,0,0,.76666],8849:[.19667,.69667,0,0,.89444],8850:[.19667,.69667,0,0,.89444],8851:[0,.55556,0,0,.76666],8852:[0,.55556,0,0,.76666],8853:[.13333,.63333,0,0,.89444],8854:[.13333,.63333,0,0,.89444],8855:[.13333,.63333,0,0,.89444],8856:[.13333,.63333,0,0,.89444],8857:[.13333,.63333,0,0,.89444],8866:[0,.69444,0,0,.70277],8867:[0,.69444,0,0,.70277],8868:[0,.69444,0,0,.89444],8869:[0,.69444,0,0,.89444],8900:[-.02639,.47361,0,0,.575],8901:[-.02639,.47361,0,0,.31944],8902:[-.02778,.47222,0,0,.575],8968:[.25,.75,0,0,.51111],8969:[.25,.75,0,0,.51111],8970:[.25,.75,0,0,.51111],8971:[.25,.75,0,0,.51111],8994:[-.13889,.36111,0,0,1.14999],8995:[-.13889,.36111,0,0,1.14999],9651:[.19444,.69444,0,0,1.02222],9657:[-.02778,.47222,0,0,.575],9661:[.19444,.69444,0,0,1.02222],9667:[-.02778,.47222,0,0,.575],9711:[.19444,.69444,0,0,1.14999],9824:[.12963,.69444,0,0,.89444],9825:[.12963,.69444,0,0,.89444],9826:[.12963,.69444,0,0,.89444],9827:[.12963,.69444,0,0,.89444],9837:[0,.75,0,0,.44722],9838:[.19444,.69444,0,0,.44722],9839:[.19444,.69444,0,0,.44722],10216:[.25,.75,0,0,.44722],10217:[.25,.75,0,0,.44722],10815:[0,.68611,0,0,.9],10927:[.19667,.69667,0,0,.89444],10928:[.19667,.69667,0,0,.89444],57376:[.19444,.69444,0,0,0]},"Main-BoldItalic":{32:[0,0,0,0,.25],33:[0,.69444,.11417,0,.38611],34:[0,.69444,.07939,0,.62055],35:[.19444,.69444,.06833,0,.94444],37:[.05556,.75,.12861,0,.94444],38:[0,.69444,.08528,0,.88555],39:[0,.69444,.12945,0,.35555],40:[.25,.75,.15806,0,.47333],41:[.25,.75,.03306,0,.47333],42:[0,.75,.14333,0,.59111],43:[.10333,.60333,.03306,0,.88555],44:[.19444,.14722,0,0,.35555],45:[0,.44444,.02611,0,.41444],46:[0,.14722,0,0,.35555],47:[.25,.75,.15806,0,.59111],48:[0,.64444,.13167,0,.59111],49:[0,.64444,.13167,0,.59111],50:[0,.64444,.13167,0,.59111],51:[0,.64444,.13167,0,.59111],52:[.19444,.64444,.13167,0,.59111],53:[0,.64444,.13167,0,.59111],54:[0,.64444,.13167,0,.59111],55:[.19444,.64444,.13167,0,.59111],56:[0,.64444,.13167,0,.59111],57:[0,.64444,.13167,0,.59111],58:[0,.44444,.06695,0,.35555],59:[.19444,.44444,.06695,0,.35555],61:[-.10889,.39111,.06833,0,.88555],63:[0,.69444,.11472,0,.59111],64:[0,.69444,.09208,0,.88555],65:[0,.68611,0,0,.86555],66:[0,.68611,.0992,0,.81666],67:[0,.68611,.14208,0,.82666],68:[0,.68611,.09062,0,.87555],69:[0,.68611,.11431,0,.75666],70:[0,.68611,.12903,0,.72722],71:[0,.68611,.07347,0,.89527],72:[0,.68611,.17208,0,.8961],73:[0,.68611,.15681,0,.47166],74:[0,.68611,.145,0,.61055],75:[0,.68611,.14208,0,.89499],76:[0,.68611,0,0,.69777],77:[0,.68611,.17208,0,1.07277],78:[0,.68611,.17208,0,.8961],79:[0,.68611,.09062,0,.85499],80:[0,.68611,.0992,0,.78721],81:[.19444,.68611,.09062,0,.85499],82:[0,.68611,.02559,0,.85944],83:[0,.68611,.11264,0,.64999],84:[0,.68611,.12903,0,.7961],85:[0,.68611,.17208,0,.88083],86:[0,.68611,.18625,0,.86555],87:[0,.68611,.18625,0,1.15999],88:[0,.68611,.15681,0,.86555],89:[0,.68611,.19803,0,.86555],90:[0,.68611,.14208,0,.70888],91:[.25,.75,.1875,0,.35611],93:[.25,.75,.09972,0,.35611],94:[0,.69444,.06709,0,.59111],95:[.31,.13444,.09811,0,.59111],97:[0,.44444,.09426,0,.59111],98:[0,.69444,.07861,0,.53222],99:[0,.44444,.05222,0,.53222],100:[0,.69444,.10861,0,.59111],101:[0,.44444,.085,0,.53222],102:[.19444,.69444,.21778,0,.4],103:[.19444,.44444,.105,0,.53222],104:[0,.69444,.09426,0,.59111],105:[0,.69326,.11387,0,.35555],106:[.19444,.69326,.1672,0,.35555],107:[0,.69444,.11111,0,.53222],108:[0,.69444,.10861,0,.29666],109:[0,.44444,.09426,0,.94444],110:[0,.44444,.09426,0,.64999],111:[0,.44444,.07861,0,.59111],112:[.19444,.44444,.07861,0,.59111],113:[.19444,.44444,.105,0,.53222],114:[0,.44444,.11111,0,.50167],115:[0,.44444,.08167,0,.48694],116:[0,.63492,.09639,0,.385],117:[0,.44444,.09426,0,.62055],118:[0,.44444,.11111,0,.53222],119:[0,.44444,.11111,0,.76777],120:[0,.44444,.12583,0,.56055],121:[.19444,.44444,.105,0,.56166],122:[0,.44444,.13889,0,.49055],126:[.35,.34444,.11472,0,.59111],160:[0,0,0,0,.25],168:[0,.69444,.11473,0,.59111],176:[0,.69444,0,0,.94888],184:[.17014,0,0,0,.53222],198:[0,.68611,.11431,0,1.02277],216:[.04861,.73472,.09062,0,.88555],223:[.19444,.69444,.09736,0,.665],230:[0,.44444,.085,0,.82666],248:[.09722,.54167,.09458,0,.59111],305:[0,.44444,.09426,0,.35555],338:[0,.68611,.11431,0,1.14054],339:[0,.44444,.085,0,.82666],567:[.19444,.44444,.04611,0,.385],710:[0,.69444,.06709,0,.59111],711:[0,.63194,.08271,0,.59111],713:[0,.59444,.10444,0,.59111],714:[0,.69444,.08528,0,.59111],715:[0,.69444,0,0,.59111],728:[0,.69444,.10333,0,.59111],729:[0,.69444,.12945,0,.35555],730:[0,.69444,0,0,.94888],732:[0,.69444,.11472,0,.59111],733:[0,.69444,.11472,0,.59111],915:[0,.68611,.12903,0,.69777],916:[0,.68611,0,0,.94444],920:[0,.68611,.09062,0,.88555],923:[0,.68611,0,0,.80666],926:[0,.68611,.15092,0,.76777],928:[0,.68611,.17208,0,.8961],931:[0,.68611,.11431,0,.82666],933:[0,.68611,.10778,0,.88555],934:[0,.68611,.05632,0,.82666],936:[0,.68611,.10778,0,.88555],937:[0,.68611,.0992,0,.82666],8211:[0,.44444,.09811,0,.59111],8212:[0,.44444,.09811,0,1.18221],8216:[0,.69444,.12945,0,.35555],8217:[0,.69444,.12945,0,.35555],8220:[0,.69444,.16772,0,.62055],8221:[0,.69444,.07939,0,.62055]},"Main-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.12417,0,.30667],34:[0,.69444,.06961,0,.51444],35:[.19444,.69444,.06616,0,.81777],37:[.05556,.75,.13639,0,.81777],38:[0,.69444,.09694,0,.76666],39:[0,.69444,.12417,0,.30667],40:[.25,.75,.16194,0,.40889],41:[.25,.75,.03694,0,.40889],42:[0,.75,.14917,0,.51111],43:[.05667,.56167,.03694,0,.76666],44:[.19444,.10556,0,0,.30667],45:[0,.43056,.02826,0,.35778],46:[0,.10556,0,0,.30667],47:[.25,.75,.16194,0,.51111],48:[0,.64444,.13556,0,.51111],49:[0,.64444,.13556,0,.51111],50:[0,.64444,.13556,0,.51111],51:[0,.64444,.13556,0,.51111],52:[.19444,.64444,.13556,0,.51111],53:[0,.64444,.13556,0,.51111],54:[0,.64444,.13556,0,.51111],55:[.19444,.64444,.13556,0,.51111],56:[0,.64444,.13556,0,.51111],57:[0,.64444,.13556,0,.51111],58:[0,.43056,.0582,0,.30667],59:[.19444,.43056,.0582,0,.30667],61:[-.13313,.36687,.06616,0,.76666],63:[0,.69444,.1225,0,.51111],64:[0,.69444,.09597,0,.76666],65:[0,.68333,0,0,.74333],66:[0,.68333,.10257,0,.70389],67:[0,.68333,.14528,0,.71555],68:[0,.68333,.09403,0,.755],69:[0,.68333,.12028,0,.67833],70:[0,.68333,.13305,0,.65277],71:[0,.68333,.08722,0,.77361],72:[0,.68333,.16389,0,.74333],73:[0,.68333,.15806,0,.38555],74:[0,.68333,.14028,0,.525],75:[0,.68333,.14528,0,.76888],76:[0,.68333,0,0,.62722],77:[0,.68333,.16389,0,.89666],78:[0,.68333,.16389,0,.74333],79:[0,.68333,.09403,0,.76666],80:[0,.68333,.10257,0,.67833],81:[.19444,.68333,.09403,0,.76666],82:[0,.68333,.03868,0,.72944],83:[0,.68333,.11972,0,.56222],84:[0,.68333,.13305,0,.71555],85:[0,.68333,.16389,0,.74333],86:[0,.68333,.18361,0,.74333],87:[0,.68333,.18361,0,.99888],88:[0,.68333,.15806,0,.74333],89:[0,.68333,.19383,0,.74333],90:[0,.68333,.14528,0,.61333],91:[.25,.75,.1875,0,.30667],93:[.25,.75,.10528,0,.30667],94:[0,.69444,.06646,0,.51111],95:[.31,.12056,.09208,0,.51111],97:[0,.43056,.07671,0,.51111],98:[0,.69444,.06312,0,.46],99:[0,.43056,.05653,0,.46],100:[0,.69444,.10333,0,.51111],101:[0,.43056,.07514,0,.46],102:[.19444,.69444,.21194,0,.30667],103:[.19444,.43056,.08847,0,.46],104:[0,.69444,.07671,0,.51111],105:[0,.65536,.1019,0,.30667],106:[.19444,.65536,.14467,0,.30667],107:[0,.69444,.10764,0,.46],108:[0,.69444,.10333,0,.25555],109:[0,.43056,.07671,0,.81777],110:[0,.43056,.07671,0,.56222],111:[0,.43056,.06312,0,.51111],112:[.19444,.43056,.06312,0,.51111],113:[.19444,.43056,.08847,0,.46],114:[0,.43056,.10764,0,.42166],115:[0,.43056,.08208,0,.40889],116:[0,.61508,.09486,0,.33222],117:[0,.43056,.07671,0,.53666],118:[0,.43056,.10764,0,.46],119:[0,.43056,.10764,0,.66444],120:[0,.43056,.12042,0,.46389],121:[.19444,.43056,.08847,0,.48555],122:[0,.43056,.12292,0,.40889],126:[.35,.31786,.11585,0,.51111],160:[0,0,0,0,.25],168:[0,.66786,.10474,0,.51111],176:[0,.69444,0,0,.83129],184:[.17014,0,0,0,.46],198:[0,.68333,.12028,0,.88277],216:[.04861,.73194,.09403,0,.76666],223:[.19444,.69444,.10514,0,.53666],230:[0,.43056,.07514,0,.71555],248:[.09722,.52778,.09194,0,.51111],338:[0,.68333,.12028,0,.98499],339:[0,.43056,.07514,0,.71555],710:[0,.69444,.06646,0,.51111],711:[0,.62847,.08295,0,.51111],713:[0,.56167,.10333,0,.51111],714:[0,.69444,.09694,0,.51111],715:[0,.69444,0,0,.51111],728:[0,.69444,.10806,0,.51111],729:[0,.66786,.11752,0,.30667],730:[0,.69444,0,0,.83129],732:[0,.66786,.11585,0,.51111],733:[0,.69444,.1225,0,.51111],915:[0,.68333,.13305,0,.62722],916:[0,.68333,0,0,.81777],920:[0,.68333,.09403,0,.76666],923:[0,.68333,0,0,.69222],926:[0,.68333,.15294,0,.66444],928:[0,.68333,.16389,0,.74333],931:[0,.68333,.12028,0,.71555],933:[0,.68333,.11111,0,.76666],934:[0,.68333,.05986,0,.71555],936:[0,.68333,.11111,0,.76666],937:[0,.68333,.10257,0,.71555],8211:[0,.43056,.09208,0,.51111],8212:[0,.43056,.09208,0,1.02222],8216:[0,.69444,.12417,0,.30667],8217:[0,.69444,.12417,0,.30667],8220:[0,.69444,.1685,0,.51444],8221:[0,.69444,.06961,0,.51444],8463:[0,.68889,0,0,.54028]},"Main-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.27778],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.77778],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.19444,.10556,0,0,.27778],45:[0,.43056,0,0,.33333],46:[0,.10556,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.64444,0,0,.5],49:[0,.64444,0,0,.5],50:[0,.64444,0,0,.5],51:[0,.64444,0,0,.5],52:[0,.64444,0,0,.5],53:[0,.64444,0,0,.5],54:[0,.64444,0,0,.5],55:[0,.64444,0,0,.5],56:[0,.64444,0,0,.5],57:[0,.64444,0,0,.5],58:[0,.43056,0,0,.27778],59:[.19444,.43056,0,0,.27778],60:[.0391,.5391,0,0,.77778],61:[-.13313,.36687,0,0,.77778],62:[.0391,.5391,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.77778],65:[0,.68333,0,0,.75],66:[0,.68333,0,0,.70834],67:[0,.68333,0,0,.72222],68:[0,.68333,0,0,.76389],69:[0,.68333,0,0,.68056],70:[0,.68333,0,0,.65278],71:[0,.68333,0,0,.78472],72:[0,.68333,0,0,.75],73:[0,.68333,0,0,.36111],74:[0,.68333,0,0,.51389],75:[0,.68333,0,0,.77778],76:[0,.68333,0,0,.625],77:[0,.68333,0,0,.91667],78:[0,.68333,0,0,.75],79:[0,.68333,0,0,.77778],80:[0,.68333,0,0,.68056],81:[.19444,.68333,0,0,.77778],82:[0,.68333,0,0,.73611],83:[0,.68333,0,0,.55556],84:[0,.68333,0,0,.72222],85:[0,.68333,0,0,.75],86:[0,.68333,.01389,0,.75],87:[0,.68333,.01389,0,1.02778],88:[0,.68333,0,0,.75],89:[0,.68333,.025,0,.75],90:[0,.68333,0,0,.61111],91:[.25,.75,0,0,.27778],92:[.25,.75,0,0,.5],93:[.25,.75,0,0,.27778],94:[0,.69444,0,0,.5],95:[.31,.12056,.02778,0,.5],97:[0,.43056,0,0,.5],98:[0,.69444,0,0,.55556],99:[0,.43056,0,0,.44445],100:[0,.69444,0,0,.55556],101:[0,.43056,0,0,.44445],102:[0,.69444,.07778,0,.30556],103:[.19444,.43056,.01389,0,.5],104:[0,.69444,0,0,.55556],105:[0,.66786,0,0,.27778],106:[.19444,.66786,0,0,.30556],107:[0,.69444,0,0,.52778],108:[0,.69444,0,0,.27778],109:[0,.43056,0,0,.83334],110:[0,.43056,0,0,.55556],111:[0,.43056,0,0,.5],112:[.19444,.43056,0,0,.55556],113:[.19444,.43056,0,0,.52778],114:[0,.43056,0,0,.39167],115:[0,.43056,0,0,.39445],116:[0,.61508,0,0,.38889],117:[0,.43056,0,0,.55556],118:[0,.43056,.01389,0,.52778],119:[0,.43056,.01389,0,.72222],120:[0,.43056,0,0,.52778],121:[.19444,.43056,.01389,0,.52778],122:[0,.43056,0,0,.44445],123:[.25,.75,0,0,.5],124:[.25,.75,0,0,.27778],125:[.25,.75,0,0,.5],126:[.35,.31786,0,0,.5],160:[0,0,0,0,.25],163:[0,.69444,0,0,.76909],167:[.19444,.69444,0,0,.44445],168:[0,.66786,0,0,.5],172:[0,.43056,0,0,.66667],176:[0,.69444,0,0,.75],177:[.08333,.58333,0,0,.77778],182:[.19444,.69444,0,0,.61111],184:[.17014,0,0,0,.44445],198:[0,.68333,0,0,.90278],215:[.08333,.58333,0,0,.77778],216:[.04861,.73194,0,0,.77778],223:[0,.69444,0,0,.5],230:[0,.43056,0,0,.72222],247:[.08333,.58333,0,0,.77778],248:[.09722,.52778,0,0,.5],305:[0,.43056,0,0,.27778],338:[0,.68333,0,0,1.01389],339:[0,.43056,0,0,.77778],567:[.19444,.43056,0,0,.30556],710:[0,.69444,0,0,.5],711:[0,.62847,0,0,.5],713:[0,.56778,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.66786,0,0,.27778],730:[0,.69444,0,0,.75],732:[0,.66786,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.68333,0,0,.625],916:[0,.68333,0,0,.83334],920:[0,.68333,0,0,.77778],923:[0,.68333,0,0,.69445],926:[0,.68333,0,0,.66667],928:[0,.68333,0,0,.75],931:[0,.68333,0,0,.72222],933:[0,.68333,0,0,.77778],934:[0,.68333,0,0,.72222],936:[0,.68333,0,0,.77778],937:[0,.68333,0,0,.72222],8211:[0,.43056,.02778,0,.5],8212:[0,.43056,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5],8224:[.19444,.69444,0,0,.44445],8225:[.19444,.69444,0,0,.44445],8230:[0,.123,0,0,1.172],8242:[0,.55556,0,0,.275],8407:[0,.71444,.15382,0,.5],8463:[0,.68889,0,0,.54028],8465:[0,.69444,0,0,.72222],8467:[0,.69444,0,.11111,.41667],8472:[.19444,.43056,0,.11111,.63646],8476:[0,.69444,0,0,.72222],8501:[0,.69444,0,0,.61111],8592:[-.13313,.36687,0,0,1],8593:[.19444,.69444,0,0,.5],8594:[-.13313,.36687,0,0,1],8595:[.19444,.69444,0,0,.5],8596:[-.13313,.36687,0,0,1],8597:[.25,.75,0,0,.5],8598:[.19444,.69444,0,0,1],8599:[.19444,.69444,0,0,1],8600:[.19444,.69444,0,0,1],8601:[.19444,.69444,0,0,1],8614:[.011,.511,0,0,1],8617:[.011,.511,0,0,1.126],8618:[.011,.511,0,0,1.126],8636:[-.13313,.36687,0,0,1],8637:[-.13313,.36687,0,0,1],8640:[-.13313,.36687,0,0,1],8641:[-.13313,.36687,0,0,1],8652:[.011,.671,0,0,1],8656:[-.13313,.36687,0,0,1],8657:[.19444,.69444,0,0,.61111],8658:[-.13313,.36687,0,0,1],8659:[.19444,.69444,0,0,.61111],8660:[-.13313,.36687,0,0,1],8661:[.25,.75,0,0,.61111],8704:[0,.69444,0,0,.55556],8706:[0,.69444,.05556,.08334,.5309],8707:[0,.69444,0,0,.55556],8709:[.05556,.75,0,0,.5],8711:[0,.68333,0,0,.83334],8712:[.0391,.5391,0,0,.66667],8715:[.0391,.5391,0,0,.66667],8722:[.08333,.58333,0,0,.77778],8723:[.08333,.58333,0,0,.77778],8725:[.25,.75,0,0,.5],8726:[.25,.75,0,0,.5],8727:[-.03472,.46528,0,0,.5],8728:[-.05555,.44445,0,0,.5],8729:[-.05555,.44445,0,0,.5],8730:[.2,.8,0,0,.83334],8733:[0,.43056,0,0,.77778],8734:[0,.43056,0,0,1],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.27778],8741:[.25,.75,0,0,.5],8743:[0,.55556,0,0,.66667],8744:[0,.55556,0,0,.66667],8745:[0,.55556,0,0,.66667],8746:[0,.55556,0,0,.66667],8747:[.19444,.69444,.11111,0,.41667],8764:[-.13313,.36687,0,0,.77778],8768:[.19444,.69444,0,0,.27778],8771:[-.03625,.46375,0,0,.77778],8773:[-.022,.589,0,0,.778],8776:[-.01688,.48312,0,0,.77778],8781:[-.03625,.46375,0,0,.77778],8784:[-.133,.673,0,0,.778],8801:[-.03625,.46375,0,0,.77778],8804:[.13597,.63597,0,0,.77778],8805:[.13597,.63597,0,0,.77778],8810:[.0391,.5391,0,0,1],8811:[.0391,.5391,0,0,1],8826:[.0391,.5391,0,0,.77778],8827:[.0391,.5391,0,0,.77778],8834:[.0391,.5391,0,0,.77778],8835:[.0391,.5391,0,0,.77778],8838:[.13597,.63597,0,0,.77778],8839:[.13597,.63597,0,0,.77778],8846:[0,.55556,0,0,.66667],8849:[.13597,.63597,0,0,.77778],8850:[.13597,.63597,0,0,.77778],8851:[0,.55556,0,0,.66667],8852:[0,.55556,0,0,.66667],8853:[.08333,.58333,0,0,.77778],8854:[.08333,.58333,0,0,.77778],8855:[.08333,.58333,0,0,.77778],8856:[.08333,.58333,0,0,.77778],8857:[.08333,.58333,0,0,.77778],8866:[0,.69444,0,0,.61111],8867:[0,.69444,0,0,.61111],8868:[0,.69444,0,0,.77778],8869:[0,.69444,0,0,.77778],8872:[.249,.75,0,0,.867],8900:[-.05555,.44445,0,0,.5],8901:[-.05555,.44445,0,0,.27778],8902:[-.03472,.46528,0,0,.5],8904:[.005,.505,0,0,.9],8942:[.03,.903,0,0,.278],8943:[-.19,.313,0,0,1.172],8945:[-.1,.823,0,0,1.282],8968:[.25,.75,0,0,.44445],8969:[.25,.75,0,0,.44445],8970:[.25,.75,0,0,.44445],8971:[.25,.75,0,0,.44445],8994:[-.14236,.35764,0,0,1],8995:[-.14236,.35764,0,0,1],9136:[.244,.744,0,0,.412],9137:[.244,.745,0,0,.412],9651:[.19444,.69444,0,0,.88889],9657:[-.03472,.46528,0,0,.5],9661:[.19444,.69444,0,0,.88889],9667:[-.03472,.46528,0,0,.5],9711:[.19444,.69444,0,0,1],9824:[.12963,.69444,0,0,.77778],9825:[.12963,.69444,0,0,.77778],9826:[.12963,.69444,0,0,.77778],9827:[.12963,.69444,0,0,.77778],9837:[0,.75,0,0,.38889],9838:[.19444,.69444,0,0,.38889],9839:[.19444,.69444,0,0,.38889],10216:[.25,.75,0,0,.38889],10217:[.25,.75,0,0,.38889],10222:[.244,.744,0,0,.412],10223:[.244,.745,0,0,.412],10229:[.011,.511,0,0,1.609],10230:[.011,.511,0,0,1.638],10231:[.011,.511,0,0,1.859],10232:[.024,.525,0,0,1.609],10233:[.024,.525,0,0,1.638],10234:[.024,.525,0,0,1.858],10236:[.011,.511,0,0,1.638],10815:[0,.68333,0,0,.75],10927:[.13597,.63597,0,0,.77778],10928:[.13597,.63597,0,0,.77778],57376:[.19444,.69444,0,0,0]},"Math-BoldItalic":{32:[0,0,0,0,.25],48:[0,.44444,0,0,.575],49:[0,.44444,0,0,.575],50:[0,.44444,0,0,.575],51:[.19444,.44444,0,0,.575],52:[.19444,.44444,0,0,.575],53:[.19444,.44444,0,0,.575],54:[0,.64444,0,0,.575],55:[.19444,.44444,0,0,.575],56:[0,.64444,0,0,.575],57:[.19444,.44444,0,0,.575],65:[0,.68611,0,0,.86944],66:[0,.68611,.04835,0,.8664],67:[0,.68611,.06979,0,.81694],68:[0,.68611,.03194,0,.93812],69:[0,.68611,.05451,0,.81007],70:[0,.68611,.15972,0,.68889],71:[0,.68611,0,0,.88673],72:[0,.68611,.08229,0,.98229],73:[0,.68611,.07778,0,.51111],74:[0,.68611,.10069,0,.63125],75:[0,.68611,.06979,0,.97118],76:[0,.68611,0,0,.75555],77:[0,.68611,.11424,0,1.14201],78:[0,.68611,.11424,0,.95034],79:[0,.68611,.03194,0,.83666],80:[0,.68611,.15972,0,.72309],81:[.19444,.68611,0,0,.86861],82:[0,.68611,.00421,0,.87235],83:[0,.68611,.05382,0,.69271],84:[0,.68611,.15972,0,.63663],85:[0,.68611,.11424,0,.80027],86:[0,.68611,.25555,0,.67778],87:[0,.68611,.15972,0,1.09305],88:[0,.68611,.07778,0,.94722],89:[0,.68611,.25555,0,.67458],90:[0,.68611,.06979,0,.77257],97:[0,.44444,0,0,.63287],98:[0,.69444,0,0,.52083],99:[0,.44444,0,0,.51342],100:[0,.69444,0,0,.60972],101:[0,.44444,0,0,.55361],102:[.19444,.69444,.11042,0,.56806],103:[.19444,.44444,.03704,0,.5449],104:[0,.69444,0,0,.66759],105:[0,.69326,0,0,.4048],106:[.19444,.69326,.0622,0,.47083],107:[0,.69444,.01852,0,.6037],108:[0,.69444,.0088,0,.34815],109:[0,.44444,0,0,1.0324],110:[0,.44444,0,0,.71296],111:[0,.44444,0,0,.58472],112:[.19444,.44444,0,0,.60092],113:[.19444,.44444,.03704,0,.54213],114:[0,.44444,.03194,0,.5287],115:[0,.44444,0,0,.53125],116:[0,.63492,0,0,.41528],117:[0,.44444,0,0,.68102],118:[0,.44444,.03704,0,.56666],119:[0,.44444,.02778,0,.83148],120:[0,.44444,0,0,.65903],121:[.19444,.44444,.03704,0,.59028],122:[0,.44444,.04213,0,.55509],160:[0,0,0,0,.25],915:[0,.68611,.15972,0,.65694],916:[0,.68611,0,0,.95833],920:[0,.68611,.03194,0,.86722],923:[0,.68611,0,0,.80555],926:[0,.68611,.07458,0,.84125],928:[0,.68611,.08229,0,.98229],931:[0,.68611,.05451,0,.88507],933:[0,.68611,.15972,0,.67083],934:[0,.68611,0,0,.76666],936:[0,.68611,.11653,0,.71402],937:[0,.68611,.04835,0,.8789],945:[0,.44444,0,0,.76064],946:[.19444,.69444,.03403,0,.65972],947:[.19444,.44444,.06389,0,.59003],948:[0,.69444,.03819,0,.52222],949:[0,.44444,0,0,.52882],950:[.19444,.69444,.06215,0,.50833],951:[.19444,.44444,.03704,0,.6],952:[0,.69444,.03194,0,.5618],953:[0,.44444,0,0,.41204],954:[0,.44444,0,0,.66759],955:[0,.69444,0,0,.67083],956:[.19444,.44444,0,0,.70787],957:[0,.44444,.06898,0,.57685],958:[.19444,.69444,.03021,0,.50833],959:[0,.44444,0,0,.58472],960:[0,.44444,.03704,0,.68241],961:[.19444,.44444,0,0,.6118],962:[.09722,.44444,.07917,0,.42361],963:[0,.44444,.03704,0,.68588],964:[0,.44444,.13472,0,.52083],965:[0,.44444,.03704,0,.63055],966:[.19444,.44444,0,0,.74722],967:[.19444,.44444,0,0,.71805],968:[.19444,.69444,.03704,0,.75833],969:[0,.44444,.03704,0,.71782],977:[0,.69444,0,0,.69155],981:[.19444,.69444,0,0,.7125],982:[0,.44444,.03194,0,.975],1009:[.19444,.44444,0,0,.6118],1013:[0,.44444,0,0,.48333],57649:[0,.44444,0,0,.39352],57911:[.19444,.44444,0,0,.43889]},"Math-Italic":{32:[0,0,0,0,.25],48:[0,.43056,0,0,.5],49:[0,.43056,0,0,.5],50:[0,.43056,0,0,.5],51:[.19444,.43056,0,0,.5],52:[.19444,.43056,0,0,.5],53:[.19444,.43056,0,0,.5],54:[0,.64444,0,0,.5],55:[.19444,.43056,0,0,.5],56:[0,.64444,0,0,.5],57:[.19444,.43056,0,0,.5],65:[0,.68333,0,.13889,.75],66:[0,.68333,.05017,.08334,.75851],67:[0,.68333,.07153,.08334,.71472],68:[0,.68333,.02778,.05556,.82792],69:[0,.68333,.05764,.08334,.7382],70:[0,.68333,.13889,.08334,.64306],71:[0,.68333,0,.08334,.78625],72:[0,.68333,.08125,.05556,.83125],73:[0,.68333,.07847,.11111,.43958],74:[0,.68333,.09618,.16667,.55451],75:[0,.68333,.07153,.05556,.84931],76:[0,.68333,0,.02778,.68056],77:[0,.68333,.10903,.08334,.97014],78:[0,.68333,.10903,.08334,.80347],79:[0,.68333,.02778,.08334,.76278],80:[0,.68333,.13889,.08334,.64201],81:[.19444,.68333,0,.08334,.79056],82:[0,.68333,.00773,.08334,.75929],83:[0,.68333,.05764,.08334,.6132],84:[0,.68333,.13889,.08334,.58438],85:[0,.68333,.10903,.02778,.68278],86:[0,.68333,.22222,0,.58333],87:[0,.68333,.13889,0,.94445],88:[0,.68333,.07847,.08334,.82847],89:[0,.68333,.22222,0,.58056],90:[0,.68333,.07153,.08334,.68264],97:[0,.43056,0,0,.52859],98:[0,.69444,0,0,.42917],99:[0,.43056,0,.05556,.43276],100:[0,.69444,0,.16667,.52049],101:[0,.43056,0,.05556,.46563],102:[.19444,.69444,.10764,.16667,.48959],103:[.19444,.43056,.03588,.02778,.47697],104:[0,.69444,0,0,.57616],105:[0,.65952,0,0,.34451],106:[.19444,.65952,.05724,0,.41181],107:[0,.69444,.03148,0,.5206],108:[0,.69444,.01968,.08334,.29838],109:[0,.43056,0,0,.87801],110:[0,.43056,0,0,.60023],111:[0,.43056,0,.05556,.48472],112:[.19444,.43056,0,.08334,.50313],113:[.19444,.43056,.03588,.08334,.44641],114:[0,.43056,.02778,.05556,.45116],115:[0,.43056,0,.05556,.46875],116:[0,.61508,0,.08334,.36111],117:[0,.43056,0,.02778,.57246],118:[0,.43056,.03588,.02778,.48472],119:[0,.43056,.02691,.08334,.71592],120:[0,.43056,0,.02778,.57153],121:[.19444,.43056,.03588,.05556,.49028],122:[0,.43056,.04398,.05556,.46505],160:[0,0,0,0,.25],915:[0,.68333,.13889,.08334,.61528],916:[0,.68333,0,.16667,.83334],920:[0,.68333,.02778,.08334,.76278],923:[0,.68333,0,.16667,.69445],926:[0,.68333,.07569,.08334,.74236],928:[0,.68333,.08125,.05556,.83125],931:[0,.68333,.05764,.08334,.77986],933:[0,.68333,.13889,.05556,.58333],934:[0,.68333,0,.08334,.66667],936:[0,.68333,.11,.05556,.61222],937:[0,.68333,.05017,.08334,.7724],945:[0,.43056,.0037,.02778,.6397],946:[.19444,.69444,.05278,.08334,.56563],947:[.19444,.43056,.05556,0,.51773],948:[0,.69444,.03785,.05556,.44444],949:[0,.43056,0,.08334,.46632],950:[.19444,.69444,.07378,.08334,.4375],951:[.19444,.43056,.03588,.05556,.49653],952:[0,.69444,.02778,.08334,.46944],953:[0,.43056,0,.05556,.35394],954:[0,.43056,0,0,.57616],955:[0,.69444,0,0,.58334],956:[.19444,.43056,0,.02778,.60255],957:[0,.43056,.06366,.02778,.49398],958:[.19444,.69444,.04601,.11111,.4375],959:[0,.43056,0,.05556,.48472],960:[0,.43056,.03588,0,.57003],961:[.19444,.43056,0,.08334,.51702],962:[.09722,.43056,.07986,.08334,.36285],963:[0,.43056,.03588,0,.57141],964:[0,.43056,.1132,.02778,.43715],965:[0,.43056,.03588,.02778,.54028],966:[.19444,.43056,0,.08334,.65417],967:[.19444,.43056,0,.05556,.62569],968:[.19444,.69444,.03588,.11111,.65139],969:[0,.43056,.03588,0,.62245],977:[0,.69444,0,.08334,.59144],981:[.19444,.69444,0,.08334,.59583],982:[0,.43056,.02778,0,.82813],1009:[.19444,.43056,0,.08334,.51702],1013:[0,.43056,0,.05556,.4059],57649:[0,.43056,0,.02778,.32246],57911:[.19444,.43056,0,.08334,.38403]},"SansSerif-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.36667],34:[0,.69444,0,0,.55834],35:[.19444,.69444,0,0,.91667],36:[.05556,.75,0,0,.55],37:[.05556,.75,0,0,1.02912],38:[0,.69444,0,0,.83056],39:[0,.69444,0,0,.30556],40:[.25,.75,0,0,.42778],41:[.25,.75,0,0,.42778],42:[0,.75,0,0,.55],43:[.11667,.61667,0,0,.85556],44:[.10556,.13056,0,0,.30556],45:[0,.45833,0,0,.36667],46:[0,.13056,0,0,.30556],47:[.25,.75,0,0,.55],48:[0,.69444,0,0,.55],49:[0,.69444,0,0,.55],50:[0,.69444,0,0,.55],51:[0,.69444,0,0,.55],52:[0,.69444,0,0,.55],53:[0,.69444,0,0,.55],54:[0,.69444,0,0,.55],55:[0,.69444,0,0,.55],56:[0,.69444,0,0,.55],57:[0,.69444,0,0,.55],58:[0,.45833,0,0,.30556],59:[.10556,.45833,0,0,.30556],61:[-.09375,.40625,0,0,.85556],63:[0,.69444,0,0,.51945],64:[0,.69444,0,0,.73334],65:[0,.69444,0,0,.73334],66:[0,.69444,0,0,.73334],67:[0,.69444,0,0,.70278],68:[0,.69444,0,0,.79445],69:[0,.69444,0,0,.64167],70:[0,.69444,0,0,.61111],71:[0,.69444,0,0,.73334],72:[0,.69444,0,0,.79445],73:[0,.69444,0,0,.33056],74:[0,.69444,0,0,.51945],75:[0,.69444,0,0,.76389],76:[0,.69444,0,0,.58056],77:[0,.69444,0,0,.97778],78:[0,.69444,0,0,.79445],79:[0,.69444,0,0,.79445],80:[0,.69444,0,0,.70278],81:[.10556,.69444,0,0,.79445],82:[0,.69444,0,0,.70278],83:[0,.69444,0,0,.61111],84:[0,.69444,0,0,.73334],85:[0,.69444,0,0,.76389],86:[0,.69444,.01528,0,.73334],87:[0,.69444,.01528,0,1.03889],88:[0,.69444,0,0,.73334],89:[0,.69444,.0275,0,.73334],90:[0,.69444,0,0,.67223],91:[.25,.75,0,0,.34306],93:[.25,.75,0,0,.34306],94:[0,.69444,0,0,.55],95:[.35,.10833,.03056,0,.55],97:[0,.45833,0,0,.525],98:[0,.69444,0,0,.56111],99:[0,.45833,0,0,.48889],100:[0,.69444,0,0,.56111],101:[0,.45833,0,0,.51111],102:[0,.69444,.07639,0,.33611],103:[.19444,.45833,.01528,0,.55],104:[0,.69444,0,0,.56111],105:[0,.69444,0,0,.25556],106:[.19444,.69444,0,0,.28611],107:[0,.69444,0,0,.53056],108:[0,.69444,0,0,.25556],109:[0,.45833,0,0,.86667],110:[0,.45833,0,0,.56111],111:[0,.45833,0,0,.55],112:[.19444,.45833,0,0,.56111],113:[.19444,.45833,0,0,.56111],114:[0,.45833,.01528,0,.37222],115:[0,.45833,0,0,.42167],116:[0,.58929,0,0,.40417],117:[0,.45833,0,0,.56111],118:[0,.45833,.01528,0,.5],119:[0,.45833,.01528,0,.74445],120:[0,.45833,0,0,.5],121:[.19444,.45833,.01528,0,.5],122:[0,.45833,0,0,.47639],126:[.35,.34444,0,0,.55],160:[0,0,0,0,.25],168:[0,.69444,0,0,.55],176:[0,.69444,0,0,.73334],180:[0,.69444,0,0,.55],184:[.17014,0,0,0,.48889],305:[0,.45833,0,0,.25556],567:[.19444,.45833,0,0,.28611],710:[0,.69444,0,0,.55],711:[0,.63542,0,0,.55],713:[0,.63778,0,0,.55],728:[0,.69444,0,0,.55],729:[0,.69444,0,0,.30556],730:[0,.69444,0,0,.73334],732:[0,.69444,0,0,.55],733:[0,.69444,0,0,.55],915:[0,.69444,0,0,.58056],916:[0,.69444,0,0,.91667],920:[0,.69444,0,0,.85556],923:[0,.69444,0,0,.67223],926:[0,.69444,0,0,.73334],928:[0,.69444,0,0,.79445],931:[0,.69444,0,0,.79445],933:[0,.69444,0,0,.85556],934:[0,.69444,0,0,.79445],936:[0,.69444,0,0,.85556],937:[0,.69444,0,0,.79445],8211:[0,.45833,.03056,0,.55],8212:[0,.45833,.03056,0,1.10001],8216:[0,.69444,0,0,.30556],8217:[0,.69444,0,0,.30556],8220:[0,.69444,0,0,.55834],8221:[0,.69444,0,0,.55834]},"SansSerif-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.05733,0,.31945],34:[0,.69444,.00316,0,.5],35:[.19444,.69444,.05087,0,.83334],36:[.05556,.75,.11156,0,.5],37:[.05556,.75,.03126,0,.83334],38:[0,.69444,.03058,0,.75834],39:[0,.69444,.07816,0,.27778],40:[.25,.75,.13164,0,.38889],41:[.25,.75,.02536,0,.38889],42:[0,.75,.11775,0,.5],43:[.08333,.58333,.02536,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,.01946,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,.13164,0,.5],48:[0,.65556,.11156,0,.5],49:[0,.65556,.11156,0,.5],50:[0,.65556,.11156,0,.5],51:[0,.65556,.11156,0,.5],52:[0,.65556,.11156,0,.5],53:[0,.65556,.11156,0,.5],54:[0,.65556,.11156,0,.5],55:[0,.65556,.11156,0,.5],56:[0,.65556,.11156,0,.5],57:[0,.65556,.11156,0,.5],58:[0,.44444,.02502,0,.27778],59:[.125,.44444,.02502,0,.27778],61:[-.13,.37,.05087,0,.77778],63:[0,.69444,.11809,0,.47222],64:[0,.69444,.07555,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,.08293,0,.66667],67:[0,.69444,.11983,0,.63889],68:[0,.69444,.07555,0,.72223],69:[0,.69444,.11983,0,.59722],70:[0,.69444,.13372,0,.56945],71:[0,.69444,.11983,0,.66667],72:[0,.69444,.08094,0,.70834],73:[0,.69444,.13372,0,.27778],74:[0,.69444,.08094,0,.47222],75:[0,.69444,.11983,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,.08094,0,.875],78:[0,.69444,.08094,0,.70834],79:[0,.69444,.07555,0,.73611],80:[0,.69444,.08293,0,.63889],81:[.125,.69444,.07555,0,.73611],82:[0,.69444,.08293,0,.64584],83:[0,.69444,.09205,0,.55556],84:[0,.69444,.13372,0,.68056],85:[0,.69444,.08094,0,.6875],86:[0,.69444,.1615,0,.66667],87:[0,.69444,.1615,0,.94445],88:[0,.69444,.13372,0,.66667],89:[0,.69444,.17261,0,.66667],90:[0,.69444,.11983,0,.61111],91:[.25,.75,.15942,0,.28889],93:[.25,.75,.08719,0,.28889],94:[0,.69444,.0799,0,.5],95:[.35,.09444,.08616,0,.5],97:[0,.44444,.00981,0,.48056],98:[0,.69444,.03057,0,.51667],99:[0,.44444,.08336,0,.44445],100:[0,.69444,.09483,0,.51667],101:[0,.44444,.06778,0,.44445],102:[0,.69444,.21705,0,.30556],103:[.19444,.44444,.10836,0,.5],104:[0,.69444,.01778,0,.51667],105:[0,.67937,.09718,0,.23889],106:[.19444,.67937,.09162,0,.26667],107:[0,.69444,.08336,0,.48889],108:[0,.69444,.09483,0,.23889],109:[0,.44444,.01778,0,.79445],110:[0,.44444,.01778,0,.51667],111:[0,.44444,.06613,0,.5],112:[.19444,.44444,.0389,0,.51667],113:[.19444,.44444,.04169,0,.51667],114:[0,.44444,.10836,0,.34167],115:[0,.44444,.0778,0,.38333],116:[0,.57143,.07225,0,.36111],117:[0,.44444,.04169,0,.51667],118:[0,.44444,.10836,0,.46111],119:[0,.44444,.10836,0,.68334],120:[0,.44444,.09169,0,.46111],121:[.19444,.44444,.10836,0,.46111],122:[0,.44444,.08752,0,.43472],126:[.35,.32659,.08826,0,.5],160:[0,0,0,0,.25],168:[0,.67937,.06385,0,.5],176:[0,.69444,0,0,.73752],184:[.17014,0,0,0,.44445],305:[0,.44444,.04169,0,.23889],567:[.19444,.44444,.04169,0,.26667],710:[0,.69444,.0799,0,.5],711:[0,.63194,.08432,0,.5],713:[0,.60889,.08776,0,.5],714:[0,.69444,.09205,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,.09483,0,.5],729:[0,.67937,.07774,0,.27778],730:[0,.69444,0,0,.73752],732:[0,.67659,.08826,0,.5],733:[0,.69444,.09205,0,.5],915:[0,.69444,.13372,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,.07555,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,.12816,0,.66667],928:[0,.69444,.08094,0,.70834],931:[0,.69444,.11983,0,.72222],933:[0,.69444,.09031,0,.77778],934:[0,.69444,.04603,0,.72222],936:[0,.69444,.09031,0,.77778],937:[0,.69444,.08293,0,.72222],8211:[0,.44444,.08616,0,.5],8212:[0,.44444,.08616,0,1],8216:[0,.69444,.07816,0,.27778],8217:[0,.69444,.07816,0,.27778],8220:[0,.69444,.14205,0,.5],8221:[0,.69444,.00316,0,.5]},"SansSerif-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.31945],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.75834],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,0,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.65556,0,0,.5],49:[0,.65556,0,0,.5],50:[0,.65556,0,0,.5],51:[0,.65556,0,0,.5],52:[0,.65556,0,0,.5],53:[0,.65556,0,0,.5],54:[0,.65556,0,0,.5],55:[0,.65556,0,0,.5],56:[0,.65556,0,0,.5],57:[0,.65556,0,0,.5],58:[0,.44444,0,0,.27778],59:[.125,.44444,0,0,.27778],61:[-.13,.37,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,0,0,.66667],67:[0,.69444,0,0,.63889],68:[0,.69444,0,0,.72223],69:[0,.69444,0,0,.59722],70:[0,.69444,0,0,.56945],71:[0,.69444,0,0,.66667],72:[0,.69444,0,0,.70834],73:[0,.69444,0,0,.27778],74:[0,.69444,0,0,.47222],75:[0,.69444,0,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,0,0,.875],78:[0,.69444,0,0,.70834],79:[0,.69444,0,0,.73611],80:[0,.69444,0,0,.63889],81:[.125,.69444,0,0,.73611],82:[0,.69444,0,0,.64584],83:[0,.69444,0,0,.55556],84:[0,.69444,0,0,.68056],85:[0,.69444,0,0,.6875],86:[0,.69444,.01389,0,.66667],87:[0,.69444,.01389,0,.94445],88:[0,.69444,0,0,.66667],89:[0,.69444,.025,0,.66667],90:[0,.69444,0,0,.61111],91:[.25,.75,0,0,.28889],93:[.25,.75,0,0,.28889],94:[0,.69444,0,0,.5],95:[.35,.09444,.02778,0,.5],97:[0,.44444,0,0,.48056],98:[0,.69444,0,0,.51667],99:[0,.44444,0,0,.44445],100:[0,.69444,0,0,.51667],101:[0,.44444,0,0,.44445],102:[0,.69444,.06944,0,.30556],103:[.19444,.44444,.01389,0,.5],104:[0,.69444,0,0,.51667],105:[0,.67937,0,0,.23889],106:[.19444,.67937,0,0,.26667],107:[0,.69444,0,0,.48889],108:[0,.69444,0,0,.23889],109:[0,.44444,0,0,.79445],110:[0,.44444,0,0,.51667],111:[0,.44444,0,0,.5],112:[.19444,.44444,0,0,.51667],113:[.19444,.44444,0,0,.51667],114:[0,.44444,.01389,0,.34167],115:[0,.44444,0,0,.38333],116:[0,.57143,0,0,.36111],117:[0,.44444,0,0,.51667],118:[0,.44444,.01389,0,.46111],119:[0,.44444,.01389,0,.68334],120:[0,.44444,0,0,.46111],121:[.19444,.44444,.01389,0,.46111],122:[0,.44444,0,0,.43472],126:[.35,.32659,0,0,.5],160:[0,0,0,0,.25],168:[0,.67937,0,0,.5],176:[0,.69444,0,0,.66667],184:[.17014,0,0,0,.44445],305:[0,.44444,0,0,.23889],567:[.19444,.44444,0,0,.26667],710:[0,.69444,0,0,.5],711:[0,.63194,0,0,.5],713:[0,.60889,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.67937,0,0,.27778],730:[0,.69444,0,0,.66667],732:[0,.67659,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.69444,0,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,0,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,0,0,.66667],928:[0,.69444,0,0,.70834],931:[0,.69444,0,0,.72222],933:[0,.69444,0,0,.77778],934:[0,.69444,0,0,.72222],936:[0,.69444,0,0,.77778],937:[0,.69444,0,0,.72222],8211:[0,.44444,.02778,0,.5],8212:[0,.44444,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5]},"Script-Regular":{32:[0,0,0,0,.25],65:[0,.7,.22925,0,.80253],66:[0,.7,.04087,0,.90757],67:[0,.7,.1689,0,.66619],68:[0,.7,.09371,0,.77443],69:[0,.7,.18583,0,.56162],70:[0,.7,.13634,0,.89544],71:[0,.7,.17322,0,.60961],72:[0,.7,.29694,0,.96919],73:[0,.7,.19189,0,.80907],74:[.27778,.7,.19189,0,1.05159],75:[0,.7,.31259,0,.91364],76:[0,.7,.19189,0,.87373],77:[0,.7,.15981,0,1.08031],78:[0,.7,.3525,0,.9015],79:[0,.7,.08078,0,.73787],80:[0,.7,.08078,0,1.01262],81:[0,.7,.03305,0,.88282],82:[0,.7,.06259,0,.85],83:[0,.7,.19189,0,.86767],84:[0,.7,.29087,0,.74697],85:[0,.7,.25815,0,.79996],86:[0,.7,.27523,0,.62204],87:[0,.7,.27523,0,.80532],88:[0,.7,.26006,0,.94445],89:[0,.7,.2939,0,.70961],90:[0,.7,.24037,0,.8212],160:[0,0,0,0,.25]},"Size1-Regular":{32:[0,0,0,0,.25],40:[.35001,.85,0,0,.45834],41:[.35001,.85,0,0,.45834],47:[.35001,.85,0,0,.57778],91:[.35001,.85,0,0,.41667],92:[.35001,.85,0,0,.57778],93:[.35001,.85,0,0,.41667],123:[.35001,.85,0,0,.58334],125:[.35001,.85,0,0,.58334],160:[0,0,0,0,.25],710:[0,.72222,0,0,.55556],732:[0,.72222,0,0,.55556],770:[0,.72222,0,0,.55556],771:[0,.72222,0,0,.55556],8214:[-99e-5,.601,0,0,.77778],8593:[1e-5,.6,0,0,.66667],8595:[1e-5,.6,0,0,.66667],8657:[1e-5,.6,0,0,.77778],8659:[1e-5,.6,0,0,.77778],8719:[.25001,.75,0,0,.94445],8720:[.25001,.75,0,0,.94445],8721:[.25001,.75,0,0,1.05556],8730:[.35001,.85,0,0,1],8739:[-.00599,.606,0,0,.33333],8741:[-.00599,.606,0,0,.55556],8747:[.30612,.805,.19445,0,.47222],8748:[.306,.805,.19445,0,.47222],8749:[.306,.805,.19445,0,.47222],8750:[.30612,.805,.19445,0,.47222],8896:[.25001,.75,0,0,.83334],8897:[.25001,.75,0,0,.83334],8898:[.25001,.75,0,0,.83334],8899:[.25001,.75,0,0,.83334],8968:[.35001,.85,0,0,.47222],8969:[.35001,.85,0,0,.47222],8970:[.35001,.85,0,0,.47222],8971:[.35001,.85,0,0,.47222],9168:[-99e-5,.601,0,0,.66667],10216:[.35001,.85,0,0,.47222],10217:[.35001,.85,0,0,.47222],10752:[.25001,.75,0,0,1.11111],10753:[.25001,.75,0,0,1.11111],10754:[.25001,.75,0,0,1.11111],10756:[.25001,.75,0,0,.83334],10758:[.25001,.75,0,0,.83334]},"Size2-Regular":{32:[0,0,0,0,.25],40:[.65002,1.15,0,0,.59722],41:[.65002,1.15,0,0,.59722],47:[.65002,1.15,0,0,.81111],91:[.65002,1.15,0,0,.47222],92:[.65002,1.15,0,0,.81111],93:[.65002,1.15,0,0,.47222],123:[.65002,1.15,0,0,.66667],125:[.65002,1.15,0,0,.66667],160:[0,0,0,0,.25],710:[0,.75,0,0,1],732:[0,.75,0,0,1],770:[0,.75,0,0,1],771:[0,.75,0,0,1],8719:[.55001,1.05,0,0,1.27778],8720:[.55001,1.05,0,0,1.27778],8721:[.55001,1.05,0,0,1.44445],8730:[.65002,1.15,0,0,1],8747:[.86225,1.36,.44445,0,.55556],8748:[.862,1.36,.44445,0,.55556],8749:[.862,1.36,.44445,0,.55556],8750:[.86225,1.36,.44445,0,.55556],8896:[.55001,1.05,0,0,1.11111],8897:[.55001,1.05,0,0,1.11111],8898:[.55001,1.05,0,0,1.11111],8899:[.55001,1.05,0,0,1.11111],8968:[.65002,1.15,0,0,.52778],8969:[.65002,1.15,0,0,.52778],8970:[.65002,1.15,0,0,.52778],8971:[.65002,1.15,0,0,.52778],10216:[.65002,1.15,0,0,.61111],10217:[.65002,1.15,0,0,.61111],10752:[.55001,1.05,0,0,1.51112],10753:[.55001,1.05,0,0,1.51112],10754:[.55001,1.05,0,0,1.51112],10756:[.55001,1.05,0,0,1.11111],10758:[.55001,1.05,0,0,1.11111]},"Size3-Regular":{32:[0,0,0,0,.25],40:[.95003,1.45,0,0,.73611],41:[.95003,1.45,0,0,.73611],47:[.95003,1.45,0,0,1.04445],91:[.95003,1.45,0,0,.52778],92:[.95003,1.45,0,0,1.04445],93:[.95003,1.45,0,0,.52778],123:[.95003,1.45,0,0,.75],125:[.95003,1.45,0,0,.75],160:[0,0,0,0,.25],710:[0,.75,0,0,1.44445],732:[0,.75,0,0,1.44445],770:[0,.75,0,0,1.44445],771:[0,.75,0,0,1.44445],8730:[.95003,1.45,0,0,1],8968:[.95003,1.45,0,0,.58334],8969:[.95003,1.45,0,0,.58334],8970:[.95003,1.45,0,0,.58334],8971:[.95003,1.45,0,0,.58334],10216:[.95003,1.45,0,0,.75],10217:[.95003,1.45,0,0,.75]},"Size4-Regular":{32:[0,0,0,0,.25],40:[1.25003,1.75,0,0,.79167],41:[1.25003,1.75,0,0,.79167],47:[1.25003,1.75,0,0,1.27778],91:[1.25003,1.75,0,0,.58334],92:[1.25003,1.75,0,0,1.27778],93:[1.25003,1.75,0,0,.58334],123:[1.25003,1.75,0,0,.80556],125:[1.25003,1.75,0,0,.80556],160:[0,0,0,0,.25],710:[0,.825,0,0,1.8889],732:[0,.825,0,0,1.8889],770:[0,.825,0,0,1.8889],771:[0,.825,0,0,1.8889],8730:[1.25003,1.75,0,0,1],8968:[1.25003,1.75,0,0,.63889],8969:[1.25003,1.75,0,0,.63889],8970:[1.25003,1.75,0,0,.63889],8971:[1.25003,1.75,0,0,.63889],9115:[.64502,1.155,0,0,.875],9116:[1e-5,.6,0,0,.875],9117:[.64502,1.155,0,0,.875],9118:[.64502,1.155,0,0,.875],9119:[1e-5,.6,0,0,.875],9120:[.64502,1.155,0,0,.875],9121:[.64502,1.155,0,0,.66667],9122:[-99e-5,.601,0,0,.66667],9123:[.64502,1.155,0,0,.66667],9124:[.64502,1.155,0,0,.66667],9125:[-99e-5,.601,0,0,.66667],9126:[.64502,1.155,0,0,.66667],9127:[1e-5,.9,0,0,.88889],9128:[.65002,1.15,0,0,.88889],9129:[.90001,0,0,0,.88889],9130:[0,.3,0,0,.88889],9131:[1e-5,.9,0,0,.88889],9132:[.65002,1.15,0,0,.88889],9133:[.90001,0,0,0,.88889],9143:[.88502,.915,0,0,1.05556],10216:[1.25003,1.75,0,0,.80556],10217:[1.25003,1.75,0,0,.80556],57344:[-.00499,.605,0,0,1.05556],57345:[-.00499,.605,0,0,1.05556],57680:[0,.12,0,0,.45],57681:[0,.12,0,0,.45],57682:[0,.12,0,0,.45],57683:[0,.12,0,0,.45]},"Typewriter-Regular":{32:[0,0,0,0,.525],33:[0,.61111,0,0,.525],34:[0,.61111,0,0,.525],35:[0,.61111,0,0,.525],36:[.08333,.69444,0,0,.525],37:[.08333,.69444,0,0,.525],38:[0,.61111,0,0,.525],39:[0,.61111,0,0,.525],40:[.08333,.69444,0,0,.525],41:[.08333,.69444,0,0,.525],42:[0,.52083,0,0,.525],43:[-.08056,.53055,0,0,.525],44:[.13889,.125,0,0,.525],45:[-.08056,.53055,0,0,.525],46:[0,.125,0,0,.525],47:[.08333,.69444,0,0,.525],48:[0,.61111,0,0,.525],49:[0,.61111,0,0,.525],50:[0,.61111,0,0,.525],51:[0,.61111,0,0,.525],52:[0,.61111,0,0,.525],53:[0,.61111,0,0,.525],54:[0,.61111,0,0,.525],55:[0,.61111,0,0,.525],56:[0,.61111,0,0,.525],57:[0,.61111,0,0,.525],58:[0,.43056,0,0,.525],59:[.13889,.43056,0,0,.525],60:[-.05556,.55556,0,0,.525],61:[-.19549,.41562,0,0,.525],62:[-.05556,.55556,0,0,.525],63:[0,.61111,0,0,.525],64:[0,.61111,0,0,.525],65:[0,.61111,0,0,.525],66:[0,.61111,0,0,.525],67:[0,.61111,0,0,.525],68:[0,.61111,0,0,.525],69:[0,.61111,0,0,.525],70:[0,.61111,0,0,.525],71:[0,.61111,0,0,.525],72:[0,.61111,0,0,.525],73:[0,.61111,0,0,.525],74:[0,.61111,0,0,.525],75:[0,.61111,0,0,.525],76:[0,.61111,0,0,.525],77:[0,.61111,0,0,.525],78:[0,.61111,0,0,.525],79:[0,.61111,0,0,.525],80:[0,.61111,0,0,.525],81:[.13889,.61111,0,0,.525],82:[0,.61111,0,0,.525],83:[0,.61111,0,0,.525],84:[0,.61111,0,0,.525],85:[0,.61111,0,0,.525],86:[0,.61111,0,0,.525],87:[0,.61111,0,0,.525],88:[0,.61111,0,0,.525],89:[0,.61111,0,0,.525],90:[0,.61111,0,0,.525],91:[.08333,.69444,0,0,.525],92:[.08333,.69444,0,0,.525],93:[.08333,.69444,0,0,.525],94:[0,.61111,0,0,.525],95:[.09514,0,0,0,.525],96:[0,.61111,0,0,.525],97:[0,.43056,0,0,.525],98:[0,.61111,0,0,.525],99:[0,.43056,0,0,.525],100:[0,.61111,0,0,.525],101:[0,.43056,0,0,.525],102:[0,.61111,0,0,.525],103:[.22222,.43056,0,0,.525],104:[0,.61111,0,0,.525],105:[0,.61111,0,0,.525],106:[.22222,.61111,0,0,.525],107:[0,.61111,0,0,.525],108:[0,.61111,0,0,.525],109:[0,.43056,0,0,.525],110:[0,.43056,0,0,.525],111:[0,.43056,0,0,.525],112:[.22222,.43056,0,0,.525],113:[.22222,.43056,0,0,.525],114:[0,.43056,0,0,.525],115:[0,.43056,0,0,.525],116:[0,.55358,0,0,.525],117:[0,.43056,0,0,.525],118:[0,.43056,0,0,.525],119:[0,.43056,0,0,.525],120:[0,.43056,0,0,.525],121:[.22222,.43056,0,0,.525],122:[0,.43056,0,0,.525],123:[.08333,.69444,0,0,.525],124:[.08333,.69444,0,0,.525],125:[.08333,.69444,0,0,.525],126:[0,.61111,0,0,.525],127:[0,.61111,0,0,.525],160:[0,0,0,0,.525],176:[0,.61111,0,0,.525],184:[.19445,0,0,0,.525],305:[0,.43056,0,0,.525],567:[.22222,.43056,0,0,.525],711:[0,.56597,0,0,.525],713:[0,.56555,0,0,.525],714:[0,.61111,0,0,.525],715:[0,.61111,0,0,.525],728:[0,.61111,0,0,.525],730:[0,.61111,0,0,.525],770:[0,.61111,0,0,.525],771:[0,.61111,0,0,.525],776:[0,.61111,0,0,.525],915:[0,.61111,0,0,.525],916:[0,.61111,0,0,.525],920:[0,.61111,0,0,.525],923:[0,.61111,0,0,.525],926:[0,.61111,0,0,.525],928:[0,.61111,0,0,.525],931:[0,.61111,0,0,.525],933:[0,.61111,0,0,.525],934:[0,.61111,0,0,.525],936:[0,.61111,0,0,.525],937:[0,.61111,0,0,.525],8216:[0,.61111,0,0,.525],8217:[0,.61111,0,0,.525],8242:[0,.61111,0,0,.525],9251:[.11111,.21944,0,0,.525]}},Q0={slant:[.25,.25,.25],space:[0,0,0],stretch:[0,0,0],shrink:[0,0,0],xHeight:[.431,.431,.431],quad:[1,1.171,1.472],extraSpace:[0,0,0],num1:[.677,.732,.925],num2:[.394,.384,.387],num3:[.444,.471,.504],denom1:[.686,.752,1.025],denom2:[.345,.344,.532],sup1:[.413,.503,.504],sup2:[.363,.431,.404],sup3:[.289,.286,.294],sub1:[.15,.143,.2],sub2:[.247,.286,.4],supDrop:[.386,.353,.494],subDrop:[.05,.071,.1],delim1:[2.39,1.7,1.98],delim2:[1.01,1.157,1.42],axisHeight:[.25,.25,.25],defaultRuleThickness:[.04,.049,.049],bigOpSpacing1:[.111,.111,.111],bigOpSpacing2:[.166,.166,.166],bigOpSpacing3:[.2,.2,.2],bigOpSpacing4:[.6,.611,.611],bigOpSpacing5:[.1,.143,.143],sqrtRuleThickness:[.04,.04,.04],ptPerEm:[10,10,10],doubleRuleSep:[.2,.2,.2],arrayRuleWidth:[.04,.04,.04],fboxsep:[.3,.3,.3],fboxrule:[.04,.04,.04]},hc={Å:"A",Ð:"D",Þ:"o",å:"a",ð:"d",þ:"o",А:"A",Б:"B",В:"B",Г:"F",Д:"A",Е:"E",Ж:"K",З:"3",И:"N",Й:"N",К:"K",Л:"N",М:"M",Н:"H",О:"O",П:"N",Р:"P",С:"C",Т:"T",У:"y",Ф:"O",Х:"X",Ц:"U",Ч:"h",Ш:"W",Щ:"W",Ъ:"B",Ы:"X",Ь:"B",Э:"3",Ю:"X",Я:"R",а:"a",б:"b",в:"a",г:"r",д:"y",е:"e",ж:"m",з:"e",и:"n",й:"n",к:"n",л:"n",м:"m",н:"n",о:"o",п:"n",р:"p",с:"c",т:"o",у:"y",ф:"b",х:"x",ц:"n",ч:"n",ш:"w",щ:"w",ъ:"a",ы:"m",ь:"a",э:"e",ю:"m",я:"r"};function Y6(t,e){kr[t]=e}function No(t,e,r){if(!kr[e])throw new Error("Font metrics not found for font: "+e+".");var n=t.charCodeAt(0),i=kr[e][n];if(!i&&t[0]in hc&&(n=hc[t[0]].charCodeAt(0),i=kr[e][n]),!i&&r==="text"&&nd(n)&&(i=kr[e][77]),i)return{depth:i[0],height:i[1],italic:i[2],skew:i[3],width:i[4]}}var $s={};function X6(t){var e;if(t>=5?e=0:t>=3?e=1:e=2,!$s[e]){var r=$s[e]={cssEmPerMu:Q0.quad[e]/18};for(var n in Q0)Q0.hasOwnProperty(n)&&(r[n]=Q0[n][e])}return $s[e]}var J6=[[1,1,1],[2,1,1],[3,1,1],[4,2,1],[5,2,1],[6,3,1],[7,4,2],[8,6,3],[9,7,6],[10,8,7],[11,10,9]],fc=[.5,.6,.7,.8,.9,1,1.2,1.44,1.728,2.074,2.488],pc=function(e,r){return r.size<2?e:J6[e-1][r.size-1]};class Dr{constructor(e){this.style=void 0,this.color=void 0,this.size=void 0,this.textSize=void 0,this.phantom=void 0,this.font=void 0,this.fontFamily=void 0,this.fontWeight=void 0,this.fontShape=void 0,this.sizeMultiplier=void 0,this.maxSize=void 0,this.minRuleThickness=void 0,this._fontMetrics=void 0,this.style=e.style,this.color=e.color,this.size=e.size||Dr.BASESIZE,this.textSize=e.textSize||this.size,this.phantom=!!e.phantom,this.font=e.font||"",this.fontFamily=e.fontFamily||"",this.fontWeight=e.fontWeight||"",this.fontShape=e.fontShape||"",this.sizeMultiplier=fc[this.size-1],this.maxSize=e.maxSize,this.minRuleThickness=e.minRuleThickness,this._fontMetrics=void 0}extend(e){var r={style:this.style,size:this.size,textSize:this.textSize,color:this.color,phantom:this.phantom,font:this.font,fontFamily:this.fontFamily,fontWeight:this.fontWeight,fontShape:this.fontShape,maxSize:this.maxSize,minRuleThickness:this.minRuleThickness};for(var n in e)e.hasOwnProperty(n)&&(r[n]=e[n]);return new Dr(r)}havingStyle(e){return this.style===e?this:this.extend({style:e,size:pc(this.textSize,e)})}havingCrampedStyle(){return this.havingStyle(this.style.cramp())}havingSize(e){return this.size===e&&this.textSize===e?this:this.extend({style:this.style.text(),size:e,textSize:e,sizeMultiplier:fc[e-1]})}havingBaseStyle(e){e=e||this.style.text();var r=pc(Dr.BASESIZE,e);return this.size===r&&this.textSize===Dr.BASESIZE&&this.style===e?this:this.extend({style:e,size:r})}havingBaseSizing(){var e;switch(this.style.id){case 4:case 5:e=3;break;case 6:case 7:e=1;break;default:e=6}return this.extend({style:this.style.text(),size:e})}withColor(e){return this.extend({color:e})}withPhantom(){return this.extend({phantom:!0})}withFont(e){return this.extend({font:e})}withTextFontFamily(e){return this.extend({fontFamily:e,font:""})}withTextFontWeight(e){return this.extend({fontWeight:e,font:""})}withTextFontShape(e){return this.extend({fontShape:e,font:""})}sizingClasses(e){return e.size!==this.size?["sizing","reset-size"+e.size,"size"+this.size]:[]}baseSizingClasses(){return this.size!==Dr.BASESIZE?["sizing","reset-size"+this.size,"size"+Dr.BASESIZE]:[]}fontMetrics(){return this._fontMetrics||(this._fontMetrics=X6(this.size)),this._fontMetrics}getColor(){return this.phantom?"transparent":this.color}}Dr.BASESIZE=6;var Ea={pt:1,mm:7227/2540,cm:7227/254,in:72.27,bp:803/800,pc:12,dd:1238/1157,cc:14856/1157,nd:685/642,nc:1370/107,sp:1/65536,px:803/800},Z6={ex:!0,em:!0,mu:!0},id=function(e){return typeof e!="string"&&(e=e.unit),e in Ea||e in Z6||e==="ex"},at=function(e,r){var n;if(e.unit in Ea)n=Ea[e.unit]/r.fontMetrics().ptPerEm/r.sizeMultiplier;else if(e.unit==="mu")n=r.fontMetrics().cssEmPerMu;else{var i;if(r.style.isTight()?i=r.havingStyle(r.style.text()):i=r,e.unit==="ex")n=i.fontMetrics().xHeight;else if(e.unit==="em")n=i.fontMetrics().quad;else throw new te("Invalid unit: '"+e.unit+"'");i!==r&&(n*=i.sizeMultiplier/r.sizeMultiplier)}return Math.min(e.number*n,r.maxSize)},se=function(e){return+e.toFixed(4)+"em"},sn=function(e){return e.filter(r=>r).join(" ")},sd=function(e,r,n){if(this.classes=e||[],this.attributes={},this.height=0,this.depth=0,this.maxFontSize=0,this.style=n||{},r){r.style.isTight()&&this.classes.push("mtight");var i=r.getColor();i&&(this.style.color=i)}},ad=function(e){var r=document.createElement(e);r.className=sn(this.classes);for(var n in this.style)this.style.hasOwnProperty(n)&&(r.style[n]=this.style[n]);for(var i in this.attributes)this.attributes.hasOwnProperty(i)&&r.setAttribute(i,this.attributes[i]);for(var s=0;s<this.children.length;s++)r.appendChild(this.children[s].toNode());return r},Q6=/[\s"'>/=\x00-\x1f]/,od=function(e){var r="<"+e;this.classes.length&&(r+=' class="'+ve.escape(sn(this.classes))+'"');var n="";for(var i in this.style)this.style.hasOwnProperty(i)&&(n+=ve.hyphenate(i)+":"+this.style[i]+";");n&&(r+=' style="'+ve.escape(n)+'"');for(var s in this.attributes)if(this.attributes.hasOwnProperty(s)){if(Q6.test(s))throw new te("Invalid attribute name '"+s+"'");r+=" "+s+'="'+ve.escape(this.attributes[s])+'"'}r+=">";for(var a=0;a<this.children.length;a++)r+=this.children[a].toMarkup();return r+="</"+e+">",r};class z0{constructor(e,r,n,i){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.width=void 0,this.maxFontSize=void 0,this.style=void 0,sd.call(this,e,n,i),this.children=r||[]}setAttribute(e,r){this.attributes[e]=r}hasClass(e){return ve.contains(this.classes,e)}toNode(){return ad.call(this,"span")}toMarkup(){return od.call(this,"span")}}class Io{constructor(e,r,n,i){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,sd.call(this,r,i),this.children=n||[],this.setAttribute("href",e)}setAttribute(e,r){this.attributes[e]=r}hasClass(e){return ve.contains(this.classes,e)}toNode(){return ad.call(this,"a")}toMarkup(){return od.call(this,"a")}}class e5{constructor(e,r,n){this.src=void 0,this.alt=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.alt=r,this.src=e,this.classes=["mord"],this.style=n}hasClass(e){return ve.contains(this.classes,e)}toNode(){var e=document.createElement("img");e.src=this.src,e.alt=this.alt,e.className="mord";for(var r in this.style)this.style.hasOwnProperty(r)&&(e.style[r]=this.style[r]);return e}toMarkup(){var e='<img src="'+ve.escape(this.src)+'"'+(' alt="'+ve.escape(this.alt)+'"'),r="";for(var n in this.style)this.style.hasOwnProperty(n)&&(r+=ve.hyphenate(n)+":"+this.style[n]+";");return r&&(e+=' style="'+ve.escape(r)+'"'),e+="'/>",e}}var t5={î:"ı̂",ï:"ı̈",í:"ı́",ì:"ı̀"};class sr{constructor(e,r,n,i,s,a,o,l){this.text=void 0,this.height=void 0,this.depth=void 0,this.italic=void 0,this.skew=void 0,this.width=void 0,this.maxFontSize=void 0,this.classes=void 0,this.style=void 0,this.text=e,this.height=r||0,this.depth=n||0,this.italic=i||0,this.skew=s||0,this.width=a||0,this.classes=o||[],this.style=l||{},this.maxFontSize=0;var c=F6(this.text.charCodeAt(0));c&&this.classes.push(c+"_fallback"),/[îïíì]/.test(this.text)&&(this.text=t5[this.text])}hasClass(e){return ve.contains(this.classes,e)}toNode(){var e=document.createTextNode(this.text),r=null;this.italic>0&&(r=document.createElement("span"),r.style.marginRight=se(this.italic)),this.classes.length>0&&(r=r||document.createElement("span"),r.className=sn(this.classes));for(var n in this.style)this.style.hasOwnProperty(n)&&(r=r||document.createElement("span"),r.style[n]=this.style[n]);return r?(r.appendChild(e),r):e}toMarkup(){var e=!1,r="<span";this.classes.length&&(e=!0,r+=' class="',r+=ve.escape(sn(this.classes)),r+='"');var n="";this.italic>0&&(n+="margin-right:"+this.italic+"em;");for(var i in this.style)this.style.hasOwnProperty(i)&&(n+=ve.hyphenate(i)+":"+this.style[i]+";");n&&(e=!0,r+=' style="'+ve.escape(n)+'"');var s=ve.escape(this.text);return e?(r+=">",r+=s,r+="</span>",r):s}}class Hr{constructor(e,r){this.children=void 0,this.attributes=void 0,this.children=e||[],this.attributes=r||{}}toNode(){var e="http://www.w3.org/2000/svg",r=document.createElementNS(e,"svg");for(var n in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,n)&&r.setAttribute(n,this.attributes[n]);for(var i=0;i<this.children.length;i++)r.appendChild(this.children[i].toNode());return r}toMarkup(){var e='<svg xmlns="http://www.w3.org/2000/svg"';for(var r in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,r)&&(e+=" "+r+'="'+ve.escape(this.attributes[r])+'"');e+=">";for(var n=0;n<this.children.length;n++)e+=this.children[n].toMarkup();return e+="</svg>",e}}class an{constructor(e,r){this.pathName=void 0,this.alternate=void 0,this.pathName=e,this.alternate=r}toNode(){var e="http://www.w3.org/2000/svg",r=document.createElementNS(e,"path");return this.alternate?r.setAttribute("d",this.alternate):r.setAttribute("d",dc[this.pathName]),r}toMarkup(){return this.alternate?'<path d="'+ve.escape(this.alternate)+'"/>':'<path d="'+ve.escape(dc[this.pathName])+'"/>'}}class Ca{constructor(e){this.attributes=void 0,this.attributes=e||{}}toNode(){var e="http://www.w3.org/2000/svg",r=document.createElementNS(e,"line");for(var n in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,n)&&r.setAttribute(n,this.attributes[n]);return r}toMarkup(){var e="<line";for(var r in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,r)&&(e+=" "+r+'="'+ve.escape(this.attributes[r])+'"');return e+="/>",e}}function mc(t){if(t instanceof sr)return t;throw new Error("Expected symbolNode but got "+String(t)+".")}function r5(t){if(t instanceof z0)return t;throw new Error("Expected span<HtmlDomNode> but got "+String(t)+".")}var n5={bin:1,close:1,inner:1,open:1,punct:1,rel:1},i5={"accent-token":1,mathord:1,"op-token":1,spacing:1,textord:1},tt={math:{},text:{}};function d(t,e,r,n,i,s){tt[t][i]={font:e,group:r,replace:n},s&&n&&(tt[t][n]=tt[t][i])}var h="math",X="text",m="main",A="ams",it="accent-token",fe="bin",$t="close",Xn="inner",we="mathord",mt="op-token",Jt="open",fs="punct",E="rel",Vr="spacing",R="textord";d(h,m,E,"≡","\\equiv",!0);d(h,m,E,"≺","\\prec",!0);d(h,m,E,"≻","\\succ",!0);d(h,m,E,"∼","\\sim",!0);d(h,m,E,"⊥","\\perp");d(h,m,E,"⪯","\\preceq",!0);d(h,m,E,"⪰","\\succeq",!0);d(h,m,E,"≃","\\simeq",!0);d(h,m,E,"∣","\\mid",!0);d(h,m,E,"≪","\\ll",!0);d(h,m,E,"≫","\\gg",!0);d(h,m,E,"≍","\\asymp",!0);d(h,m,E,"∥","\\parallel");d(h,m,E,"⋈","\\bowtie",!0);d(h,m,E,"⌣","\\smile",!0);d(h,m,E,"⊑","\\sqsubseteq",!0);d(h,m,E,"⊒","\\sqsupseteq",!0);d(h,m,E,"≐","\\doteq",!0);d(h,m,E,"⌢","\\frown",!0);d(h,m,E,"∋","\\ni",!0);d(h,m,E,"∝","\\propto",!0);d(h,m,E,"⊢","\\vdash",!0);d(h,m,E,"⊣","\\dashv",!0);d(h,m,E,"∋","\\owns");d(h,m,fs,".","\\ldotp");d(h,m,fs,"⋅","\\cdotp");d(h,m,R,"#","\\#");d(X,m,R,"#","\\#");d(h,m,R,"&","\\&");d(X,m,R,"&","\\&");d(h,m,R,"ℵ","\\aleph",!0);d(h,m,R,"∀","\\forall",!0);d(h,m,R,"ℏ","\\hbar",!0);d(h,m,R,"∃","\\exists",!0);d(h,m,R,"∇","\\nabla",!0);d(h,m,R,"♭","\\flat",!0);d(h,m,R,"ℓ","\\ell",!0);d(h,m,R,"♮","\\natural",!0);d(h,m,R,"♣","\\clubsuit",!0);d(h,m,R,"℘","\\wp",!0);d(h,m,R,"♯","\\sharp",!0);d(h,m,R,"♢","\\diamondsuit",!0);d(h,m,R,"ℜ","\\Re",!0);d(h,m,R,"♡","\\heartsuit",!0);d(h,m,R,"ℑ","\\Im",!0);d(h,m,R,"♠","\\spadesuit",!0);d(h,m,R,"§","\\S",!0);d(X,m,R,"§","\\S");d(h,m,R,"¶","\\P",!0);d(X,m,R,"¶","\\P");d(h,m,R,"†","\\dag");d(X,m,R,"†","\\dag");d(X,m,R,"†","\\textdagger");d(h,m,R,"‡","\\ddag");d(X,m,R,"‡","\\ddag");d(X,m,R,"‡","\\textdaggerdbl");d(h,m,$t,"⎱","\\rmoustache",!0);d(h,m,Jt,"⎰","\\lmoustache",!0);d(h,m,$t,"⟯","\\rgroup",!0);d(h,m,Jt,"⟮","\\lgroup",!0);d(h,m,fe,"∓","\\mp",!0);d(h,m,fe,"⊖","\\ominus",!0);d(h,m,fe,"⊎","\\uplus",!0);d(h,m,fe,"⊓","\\sqcap",!0);d(h,m,fe,"∗","\\ast");d(h,m,fe,"⊔","\\sqcup",!0);d(h,m,fe,"◯","\\bigcirc",!0);d(h,m,fe,"∙","\\bullet",!0);d(h,m,fe,"‡","\\ddagger");d(h,m,fe,"≀","\\wr",!0);d(h,m,fe,"⨿","\\amalg");d(h,m,fe,"&","\\And");d(h,m,E,"⟵","\\longleftarrow",!0);d(h,m,E,"⇐","\\Leftarrow",!0);d(h,m,E,"⟸","\\Longleftarrow",!0);d(h,m,E,"⟶","\\longrightarrow",!0);d(h,m,E,"⇒","\\Rightarrow",!0);d(h,m,E,"⟹","\\Longrightarrow",!0);d(h,m,E,"↔","\\leftrightarrow",!0);d(h,m,E,"⟷","\\longleftrightarrow",!0);d(h,m,E,"⇔","\\Leftrightarrow",!0);d(h,m,E,"⟺","\\Longleftrightarrow",!0);d(h,m,E,"↦","\\mapsto",!0);d(h,m,E,"⟼","\\longmapsto",!0);d(h,m,E,"↗","\\nearrow",!0);d(h,m,E,"↩","\\hookleftarrow",!0);d(h,m,E,"↪","\\hookrightarrow",!0);d(h,m,E,"↘","\\searrow",!0);d(h,m,E,"↼","\\leftharpoonup",!0);d(h,m,E,"⇀","\\rightharpoonup",!0);d(h,m,E,"↙","\\swarrow",!0);d(h,m,E,"↽","\\leftharpoondown",!0);d(h,m,E,"⇁","\\rightharpoondown",!0);d(h,m,E,"↖","\\nwarrow",!0);d(h,m,E,"⇌","\\rightleftharpoons",!0);d(h,A,E,"≮","\\nless",!0);d(h,A,E,"","\\@nleqslant");d(h,A,E,"","\\@nleqq");d(h,A,E,"⪇","\\lneq",!0);d(h,A,E,"≨","\\lneqq",!0);d(h,A,E,"","\\@lvertneqq");d(h,A,E,"⋦","\\lnsim",!0);d(h,A,E,"⪉","\\lnapprox",!0);d(h,A,E,"⊀","\\nprec",!0);d(h,A,E,"⋠","\\npreceq",!0);d(h,A,E,"⋨","\\precnsim",!0);d(h,A,E,"⪹","\\precnapprox",!0);d(h,A,E,"≁","\\nsim",!0);d(h,A,E,"","\\@nshortmid");d(h,A,E,"∤","\\nmid",!0);d(h,A,E,"⊬","\\nvdash",!0);d(h,A,E,"⊭","\\nvDash",!0);d(h,A,E,"⋪","\\ntriangleleft");d(h,A,E,"⋬","\\ntrianglelefteq",!0);d(h,A,E,"⊊","\\subsetneq",!0);d(h,A,E,"","\\@varsubsetneq");d(h,A,E,"⫋","\\subsetneqq",!0);d(h,A,E,"","\\@varsubsetneqq");d(h,A,E,"≯","\\ngtr",!0);d(h,A,E,"","\\@ngeqslant");d(h,A,E,"","\\@ngeqq");d(h,A,E,"⪈","\\gneq",!0);d(h,A,E,"≩","\\gneqq",!0);d(h,A,E,"","\\@gvertneqq");d(h,A,E,"⋧","\\gnsim",!0);d(h,A,E,"⪊","\\gnapprox",!0);d(h,A,E,"⊁","\\nsucc",!0);d(h,A,E,"⋡","\\nsucceq",!0);d(h,A,E,"⋩","\\succnsim",!0);d(h,A,E,"⪺","\\succnapprox",!0);d(h,A,E,"≆","\\ncong",!0);d(h,A,E,"","\\@nshortparallel");d(h,A,E,"∦","\\nparallel",!0);d(h,A,E,"⊯","\\nVDash",!0);d(h,A,E,"⋫","\\ntriangleright");d(h,A,E,"⋭","\\ntrianglerighteq",!0);d(h,A,E,"","\\@nsupseteqq");d(h,A,E,"⊋","\\supsetneq",!0);d(h,A,E,"","\\@varsupsetneq");d(h,A,E,"⫌","\\supsetneqq",!0);d(h,A,E,"","\\@varsupsetneqq");d(h,A,E,"⊮","\\nVdash",!0);d(h,A,E,"⪵","\\precneqq",!0);d(h,A,E,"⪶","\\succneqq",!0);d(h,A,E,"","\\@nsubseteqq");d(h,A,fe,"⊴","\\unlhd");d(h,A,fe,"⊵","\\unrhd");d(h,A,E,"↚","\\nleftarrow",!0);d(h,A,E,"↛","\\nrightarrow",!0);d(h,A,E,"⇍","\\nLeftarrow",!0);d(h,A,E,"⇏","\\nRightarrow",!0);d(h,A,E,"↮","\\nleftrightarrow",!0);d(h,A,E,"⇎","\\nLeftrightarrow",!0);d(h,A,E,"△","\\vartriangle");d(h,A,R,"ℏ","\\hslash");d(h,A,R,"▽","\\triangledown");d(h,A,R,"◊","\\lozenge");d(h,A,R,"Ⓢ","\\circledS");d(h,A,R,"®","\\circledR");d(X,A,R,"®","\\circledR");d(h,A,R,"∡","\\measuredangle",!0);d(h,A,R,"∄","\\nexists");d(h,A,R,"℧","\\mho");d(h,A,R,"Ⅎ","\\Finv",!0);d(h,A,R,"⅁","\\Game",!0);d(h,A,R,"‵","\\backprime");d(h,A,R,"▲","\\blacktriangle");d(h,A,R,"▼","\\blacktriangledown");d(h,A,R,"■","\\blacksquare");d(h,A,R,"⧫","\\blacklozenge");d(h,A,R,"★","\\bigstar");d(h,A,R,"∢","\\sphericalangle",!0);d(h,A,R,"∁","\\complement",!0);d(h,A,R,"ð","\\eth",!0);d(X,m,R,"ð","ð");d(h,A,R,"╱","\\diagup");d(h,A,R,"╲","\\diagdown");d(h,A,R,"□","\\square");d(h,A,R,"□","\\Box");d(h,A,R,"◊","\\Diamond");d(h,A,R,"¥","\\yen",!0);d(X,A,R,"¥","\\yen",!0);d(h,A,R,"✓","\\checkmark",!0);d(X,A,R,"✓","\\checkmark");d(h,A,R,"ℶ","\\beth",!0);d(h,A,R,"ℸ","\\daleth",!0);d(h,A,R,"ℷ","\\gimel",!0);d(h,A,R,"ϝ","\\digamma",!0);d(h,A,R,"ϰ","\\varkappa");d(h,A,Jt,"┌","\\@ulcorner",!0);d(h,A,$t,"┐","\\@urcorner",!0);d(h,A,Jt,"└","\\@llcorner",!0);d(h,A,$t,"┘","\\@lrcorner",!0);d(h,A,E,"≦","\\leqq",!0);d(h,A,E,"⩽","\\leqslant",!0);d(h,A,E,"⪕","\\eqslantless",!0);d(h,A,E,"≲","\\lesssim",!0);d(h,A,E,"⪅","\\lessapprox",!0);d(h,A,E,"≊","\\approxeq",!0);d(h,A,fe,"⋖","\\lessdot");d(h,A,E,"⋘","\\lll",!0);d(h,A,E,"≶","\\lessgtr",!0);d(h,A,E,"⋚","\\lesseqgtr",!0);d(h,A,E,"⪋","\\lesseqqgtr",!0);d(h,A,E,"≑","\\doteqdot");d(h,A,E,"≓","\\risingdotseq",!0);d(h,A,E,"≒","\\fallingdotseq",!0);d(h,A,E,"∽","\\backsim",!0);d(h,A,E,"⋍","\\backsimeq",!0);d(h,A,E,"⫅","\\subseteqq",!0);d(h,A,E,"⋐","\\Subset",!0);d(h,A,E,"⊏","\\sqsubset",!0);d(h,A,E,"≼","\\preccurlyeq",!0);d(h,A,E,"⋞","\\curlyeqprec",!0);d(h,A,E,"≾","\\precsim",!0);d(h,A,E,"⪷","\\precapprox",!0);d(h,A,E,"⊲","\\vartriangleleft");d(h,A,E,"⊴","\\trianglelefteq");d(h,A,E,"⊨","\\vDash",!0);d(h,A,E,"⊪","\\Vvdash",!0);d(h,A,E,"⌣","\\smallsmile");d(h,A,E,"⌢","\\smallfrown");d(h,A,E,"≏","\\bumpeq",!0);d(h,A,E,"≎","\\Bumpeq",!0);d(h,A,E,"≧","\\geqq",!0);d(h,A,E,"⩾","\\geqslant",!0);d(h,A,E,"⪖","\\eqslantgtr",!0);d(h,A,E,"≳","\\gtrsim",!0);d(h,A,E,"⪆","\\gtrapprox",!0);d(h,A,fe,"⋗","\\gtrdot");d(h,A,E,"⋙","\\ggg",!0);d(h,A,E,"≷","\\gtrless",!0);d(h,A,E,"⋛","\\gtreqless",!0);d(h,A,E,"⪌","\\gtreqqless",!0);d(h,A,E,"≖","\\eqcirc",!0);d(h,A,E,"≗","\\circeq",!0);d(h,A,E,"≜","\\triangleq",!0);d(h,A,E,"∼","\\thicksim");d(h,A,E,"≈","\\thickapprox");d(h,A,E,"⫆","\\supseteqq",!0);d(h,A,E,"⋑","\\Supset",!0);d(h,A,E,"⊐","\\sqsupset",!0);d(h,A,E,"≽","\\succcurlyeq",!0);d(h,A,E,"⋟","\\curlyeqsucc",!0);d(h,A,E,"≿","\\succsim",!0);d(h,A,E,"⪸","\\succapprox",!0);d(h,A,E,"⊳","\\vartriangleright");d(h,A,E,"⊵","\\trianglerighteq");d(h,A,E,"⊩","\\Vdash",!0);d(h,A,E,"∣","\\shortmid");d(h,A,E,"∥","\\shortparallel");d(h,A,E,"≬","\\between",!0);d(h,A,E,"⋔","\\pitchfork",!0);d(h,A,E,"∝","\\varpropto");d(h,A,E,"◀","\\blacktriangleleft");d(h,A,E,"∴","\\therefore",!0);d(h,A,E,"∍","\\backepsilon");d(h,A,E,"▶","\\blacktriangleright");d(h,A,E,"∵","\\because",!0);d(h,A,E,"⋘","\\llless");d(h,A,E,"⋙","\\gggtr");d(h,A,fe,"⊲","\\lhd");d(h,A,fe,"⊳","\\rhd");d(h,A,E,"≂","\\eqsim",!0);d(h,m,E,"⋈","\\Join");d(h,A,E,"≑","\\Doteq",!0);d(h,A,fe,"∔","\\dotplus",!0);d(h,A,fe,"∖","\\smallsetminus");d(h,A,fe,"⋒","\\Cap",!0);d(h,A,fe,"⋓","\\Cup",!0);d(h,A,fe,"⩞","\\doublebarwedge",!0);d(h,A,fe,"⊟","\\boxminus",!0);d(h,A,fe,"⊞","\\boxplus",!0);d(h,A,fe,"⋇","\\divideontimes",!0);d(h,A,fe,"⋉","\\ltimes",!0);d(h,A,fe,"⋊","\\rtimes",!0);d(h,A,fe,"⋋","\\leftthreetimes",!0);d(h,A,fe,"⋌","\\rightthreetimes",!0);d(h,A,fe,"⋏","\\curlywedge",!0);d(h,A,fe,"⋎","\\curlyvee",!0);d(h,A,fe,"⊝","\\circleddash",!0);d(h,A,fe,"⊛","\\circledast",!0);d(h,A,fe,"⋅","\\centerdot");d(h,A,fe,"⊺","\\intercal",!0);d(h,A,fe,"⋒","\\doublecap");d(h,A,fe,"⋓","\\doublecup");d(h,A,fe,"⊠","\\boxtimes",!0);d(h,A,E,"⇢","\\dashrightarrow",!0);d(h,A,E,"⇠","\\dashleftarrow",!0);d(h,A,E,"⇇","\\leftleftarrows",!0);d(h,A,E,"⇆","\\leftrightarrows",!0);d(h,A,E,"⇚","\\Lleftarrow",!0);d(h,A,E,"↞","\\twoheadleftarrow",!0);d(h,A,E,"↢","\\leftarrowtail",!0);d(h,A,E,"↫","\\looparrowleft",!0);d(h,A,E,"⇋","\\leftrightharpoons",!0);d(h,A,E,"↶","\\curvearrowleft",!0);d(h,A,E,"↺","\\circlearrowleft",!0);d(h,A,E,"↰","\\Lsh",!0);d(h,A,E,"⇈","\\upuparrows",!0);d(h,A,E,"↿","\\upharpoonleft",!0);d(h,A,E,"⇃","\\downharpoonleft",!0);d(h,m,E,"⊶","\\origof",!0);d(h,m,E,"⊷","\\imageof",!0);d(h,A,E,"⊸","\\multimap",!0);d(h,A,E,"↭","\\leftrightsquigarrow",!0);d(h,A,E,"⇉","\\rightrightarrows",!0);d(h,A,E,"⇄","\\rightleftarrows",!0);d(h,A,E,"↠","\\twoheadrightarrow",!0);d(h,A,E,"↣","\\rightarrowtail",!0);d(h,A,E,"↬","\\looparrowright",!0);d(h,A,E,"↷","\\curvearrowright",!0);d(h,A,E,"↻","\\circlearrowright",!0);d(h,A,E,"↱","\\Rsh",!0);d(h,A,E,"⇊","\\downdownarrows",!0);d(h,A,E,"↾","\\upharpoonright",!0);d(h,A,E,"⇂","\\downharpoonright",!0);d(h,A,E,"⇝","\\rightsquigarrow",!0);d(h,A,E,"⇝","\\leadsto");d(h,A,E,"⇛","\\Rrightarrow",!0);d(h,A,E,"↾","\\restriction");d(h,m,R,"‘","`");d(h,m,R,"$","\\$");d(X,m,R,"$","\\$");d(X,m,R,"$","\\textdollar");d(h,m,R,"%","\\%");d(X,m,R,"%","\\%");d(h,m,R,"_","\\_");d(X,m,R,"_","\\_");d(X,m,R,"_","\\textunderscore");d(h,m,R,"∠","\\angle",!0);d(h,m,R,"∞","\\infty",!0);d(h,m,R,"′","\\prime");d(h,m,R,"△","\\triangle");d(h,m,R,"Γ","\\Gamma",!0);d(h,m,R,"Δ","\\Delta",!0);d(h,m,R,"Θ","\\Theta",!0);d(h,m,R,"Λ","\\Lambda",!0);d(h,m,R,"Ξ","\\Xi",!0);d(h,m,R,"Π","\\Pi",!0);d(h,m,R,"Σ","\\Sigma",!0);d(h,m,R,"Υ","\\Upsilon",!0);d(h,m,R,"Φ","\\Phi",!0);d(h,m,R,"Ψ","\\Psi",!0);d(h,m,R,"Ω","\\Omega",!0);d(h,m,R,"A","Α");d(h,m,R,"B","Β");d(h,m,R,"E","Ε");d(h,m,R,"Z","Ζ");d(h,m,R,"H","Η");d(h,m,R,"I","Ι");d(h,m,R,"K","Κ");d(h,m,R,"M","Μ");d(h,m,R,"N","Ν");d(h,m,R,"O","Ο");d(h,m,R,"P","Ρ");d(h,m,R,"T","Τ");d(h,m,R,"X","Χ");d(h,m,R,"¬","\\neg",!0);d(h,m,R,"¬","\\lnot");d(h,m,R,"⊤","\\top");d(h,m,R,"⊥","\\bot");d(h,m,R,"∅","\\emptyset");d(h,A,R,"∅","\\varnothing");d(h,m,we,"α","\\alpha",!0);d(h,m,we,"β","\\beta",!0);d(h,m,we,"γ","\\gamma",!0);d(h,m,we,"δ","\\delta",!0);d(h,m,we,"ϵ","\\epsilon",!0);d(h,m,we,"ζ","\\zeta",!0);d(h,m,we,"η","\\eta",!0);d(h,m,we,"θ","\\theta",!0);d(h,m,we,"ι","\\iota",!0);d(h,m,we,"κ","\\kappa",!0);d(h,m,we,"λ","\\lambda",!0);d(h,m,we,"μ","\\mu",!0);d(h,m,we,"ν","\\nu",!0);d(h,m,we,"ξ","\\xi",!0);d(h,m,we,"ο","\\omicron",!0);d(h,m,we,"π","\\pi",!0);d(h,m,we,"ρ","\\rho",!0);d(h,m,we,"σ","\\sigma",!0);d(h,m,we,"τ","\\tau",!0);d(h,m,we,"υ","\\upsilon",!0);d(h,m,we,"ϕ","\\phi",!0);d(h,m,we,"χ","\\chi",!0);d(h,m,we,"ψ","\\psi",!0);d(h,m,we,"ω","\\omega",!0);d(h,m,we,"ε","\\varepsilon",!0);d(h,m,we,"ϑ","\\vartheta",!0);d(h,m,we,"ϖ","\\varpi",!0);d(h,m,we,"ϱ","\\varrho",!0);d(h,m,we,"ς","\\varsigma",!0);d(h,m,we,"φ","\\varphi",!0);d(h,m,fe,"∗","*",!0);d(h,m,fe,"+","+");d(h,m,fe,"−","-",!0);d(h,m,fe,"⋅","\\cdot",!0);d(h,m,fe,"∘","\\circ",!0);d(h,m,fe,"÷","\\div",!0);d(h,m,fe,"±","\\pm",!0);d(h,m,fe,"×","\\times",!0);d(h,m,fe,"∩","\\cap",!0);d(h,m,fe,"∪","\\cup",!0);d(h,m,fe,"∖","\\setminus",!0);d(h,m,fe,"∧","\\land");d(h,m,fe,"∨","\\lor");d(h,m,fe,"∧","\\wedge",!0);d(h,m,fe,"∨","\\vee",!0);d(h,m,R,"√","\\surd");d(h,m,Jt,"⟨","\\langle",!0);d(h,m,Jt,"∣","\\lvert");d(h,m,Jt,"∥","\\lVert");d(h,m,$t,"?","?");d(h,m,$t,"!","!");d(h,m,$t,"⟩","\\rangle",!0);d(h,m,$t,"∣","\\rvert");d(h,m,$t,"∥","\\rVert");d(h,m,E,"=","=");d(h,m,E,":",":");d(h,m,E,"≈","\\approx",!0);d(h,m,E,"≅","\\cong",!0);d(h,m,E,"≥","\\ge");d(h,m,E,"≥","\\geq",!0);d(h,m,E,"←","\\gets");d(h,m,E,">","\\gt",!0);d(h,m,E,"∈","\\in",!0);d(h,m,E,"","\\@not");d(h,m,E,"⊂","\\subset",!0);d(h,m,E,"⊃","\\supset",!0);d(h,m,E,"⊆","\\subseteq",!0);d(h,m,E,"⊇","\\supseteq",!0);d(h,A,E,"⊈","\\nsubseteq",!0);d(h,A,E,"⊉","\\nsupseteq",!0);d(h,m,E,"⊨","\\models");d(h,m,E,"←","\\leftarrow",!0);d(h,m,E,"≤","\\le");d(h,m,E,"≤","\\leq",!0);d(h,m,E,"<","\\lt",!0);d(h,m,E,"→","\\rightarrow",!0);d(h,m,E,"→","\\to");d(h,A,E,"≱","\\ngeq",!0);d(h,A,E,"≰","\\nleq",!0);d(h,m,Vr," ","\\ ");d(h,m,Vr," ","\\space");d(h,m,Vr," ","\\nobreakspace");d(X,m,Vr," ","\\ ");d(X,m,Vr," "," ");d(X,m,Vr," ","\\space");d(X,m,Vr," ","\\nobreakspace");d(h,m,Vr,null,"\\nobreak");d(h,m,Vr,null,"\\allowbreak");d(h,m,fs,",",",");d(h,m,fs,";",";");d(h,A,fe,"⊼","\\barwedge",!0);d(h,A,fe,"⊻","\\veebar",!0);d(h,m,fe,"⊙","\\odot",!0);d(h,m,fe,"⊕","\\oplus",!0);d(h,m,fe,"⊗","\\otimes",!0);d(h,m,R,"∂","\\partial",!0);d(h,m,fe,"⊘","\\oslash",!0);d(h,A,fe,"⊚","\\circledcirc",!0);d(h,A,fe,"⊡","\\boxdot",!0);d(h,m,fe,"△","\\bigtriangleup");d(h,m,fe,"▽","\\bigtriangledown");d(h,m,fe,"†","\\dagger");d(h,m,fe,"⋄","\\diamond");d(h,m,fe,"⋆","\\star");d(h,m,fe,"◃","\\triangleleft");d(h,m,fe,"▹","\\triangleright");d(h,m,Jt,"{","\\{");d(X,m,R,"{","\\{");d(X,m,R,"{","\\textbraceleft");d(h,m,$t,"}","\\}");d(X,m,R,"}","\\}");d(X,m,R,"}","\\textbraceright");d(h,m,Jt,"{","\\lbrace");d(h,m,$t,"}","\\rbrace");d(h,m,Jt,"[","\\lbrack",!0);d(X,m,R,"[","\\lbrack",!0);d(h,m,$t,"]","\\rbrack",!0);d(X,m,R,"]","\\rbrack",!0);d(h,m,Jt,"(","\\lparen",!0);d(h,m,$t,")","\\rparen",!0);d(X,m,R,"<","\\textless",!0);d(X,m,R,">","\\textgreater",!0);d(h,m,Jt,"⌊","\\lfloor",!0);d(h,m,$t,"⌋","\\rfloor",!0);d(h,m,Jt,"⌈","\\lceil",!0);d(h,m,$t,"⌉","\\rceil",!0);d(h,m,R,"\\","\\backslash");d(h,m,R,"∣","|");d(h,m,R,"∣","\\vert");d(X,m,R,"|","\\textbar",!0);d(h,m,R,"∥","\\|");d(h,m,R,"∥","\\Vert");d(X,m,R,"∥","\\textbardbl");d(X,m,R,"~","\\textasciitilde");d(X,m,R,"\\","\\textbackslash");d(X,m,R,"^","\\textasciicircum");d(h,m,E,"↑","\\uparrow",!0);d(h,m,E,"⇑","\\Uparrow",!0);d(h,m,E,"↓","\\downarrow",!0);d(h,m,E,"⇓","\\Downarrow",!0);d(h,m,E,"↕","\\updownarrow",!0);d(h,m,E,"⇕","\\Updownarrow",!0);d(h,m,mt,"∐","\\coprod");d(h,m,mt,"⋁","\\bigvee");d(h,m,mt,"⋀","\\bigwedge");d(h,m,mt,"⨄","\\biguplus");d(h,m,mt,"⋂","\\bigcap");d(h,m,mt,"⋃","\\bigcup");d(h,m,mt,"∫","\\int");d(h,m,mt,"∫","\\intop");d(h,m,mt,"∬","\\iint");d(h,m,mt,"∭","\\iiint");d(h,m,mt,"∏","\\prod");d(h,m,mt,"∑","\\sum");d(h,m,mt,"⨂","\\bigotimes");d(h,m,mt,"⨁","\\bigoplus");d(h,m,mt,"⨀","\\bigodot");d(h,m,mt,"∮","\\oint");d(h,m,mt,"∯","\\oiint");d(h,m,mt,"∰","\\oiiint");d(h,m,mt,"⨆","\\bigsqcup");d(h,m,mt,"∫","\\smallint");d(X,m,Xn,"…","\\textellipsis");d(h,m,Xn,"…","\\mathellipsis");d(X,m,Xn,"…","\\ldots",!0);d(h,m,Xn,"…","\\ldots",!0);d(h,m,Xn,"⋯","\\@cdots",!0);d(h,m,Xn,"⋱","\\ddots",!0);d(h,m,R,"⋮","\\varvdots");d(X,m,R,"⋮","\\varvdots");d(h,m,it,"ˊ","\\acute");d(h,m,it,"ˋ","\\grave");d(h,m,it,"¨","\\ddot");d(h,m,it,"~","\\tilde");d(h,m,it,"ˉ","\\bar");d(h,m,it,"˘","\\breve");d(h,m,it,"ˇ","\\check");d(h,m,it,"^","\\hat");d(h,m,it,"⃗","\\vec");d(h,m,it,"˙","\\dot");d(h,m,it,"˚","\\mathring");d(h,m,we,"","\\@imath");d(h,m,we,"","\\@jmath");d(h,m,R,"ı","ı");d(h,m,R,"ȷ","ȷ");d(X,m,R,"ı","\\i",!0);d(X,m,R,"ȷ","\\j",!0);d(X,m,R,"ß","\\ss",!0);d(X,m,R,"æ","\\ae",!0);d(X,m,R,"œ","\\oe",!0);d(X,m,R,"ø","\\o",!0);d(X,m,R,"Æ","\\AE",!0);d(X,m,R,"Œ","\\OE",!0);d(X,m,R,"Ø","\\O",!0);d(X,m,it,"ˊ","\\'");d(X,m,it,"ˋ","\\`");d(X,m,it,"ˆ","\\^");d(X,m,it,"˜","\\~");d(X,m,it,"ˉ","\\=");d(X,m,it,"˘","\\u");d(X,m,it,"˙","\\.");d(X,m,it,"¸","\\c");d(X,m,it,"˚","\\r");d(X,m,it,"ˇ","\\v");d(X,m,it,"¨",'\\"');d(X,m,it,"˝","\\H");d(X,m,it,"◯","\\textcircled");var ld={"--":!0,"---":!0,"``":!0,"''":!0};d(X,m,R,"–","--",!0);d(X,m,R,"–","\\textendash");d(X,m,R,"—","---",!0);d(X,m,R,"—","\\textemdash");d(X,m,R,"‘","`",!0);d(X,m,R,"‘","\\textquoteleft");d(X,m,R,"’","'",!0);d(X,m,R,"’","\\textquoteright");d(X,m,R,"“","``",!0);d(X,m,R,"“","\\textquotedblleft");d(X,m,R,"”","''",!0);d(X,m,R,"”","\\textquotedblright");d(h,m,R,"°","\\degree",!0);d(X,m,R,"°","\\degree");d(X,m,R,"°","\\textdegree",!0);d(h,m,R,"£","\\pounds");d(h,m,R,"£","\\mathsterling",!0);d(X,m,R,"£","\\pounds");d(X,m,R,"£","\\textsterling",!0);d(h,A,R,"✠","\\maltese");d(X,A,R,"✠","\\maltese");var gc='0123456789/@."';for(var Fs=0;Fs<gc.length;Fs++){var vc=gc.charAt(Fs);d(h,m,R,vc,vc)}var bc='0123456789!@*()-=+";:?/.,';for(var Bs=0;Bs<bc.length;Bs++){var yc=bc.charAt(Bs);d(X,m,R,yc,yc)}var Hi="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";for(var Ps=0;Ps<Hi.length;Ps++){var ei=Hi.charAt(Ps);d(h,m,we,ei,ei),d(X,m,R,ei,ei)}d(h,A,R,"C","ℂ");d(X,A,R,"C","ℂ");d(h,A,R,"H","ℍ");d(X,A,R,"H","ℍ");d(h,A,R,"N","ℕ");d(X,A,R,"N","ℕ");d(h,A,R,"P","ℙ");d(X,A,R,"P","ℙ");d(h,A,R,"Q","ℚ");d(X,A,R,"Q","ℚ");d(h,A,R,"R","ℝ");d(X,A,R,"R","ℝ");d(h,A,R,"Z","ℤ");d(X,A,R,"Z","ℤ");d(h,m,we,"h","ℎ");d(X,m,we,"h","ℎ");var Te="";for(var Rt=0;Rt<Hi.length;Rt++){var ct=Hi.charAt(Rt);Te=String.fromCharCode(55349,56320+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56372+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56424+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56580+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56684+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56736+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56788+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56840+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56944+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Rt<26&&(Te=String.fromCharCode(55349,56632+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te),Te=String.fromCharCode(55349,56476+Rt),d(h,m,we,ct,Te),d(X,m,R,ct,Te))}Te=String.fromCharCode(55349,56668);d(h,m,we,"k",Te);d(X,m,R,"k",Te);for(var gn=0;gn<10;gn++){var Yr=gn.toString();Te=String.fromCharCode(55349,57294+gn),d(h,m,we,Yr,Te),d(X,m,R,Yr,Te),Te=String.fromCharCode(55349,57314+gn),d(h,m,we,Yr,Te),d(X,m,R,Yr,Te),Te=String.fromCharCode(55349,57324+gn),d(h,m,we,Yr,Te),d(X,m,R,Yr,Te),Te=String.fromCharCode(55349,57334+gn),d(h,m,we,Yr,Te),d(X,m,R,Yr,Te)}var Ma="ÐÞþ";for(var Hs=0;Hs<Ma.length;Hs++){var ti=Ma.charAt(Hs);d(h,m,we,ti,ti),d(X,m,R,ti,ti)}var ri=[["mathbf","textbf","Main-Bold"],["mathbf","textbf","Main-Bold"],["mathnormal","textit","Math-Italic"],["mathnormal","textit","Math-Italic"],["boldsymbol","boldsymbol","Main-BoldItalic"],["boldsymbol","boldsymbol","Main-BoldItalic"],["mathscr","textscr","Script-Regular"],["","",""],["","",""],["","",""],["mathfrak","textfrak","Fraktur-Regular"],["mathfrak","textfrak","Fraktur-Regular"],["mathbb","textbb","AMS-Regular"],["mathbb","textbb","AMS-Regular"],["mathboldfrak","textboldfrak","Fraktur-Regular"],["mathboldfrak","textboldfrak","Fraktur-Regular"],["mathsf","textsf","SansSerif-Regular"],["mathsf","textsf","SansSerif-Regular"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathitsf","textitsf","SansSerif-Italic"],["mathitsf","textitsf","SansSerif-Italic"],["","",""],["","",""],["mathtt","texttt","Typewriter-Regular"],["mathtt","texttt","Typewriter-Regular"]],wc=[["mathbf","textbf","Main-Bold"],["","",""],["mathsf","textsf","SansSerif-Regular"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathtt","texttt","Typewriter-Regular"]],s5=function(e,r){var n=e.charCodeAt(0),i=e.charCodeAt(1),s=(n-55296)*1024+(i-56320)+65536,a=r==="math"?0:1;if(119808<=s&&s<120484){var o=Math.floor((s-119808)/26);return[ri[o][2],ri[o][a]]}else if(120782<=s&&s<=120831){var l=Math.floor((s-120782)/10);return[wc[l][2],wc[l][a]]}else{if(s===120485||s===120486)return[ri[0][2],ri[0][a]];if(120486<s&&s<120782)return["",""];throw new te("Unsupported character: "+e)}},ps=function(e,r,n){return tt[n][e]&&tt[n][e].replace&&(e=tt[n][e].replace),{value:e,metrics:No(e,r,n)}},cr=function(e,r,n,i,s){var a=ps(e,r,n),o=a.metrics;e=a.value;var l;if(o){var c=o.italic;(n==="text"||i&&i.font==="mathit")&&(c=0),l=new sr(e,o.height,o.depth,c,o.skew,o.width,s)}else typeof console<"u"&&console.warn("No character metrics "+("for '"+e+"' in style '"+r+"' and mode '"+n+"'")),l=new sr(e,0,0,0,0,0,s);if(i){l.maxFontSize=i.sizeMultiplier,i.style.isTight()&&l.classes.push("mtight");var u=i.getColor();u&&(l.style.color=u)}return l},a5=function(e,r,n,i){return i===void 0&&(i=[]),n.font==="boldsymbol"&&ps(e,"Main-Bold",r).metrics?cr(e,"Main-Bold",r,n,i.concat(["mathbf"])):e==="\\"||tt[r][e].font==="main"?cr(e,"Main-Regular",r,n,i):cr(e,"AMS-Regular",r,n,i.concat(["amsrm"]))},o5=function(e,r,n,i,s){return s!=="textord"&&ps(e,"Math-BoldItalic",r).metrics?{fontName:"Math-BoldItalic",fontClass:"boldsymbol"}:{fontName:"Main-Bold",fontClass:"mathbf"}},l5=function(e,r,n){var i=e.mode,s=e.text,a=["mord"],o=i==="math"||i==="text"&&r.font,l=o?r.font:r.fontFamily,c="",u="";if(s.charCodeAt(0)===55349&&([c,u]=s5(s,i)),c.length>0)return cr(s,c,i,r,a.concat(u));if(l){var f,p;if(l==="boldsymbol"){var g=o5(s,i,r,a,n);f=g.fontName,p=[g.fontClass]}else o?(f=dd[l].fontName,p=[l]):(f=ni(l,r.fontWeight,r.fontShape),p=[l,r.fontWeight,r.fontShape]);if(ps(s,f,i).metrics)return cr(s,f,i,r,a.concat(p));if(ld.hasOwnProperty(s)&&f.slice(0,10)==="Typewriter"){for(var b=[],x=0;x<s.length;x++)b.push(cr(s[x],f,i,r,a.concat(p)));return ud(b)}}if(n==="mathord")return cr(s,"Math-Italic",i,r,a.concat(["mathnormal"]));if(n==="textord"){var w=tt[i][s]&&tt[i][s].font;if(w==="ams"){var N=ni("amsrm",r.fontWeight,r.fontShape);return cr(s,N,i,r,a.concat("amsrm",r.fontWeight,r.fontShape))}else if(w==="main"||!w){var y=ni("textrm",r.fontWeight,r.fontShape);return cr(s,y,i,r,a.concat(r.fontWeight,r.fontShape))}else{var k=ni(w,r.fontWeight,r.fontShape);return cr(s,k,i,r,a.concat(k,r.fontWeight,r.fontShape))}}else throw new Error("unexpected type: "+n+" in makeOrd")},c5=(t,e)=>{if(sn(t.classes)!==sn(e.classes)||t.skew!==e.skew||t.maxFontSize!==e.maxFontSize)return!1;if(t.classes.length===1){var r=t.classes[0];if(r==="mbin"||r==="mord")return!1}for(var n in t.style)if(t.style.hasOwnProperty(n)&&t.style[n]!==e.style[n])return!1;for(var i in e.style)if(e.style.hasOwnProperty(i)&&t.style[i]!==e.style[i])return!1;return!0},u5=t=>{for(var e=0;e<t.length-1;e++){var r=t[e],n=t[e+1];r instanceof sr&&n instanceof sr&&c5(r,n)&&(r.text+=n.text,r.height=Math.max(r.height,n.height),r.depth=Math.max(r.depth,n.depth),r.italic=n.italic,t.splice(e+1,1),e--)}return t},Ro=function(e){for(var r=0,n=0,i=0,s=0;s<e.children.length;s++){var a=e.children[s];a.height>r&&(r=a.height),a.depth>n&&(n=a.depth),a.maxFontSize>i&&(i=a.maxFontSize)}e.height=r,e.depth=n,e.maxFontSize=i},qt=function(e,r,n,i){var s=new z0(e,r,n,i);return Ro(s),s},cd=(t,e,r,n)=>new z0(t,e,r,n),d5=function(e,r,n){var i=qt([e],[],r);return i.height=Math.max(n||r.fontMetrics().defaultRuleThickness,r.minRuleThickness),i.style.borderBottomWidth=se(i.height),i.maxFontSize=1,i},h5=function(e,r,n,i){var s=new Io(e,r,n,i);return Ro(s),s},ud=function(e){var r=new L0(e);return Ro(r),r},f5=function(e,r){return e instanceof L0?qt([],[e],r):e},p5=function(e){if(e.positionType==="individualShift"){for(var r=e.children,n=[r[0]],i=-r[0].shift-r[0].elem.depth,s=i,a=1;a<r.length;a++){var o=-r[a].shift-s-r[a].elem.depth,l=o-(r[a-1].elem.height+r[a-1].elem.depth);s=s+o,n.push({type:"kern",size:l}),n.push(r[a])}return{children:n,depth:i}}var c;if(e.positionType==="top"){for(var u=e.positionData,f=0;f<e.children.length;f++){var p=e.children[f];u-=p.type==="kern"?p.size:p.elem.height+p.elem.depth}c=u}else if(e.positionType==="bottom")c=-e.positionData;else{var g=e.children[0];if(g.type!=="elem")throw new Error('First child must have type "elem".');if(e.positionType==="shift")c=-g.elem.depth-e.positionData;else if(e.positionType==="firstBaseline")c=-g.elem.depth;else throw new Error("Invalid positionType "+e.positionType+".")}return{children:e.children,depth:c}},m5=function(e,r){for(var{children:n,depth:i}=p5(e),s=0,a=0;a<n.length;a++){var o=n[a];if(o.type==="elem"){var l=o.elem;s=Math.max(s,l.maxFontSize,l.height)}}s+=2;var c=qt(["pstrut"],[]);c.style.height=se(s);for(var u=[],f=i,p=i,g=i,b=0;b<n.length;b++){var x=n[b];if(x.type==="kern")g+=x.size;else{var w=x.elem,N=x.wrapperClasses||[],y=x.wrapperStyle||{},k=qt(N,[c,w],void 0,y);k.style.top=se(-s-g-w.depth),x.marginLeft&&(k.style.marginLeft=x.marginLeft),x.marginRight&&(k.style.marginRight=x.marginRight),u.push(k),g+=w.height+w.depth}f=Math.min(f,g),p=Math.max(p,g)}var I=qt(["vlist"],u);I.style.height=se(p);var D;if(f<0){var O=qt([],[]),z=qt(["vlist"],[O]);z.style.height=se(-f);var W=qt(["vlist-s"],[new sr("")]);D=[qt(["vlist-r"],[I,W]),qt(["vlist-r"],[z])]}else D=[qt(["vlist-r"],[I])];var H=qt(["vlist-t"],D);return D.length===2&&H.classes.push("vlist-t2"),H.height=p,H.depth=-f,H},g5=(t,e)=>{var r=qt(["mspace"],[],e),n=at(t,e);return r.style.marginRight=se(n),r},ni=function(e,r,n){var i="";switch(e){case"amsrm":i="AMS";break;case"textrm":i="Main";break;case"textsf":i="SansSerif";break;case"texttt":i="Typewriter";break;default:i=e}var s;return r==="textbf"&&n==="textit"?s="BoldItalic":r==="textbf"?s="Bold":r==="textit"?s="Italic":s="Regular",i+"-"+s},dd={mathbf:{variant:"bold",fontName:"Main-Bold"},mathrm:{variant:"normal",fontName:"Main-Regular"},textit:{variant:"italic",fontName:"Main-Italic"},mathit:{variant:"italic",fontName:"Main-Italic"},mathnormal:{variant:"italic",fontName:"Math-Italic"},mathsfit:{variant:"sans-serif-italic",fontName:"SansSerif-Italic"},mathbb:{variant:"double-struck",fontName:"AMS-Regular"},mathcal:{variant:"script",fontName:"Caligraphic-Regular"},mathfrak:{variant:"fraktur",fontName:"Fraktur-Regular"},mathscr:{variant:"script",fontName:"Script-Regular"},mathsf:{variant:"sans-serif",fontName:"SansSerif-Regular"},mathtt:{variant:"monospace",fontName:"Typewriter-Regular"}},hd={vec:["vec",.471,.714],oiintSize1:["oiintSize1",.957,.499],oiintSize2:["oiintSize2",1.472,.659],oiiintSize1:["oiiintSize1",1.304,.499],oiiintSize2:["oiiintSize2",1.98,.659]},v5=function(e,r){var[n,i,s]=hd[e],a=new an(n),o=new Hr([a],{width:se(i),height:se(s),style:"width:"+se(i),viewBox:"0 0 "+1e3*i+" "+1e3*s,preserveAspectRatio:"xMinYMin"}),l=cd(["overlay"],[o],r);return l.height=s,l.style.height=se(s),l.style.width=se(i),l},F={fontMap:dd,makeSymbol:cr,mathsym:a5,makeSpan:qt,makeSvgSpan:cd,makeLineSpan:d5,makeAnchor:h5,makeFragment:ud,wrapFragment:f5,makeVList:m5,makeOrd:l5,makeGlue:g5,staticSvg:v5,svgData:hd,tryCombineChars:u5},st={number:3,unit:"mu"},vn={number:4,unit:"mu"},Ir={number:5,unit:"mu"},b5={mord:{mop:st,mbin:vn,mrel:Ir,minner:st},mop:{mord:st,mop:st,mrel:Ir,minner:st},mbin:{mord:vn,mop:vn,mopen:vn,minner:vn},mrel:{mord:Ir,mop:Ir,mopen:Ir,minner:Ir},mopen:{},mclose:{mop:st,mbin:vn,mrel:Ir,minner:st},mpunct:{mord:st,mop:st,mrel:Ir,mopen:st,mclose:st,mpunct:st,minner:st},minner:{mord:st,mop:st,mbin:vn,mrel:Ir,mopen:st,mpunct:st,minner:st}},y5={mord:{mop:st},mop:{mord:st,mop:st},mbin:{},mrel:{},mopen:{},mclose:{mop:st},mpunct:{},minner:{mop:st}},fd={},qi={},ji={};function ce(t){for(var{type:e,names:r,props:n,handler:i,htmlBuilder:s,mathmlBuilder:a}=t,o={type:e,numArgs:n.numArgs,argTypes:n.argTypes,allowedInArgument:!!n.allowedInArgument,allowedInText:!!n.allowedInText,allowedInMath:n.allowedInMath===void 0?!0:n.allowedInMath,numOptionalArgs:n.numOptionalArgs||0,infix:!!n.infix,primitive:!!n.primitive,handler:i},l=0;l<r.length;++l)fd[r[l]]=o;e&&(s&&(qi[e]=s),a&&(ji[e]=a))}function En(t){var{type:e,htmlBuilder:r,mathmlBuilder:n}=t;ce({type:e,names:[],props:{numArgs:0},handler(){throw new Error("Should never be called.")},htmlBuilder:r,mathmlBuilder:n})}var Ui=function(e){return e.type==="ordgroup"&&e.body.length===1?e.body[0]:e},dt=function(e){return e.type==="ordgroup"?e.body:[e]},qr=F.makeSpan,w5=["leftmost","mbin","mopen","mrel","mop","mpunct"],x5=["rightmost","mrel","mclose","mpunct"],k5={display:xe.DISPLAY,text:xe.TEXT,script:xe.SCRIPT,scriptscript:xe.SCRIPTSCRIPT},S5={mord:"mord",mop:"mop",mbin:"mbin",mrel:"mrel",mopen:"mopen",mclose:"mclose",mpunct:"mpunct",minner:"minner"},bt=function(e,r,n,i){i===void 0&&(i=[null,null]);for(var s=[],a=0;a<e.length;a++){var o=$e(e[a],r);if(o instanceof L0){var l=o.children;s.push(...l)}else s.push(o)}if(F.tryCombineChars(s),!n)return s;var c=r;if(e.length===1){var u=e[0];u.type==="sizing"?c=r.havingSize(u.size):u.type==="styling"&&(c=r.havingStyle(k5[u.style]))}var f=qr([i[0]||"leftmost"],[],r),p=qr([i[1]||"rightmost"],[],r),g=n==="root";return xc(s,(b,x)=>{var w=x.classes[0],N=b.classes[0];w==="mbin"&&ve.contains(x5,N)?x.classes[0]="mord":N==="mbin"&&ve.contains(w5,w)&&(b.classes[0]="mord")},{node:f},p,g),xc(s,(b,x)=>{var w=Na(x),N=Na(b),y=w&&N?b.hasClass("mtight")?y5[w][N]:b5[w][N]:null;if(y)return F.makeGlue(y,c)},{node:f},p,g),s},xc=function t(e,r,n,i,s){i&&e.push(i);for(var a=0;a<e.length;a++){var o=e[a],l=pd(o);if(l){t(l.children,r,n,null,s);continue}var c=!o.hasClass("mspace");if(c){var u=r(o,n.node);u&&(n.insertAfter?n.insertAfter(u):(e.unshift(u),a++))}c?n.node=o:s&&o.hasClass("newline")&&(n.node=qr(["leftmost"])),n.insertAfter=(f=>p=>{e.splice(f+1,0,p),a++})(a)}i&&e.pop()},pd=function(e){return e instanceof L0||e instanceof Io||e instanceof z0&&e.hasClass("enclosing")?e:null},T5=function t(e,r){var n=pd(e);if(n){var i=n.children;if(i.length){if(r==="right")return t(i[i.length-1],"right");if(r==="left")return t(i[0],"left")}}return e},Na=function(e,r){return e?(r&&(e=T5(e,r)),S5[e.classes[0]]||null):null},A0=function(e,r){var n=["nulldelimiter"].concat(e.baseSizingClasses());return qr(r.concat(n))},$e=function(e,r,n){if(!e)return qr();if(qi[e.type]){var i=qi[e.type](e,r);if(n&&r.size!==n.size){i=qr(r.sizingClasses(n),[i],r);var s=r.sizeMultiplier/n.sizeMultiplier;i.height*=s,i.depth*=s}return i}else throw new te("Got group of unknown type: '"+e.type+"'")};function ii(t,e){var r=qr(["base"],t,e),n=qr(["strut"]);return n.style.height=se(r.height+r.depth),r.depth&&(n.style.verticalAlign=se(-r.depth)),r.children.unshift(n),r}function Ia(t,e){var r=null;t.length===1&&t[0].type==="tag"&&(r=t[0].tag,t=t[0].body);var n=bt(t,e,"root"),i;n.length===2&&n[1].hasClass("tag")&&(i=n.pop());for(var s=[],a=[],o=0;o<n.length;o++)if(a.push(n[o]),n[o].hasClass("mbin")||n[o].hasClass("mrel")||n[o].hasClass("allowbreak")){for(var l=!1;o<n.length-1&&n[o+1].hasClass("mspace")&&!n[o+1].hasClass("newline");)o++,a.push(n[o]),n[o].hasClass("nobreak")&&(l=!0);l||(s.push(ii(a,e)),a=[])}else n[o].hasClass("newline")&&(a.pop(),a.length>0&&(s.push(ii(a,e)),a=[]),s.push(n[o]));a.length>0&&s.push(ii(a,e));var c;r?(c=ii(bt(r,e,!0)),c.classes=["tag"],s.push(c)):i&&s.push(i);var u=qr(["katex-html"],s);if(u.setAttribute("aria-hidden","true"),c){var f=c.children[0];f.style.height=se(u.height+u.depth),u.depth&&(f.style.verticalAlign=se(-u.depth))}return u}function md(t){return new L0(t)}class Kt{constructor(e,r,n){this.type=void 0,this.attributes=void 0,this.children=void 0,this.classes=void 0,this.type=e,this.attributes={},this.children=r||[],this.classes=n||[]}setAttribute(e,r){this.attributes[e]=r}getAttribute(e){return this.attributes[e]}toNode(){var e=document.createElementNS("http://www.w3.org/1998/Math/MathML",this.type);for(var r in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,r)&&e.setAttribute(r,this.attributes[r]);this.classes.length>0&&(e.className=sn(this.classes));for(var n=0;n<this.children.length;n++)if(this.children[n]instanceof Sr&&this.children[n+1]instanceof Sr){for(var i=this.children[n].toText()+this.children[++n].toText();this.children[n+1]instanceof Sr;)i+=this.children[++n].toText();e.appendChild(new Sr(i).toNode())}else e.appendChild(this.children[n].toNode());return e}toMarkup(){var e="<"+this.type;for(var r in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,r)&&(e+=" "+r+'="',e+=ve.escape(this.attributes[r]),e+='"');this.classes.length>0&&(e+=' class ="'+ve.escape(sn(this.classes))+'"'),e+=">";for(var n=0;n<this.children.length;n++)e+=this.children[n].toMarkup();return e+="</"+this.type+">",e}toText(){return this.children.map(e=>e.toText()).join("")}}class Sr{constructor(e){this.text=void 0,this.text=e}toNode(){return document.createTextNode(this.text)}toMarkup(){return ve.escape(this.toText())}toText(){return this.text}}class A5{constructor(e){this.width=void 0,this.character=void 0,this.width=e,e>=.05555&&e<=.05556?this.character=" ":e>=.1666&&e<=.1667?this.character=" ":e>=.2222&&e<=.2223?this.character=" ":e>=.2777&&e<=.2778?this.character=" ":e>=-.05556&&e<=-.05555?this.character=" ":e>=-.1667&&e<=-.1666?this.character=" ":e>=-.2223&&e<=-.2222?this.character=" ":e>=-.2778&&e<=-.2777?this.character=" ":this.character=null}toNode(){if(this.character)return document.createTextNode(this.character);var e=document.createElementNS("http://www.w3.org/1998/Math/MathML","mspace");return e.setAttribute("width",se(this.width)),e}toMarkup(){return this.character?"<mtext>"+this.character+"</mtext>":'<mspace width="'+se(this.width)+'"/>'}toText(){return this.character?this.character:" "}}var Q={MathNode:Kt,TextNode:Sr,SpaceNode:A5,newDocumentFragment:md},ar=function(e,r,n){return tt[r][e]&&tt[r][e].replace&&e.charCodeAt(0)!==55349&&!(ld.hasOwnProperty(e)&&n&&(n.fontFamily&&n.fontFamily.slice(4,6)==="tt"||n.font&&n.font.slice(4,6)==="tt"))&&(e=tt[r][e].replace),new Q.TextNode(e)},Do=function(e){return e.length===1?e[0]:new Q.MathNode("mrow",e)},Oo=function(e,r){if(r.fontFamily==="texttt")return"monospace";if(r.fontFamily==="textsf")return r.fontShape==="textit"&&r.fontWeight==="textbf"?"sans-serif-bold-italic":r.fontShape==="textit"?"sans-serif-italic":r.fontWeight==="textbf"?"bold-sans-serif":"sans-serif";if(r.fontShape==="textit"&&r.fontWeight==="textbf")return"bold-italic";if(r.fontShape==="textit")return"italic";if(r.fontWeight==="textbf")return"bold";var n=r.font;if(!n||n==="mathnormal")return null;var i=e.mode;if(n==="mathit")return"italic";if(n==="boldsymbol")return e.type==="textord"?"bold":"bold-italic";if(n==="mathbf")return"bold";if(n==="mathbb")return"double-struck";if(n==="mathsfit")return"sans-serif-italic";if(n==="mathfrak")return"fraktur";if(n==="mathscr"||n==="mathcal")return"script";if(n==="mathsf")return"sans-serif";if(n==="mathtt")return"monospace";var s=e.text;if(ve.contains(["\\imath","\\jmath"],s))return null;tt[i][s]&&tt[i][s].replace&&(s=tt[i][s].replace);var a=F.fontMap[n].fontName;return No(s,a,i)?F.fontMap[n].variant:null};function qs(t){if(!t)return!1;if(t.type==="mi"&&t.children.length===1){var e=t.children[0];return e instanceof Sr&&e.text==="."}else if(t.type==="mo"&&t.children.length===1&&t.getAttribute("separator")==="true"&&t.getAttribute("lspace")==="0em"&&t.getAttribute("rspace")==="0em"){var r=t.children[0];return r instanceof Sr&&r.text===","}else return!1}var Ut=function(e,r,n){if(e.length===1){var i=Qe(e[0],r);return n&&i instanceof Kt&&i.type==="mo"&&(i.setAttribute("lspace","0em"),i.setAttribute("rspace","0em")),[i]}for(var s=[],a,o=0;o<e.length;o++){var l=Qe(e[o],r);if(l instanceof Kt&&a instanceof Kt){if(l.type==="mtext"&&a.type==="mtext"&&l.getAttribute("mathvariant")===a.getAttribute("mathvariant")){a.children.push(...l.children);continue}else if(l.type==="mn"&&a.type==="mn"){a.children.push(...l.children);continue}else if(qs(l)&&a.type==="mn"){a.children.push(...l.children);continue}else if(l.type==="mn"&&qs(a))l.children=[...a.children,...l.children],s.pop();else if((l.type==="msup"||l.type==="msub")&&l.children.length>=1&&(a.type==="mn"||qs(a))){var c=l.children[0];c instanceof Kt&&c.type==="mn"&&(c.children=[...a.children,...c.children],s.pop())}else if(a.type==="mi"&&a.children.length===1){var u=a.children[0];if(u instanceof Sr&&u.text==="̸"&&(l.type==="mo"||l.type==="mi"||l.type==="mn")){var f=l.children[0];f instanceof Sr&&f.text.length>0&&(f.text=f.text.slice(0,1)+"̸"+f.text.slice(1),s.pop())}}}s.push(l),a=l}return s},on=function(e,r,n){return Do(Ut(e,r,n))},Qe=function(e,r){if(!e)return new Q.MathNode("mrow");if(ji[e.type]){var n=ji[e.type](e,r);return n}else throw new te("Got group of unknown type: '"+e.type+"'")};function kc(t,e,r,n,i){var s=Ut(t,r),a;s.length===1&&s[0]instanceof Kt&&ve.contains(["mrow","mtable"],s[0].type)?a=s[0]:a=new Q.MathNode("mrow",s);var o=new Q.MathNode("annotation",[new Q.TextNode(e)]);o.setAttribute("encoding","application/x-tex");var l=new Q.MathNode("semantics",[a,o]),c=new Q.MathNode("math",[l]);c.setAttribute("xmlns","http://www.w3.org/1998/Math/MathML"),n&&c.setAttribute("display","block");var u=i?"katex":"katex-mathml";return F.makeSpan([u],[c])}var gd=function(e){return new Dr({style:e.displayMode?xe.DISPLAY:xe.TEXT,maxSize:e.maxSize,minRuleThickness:e.minRuleThickness})},vd=function(e,r){if(r.displayMode){var n=["katex-display"];r.leqno&&n.push("leqno"),r.fleqn&&n.push("fleqn"),e=F.makeSpan(n,[e])}return e},E5=function(e,r,n){var i=gd(n),s;if(n.output==="mathml")return kc(e,r,i,n.displayMode,!0);if(n.output==="html"){var a=Ia(e,i);s=F.makeSpan(["katex"],[a])}else{var o=kc(e,r,i,n.displayMode,!1),l=Ia(e,i);s=F.makeSpan(["katex"],[o,l])}return vd(s,n)},C5=function(e,r,n){var i=gd(n),s=Ia(e,i),a=F.makeSpan(["katex"],[s]);return vd(a,n)},M5={widehat:"^",widecheck:"ˇ",widetilde:"~",utilde:"~",overleftarrow:"←",underleftarrow:"←",xleftarrow:"←",overrightarrow:"→",underrightarrow:"→",xrightarrow:"→",underbrace:"⏟",overbrace:"⏞",overgroup:"⏠",undergroup:"⏡",overleftrightarrow:"↔",underleftrightarrow:"↔",xleftrightarrow:"↔",Overrightarrow:"⇒",xRightarrow:"⇒",overleftharpoon:"↼",xleftharpoonup:"↼",overrightharpoon:"⇀",xrightharpoonup:"⇀",xLeftarrow:"⇐",xLeftrightarrow:"⇔",xhookleftarrow:"↩",xhookrightarrow:"↪",xmapsto:"↦",xrightharpoondown:"⇁",xleftharpoondown:"↽",xrightleftharpoons:"⇌",xleftrightharpoons:"⇋",xtwoheadleftarrow:"↞",xtwoheadrightarrow:"↠",xlongequal:"=",xtofrom:"⇄",xrightleftarrows:"⇄",xrightequilibrium:"⇌",xleftequilibrium:"⇋","\\cdrightarrow":"→","\\cdleftarrow":"←","\\cdlongequal":"="},N5=function(e){var r=new Q.MathNode("mo",[new Q.TextNode(M5[e.replace(/^\\/,"")])]);return r.setAttribute("stretchy","true"),r},I5={overrightarrow:[["rightarrow"],.888,522,"xMaxYMin"],overleftarrow:[["leftarrow"],.888,522,"xMinYMin"],underrightarrow:[["rightarrow"],.888,522,"xMaxYMin"],underleftarrow:[["leftarrow"],.888,522,"xMinYMin"],xrightarrow:[["rightarrow"],1.469,522,"xMaxYMin"],"\\cdrightarrow":[["rightarrow"],3,522,"xMaxYMin"],xleftarrow:[["leftarrow"],1.469,522,"xMinYMin"],"\\cdleftarrow":[["leftarrow"],3,522,"xMinYMin"],Overrightarrow:[["doublerightarrow"],.888,560,"xMaxYMin"],xRightarrow:[["doublerightarrow"],1.526,560,"xMaxYMin"],xLeftarrow:[["doubleleftarrow"],1.526,560,"xMinYMin"],overleftharpoon:[["leftharpoon"],.888,522,"xMinYMin"],xleftharpoonup:[["leftharpoon"],.888,522,"xMinYMin"],xleftharpoondown:[["leftharpoondown"],.888,522,"xMinYMin"],overrightharpoon:[["rightharpoon"],.888,522,"xMaxYMin"],xrightharpoonup:[["rightharpoon"],.888,522,"xMaxYMin"],xrightharpoondown:[["rightharpoondown"],.888,522,"xMaxYMin"],xlongequal:[["longequal"],.888,334,"xMinYMin"],"\\cdlongequal":[["longequal"],3,334,"xMinYMin"],xtwoheadleftarrow:[["twoheadleftarrow"],.888,334,"xMinYMin"],xtwoheadrightarrow:[["twoheadrightarrow"],.888,334,"xMaxYMin"],overleftrightarrow:[["leftarrow","rightarrow"],.888,522],overbrace:[["leftbrace","midbrace","rightbrace"],1.6,548],underbrace:[["leftbraceunder","midbraceunder","rightbraceunder"],1.6,548],underleftrightarrow:[["leftarrow","rightarrow"],.888,522],xleftrightarrow:[["leftarrow","rightarrow"],1.75,522],xLeftrightarrow:[["doubleleftarrow","doublerightarrow"],1.75,560],xrightleftharpoons:[["leftharpoondownplus","rightharpoonplus"],1.75,716],xleftrightharpoons:[["leftharpoonplus","rightharpoondownplus"],1.75,716],xhookleftarrow:[["leftarrow","righthook"],1.08,522],xhookrightarrow:[["lefthook","rightarrow"],1.08,522],overlinesegment:[["leftlinesegment","rightlinesegment"],.888,522],underlinesegment:[["leftlinesegment","rightlinesegment"],.888,522],overgroup:[["leftgroup","rightgroup"],.888,342],undergroup:[["leftgroupunder","rightgroupunder"],.888,342],xmapsto:[["leftmapsto","rightarrow"],1.5,522],xtofrom:[["leftToFrom","rightToFrom"],1.75,528],xrightleftarrows:[["baraboveleftarrow","rightarrowabovebar"],1.75,901],xrightequilibrium:[["baraboveshortleftharpoon","rightharpoonaboveshortbar"],1.75,716],xleftequilibrium:[["shortbaraboveleftharpoon","shortrightharpoonabovebar"],1.75,716]},R5=function(e){return e.type==="ordgroup"?e.body.length:1},D5=function(e,r){function n(){var o=4e5,l=e.label.slice(1);if(ve.contains(["widehat","widecheck","widetilde","utilde"],l)){var c=e,u=R5(c.base),f,p,g;if(u>5)l==="widehat"||l==="widecheck"?(f=420,o=2364,g=.42,p=l+"4"):(f=312,o=2340,g=.34,p="tilde4");else{var b=[1,1,2,2,3,3][u];l==="widehat"||l==="widecheck"?(o=[0,1062,2364,2364,2364][b],f=[0,239,300,360,420][b],g=[0,.24,.3,.3,.36,.42][b],p=l+b):(o=[0,600,1033,2339,2340][b],f=[0,260,286,306,312][b],g=[0,.26,.286,.3,.306,.34][b],p="tilde"+b)}var x=new an(p),w=new Hr([x],{width:"100%",height:se(g),viewBox:"0 0 "+o+" "+f,preserveAspectRatio:"none"});return{span:F.makeSvgSpan([],[w],r),minWidth:0,height:g}}else{var N=[],y=I5[l],[k,I,D]=y,O=D/1e3,z=k.length,W,H;if(z===1){var oe=y[3];W=["hide-tail"],H=[oe]}else if(z===2)W=["halfarrow-left","halfarrow-right"],H=["xMinYMin","xMaxYMin"];else if(z===3)W=["brace-left","brace-center","brace-right"],H=["xMinYMin","xMidYMin","xMaxYMin"];else throw new Error(`Correct katexImagesData or update code here to support
|
||
`+z+" children.");for(var me=0;me<z;me++){var ye=new an(k[me]),Le=new Hr([ye],{width:"400em",height:se(O),viewBox:"0 0 "+o+" "+D,preserveAspectRatio:H[me]+" slice"}),ze=F.makeSvgSpan([W[me]],[Le],r);if(z===1)return{span:ze,minWidth:I,height:O};ze.style.height=se(O),N.push(ze)}return{span:F.makeSpan(["stretchy"],N,r),minWidth:I,height:O}}}var{span:i,minWidth:s,height:a}=n();return i.height=a,i.style.height=se(a),s>0&&(i.style.minWidth=se(s)),i},O5=function(e,r,n,i,s){var a,o=e.height+e.depth+n+i;if(/fbox|color|angl/.test(r)){if(a=F.makeSpan(["stretchy",r],[],s),r==="fbox"){var l=s.color&&s.getColor();l&&(a.style.borderColor=l)}}else{var c=[];/^[bx]cancel$/.test(r)&&c.push(new Ca({x1:"0",y1:"0",x2:"100%",y2:"100%","stroke-width":"0.046em"})),/^x?cancel$/.test(r)&&c.push(new Ca({x1:"0",y1:"100%",x2:"100%",y2:"0","stroke-width":"0.046em"}));var u=new Hr(c,{width:"100%",height:se(o)});a=F.makeSvgSpan([],[u],s)}return a.height=o,a.style.height=se(o),a},jr={encloseSpan:O5,mathMLnode:N5,svgSpan:D5};function Ie(t,e){if(!t||t.type!==e)throw new Error("Expected node of type "+e+", but got "+(t?"node of type "+t.type:String(t)));return t}function _o(t){var e=ms(t);if(!e)throw new Error("Expected node of symbol group type, but got "+(t?"node of type "+t.type:String(t)));return e}function ms(t){return t&&(t.type==="atom"||i5.hasOwnProperty(t.type))?t:null}var Lo=(t,e)=>{var r,n,i;t&&t.type==="supsub"?(n=Ie(t.base,"accent"),r=n.base,t.base=r,i=r5($e(t,e)),t.base=n):(n=Ie(t,"accent"),r=n.base);var s=$e(r,e.havingCrampedStyle()),a=n.isShifty&&ve.isCharacterBox(r),o=0;if(a){var l=ve.getBaseElem(r),c=$e(l,e.havingCrampedStyle());o=mc(c).skew}var u=n.label==="\\c",f=u?s.height+s.depth:Math.min(s.height,e.fontMetrics().xHeight),p;if(n.isStretchy)p=jr.svgSpan(n,e),p=F.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:s},{type:"elem",elem:p,wrapperClasses:["svg-align"],wrapperStyle:o>0?{width:"calc(100% - "+se(2*o)+")",marginLeft:se(2*o)}:void 0}]},e);else{var g,b;n.label==="\\vec"?(g=F.staticSvg("vec",e),b=F.svgData.vec[1]):(g=F.makeOrd({mode:n.mode,text:n.label},e,"textord"),g=mc(g),g.italic=0,b=g.width,u&&(f+=g.depth)),p=F.makeSpan(["accent-body"],[g]);var x=n.label==="\\textcircled";x&&(p.classes.push("accent-full"),f=s.height);var w=o;x||(w-=b/2),p.style.left=se(w),n.label==="\\textcircled"&&(p.style.top=".2em"),p=F.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:s},{type:"kern",size:-f},{type:"elem",elem:p}]},e)}var N=F.makeSpan(["mord","accent"],[p],e);return i?(i.children[0]=N,i.height=Math.max(N.height,i.height),i.classes[0]="mord",i):N},bd=(t,e)=>{var r=t.isStretchy?jr.mathMLnode(t.label):new Q.MathNode("mo",[ar(t.label,t.mode)]),n=new Q.MathNode("mover",[Qe(t.base,e),r]);return n.setAttribute("accent","true"),n},_5=new RegExp(["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring"].map(t=>"\\"+t).join("|"));ce({type:"accent",names:["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring","\\widecheck","\\widehat","\\widetilde","\\overrightarrow","\\overleftarrow","\\Overrightarrow","\\overleftrightarrow","\\overgroup","\\overlinesegment","\\overleftharpoon","\\overrightharpoon"],props:{numArgs:1},handler:(t,e)=>{var r=Ui(e[0]),n=!_5.test(t.funcName),i=!n||t.funcName==="\\widehat"||t.funcName==="\\widetilde"||t.funcName==="\\widecheck";return{type:"accent",mode:t.parser.mode,label:t.funcName,isStretchy:n,isShifty:i,base:r}},htmlBuilder:Lo,mathmlBuilder:bd});ce({type:"accent",names:["\\'","\\`","\\^","\\~","\\=","\\u","\\.",'\\"',"\\c","\\r","\\H","\\v","\\textcircled"],props:{numArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["primitive"]},handler:(t,e)=>{var r=e[0],n=t.parser.mode;return n==="math"&&(t.parser.settings.reportNonstrict("mathVsTextAccents","LaTeX's accent "+t.funcName+" works only in text mode"),n="text"),{type:"accent",mode:n,label:t.funcName,isStretchy:!1,isShifty:!0,base:r}},htmlBuilder:Lo,mathmlBuilder:bd});ce({type:"accentUnder",names:["\\underleftarrow","\\underrightarrow","\\underleftrightarrow","\\undergroup","\\underlinesegment","\\utilde"],props:{numArgs:1},handler:(t,e)=>{var{parser:r,funcName:n}=t,i=e[0];return{type:"accentUnder",mode:r.mode,label:n,base:i}},htmlBuilder:(t,e)=>{var r=$e(t.base,e),n=jr.svgSpan(t,e),i=t.label==="\\utilde"?.12:0,s=F.makeVList({positionType:"top",positionData:r.height,children:[{type:"elem",elem:n,wrapperClasses:["svg-align"]},{type:"kern",size:i},{type:"elem",elem:r}]},e);return F.makeSpan(["mord","accentunder"],[s],e)},mathmlBuilder:(t,e)=>{var r=jr.mathMLnode(t.label),n=new Q.MathNode("munder",[Qe(t.base,e),r]);return n.setAttribute("accentunder","true"),n}});var si=t=>{var e=new Q.MathNode("mpadded",t?[t]:[]);return e.setAttribute("width","+0.6em"),e.setAttribute("lspace","0.3em"),e};ce({type:"xArrow",names:["\\xleftarrow","\\xrightarrow","\\xLeftarrow","\\xRightarrow","\\xleftrightarrow","\\xLeftrightarrow","\\xhookleftarrow","\\xhookrightarrow","\\xmapsto","\\xrightharpoondown","\\xrightharpoonup","\\xleftharpoondown","\\xleftharpoonup","\\xrightleftharpoons","\\xleftrightharpoons","\\xlongequal","\\xtwoheadrightarrow","\\xtwoheadleftarrow","\\xtofrom","\\xrightleftarrows","\\xrightequilibrium","\\xleftequilibrium","\\\\cdrightarrow","\\\\cdleftarrow","\\\\cdlongequal"],props:{numArgs:1,numOptionalArgs:1},handler(t,e,r){var{parser:n,funcName:i}=t;return{type:"xArrow",mode:n.mode,label:i,body:e[0],below:r[0]}},htmlBuilder(t,e){var r=e.style,n=e.havingStyle(r.sup()),i=F.wrapFragment($e(t.body,n,e),e),s=t.label.slice(0,2)==="\\x"?"x":"cd";i.classes.push(s+"-arrow-pad");var a;t.below&&(n=e.havingStyle(r.sub()),a=F.wrapFragment($e(t.below,n,e),e),a.classes.push(s+"-arrow-pad"));var o=jr.svgSpan(t,e),l=-e.fontMetrics().axisHeight+.5*o.height,c=-e.fontMetrics().axisHeight-.5*o.height-.111;(i.depth>.25||t.label==="\\xleftequilibrium")&&(c-=i.depth);var u;if(a){var f=-e.fontMetrics().axisHeight+a.height+.5*o.height+.111;u=F.makeVList({positionType:"individualShift",children:[{type:"elem",elem:i,shift:c},{type:"elem",elem:o,shift:l},{type:"elem",elem:a,shift:f}]},e)}else u=F.makeVList({positionType:"individualShift",children:[{type:"elem",elem:i,shift:c},{type:"elem",elem:o,shift:l}]},e);return u.children[0].children[0].children[1].classes.push("svg-align"),F.makeSpan(["mrel","x-arrow"],[u],e)},mathmlBuilder(t,e){var r=jr.mathMLnode(t.label);r.setAttribute("minsize",t.label.charAt(0)==="x"?"1.75em":"3.0em");var n;if(t.body){var i=si(Qe(t.body,e));if(t.below){var s=si(Qe(t.below,e));n=new Q.MathNode("munderover",[r,s,i])}else n=new Q.MathNode("mover",[r,i])}else if(t.below){var a=si(Qe(t.below,e));n=new Q.MathNode("munder",[r,a])}else n=si(),n=new Q.MathNode("mover",[r,n]);return n}});var L5=F.makeSpan;function yd(t,e){var r=bt(t.body,e,!0);return L5([t.mclass],r,e)}function wd(t,e){var r,n=Ut(t.body,e);return t.mclass==="minner"?r=new Q.MathNode("mpadded",n):t.mclass==="mord"?t.isCharacterBox?(r=n[0],r.type="mi"):r=new Q.MathNode("mi",n):(t.isCharacterBox?(r=n[0],r.type="mo"):r=new Q.MathNode("mo",n),t.mclass==="mbin"?(r.attributes.lspace="0.22em",r.attributes.rspace="0.22em"):t.mclass==="mpunct"?(r.attributes.lspace="0em",r.attributes.rspace="0.17em"):t.mclass==="mopen"||t.mclass==="mclose"?(r.attributes.lspace="0em",r.attributes.rspace="0em"):t.mclass==="minner"&&(r.attributes.lspace="0.0556em",r.attributes.width="+0.1111em")),r}ce({type:"mclass",names:["\\mathord","\\mathbin","\\mathrel","\\mathopen","\\mathclose","\\mathpunct","\\mathinner"],props:{numArgs:1,primitive:!0},handler(t,e){var{parser:r,funcName:n}=t,i=e[0];return{type:"mclass",mode:r.mode,mclass:"m"+n.slice(5),body:dt(i),isCharacterBox:ve.isCharacterBox(i)}},htmlBuilder:yd,mathmlBuilder:wd});var gs=t=>{var e=t.type==="ordgroup"&&t.body.length?t.body[0]:t;return e.type==="atom"&&(e.family==="bin"||e.family==="rel")?"m"+e.family:"mord"};ce({type:"mclass",names:["\\@binrel"],props:{numArgs:2},handler(t,e){var{parser:r}=t;return{type:"mclass",mode:r.mode,mclass:gs(e[0]),body:dt(e[1]),isCharacterBox:ve.isCharacterBox(e[1])}}});ce({type:"mclass",names:["\\stackrel","\\overset","\\underset"],props:{numArgs:2},handler(t,e){var{parser:r,funcName:n}=t,i=e[1],s=e[0],a;n!=="\\stackrel"?a=gs(i):a="mrel";var o={type:"op",mode:i.mode,limits:!0,alwaysHandleSupSub:!0,parentIsSupSub:!1,symbol:!1,suppressBaseShift:n!=="\\stackrel",body:dt(i)},l={type:"supsub",mode:s.mode,base:o,sup:n==="\\underset"?null:s,sub:n==="\\underset"?s:null};return{type:"mclass",mode:r.mode,mclass:a,body:[l],isCharacterBox:ve.isCharacterBox(l)}},htmlBuilder:yd,mathmlBuilder:wd});ce({type:"pmb",names:["\\pmb"],props:{numArgs:1,allowedInText:!0},handler(t,e){var{parser:r}=t;return{type:"pmb",mode:r.mode,mclass:gs(e[0]),body:dt(e[0])}},htmlBuilder(t,e){var r=bt(t.body,e,!0),n=F.makeSpan([t.mclass],r,e);return n.style.textShadow="0.02em 0.01em 0.04px",n},mathmlBuilder(t,e){var r=Ut(t.body,e),n=new Q.MathNode("mstyle",r);return n.setAttribute("style","text-shadow: 0.02em 0.01em 0.04px"),n}});var z5={">":"\\\\cdrightarrow","<":"\\\\cdleftarrow","=":"\\\\cdlongequal",A:"\\uparrow",V:"\\downarrow","|":"\\Vert",".":"no arrow"},Sc=()=>({type:"styling",body:[],mode:"math",style:"display"}),Tc=t=>t.type==="textord"&&t.text==="@",$5=(t,e)=>(t.type==="mathord"||t.type==="atom")&&t.text===e;function F5(t,e,r){var n=z5[t];switch(n){case"\\\\cdrightarrow":case"\\\\cdleftarrow":return r.callFunction(n,[e[0]],[e[1]]);case"\\uparrow":case"\\downarrow":{var i=r.callFunction("\\\\cdleft",[e[0]],[]),s={type:"atom",text:n,mode:"math",family:"rel"},a=r.callFunction("\\Big",[s],[]),o=r.callFunction("\\\\cdright",[e[1]],[]),l={type:"ordgroup",mode:"math",body:[i,a,o]};return r.callFunction("\\\\cdparent",[l],[])}case"\\\\cdlongequal":return r.callFunction("\\\\cdlongequal",[],[]);case"\\Vert":{var c={type:"textord",text:"\\Vert",mode:"math"};return r.callFunction("\\Big",[c],[])}default:return{type:"textord",text:" ",mode:"math"}}}function B5(t){var e=[];for(t.gullet.beginGroup(),t.gullet.macros.set("\\cr","\\\\\\relax"),t.gullet.beginGroup();;){e.push(t.parseExpression(!1,"\\\\")),t.gullet.endGroup(),t.gullet.beginGroup();var r=t.fetch().text;if(r==="&"||r==="\\\\")t.consume();else if(r==="\\end"){e[e.length-1].length===0&&e.pop();break}else throw new te("Expected \\\\ or \\cr or \\end",t.nextToken)}for(var n=[],i=[n],s=0;s<e.length;s++){for(var a=e[s],o=Sc(),l=0;l<a.length;l++)if(!Tc(a[l]))o.body.push(a[l]);else{n.push(o),l+=1;var c=_o(a[l]).text,u=new Array(2);if(u[0]={type:"ordgroup",mode:"math",body:[]},u[1]={type:"ordgroup",mode:"math",body:[]},!("=|.".indexOf(c)>-1))if("<>AV".indexOf(c)>-1)for(var f=0;f<2;f++){for(var p=!0,g=l+1;g<a.length;g++){if($5(a[g],c)){p=!1,l=g;break}if(Tc(a[g]))throw new te("Missing a "+c+" character to complete a CD arrow.",a[g]);u[f].body.push(a[g])}if(p)throw new te("Missing a "+c+" character to complete a CD arrow.",a[l])}else throw new te('Expected one of "<>AV=|." after @',a[l]);var b=F5(c,u,t),x={type:"styling",body:[b],mode:"math",style:"display"};n.push(x),o=Sc()}s%2===0?n.push(o):n.shift(),n=[],i.push(n)}t.gullet.endGroup(),t.gullet.endGroup();var w=new Array(i[0].length).fill({type:"align",align:"c",pregap:.25,postgap:.25});return{type:"array",mode:"math",body:i,arraystretch:1,addJot:!0,rowGaps:[null],cols:w,colSeparationType:"CD",hLinesBeforeRow:new Array(i.length+1).fill([])}}ce({type:"cdlabel",names:["\\\\cdleft","\\\\cdright"],props:{numArgs:1},handler(t,e){var{parser:r,funcName:n}=t;return{type:"cdlabel",mode:r.mode,side:n.slice(4),label:e[0]}},htmlBuilder(t,e){var r=e.havingStyle(e.style.sup()),n=F.wrapFragment($e(t.label,r,e),e);return n.classes.push("cd-label-"+t.side),n.style.bottom=se(.8-n.depth),n.height=0,n.depth=0,n},mathmlBuilder(t,e){var r=new Q.MathNode("mrow",[Qe(t.label,e)]);return r=new Q.MathNode("mpadded",[r]),r.setAttribute("width","0"),t.side==="left"&&r.setAttribute("lspace","-1width"),r.setAttribute("voffset","0.7em"),r=new Q.MathNode("mstyle",[r]),r.setAttribute("displaystyle","false"),r.setAttribute("scriptlevel","1"),r}});ce({type:"cdlabelparent",names:["\\\\cdparent"],props:{numArgs:1},handler(t,e){var{parser:r}=t;return{type:"cdlabelparent",mode:r.mode,fragment:e[0]}},htmlBuilder(t,e){var r=F.wrapFragment($e(t.fragment,e),e);return r.classes.push("cd-vert-arrow"),r},mathmlBuilder(t,e){return new Q.MathNode("mrow",[Qe(t.fragment,e)])}});ce({type:"textord",names:["\\@char"],props:{numArgs:1,allowedInText:!0},handler(t,e){for(var{parser:r}=t,n=Ie(e[0],"ordgroup"),i=n.body,s="",a=0;a<i.length;a++){var o=Ie(i[a],"textord");s+=o.text}var l=parseInt(s),c;if(isNaN(l))throw new te("\\@char has non-numeric argument "+s);if(l<0||l>=1114111)throw new te("\\@char with invalid code point "+s);return l<=65535?c=String.fromCharCode(l):(l-=65536,c=String.fromCharCode((l>>10)+55296,(l&1023)+56320)),{type:"textord",mode:r.mode,text:c}}});var xd=(t,e)=>{var r=bt(t.body,e.withColor(t.color),!1);return F.makeFragment(r)},kd=(t,e)=>{var r=Ut(t.body,e.withColor(t.color)),n=new Q.MathNode("mstyle",r);return n.setAttribute("mathcolor",t.color),n};ce({type:"color",names:["\\textcolor"],props:{numArgs:2,allowedInText:!0,argTypes:["color","original"]},handler(t,e){var{parser:r}=t,n=Ie(e[0],"color-token").color,i=e[1];return{type:"color",mode:r.mode,color:n,body:dt(i)}},htmlBuilder:xd,mathmlBuilder:kd});ce({type:"color",names:["\\color"],props:{numArgs:1,allowedInText:!0,argTypes:["color"]},handler(t,e){var{parser:r,breakOnTokenText:n}=t,i=Ie(e[0],"color-token").color;r.gullet.macros.set("\\current@color",i);var s=r.parseExpression(!0,n);return{type:"color",mode:r.mode,color:i,body:s}},htmlBuilder:xd,mathmlBuilder:kd});ce({type:"cr",names:["\\\\"],props:{numArgs:0,numOptionalArgs:0,allowedInText:!0},handler(t,e,r){var{parser:n}=t,i=n.gullet.future().text==="["?n.parseSizeGroup(!0):null,s=!n.settings.displayMode||!n.settings.useStrictBehavior("newLineInDisplayMode","In LaTeX, \\\\ or \\newline does nothing in display mode");return{type:"cr",mode:n.mode,newLine:s,size:i&&Ie(i,"size").value}},htmlBuilder(t,e){var r=F.makeSpan(["mspace"],[],e);return t.newLine&&(r.classes.push("newline"),t.size&&(r.style.marginTop=se(at(t.size,e)))),r},mathmlBuilder(t,e){var r=new Q.MathNode("mspace");return t.newLine&&(r.setAttribute("linebreak","newline"),t.size&&r.setAttribute("height",se(at(t.size,e)))),r}});var Ra={"\\global":"\\global","\\long":"\\\\globallong","\\\\globallong":"\\\\globallong","\\def":"\\gdef","\\gdef":"\\gdef","\\edef":"\\xdef","\\xdef":"\\xdef","\\let":"\\\\globallet","\\futurelet":"\\\\globalfuture"},Sd=t=>{var e=t.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(e))throw new te("Expected a control sequence",t);return e},P5=t=>{var e=t.gullet.popToken();return e.text==="="&&(e=t.gullet.popToken(),e.text===" "&&(e=t.gullet.popToken())),e},Td=(t,e,r,n)=>{var i=t.gullet.macros.get(r.text);i==null&&(r.noexpand=!0,i={tokens:[r],numArgs:0,unexpandable:!t.gullet.isExpandable(r.text)}),t.gullet.macros.set(e,i,n)};ce({type:"internal",names:["\\global","\\long","\\\\globallong"],props:{numArgs:0,allowedInText:!0},handler(t){var{parser:e,funcName:r}=t;e.consumeSpaces();var n=e.fetch();if(Ra[n.text])return(r==="\\global"||r==="\\\\globallong")&&(n.text=Ra[n.text]),Ie(e.parseFunction(),"internal");throw new te("Invalid token after macro prefix",n)}});ce({type:"internal",names:["\\def","\\gdef","\\edef","\\xdef"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t){var{parser:e,funcName:r}=t,n=e.gullet.popToken(),i=n.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(i))throw new te("Expected a control sequence",n);for(var s=0,a,o=[[]];e.gullet.future().text!=="{";)if(n=e.gullet.popToken(),n.text==="#"){if(e.gullet.future().text==="{"){a=e.gullet.future(),o[s].push("{");break}if(n=e.gullet.popToken(),!/^[1-9]$/.test(n.text))throw new te('Invalid argument number "'+n.text+'"');if(parseInt(n.text)!==s+1)throw new te('Argument number "'+n.text+'" out of order');s++,o.push([])}else{if(n.text==="EOF")throw new te("Expected a macro definition");o[s].push(n.text)}var{tokens:l}=e.gullet.consumeArg();return a&&l.unshift(a),(r==="\\edef"||r==="\\xdef")&&(l=e.gullet.expandTokens(l),l.reverse()),e.gullet.macros.set(i,{tokens:l,numArgs:s,delimiters:o},r===Ra[r]),{type:"internal",mode:e.mode}}});ce({type:"internal",names:["\\let","\\\\globallet"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t){var{parser:e,funcName:r}=t,n=Sd(e.gullet.popToken());e.gullet.consumeSpaces();var i=P5(e);return Td(e,n,i,r==="\\\\globallet"),{type:"internal",mode:e.mode}}});ce({type:"internal",names:["\\futurelet","\\\\globalfuture"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t){var{parser:e,funcName:r}=t,n=Sd(e.gullet.popToken()),i=e.gullet.popToken(),s=e.gullet.popToken();return Td(e,n,s,r==="\\\\globalfuture"),e.gullet.pushToken(s),e.gullet.pushToken(i),{type:"internal",mode:e.mode}}});var o0=function(e,r,n){var i=tt.math[e]&&tt.math[e].replace,s=No(i||e,r,n);if(!s)throw new Error("Unsupported symbol "+e+" and font size "+r+".");return s},zo=function(e,r,n,i){var s=n.havingBaseStyle(r),a=F.makeSpan(i.concat(s.sizingClasses(n)),[e],n),o=s.sizeMultiplier/n.sizeMultiplier;return a.height*=o,a.depth*=o,a.maxFontSize=s.sizeMultiplier,a},Ad=function(e,r,n){var i=r.havingBaseStyle(n),s=(1-r.sizeMultiplier/i.sizeMultiplier)*r.fontMetrics().axisHeight;e.classes.push("delimcenter"),e.style.top=se(s),e.height-=s,e.depth+=s},H5=function(e,r,n,i,s,a){var o=F.makeSymbol(e,"Main-Regular",s,i),l=zo(o,r,i,a);return n&&Ad(l,i,r),l},q5=function(e,r,n,i){return F.makeSymbol(e,"Size"+r+"-Regular",n,i)},Ed=function(e,r,n,i,s,a){var o=q5(e,r,s,i),l=zo(F.makeSpan(["delimsizing","size"+r],[o],i),xe.TEXT,i,a);return n&&Ad(l,i,xe.TEXT),l},js=function(e,r,n){var i;r==="Size1-Regular"?i="delim-size1":i="delim-size4";var s=F.makeSpan(["delimsizinginner",i],[F.makeSpan([],[F.makeSymbol(e,r,n)])]);return{type:"elem",elem:s}},Us=function(e,r,n){var i=kr["Size4-Regular"][e.charCodeAt(0)]?kr["Size4-Regular"][e.charCodeAt(0)][4]:kr["Size1-Regular"][e.charCodeAt(0)][4],s=new an("inner",G6(e,Math.round(1e3*r))),a=new Hr([s],{width:se(i),height:se(r),style:"width:"+se(i),viewBox:"0 0 "+1e3*i+" "+Math.round(1e3*r),preserveAspectRatio:"xMinYMin"}),o=F.makeSvgSpan([],[a],n);return o.height=r,o.style.height=se(r),o.style.width=se(i),{type:"elem",elem:o}},Da=.008,ai={type:"kern",size:-1*Da},j5=["|","\\lvert","\\rvert","\\vert"],U5=["\\|","\\lVert","\\rVert","\\Vert"],Cd=function(e,r,n,i,s,a){var o,l,c,u,f="",p=0;o=c=u=e,l=null;var g="Size1-Regular";e==="\\uparrow"?c=u="⏐":e==="\\Uparrow"?c=u="‖":e==="\\downarrow"?o=c="⏐":e==="\\Downarrow"?o=c="‖":e==="\\updownarrow"?(o="\\uparrow",c="⏐",u="\\downarrow"):e==="\\Updownarrow"?(o="\\Uparrow",c="‖",u="\\Downarrow"):ve.contains(j5,e)?(c="∣",f="vert",p=333):ve.contains(U5,e)?(c="∥",f="doublevert",p=556):e==="["||e==="\\lbrack"?(o="⎡",c="⎢",u="⎣",g="Size4-Regular",f="lbrack",p=667):e==="]"||e==="\\rbrack"?(o="⎤",c="⎥",u="⎦",g="Size4-Regular",f="rbrack",p=667):e==="\\lfloor"||e==="⌊"?(c=o="⎢",u="⎣",g="Size4-Regular",f="lfloor",p=667):e==="\\lceil"||e==="⌈"?(o="⎡",c=u="⎢",g="Size4-Regular",f="lceil",p=667):e==="\\rfloor"||e==="⌋"?(c=o="⎥",u="⎦",g="Size4-Regular",f="rfloor",p=667):e==="\\rceil"||e==="⌉"?(o="⎤",c=u="⎥",g="Size4-Regular",f="rceil",p=667):e==="("||e==="\\lparen"?(o="⎛",c="⎜",u="⎝",g="Size4-Regular",f="lparen",p=875):e===")"||e==="\\rparen"?(o="⎞",c="⎟",u="⎠",g="Size4-Regular",f="rparen",p=875):e==="\\{"||e==="\\lbrace"?(o="⎧",l="⎨",u="⎩",c="⎪",g="Size4-Regular"):e==="\\}"||e==="\\rbrace"?(o="⎫",l="⎬",u="⎭",c="⎪",g="Size4-Regular"):e==="\\lgroup"||e==="⟮"?(o="⎧",u="⎩",c="⎪",g="Size4-Regular"):e==="\\rgroup"||e==="⟯"?(o="⎫",u="⎭",c="⎪",g="Size4-Regular"):e==="\\lmoustache"||e==="⎰"?(o="⎧",u="⎭",c="⎪",g="Size4-Regular"):(e==="\\rmoustache"||e==="⎱")&&(o="⎫",u="⎩",c="⎪",g="Size4-Regular");var b=o0(o,g,s),x=b.height+b.depth,w=o0(c,g,s),N=w.height+w.depth,y=o0(u,g,s),k=y.height+y.depth,I=0,D=1;if(l!==null){var O=o0(l,g,s);I=O.height+O.depth,D=2}var z=x+k+I,W=Math.max(0,Math.ceil((r-z)/(D*N))),H=z+W*D*N,oe=i.fontMetrics().axisHeight;n&&(oe*=i.sizeMultiplier);var me=H/2-oe,ye=[];if(f.length>0){var Le=H-x-k,ze=Math.round(H*1e3),Ge=K6(f,Math.round(Le*1e3)),Oe=new an(f,Ge),ke=(p/1e3).toFixed(3)+"em",he=(ze/1e3).toFixed(3)+"em",je=new Hr([Oe],{width:ke,height:he,viewBox:"0 0 "+p+" "+ze}),Ke=F.makeSvgSpan([],[je],i);Ke.height=ze/1e3,Ke.style.width=ke,Ke.style.height=he,ye.push({type:"elem",elem:Ke})}else{if(ye.push(js(u,g,s)),ye.push(ai),l===null){var Be=H-x-k+2*Da;ye.push(Us(c,Be,i))}else{var ge=(H-x-k-I)/2+2*Da;ye.push(Us(c,ge,i)),ye.push(ai),ye.push(js(l,g,s)),ye.push(ai),ye.push(Us(c,ge,i))}ye.push(ai),ye.push(js(o,g,s))}var Ft=i.havingBaseStyle(xe.TEXT),ht=F.makeVList({positionType:"bottom",positionData:me,children:ye},Ft);return zo(F.makeSpan(["delimsizing","mult"],[ht],Ft),xe.TEXT,i,a)},Vs=80,Ws=.08,Gs=function(e,r,n,i,s){var a=W6(e,i,n),o=new an(e,a),l=new Hr([o],{width:"400em",height:se(r),viewBox:"0 0 400000 "+n,preserveAspectRatio:"xMinYMin slice"});return F.makeSvgSpan(["hide-tail"],[l],s)},V5=function(e,r){var n=r.havingBaseSizing(),i=Rd("\\surd",e*n.sizeMultiplier,Id,n),s=n.sizeMultiplier,a=Math.max(0,r.minRuleThickness-r.fontMetrics().sqrtRuleThickness),o,l=0,c=0,u=0,f;return i.type==="small"?(u=1e3+1e3*a+Vs,e<1?s=1:e<1.4&&(s=.7),l=(1+a+Ws)/s,c=(1+a)/s,o=Gs("sqrtMain",l,u,a,r),o.style.minWidth="0.853em",f=.833/s):i.type==="large"?(u=(1e3+Vs)*v0[i.size],c=(v0[i.size]+a)/s,l=(v0[i.size]+a+Ws)/s,o=Gs("sqrtSize"+i.size,l,u,a,r),o.style.minWidth="1.02em",f=1/s):(l=e+a+Ws,c=e+a,u=Math.floor(1e3*e+a)+Vs,o=Gs("sqrtTall",l,u,a,r),o.style.minWidth="0.742em",f=1.056),o.height=c,o.style.height=se(l),{span:o,advanceWidth:f,ruleWidth:(r.fontMetrics().sqrtRuleThickness+a)*s}},Md=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","\\surd"],W5=["\\uparrow","\\downarrow","\\updownarrow","\\Uparrow","\\Downarrow","\\Updownarrow","|","\\|","\\vert","\\Vert","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱"],Nd=["<",">","\\langle","\\rangle","/","\\backslash","\\lt","\\gt"],v0=[0,1.2,1.8,2.4,3],G5=function(e,r,n,i,s){if(e==="<"||e==="\\lt"||e==="⟨"?e="\\langle":(e===">"||e==="\\gt"||e==="⟩")&&(e="\\rangle"),ve.contains(Md,e)||ve.contains(Nd,e))return Ed(e,r,!1,n,i,s);if(ve.contains(W5,e))return Cd(e,v0[r],!1,n,i,s);throw new te("Illegal delimiter: '"+e+"'")},K5=[{type:"small",style:xe.SCRIPTSCRIPT},{type:"small",style:xe.SCRIPT},{type:"small",style:xe.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4}],Y5=[{type:"small",style:xe.SCRIPTSCRIPT},{type:"small",style:xe.SCRIPT},{type:"small",style:xe.TEXT},{type:"stack"}],Id=[{type:"small",style:xe.SCRIPTSCRIPT},{type:"small",style:xe.SCRIPT},{type:"small",style:xe.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4},{type:"stack"}],X5=function(e){if(e.type==="small")return"Main-Regular";if(e.type==="large")return"Size"+e.size+"-Regular";if(e.type==="stack")return"Size4-Regular";throw new Error("Add support for delim type '"+e.type+"' here.")},Rd=function(e,r,n,i){for(var s=Math.min(2,3-i.style.size),a=s;a<n.length&&n[a].type!=="stack";a++){var o=o0(e,X5(n[a]),"math"),l=o.height+o.depth;if(n[a].type==="small"){var c=i.havingBaseStyle(n[a].style);l*=c.sizeMultiplier}if(l>r)return n[a]}return n[n.length-1]},Dd=function(e,r,n,i,s,a){e==="<"||e==="\\lt"||e==="⟨"?e="\\langle":(e===">"||e==="\\gt"||e==="⟩")&&(e="\\rangle");var o;ve.contains(Nd,e)?o=K5:ve.contains(Md,e)?o=Id:o=Y5;var l=Rd(e,r,o,i);return l.type==="small"?H5(e,l.style,n,i,s,a):l.type==="large"?Ed(e,l.size,n,i,s,a):Cd(e,r,n,i,s,a)},J5=function(e,r,n,i,s,a){var o=i.fontMetrics().axisHeight*i.sizeMultiplier,l=901,c=5/i.fontMetrics().ptPerEm,u=Math.max(r-o,n+o),f=Math.max(u/500*l,2*u-c);return Dd(e,f,!0,i,s,a)},Fr={sqrtImage:V5,sizedDelim:G5,sizeToMaxHeight:v0,customSizedDelim:Dd,leftRightDelim:J5},Ac={"\\bigl":{mclass:"mopen",size:1},"\\Bigl":{mclass:"mopen",size:2},"\\biggl":{mclass:"mopen",size:3},"\\Biggl":{mclass:"mopen",size:4},"\\bigr":{mclass:"mclose",size:1},"\\Bigr":{mclass:"mclose",size:2},"\\biggr":{mclass:"mclose",size:3},"\\Biggr":{mclass:"mclose",size:4},"\\bigm":{mclass:"mrel",size:1},"\\Bigm":{mclass:"mrel",size:2},"\\biggm":{mclass:"mrel",size:3},"\\Biggm":{mclass:"mrel",size:4},"\\big":{mclass:"mord",size:1},"\\Big":{mclass:"mord",size:2},"\\bigg":{mclass:"mord",size:3},"\\Bigg":{mclass:"mord",size:4}},Z5=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","<",">","\\langle","⟨","\\rangle","⟩","\\lt","\\gt","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱","/","\\backslash","|","\\vert","\\|","\\Vert","\\uparrow","\\Uparrow","\\downarrow","\\Downarrow","\\updownarrow","\\Updownarrow","."];function vs(t,e){var r=ms(t);if(r&&ve.contains(Z5,r.text))return r;throw r?new te("Invalid delimiter '"+r.text+"' after '"+e.funcName+"'",t):new te("Invalid delimiter type '"+t.type+"'",t)}ce({type:"delimsizing",names:["\\bigl","\\Bigl","\\biggl","\\Biggl","\\bigr","\\Bigr","\\biggr","\\Biggr","\\bigm","\\Bigm","\\biggm","\\Biggm","\\big","\\Big","\\bigg","\\Bigg"],props:{numArgs:1,argTypes:["primitive"]},handler:(t,e)=>{var r=vs(e[0],t);return{type:"delimsizing",mode:t.parser.mode,size:Ac[t.funcName].size,mclass:Ac[t.funcName].mclass,delim:r.text}},htmlBuilder:(t,e)=>t.delim==="."?F.makeSpan([t.mclass]):Fr.sizedDelim(t.delim,t.size,e,t.mode,[t.mclass]),mathmlBuilder:t=>{var e=[];t.delim!=="."&&e.push(ar(t.delim,t.mode));var r=new Q.MathNode("mo",e);t.mclass==="mopen"||t.mclass==="mclose"?r.setAttribute("fence","true"):r.setAttribute("fence","false"),r.setAttribute("stretchy","true");var n=se(Fr.sizeToMaxHeight[t.size]);return r.setAttribute("minsize",n),r.setAttribute("maxsize",n),r}});function Ec(t){if(!t.body)throw new Error("Bug: The leftright ParseNode wasn't fully parsed.")}ce({type:"leftright-right",names:["\\right"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var r=t.parser.gullet.macros.get("\\current@color");if(r&&typeof r!="string")throw new te("\\current@color set to non-string in \\right");return{type:"leftright-right",mode:t.parser.mode,delim:vs(e[0],t).text,color:r}}});ce({type:"leftright",names:["\\left"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var r=vs(e[0],t),n=t.parser;++n.leftrightDepth;var i=n.parseExpression(!1);--n.leftrightDepth,n.expect("\\right",!1);var s=Ie(n.parseFunction(),"leftright-right");return{type:"leftright",mode:n.mode,body:i,left:r.text,right:s.delim,rightColor:s.color}},htmlBuilder:(t,e)=>{Ec(t);for(var r=bt(t.body,e,!0,["mopen","mclose"]),n=0,i=0,s=!1,a=0;a<r.length;a++)r[a].isMiddle?s=!0:(n=Math.max(r[a].height,n),i=Math.max(r[a].depth,i));n*=e.sizeMultiplier,i*=e.sizeMultiplier;var o;if(t.left==="."?o=A0(e,["mopen"]):o=Fr.leftRightDelim(t.left,n,i,e,t.mode,["mopen"]),r.unshift(o),s)for(var l=1;l<r.length;l++){var c=r[l],u=c.isMiddle;u&&(r[l]=Fr.leftRightDelim(u.delim,n,i,u.options,t.mode,[]))}var f;if(t.right===".")f=A0(e,["mclose"]);else{var p=t.rightColor?e.withColor(t.rightColor):e;f=Fr.leftRightDelim(t.right,n,i,p,t.mode,["mclose"])}return r.push(f),F.makeSpan(["minner"],r,e)},mathmlBuilder:(t,e)=>{Ec(t);var r=Ut(t.body,e);if(t.left!=="."){var n=new Q.MathNode("mo",[ar(t.left,t.mode)]);n.setAttribute("fence","true"),r.unshift(n)}if(t.right!=="."){var i=new Q.MathNode("mo",[ar(t.right,t.mode)]);i.setAttribute("fence","true"),t.rightColor&&i.setAttribute("mathcolor",t.rightColor),r.push(i)}return Do(r)}});ce({type:"middle",names:["\\middle"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var r=vs(e[0],t);if(!t.parser.leftrightDepth)throw new te("\\middle without preceding \\left",r);return{type:"middle",mode:t.parser.mode,delim:r.text}},htmlBuilder:(t,e)=>{var r;if(t.delim===".")r=A0(e,[]);else{r=Fr.sizedDelim(t.delim,1,e,t.mode,[]);var n={delim:t.delim,options:e};r.isMiddle=n}return r},mathmlBuilder:(t,e)=>{var r=t.delim==="\\vert"||t.delim==="|"?ar("|","text"):ar(t.delim,t.mode),n=new Q.MathNode("mo",[r]);return n.setAttribute("fence","true"),n.setAttribute("lspace","0.05em"),n.setAttribute("rspace","0.05em"),n}});var $o=(t,e)=>{var r=F.wrapFragment($e(t.body,e),e),n=t.label.slice(1),i=e.sizeMultiplier,s,a=0,o=ve.isCharacterBox(t.body);if(n==="sout")s=F.makeSpan(["stretchy","sout"]),s.height=e.fontMetrics().defaultRuleThickness/i,a=-.5*e.fontMetrics().xHeight;else if(n==="phase"){var l=at({number:.6,unit:"pt"},e),c=at({number:.35,unit:"ex"},e),u=e.havingBaseSizing();i=i/u.sizeMultiplier;var f=r.height+r.depth+l+c;r.style.paddingLeft=se(f/2+l);var p=Math.floor(1e3*f*i),g=U6(p),b=new Hr([new an("phase",g)],{width:"400em",height:se(p/1e3),viewBox:"0 0 400000 "+p,preserveAspectRatio:"xMinYMin slice"});s=F.makeSvgSpan(["hide-tail"],[b],e),s.style.height=se(f),a=r.depth+l+c}else{/cancel/.test(n)?o||r.classes.push("cancel-pad"):n==="angl"?r.classes.push("anglpad"):r.classes.push("boxpad");var x=0,w=0,N=0;/box/.test(n)?(N=Math.max(e.fontMetrics().fboxrule,e.minRuleThickness),x=e.fontMetrics().fboxsep+(n==="colorbox"?0:N),w=x):n==="angl"?(N=Math.max(e.fontMetrics().defaultRuleThickness,e.minRuleThickness),x=4*N,w=Math.max(0,.25-r.depth)):(x=o?.2:0,w=x),s=jr.encloseSpan(r,n,x,w,e),/fbox|boxed|fcolorbox/.test(n)?(s.style.borderStyle="solid",s.style.borderWidth=se(N)):n==="angl"&&N!==.049&&(s.style.borderTopWidth=se(N),s.style.borderRightWidth=se(N)),a=r.depth+w,t.backgroundColor&&(s.style.backgroundColor=t.backgroundColor,t.borderColor&&(s.style.borderColor=t.borderColor))}var y;if(t.backgroundColor)y=F.makeVList({positionType:"individualShift",children:[{type:"elem",elem:s,shift:a},{type:"elem",elem:r,shift:0}]},e);else{var k=/cancel|phase/.test(n)?["svg-align"]:[];y=F.makeVList({positionType:"individualShift",children:[{type:"elem",elem:r,shift:0},{type:"elem",elem:s,shift:a,wrapperClasses:k}]},e)}return/cancel/.test(n)&&(y.height=r.height,y.depth=r.depth),/cancel/.test(n)&&!o?F.makeSpan(["mord","cancel-lap"],[y],e):F.makeSpan(["mord"],[y],e)},Fo=(t,e)=>{var r=0,n=new Q.MathNode(t.label.indexOf("colorbox")>-1?"mpadded":"menclose",[Qe(t.body,e)]);switch(t.label){case"\\cancel":n.setAttribute("notation","updiagonalstrike");break;case"\\bcancel":n.setAttribute("notation","downdiagonalstrike");break;case"\\phase":n.setAttribute("notation","phasorangle");break;case"\\sout":n.setAttribute("notation","horizontalstrike");break;case"\\fbox":n.setAttribute("notation","box");break;case"\\angl":n.setAttribute("notation","actuarial");break;case"\\fcolorbox":case"\\colorbox":if(r=e.fontMetrics().fboxsep*e.fontMetrics().ptPerEm,n.setAttribute("width","+"+2*r+"pt"),n.setAttribute("height","+"+2*r+"pt"),n.setAttribute("lspace",r+"pt"),n.setAttribute("voffset",r+"pt"),t.label==="\\fcolorbox"){var i=Math.max(e.fontMetrics().fboxrule,e.minRuleThickness);n.setAttribute("style","border: "+i+"em solid "+String(t.borderColor))}break;case"\\xcancel":n.setAttribute("notation","updiagonalstrike downdiagonalstrike");break}return t.backgroundColor&&n.setAttribute("mathbackground",t.backgroundColor),n};ce({type:"enclose",names:["\\colorbox"],props:{numArgs:2,allowedInText:!0,argTypes:["color","text"]},handler(t,e,r){var{parser:n,funcName:i}=t,s=Ie(e[0],"color-token").color,a=e[1];return{type:"enclose",mode:n.mode,label:i,backgroundColor:s,body:a}},htmlBuilder:$o,mathmlBuilder:Fo});ce({type:"enclose",names:["\\fcolorbox"],props:{numArgs:3,allowedInText:!0,argTypes:["color","color","text"]},handler(t,e,r){var{parser:n,funcName:i}=t,s=Ie(e[0],"color-token").color,a=Ie(e[1],"color-token").color,o=e[2];return{type:"enclose",mode:n.mode,label:i,backgroundColor:a,borderColor:s,body:o}},htmlBuilder:$o,mathmlBuilder:Fo});ce({type:"enclose",names:["\\fbox"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!0},handler(t,e){var{parser:r}=t;return{type:"enclose",mode:r.mode,label:"\\fbox",body:e[0]}}});ce({type:"enclose",names:["\\cancel","\\bcancel","\\xcancel","\\sout","\\phase"],props:{numArgs:1},handler(t,e){var{parser:r,funcName:n}=t,i=e[0];return{type:"enclose",mode:r.mode,label:n,body:i}},htmlBuilder:$o,mathmlBuilder:Fo});ce({type:"enclose",names:["\\angl"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!1},handler(t,e){var{parser:r}=t;return{type:"enclose",mode:r.mode,label:"\\angl",body:e[0]}}});var Od={};function Ar(t){for(var{type:e,names:r,props:n,handler:i,htmlBuilder:s,mathmlBuilder:a}=t,o={type:e,numArgs:n.numArgs||0,allowedInText:!1,numOptionalArgs:0,handler:i},l=0;l<r.length;++l)Od[r[l]]=o;s&&(qi[e]=s),a&&(ji[e]=a)}var _d={};function v(t,e){_d[t]=e}function Cc(t){var e=[];t.consumeSpaces();var r=t.fetch().text;for(r==="\\relax"&&(t.consume(),t.consumeSpaces(),r=t.fetch().text);r==="\\hline"||r==="\\hdashline";)t.consume(),e.push(r==="\\hdashline"),t.consumeSpaces(),r=t.fetch().text;return e}var bs=t=>{var e=t.parser.settings;if(!e.displayMode)throw new te("{"+t.envName+"} can be used only in display mode.")};function Bo(t){if(t.indexOf("ed")===-1)return t.indexOf("*")===-1}function dn(t,e,r){var{hskipBeforeAndAfter:n,addJot:i,cols:s,arraystretch:a,colSeparationType:o,autoTag:l,singleRow:c,emptySingleRow:u,maxNumCols:f,leqno:p}=e;if(t.gullet.beginGroup(),c||t.gullet.macros.set("\\cr","\\\\\\relax"),!a){var g=t.gullet.expandMacroAsText("\\arraystretch");if(g==null)a=1;else if(a=parseFloat(g),!a||a<0)throw new te("Invalid \\arraystretch: "+g)}t.gullet.beginGroup();var b=[],x=[b],w=[],N=[],y=l!=null?[]:void 0;function k(){l&&t.gullet.macros.set("\\@eqnsw","1",!0)}function I(){y&&(t.gullet.macros.get("\\df@tag")?(y.push(t.subparse([new nr("\\df@tag")])),t.gullet.macros.set("\\df@tag",void 0,!0)):y.push(!!l&&t.gullet.macros.get("\\@eqnsw")==="1"))}for(k(),N.push(Cc(t));;){var D=t.parseExpression(!1,c?"\\end":"\\\\");t.gullet.endGroup(),t.gullet.beginGroup(),D={type:"ordgroup",mode:t.mode,body:D},r&&(D={type:"styling",mode:t.mode,style:r,body:[D]}),b.push(D);var O=t.fetch().text;if(O==="&"){if(f&&b.length===f){if(c||o)throw new te("Too many tab characters: &",t.nextToken);t.settings.reportNonstrict("textEnv","Too few columns specified in the {array} column argument.")}t.consume()}else if(O==="\\end"){I(),b.length===1&&D.type==="styling"&&D.body[0].body.length===0&&(x.length>1||!u)&&x.pop(),N.length<x.length+1&&N.push([]);break}else if(O==="\\\\"){t.consume();var z=void 0;t.gullet.future().text!==" "&&(z=t.parseSizeGroup(!0)),w.push(z?z.value:null),I(),N.push(Cc(t)),b=[],x.push(b),k()}else throw new te("Expected & or \\\\ or \\cr or \\end",t.nextToken)}return t.gullet.endGroup(),t.gullet.endGroup(),{type:"array",mode:t.mode,addJot:i,arraystretch:a,body:x,cols:s,rowGaps:w,hskipBeforeAndAfter:n,hLinesBeforeRow:N,colSeparationType:o,tags:y,leqno:p}}function Po(t){return t.slice(0,1)==="d"?"display":"text"}var Er=function(e,r){var n,i,s=e.body.length,a=e.hLinesBeforeRow,o=0,l=new Array(s),c=[],u=Math.max(r.fontMetrics().arrayRuleWidth,r.minRuleThickness),f=1/r.fontMetrics().ptPerEm,p=5*f;if(e.colSeparationType&&e.colSeparationType==="small"){var g=r.havingStyle(xe.SCRIPT).sizeMultiplier;p=.2778*(g/r.sizeMultiplier)}var b=e.colSeparationType==="CD"?at({number:3,unit:"ex"},r):12*f,x=3*f,w=e.arraystretch*b,N=.7*w,y=.3*w,k=0;function I(U){for(var Z=0;Z<U.length;++Z)Z>0&&(k+=.25),c.push({pos:k,isDashed:U[Z]})}for(I(a[0]),n=0;n<e.body.length;++n){var D=e.body[n],O=N,z=y;o<D.length&&(o=D.length);var W=new Array(D.length);for(i=0;i<D.length;++i){var H=$e(D[i],r);z<H.depth&&(z=H.depth),O<H.height&&(O=H.height),W[i]=H}var oe=e.rowGaps[n],me=0;oe&&(me=at(oe,r),me>0&&(me+=y,z<me&&(z=me),me=0)),e.addJot&&(z+=x),W.height=O,W.depth=z,k+=O,W.pos=k,k+=z+me,l[n]=W,I(a[n+1])}var ye=k/2+r.fontMetrics().axisHeight,Le=e.cols||[],ze=[],Ge,Oe,ke=[];if(e.tags&&e.tags.some(U=>U))for(n=0;n<s;++n){var he=l[n],je=he.pos-ye,Ke=e.tags[n],Be=void 0;Ke===!0?Be=F.makeSpan(["eqn-num"],[],r):Ke===!1?Be=F.makeSpan([],[],r):Be=F.makeSpan([],bt(Ke,r,!0),r),Be.depth=he.depth,Be.height=he.height,ke.push({type:"elem",elem:Be,shift:je})}for(i=0,Oe=0;i<o||Oe<Le.length;++i,++Oe){for(var ge=Le[Oe]||{},Ft=!0;ge.type==="separator";){if(Ft||(Ge=F.makeSpan(["arraycolsep"],[]),Ge.style.width=se(r.fontMetrics().doubleRuleSep),ze.push(Ge)),ge.separator==="|"||ge.separator===":"){var ht=ge.separator==="|"?"solid":"dashed",yt=F.makeSpan(["vertical-separator"],[],r);yt.style.height=se(k),yt.style.borderRightWidth=se(u),yt.style.borderRightStyle=ht,yt.style.margin="0 "+se(-u/2);var St=k-ye;St&&(yt.style.verticalAlign=se(-St)),ze.push(yt)}else throw new te("Invalid separator type: "+ge.separator);Oe++,ge=Le[Oe]||{},Ft=!1}if(!(i>=o)){var lt=void 0;(i>0||e.hskipBeforeAndAfter)&&(lt=ve.deflt(ge.pregap,p),lt!==0&&(Ge=F.makeSpan(["arraycolsep"],[]),Ge.style.width=se(lt),ze.push(Ge)));var j=[];for(n=0;n<s;++n){var G=l[n],J=G[i];if(J){var ne=G.pos-ye;J.depth=G.depth,J.height=G.height,j.push({type:"elem",elem:J,shift:ne})}}j=F.makeVList({positionType:"individualShift",children:j},r),j=F.makeSpan(["col-align-"+(ge.align||"c")],[j]),ze.push(j),(i<o-1||e.hskipBeforeAndAfter)&&(lt=ve.deflt(ge.postgap,p),lt!==0&&(Ge=F.makeSpan(["arraycolsep"],[]),Ge.style.width=se(lt),ze.push(Ge)))}}if(l=F.makeSpan(["mtable"],ze),c.length>0){for(var be=F.makeLineSpan("hline",r,u),S=F.makeLineSpan("hdashline",r,u),C=[{type:"elem",elem:l,shift:0}];c.length>0;){var $=c.pop(),q=$.pos-ye;$.isDashed?C.push({type:"elem",elem:S,shift:q}):C.push({type:"elem",elem:be,shift:q})}l=F.makeVList({positionType:"individualShift",children:C},r)}if(ke.length===0)return F.makeSpan(["mord"],[l],r);var B=F.makeVList({positionType:"individualShift",children:ke},r);return B=F.makeSpan(["tag"],[B],r),F.makeFragment([l,B])},Q5={c:"center ",l:"left ",r:"right "},Cr=function(e,r){for(var n=[],i=new Q.MathNode("mtd",[],["mtr-glue"]),s=new Q.MathNode("mtd",[],["mml-eqn-num"]),a=0;a<e.body.length;a++){for(var o=e.body[a],l=[],c=0;c<o.length;c++)l.push(new Q.MathNode("mtd",[Qe(o[c],r)]));e.tags&&e.tags[a]&&(l.unshift(i),l.push(i),e.leqno?l.unshift(s):l.push(s)),n.push(new Q.MathNode("mtr",l))}var u=new Q.MathNode("mtable",n),f=e.arraystretch===.5?.1:.16+e.arraystretch-1+(e.addJot?.09:0);u.setAttribute("rowspacing",se(f));var p="",g="";if(e.cols&&e.cols.length>0){var b=e.cols,x="",w=!1,N=0,y=b.length;b[0].type==="separator"&&(p+="top ",N=1),b[b.length-1].type==="separator"&&(p+="bottom ",y-=1);for(var k=N;k<y;k++)b[k].type==="align"?(g+=Q5[b[k].align],w&&(x+="none "),w=!0):b[k].type==="separator"&&w&&(x+=b[k].separator==="|"?"solid ":"dashed ",w=!1);u.setAttribute("columnalign",g.trim()),/[sd]/.test(x)&&u.setAttribute("columnlines",x.trim())}if(e.colSeparationType==="align"){for(var I=e.cols||[],D="",O=1;O<I.length;O++)D+=O%2?"0em ":"1em ";u.setAttribute("columnspacing",D.trim())}else e.colSeparationType==="alignat"||e.colSeparationType==="gather"?u.setAttribute("columnspacing","0em"):e.colSeparationType==="small"?u.setAttribute("columnspacing","0.2778em"):e.colSeparationType==="CD"?u.setAttribute("columnspacing","0.5em"):u.setAttribute("columnspacing","1em");var z="",W=e.hLinesBeforeRow;p+=W[0].length>0?"left ":"",p+=W[W.length-1].length>0?"right ":"";for(var H=1;H<W.length-1;H++)z+=W[H].length===0?"none ":W[H][0]?"dashed ":"solid ";return/[sd]/.test(z)&&u.setAttribute("rowlines",z.trim()),p!==""&&(u=new Q.MathNode("menclose",[u]),u.setAttribute("notation",p.trim())),e.arraystretch&&e.arraystretch<1&&(u=new Q.MathNode("mstyle",[u]),u.setAttribute("scriptlevel","1")),u},Ld=function(e,r){e.envName.indexOf("ed")===-1&&bs(e);var n=[],i=e.envName.indexOf("at")>-1?"alignat":"align",s=e.envName==="split",a=dn(e.parser,{cols:n,addJot:!0,autoTag:s?void 0:Bo(e.envName),emptySingleRow:!0,colSeparationType:i,maxNumCols:s?2:void 0,leqno:e.parser.settings.leqno},"display"),o,l=0,c={type:"ordgroup",mode:e.mode,body:[]};if(r[0]&&r[0].type==="ordgroup"){for(var u="",f=0;f<r[0].body.length;f++){var p=Ie(r[0].body[f],"textord");u+=p.text}o=Number(u),l=o*2}var g=!l;a.body.forEach(function(N){for(var y=1;y<N.length;y+=2){var k=Ie(N[y],"styling"),I=Ie(k.body[0],"ordgroup");I.body.unshift(c)}if(g)l<N.length&&(l=N.length);else{var D=N.length/2;if(o<D)throw new te("Too many math in a row: "+("expected "+o+", but got "+D),N[0])}});for(var b=0;b<l;++b){var x="r",w=0;b%2===1?x="l":b>0&&g&&(w=1),n[b]={type:"align",align:x,pregap:w,postgap:0}}return a.colSeparationType=g?"align":"alignat",a};Ar({type:"array",names:["array","darray"],props:{numArgs:1},handler(t,e){var r=ms(e[0]),n=r?[e[0]]:Ie(e[0],"ordgroup").body,i=n.map(function(a){var o=_o(a),l=o.text;if("lcr".indexOf(l)!==-1)return{type:"align",align:l};if(l==="|")return{type:"separator",separator:"|"};if(l===":")return{type:"separator",separator:":"};throw new te("Unknown column alignment: "+l,a)}),s={cols:i,hskipBeforeAndAfter:!0,maxNumCols:i.length};return dn(t.parser,s,Po(t.envName))},htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["matrix","pmatrix","bmatrix","Bmatrix","vmatrix","Vmatrix","matrix*","pmatrix*","bmatrix*","Bmatrix*","vmatrix*","Vmatrix*"],props:{numArgs:0},handler(t){var e={matrix:null,pmatrix:["(",")"],bmatrix:["[","]"],Bmatrix:["\\{","\\}"],vmatrix:["|","|"],Vmatrix:["\\Vert","\\Vert"]}[t.envName.replace("*","")],r="c",n={hskipBeforeAndAfter:!1,cols:[{type:"align",align:r}]};if(t.envName.charAt(t.envName.length-1)==="*"){var i=t.parser;if(i.consumeSpaces(),i.fetch().text==="["){if(i.consume(),i.consumeSpaces(),r=i.fetch().text,"lcr".indexOf(r)===-1)throw new te("Expected l or c or r",i.nextToken);i.consume(),i.consumeSpaces(),i.expect("]"),i.consume(),n.cols=[{type:"align",align:r}]}}var s=dn(t.parser,n,Po(t.envName)),a=Math.max(0,...s.body.map(o=>o.length));return s.cols=new Array(a).fill({type:"align",align:r}),e?{type:"leftright",mode:t.mode,body:[s],left:e[0],right:e[1],rightColor:void 0}:s},htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["smallmatrix"],props:{numArgs:0},handler(t){var e={arraystretch:.5},r=dn(t.parser,e,"script");return r.colSeparationType="small",r},htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["subarray"],props:{numArgs:1},handler(t,e){var r=ms(e[0]),n=r?[e[0]]:Ie(e[0],"ordgroup").body,i=n.map(function(a){var o=_o(a),l=o.text;if("lc".indexOf(l)!==-1)return{type:"align",align:l};throw new te("Unknown column alignment: "+l,a)});if(i.length>1)throw new te("{subarray} can contain only one column");var s={cols:i,hskipBeforeAndAfter:!1,arraystretch:.5};if(s=dn(t.parser,s,"script"),s.body.length>0&&s.body[0].length>1)throw new te("{subarray} can contain only one column");return s},htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["cases","dcases","rcases","drcases"],props:{numArgs:0},handler(t){var e={arraystretch:1.2,cols:[{type:"align",align:"l",pregap:0,postgap:1},{type:"align",align:"l",pregap:0,postgap:0}]},r=dn(t.parser,e,Po(t.envName));return{type:"leftright",mode:t.mode,body:[r],left:t.envName.indexOf("r")>-1?".":"\\{",right:t.envName.indexOf("r")>-1?"\\}":".",rightColor:void 0}},htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["align","align*","aligned","split"],props:{numArgs:0},handler:Ld,htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["gathered","gather","gather*"],props:{numArgs:0},handler(t){ve.contains(["gather","gather*"],t.envName)&&bs(t);var e={cols:[{type:"align",align:"c"}],addJot:!0,colSeparationType:"gather",autoTag:Bo(t.envName),emptySingleRow:!0,leqno:t.parser.settings.leqno};return dn(t.parser,e,"display")},htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["alignat","alignat*","alignedat"],props:{numArgs:1},handler:Ld,htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["equation","equation*"],props:{numArgs:0},handler(t){bs(t);var e={autoTag:Bo(t.envName),emptySingleRow:!0,singleRow:!0,maxNumCols:1,leqno:t.parser.settings.leqno};return dn(t.parser,e,"display")},htmlBuilder:Er,mathmlBuilder:Cr});Ar({type:"array",names:["CD"],props:{numArgs:0},handler(t){return bs(t),B5(t.parser)},htmlBuilder:Er,mathmlBuilder:Cr});v("\\nonumber","\\gdef\\@eqnsw{0}");v("\\notag","\\nonumber");ce({type:"text",names:["\\hline","\\hdashline"],props:{numArgs:0,allowedInText:!0,allowedInMath:!0},handler(t,e){throw new te(t.funcName+" valid only within array environment")}});var Mc=Od;ce({type:"environment",names:["\\begin","\\end"],props:{numArgs:1,argTypes:["text"]},handler(t,e){var{parser:r,funcName:n}=t,i=e[0];if(i.type!=="ordgroup")throw new te("Invalid environment name",i);for(var s="",a=0;a<i.body.length;++a)s+=Ie(i.body[a],"textord").text;if(n==="\\begin"){if(!Mc.hasOwnProperty(s))throw new te("No such environment: "+s,i);var o=Mc[s],{args:l,optArgs:c}=r.parseArguments("\\begin{"+s+"}",o),u={mode:r.mode,envName:s,parser:r},f=o.handler(u,l,c);r.expect("\\end",!1);var p=r.nextToken,g=Ie(r.parseFunction(),"environment");if(g.name!==s)throw new te("Mismatch: \\begin{"+s+"} matched by \\end{"+g.name+"}",p);return f}return{type:"environment",mode:r.mode,name:s,nameGroup:i}}});var zd=(t,e)=>{var r=t.font,n=e.withFont(r);return $e(t.body,n)},$d=(t,e)=>{var r=t.font,n=e.withFont(r);return Qe(t.body,n)},Nc={"\\Bbb":"\\mathbb","\\bold":"\\mathbf","\\frak":"\\mathfrak","\\bm":"\\boldsymbol"};ce({type:"font",names:["\\mathrm","\\mathit","\\mathbf","\\mathnormal","\\mathsfit","\\mathbb","\\mathcal","\\mathfrak","\\mathscr","\\mathsf","\\mathtt","\\Bbb","\\bold","\\frak"],props:{numArgs:1,allowedInArgument:!0},handler:(t,e)=>{var{parser:r,funcName:n}=t,i=Ui(e[0]),s=n;return s in Nc&&(s=Nc[s]),{type:"font",mode:r.mode,font:s.slice(1),body:i}},htmlBuilder:zd,mathmlBuilder:$d});ce({type:"mclass",names:["\\boldsymbol","\\bm"],props:{numArgs:1},handler:(t,e)=>{var{parser:r}=t,n=e[0],i=ve.isCharacterBox(n);return{type:"mclass",mode:r.mode,mclass:gs(n),body:[{type:"font",mode:r.mode,font:"boldsymbol",body:n}],isCharacterBox:i}}});ce({type:"font",names:["\\rm","\\sf","\\tt","\\bf","\\it","\\cal"],props:{numArgs:0,allowedInText:!0},handler:(t,e)=>{var{parser:r,funcName:n,breakOnTokenText:i}=t,{mode:s}=r,a=r.parseExpression(!0,i),o="math"+n.slice(1);return{type:"font",mode:s,font:o,body:{type:"ordgroup",mode:r.mode,body:a}}},htmlBuilder:zd,mathmlBuilder:$d});var Fd=(t,e)=>{var r=e;return t==="display"?r=r.id>=xe.SCRIPT.id?r.text():xe.DISPLAY:t==="text"&&r.size===xe.DISPLAY.size?r=xe.TEXT:t==="script"?r=xe.SCRIPT:t==="scriptscript"&&(r=xe.SCRIPTSCRIPT),r},Ho=(t,e)=>{var r=Fd(t.size,e.style),n=r.fracNum(),i=r.fracDen(),s;s=e.havingStyle(n);var a=$e(t.numer,s,e);if(t.continued){var o=8.5/e.fontMetrics().ptPerEm,l=3.5/e.fontMetrics().ptPerEm;a.height=a.height<o?o:a.height,a.depth=a.depth<l?l:a.depth}s=e.havingStyle(i);var c=$e(t.denom,s,e),u,f,p;t.hasBarLine?(t.barSize?(f=at(t.barSize,e),u=F.makeLineSpan("frac-line",e,f)):u=F.makeLineSpan("frac-line",e),f=u.height,p=u.height):(u=null,f=0,p=e.fontMetrics().defaultRuleThickness);var g,b,x;r.size===xe.DISPLAY.size||t.size==="display"?(g=e.fontMetrics().num1,f>0?b=3*p:b=7*p,x=e.fontMetrics().denom1):(f>0?(g=e.fontMetrics().num2,b=p):(g=e.fontMetrics().num3,b=3*p),x=e.fontMetrics().denom2);var w;if(u){var y=e.fontMetrics().axisHeight;g-a.depth-(y+.5*f)<b&&(g+=b-(g-a.depth-(y+.5*f))),y-.5*f-(c.height-x)<b&&(x+=b-(y-.5*f-(c.height-x)));var k=-(y-.5*f);w=F.makeVList({positionType:"individualShift",children:[{type:"elem",elem:c,shift:x},{type:"elem",elem:u,shift:k},{type:"elem",elem:a,shift:-g}]},e)}else{var N=g-a.depth-(c.height-x);N<b&&(g+=.5*(b-N),x+=.5*(b-N)),w=F.makeVList({positionType:"individualShift",children:[{type:"elem",elem:c,shift:x},{type:"elem",elem:a,shift:-g}]},e)}s=e.havingStyle(r),w.height*=s.sizeMultiplier/e.sizeMultiplier,w.depth*=s.sizeMultiplier/e.sizeMultiplier;var I;r.size===xe.DISPLAY.size?I=e.fontMetrics().delim1:r.size===xe.SCRIPTSCRIPT.size?I=e.havingStyle(xe.SCRIPT).fontMetrics().delim2:I=e.fontMetrics().delim2;var D,O;return t.leftDelim==null?D=A0(e,["mopen"]):D=Fr.customSizedDelim(t.leftDelim,I,!0,e.havingStyle(r),t.mode,["mopen"]),t.continued?O=F.makeSpan([]):t.rightDelim==null?O=A0(e,["mclose"]):O=Fr.customSizedDelim(t.rightDelim,I,!0,e.havingStyle(r),t.mode,["mclose"]),F.makeSpan(["mord"].concat(s.sizingClasses(e)),[D,F.makeSpan(["mfrac"],[w]),O],e)},qo=(t,e)=>{var r=new Q.MathNode("mfrac",[Qe(t.numer,e),Qe(t.denom,e)]);if(!t.hasBarLine)r.setAttribute("linethickness","0px");else if(t.barSize){var n=at(t.barSize,e);r.setAttribute("linethickness",se(n))}var i=Fd(t.size,e.style);if(i.size!==e.style.size){r=new Q.MathNode("mstyle",[r]);var s=i.size===xe.DISPLAY.size?"true":"false";r.setAttribute("displaystyle",s),r.setAttribute("scriptlevel","0")}if(t.leftDelim!=null||t.rightDelim!=null){var a=[];if(t.leftDelim!=null){var o=new Q.MathNode("mo",[new Q.TextNode(t.leftDelim.replace("\\",""))]);o.setAttribute("fence","true"),a.push(o)}if(a.push(r),t.rightDelim!=null){var l=new Q.MathNode("mo",[new Q.TextNode(t.rightDelim.replace("\\",""))]);l.setAttribute("fence","true"),a.push(l)}return Do(a)}return r};ce({type:"genfrac",names:["\\dfrac","\\frac","\\tfrac","\\dbinom","\\binom","\\tbinom","\\\\atopfrac","\\\\bracefrac","\\\\brackfrac"],props:{numArgs:2,allowedInArgument:!0},handler:(t,e)=>{var{parser:r,funcName:n}=t,i=e[0],s=e[1],a,o=null,l=null,c="auto";switch(n){case"\\dfrac":case"\\frac":case"\\tfrac":a=!0;break;case"\\\\atopfrac":a=!1;break;case"\\dbinom":case"\\binom":case"\\tbinom":a=!1,o="(",l=")";break;case"\\\\bracefrac":a=!1,o="\\{",l="\\}";break;case"\\\\brackfrac":a=!1,o="[",l="]";break;default:throw new Error("Unrecognized genfrac command")}switch(n){case"\\dfrac":case"\\dbinom":c="display";break;case"\\tfrac":case"\\tbinom":c="text";break}return{type:"genfrac",mode:r.mode,continued:!1,numer:i,denom:s,hasBarLine:a,leftDelim:o,rightDelim:l,size:c,barSize:null}},htmlBuilder:Ho,mathmlBuilder:qo});ce({type:"genfrac",names:["\\cfrac"],props:{numArgs:2},handler:(t,e)=>{var{parser:r,funcName:n}=t,i=e[0],s=e[1];return{type:"genfrac",mode:r.mode,continued:!0,numer:i,denom:s,hasBarLine:!0,leftDelim:null,rightDelim:null,size:"display",barSize:null}}});ce({type:"infix",names:["\\over","\\choose","\\atop","\\brace","\\brack"],props:{numArgs:0,infix:!0},handler(t){var{parser:e,funcName:r,token:n}=t,i;switch(r){case"\\over":i="\\frac";break;case"\\choose":i="\\binom";break;case"\\atop":i="\\\\atopfrac";break;case"\\brace":i="\\\\bracefrac";break;case"\\brack":i="\\\\brackfrac";break;default:throw new Error("Unrecognized infix genfrac command")}return{type:"infix",mode:e.mode,replaceWith:i,token:n}}});var Ic=["display","text","script","scriptscript"],Rc=function(e){var r=null;return e.length>0&&(r=e,r=r==="."?null:r),r};ce({type:"genfrac",names:["\\genfrac"],props:{numArgs:6,allowedInArgument:!0,argTypes:["math","math","size","text","math","math"]},handler(t,e){var{parser:r}=t,n=e[4],i=e[5],s=Ui(e[0]),a=s.type==="atom"&&s.family==="open"?Rc(s.text):null,o=Ui(e[1]),l=o.type==="atom"&&o.family==="close"?Rc(o.text):null,c=Ie(e[2],"size"),u,f=null;c.isBlank?u=!0:(f=c.value,u=f.number>0);var p="auto",g=e[3];if(g.type==="ordgroup"){if(g.body.length>0){var b=Ie(g.body[0],"textord");p=Ic[Number(b.text)]}}else g=Ie(g,"textord"),p=Ic[Number(g.text)];return{type:"genfrac",mode:r.mode,numer:n,denom:i,continued:!1,hasBarLine:u,barSize:f,leftDelim:a,rightDelim:l,size:p}},htmlBuilder:Ho,mathmlBuilder:qo});ce({type:"infix",names:["\\above"],props:{numArgs:1,argTypes:["size"],infix:!0},handler(t,e){var{parser:r,funcName:n,token:i}=t;return{type:"infix",mode:r.mode,replaceWith:"\\\\abovefrac",size:Ie(e[0],"size").value,token:i}}});ce({type:"genfrac",names:["\\\\abovefrac"],props:{numArgs:3,argTypes:["math","size","math"]},handler:(t,e)=>{var{parser:r,funcName:n}=t,i=e[0],s=N6(Ie(e[1],"infix").size),a=e[2],o=s.number>0;return{type:"genfrac",mode:r.mode,numer:i,denom:a,continued:!1,hasBarLine:o,barSize:s,leftDelim:null,rightDelim:null,size:"auto"}},htmlBuilder:Ho,mathmlBuilder:qo});var Bd=(t,e)=>{var r=e.style,n,i;t.type==="supsub"?(n=t.sup?$e(t.sup,e.havingStyle(r.sup()),e):$e(t.sub,e.havingStyle(r.sub()),e),i=Ie(t.base,"horizBrace")):i=Ie(t,"horizBrace");var s=$e(i.base,e.havingBaseStyle(xe.DISPLAY)),a=jr.svgSpan(i,e),o;if(i.isOver?(o=F.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:s},{type:"kern",size:.1},{type:"elem",elem:a}]},e),o.children[0].children[0].children[1].classes.push("svg-align")):(o=F.makeVList({positionType:"bottom",positionData:s.depth+.1+a.height,children:[{type:"elem",elem:a},{type:"kern",size:.1},{type:"elem",elem:s}]},e),o.children[0].children[0].children[0].classes.push("svg-align")),n){var l=F.makeSpan(["mord",i.isOver?"mover":"munder"],[o],e);i.isOver?o=F.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:l},{type:"kern",size:.2},{type:"elem",elem:n}]},e):o=F.makeVList({positionType:"bottom",positionData:l.depth+.2+n.height+n.depth,children:[{type:"elem",elem:n},{type:"kern",size:.2},{type:"elem",elem:l}]},e)}return F.makeSpan(["mord",i.isOver?"mover":"munder"],[o],e)},e7=(t,e)=>{var r=jr.mathMLnode(t.label);return new Q.MathNode(t.isOver?"mover":"munder",[Qe(t.base,e),r])};ce({type:"horizBrace",names:["\\overbrace","\\underbrace"],props:{numArgs:1},handler(t,e){var{parser:r,funcName:n}=t;return{type:"horizBrace",mode:r.mode,label:n,isOver:/^\\over/.test(n),base:e[0]}},htmlBuilder:Bd,mathmlBuilder:e7});ce({type:"href",names:["\\href"],props:{numArgs:2,argTypes:["url","original"],allowedInText:!0},handler:(t,e)=>{var{parser:r}=t,n=e[1],i=Ie(e[0],"url").url;return r.settings.isTrusted({command:"\\href",url:i})?{type:"href",mode:r.mode,href:i,body:dt(n)}:r.formatUnsupportedCmd("\\href")},htmlBuilder:(t,e)=>{var r=bt(t.body,e,!1);return F.makeAnchor(t.href,[],r,e)},mathmlBuilder:(t,e)=>{var r=on(t.body,e);return r instanceof Kt||(r=new Kt("mrow",[r])),r.setAttribute("href",t.href),r}});ce({type:"href",names:["\\url"],props:{numArgs:1,argTypes:["url"],allowedInText:!0},handler:(t,e)=>{var{parser:r}=t,n=Ie(e[0],"url").url;if(!r.settings.isTrusted({command:"\\url",url:n}))return r.formatUnsupportedCmd("\\url");for(var i=[],s=0;s<n.length;s++){var a=n[s];a==="~"&&(a="\\textasciitilde"),i.push({type:"textord",mode:"text",text:a})}var o={type:"text",mode:r.mode,font:"\\texttt",body:i};return{type:"href",mode:r.mode,href:n,body:dt(o)}}});ce({type:"hbox",names:["\\hbox"],props:{numArgs:1,argTypes:["text"],allowedInText:!0,primitive:!0},handler(t,e){var{parser:r}=t;return{type:"hbox",mode:r.mode,body:dt(e[0])}},htmlBuilder(t,e){var r=bt(t.body,e,!1);return F.makeFragment(r)},mathmlBuilder(t,e){return new Q.MathNode("mrow",Ut(t.body,e))}});ce({type:"html",names:["\\htmlClass","\\htmlId","\\htmlStyle","\\htmlData"],props:{numArgs:2,argTypes:["raw","original"],allowedInText:!0},handler:(t,e)=>{var{parser:r,funcName:n,token:i}=t,s=Ie(e[0],"raw").string,a=e[1];r.settings.strict&&r.settings.reportNonstrict("htmlExtension","HTML extension is disabled on strict mode");var o,l={};switch(n){case"\\htmlClass":l.class=s,o={command:"\\htmlClass",class:s};break;case"\\htmlId":l.id=s,o={command:"\\htmlId",id:s};break;case"\\htmlStyle":l.style=s,o={command:"\\htmlStyle",style:s};break;case"\\htmlData":{for(var c=s.split(","),u=0;u<c.length;u++){var f=c[u].split("=");if(f.length!==2)throw new te("Error parsing key-value for \\htmlData");l["data-"+f[0].trim()]=f[1].trim()}o={command:"\\htmlData",attributes:l};break}default:throw new Error("Unrecognized html command")}return r.settings.isTrusted(o)?{type:"html",mode:r.mode,attributes:l,body:dt(a)}:r.formatUnsupportedCmd(n)},htmlBuilder:(t,e)=>{var r=bt(t.body,e,!1),n=["enclosing"];t.attributes.class&&n.push(...t.attributes.class.trim().split(/\s+/));var i=F.makeSpan(n,r,e);for(var s in t.attributes)s!=="class"&&t.attributes.hasOwnProperty(s)&&i.setAttribute(s,t.attributes[s]);return i},mathmlBuilder:(t,e)=>on(t.body,e)});ce({type:"htmlmathml",names:["\\html@mathml"],props:{numArgs:2,allowedInText:!0},handler:(t,e)=>{var{parser:r}=t;return{type:"htmlmathml",mode:r.mode,html:dt(e[0]),mathml:dt(e[1])}},htmlBuilder:(t,e)=>{var r=bt(t.html,e,!1);return F.makeFragment(r)},mathmlBuilder:(t,e)=>on(t.mathml,e)});var Ks=function(e){if(/^[-+]? *(\d+(\.\d*)?|\.\d+)$/.test(e))return{number:+e,unit:"bp"};var r=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(e);if(!r)throw new te("Invalid size: '"+e+"' in \\includegraphics");var n={number:+(r[1]+r[2]),unit:r[3]};if(!id(n))throw new te("Invalid unit: '"+n.unit+"' in \\includegraphics.");return n};ce({type:"includegraphics",names:["\\includegraphics"],props:{numArgs:1,numOptionalArgs:1,argTypes:["raw","url"],allowedInText:!1},handler:(t,e,r)=>{var{parser:n}=t,i={number:0,unit:"em"},s={number:.9,unit:"em"},a={number:0,unit:"em"},o="";if(r[0])for(var l=Ie(r[0],"raw").string,c=l.split(","),u=0;u<c.length;u++){var f=c[u].split("=");if(f.length===2){var p=f[1].trim();switch(f[0].trim()){case"alt":o=p;break;case"width":i=Ks(p);break;case"height":s=Ks(p);break;case"totalheight":a=Ks(p);break;default:throw new te("Invalid key: '"+f[0]+"' in \\includegraphics.")}}}var g=Ie(e[0],"url").url;return o===""&&(o=g,o=o.replace(/^.*[\\/]/,""),o=o.substring(0,o.lastIndexOf("."))),n.settings.isTrusted({command:"\\includegraphics",url:g})?{type:"includegraphics",mode:n.mode,alt:o,width:i,height:s,totalheight:a,src:g}:n.formatUnsupportedCmd("\\includegraphics")},htmlBuilder:(t,e)=>{var r=at(t.height,e),n=0;t.totalheight.number>0&&(n=at(t.totalheight,e)-r);var i=0;t.width.number>0&&(i=at(t.width,e));var s={height:se(r+n)};i>0&&(s.width=se(i)),n>0&&(s.verticalAlign=se(-n));var a=new e5(t.src,t.alt,s);return a.height=r,a.depth=n,a},mathmlBuilder:(t,e)=>{var r=new Q.MathNode("mglyph",[]);r.setAttribute("alt",t.alt);var n=at(t.height,e),i=0;if(t.totalheight.number>0&&(i=at(t.totalheight,e)-n,r.setAttribute("valign",se(-i))),r.setAttribute("height",se(n+i)),t.width.number>0){var s=at(t.width,e);r.setAttribute("width",se(s))}return r.setAttribute("src",t.src),r}});ce({type:"kern",names:["\\kern","\\mkern","\\hskip","\\mskip"],props:{numArgs:1,argTypes:["size"],primitive:!0,allowedInText:!0},handler(t,e){var{parser:r,funcName:n}=t,i=Ie(e[0],"size");if(r.settings.strict){var s=n[1]==="m",a=i.value.unit==="mu";s?(a||r.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+n+" supports only mu units, "+("not "+i.value.unit+" units")),r.mode!=="math"&&r.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+n+" works only in math mode")):a&&r.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+n+" doesn't support mu units")}return{type:"kern",mode:r.mode,dimension:i.value}},htmlBuilder(t,e){return F.makeGlue(t.dimension,e)},mathmlBuilder(t,e){var r=at(t.dimension,e);return new Q.SpaceNode(r)}});ce({type:"lap",names:["\\mathllap","\\mathrlap","\\mathclap"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:r,funcName:n}=t,i=e[0];return{type:"lap",mode:r.mode,alignment:n.slice(5),body:i}},htmlBuilder:(t,e)=>{var r;t.alignment==="clap"?(r=F.makeSpan([],[$e(t.body,e)]),r=F.makeSpan(["inner"],[r],e)):r=F.makeSpan(["inner"],[$e(t.body,e)]);var n=F.makeSpan(["fix"],[]),i=F.makeSpan([t.alignment],[r,n],e),s=F.makeSpan(["strut"]);return s.style.height=se(i.height+i.depth),i.depth&&(s.style.verticalAlign=se(-i.depth)),i.children.unshift(s),i=F.makeSpan(["thinbox"],[i],e),F.makeSpan(["mord","vbox"],[i],e)},mathmlBuilder:(t,e)=>{var r=new Q.MathNode("mpadded",[Qe(t.body,e)]);if(t.alignment!=="rlap"){var n=t.alignment==="llap"?"-1":"-0.5";r.setAttribute("lspace",n+"width")}return r.setAttribute("width","0px"),r}});ce({type:"styling",names:["\\(","$"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(t,e){var{funcName:r,parser:n}=t,i=n.mode;n.switchMode("math");var s=r==="\\("?"\\)":"$",a=n.parseExpression(!1,s);return n.expect(s),n.switchMode(i),{type:"styling",mode:n.mode,style:"text",body:a}}});ce({type:"text",names:["\\)","\\]"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(t,e){throw new te("Mismatched "+t.funcName)}});var Dc=(t,e)=>{switch(e.style.size){case xe.DISPLAY.size:return t.display;case xe.TEXT.size:return t.text;case xe.SCRIPT.size:return t.script;case xe.SCRIPTSCRIPT.size:return t.scriptscript;default:return t.text}};ce({type:"mathchoice",names:["\\mathchoice"],props:{numArgs:4,primitive:!0},handler:(t,e)=>{var{parser:r}=t;return{type:"mathchoice",mode:r.mode,display:dt(e[0]),text:dt(e[1]),script:dt(e[2]),scriptscript:dt(e[3])}},htmlBuilder:(t,e)=>{var r=Dc(t,e),n=bt(r,e,!1);return F.makeFragment(n)},mathmlBuilder:(t,e)=>{var r=Dc(t,e);return on(r,e)}});var Pd=(t,e,r,n,i,s,a)=>{t=F.makeSpan([],[t]);var o=r&&ve.isCharacterBox(r),l,c;if(e){var u=$e(e,n.havingStyle(i.sup()),n);c={elem:u,kern:Math.max(n.fontMetrics().bigOpSpacing1,n.fontMetrics().bigOpSpacing3-u.depth)}}if(r){var f=$e(r,n.havingStyle(i.sub()),n);l={elem:f,kern:Math.max(n.fontMetrics().bigOpSpacing2,n.fontMetrics().bigOpSpacing4-f.height)}}var p;if(c&&l){var g=n.fontMetrics().bigOpSpacing5+l.elem.height+l.elem.depth+l.kern+t.depth+a;p=F.makeVList({positionType:"bottom",positionData:g,children:[{type:"kern",size:n.fontMetrics().bigOpSpacing5},{type:"elem",elem:l.elem,marginLeft:se(-s)},{type:"kern",size:l.kern},{type:"elem",elem:t},{type:"kern",size:c.kern},{type:"elem",elem:c.elem,marginLeft:se(s)},{type:"kern",size:n.fontMetrics().bigOpSpacing5}]},n)}else if(l){var b=t.height-a;p=F.makeVList({positionType:"top",positionData:b,children:[{type:"kern",size:n.fontMetrics().bigOpSpacing5},{type:"elem",elem:l.elem,marginLeft:se(-s)},{type:"kern",size:l.kern},{type:"elem",elem:t}]},n)}else if(c){var x=t.depth+a;p=F.makeVList({positionType:"bottom",positionData:x,children:[{type:"elem",elem:t},{type:"kern",size:c.kern},{type:"elem",elem:c.elem,marginLeft:se(s)},{type:"kern",size:n.fontMetrics().bigOpSpacing5}]},n)}else return t;var w=[p];if(l&&s!==0&&!o){var N=F.makeSpan(["mspace"],[],n);N.style.marginRight=se(s),w.unshift(N)}return F.makeSpan(["mop","op-limits"],w,n)},Hd=["\\smallint"],Jn=(t,e)=>{var r,n,i=!1,s;t.type==="supsub"?(r=t.sup,n=t.sub,s=Ie(t.base,"op"),i=!0):s=Ie(t,"op");var a=e.style,o=!1;a.size===xe.DISPLAY.size&&s.symbol&&!ve.contains(Hd,s.name)&&(o=!0);var l;if(s.symbol){var c=o?"Size2-Regular":"Size1-Regular",u="";if((s.name==="\\oiint"||s.name==="\\oiiint")&&(u=s.name.slice(1),s.name=u==="oiint"?"\\iint":"\\iiint"),l=F.makeSymbol(s.name,c,"math",e,["mop","op-symbol",o?"large-op":"small-op"]),u.length>0){var f=l.italic,p=F.staticSvg(u+"Size"+(o?"2":"1"),e);l=F.makeVList({positionType:"individualShift",children:[{type:"elem",elem:l,shift:0},{type:"elem",elem:p,shift:o?.08:0}]},e),s.name="\\"+u,l.classes.unshift("mop"),l.italic=f}}else if(s.body){var g=bt(s.body,e,!0);g.length===1&&g[0]instanceof sr?(l=g[0],l.classes[0]="mop"):l=F.makeSpan(["mop"],g,e)}else{for(var b=[],x=1;x<s.name.length;x++)b.push(F.mathsym(s.name[x],s.mode,e));l=F.makeSpan(["mop"],b,e)}var w=0,N=0;return(l instanceof sr||s.name==="\\oiint"||s.name==="\\oiiint")&&!s.suppressBaseShift&&(w=(l.height-l.depth)/2-e.fontMetrics().axisHeight,N=l.italic),i?Pd(l,r,n,e,a,N,w):(w&&(l.style.position="relative",l.style.top=se(w)),l)},$0=(t,e)=>{var r;if(t.symbol)r=new Kt("mo",[ar(t.name,t.mode)]),ve.contains(Hd,t.name)&&r.setAttribute("largeop","false");else if(t.body)r=new Kt("mo",Ut(t.body,e));else{r=new Kt("mi",[new Sr(t.name.slice(1))]);var n=new Kt("mo",[ar("","text")]);t.parentIsSupSub?r=new Kt("mrow",[r,n]):r=md([r,n])}return r},t7={"∏":"\\prod","∐":"\\coprod","∑":"\\sum","⋀":"\\bigwedge","⋁":"\\bigvee","⋂":"\\bigcap","⋃":"\\bigcup","⨀":"\\bigodot","⨁":"\\bigoplus","⨂":"\\bigotimes","⨄":"\\biguplus","⨆":"\\bigsqcup"};ce({type:"op",names:["\\coprod","\\bigvee","\\bigwedge","\\biguplus","\\bigcap","\\bigcup","\\intop","\\prod","\\sum","\\bigotimes","\\bigoplus","\\bigodot","\\bigsqcup","\\smallint","∏","∐","∑","⋀","⋁","⋂","⋃","⨀","⨁","⨂","⨄","⨆"],props:{numArgs:0},handler:(t,e)=>{var{parser:r,funcName:n}=t,i=n;return i.length===1&&(i=t7[i]),{type:"op",mode:r.mode,limits:!0,parentIsSupSub:!1,symbol:!0,name:i}},htmlBuilder:Jn,mathmlBuilder:$0});ce({type:"op",names:["\\mathop"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var{parser:r}=t,n=e[0];return{type:"op",mode:r.mode,limits:!1,parentIsSupSub:!1,symbol:!1,body:dt(n)}},htmlBuilder:Jn,mathmlBuilder:$0});var r7={"∫":"\\int","∬":"\\iint","∭":"\\iiint","∮":"\\oint","∯":"\\oiint","∰":"\\oiiint"};ce({type:"op",names:["\\arcsin","\\arccos","\\arctan","\\arctg","\\arcctg","\\arg","\\ch","\\cos","\\cosec","\\cosh","\\cot","\\cotg","\\coth","\\csc","\\ctg","\\cth","\\deg","\\dim","\\exp","\\hom","\\ker","\\lg","\\ln","\\log","\\sec","\\sin","\\sinh","\\sh","\\tan","\\tanh","\\tg","\\th"],props:{numArgs:0},handler(t){var{parser:e,funcName:r}=t;return{type:"op",mode:e.mode,limits:!1,parentIsSupSub:!1,symbol:!1,name:r}},htmlBuilder:Jn,mathmlBuilder:$0});ce({type:"op",names:["\\det","\\gcd","\\inf","\\lim","\\max","\\min","\\Pr","\\sup"],props:{numArgs:0},handler(t){var{parser:e,funcName:r}=t;return{type:"op",mode:e.mode,limits:!0,parentIsSupSub:!1,symbol:!1,name:r}},htmlBuilder:Jn,mathmlBuilder:$0});ce({type:"op",names:["\\int","\\iint","\\iiint","\\oint","\\oiint","\\oiiint","∫","∬","∭","∮","∯","∰"],props:{numArgs:0},handler(t){var{parser:e,funcName:r}=t,n=r;return n.length===1&&(n=r7[n]),{type:"op",mode:e.mode,limits:!1,parentIsSupSub:!1,symbol:!0,name:n}},htmlBuilder:Jn,mathmlBuilder:$0});var qd=(t,e)=>{var r,n,i=!1,s;t.type==="supsub"?(r=t.sup,n=t.sub,s=Ie(t.base,"operatorname"),i=!0):s=Ie(t,"operatorname");var a;if(s.body.length>0){for(var o=s.body.map(f=>{var p=f.text;return typeof p=="string"?{type:"textord",mode:f.mode,text:p}:f}),l=bt(o,e.withFont("mathrm"),!0),c=0;c<l.length;c++){var u=l[c];u instanceof sr&&(u.text=u.text.replace(/\u2212/,"-").replace(/\u2217/,"*"))}a=F.makeSpan(["mop"],l,e)}else a=F.makeSpan(["mop"],[],e);return i?Pd(a,r,n,e,e.style,0,0):a},n7=(t,e)=>{for(var r=Ut(t.body,e.withFont("mathrm")),n=!0,i=0;i<r.length;i++){var s=r[i];if(!(s instanceof Q.SpaceNode))if(s instanceof Q.MathNode)switch(s.type){case"mi":case"mn":case"ms":case"mspace":case"mtext":break;case"mo":{var a=s.children[0];s.children.length===1&&a instanceof Q.TextNode?a.text=a.text.replace(/\u2212/,"-").replace(/\u2217/,"*"):n=!1;break}default:n=!1}else n=!1}if(n){var o=r.map(u=>u.toText()).join("");r=[new Q.TextNode(o)]}var l=new Q.MathNode("mi",r);l.setAttribute("mathvariant","normal");var c=new Q.MathNode("mo",[ar("","text")]);return t.parentIsSupSub?new Q.MathNode("mrow",[l,c]):Q.newDocumentFragment([l,c])};ce({type:"operatorname",names:["\\operatorname@","\\operatornamewithlimits"],props:{numArgs:1},handler:(t,e)=>{var{parser:r,funcName:n}=t,i=e[0];return{type:"operatorname",mode:r.mode,body:dt(i),alwaysHandleSupSub:n==="\\operatornamewithlimits",limits:!1,parentIsSupSub:!1}},htmlBuilder:qd,mathmlBuilder:n7});v("\\operatorname","\\@ifstar\\operatornamewithlimits\\operatorname@");En({type:"ordgroup",htmlBuilder(t,e){return t.semisimple?F.makeFragment(bt(t.body,e,!1)):F.makeSpan(["mord"],bt(t.body,e,!0),e)},mathmlBuilder(t,e){return on(t.body,e,!0)}});ce({type:"overline",names:["\\overline"],props:{numArgs:1},handler(t,e){var{parser:r}=t,n=e[0];return{type:"overline",mode:r.mode,body:n}},htmlBuilder(t,e){var r=$e(t.body,e.havingCrampedStyle()),n=F.makeLineSpan("overline-line",e),i=e.fontMetrics().defaultRuleThickness,s=F.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r},{type:"kern",size:3*i},{type:"elem",elem:n},{type:"kern",size:i}]},e);return F.makeSpan(["mord","overline"],[s],e)},mathmlBuilder(t,e){var r=new Q.MathNode("mo",[new Q.TextNode("‾")]);r.setAttribute("stretchy","true");var n=new Q.MathNode("mover",[Qe(t.body,e),r]);return n.setAttribute("accent","true"),n}});ce({type:"phantom",names:["\\phantom"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:r}=t,n=e[0];return{type:"phantom",mode:r.mode,body:dt(n)}},htmlBuilder:(t,e)=>{var r=bt(t.body,e.withPhantom(),!1);return F.makeFragment(r)},mathmlBuilder:(t,e)=>{var r=Ut(t.body,e);return new Q.MathNode("mphantom",r)}});ce({type:"hphantom",names:["\\hphantom"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:r}=t,n=e[0];return{type:"hphantom",mode:r.mode,body:n}},htmlBuilder:(t,e)=>{var r=F.makeSpan([],[$e(t.body,e.withPhantom())]);if(r.height=0,r.depth=0,r.children)for(var n=0;n<r.children.length;n++)r.children[n].height=0,r.children[n].depth=0;return r=F.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r}]},e),F.makeSpan(["mord"],[r],e)},mathmlBuilder:(t,e)=>{var r=Ut(dt(t.body),e),n=new Q.MathNode("mphantom",r),i=new Q.MathNode("mpadded",[n]);return i.setAttribute("height","0px"),i.setAttribute("depth","0px"),i}});ce({type:"vphantom",names:["\\vphantom"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:r}=t,n=e[0];return{type:"vphantom",mode:r.mode,body:n}},htmlBuilder:(t,e)=>{var r=F.makeSpan(["inner"],[$e(t.body,e.withPhantom())]),n=F.makeSpan(["fix"],[]);return F.makeSpan(["mord","rlap"],[r,n],e)},mathmlBuilder:(t,e)=>{var r=Ut(dt(t.body),e),n=new Q.MathNode("mphantom",r),i=new Q.MathNode("mpadded",[n]);return i.setAttribute("width","0px"),i}});ce({type:"raisebox",names:["\\raisebox"],props:{numArgs:2,argTypes:["size","hbox"],allowedInText:!0},handler(t,e){var{parser:r}=t,n=Ie(e[0],"size").value,i=e[1];return{type:"raisebox",mode:r.mode,dy:n,body:i}},htmlBuilder(t,e){var r=$e(t.body,e),n=at(t.dy,e);return F.makeVList({positionType:"shift",positionData:-n,children:[{type:"elem",elem:r}]},e)},mathmlBuilder(t,e){var r=new Q.MathNode("mpadded",[Qe(t.body,e)]),n=t.dy.number+t.dy.unit;return r.setAttribute("voffset",n),r}});ce({type:"internal",names:["\\relax"],props:{numArgs:0,allowedInText:!0,allowedInArgument:!0},handler(t){var{parser:e}=t;return{type:"internal",mode:e.mode}}});ce({type:"rule",names:["\\rule"],props:{numArgs:2,numOptionalArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["size","size","size"]},handler(t,e,r){var{parser:n}=t,i=r[0],s=Ie(e[0],"size"),a=Ie(e[1],"size");return{type:"rule",mode:n.mode,shift:i&&Ie(i,"size").value,width:s.value,height:a.value}},htmlBuilder(t,e){var r=F.makeSpan(["mord","rule"],[],e),n=at(t.width,e),i=at(t.height,e),s=t.shift?at(t.shift,e):0;return r.style.borderRightWidth=se(n),r.style.borderTopWidth=se(i),r.style.bottom=se(s),r.width=n,r.height=i+s,r.depth=-s,r.maxFontSize=i*1.125*e.sizeMultiplier,r},mathmlBuilder(t,e){var r=at(t.width,e),n=at(t.height,e),i=t.shift?at(t.shift,e):0,s=e.color&&e.getColor()||"black",a=new Q.MathNode("mspace");a.setAttribute("mathbackground",s),a.setAttribute("width",se(r)),a.setAttribute("height",se(n));var o=new Q.MathNode("mpadded",[a]);return i>=0?o.setAttribute("height",se(i)):(o.setAttribute("height",se(i)),o.setAttribute("depth",se(-i))),o.setAttribute("voffset",se(i)),o}});function jd(t,e,r){for(var n=bt(t,e,!1),i=e.sizeMultiplier/r.sizeMultiplier,s=0;s<n.length;s++){var a=n[s].classes.indexOf("sizing");a<0?Array.prototype.push.apply(n[s].classes,e.sizingClasses(r)):n[s].classes[a+1]==="reset-size"+e.size&&(n[s].classes[a+1]="reset-size"+r.size),n[s].height*=i,n[s].depth*=i}return F.makeFragment(n)}var Oc=["\\tiny","\\sixptsize","\\scriptsize","\\footnotesize","\\small","\\normalsize","\\large","\\Large","\\LARGE","\\huge","\\Huge"],i7=(t,e)=>{var r=e.havingSize(t.size);return jd(t.body,r,e)};ce({type:"sizing",names:Oc,props:{numArgs:0,allowedInText:!0},handler:(t,e)=>{var{breakOnTokenText:r,funcName:n,parser:i}=t,s=i.parseExpression(!1,r);return{type:"sizing",mode:i.mode,size:Oc.indexOf(n)+1,body:s}},htmlBuilder:i7,mathmlBuilder:(t,e)=>{var r=e.havingSize(t.size),n=Ut(t.body,r),i=new Q.MathNode("mstyle",n);return i.setAttribute("mathsize",se(r.sizeMultiplier)),i}});ce({type:"smash",names:["\\smash"],props:{numArgs:1,numOptionalArgs:1,allowedInText:!0},handler:(t,e,r)=>{var{parser:n}=t,i=!1,s=!1,a=r[0]&&Ie(r[0],"ordgroup");if(a)for(var o="",l=0;l<a.body.length;++l){var c=a.body[l];if(o=c.text,o==="t")i=!0;else if(o==="b")s=!0;else{i=!1,s=!1;break}}else i=!0,s=!0;var u=e[0];return{type:"smash",mode:n.mode,body:u,smashHeight:i,smashDepth:s}},htmlBuilder:(t,e)=>{var r=F.makeSpan([],[$e(t.body,e)]);if(!t.smashHeight&&!t.smashDepth)return r;if(t.smashHeight&&(r.height=0,r.children))for(var n=0;n<r.children.length;n++)r.children[n].height=0;if(t.smashDepth&&(r.depth=0,r.children))for(var i=0;i<r.children.length;i++)r.children[i].depth=0;var s=F.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r}]},e);return F.makeSpan(["mord"],[s],e)},mathmlBuilder:(t,e)=>{var r=new Q.MathNode("mpadded",[Qe(t.body,e)]);return t.smashHeight&&r.setAttribute("height","0px"),t.smashDepth&&r.setAttribute("depth","0px"),r}});ce({type:"sqrt",names:["\\sqrt"],props:{numArgs:1,numOptionalArgs:1},handler(t,e,r){var{parser:n}=t,i=r[0],s=e[0];return{type:"sqrt",mode:n.mode,body:s,index:i}},htmlBuilder(t,e){var r=$e(t.body,e.havingCrampedStyle());r.height===0&&(r.height=e.fontMetrics().xHeight),r=F.wrapFragment(r,e);var n=e.fontMetrics(),i=n.defaultRuleThickness,s=i;e.style.id<xe.TEXT.id&&(s=e.fontMetrics().xHeight);var a=i+s/4,o=r.height+r.depth+a+i,{span:l,ruleWidth:c,advanceWidth:u}=Fr.sqrtImage(o,e),f=l.height-c;f>r.height+r.depth+a&&(a=(a+f-r.height-r.depth)/2);var p=l.height-r.height-a-c;r.style.paddingLeft=se(u);var g=F.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r,wrapperClasses:["svg-align"]},{type:"kern",size:-(r.height+p)},{type:"elem",elem:l},{type:"kern",size:c}]},e);if(t.index){var b=e.havingStyle(xe.SCRIPTSCRIPT),x=$e(t.index,b,e),w=.6*(g.height-g.depth),N=F.makeVList({positionType:"shift",positionData:-w,children:[{type:"elem",elem:x}]},e),y=F.makeSpan(["root"],[N]);return F.makeSpan(["mord","sqrt"],[y,g],e)}else return F.makeSpan(["mord","sqrt"],[g],e)},mathmlBuilder(t,e){var{body:r,index:n}=t;return n?new Q.MathNode("mroot",[Qe(r,e),Qe(n,e)]):new Q.MathNode("msqrt",[Qe(r,e)])}});var _c={display:xe.DISPLAY,text:xe.TEXT,script:xe.SCRIPT,scriptscript:xe.SCRIPTSCRIPT};ce({type:"styling",names:["\\displaystyle","\\textstyle","\\scriptstyle","\\scriptscriptstyle"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t,e){var{breakOnTokenText:r,funcName:n,parser:i}=t,s=i.parseExpression(!0,r),a=n.slice(1,n.length-5);return{type:"styling",mode:i.mode,style:a,body:s}},htmlBuilder(t,e){var r=_c[t.style],n=e.havingStyle(r).withFont("");return jd(t.body,n,e)},mathmlBuilder(t,e){var r=_c[t.style],n=e.havingStyle(r),i=Ut(t.body,n),s=new Q.MathNode("mstyle",i),a={display:["0","true"],text:["0","false"],script:["1","false"],scriptscript:["2","false"]},o=a[t.style];return s.setAttribute("scriptlevel",o[0]),s.setAttribute("displaystyle",o[1]),s}});var s7=function(e,r){var n=e.base;if(n)if(n.type==="op"){var i=n.limits&&(r.style.size===xe.DISPLAY.size||n.alwaysHandleSupSub);return i?Jn:null}else if(n.type==="operatorname"){var s=n.alwaysHandleSupSub&&(r.style.size===xe.DISPLAY.size||n.limits);return s?qd:null}else{if(n.type==="accent")return ve.isCharacterBox(n.base)?Lo:null;if(n.type==="horizBrace"){var a=!e.sub;return a===n.isOver?Bd:null}else return null}else return null};En({type:"supsub",htmlBuilder(t,e){var r=s7(t,e);if(r)return r(t,e);var{base:n,sup:i,sub:s}=t,a=$e(n,e),o,l,c=e.fontMetrics(),u=0,f=0,p=n&&ve.isCharacterBox(n);if(i){var g=e.havingStyle(e.style.sup());o=$e(i,g,e),p||(u=a.height-g.fontMetrics().supDrop*g.sizeMultiplier/e.sizeMultiplier)}if(s){var b=e.havingStyle(e.style.sub());l=$e(s,b,e),p||(f=a.depth+b.fontMetrics().subDrop*b.sizeMultiplier/e.sizeMultiplier)}var x;e.style===xe.DISPLAY?x=c.sup1:e.style.cramped?x=c.sup3:x=c.sup2;var w=e.sizeMultiplier,N=se(.5/c.ptPerEm/w),y=null;if(l){var k=t.base&&t.base.type==="op"&&t.base.name&&(t.base.name==="\\oiint"||t.base.name==="\\oiiint");(a instanceof sr||k)&&(y=se(-a.italic))}var I;if(o&&l){u=Math.max(u,x,o.depth+.25*c.xHeight),f=Math.max(f,c.sub2);var D=c.defaultRuleThickness,O=4*D;if(u-o.depth-(l.height-f)<O){f=O-(u-o.depth)+l.height;var z=.8*c.xHeight-(u-o.depth);z>0&&(u+=z,f-=z)}var W=[{type:"elem",elem:l,shift:f,marginRight:N,marginLeft:y},{type:"elem",elem:o,shift:-u,marginRight:N}];I=F.makeVList({positionType:"individualShift",children:W},e)}else if(l){f=Math.max(f,c.sub1,l.height-.8*c.xHeight);var H=[{type:"elem",elem:l,marginLeft:y,marginRight:N}];I=F.makeVList({positionType:"shift",positionData:f,children:H},e)}else if(o)u=Math.max(u,x,o.depth+.25*c.xHeight),I=F.makeVList({positionType:"shift",positionData:-u,children:[{type:"elem",elem:o,marginRight:N}]},e);else throw new Error("supsub must have either sup or sub.");var oe=Na(a,"right")||"mord";return F.makeSpan([oe],[a,F.makeSpan(["msupsub"],[I])],e)},mathmlBuilder(t,e){var r=!1,n,i;t.base&&t.base.type==="horizBrace"&&(i=!!t.sup,i===t.base.isOver&&(r=!0,n=t.base.isOver)),t.base&&(t.base.type==="op"||t.base.type==="operatorname")&&(t.base.parentIsSupSub=!0);var s=[Qe(t.base,e)];t.sub&&s.push(Qe(t.sub,e)),t.sup&&s.push(Qe(t.sup,e));var a;if(r)a=n?"mover":"munder";else if(t.sub)if(t.sup){var c=t.base;c&&c.type==="op"&&c.limits&&e.style===xe.DISPLAY||c&&c.type==="operatorname"&&c.alwaysHandleSupSub&&(e.style===xe.DISPLAY||c.limits)?a="munderover":a="msubsup"}else{var l=t.base;l&&l.type==="op"&&l.limits&&(e.style===xe.DISPLAY||l.alwaysHandleSupSub)||l&&l.type==="operatorname"&&l.alwaysHandleSupSub&&(l.limits||e.style===xe.DISPLAY)?a="munder":a="msub"}else{var o=t.base;o&&o.type==="op"&&o.limits&&(e.style===xe.DISPLAY||o.alwaysHandleSupSub)||o&&o.type==="operatorname"&&o.alwaysHandleSupSub&&(o.limits||e.style===xe.DISPLAY)?a="mover":a="msup"}return new Q.MathNode(a,s)}});En({type:"atom",htmlBuilder(t,e){return F.mathsym(t.text,t.mode,e,["m"+t.family])},mathmlBuilder(t,e){var r=new Q.MathNode("mo",[ar(t.text,t.mode)]);if(t.family==="bin"){var n=Oo(t,e);n==="bold-italic"&&r.setAttribute("mathvariant",n)}else t.family==="punct"?r.setAttribute("separator","true"):(t.family==="open"||t.family==="close")&&r.setAttribute("stretchy","false");return r}});var Ud={mi:"italic",mn:"normal",mtext:"normal"};En({type:"mathord",htmlBuilder(t,e){return F.makeOrd(t,e,"mathord")},mathmlBuilder(t,e){var r=new Q.MathNode("mi",[ar(t.text,t.mode,e)]),n=Oo(t,e)||"italic";return n!==Ud[r.type]&&r.setAttribute("mathvariant",n),r}});En({type:"textord",htmlBuilder(t,e){return F.makeOrd(t,e,"textord")},mathmlBuilder(t,e){var r=ar(t.text,t.mode,e),n=Oo(t,e)||"normal",i;return t.mode==="text"?i=new Q.MathNode("mtext",[r]):/[0-9]/.test(t.text)?i=new Q.MathNode("mn",[r]):t.text==="\\prime"?i=new Q.MathNode("mo",[r]):i=new Q.MathNode("mi",[r]),n!==Ud[i.type]&&i.setAttribute("mathvariant",n),i}});var Ys={"\\nobreak":"nobreak","\\allowbreak":"allowbreak"},Xs={" ":{},"\\ ":{},"~":{className:"nobreak"},"\\space":{},"\\nobreakspace":{className:"nobreak"}};En({type:"spacing",htmlBuilder(t,e){if(Xs.hasOwnProperty(t.text)){var r=Xs[t.text].className||"";if(t.mode==="text"){var n=F.makeOrd(t,e,"textord");return n.classes.push(r),n}else return F.makeSpan(["mspace",r],[F.mathsym(t.text,t.mode,e)],e)}else{if(Ys.hasOwnProperty(t.text))return F.makeSpan(["mspace",Ys[t.text]],[],e);throw new te('Unknown type of space "'+t.text+'"')}},mathmlBuilder(t,e){var r;if(Xs.hasOwnProperty(t.text))r=new Q.MathNode("mtext",[new Q.TextNode(" ")]);else{if(Ys.hasOwnProperty(t.text))return new Q.MathNode("mspace");throw new te('Unknown type of space "'+t.text+'"')}return r}});var Lc=()=>{var t=new Q.MathNode("mtd",[]);return t.setAttribute("width","50%"),t};En({type:"tag",mathmlBuilder(t,e){var r=new Q.MathNode("mtable",[new Q.MathNode("mtr",[Lc(),new Q.MathNode("mtd",[on(t.body,e)]),Lc(),new Q.MathNode("mtd",[on(t.tag,e)])])]);return r.setAttribute("width","100%"),r}});var zc={"\\text":void 0,"\\textrm":"textrm","\\textsf":"textsf","\\texttt":"texttt","\\textnormal":"textrm"},$c={"\\textbf":"textbf","\\textmd":"textmd"},a7={"\\textit":"textit","\\textup":"textup"},Fc=(t,e)=>{var r=t.font;if(r){if(zc[r])return e.withTextFontFamily(zc[r]);if($c[r])return e.withTextFontWeight($c[r]);if(r==="\\emph")return e.fontShape==="textit"?e.withTextFontShape("textup"):e.withTextFontShape("textit")}else return e;return e.withTextFontShape(a7[r])};ce({type:"text",names:["\\text","\\textrm","\\textsf","\\texttt","\\textnormal","\\textbf","\\textmd","\\textit","\\textup","\\emph"],props:{numArgs:1,argTypes:["text"],allowedInArgument:!0,allowedInText:!0},handler(t,e){var{parser:r,funcName:n}=t,i=e[0];return{type:"text",mode:r.mode,body:dt(i),font:n}},htmlBuilder(t,e){var r=Fc(t,e),n=bt(t.body,r,!0);return F.makeSpan(["mord","text"],n,r)},mathmlBuilder(t,e){var r=Fc(t,e);return on(t.body,r)}});ce({type:"underline",names:["\\underline"],props:{numArgs:1,allowedInText:!0},handler(t,e){var{parser:r}=t;return{type:"underline",mode:r.mode,body:e[0]}},htmlBuilder(t,e){var r=$e(t.body,e),n=F.makeLineSpan("underline-line",e),i=e.fontMetrics().defaultRuleThickness,s=F.makeVList({positionType:"top",positionData:r.height,children:[{type:"kern",size:i},{type:"elem",elem:n},{type:"kern",size:3*i},{type:"elem",elem:r}]},e);return F.makeSpan(["mord","underline"],[s],e)},mathmlBuilder(t,e){var r=new Q.MathNode("mo",[new Q.TextNode("‾")]);r.setAttribute("stretchy","true");var n=new Q.MathNode("munder",[Qe(t.body,e),r]);return n.setAttribute("accentunder","true"),n}});ce({type:"vcenter",names:["\\vcenter"],props:{numArgs:1,argTypes:["original"],allowedInText:!1},handler(t,e){var{parser:r}=t;return{type:"vcenter",mode:r.mode,body:e[0]}},htmlBuilder(t,e){var r=$e(t.body,e),n=e.fontMetrics().axisHeight,i=.5*(r.height-n-(r.depth+n));return F.makeVList({positionType:"shift",positionData:i,children:[{type:"elem",elem:r}]},e)},mathmlBuilder(t,e){return new Q.MathNode("mpadded",[Qe(t.body,e)],["vcenter"])}});ce({type:"verb",names:["\\verb"],props:{numArgs:0,allowedInText:!0},handler(t,e,r){throw new te("\\verb ended by end of line instead of matching delimiter")},htmlBuilder(t,e){for(var r=Bc(t),n=[],i=e.havingStyle(e.style.text()),s=0;s<r.length;s++){var a=r[s];a==="~"&&(a="\\textasciitilde"),n.push(F.makeSymbol(a,"Typewriter-Regular",t.mode,i,["mord","texttt"]))}return F.makeSpan(["mord","text"].concat(i.sizingClasses(e)),F.tryCombineChars(n),i)},mathmlBuilder(t,e){var r=new Q.TextNode(Bc(t)),n=new Q.MathNode("mtext",[r]);return n.setAttribute("mathvariant","monospace"),n}});var Bc=t=>t.body.replace(/ /g,t.star?"␣":" "),Qr=fd,Vd=`[ \r
|
||
]`,o7="\\\\[a-zA-Z@]+",l7="\\\\[^\uD800-\uDFFF]",c7="("+o7+")"+Vd+"*",u7=`\\\\(
|
||
|[ \r ]+
|
||
?)[ \r ]*`,Oa="[̀-ͯ]",d7=new RegExp(Oa+"+$"),h7="("+Vd+"+)|"+(u7+"|")+"([!-\\[\\]-‧-豈-]"+(Oa+"*")+"|[\uD800-\uDBFF][\uDC00-\uDFFF]"+(Oa+"*")+"|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5"+("|"+c7)+("|"+l7+")");class Pc{constructor(e,r){this.input=void 0,this.settings=void 0,this.tokenRegex=void 0,this.catcodes=void 0,this.input=e,this.settings=r,this.tokenRegex=new RegExp(h7,"g"),this.catcodes={"%":14,"~":13}}setCatcode(e,r){this.catcodes[e]=r}lex(){var e=this.input,r=this.tokenRegex.lastIndex;if(r===e.length)return new nr("EOF",new Wt(this,r,r));var n=this.tokenRegex.exec(e);if(n===null||n.index!==r)throw new te("Unexpected character: '"+e[r]+"'",new nr(e[r],new Wt(this,r,r+1)));var i=n[6]||n[3]||(n[2]?"\\ ":" ");if(this.catcodes[i]===14){var s=e.indexOf(`
|
||
`,this.tokenRegex.lastIndex);return s===-1?(this.tokenRegex.lastIndex=e.length,this.settings.reportNonstrict("commentAtEnd","% comment has no terminating newline; LaTeX would fail because of commenting the end of math mode (e.g. $)")):this.tokenRegex.lastIndex=s+1,this.lex()}return new nr(i,new Wt(this,r,this.tokenRegex.lastIndex))}}class f7{constructor(e,r){e===void 0&&(e={}),r===void 0&&(r={}),this.current=void 0,this.builtins=void 0,this.undefStack=void 0,this.current=r,this.builtins=e,this.undefStack=[]}beginGroup(){this.undefStack.push({})}endGroup(){if(this.undefStack.length===0)throw new te("Unbalanced namespace destruction: attempt to pop global namespace; please report this as a bug");var e=this.undefStack.pop();for(var r in e)e.hasOwnProperty(r)&&(e[r]==null?delete this.current[r]:this.current[r]=e[r])}endGroups(){for(;this.undefStack.length>0;)this.endGroup()}has(e){return this.current.hasOwnProperty(e)||this.builtins.hasOwnProperty(e)}get(e){return this.current.hasOwnProperty(e)?this.current[e]:this.builtins[e]}set(e,r,n){if(n===void 0&&(n=!1),n){for(var i=0;i<this.undefStack.length;i++)delete this.undefStack[i][e];this.undefStack.length>0&&(this.undefStack[this.undefStack.length-1][e]=r)}else{var s=this.undefStack[this.undefStack.length-1];s&&!s.hasOwnProperty(e)&&(s[e]=this.current[e])}r==null?delete this.current[e]:this.current[e]=r}}var p7=_d;v("\\noexpand",function(t){var e=t.popToken();return t.isExpandable(e.text)&&(e.noexpand=!0,e.treatAsRelax=!0),{tokens:[e],numArgs:0}});v("\\expandafter",function(t){var e=t.popToken();return t.expandOnce(!0),{tokens:[e],numArgs:0}});v("\\@firstoftwo",function(t){var e=t.consumeArgs(2);return{tokens:e[0],numArgs:0}});v("\\@secondoftwo",function(t){var e=t.consumeArgs(2);return{tokens:e[1],numArgs:0}});v("\\@ifnextchar",function(t){var e=t.consumeArgs(3);t.consumeSpaces();var r=t.future();return e[0].length===1&&e[0][0].text===r.text?{tokens:e[1],numArgs:0}:{tokens:e[2],numArgs:0}});v("\\@ifstar","\\@ifnextchar *{\\@firstoftwo{#1}}");v("\\TextOrMath",function(t){var e=t.consumeArgs(2);return t.mode==="text"?{tokens:e[0],numArgs:0}:{tokens:e[1],numArgs:0}});var Hc={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};v("\\char",function(t){var e=t.popToken(),r,n="";if(e.text==="'")r=8,e=t.popToken();else if(e.text==='"')r=16,e=t.popToken();else if(e.text==="`")if(e=t.popToken(),e.text[0]==="\\")n=e.text.charCodeAt(1);else{if(e.text==="EOF")throw new te("\\char` missing argument");n=e.text.charCodeAt(0)}else r=10;if(r){if(n=Hc[e.text],n==null||n>=r)throw new te("Invalid base-"+r+" digit "+e.text);for(var i;(i=Hc[t.future().text])!=null&&i<r;)n*=r,n+=i,t.popToken()}return"\\@char{"+n+"}"});var jo=(t,e,r,n)=>{var i=t.consumeArg().tokens;if(i.length!==1)throw new te("\\newcommand's first argument must be a macro name");var s=i[0].text,a=t.isDefined(s);if(a&&!e)throw new te("\\newcommand{"+s+"} attempting to redefine "+(s+"; use \\renewcommand"));if(!a&&!r)throw new te("\\renewcommand{"+s+"} when command "+s+" does not yet exist; use \\newcommand");var o=0;if(i=t.consumeArg().tokens,i.length===1&&i[0].text==="["){for(var l="",c=t.expandNextToken();c.text!=="]"&&c.text!=="EOF";)l+=c.text,c=t.expandNextToken();if(!l.match(/^\s*[0-9]+\s*$/))throw new te("Invalid number of arguments: "+l);o=parseInt(l),i=t.consumeArg().tokens}return a&&n||t.macros.set(s,{tokens:i,numArgs:o}),""};v("\\newcommand",t=>jo(t,!1,!0,!1));v("\\renewcommand",t=>jo(t,!0,!1,!1));v("\\providecommand",t=>jo(t,!0,!0,!0));v("\\message",t=>{var e=t.consumeArgs(1)[0];return console.log(e.reverse().map(r=>r.text).join("")),""});v("\\errmessage",t=>{var e=t.consumeArgs(1)[0];return console.error(e.reverse().map(r=>r.text).join("")),""});v("\\show",t=>{var e=t.popToken(),r=e.text;return console.log(e,t.macros.get(r),Qr[r],tt.math[r],tt.text[r]),""});v("\\bgroup","{");v("\\egroup","}");v("~","\\nobreakspace");v("\\lq","`");v("\\rq","'");v("\\aa","\\r a");v("\\AA","\\r A");v("\\textcopyright","\\html@mathml{\\textcircled{c}}{\\char`©}");v("\\copyright","\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}");v("\\textregistered","\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`®}");v("ℬ","\\mathscr{B}");v("ℰ","\\mathscr{E}");v("ℱ","\\mathscr{F}");v("ℋ","\\mathscr{H}");v("ℐ","\\mathscr{I}");v("ℒ","\\mathscr{L}");v("ℳ","\\mathscr{M}");v("ℛ","\\mathscr{R}");v("ℭ","\\mathfrak{C}");v("ℌ","\\mathfrak{H}");v("ℨ","\\mathfrak{Z}");v("\\Bbbk","\\Bbb{k}");v("·","\\cdotp");v("\\llap","\\mathllap{\\textrm{#1}}");v("\\rlap","\\mathrlap{\\textrm{#1}}");v("\\clap","\\mathclap{\\textrm{#1}}");v("\\mathstrut","\\vphantom{(}");v("\\underbar","\\underline{\\text{#1}}");v("\\not",'\\html@mathml{\\mathrel{\\mathrlap\\@not}}{\\char"338}');v("\\neq","\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`≠}}");v("\\ne","\\neq");v("≠","\\neq");v("\\notin","\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`∉}}");v("∉","\\notin");v("≘","\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`≘}}");v("≙","\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`≘}}");v("≚","\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`≚}}");v("≛","\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`≛}}");v("≝","\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`≝}}");v("≞","\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`≞}}");v("≟","\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`≟}}");v("⟂","\\perp");v("‼","\\mathclose{!\\mkern-0.8mu!}");v("∌","\\notni");v("⌜","\\ulcorner");v("⌝","\\urcorner");v("⌞","\\llcorner");v("⌟","\\lrcorner");v("©","\\copyright");v("®","\\textregistered");v("️","\\textregistered");v("\\ulcorner",'\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}');v("\\urcorner",'\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}');v("\\llcorner",'\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}');v("\\lrcorner",'\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}');v("\\vdots","{\\varvdots\\rule{0pt}{15pt}}");v("⋮","\\vdots");v("\\varGamma","\\mathit{\\Gamma}");v("\\varDelta","\\mathit{\\Delta}");v("\\varTheta","\\mathit{\\Theta}");v("\\varLambda","\\mathit{\\Lambda}");v("\\varXi","\\mathit{\\Xi}");v("\\varPi","\\mathit{\\Pi}");v("\\varSigma","\\mathit{\\Sigma}");v("\\varUpsilon","\\mathit{\\Upsilon}");v("\\varPhi","\\mathit{\\Phi}");v("\\varPsi","\\mathit{\\Psi}");v("\\varOmega","\\mathit{\\Omega}");v("\\substack","\\begin{subarray}{c}#1\\end{subarray}");v("\\colon","\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax");v("\\boxed","\\fbox{$\\displaystyle{#1}$}");v("\\iff","\\DOTSB\\;\\Longleftrightarrow\\;");v("\\implies","\\DOTSB\\;\\Longrightarrow\\;");v("\\impliedby","\\DOTSB\\;\\Longleftarrow\\;");v("\\dddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ...}}{#1}}");v("\\ddddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ....}}{#1}}");var qc={",":"\\dotsc","\\not":"\\dotsb","+":"\\dotsb","=":"\\dotsb","<":"\\dotsb",">":"\\dotsb","-":"\\dotsb","*":"\\dotsb",":":"\\dotsb","\\DOTSB":"\\dotsb","\\coprod":"\\dotsb","\\bigvee":"\\dotsb","\\bigwedge":"\\dotsb","\\biguplus":"\\dotsb","\\bigcap":"\\dotsb","\\bigcup":"\\dotsb","\\prod":"\\dotsb","\\sum":"\\dotsb","\\bigotimes":"\\dotsb","\\bigoplus":"\\dotsb","\\bigodot":"\\dotsb","\\bigsqcup":"\\dotsb","\\And":"\\dotsb","\\longrightarrow":"\\dotsb","\\Longrightarrow":"\\dotsb","\\longleftarrow":"\\dotsb","\\Longleftarrow":"\\dotsb","\\longleftrightarrow":"\\dotsb","\\Longleftrightarrow":"\\dotsb","\\mapsto":"\\dotsb","\\longmapsto":"\\dotsb","\\hookrightarrow":"\\dotsb","\\doteq":"\\dotsb","\\mathbin":"\\dotsb","\\mathrel":"\\dotsb","\\relbar":"\\dotsb","\\Relbar":"\\dotsb","\\xrightarrow":"\\dotsb","\\xleftarrow":"\\dotsb","\\DOTSI":"\\dotsi","\\int":"\\dotsi","\\oint":"\\dotsi","\\iint":"\\dotsi","\\iiint":"\\dotsi","\\iiiint":"\\dotsi","\\idotsint":"\\dotsi","\\DOTSX":"\\dotsx"};v("\\dots",function(t){var e="\\dotso",r=t.expandAfterFuture().text;return r in qc?e=qc[r]:(r.slice(0,4)==="\\not"||r in tt.math&&ve.contains(["bin","rel"],tt.math[r].group))&&(e="\\dotsb"),e});var Uo={")":!0,"]":!0,"\\rbrack":!0,"\\}":!0,"\\rbrace":!0,"\\rangle":!0,"\\rceil":!0,"\\rfloor":!0,"\\rgroup":!0,"\\rmoustache":!0,"\\right":!0,"\\bigr":!0,"\\biggr":!0,"\\Bigr":!0,"\\Biggr":!0,$:!0,";":!0,".":!0,",":!0};v("\\dotso",function(t){var e=t.future().text;return e in Uo?"\\ldots\\,":"\\ldots"});v("\\dotsc",function(t){var e=t.future().text;return e in Uo&&e!==","?"\\ldots\\,":"\\ldots"});v("\\cdots",function(t){var e=t.future().text;return e in Uo?"\\@cdots\\,":"\\@cdots"});v("\\dotsb","\\cdots");v("\\dotsm","\\cdots");v("\\dotsi","\\!\\cdots");v("\\dotsx","\\ldots\\,");v("\\DOTSI","\\relax");v("\\DOTSB","\\relax");v("\\DOTSX","\\relax");v("\\tmspace","\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax");v("\\,","\\tmspace+{3mu}{.1667em}");v("\\thinspace","\\,");v("\\>","\\mskip{4mu}");v("\\:","\\tmspace+{4mu}{.2222em}");v("\\medspace","\\:");v("\\;","\\tmspace+{5mu}{.2777em}");v("\\thickspace","\\;");v("\\!","\\tmspace-{3mu}{.1667em}");v("\\negthinspace","\\!");v("\\negmedspace","\\tmspace-{4mu}{.2222em}");v("\\negthickspace","\\tmspace-{5mu}{.277em}");v("\\enspace","\\kern.5em ");v("\\enskip","\\hskip.5em\\relax");v("\\quad","\\hskip1em\\relax");v("\\qquad","\\hskip2em\\relax");v("\\tag","\\@ifstar\\tag@literal\\tag@paren");v("\\tag@paren","\\tag@literal{({#1})}");v("\\tag@literal",t=>{if(t.macros.get("\\df@tag"))throw new te("Multiple \\tag");return"\\gdef\\df@tag{\\text{#1}}"});v("\\bmod","\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}");v("\\pod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)");v("\\pmod","\\pod{{\\rm mod}\\mkern6mu#1}");v("\\mod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1");v("\\newline","\\\\\\relax");v("\\TeX","\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}");var Wd=se(kr["Main-Regular"]["T".charCodeAt(0)][1]-.7*kr["Main-Regular"]["A".charCodeAt(0)][1]);v("\\LaTeX","\\textrm{\\html@mathml{"+("L\\kern-.36em\\raisebox{"+Wd+"}{\\scriptstyle A}")+"\\kern-.15em\\TeX}{LaTeX}}");v("\\KaTeX","\\textrm{\\html@mathml{"+("K\\kern-.17em\\raisebox{"+Wd+"}{\\scriptstyle A}")+"\\kern-.15em\\TeX}{KaTeX}}");v("\\hspace","\\@ifstar\\@hspacer\\@hspace");v("\\@hspace","\\hskip #1\\relax");v("\\@hspacer","\\rule{0pt}{0pt}\\hskip #1\\relax");v("\\ordinarycolon",":");v("\\vcentcolon","\\mathrel{\\mathop\\ordinarycolon}");v("\\dblcolon",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}');v("\\coloneqq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}');v("\\Coloneqq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}');v("\\coloneq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}');v("\\Coloneq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}');v("\\eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}');v("\\Eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}');v("\\eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}');v("\\Eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}');v("\\colonapprox",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}');v("\\Colonapprox",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}');v("\\colonsim",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}');v("\\Colonsim",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}');v("∷","\\dblcolon");v("∹","\\eqcolon");v("≔","\\coloneqq");v("≕","\\eqqcolon");v("⩴","\\Coloneqq");v("\\ratio","\\vcentcolon");v("\\coloncolon","\\dblcolon");v("\\colonequals","\\coloneqq");v("\\coloncolonequals","\\Coloneqq");v("\\equalscolon","\\eqqcolon");v("\\equalscoloncolon","\\Eqqcolon");v("\\colonminus","\\coloneq");v("\\coloncolonminus","\\Coloneq");v("\\minuscolon","\\eqcolon");v("\\minuscoloncolon","\\Eqcolon");v("\\coloncolonapprox","\\Colonapprox");v("\\coloncolonsim","\\Colonsim");v("\\simcolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}");v("\\simcoloncolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}");v("\\approxcolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}");v("\\approxcoloncolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}");v("\\notni","\\html@mathml{\\not\\ni}{\\mathrel{\\char`∌}}");v("\\limsup","\\DOTSB\\operatorname*{lim\\,sup}");v("\\liminf","\\DOTSB\\operatorname*{lim\\,inf}");v("\\injlim","\\DOTSB\\operatorname*{inj\\,lim}");v("\\projlim","\\DOTSB\\operatorname*{proj\\,lim}");v("\\varlimsup","\\DOTSB\\operatorname*{\\overline{lim}}");v("\\varliminf","\\DOTSB\\operatorname*{\\underline{lim}}");v("\\varinjlim","\\DOTSB\\operatorname*{\\underrightarrow{lim}}");v("\\varprojlim","\\DOTSB\\operatorname*{\\underleftarrow{lim}}");v("\\gvertneqq","\\html@mathml{\\@gvertneqq}{≩}");v("\\lvertneqq","\\html@mathml{\\@lvertneqq}{≨}");v("\\ngeqq","\\html@mathml{\\@ngeqq}{≱}");v("\\ngeqslant","\\html@mathml{\\@ngeqslant}{≱}");v("\\nleqq","\\html@mathml{\\@nleqq}{≰}");v("\\nleqslant","\\html@mathml{\\@nleqslant}{≰}");v("\\nshortmid","\\html@mathml{\\@nshortmid}{∤}");v("\\nshortparallel","\\html@mathml{\\@nshortparallel}{∦}");v("\\nsubseteqq","\\html@mathml{\\@nsubseteqq}{⊈}");v("\\nsupseteqq","\\html@mathml{\\@nsupseteqq}{⊉}");v("\\varsubsetneq","\\html@mathml{\\@varsubsetneq}{⊊}");v("\\varsubsetneqq","\\html@mathml{\\@varsubsetneqq}{⫋}");v("\\varsupsetneq","\\html@mathml{\\@varsupsetneq}{⊋}");v("\\varsupsetneqq","\\html@mathml{\\@varsupsetneqq}{⫌}");v("\\imath","\\html@mathml{\\@imath}{ı}");v("\\jmath","\\html@mathml{\\@jmath}{ȷ}");v("\\llbracket","\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`⟦}}");v("\\rrbracket","\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`⟧}}");v("⟦","\\llbracket");v("⟧","\\rrbracket");v("\\lBrace","\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`⦃}}");v("\\rBrace","\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`⦄}}");v("⦃","\\lBrace");v("⦄","\\rBrace");v("\\minuso","\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`⦵}}");v("⦵","\\minuso");v("\\darr","\\downarrow");v("\\dArr","\\Downarrow");v("\\Darr","\\Downarrow");v("\\lang","\\langle");v("\\rang","\\rangle");v("\\uarr","\\uparrow");v("\\uArr","\\Uparrow");v("\\Uarr","\\Uparrow");v("\\N","\\mathbb{N}");v("\\R","\\mathbb{R}");v("\\Z","\\mathbb{Z}");v("\\alef","\\aleph");v("\\alefsym","\\aleph");v("\\Alpha","\\mathrm{A}");v("\\Beta","\\mathrm{B}");v("\\bull","\\bullet");v("\\Chi","\\mathrm{X}");v("\\clubs","\\clubsuit");v("\\cnums","\\mathbb{C}");v("\\Complex","\\mathbb{C}");v("\\Dagger","\\ddagger");v("\\diamonds","\\diamondsuit");v("\\empty","\\emptyset");v("\\Epsilon","\\mathrm{E}");v("\\Eta","\\mathrm{H}");v("\\exist","\\exists");v("\\harr","\\leftrightarrow");v("\\hArr","\\Leftrightarrow");v("\\Harr","\\Leftrightarrow");v("\\hearts","\\heartsuit");v("\\image","\\Im");v("\\infin","\\infty");v("\\Iota","\\mathrm{I}");v("\\isin","\\in");v("\\Kappa","\\mathrm{K}");v("\\larr","\\leftarrow");v("\\lArr","\\Leftarrow");v("\\Larr","\\Leftarrow");v("\\lrarr","\\leftrightarrow");v("\\lrArr","\\Leftrightarrow");v("\\Lrarr","\\Leftrightarrow");v("\\Mu","\\mathrm{M}");v("\\natnums","\\mathbb{N}");v("\\Nu","\\mathrm{N}");v("\\Omicron","\\mathrm{O}");v("\\plusmn","\\pm");v("\\rarr","\\rightarrow");v("\\rArr","\\Rightarrow");v("\\Rarr","\\Rightarrow");v("\\real","\\Re");v("\\reals","\\mathbb{R}");v("\\Reals","\\mathbb{R}");v("\\Rho","\\mathrm{P}");v("\\sdot","\\cdot");v("\\sect","\\S");v("\\spades","\\spadesuit");v("\\sub","\\subset");v("\\sube","\\subseteq");v("\\supe","\\supseteq");v("\\Tau","\\mathrm{T}");v("\\thetasym","\\vartheta");v("\\weierp","\\wp");v("\\Zeta","\\mathrm{Z}");v("\\argmin","\\DOTSB\\operatorname*{arg\\,min}");v("\\argmax","\\DOTSB\\operatorname*{arg\\,max}");v("\\plim","\\DOTSB\\mathop{\\operatorname{plim}}\\limits");v("\\bra","\\mathinner{\\langle{#1}|}");v("\\ket","\\mathinner{|{#1}\\rangle}");v("\\braket","\\mathinner{\\langle{#1}\\rangle}");v("\\Bra","\\left\\langle#1\\right|");v("\\Ket","\\left|#1\\right\\rangle");var Gd=t=>e=>{var r=e.consumeArg().tokens,n=e.consumeArg().tokens,i=e.consumeArg().tokens,s=e.consumeArg().tokens,a=e.macros.get("|"),o=e.macros.get("\\|");e.macros.beginGroup();var l=f=>p=>{t&&(p.macros.set("|",a),i.length&&p.macros.set("\\|",o));var g=f;if(!f&&i.length){var b=p.future();b.text==="|"&&(p.popToken(),g=!0)}return{tokens:g?i:n,numArgs:0}};e.macros.set("|",l(!1)),i.length&&e.macros.set("\\|",l(!0));var c=e.consumeArg().tokens,u=e.expandTokens([...s,...c,...r]);return e.macros.endGroup(),{tokens:u.reverse(),numArgs:0}};v("\\bra@ket",Gd(!1));v("\\bra@set",Gd(!0));v("\\Braket","\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}");v("\\Set","\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}");v("\\set","\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}");v("\\angln","{\\angl n}");v("\\blue","\\textcolor{##6495ed}{#1}");v("\\orange","\\textcolor{##ffa500}{#1}");v("\\pink","\\textcolor{##ff00af}{#1}");v("\\red","\\textcolor{##df0030}{#1}");v("\\green","\\textcolor{##28ae7b}{#1}");v("\\gray","\\textcolor{gray}{#1}");v("\\purple","\\textcolor{##9d38bd}{#1}");v("\\blueA","\\textcolor{##ccfaff}{#1}");v("\\blueB","\\textcolor{##80f6ff}{#1}");v("\\blueC","\\textcolor{##63d9ea}{#1}");v("\\blueD","\\textcolor{##11accd}{#1}");v("\\blueE","\\textcolor{##0c7f99}{#1}");v("\\tealA","\\textcolor{##94fff5}{#1}");v("\\tealB","\\textcolor{##26edd5}{#1}");v("\\tealC","\\textcolor{##01d1c1}{#1}");v("\\tealD","\\textcolor{##01a995}{#1}");v("\\tealE","\\textcolor{##208170}{#1}");v("\\greenA","\\textcolor{##b6ffb0}{#1}");v("\\greenB","\\textcolor{##8af281}{#1}");v("\\greenC","\\textcolor{##74cf70}{#1}");v("\\greenD","\\textcolor{##1fab54}{#1}");v("\\greenE","\\textcolor{##0d923f}{#1}");v("\\goldA","\\textcolor{##ffd0a9}{#1}");v("\\goldB","\\textcolor{##ffbb71}{#1}");v("\\goldC","\\textcolor{##ff9c39}{#1}");v("\\goldD","\\textcolor{##e07d10}{#1}");v("\\goldE","\\textcolor{##a75a05}{#1}");v("\\redA","\\textcolor{##fca9a9}{#1}");v("\\redB","\\textcolor{##ff8482}{#1}");v("\\redC","\\textcolor{##f9685d}{#1}");v("\\redD","\\textcolor{##e84d39}{#1}");v("\\redE","\\textcolor{##bc2612}{#1}");v("\\maroonA","\\textcolor{##ffbde0}{#1}");v("\\maroonB","\\textcolor{##ff92c6}{#1}");v("\\maroonC","\\textcolor{##ed5fa6}{#1}");v("\\maroonD","\\textcolor{##ca337c}{#1}");v("\\maroonE","\\textcolor{##9e034e}{#1}");v("\\purpleA","\\textcolor{##ddd7ff}{#1}");v("\\purpleB","\\textcolor{##c6b9fc}{#1}");v("\\purpleC","\\textcolor{##aa87ff}{#1}");v("\\purpleD","\\textcolor{##7854ab}{#1}");v("\\purpleE","\\textcolor{##543b78}{#1}");v("\\mintA","\\textcolor{##f5f9e8}{#1}");v("\\mintB","\\textcolor{##edf2df}{#1}");v("\\mintC","\\textcolor{##e0e5cc}{#1}");v("\\grayA","\\textcolor{##f6f7f7}{#1}");v("\\grayB","\\textcolor{##f0f1f2}{#1}");v("\\grayC","\\textcolor{##e3e5e6}{#1}");v("\\grayD","\\textcolor{##d6d8da}{#1}");v("\\grayE","\\textcolor{##babec2}{#1}");v("\\grayF","\\textcolor{##888d93}{#1}");v("\\grayG","\\textcolor{##626569}{#1}");v("\\grayH","\\textcolor{##3b3e40}{#1}");v("\\grayI","\\textcolor{##21242c}{#1}");v("\\kaBlue","\\textcolor{##314453}{#1}");v("\\kaGreen","\\textcolor{##71B307}{#1}");var Kd={"^":!0,_:!0,"\\limits":!0,"\\nolimits":!0};class m7{constructor(e,r,n){this.settings=void 0,this.expansionCount=void 0,this.lexer=void 0,this.macros=void 0,this.stack=void 0,this.mode=void 0,this.settings=r,this.expansionCount=0,this.feed(e),this.macros=new f7(p7,r.macros),this.mode=n,this.stack=[]}feed(e){this.lexer=new Pc(e,this.settings)}switchMode(e){this.mode=e}beginGroup(){this.macros.beginGroup()}endGroup(){this.macros.endGroup()}endGroups(){this.macros.endGroups()}future(){return this.stack.length===0&&this.pushToken(this.lexer.lex()),this.stack[this.stack.length-1]}popToken(){return this.future(),this.stack.pop()}pushToken(e){this.stack.push(e)}pushTokens(e){this.stack.push(...e)}scanArgument(e){var r,n,i;if(e){if(this.consumeSpaces(),this.future().text!=="[")return null;r=this.popToken(),{tokens:i,end:n}=this.consumeArg(["]"])}else({tokens:i,start:r,end:n}=this.consumeArg());return this.pushToken(new nr("EOF",n.loc)),this.pushTokens(i),r.range(n,"")}consumeSpaces(){for(;;){var e=this.future();if(e.text===" ")this.stack.pop();else break}}consumeArg(e){var r=[],n=e&&e.length>0;n||this.consumeSpaces();var i=this.future(),s,a=0,o=0;do{if(s=this.popToken(),r.push(s),s.text==="{")++a;else if(s.text==="}"){if(--a,a===-1)throw new te("Extra }",s)}else if(s.text==="EOF")throw new te("Unexpected end of input in a macro argument, expected '"+(e&&n?e[o]:"}")+"'",s);if(e&&n)if((a===0||a===1&&e[o]==="{")&&s.text===e[o]){if(++o,o===e.length){r.splice(-o,o);break}}else o=0}while(a!==0||n);return i.text==="{"&&r[r.length-1].text==="}"&&(r.pop(),r.shift()),r.reverse(),{tokens:r,start:i,end:s}}consumeArgs(e,r){if(r){if(r.length!==e+1)throw new te("The length of delimiters doesn't match the number of args!");for(var n=r[0],i=0;i<n.length;i++){var s=this.popToken();if(n[i]!==s.text)throw new te("Use of the macro doesn't match its definition",s)}}for(var a=[],o=0;o<e;o++)a.push(this.consumeArg(r&&r[o+1]).tokens);return a}countExpansion(e){if(this.expansionCount+=e,this.expansionCount>this.settings.maxExpand)throw new te("Too many expansions: infinite loop or need to increase maxExpand setting")}expandOnce(e){var r=this.popToken(),n=r.text,i=r.noexpand?null:this._getExpansion(n);if(i==null||e&&i.unexpandable){if(e&&i==null&&n[0]==="\\"&&!this.isDefined(n))throw new te("Undefined control sequence: "+n);return this.pushToken(r),!1}this.countExpansion(1);var s=i.tokens,a=this.consumeArgs(i.numArgs,i.delimiters);if(i.numArgs){s=s.slice();for(var o=s.length-1;o>=0;--o){var l=s[o];if(l.text==="#"){if(o===0)throw new te("Incomplete placeholder at end of macro body",l);if(l=s[--o],l.text==="#")s.splice(o+1,1);else if(/^[1-9]$/.test(l.text))s.splice(o,2,...a[+l.text-1]);else throw new te("Not a valid argument number",l)}}}return this.pushTokens(s),s.length}expandAfterFuture(){return this.expandOnce(),this.future()}expandNextToken(){for(;;)if(this.expandOnce()===!1){var e=this.stack.pop();return e.treatAsRelax&&(e.text="\\relax"),e}throw new Error}expandMacro(e){return this.macros.has(e)?this.expandTokens([new nr(e)]):void 0}expandTokens(e){var r=[],n=this.stack.length;for(this.pushTokens(e);this.stack.length>n;)if(this.expandOnce(!0)===!1){var i=this.stack.pop();i.treatAsRelax&&(i.noexpand=!1,i.treatAsRelax=!1),r.push(i)}return this.countExpansion(r.length),r}expandMacroAsText(e){var r=this.expandMacro(e);return r&&r.map(n=>n.text).join("")}_getExpansion(e){var r=this.macros.get(e);if(r==null)return r;if(e.length===1){var n=this.lexer.catcodes[e];if(n!=null&&n!==13)return}var i=typeof r=="function"?r(this):r;if(typeof i=="string"){var s=0;if(i.indexOf("#")!==-1)for(var a=i.replace(/##/g,"");a.indexOf("#"+(s+1))!==-1;)++s;for(var o=new Pc(i,this.settings),l=[],c=o.lex();c.text!=="EOF";)l.push(c),c=o.lex();l.reverse();var u={tokens:l,numArgs:s};return u}return i}isDefined(e){return this.macros.has(e)||Qr.hasOwnProperty(e)||tt.math.hasOwnProperty(e)||tt.text.hasOwnProperty(e)||Kd.hasOwnProperty(e)}isExpandable(e){var r=this.macros.get(e);return r!=null?typeof r=="string"||typeof r=="function"||!r.unexpandable:Qr.hasOwnProperty(e)&&!Qr[e].primitive}}var jc=/^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/,oi=Object.freeze({"₊":"+","₋":"-","₌":"=","₍":"(","₎":")","₀":"0","₁":"1","₂":"2","₃":"3","₄":"4","₅":"5","₆":"6","₇":"7","₈":"8","₉":"9","ₐ":"a","ₑ":"e","ₕ":"h","ᵢ":"i","ⱼ":"j","ₖ":"k","ₗ":"l","ₘ":"m","ₙ":"n","ₒ":"o","ₚ":"p","ᵣ":"r","ₛ":"s","ₜ":"t","ᵤ":"u","ᵥ":"v","ₓ":"x","ᵦ":"β","ᵧ":"γ","ᵨ":"ρ","ᵩ":"ϕ","ᵪ":"χ","⁺":"+","⁻":"-","⁼":"=","⁽":"(","⁾":")","⁰":"0","¹":"1","²":"2","³":"3","⁴":"4","⁵":"5","⁶":"6","⁷":"7","⁸":"8","⁹":"9","ᴬ":"A","ᴮ":"B","ᴰ":"D","ᴱ":"E","ᴳ":"G","ᴴ":"H","ᴵ":"I","ᴶ":"J","ᴷ":"K","ᴸ":"L","ᴹ":"M","ᴺ":"N","ᴼ":"O","ᴾ":"P","ᴿ":"R","ᵀ":"T","ᵁ":"U","ⱽ":"V","ᵂ":"W","ᵃ":"a","ᵇ":"b","ᶜ":"c","ᵈ":"d","ᵉ":"e","ᶠ":"f","ᵍ":"g",ʰ:"h","ⁱ":"i",ʲ:"j","ᵏ":"k",ˡ:"l","ᵐ":"m",ⁿ:"n","ᵒ":"o","ᵖ":"p",ʳ:"r",ˢ:"s","ᵗ":"t","ᵘ":"u","ᵛ":"v",ʷ:"w",ˣ:"x",ʸ:"y","ᶻ":"z","ᵝ":"β","ᵞ":"γ","ᵟ":"δ","ᵠ":"ϕ","ᵡ":"χ","ᶿ":"θ"}),Js={"́":{text:"\\'",math:"\\acute"},"̀":{text:"\\`",math:"\\grave"},"̈":{text:'\\"',math:"\\ddot"},"̃":{text:"\\~",math:"\\tilde"},"̄":{text:"\\=",math:"\\bar"},"̆":{text:"\\u",math:"\\breve"},"̌":{text:"\\v",math:"\\check"},"̂":{text:"\\^",math:"\\hat"},"̇":{text:"\\.",math:"\\dot"},"̊":{text:"\\r",math:"\\mathring"},"̋":{text:"\\H"},"̧":{text:"\\c"}},Uc={á:"á",à:"à",ä:"ä",ǟ:"ǟ",ã:"ã",ā:"ā",ă:"ă",ắ:"ắ",ằ:"ằ",ẵ:"ẵ",ǎ:"ǎ",â:"â",ấ:"ấ",ầ:"ầ",ẫ:"ẫ",ȧ:"ȧ",ǡ:"ǡ",å:"å",ǻ:"ǻ",ḃ:"ḃ",ć:"ć",ḉ:"ḉ",č:"č",ĉ:"ĉ",ċ:"ċ",ç:"ç",ď:"ď",ḋ:"ḋ",ḑ:"ḑ",é:"é",è:"è",ë:"ë",ẽ:"ẽ",ē:"ē",ḗ:"ḗ",ḕ:"ḕ",ĕ:"ĕ",ḝ:"ḝ",ě:"ě",ê:"ê",ế:"ế",ề:"ề",ễ:"ễ",ė:"ė",ȩ:"ȩ",ḟ:"ḟ",ǵ:"ǵ",ḡ:"ḡ",ğ:"ğ",ǧ:"ǧ",ĝ:"ĝ",ġ:"ġ",ģ:"ģ",ḧ:"ḧ",ȟ:"ȟ",ĥ:"ĥ",ḣ:"ḣ",ḩ:"ḩ",í:"í",ì:"ì",ï:"ï",ḯ:"ḯ",ĩ:"ĩ",ī:"ī",ĭ:"ĭ",ǐ:"ǐ",î:"î",ǰ:"ǰ",ĵ:"ĵ",ḱ:"ḱ",ǩ:"ǩ",ķ:"ķ",ĺ:"ĺ",ľ:"ľ",ļ:"ļ",ḿ:"ḿ",ṁ:"ṁ",ń:"ń",ǹ:"ǹ",ñ:"ñ",ň:"ň",ṅ:"ṅ",ņ:"ņ",ó:"ó",ò:"ò",ö:"ö",ȫ:"ȫ",õ:"õ",ṍ:"ṍ",ṏ:"ṏ",ȭ:"ȭ",ō:"ō",ṓ:"ṓ",ṑ:"ṑ",ŏ:"ŏ",ǒ:"ǒ",ô:"ô",ố:"ố",ồ:"ồ",ỗ:"ỗ",ȯ:"ȯ",ȱ:"ȱ",ő:"ő",ṕ:"ṕ",ṗ:"ṗ",ŕ:"ŕ",ř:"ř",ṙ:"ṙ",ŗ:"ŗ",ś:"ś",ṥ:"ṥ",š:"š",ṧ:"ṧ",ŝ:"ŝ",ṡ:"ṡ",ş:"ş",ẗ:"ẗ",ť:"ť",ṫ:"ṫ",ţ:"ţ",ú:"ú",ù:"ù",ü:"ü",ǘ:"ǘ",ǜ:"ǜ",ǖ:"ǖ",ǚ:"ǚ",ũ:"ũ",ṹ:"ṹ",ū:"ū",ṻ:"ṻ",ŭ:"ŭ",ǔ:"ǔ",û:"û",ů:"ů",ű:"ű",ṽ:"ṽ",ẃ:"ẃ",ẁ:"ẁ",ẅ:"ẅ",ŵ:"ŵ",ẇ:"ẇ",ẘ:"ẘ",ẍ:"ẍ",ẋ:"ẋ",ý:"ý",ỳ:"ỳ",ÿ:"ÿ",ỹ:"ỹ",ȳ:"ȳ",ŷ:"ŷ",ẏ:"ẏ",ẙ:"ẙ",ź:"ź",ž:"ž",ẑ:"ẑ",ż:"ż",Á:"Á",À:"À",Ä:"Ä",Ǟ:"Ǟ",Ã:"Ã",Ā:"Ā",Ă:"Ă",Ắ:"Ắ",Ằ:"Ằ",Ẵ:"Ẵ",Ǎ:"Ǎ",Â:"Â",Ấ:"Ấ",Ầ:"Ầ",Ẫ:"Ẫ",Ȧ:"Ȧ",Ǡ:"Ǡ",Å:"Å",Ǻ:"Ǻ",Ḃ:"Ḃ",Ć:"Ć",Ḉ:"Ḉ",Č:"Č",Ĉ:"Ĉ",Ċ:"Ċ",Ç:"Ç",Ď:"Ď",Ḋ:"Ḋ",Ḑ:"Ḑ",É:"É",È:"È",Ë:"Ë",Ẽ:"Ẽ",Ē:"Ē",Ḗ:"Ḗ",Ḕ:"Ḕ",Ĕ:"Ĕ",Ḝ:"Ḝ",Ě:"Ě",Ê:"Ê",Ế:"Ế",Ề:"Ề",Ễ:"Ễ",Ė:"Ė",Ȩ:"Ȩ",Ḟ:"Ḟ",Ǵ:"Ǵ",Ḡ:"Ḡ",Ğ:"Ğ",Ǧ:"Ǧ",Ĝ:"Ĝ",Ġ:"Ġ",Ģ:"Ģ",Ḧ:"Ḧ",Ȟ:"Ȟ",Ĥ:"Ĥ",Ḣ:"Ḣ",Ḩ:"Ḩ",Í:"Í",Ì:"Ì",Ï:"Ï",Ḯ:"Ḯ",Ĩ:"Ĩ",Ī:"Ī",Ĭ:"Ĭ",Ǐ:"Ǐ",Î:"Î",İ:"İ",Ĵ:"Ĵ",Ḱ:"Ḱ",Ǩ:"Ǩ",Ķ:"Ķ",Ĺ:"Ĺ",Ľ:"Ľ",Ļ:"Ļ",Ḿ:"Ḿ",Ṁ:"Ṁ",Ń:"Ń",Ǹ:"Ǹ",Ñ:"Ñ",Ň:"Ň",Ṅ:"Ṅ",Ņ:"Ņ",Ó:"Ó",Ò:"Ò",Ö:"Ö",Ȫ:"Ȫ",Õ:"Õ",Ṍ:"Ṍ",Ṏ:"Ṏ",Ȭ:"Ȭ",Ō:"Ō",Ṓ:"Ṓ",Ṑ:"Ṑ",Ŏ:"Ŏ",Ǒ:"Ǒ",Ô:"Ô",Ố:"Ố",Ồ:"Ồ",Ỗ:"Ỗ",Ȯ:"Ȯ",Ȱ:"Ȱ",Ő:"Ő",Ṕ:"Ṕ",Ṗ:"Ṗ",Ŕ:"Ŕ",Ř:"Ř",Ṙ:"Ṙ",Ŗ:"Ŗ",Ś:"Ś",Ṥ:"Ṥ",Š:"Š",Ṧ:"Ṧ",Ŝ:"Ŝ",Ṡ:"Ṡ",Ş:"Ş",Ť:"Ť",Ṫ:"Ṫ",Ţ:"Ţ",Ú:"Ú",Ù:"Ù",Ü:"Ü",Ǘ:"Ǘ",Ǜ:"Ǜ",Ǖ:"Ǖ",Ǚ:"Ǚ",Ũ:"Ũ",Ṹ:"Ṹ",Ū:"Ū",Ṻ:"Ṻ",Ŭ:"Ŭ",Ǔ:"Ǔ",Û:"Û",Ů:"Ů",Ű:"Ű",Ṽ:"Ṽ",Ẃ:"Ẃ",Ẁ:"Ẁ",Ẅ:"Ẅ",Ŵ:"Ŵ",Ẇ:"Ẇ",Ẍ:"Ẍ",Ẋ:"Ẋ",Ý:"Ý",Ỳ:"Ỳ",Ÿ:"Ÿ",Ỹ:"Ỹ",Ȳ:"Ȳ",Ŷ:"Ŷ",Ẏ:"Ẏ",Ź:"Ź",Ž:"Ž",Ẑ:"Ẑ",Ż:"Ż",ά:"ά",ὰ:"ὰ",ᾱ:"ᾱ",ᾰ:"ᾰ",έ:"έ",ὲ:"ὲ",ή:"ή",ὴ:"ὴ",ί:"ί",ὶ:"ὶ",ϊ:"ϊ",ΐ:"ΐ",ῒ:"ῒ",ῑ:"ῑ",ῐ:"ῐ",ό:"ό",ὸ:"ὸ",ύ:"ύ",ὺ:"ὺ",ϋ:"ϋ",ΰ:"ΰ",ῢ:"ῢ",ῡ:"ῡ",ῠ:"ῠ",ώ:"ώ",ὼ:"ὼ",Ύ:"Ύ",Ὺ:"Ὺ",Ϋ:"Ϋ",Ῡ:"Ῡ",Ῠ:"Ῠ",Ώ:"Ώ",Ὼ:"Ὼ"};class ys{constructor(e,r){this.mode=void 0,this.gullet=void 0,this.settings=void 0,this.leftrightDepth=void 0,this.nextToken=void 0,this.mode="math",this.gullet=new m7(e,r,this.mode),this.settings=r,this.leftrightDepth=0}expect(e,r){if(r===void 0&&(r=!0),this.fetch().text!==e)throw new te("Expected '"+e+"', got '"+this.fetch().text+"'",this.fetch());r&&this.consume()}consume(){this.nextToken=null}fetch(){return this.nextToken==null&&(this.nextToken=this.gullet.expandNextToken()),this.nextToken}switchMode(e){this.mode=e,this.gullet.switchMode(e)}parse(){this.settings.globalGroup||this.gullet.beginGroup(),this.settings.colorIsTextColor&&this.gullet.macros.set("\\color","\\textcolor");try{var e=this.parseExpression(!1);return this.expect("EOF"),this.settings.globalGroup||this.gullet.endGroup(),e}finally{this.gullet.endGroups()}}subparse(e){var r=this.nextToken;this.consume(),this.gullet.pushToken(new nr("}")),this.gullet.pushTokens(e);var n=this.parseExpression(!1);return this.expect("}"),this.nextToken=r,n}parseExpression(e,r){for(var n=[];;){this.mode==="math"&&this.consumeSpaces();var i=this.fetch();if(ys.endOfExpression.indexOf(i.text)!==-1||r&&i.text===r||e&&Qr[i.text]&&Qr[i.text].infix)break;var s=this.parseAtom(r);if(s){if(s.type==="internal")continue}else break;n.push(s)}return this.mode==="text"&&this.formLigatures(n),this.handleInfixNodes(n)}handleInfixNodes(e){for(var r=-1,n,i=0;i<e.length;i++)if(e[i].type==="infix"){if(r!==-1)throw new te("only one infix operator per group",e[i].token);r=i,n=e[i].replaceWith}if(r!==-1&&n){var s,a,o=e.slice(0,r),l=e.slice(r+1);o.length===1&&o[0].type==="ordgroup"?s=o[0]:s={type:"ordgroup",mode:this.mode,body:o},l.length===1&&l[0].type==="ordgroup"?a=l[0]:a={type:"ordgroup",mode:this.mode,body:l};var c;return n==="\\\\abovefrac"?c=this.callFunction(n,[s,e[r],a],[]):c=this.callFunction(n,[s,a],[]),[c]}else return e}handleSupSubscript(e){var r=this.fetch(),n=r.text;this.consume(),this.consumeSpaces();var i;do{var s;i=this.parseGroup(e)}while(((s=i)==null?void 0:s.type)==="internal");if(!i)throw new te("Expected group after '"+n+"'",r);return i}formatUnsupportedCmd(e){for(var r=[],n=0;n<e.length;n++)r.push({type:"textord",mode:"text",text:e[n]});var i={type:"text",mode:this.mode,body:r},s={type:"color",mode:this.mode,color:this.settings.errorColor,body:[i]};return s}parseAtom(e){var r=this.parseGroup("atom",e);if((r==null?void 0:r.type)==="internal"||this.mode==="text")return r;for(var n,i;;){this.consumeSpaces();var s=this.fetch();if(s.text==="\\limits"||s.text==="\\nolimits"){if(r&&r.type==="op"){var a=s.text==="\\limits";r.limits=a,r.alwaysHandleSupSub=!0}else if(r&&r.type==="operatorname")r.alwaysHandleSupSub&&(r.limits=s.text==="\\limits");else throw new te("Limit controls must follow a math operator",s);this.consume()}else if(s.text==="^"){if(n)throw new te("Double superscript",s);n=this.handleSupSubscript("superscript")}else if(s.text==="_"){if(i)throw new te("Double subscript",s);i=this.handleSupSubscript("subscript")}else if(s.text==="'"){if(n)throw new te("Double superscript",s);var o={type:"textord",mode:this.mode,text:"\\prime"},l=[o];for(this.consume();this.fetch().text==="'";)l.push(o),this.consume();this.fetch().text==="^"&&l.push(this.handleSupSubscript("superscript")),n={type:"ordgroup",mode:this.mode,body:l}}else if(oi[s.text]){var c=jc.test(s.text),u=[];for(u.push(new nr(oi[s.text])),this.consume();;){var f=this.fetch().text;if(!oi[f]||jc.test(f)!==c)break;u.unshift(new nr(oi[f])),this.consume()}var p=this.subparse(u);c?i={type:"ordgroup",mode:"math",body:p}:n={type:"ordgroup",mode:"math",body:p}}else break}return n||i?{type:"supsub",mode:this.mode,base:r,sup:n,sub:i}:r}parseFunction(e,r){var n=this.fetch(),i=n.text,s=Qr[i];if(!s)return null;if(this.consume(),r&&r!=="atom"&&!s.allowedInArgument)throw new te("Got function '"+i+"' with no arguments"+(r?" as "+r:""),n);if(this.mode==="text"&&!s.allowedInText)throw new te("Can't use function '"+i+"' in text mode",n);if(this.mode==="math"&&s.allowedInMath===!1)throw new te("Can't use function '"+i+"' in math mode",n);var{args:a,optArgs:o}=this.parseArguments(i,s);return this.callFunction(i,a,o,n,e)}callFunction(e,r,n,i,s){var a={funcName:e,parser:this,token:i,breakOnTokenText:s},o=Qr[e];if(o&&o.handler)return o.handler(a,r,n);throw new te("No function handler for "+e)}parseArguments(e,r){var n=r.numArgs+r.numOptionalArgs;if(n===0)return{args:[],optArgs:[]};for(var i=[],s=[],a=0;a<n;a++){var o=r.argTypes&&r.argTypes[a],l=a<r.numOptionalArgs;(r.primitive&&o==null||r.type==="sqrt"&&a===1&&s[0]==null)&&(o="primitive");var c=this.parseGroupOfType("argument to '"+e+"'",o,l);if(l)s.push(c);else if(c!=null)i.push(c);else throw new te("Null argument, please report this as a bug")}return{args:i,optArgs:s}}parseGroupOfType(e,r,n){switch(r){case"color":return this.parseColorGroup(n);case"size":return this.parseSizeGroup(n);case"url":return this.parseUrlGroup(n);case"math":case"text":return this.parseArgumentGroup(n,r);case"hbox":{var i=this.parseArgumentGroup(n,"text");return i!=null?{type:"styling",mode:i.mode,body:[i],style:"text"}:null}case"raw":{var s=this.parseStringGroup("raw",n);return s!=null?{type:"raw",mode:"text",string:s.text}:null}case"primitive":{if(n)throw new te("A primitive argument cannot be optional");var a=this.parseGroup(e);if(a==null)throw new te("Expected group as "+e,this.fetch());return a}case"original":case null:case void 0:return this.parseArgumentGroup(n);default:throw new te("Unknown group type as "+e,this.fetch())}}consumeSpaces(){for(;this.fetch().text===" ";)this.consume()}parseStringGroup(e,r){var n=this.gullet.scanArgument(r);if(n==null)return null;for(var i="",s;(s=this.fetch()).text!=="EOF";)i+=s.text,this.consume();return this.consume(),n.text=i,n}parseRegexGroup(e,r){for(var n=this.fetch(),i=n,s="",a;(a=this.fetch()).text!=="EOF"&&e.test(s+a.text);)i=a,s+=i.text,this.consume();if(s==="")throw new te("Invalid "+r+": '"+n.text+"'",n);return n.range(i,s)}parseColorGroup(e){var r=this.parseStringGroup("color",e);if(r==null)return null;var n=/^(#[a-f0-9]{3}|#?[a-f0-9]{6}|[a-z]+)$/i.exec(r.text);if(!n)throw new te("Invalid color: '"+r.text+"'",r);var i=n[0];return/^[0-9a-f]{6}$/i.test(i)&&(i="#"+i),{type:"color-token",mode:this.mode,color:i}}parseSizeGroup(e){var r,n=!1;if(this.gullet.consumeSpaces(),!e&&this.gullet.future().text!=="{"?r=this.parseRegexGroup(/^[-+]? *(?:$|\d+|\d+\.\d*|\.\d*) *[a-z]{0,2} *$/,"size"):r=this.parseStringGroup("size",e),!r)return null;!e&&r.text.length===0&&(r.text="0pt",n=!0);var i=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(r.text);if(!i)throw new te("Invalid size: '"+r.text+"'",r);var s={number:+(i[1]+i[2]),unit:i[3]};if(!id(s))throw new te("Invalid unit: '"+s.unit+"'",r);return{type:"size",mode:this.mode,value:s,isBlank:n}}parseUrlGroup(e){this.gullet.lexer.setCatcode("%",13),this.gullet.lexer.setCatcode("~",12);var r=this.parseStringGroup("url",e);if(this.gullet.lexer.setCatcode("%",14),this.gullet.lexer.setCatcode("~",13),r==null)return null;var n=r.text.replace(/\\([#$%&~_^{}])/g,"$1");return{type:"url",mode:this.mode,url:n}}parseArgumentGroup(e,r){var n=this.gullet.scanArgument(e);if(n==null)return null;var i=this.mode;r&&this.switchMode(r),this.gullet.beginGroup();var s=this.parseExpression(!1,"EOF");this.expect("EOF"),this.gullet.endGroup();var a={type:"ordgroup",mode:this.mode,loc:n.loc,body:s};return r&&this.switchMode(i),a}parseGroup(e,r){var n=this.fetch(),i=n.text,s;if(i==="{"||i==="\\begingroup"){this.consume();var a=i==="{"?"}":"\\endgroup";this.gullet.beginGroup();var o=this.parseExpression(!1,a),l=this.fetch();this.expect(a),this.gullet.endGroup(),s={type:"ordgroup",mode:this.mode,loc:Wt.range(n,l),body:o,semisimple:i==="\\begingroup"||void 0}}else if(s=this.parseFunction(r,e)||this.parseSymbol(),s==null&&i[0]==="\\"&&!Kd.hasOwnProperty(i)){if(this.settings.throwOnError)throw new te("Undefined control sequence: "+i,n);s=this.formatUnsupportedCmd(i),this.consume()}return s}formLigatures(e){for(var r=e.length-1,n=0;n<r;++n){var i=e[n],s=i.text;s==="-"&&e[n+1].text==="-"&&(n+1<r&&e[n+2].text==="-"?(e.splice(n,3,{type:"textord",mode:"text",loc:Wt.range(i,e[n+2]),text:"---"}),r-=2):(e.splice(n,2,{type:"textord",mode:"text",loc:Wt.range(i,e[n+1]),text:"--"}),r-=1)),(s==="'"||s==="`")&&e[n+1].text===s&&(e.splice(n,2,{type:"textord",mode:"text",loc:Wt.range(i,e[n+1]),text:s+s}),r-=1)}}parseSymbol(){var e=this.fetch(),r=e.text;if(/^\\verb[^a-zA-Z]/.test(r)){this.consume();var n=r.slice(5),i=n.charAt(0)==="*";if(i&&(n=n.slice(1)),n.length<2||n.charAt(0)!==n.slice(-1))throw new te(`\\verb assertion failed --
|
||
please report what input caused this bug`);return n=n.slice(1,-1),{type:"verb",mode:"text",body:n,star:i}}Uc.hasOwnProperty(r[0])&&!tt[this.mode][r[0]]&&(this.settings.strict&&this.mode==="math"&&this.settings.reportNonstrict("unicodeTextInMathMode",'Accented Unicode text character "'+r[0]+'" used in math mode',e),r=Uc[r[0]]+r.slice(1));var s=d7.exec(r);s&&(r=r.substring(0,s.index),r==="i"?r="ı":r==="j"&&(r="ȷ"));var a;if(tt[this.mode][r]){this.settings.strict&&this.mode==="math"&&Ma.indexOf(r)>=0&&this.settings.reportNonstrict("unicodeTextInMathMode",'Latin-1/Unicode text character "'+r[0]+'" used in math mode',e);var o=tt[this.mode][r].group,l=Wt.range(e),c;if(n5.hasOwnProperty(o)){var u=o;c={type:"atom",mode:this.mode,family:u,loc:l,text:r}}else c={type:o,mode:this.mode,loc:l,text:r};a=c}else if(r.charCodeAt(0)>=128)this.settings.strict&&(nd(r.charCodeAt(0))?this.mode==="math"&&this.settings.reportNonstrict("unicodeTextInMathMode",'Unicode text character "'+r[0]+'" used in math mode',e):this.settings.reportNonstrict("unknownSymbol",'Unrecognized Unicode character "'+r[0]+'"'+(" ("+r.charCodeAt(0)+")"),e)),a={type:"textord",mode:"text",loc:Wt.range(e),text:r};else return null;if(this.consume(),s)for(var f=0;f<s[0].length;f++){var p=s[0][f];if(!Js[p])throw new te("Unknown accent ' "+p+"'",e);var g=Js[p][this.mode]||Js[p].text;if(!g)throw new te("Accent "+p+" unsupported in "+this.mode+" mode",e);a={type:"accent",mode:this.mode,loc:Wt.range(e),label:g,isStretchy:!1,isShifty:!0,base:a}}return a}}ys.endOfExpression=["}","\\endgroup","\\end","\\right","&"];var Vo=function(e,r){if(!(typeof e=="string"||e instanceof String))throw new TypeError("KaTeX can only parse string typed expression");var n=new ys(e,r);delete n.gullet.macros.current["\\df@tag"];var i=n.parse();if(delete n.gullet.macros.current["\\current@color"],delete n.gullet.macros.current["\\color"],n.gullet.macros.get("\\df@tag")){if(!r.displayMode)throw new te("\\tag works only in display equations");i=[{type:"tag",mode:"text",body:i,tag:n.subparse([new nr("\\df@tag")])}]}return i},Yd=function(e,r,n){r.textContent="";var i=Wo(e,n).toNode();r.appendChild(i)};typeof document<"u"&&document.compatMode!=="CSS1Compat"&&(typeof console<"u"&&console.warn("Warning: KaTeX doesn't work in quirks mode. Make sure your website has a suitable doctype."),Yd=function(){throw new te("KaTeX doesn't work in quirks mode.")});var g7=function(e,r){var n=Wo(e,r).toMarkup();return n},v7=function(e,r){var n=new Co(r);return Vo(e,n)},Xd=function(e,r,n){if(n.throwOnError||!(e instanceof te))throw e;var i=F.makeSpan(["katex-error"],[new sr(r)]);return i.setAttribute("title",e.toString()),i.setAttribute("style","color:"+n.errorColor),i},Wo=function(e,r){var n=new Co(r);try{var i=Vo(e,n);return E5(i,e,n)}catch(s){return Xd(s,e,n)}},b7=function(e,r){var n=new Co(r);try{var i=Vo(e,n);return C5(i,e,n)}catch(s){return Xd(s,e,n)}},y7="0.16.22",w7={Span:z0,Anchor:Io,SymbolNode:sr,SvgNode:Hr,PathNode:an,LineNode:Ca},Vc={version:y7,render:Yd,renderToString:g7,ParseError:te,SETTINGS_SCHEMA:yi,__parse:v7,__renderToDomTree:Wo,__renderToHTMLTree:b7,__setFontMetrics:Y6,__defineSymbol:d,__defineFunction:ce,__defineMacro:v,__domTree:w7};Prism.languages.javascript=Prism.languages.extend("clike",{"class-name":[Prism.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/});Prism.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/;Prism.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:Prism.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:Prism.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:Prism.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/});Prism.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:Prism.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}});Prism.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}});Prism.languages.markup&&(Prism.languages.markup.tag.addInlined("script","javascript"),Prism.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript"));Prism.languages.js=Prism.languages.javascript;(function(t){var e=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;t.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+e.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+e.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+e.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+e.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:e,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},t.languages.css.atrule.inside.rest=t.languages.css;var r=t.languages.markup;r&&(r.tag.addInlined("style","css"),r.tag.addAttribute("style","css"))})(Prism);Prism.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}};Prism.languages.webmanifest=Prism.languages.json;Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern://,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/};Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python;Prism.languages.py=Prism.languages.python;Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/};const x7=new qe.Renderer;qe.setOptions({breaks:!1,gfm:!0,tables:!0,sanitize:!1,renderer:x7});const E0=t=>{if(!t||typeof t!="string")return"";try{const e=k7(t),r=qe.parse(e);return S7(r)}catch(e){return console.error("Markdown渲染失败:",e),`<div class="markdown-error">渲染失败: ${e.message}</div>`}},k7=t=>t.replace(/\$\$([\s\S]*?)\$\$/g,(e,r)=>{try{return`<div class="math-block">${Vc.renderToString(r.trim(),{displayMode:!0,throwOnError:!1})}</div>`}catch(n){return console.warn("数学公式渲染失败:",n),`<div class="math-error">数学公式错误: ${r}</div>`}}).replace(/\$([^$\n]+?)\$/g,(e,r)=>{if(r.includes("\\")||r.includes("{")||r.includes("}")||r.includes("^")||r.includes("_")||r.includes("=")||r.includes("+")||r.includes("-")||r.includes("*")||r.includes("/")||r.includes("(")||r.includes(")"))try{return`<span class="math-inline">${Vc.renderToString(r.trim(),{displayMode:!1,throwOnError:!1})}</span>`}catch(n){return console.warn("数学公式渲染失败:",n),`<span class="math-error">数学公式错误: ${r}</span>`}return e}),S7=t=>{let e=t.replace(/<table>/g,'<table class="markdown-table">').replace(/<pre><code/g,'<pre class="markdown-code"><code');const r=document.createElement("div");return r.innerHTML=e,r.querySelectorAll("pre code").forEach(i=>{const s=i.className.match(/language-(\w+)/);if(s)try{i.innerHTML=uc.highlight(i.textContent,uc.languages[s[1]],s[1])}catch(a){console.warn("语法高亮失败:",a)}}),r.innerHTML},T7=t=>{if(!t||typeof t!="string")return!1;const e=t.split(`
|
||
`);let r=!1,n=!1;for(const a of e){const o=a.trim();o.includes("|")&&o.split("|").length>=3&&(r=!0),o.includes("|")&&o.includes("-")&&/^[\s\|\-\:]+$/.test(o)&&(n=!0)}const i=(t.match(/\|/g)||[]).length,s=i>=6;return r&&n||r&&s||r&&i>=4},A7=t=>!t||typeof t!="string"?!1:T7(t)?!0:[/#{1,6}\s+/,/\*\*.*?\*\*/,/\*.*?\*/,/`.*?`/,/```[\s\S]*?```/,/^\s*[-*+]\s+/m,/^\s*\d+\.\s+/m,/\[.*?\]\(.*?\)/,/!\[.*?\]\(.*?\)/,/\$\$.*?\$\$/,/\$.*?\$/].some(r=>r.test(t)),li=t=>!t||typeof t!="string"?t||"":A7(t)||t.includes("|")?E0(t):t;const Go=(t,e)=>{const r=t.__vccOpts||t;for(const[n,i]of e)r[n]=i;return r},E7={class:"mindmap-container"},C7={key:0,class:"welcome-page"},M7={class:"ai-input-content"},N7=["disabled","onKeydown"],I7={class:"ai-input-actions"},R7=["disabled"],D7=["disabled"],O7={key:0},_7={key:1},L7={key:3,class:"save-controls"},z7={class:"image-preview-header"},$7={class:"image-preview-title"},F7={class:"image-preview-body"},B7={key:0,class:"image-preview-loading"},P7={key:1,class:"image-preview-error"},H7=["src","alt"],q7={__name:"MindMap",setup(t,{expose:e}){const r={name:"Light Purple",type:"light",palette:["#660874","#660874","#660874","#660874","#660874","#660874","#660874","#660874","#660874","#660874"],cssVar:{"--node-gap-x":"30px","--node-gap-y":"10px","--main-gap-x":"65px","--main-gap-y":"45px","--root-radius":"30px","--main-radius":"20px","--root-color":"#ffffff","--root-bgcolor":"#660874","--root-border-color":"rgba(0, 0, 0, 0)","--main-color":"#444446","--main-bgcolor":"#ffffff","--topic-padding":"3px","--color":"#777777","--bgcolor":"#f6f6f6","--selected":"#660874","--accent-color":"#660874","--panel-color":"#444446","--panel-bgcolor":"#ffffff","--panel-border-color":"#eaeaea","--map-padding":"50px","--enable-node-border":"true","--node-border-padding":"8","--node-border-radius":"8","--node-border-color":"#660874","--node-border-fill":"#ffffff","--node-border-width":"1"}},n=De(null),i=De(null),s=De(null),a=De({}),o=De({}),l=De(null),c=De(1),u=De(!0),f=De(!1),p=De(!1),g=De(null),b=De(""),x=De(!1);De(new Map),De(!1),De({x:0,y:0}),De(null);const w=De(!1),N=De(""),y=De(""),k=De(!1),I=De(""),D=()=>{u.value=!0,n.value&&(n.value.innerHTML=""),i.value&&(i.value=null)},O=()=>{u.value=!1},z=()=>{u.value=!1},W=(T,M="")=>{console.log("🖼️ 打开图片预览:",{imageUrl:T,altText:M});let _=T;typeof T=="string"&&(T.startsWith("/")||T.startsWith("./")||T.startsWith("../")?_=new URL(T,window.location.origin).href:(T.startsWith("data:image/")||T.startsWith("http://")||T.startsWith("https://"))&&(_=T)),console.log("🖼️ 处理后的图片URL:",_),w.value=!0,y.value=M||"图片预览",k.value=!0,I.value="",ze();const V=new Image;V.onload=()=>{console.log("✅ 图片预加载成功"),N.value=_,k.value=!1,Ge()},V.onerror=()=>{console.error("❌ 图片预加载失败:",_),Ge(),k.value=!1,I.value=`图片加载失败: ${_}`},V.src=_},H=()=>{Ge(),w.value=!1,N.value="",y.value="",k.value=!1,I.value=""},oe=()=>{console.log("✅ 模态框图片加载成功")},me=T=>{console.error("❌ 模态框图片加载失败:",T),console.error("❌ 失败的图片URL:",N.value),k.value=!1,I.value=`图片显示失败: ${N.value}`},ye=()=>{console.log("🔄 重试加载图片"),k.value=!0,I.value="",ze()};let Le=null;const ze=()=>{Le&&clearTimeout(Le),Le=setTimeout(()=>{k.value&&(console.warn("⚠️ 图片加载超时"),k.value=!1,I.value="图片加载超时,请检查网络连接或图片URL是否正确")},1e4)},Ge=()=>{Le&&(clearTimeout(Le),Le=null)},Oe=()=>{if(!i.value||!n.value)return null;try{const T=n.value.querySelector(".map-canvas");if(T){const M=T.style.transform,_=i.value.scaleVal||1;return console.log("📍 保存位置:",{transform:M,scaleVal:_}),{transform:M,scaleVal:_}}}catch(T){console.warn("保存位置失败:",T)}return null},ke=T=>{if(!(!T||!n.value||!i.value))try{const M=n.value.querySelector(".map-canvas");M&&T.transform&&(M.style.setProperty("transform",T.transform,"important"),T.scaleVal&&i.value.scaleVal!==T.scaleVal&&(i.value.scaleVal=T.scaleVal),M.style.setProperty("transform-origin","center center","important"),console.log("📍 恢复位置:",{transform:T.transform,scaleVal:T.scaleVal}))}catch(M){console.warn("恢复位置失败:",M)}},he=async(T,M=!1,_=!0)=>{try{const V=M?Oe():null;V?console.log("📍 保存当前位置用于保持原位:",V):!M&&!_&&console.log("📍 添加节点模式:不保存位置,等待居中到新节点"),console.log("🔍 loadMindmapData 被调用,数据:",T),console.log("🔍 数据字段:",Object.keys(T||{})),T&&T.id?(l.value=T.id,console.log("🔍 设置当前思维导图ID (data.id):",T.id)):T&&T.mindmapId?(l.value=T.mindmapId,console.log("🔍 设置当前思维导图ID (data.mindmapId):",T.mindmapId)):T&&T.nodeData&&T.nodeData.mindmapId?(l.value=T.nodeData.mindmapId,console.log("🔍 设置当前思维导图ID (data.nodeData.mindmapId):",T.nodeData.mindmapId)):T&&T.nodeData&&T.nodeData.mindmap_id?(l.value=T.nodeData.mindmap_id,console.log("🔍 设置当前思维导图ID (data.nodeData.mindmap_id):",T.nodeData.mindmap_id)):(console.warn("⚠️ 数据中没有找到 id 或 mindmapId 字段"),console.log("🔍 可用的字段:",Object.keys(T||{})),T&&T.nodeData&&console.log("🔍 nodeData字段:",Object.keys(T.nodeData||{}))),console.log("🔍 设置后的 currentMindmapId.value:",l.value),O(),await On(),n.value||(console.warn("⚠️ 思维导图容器未准备好,等待DOM更新..."),await new Promise(ie=>setTimeout(ie,100)),n.value||console.warn("⚠️ 思维导图容器仍未准备好,尝试继续执行..."));try{if(n.value){console.log("🔍 创建Mind Elixir实例,设置markdown函数"),i.value=new kt({el:n.value,direction:kt.RIGHT,draggable:!0,contextMenu:!1,toolBar:!0,nodeMenu:!1,keypress:!1,autoCenter:!1,infinite:!0,maxScale:5,minScale:.1,theme:r,enableNodeBorder:!0,markdown:(L,de)=>L.includes("|")||L.includes("**")||L.includes("`")||L.includes("#")||L.includes("![")?li(L):L,imageProxy:L=>L.startsWith("http://")||L.startsWith("https://")?L:L.startsWith("/")?window.location.origin+L:window.location.origin+"/"+L}),console.log("✅ Mind Elixir实例创建完成,markdown函数已设置"),console.log("🔍 初始化Mind Elixir数据:",T);const ie=i.value.init(T);console.log("✅ Mind Elixir实例创建成功,初始化结果:",ie),V?(ke(V),console.log("📍 初始化后立即恢复位置")):!M&&!_&&console.log("📍 跳过根节点居中,等待居中新节点"),(async()=>{try{await On(),await document.fonts.ready,await new Promise(L=>requestAnimationFrame(L)),i.value&&i.value.refresh&&(console.log("🔄 执行完整DOM稳定后的延迟刷新"),i.value.refresh(),!V&&(M||_)&&i.value.toCenter())}catch(L){console.warn("⚠️ 延迟刷新过程中出现错误:",L),setTimeout(()=>{i.value&&i.value.refresh&&i.value.refresh()},200)}})(),i.value.bus.addListener("showImagePreview",(L,de)=>{console.log("🖼️ 收到图片预览事件:",{imageUrl:L,altText:de}),W(L,de)})}else{console.warn("⚠️ 容器未准备好,延迟创建Mind Elixir实例..."),setTimeout(()=>{if(n.value){i.value=new kt({el:n.value,direction:kt.RIGHT,draggable:!0,contextMenu:!1,toolBar:!0,nodeMenu:!1,keypress:!1,autoCenter:!1,infinite:!0,maxScale:5,minScale:.1,theme:r,enableNodeBorder:!0,markdown:(L,de)=>L.includes("|")||L.includes("**")||L.includes("`")||L.includes("#")||L.includes("![")?li(L):L});const ie=i.value.init(T);console.log("✅ Mind Elixir实例延迟创建成功"),V?(ke(V),console.log("📍 延迟创建后立即恢复位置"),setTimeout(()=>{ke(V),console.log("📍 延迟创建后二次确认位置恢复")},100)):!M&&!_&&console.log("📍 延迟创建后跳过根节点居中,等待居中新节点"),(async()=>{try{await On(),await document.fonts.ready,await new Promise(L=>requestAnimationFrame(L)),i.value&&i.value.refresh&&(console.log("🔄 延迟创建实例执行完整DOM稳定后的延迟刷新"),i.value.refresh(),!V&&(M||_)&&i.value.toCenter())}catch(L){console.warn("⚠️ 延迟创建实例的延迟刷新过程中出现错误:",L),setTimeout(()=>{i.value&&i.value.refresh&&i.value.refresh()},250)}})(),i.value.bus.addListener("showImagePreview",(L,de)=>{console.log("🖼️ 收到图片预览事件(延迟创建):",{imageUrl:L,altText:de}),W(L,de)}),setTimeout(()=>{V?ke(V):_&&Ke(),wt(),je()},300)}},200);return}}catch{setTimeout(()=>{try{if(n.value){i.value=new kt({el:n.value,direction:kt.RIGHT,draggable:!0,contextMenu:!1,toolBar:!0,nodeMenu:!1,keypress:!1,autoCenter:!1,infinite:!0,maxScale:5,minScale:.1,theme:r,enableNodeBorder:!0,markdown:(L,de)=>L.includes("|")||L.includes("**")||L.includes("`")||L.includes("#")||L.includes("![")?li(L):L});const ue=i.value.init(T);V?(ke(V),console.log("📍 重试创建后立即恢复位置"),setTimeout(()=>{ke(V),console.log("📍 重试创建后二次确认位置恢复")},100)):!M&&!_&&console.log("📍 重试创建后跳过根节点居中,等待居中新节点"),setTimeout(()=>{V?ke(V):_&&Ke(),wt(),je()},300)}}catch(ue){console.error("❌ Mind Elixir实例重试创建失败:",ue)}},500);return}setTimeout(()=>{M&&V?ke(V):_&&Ke(),O(),wt(),setTimeout(()=>{je()},500)},100)}catch{}},je=()=>{i.value&&n.value&&setTimeout(()=>{n.value.querySelectorAll("me-tpc, .topic, [data-id]").forEach((M,_)=>{var L;const V=M.getAttribute("data-id")||M.id||M.getAttribute("nodeid")||((L=M.querySelector("[data-id]"))==null?void 0:L.getAttribute("data-id"));if(!V)return;const ie=(de,Ee)=>{for(const Ae of de){if(Ae.id===Ee)return Ae;if(Ae.children){const _e=ie(Ae.children,Ee);if(_e)return _e}}return null},ue=ie(i.value.data.nodeData,V);if(ue&&ue.data&&ue.data.des){let de=M.querySelector(".node-description");de||(de=document.createElement("div"),de.className="node-description",de.style.cssText=`
|
||
font-size: 11px;
|
||
color: #666;
|
||
margin-top: 6px;
|
||
padding: 6px 8px;
|
||
background: rgba(0, 0, 0, 0.03);
|
||
border-radius: 4px;
|
||
max-width: 250px;
|
||
word-wrap: break-word;
|
||
line-height: 1.3;
|
||
border-left: 3px solid #e0e0e0;
|
||
display: block;
|
||
`,M.appendChild(de));const Ee=ue.data.des;Ee.length>150?(de.textContent=Ee.substring(0,150)+"...",de.title=Ee):de.textContent=Ee}})},1e3)},Ke=()=>{try{if(i.value&&i.value.toCenter){i.value.toCenter(),console.log("✅ 使用 MindElixir toCenter 方法实现根节点居中");return}const T=n.value;if(!T)return;const M=T.querySelector(".map-canvas");if(!M)return;const _=M.querySelectorAll("me-tpc");if(_.length===0)return;let V=1/0,ie=-1/0,ue=1/0,L=-1/0;_.forEach(H0=>{const Cn=H0.getBoundingClientRect(),q0=T.getBoundingClientRect(),Yo=Cn.left-q0.left,Xo=Cn.top-q0.top;V=Math.min(V,Yo),ie=Math.max(ie,Yo+Cn.width),ue=Math.min(ue,Xo),L=Math.max(L,Xo+Cn.height)});const de=(V+ie)/2,Ee=(ue+L)/2,Ae=T.clientWidth/2,_e=T.clientHeight/2,Xe=Ae-de,xt=_e-Ee;M.style.transform=`translate(${Xe}px, ${xt}px)`,M.style.opacity="1",M.style.transition="opacity 0.3s ease";const Pt=100,or=Math.max(Xe,Pt),Mr=Math.max(xt,Pt);M.style.transform=`translate(${or}px, ${Mr}px)`,M.style.opacity="1",M.style.visibility="visible"}catch{}},Be=async T=>{if(!(!i.value||!T))try{console.log("🎯 开始处理新节点:",T);let M=null,_=0;const V=5;for(;!M&&_<V;)M=i.value.findEle(T),M||(_++,await new Promise(ie=>setTimeout(ie,50)));M?(console.log("✅ 找到节点元素:",M),i.value.scrollIntoView&&(i.value.scrollIntoView(M),console.log("✅ 节点已平滑居中显示")),setTimeout(()=>{i.value.beginEdit&&(i.value.beginEdit(M),console.log("✅ 节点已进入编辑状态"))},350)):console.error("❌ 多次尝试后仍未找到节点元素:",T)}catch(M){console.error("❌ 居中显示节点失败:",M)}},ge=()=>{if(!s.value)return;if(i.value&&i.value.getNodeById)try{const M=i.value.getNodeById(s.value.id);if(M){const _=M.getBoundingClientRect(),V=n.value.getBoundingClientRect(),ie=_.left-V.left+_.width/2,ue=_.bottom-V.top+10;a.value={left:`${ie}px`,top:`${ue}px`};return}}catch{}let T=document.querySelector(`[data-id="${s.value.id}"]`);if(T||(T=document.querySelector(`.topic[data-id="${s.value.id}"]`)),T||(T=document.querySelector(`[data-node-id="${s.value.id}"]`)),T||(T=document.querySelector(`[data-nodeid="me${s.value.id}"]`)),!T){const M=document.querySelectorAll("me-tpc");for(const _ of M)if(_.getAttribute("data-nodeid")===`me${s.value.id}`){T=_;break}}if(!T){const M=document.querySelectorAll(".topic");for(const _ of M)if(_.textContent.trim()===s.value.topic){T=_;break}}if(T){const M=T.getBoundingClientRect(),_=n.value.getBoundingClientRect(),V=M.left-_.left+M.width/2,ie=M.bottom-_.top+10;a.value={left:`${V}px`,top:`${ie}px`}}else a.value={left:"50%",top:"50%",transform:"translate(-50%, -50%)"}},Ft=async()=>{s.value&&(await ae(s.value),s.value=null)},ht=async()=>{s.value&&(await pe(s.value),s.value=null)},yt=async()=>{s.value&&(await Se(s.value),s.value=null)},St=async()=>{if(!s.value)return;console.log("Ask AI for node:",s.value);const T=parseFloat(a.value.left)||0,M=parseFloat(a.value.top)||0;o.value={left:`${T}px`,top:`${M+60}px`,transform:"translateX(-50%)"},p.value=!0,g.value=s.value},lt=()=>{p.value=!1,g.value=null,b.value="",x.value=!1,s.value=null},j=T=>{if(!T)return"";const M=[];return T.parent&&T.parent.topic&&M.push(`父节点: ${T.parent.topic}`),T.parent&&T.parent.parent&&T.parent.parent.topic&&M.push(`祖父节点: ${T.parent.parent.topic}`),M.join(" | ")},G=T=>{T.ctrlKey||T.metaKey||(T.preventDefault(),J())},J=async()=>{if(!(!b.value.trim()||!g.value||x.value)){x.value=!0;try{const T="你是一个专业的思维导图分析助手。请根据用户的问题和提供的节点信息,给出专业、有用的回答。",M=`节点信息:
|
||
当前节点:${g.value.topic}
|
||
上下文:${j(g.value)}
|
||
|
||
用户问题:${b.value}
|
||
|
||
请给出详细的回答,回答应该:
|
||
1. 直接回答用户的问题
|
||
2. 提供具体的建议或改进方案
|
||
3. 保持专业和有用的语调
|
||
4. 回答长度适中,便于在思维导图中展示`;console.log("发送AI请求:",{systemPrompt:T,userPrompt:M});const _=await fetch("http://127.0.0.1:8000/api/ai/generate-stream",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({system_prompt:T,user_prompt:M,model:"glm-4.5",base_url:"https://open.bigmodel.cn/api/paas/v4/",api_key:"ce39bdd4fcf34ec0aec75072bc9ff988.hAp7HZTVUwy7vImn"})});if(!_.ok)throw new Error(`HTTP error! status: ${_.status}`);let V="";const ie=_.body.getReader(),ue=new TextDecoder;let L="";for(;;){const{done:de,value:Ee}=await ie.read();if(de)break;L+=ue.decode(Ee,{stream:!0});const Ae=L.split(`
|
||
`);L=Ae.pop()||"";for(const _e of Ae)if(_e.startsWith("data: "))try{const Xe=JSON.parse(_e.slice(6));if(Xe.type==="chunk")V+=Xe.content;else if(Xe.type==="error")throw new Error(Xe.content)}catch(Xe){console.warn("解析流式数据失败:",Xe)}}await C(g.value,b.value,V),lt()}catch(T){console.error("AI请求失败:",T),alert("AI请求失败,请稍后重试")}finally{x.value=!1}}},ne=T=>T.replace(/^### (.*$)/gim,"📋 $1").replace(/^## (.*$)/gim,"📌 $1").replace(/^# (.*$)/gim,"🎯 $1").replace(/\*\*(.*?)\*\*/g,(M,_)=>{if(_.includes(":")){const V=_.split(":");if(V.length>1)return`【${V[0]}】: ${V.slice(1).join(":")}`}return`【${_}】`}).replace(/\*(.*?)\*/g,"《$1》").replace(/^- (.*$)/gim," • $1").replace(/^\d+\. (.*$)/gim," $&").replace(/```(.*?)```/gims,"💻 $1").replace(/`(.*?)`/g,"「$1」").replace(/\[([^\]]+)\]\([^)]+\)/g,"🔗 $1").replace(/\n\n/g,`
|
||
`).replace(/\n/g,`
|
||
`),be=(T,M,_)=>{const V=T.split(`
|
||
`);let ie=_,ue=[];for(let L=0;L<V.length;L++){const Ee=V[L].trim(),Ae=Ee.match(/^[-*+]\s*【(.+)】/);if(Ae){const _e=Ae[1].trim(),Xe={id:`node_${ie++}`,topic:_e,children:[],level:(M.level||0)+1,data:{}};let xt=[],Pt=L+1;for(;Pt<V.length;){const or=V[Pt].trim();if(or.match(/^[-*+]\s*【(.+)】/))break;const H0=or.match(/^[-*+]\s+(.+)$/);if(H0){const Cn=H0[1].trim(),q0=ne(Cn);xt.push("• "+q0)}Pt++}if(xt.length>0){const or=ne(xt.join(`
|
||
`));Xe.topic=Xe.topic+`
|
||
|
||
`+or}M.children.push(Xe),L=Pt-1}else Ee&&ue.push(Ee)}if(ue.length>0){const L=ue.join(`
|
||
`).trim();L&&L.split(`
|
||
|
||
`).filter(Ee=>Ee.trim()).forEach(Ee=>{const Ae=ne(Ee.trim());if(Ae){const _e={id:`node_${ie++}`,topic:Ae,children:[],level:(M.level||0)+1,data:{}};M.children.push(_e)}})}return{nodeCounter:ie}},S=T=>{const M=T.split(`
|
||
`);let _=null;const V=[];let ie=0,ue=[];if(M.forEach((L,de)=>{const Ee=L.trim(),Ae=Ee.match(/^(#{1,6})\s+(.+)$/);if(Ae){if(ue.length>0&&V.length>0){const or=ue.join(`
|
||
`).trim();or&&(ie=be(or,V[V.length-1],ie).nodeCounter),ue=[]}const _e=Ae[1].length,Xe=Ae[2].trim(),xt=ne(Xe),Pt={id:`node_${ie++}`,topic:xt,children:[],level:_e,data:{}};if(_e===1&&!_)_=Pt,V.length=0,V.push(_);else{for(;V.length>1&&V[V.length-1].level>=_e;)V.pop();V.length>0&&V[V.length-1].children.push(Pt),V.push(Pt)}}else Ee&&ue.push(Ee)}),ue.length>0&&V.length>0){const L=ue.join(`
|
||
`).trim();L&&(ie=be(L,V[V.length-1],ie).nodeCounter)}return _||(_={id:"root",topic:"根节点",children:[],data:{}}),_},C=async(T,M,_)=>{var V,ie,ue;try{const de=(Mr=>Mr.replace(/^#+\s*/gm,"").replace(/\*\*(.*?)\*\*/g,"$1").replace(/\*(.*?)\*/g,"$1").replace(/^\s*[-*+]\s*(?![|])/gm,"• ").replace(/\n{3,}/g,`
|
||
|
||
`).trim())(_),Ee=`# ${M}
|
||
|
||
${de}`,Ae=S(Ee),_e={title:M,des:`AI追问产生的节点 - ${new Date().toLocaleString()}`,parentId:T.id,isRoot:!1},Xe=[];if(Ae.children&&Ae.children.length>0&&Ae.children.forEach(Mr=>{Xe.push({title:Mr.topic,des:"",parentId:null,isRoot:!1})}),console.log("当前思维导图ID:",l.value),!l.value)throw new Error("没有找到当前思维导图ID,无法创建节点");const xt=await ut.addNodes(l.value,[_e]);if(!xt.data||!xt.data.success)throw new Error("AI父节点创建失败");const Pt=(ue=(ie=(V=xt.data.data)==null?void 0:V.nodes)==null?void 0:ie[0])==null?void 0:ue.id;if(!Pt)throw new Error("无法获取创建的父节点ID");Xe.forEach(Mr=>{Mr.parentId=Pt});let or=null;if(Xe.length>0&&(or=await ut.addNodes(l.value,Xe)),xt.data&&xt.data.success)await Bt();else throw new Error("AI父节点创建失败")}catch(L){console.error("创建AI节点失败:",L),alert("创建AI回答节点失败: "+L.message)}},$=async()=>{if(s.value){try{const T=s.value.topic||s.value.title||"无标题";if(navigator.clipboard&&window.isSecureContext)await navigator.clipboard.writeText(T),q();else{const M=document.createElement("textarea");M.value=T,M.style.position="fixed",M.style.left="-999999px",M.style.top="-999999px",document.body.appendChild(M),M.focus(),M.select();const _=document.execCommand("copy");document.body.removeChild(M),_?q():B()}}catch{B()}s.value=null}},q=()=>{const T=document.createElement("div");T.textContent="文本已复制到剪贴板",T.style.cssText=`
|
||
position: fixed;
|
||
top: 20px;
|
||
right: 20px;
|
||
background: #4CAF50;
|
||
color: white;
|
||
padding: 12px 20px;
|
||
border-radius: 6px;
|
||
font-size: 14px;
|
||
z-index: 10000;
|
||
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
|
||
animation: slideIn 0.3s ease;
|
||
`;const M=document.createElement("style");M.textContent=`
|
||
@keyframes slideIn {
|
||
from { transform: translateX(100%); opacity: 0; }
|
||
to { transform: translateX(0); opacity: 1; }
|
||
}
|
||
`,document.head.appendChild(M),document.body.appendChild(T),setTimeout(()=>{T.parentNode&&T.parentNode.removeChild(T),M.parentNode&&M.parentNode.removeChild(M)},3e3)},B=()=>{const T=document.createElement("div");T.textContent="复制失败,请手动复制",T.style.cssText=`
|
||
position: fixed;
|
||
top: 20px;
|
||
right: 20px;
|
||
background: #f44336;
|
||
color: white;
|
||
padding: 12px 20px;
|
||
border-radius: 6px;
|
||
font-size: 14px;
|
||
z-index: 10000;
|
||
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
|
||
animation: slideIn 0.3s ease;
|
||
`,document.body.appendChild(T),setTimeout(()=>{T.parentNode&&T.parentNode.removeChild(T)},3e3)},U=(T,M="success")=>{const _=document.createElement("div");_.textContent=T;const V=M==="success"?"#4CAF50":M==="error"?"#f44336":"#ff9800";_.style.cssText=`
|
||
position: fixed;
|
||
top: 20px;
|
||
right: 20px;
|
||
background: ${V};
|
||
color: white;
|
||
padding: 12px 20px;
|
||
border-radius: 6px;
|
||
font-size: 14px;
|
||
z-index: 10000;
|
||
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
|
||
animation: slideIn 0.3s ease;
|
||
`,document.body.appendChild(_),setTimeout(()=>{_.parentNode&&_.parentNode.removeChild(_)},2e3)},Z=()=>{const T=document.createElement("div");T.textContent="✅ 节点编辑已保存",T.style.cssText=`
|
||
position: fixed;
|
||
top: 20px;
|
||
right: 20px;
|
||
background: #4CAF50;
|
||
color: white;
|
||
padding: 12px 20px;
|
||
border-radius: 6px;
|
||
font-size: 14px;
|
||
z-index: 10000;
|
||
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
|
||
animation: slideIn 0.3s ease;
|
||
`,document.body.appendChild(T),setTimeout(()=>{T.parentNode&&T.parentNode.removeChild(T)},2e3)},ee=()=>{const T=document.createElement("div");T.textContent="❌ 节点编辑保存失败",T.style.cssText=`
|
||
position: fixed;
|
||
top: 20px;
|
||
right: 20px;
|
||
background: #f44336;
|
||
color: white;
|
||
padding: 12px 20px;
|
||
border-radius: 6px;
|
||
font-size: 14px;
|
||
z-index: 10000;
|
||
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
|
||
animation: slideIn 0.3s ease;
|
||
`,document.body.appendChild(T),setTimeout(()=>{T.parentNode&&T.parentNode.removeChild(T)},3e3)},re=async T=>{try{console.log("🎯 处理节点拖拽操作:",T.name),console.log("📦 操作详情:",{name:T.name,objs:T.objs,toObj:T.toObj}),setTimeout(async()=>{var M;try{const _=T.objs||[],V=T.toObj;if(!_.length||!V){console.warn("⚠️ 拖拽操作缺少必要信息");return}console.log(`📦 准备保存 ${_.length} 个节点的父子关系`);let ie=null;T.name==="moveNodeIn"?(ie=V.id,console.log(`📌 拖入操作:新父节点为 ${ie}`)):(T.name==="moveNodeBefore"||T.name==="moveNodeAfter")&&(ie=((M=V.parent)==null?void 0:M.id)||null,console.log(`📌 拖到兄弟位置:新父节点为 ${ie||"根节点"}`));const ue=_.map(async Ae=>{try{console.log(`🔄 更新节点 ${Ae.id} 的父节点为 ${ie||"根节点"}`);const _e=await ut.updateNode(Ae.id,{newParentId:ie});return _e.data&&_e.data.success?(console.log(`✅ 节点 ${Ae.id} 父子关系更新成功`),{success:!0,nodeId:Ae.id}):(console.warn(`⚠️ 节点 ${Ae.id} 父子关系更新失败:`,_e),{success:!1,nodeId:Ae.id})}catch(_e){return console.error(`❌ 节点 ${Ae.id} 父子关系更新失败:`,_e),{success:!1,nodeId:Ae.id,error:_e}}}),L=await Promise.all(ue),de=L.filter(Ae=>Ae.success).length,Ee=L.filter(Ae=>!Ae.success).length;console.log(`📊 拖拽保存结果: ${de} 成功, ${Ee} 失败`)}catch(_){console.error("❌ 保存拖拽后的结构失败:",_),U("❌ 节点拖拽保存失败","error")}},500)}catch(M){console.error("❌ 处理节点拖拽操作失败:",M)}},K=async T=>{try{const M=T.obj;M?await le(M):console.error("无法解析编辑操作:",T)}catch(M){console.error("处理编辑完成失败:",M)}},le=async T=>{var M,_;try{if(!l.value){console.error("无法获取思维导图ID");return}const V=await ut.updateNode(T.id,{newTitle:T.topic,newDes:((M=T.data)==null?void 0:M.des)||"",newParentId:T.parentId||((_=T.parent)==null?void 0:_.id)});V.data&&V.data.success?Z():(console.error("更新节点编辑失败:",V.data),ee())}catch(V){console.error("更新节点编辑失败:",V),ee()}},ae=async T=>{var M;try{await Re();const _=l.value||T.mindmap_id||T.mindmapId;if(!_){console.error("无法获取思维导图ID");return}const V=await ut.addNodes(_,[{title:"新子节点",des:"子节点描述",parentId:T.id}]);if(V.data&&V.data.success){const ie=((M=V.data.data)==null?void 0:M.nodes)||[];if(ie.length>0){const ue=ie[0];try{await new Promise(de=>setTimeout(de,800));const L=await ut.getMindmap(_);if(L.data&&L.data.nodeData){await he(L.data,!1,!1);try{console.log("🎯 开始居中显示新子节点:",ue.id),await Be(ue.id)}catch(de){console.error("居中显示新节点失败:",de)}}else throw new Error("无法获取思维导图数据")}catch(L){console.error("刷新思维导图失败:",L)}}}}catch(_){console.error("添加子节点失败:",_)}},pe=async T=>{var M;try{await Re(),console.log("添加兄弟节点到API:",T.id),console.log("节点信息:",{id:T.id,parentId:T.parentId,parent:T.parent,mindmap_id:T.mindmap_id,mindmapId:T.mindmapId});const _=l.value||T.mindmap_id||T.mindmapId;if(!_){console.error("无法获取思维导图ID");return}let V=T.parentId;!V&&T.parent&&(V=T.parent.id);const ie=await ut.addNodes(_,[{title:"新兄弟节点",des:"兄弟节点描述",parentId:V}]);if(console.log("添加兄弟节点响应:",ie),ie.data&&ie.data.success){const ue=((M=ie.data.data)==null?void 0:M.nodes)||[];if(ue.length>0){const L=ue[0];console.log("新创建的兄弟节点:",L),console.log("🎯 使用MindElixir init方法重新初始化数据...");try{const de=await ut.getMindmap(_);if(de.data&&de.data.nodeData){await he(de.data,!1,!1),console.log("✅ 思维导图刷新成功");try{console.log("🎯 开始居中显示新兄弟节点:",L.id),await Be(L.id)}catch(Ee){console.error("居中显示新节点失败:",Ee)}}else throw new Error("无法获取思维导图数据")}catch(de){console.error("重新初始化失败,使用完整重新加载:",de);const Ee=await ut.getMindmap(_);Ee.data&&Ee.data.nodeData&&await he(Ee.data,!0,!1)}}}}catch(_){console.error("添加兄弟节点失败:",_)}},Se=async T=>{try{await Re(),console.log("删除节点从API:",T.id);const M=await ut.deleteNodes([T.id]);if(console.log("删除节点响应:",M),M.data&&M.data.success){const _=l.value||T.mindmap_id||T.mindmapId;if(_){const V=await ut.getMindmap(_);V.data&&V.data.nodeData&&(await he(V.data,!0,!1),console.log("✅ 删除节点后思维导图已刷新,保持当前位置"))}}}catch(M){console.error("删除节点失败:",M)}},Re=async()=>{const T=n.value;if(T){const M=T.querySelector("input:focus");if(M&&s.value){const _=M.value;_!==s.value.topic&&_.trim()!==""&&(console.log("保存当前编辑:",_),s.value.topic=_,await Ye(s.value))}}},Ye=async T=>{var M,_,V,ie,ue;try{console.log("保存Mind Elixir编辑,节点ID:",T.id),console.log("编辑内容:",{newTitle:T.topic,newDes:((M=T.data)==null?void 0:M.des)||""});const L=String(T.id),de=await ut.updateNode(L,{newTitle:T.topic,newDes:((_=T.data)==null?void 0:_.des)||""});console.log("更新节点API响应:",de),console.log("节点编辑已保存到后端"),console.log("✅ 节点编辑已保存,无需重新加载")}catch(L){console.error("保存Mind Elixir编辑失败:",L),console.error("错误详情:",(V=L.response)==null?void 0:V.data),alert("保存编辑失败: "+(((ue=(ie=L.response)==null?void 0:ie.data)==null?void 0:ue.detail)||L.message))}},Pe=T=>{console.log("打开编辑模态框:",T),i.value.editText(T)},Tt=async(T,M,_)=>{var V,ie,ue;try{console.log("开始创建节点:",T.topic,"父节点ID:",_);const L={title:T.topic||T.title||"无标题",des:((V=T.data)==null?void 0:V.des)||"",parentId:_};T.dangerouslySetInnerHTML&&(L.dangerouslySetInnerHTML=T.dangerouslySetInnerHTML);const de=await ut.addNodes(M,L);if(console.log("创建节点响应:",de),de.data&&de.data.success){const Ae=(ue=(((ie=de.data.data)==null?void 0:ie.nodes)||[])[0])==null?void 0:ue.id;if(console.log("当前节点ID:",Ae),T.children&&T.children.length>0){console.log("开始创建子节点,数量:",T.children.length);for(const _e of T.children)await Tt(_e,M,Ae)}else console.log("节点没有子节点,创建完成")}else console.error("创建节点失败,响应:",de)}catch(L){console.error("创建节点失败:",L)}};let nt=null,gt=null;const wt=()=>{if(!i.value)return;console.log("绑定事件监听器..."),nt&&n.value.removeEventListener("wheel",nt),gt&&n.value.removeEventListener("click",gt),nt=_=>{if(_.ctrlKey||_.metaKey){_.preventDefault();const V=_.deltaY>0?.9:1.1,ie=Math.max(.3,Math.min(3,c.value*V));if(i.value){const ue=n.value.querySelector(".map-container");ue&&(ue.style.transform=`scale(${ie})`,c.value=ie,localStorage.setItem("mindmap-zoom-level",ie.toString()))}}},n.value.addEventListener("wheel",nt),i.value.bus.addListener("select",_=>{s.value=_,setTimeout(()=>{ge()},50)}),i.value.bus.addListener("selectNode",_=>{s.value=_,setTimeout(()=>{ge()},50)}),i.value.bus.addListener("scale",_=>{Math.abs(_-1)<.01&&Math.abs(c.value-1)>.01&&setTimeout(()=>{hn()},50)}),window.zoomIntervalId&&clearInterval(window.zoomIntervalId);const T=setInterval(()=>{c.value!==1&&n.value&&F0()},500);window.zoomIntervalId=T;let M=0;gt=_=>{const V=Date.now();if(V-M<100)return;M=V;const ie=_.target,ue=ie.closest("me-tpc")||ie.closest(".topic")||(ie.classList.contains("topic")?ie:null)||(ie.tagName==="ME-TPC"?ie:null);if(ue){const L=ue.nodeObj;if(L){s.value=L;const de=n.value.getBoundingClientRect(),Ee=ue.getBoundingClientRect(),Ae=Ee.left-de.left+Ee.width/2,_e=Ee.bottom-de.top+8;a.value={left:`${Ae}px`,top:`${_e}px`}}}else s.value=null,p.value&&(p.value=!1,g.value=null,b.value="",x.value=!1)},n.value.addEventListener("click",gt),i.value.bus.addListener("edit",_=>{console.log("edit事件触发:",_),Pe(_)}),i.value.bus.addListener("editFinish",_=>{console.log("editFinish事件触发:",_),K(_)}),i.value.bus.addListener("operation",_=>{console.log("Mind Elixir操作事件:",_),_.name==="moveNodeIn"||_.name==="moveNodeBefore"||_.name==="moveNodeAfter"?(console.log("检测到节点拖拽操作:",_.name,_),re(_)):_.name==="finishEdit"&&(console.log("检测到编辑完成操作:",_),K(_))}),i.value.bus.addListener("removeNode",_=>{console.log("删除节点:",_),Se(_)})},hn=()=>{if(i.value){const T=localStorage.getItem("mindmap-zoom-level");if(T){const M=parseFloat(T);if(M>=.3&&M<=3){const _=n.value.querySelector(".map-container");_&&(_.style.transform=`scale(${M})`,c.value=M)}}}},F0=()=>{if(i.value&&c.value!==1&&n.value){const T=n.value.querySelector(".map-container");T&&(T.style.transform=`scale(${c.value})`)}},It=async()=>{var T;if(console.log("🚀🚀🚀 保存函数被调用 🚀🚀🚀"),console.log("🔍 mindElixir.value:",i.value),console.log("🔍 currentMindmapId.value:",l.value),console.log("🔍 mindmapEl.value:",n.value),console.log("🔍🔍🔍 全局状态检查开始 🔍🔍🔍"),console.log("🔍 - showWelcome:",u.value),console.log("🔍 - 是否有思维导图容器:",!!n.value),console.log("🔍 - MindElixir实例状态:",!!i.value),console.log("🔍🔍🔍 全局状态检查结束 🔍🔍🔍"),i.value&&i.value.data?(console.log("🔍🔍🔍 MindElixir数据检查开始 🔍🔍🔍"),console.log("🔍 - 数据对象:",i.value.data),console.log("🔍 - 数据字段:",Object.keys(i.value.data)),console.log("🔍 - 是否有nodeData:",!!i.value.data.nodeData),console.log("🔍 - 是否有nodes:",!!i.value.data.nodes),console.log("🔍🔍🔍 MindElixir数据检查结束 🔍🔍🔍")):console.log("⚠️ MindElixir数据不存在或为空"),!i.value||!l.value){if(console.warn("⚠️ 没有可保存的思维导图数据"),console.warn("🔍 mindElixir.value 状态:",!!i.value),console.warn("🔍 currentMindmapId.value 状态:",!!l.value),i.value&&i.value.data&&(console.log("🔍 尝试从MindElixir数据中获取ID"),console.log("🔍 MindElixir数据:",i.value.data),i.value.data.mindmapId?(l.value=i.value.data.mindmapId,console.log("🔍 从MindElixir数据中获取到mindmapId:",i.value.data.mindmapId)):i.value.data.mindmap_id&&(l.value=i.value.data.mindmap_id,console.log("🔍 从MindElixir数据中获取到mindmap_id:",i.value.data.mindmap_id))),!l.value&&i.value){if(console.log("🔍 尝试重新初始化MindElixir数据..."),console.log("🔍 MindElixir实例属性:",Object.keys(i.value)),console.log("🔍 MindElixir实例方法:",Object.getOwnPropertyNames(Object.getPrototypeOf(i.value))),i.value.getData){const M=i.value.getData();console.log("🔍 通过getData()获取的数据:",M),M&&M.nodeData&&(console.log("🔍 nodeData详情:",M.nodeData),M.nodeData.mindmapId?(l.value=M.nodeData.mindmapId,console.log("🔍 从nodeData.mindmapId获取到ID:",M.nodeData.mindmapId)):M.nodeData.mindmap_id?(l.value=M.nodeData.mindmap_id,console.log("🔍 从nodeData.mindmap_id获取到ID:",M.nodeData.mindmap_id)):(console.log("🔍 nodeData中没有找到mindmapId字段"),console.log("🔍 nodeData字段:",Object.keys(M.nodeData)))),!l.value&&M&&(console.log("🔍 检查其他可能的ID字段..."),M.id?(l.value=M.id,console.log("🔍 从data.id获取到ID:",M.id)):M.mindmapId&&(l.value=M.mindmapId,console.log("🔍 从data.mindmapId获取到ID:",M.mindmapId)))}i.value.mindElixirData&&(console.log("🔍 mindElixirData:",i.value.mindElixirData),i.value.mindElixirData.id&&(l.value=i.value.mindElixirData.id,console.log("🔍 从mindElixirData获取到ID:",i.value.mindElixirData.id)))}if(!l.value){console.warn("⚠️ 仍然无法获取思维导图ID,无法保存"),console.warn("🔍 建议:请先加载一个思维导图,然后再尝试保存");return}}try{console.log("💾 开始保存思维导图..."),console.log("🔍 当前思维导图ID:",l.value),console.log("🔍 MindElixir实例:",i.value);let M=null;if(i.value&&i.value.getData?(M=i.value.getData(),console.log("🔍 通过getData()获取的数据:",M)):(M=i.value.data,console.log("🔍 通过data属性获取的数据:",M)),!M){console.warn("⚠️ MindElixir数据为空");return}let _=[];console.log("🔍 数据结构分析:"),console.log("🔍 - currentData.nodeData:",M.nodeData),console.log("🔍 - currentData.nodes:",M.nodes),console.log("🔍 - currentData.nodeData.children:",(T=M.nodeData)==null?void 0:T.children);const V=L=>{L&&L.id&&(_.push(L),console.log(`🔍 收集节点: ${L.id} - ${L.topic||L.content||"无标题"}`),L.children&&L.children.length>0&&L.children.forEach(de=>V(de)))};if(M.nodeData)V(M.nodeData),console.log("🔍 从根节点收集到节点数量:",_.length);else if(M.nodes&&Array.isArray(M.nodes))M.nodes.forEach(L=>V(L)),console.log("🔍 从nodes数组收集到节点数量:",_.length);else if(Array.isArray(M))M.forEach(L=>V(L)),console.log("🔍 从currentData数组收集到节点数量:",_.length);else{console.warn("⚠️ 无法找到节点数据"),console.log("🔍 可用的数据字段:",Object.keys(M));return}if(_.length===0){console.warn("⚠️ 没有收集到任何节点");return}console.log("🔍 找到节点数据:",_),console.log("🔍 节点数量:",_.length),console.log("🔍 节点数据类型:",Array.isArray(_)?"数组":typeof _);const ie=[];if(_.forEach((L,de)=>{if(console.log(`🔍 处理节点 ${de}:`,L),L&&L.id){const Ee=L.topic||L.content||L.text||"",Ae=L.x||L.offsetX||0,_e=L.y||L.offsetY||0;console.log(`🔍 节点 ${L.id} 内容:`,Ee,"位置:",{x:Ae,y:_e});const Xe={content:Ee,position:{x:Ae,y:_e}};(L.parentId||L.parent)&&(Xe.parentId=L.parentId||L.parent,console.log(`🔍 节点 ${L.id} 父节点:`,Xe.parentId)),console.log(`🔍 准备保存节点 ${L.id}:`,Xe),ie.push(ut.updateNode(L.id,Xe).then(xt=>{console.log(`✅ 节点 ${L.id} 保存成功:`,xt)}).catch(xt=>{console.error(`❌ 节点 ${L.id} 保存失败:`,xt)}))}else console.warn(`⚠️ 节点 ${de} 缺少ID:`,L)}),console.log("🔍 准备保存的节点数量:",ie.length),ie.length===0){console.warn("⚠️ 没有找到需要保存的节点");return}const ue=await Promise.all(ie);console.log("🔍 保存结果:",ue),console.log("🎉 思维导图保存完成!"),console.log("🔄 保存完成,开始自动刷新..."),await Bt()}catch(M){console.error("❌ 保存思维导图失败:",M)}},Bt=async()=>{if(!l.value){console.warn("⚠️ 没有当前思维导图ID,无法刷新");return}try{console.log("🔄 开始刷新思维导图...");const T=await ut.getMindmap(l.value);T.data&&T.data.nodeData?(console.log("✅ 获取到最新数据,开始刷新显示..."),await he(T.data,!0,!1),console.log("🎉 思维导图刷新完成!")):console.warn("⚠️ 无法获取思维导图数据")}catch(T){console.error("❌ 刷新思维导图失败:",T)}},B0=async(T,M)=>{try{const _=String(l.value||"");if(i.value&&_&&_.startsWith("temp-")){console.log("🔄 检测到实时渲染的思维导图,将保存到数据库并更新ID");const ue=Oe();console.log("📍 保存当前位置:",ue);const L=await ut.createMindmap(M||"预览思维导图",T);if(console.log("🔄 创建思维导图响应:",L),L.data&&L.data.id){const de=L.data.id;console.log("🎉 创建思维导图成功,新思维导图的ID是:",de);const Ee=l.value;if(l.value=de,i.value&&i.value.data){i.value.data.mindmapId=de,i.value.data.id=de;const Ae=_e=>{_e&&(_e.mindmapId=de,_e.children&&_e.children.forEach(Xe=>Ae(Xe)))};i.value.data.nodeData&&Ae(i.value.data.nodeData)}console.log("✅ 已更新思维导图ID,保持视图状态"),console.log("🔄 从临时ID",Ee,"更新为正式ID",de),ue&&setTimeout(()=>{ke(ue),console.log("📍 已恢复位置和缩放状态")},100),window.dispatchEvent(new CustomEvent("mindmap-saved",{detail:{mindmapId:de,title:M,timestamp:Date.now(),fromRealtime:!0}}));return}}console.log("🔄 没有检测到实时渲染的思维导图,使用标准保存流程");const ie=await ut.createMindmap(M||"预览思维导图",T);if(console.log("🔄 创建思维导图响应:",ie),ie.data&&ie.data.id){const ue=ie.data.id;if(console.log("🎉 创建思维导图成功,新思维导图的ID是:",ue),console.log("📊 响应数据详情:",ie.data),ie.data.nodeData)console.log("✅ 思维导图创建时已包含节点数据,直接加载"),l.value=ue,O(),await he(ie.data),window.dispatchEvent(new CustomEvent("mindmap-saved",{detail:{mindmapId:ue,title:M,timestamp:Date.now()}})),setTimeout(async()=>{try{console.log("🔄 重新加载思维导图数据...");const L=await ut.getMindmap(ue);L.data&&L.data.nodeData&&(await he(L.data),console.log("✅ 思维导图数据重新加载成功"))}catch(L){console.error("❌ 重新加载思维导图失败:",L)}},1500);else{console.log("🔧 需要递归创建节点"),await Tt(T,ue,null),console.log("📥 开始加载新创建的思维导图,ID:",ue);const L=await ut.getMindmap(ue);console.log("🔄 加载思维导图响应:",L),L.data&&L.data.nodeData?(console.log("✅ 成功获取思维导图数据,开始加载显示"),l.value=ue,O(),await he(L.data),window.dispatchEvent(new CustomEvent("mindmap-saved",{detail:{mindmapId:ue,title:M,timestamp:Date.now()}})),setTimeout(async()=>{try{console.log("🔄 重新加载思维导图数据...");const de=await ut.getMindmap(ue);de.data&&de.data.nodeData&&(await he(de.data),console.log("✅ 思维导图数据重新加载成功"))}catch(de){console.error("❌ 重新加载思维导图失败:",de)}},1500)):console.error("❌ 获取思维导图数据失败:",L)}}}catch(_){console.error("❌ 保存预览数据到数据库失败:",_)}},P0=async T=>{try{if(console.log("📚 开始从历史记录加载思维导图:",T.title),O(),T.mindmapId){console.log("🎯 使用思维导图ID加载:",T.mindmapId);const M=await ut.getMindmap(T.mindmapId);if(M.data&&M.data.nodeData)await he(M.data);else throw new Error("无法获取思维导图数据")}else if(T.json)console.log("📊 使用历史记录中的JSON数据"),await he(T.json);else if(T.markdown){console.log("📝 使用历史记录中的Markdown数据,尝试转换为JSON");try{const M=await convertMarkdownToJSON(T.markdown);if(M)await he(M);else throw new Error("Markdown转换失败")}catch(M){console.error("Markdown转换失败:",M)}}}catch(M){console.error("❌ 从历史记录加载思维导图失败:",M)}};Ka(async()=>{window.addEventListener("save-preview-to-database",T=>{console.log("🎯 收到保存到数据库事件:",T.detail),console.log("📋 事件详情 - 标题:",T.detail.title,"来源:",T.detail.source,"时间戳:",new Date(T.detail.timestamp).toLocaleString()),B0(T.detail.data,T.detail.title)}),window.addEventListener("realtime-mindmap-update",T=>{console.log("🔄 收到实时思维导图更新事件:",T.detail),Jd(T.detail.data,T.detail.title)}),window.addEventListener("loadMindmapFromHistory",T=>{console.log("📚 收到从历史记录加载思维导图事件:",T.detail),console.log("🔍 事件数据详情:",T.detail),P0(T.detail)}),window.addEventListener("ai-sidebar-toggle",T=>{console.log("🤖 AI侧边栏折叠状态变化:",T.detail.isCollapsed),f.value=T.detail.isCollapsed}),D()});const Ko=()=>{window.zoomIntervalId&&(clearInterval(window.zoomIntervalId),window.zoomIntervalId=null),n.value&&(nt&&(n.value.removeEventListener("wheel",nt),nt=null),gt&&(n.value.removeEventListener("click",gt),gt=null)),console.log("✅ 已清理所有定时器和事件监听器")};Ya(()=>{Ko()}),e({showMindMapPage:z,cleanupIntervals:Ko});const Jd=async(T,M)=>{try{if(i.value){console.log("🔄 更新现有思维导图数据");try{const _=Oe(),V=String(l.value||""),ie=V&&V.startsWith("temp-")?V:`temp-${Date.now()}`,ue={nodeData:T,mindmapId:ie,id:ie,title:M||"AI生成中..."};(!V||!V.startsWith("temp-"))&&(l.value=ie,console.log("🆔 更新临时思维导图ID:",ie));const L=i.value.init(ue);_&&setTimeout(()=>{ke(_)},100)}catch(_){console.error("❌ 更新思维导图数据失败:",_)}}else{O(),await On();let _=0;for(;!n.value&&_<20;)await new Promise(L=>setTimeout(L,50)),await On(),_++;if(!n.value){console.error("❌ 思维导图容器仍未准备好,跳过此次更新");return}i.value=new kt({el:n.value,direction:kt.RIGHT,draggable:!0,contextMenu:!1,toolBar:!0,nodeMenu:!0,keypress:!1,autoCenter:!1,infinite:!0,maxScale:5,minScale:.1,markdown:(L,de)=>L.includes("|")||L.includes("**")||L.includes("`")||L.includes("#")||L.includes("$")||L.includes("![")?li(L):L});const V=`temp-${Date.now()}`,ie={nodeData:T,mindmapId:V,id:V,title:M||"AI生成中..."};l.value=V,console.log("🆔 设置临时思维导图ID:",V);const ue=i.value.init(ie);console.log("✅ 实时思维导图实例创建成功"),wt(),Ke()}}catch(_){console.error("❌ 实时更新思维导图失败:",_)}};return(T,M)=>(Fe(),He("div",E7,[u.value?(Fe(),He("div",C7,[Y("div",{class:Un(["welcome-content",{"ai-sidebar-collapsed":f.value}])},[...M[2]||(M[2]=[cl('<div class="welcome-header" data-v-11632a07><h1 data-v-11632a07>🧠 思维导图工具</h1><p class="welcome-subtitle" data-v-11632a07>可视化您的想法,构建知识体系</p></div><div class="welcome-features" data-v-11632a07><div class="feature-item" data-v-11632a07><div class="feature-icon" data-v-11632a07>🎯</div><div class="feature-text" data-v-11632a07><h3 data-v-11632a07>智能AI生成</h3><p data-v-11632a07>上传文档,AI自动生成思维导图结构</p></div></div><div class="feature-item" data-v-11632a07><div class="feature-icon" data-v-11632a07>✏️</div><div class="feature-text" data-v-11632a07><h3 data-v-11632a07>灵活编辑</h3><p data-v-11632a07>拖拽节点,自由调整思维导图布局</p></div></div><div class="feature-item" data-v-11632a07><div class="feature-icon" data-v-11632a07>💾</div><div class="feature-text" data-v-11632a07><h3 data-v-11632a07>云端存储</h3><p data-v-11632a07>自动保存,多设备同步访问</p></div></div></div><div class="welcome-tips" data-v-11632a07><p data-v-11632a07>💡 提示:使用左侧AI侧边栏可以快速生成思维导图内容</p></div>',3)])],2)])):yr("",!0),p.value?(Fe(),He("div",{key:1,class:"ai-input-area",style:jn(o.value)},[Y("div",{class:"ai-input-header"},[M[3]||(M[3]=Y("span",{class:"ai-input-title"},"🤖 询问AI",-1)),Y("button",{onClick:lt,class:"ai-close-btn"},"×")]),Y("div",M7,[Ai(Y("textarea",{"onUpdate:modelValue":M[0]||(M[0]=_=>b.value=_),placeholder:"请输入您的问题...",rows:"2",disabled:x.value,onKeydown:[Rs(W0(G,["exact"]),["enter"]),Rs(W0(J,["ctrl"]),["enter"]),Rs(W0(J,["meta"]),["enter"])]},null,40,N7),[[eo,b.value]]),Y("div",I7,[Y("button",{onClick:lt,class:"btn-cancel",disabled:x.value}," 取消 ",8,R7),Y("button",{onClick:J,class:"btn-submit",disabled:!b.value.trim()||x.value},[x.value?(Fe(),He("span",O7,"AI思考中...")):(Fe(),He("span",_7,"询问AI"))],8,D7)])])],4)):yr("",!0),u.value?yr("",!0):(Fe(),He("div",{key:2,ref_key:"mindmapEl",ref:n,class:"mindmap-el"},null,512)),u.value?yr("",!0):(Fe(),He("div",L7,[Y("button",{onClick:It,class:"save-btn",title:"保存思维导图",style:{display:"none"}},[...M[4]||(M[4]=[Y("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"},[Y("path",{d:"M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z"}),Y("polyline",{points:"17,21 17,13 7,13 7,21"}),Y("polyline",{points:"7,3 7,8 15,8"})],-1),Y("span",null,"保存",-1)])]),Y("button",{onClick:Bt,class:"refresh-btn",title:"刷新思维导图",style:{display:"none"}},[...M[5]||(M[5]=[Y("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"},[Y("path",{d:"M1 4v6h6"}),Y("path",{d:"M23 20v-6h-6"}),Y("path",{d:"M20.49 9A9 9 0 0 0 5.64 5.64L1 10m22 4l-4.64 4.36A9 9 0 0 1 3.51 15"})],-1),Y("span",null,"刷新",-1)])])])),s.value?(Fe(),He("div",{key:4,class:"context-menu",style:jn(a.value)},[s.value.parentId||s.value.parent?(Fe(),He("div",{key:0,class:"context-menu-item",onClick:ht,title:"Add a sibling card"},[...M[6]||(M[6]=[Y("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 18 18",fill:"none"},[Y("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M9.9001 4.5C9.9001 5.74264 8.89274 6.75 7.6501 6.75C6.64263 6.75 5.78981 6.08785 5.5031 5.175H2.7001V11.025H5.4001V9.9C5.4001 8.90589 6.11644 8.1 7.0001 8.1H15.0501C15.9338 8.1 16.6501 8.90589 16.6501 9.9V13.95C16.6501 14.9441 15.9338 15.75 15.0501 15.75H7.0001C6.11644 15.75 5.4001 14.9441 5.4001 13.95V12.375H2.2501C1.75304 12.375 1.3501 11.7471 1.3501 11.475V4.725C1.3501 4.22794 1.75304 3.825 2.2501 3.825H5.5031C5.78981 2.91215 6.64263 2.25 7.6501 2.25C8.89274 2.25 9.9001 3.25736 9.9001 4.5ZM15.0501 9.9H7.0001V13.95H15.0501V9.9Z",fill:"currentColor","fill-opacity":"1"})],-1)])])):yr("",!0),Y("div",{class:"context-menu-item",onClick:Ft,title:"Add a child card"},[...M[7]||(M[7]=[Y("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 18 18",fill:"none"},[Y("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M15.9501 6.63691H8.35014V11.3619H15.9501V6.63691ZM8.35014 4.83691C7.46649 4.83691 6.75014 5.6428 6.75014 6.63691V8.32441H4.84719C4.56048 7.41157 3.70766 6.74941 2.7002 6.74941C1.45755 6.74941 0.450195 7.75677 0.450195 8.99941C0.450195 10.2421 1.45755 11.2494 2.7002 11.2494C3.70766 11.2494 4.56048 10.5873 4.84719 9.67441H6.75014V11.3619C6.75014 12.356 7.46649 13.1619 8.35014 13.1619H15.9501C16.8338 13.1619 17.5501 12.356 17.5501 11.3619V6.63691C17.5501 5.6428 16.8338 4.83691 15.9501 4.83691H8.35014Z",fill:"currentColor","fill-opacity":"1"})],-1)])]),Y("div",{class:"context-menu-item",onClick:$,title:"Copy text"},[...M[8]||(M[8]=[Y("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 18 18",fill:"none"},[Y("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M16.4503 2.99952C16.4016 2.18908 15.7289 1.54688 14.9062 1.54688H6.46875L6.37452 1.5497C5.56408 1.5984 4.92188 2.27108 4.92188 3.09375V3.54688C4.92188 3.68495 5.0338 3.79688 5.17188 3.79688H6.35938C6.49745 3.79688 6.60938 3.68495 6.60938 3.54688V3.375L6.61309 3.34276C6.62766 3.28063 6.68343 3.23438 6.75 3.23438H14.625L14.6572 3.23809C14.7261 3.23438 14.7656 3.30029 14.7656 3.375V11.25L14.7619 11.2822C14.7473 11.3444 14.6916 11.3906 14.625 11.3906H14.4531C14.3151 11.3906 14.2031 11.5026 14.2031 11.6406V12.8281C14.2031 12.9662 14.3151 13.0781 14.4531 13.0781H14.9062L15.0005 13.0753C15.8109 13.0266 16.4531 12.3539 16.4531 11.5312V3.09375L16.4503 2.99952ZM11.5312 4.92188H3.09375C2.23943 4.92188 1.54688 5.61443 1.54688 6.46875V14.9062C1.54688 15.7606 2.23943 16.4531 3.09375 16.4531H11.5312C12.3856 16.4531 13.0781 15.7606 13.0781 14.9062V6.46875C13.0781 5.61443 12.3856 4.92188 11.5312 4.92188ZM3.37032 6.615H11.2635C11.3361 6.615 11.395 6.6739 11.395 6.74655V14.6397C11.395 14.7124 11.3361 14.7712 11.2635 14.7712H3.37032C3.29767 14.7712 3.23877 14.7124 3.23877 14.6397V6.74655C3.23877 6.6739 3.29767 6.615 3.37032 6.615ZM4.5 8.5C4.5 8.27909 4.67909 8.1 4.9 8.1H9.725C9.94591 8.1 10.125 8.27909 10.125 8.5V9.5C10.125 9.72091 9.94591 9.9 9.725 9.9H4.9C4.67909 9.9 4.5 9.72091 4.5 9.5V8.5ZM4.9 11.475C4.67909 11.475 4.5 11.6541 4.5 11.875V12.875C4.5 13.0959 4.67909 13.275 4.9 13.275H9.725C9.94591 13.275 10.125 13.0959 10.125 12.875V11.875C10.125 11.6541 9.94591 11.475 9.725 11.475H4.9Z",fill:"currentColor","fill-opacity":"1"})],-1)])]),Y("div",{class:"context-menu-item ask-ai",onClick:St,title:"Ask AI"},[...M[9]||(M[9]=[cl('<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-v-11632a07><path d="M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z" data-v-11632a07></path><path d="M13 8H7" data-v-11632a07></path><path d="M17 12H7" data-v-11632a07></path><circle cx="17" cy="8" r="1" data-v-11632a07></circle></svg>',1)])]),Y("div",{class:"context-menu-item delete",onClick:yt,title:"Delete"},[...M[10]||(M[10]=[Y("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[Y("path",{d:"M5.5 5.5A.5.5 0 0 1 6 6v6a.5.5 0 0 1-1 0V6a.5.5 0 0 1 .5-.5zm2.5 0a.5.5 0 0 1 .5.5v6a.5.5 0 0 1-1 0V6a.5.5 0 0 1 .5-.5zm3 .5a.5.5 0 0 0-1 0v6a.5.5 0 0 0 1 0V6z",fill:"currentColor"}),Y("path",{"fill-rule":"evenodd",d:"M14.5 3a1 1 0 0 1-1 1H13v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V4h-.5a1 1 0 0 1-1-1V2a1 1 0 0 1 1-1H6a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1h3.5a1 1 0 0 1 1 1v1zM4.118 4 4 4.059V13a1 1 0 0 0 1 1h6a1 1 0 0 0 1-1V4.059L11.882 4H4.118zM2.5 3V2h11v1h-11z",fill:"currentColor"})],-1)])])],4)):yr("",!0),w.value?(Fe(),He("div",{key:5,class:"image-preview-modal",onClick:H},[Y("div",{class:"image-preview-content",onClick:M[1]||(M[1]=W0(()=>{},["stop"]))},[Y("div",z7,[Y("span",$7,Zt(y.value),1),Y("button",{onClick:H,class:"image-preview-close"},"×")]),Y("div",F7,[k.value?(Fe(),He("div",B7,[...M[11]||(M[11]=[Y("div",{class:"loading-spinner"},null,-1),Y("p",null,"加载图片中...",-1)])])):I.value?(Fe(),He("div",P7,[M[12]||(M[12]=Y("p",null,"❌ 图片加载失败",-1)),Y("p",null,Zt(I.value),1),Y("button",{onClick:ye,class:"retry-button"},"重试")])):(Fe(),He("img",{key:2,src:N.value,alt:y.value,class:"preview-image",onLoad:oe,onError:me},null,40,H7))])])])):yr("",!0)]))}},j7=Go(q7,[["__scopeId","data-v-11632a07"]]),U7="modulepreload",V7=function(t){return"/"+t},Wc={},Gc=function(e,r,n){if(!r||r.length===0)return e();const i=document.getElementsByTagName("link");return Promise.all(r.map(s=>{if(s=V7(s),s in Wc)return;Wc[s]=!0;const a=s.endsWith(".css"),o=a?'[rel="stylesheet"]':"";if(!!n)for(let u=i.length-1;u>=0;u--){const f=i[u];if(f.href===s&&(!a||f.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${s}"]${o}`))return;const c=document.createElement("link");if(c.rel=a?"stylesheet":U7,a||(c.as="script",c.crossOrigin=""),c.href=s,document.head.appendChild(c),a)return new Promise((u,f)=>{c.addEventListener("load",u),c.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${s}`)))})})).then(()=>e()).catch(s=>{const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=s,window.dispatchEvent(a),!a.defaultPrevented)throw s})};const W7={class:"ai-sidebar-wrapper"},G7=["title"],K7={key:0,width:"22",height:"22",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5"},Y7={key:1,width:"22",height:"22",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5"},X7={class:"sidebar-content"},J7={class:"section"},Z7={class:"input-group"},Q7={key:0,class:"file-info"},eg={class:"file-details"},tg={class:"file-info-left"},rg={class:"file-name"},ng={class:"file-size"},ig={class:"button-group file-action-buttons"},sg=["disabled"],ag={key:0},og={key:1},lg={key:0,class:"section"},cg={class:"history-list"},ug=["onClick"],dg={class:"history-title"},hg={class:"history-time"},fg={class:"section"},pg={class:"input-group"},mg={class:"button-group"},gg=["disabled"],vg={key:0},bg={key:1},yg={class:"section"},wg={key:0,class:"processing-status"},xg={class:"result-container"},kg={class:"json-result"},Sg={class:"button-group"},Tg=["disabled"],Ag={__name:"AISidebar",emits:["start-realtime-generation"],setup(t,{emit:e}){const r=e,n=De(!1),i=De(""),s=De(""),a=De(""),o=De(!1),l=De(!1),c=De([]),u=De(!1);De(""),De("");const f=De(!1),p=De(""),g=De(null),b=De(null),x=()=>{n.value=!n.value,window.dispatchEvent(new CustomEvent("ai-sidebar-toggle",{detail:{isCollapsed:n.value}}))},w=j=>{const G=j.target.files[0];G&&(b.value=G,ge("文件上传成功!","success"))},N=j=>{j.preventDefault(),u.value=!1;const G=j.dataTransfer.files;if(G.length>0){const J=G[0],ne=[".txt",".md",".doc",".docx",".pdf"],be="."+J.name.split(".").pop().toLowerCase();ne.includes(be)?(b.value=J,ge("文件拖拽上传成功!","success")):ge("不支持的文件格式!请上传 .txt, .md, .doc, .docx, .pdf 格式的文件","error")}},y=j=>{j.preventDefault(),u.value=!0},k=j=>{j.preventDefault(),u.value=!1},I=()=>{b.value=null,g.value&&(g.value.value="")},D=j=>{if(j===0)return"0 Bytes";const G=1024,J=["Bytes","KB","MB","GB"],ne=Math.floor(Math.log(j)/Math.log(G));return parseFloat((j/Math.pow(G,ne)).toFixed(2))+" "+J[ne]},O=async()=>{if(!b.value){ge("请先上传文件","error");return}o.value=!0,r("start-realtime-generation");try{const j=await z(b.value);s.value="";const G=`你是一个专业的文档分析专家。请分析上传的文档内容,生成结构化的Markdown格式思维导图。要求:
|
||
1. 提取主要主题和关键概念
|
||
2. 组织成层次分明的结构
|
||
3. 使用清晰的标题和子标题
|
||
4. 保持内容的逻辑性和完整性
|
||
5. 对于长文档,请确保完整处理所有内容,不要截断
|
||
6. **重要:如果原文档中包含图片,请按以下方式处理:
|
||
- 识别图片在文档中的位置和上下文
|
||
- 根据图片内容生成准确的描述文字
|
||
- 在相应位置插入图片占位符:
|
||
- 图片描述要准确反映图片内容,图片路径可以是相对路径或占位符
|
||
- 确保图片占位符放在逻辑上合适的位置**
|
||
7. **重要:如果原文档中包含表格,请完整保留表格结构:
|
||
- 保持表格的Markdown格式
|
||
- 确保所有表格行都被包含
|
||
- 不要省略任何表格内容
|
||
- 对于合并单元格的表格,请使用HTML格式并正确使用rowspan和colspan属性
|
||
- 如果表格结构复杂,优先使用HTML table标签而不是Markdown表格语法**
|
||
8. **重要:确保内容完整性:
|
||
- 不要截断任何内容
|
||
- 保持原文的完整性
|
||
- 所有重要信息都要包含在思维导图中**
|
||
9. 输出格式:直接输出Markdown内容,不要添加任何说明文字或代码块标记`,J=`请分析以下文档内容并生成结构化Markdown:
|
||
|
||
${j}`;await me(G,J),await Le(),ht(b.value.name,s.value),setTimeout(async()=>{try{await Be()}catch(ne){console.error("自动保存失败:",ne)}},1500)}catch(j){console.error("从文件生成Markdown失败:",j),ge("生成失败: "+j.message,"error")}finally{o.value=!1}},z=j=>new Promise(async(G,J)=>{try{const ne=j.type.includes("text")||j.name.endsWith(".txt")||j.name.endsWith(".md"),be=j.type==="application/vnd.openxmlformats-officedocument.wordprocessingml.document"||j.type==="application/msword"||j.name.endsWith(".docx")||j.name.endsWith(".doc"),S=j.type==="application/pdf"||j.name.endsWith(".pdf");if(ne){const C=new FileReader;C.onload=$=>G($.target.result),C.onerror=()=>J(new Error("文本文件读取失败")),C.readAsText(j)}else if(be){const C=await W(j);G(C)}else if(S){const C=await H(j);G(C)}else{const C=new FileReader;C.onload=$=>G($.target.result),C.onerror=()=>J(new Error("文件读取失败")),C.readAsText(j)}}catch(ne){J(ne)}}),W=async j=>{try{if(j.name.endsWith(".docx")){const G=await Gc(()=>import("./index-e2e82a25.js").then(be=>be.i),[]),J=await j.arrayBuffer();return(await G.extractRawText({arrayBuffer:J})).value}else if(j.name.endsWith(".doc"))throw new Error("请将.doc文件转换为.docx格式,或安装相应的解析库")}catch(G){throw new Error(`Office文档解析失败: ${G.message}`)}},H=async j=>{try{const G=await Gc(()=>import("./pdf-be81a221.js"),[]);G.GlobalWorkerOptions.workerSrc="/pdf.worker.min.mjs";const J=await j.arrayBuffer(),ne=await G.getDocument({data:J}).promise;let be="";for(let S=1;S<=ne.numPages;S++){const q=(await(await ne.getPage(S)).getTextContent()).items.map(B=>B.str).join(" ");be+=q+`
|
||
`}return be}catch(G){throw new Error(`PDF文件解析失败: ${G.message}`)}},oe=j=>j&&j.replace(/^好的[,,]?作为.*?专家[,,]?我已.*?分析.*?内容.*?生成了以下.*?思维导图[::]\s*/i,"").replace(/^好的[,,]?作为.*?专业的.*?专家[,,]?我已.*?分析.*?内容.*?生成了以下.*?思维导图[::]\s*/i,"").replace(/^以下是.*?结构化的.*?思维导图[::]\s*/i,"").replace(/^以下是.*?Markdown.*?思维导图[::]\s*/i,"").replace(/^以下是.*?Markdown.*?格式.*?思维导图[::]\s*/i,"").replace(/^```(?:markdown)?\s*/gm,"").replace(/```\s*$/gm,"").replace(/^「」`markdown\s*/gm,"").replace(/^「」`\s*/gm,"").replace(/^\s*「」`markdown\s*/gm,"").replace(/^\s*「」`\s*/gm,"").replace(/^作为.*?专家[,,]?我已.*?分析.*?内容.*?生成了以下.*?思维导图[::]\s*/i,"").replace(/^我已.*?分析.*?内容.*?生成了以下.*?思维导图[::]\s*/i,"").replace(/^根据.*?文档内容.*?生成了以下.*?思维导图[::]\s*/i,"").replace(/^基于.*?文档.*?生成了以下.*?思维导图[::]\s*/i,"").replace(/^以下是.*?分析.*?结果[::]\s*/i,"").replace(/^以下是.*?整理.*?结果[::]\s*/i,"").replace(/^以下是.*?结构化.*?内容[::]\s*/i,"").replace(/\n{3,}/g,`
|
||
|
||
`).trim(),me=async(j,G)=>{const ne=j||`你是一位Markdown格式转换专家。你的任务是将用户提供的文章内容精确转换为结构化的Markdown格式。请遵循以下步骤:
|
||
|
||
提取主标题: 识别文章最顶层的主标题(通常为文章题目或书名),并使用Markdown的 # 级别表示。
|
||
|
||
识别层级标题: 从文章内容中提取所有层级的内容标题(从主标题后的第一个标题开始,Level 1 至 Level 4)。判断层级依据:
|
||
|
||
视觉与结构特征: 如独立成行/段、位置(行首)、格式(加粗、编号如 1., 1.1, (1), - 等)。
|
||
|
||
语义逻辑: 标题之间的包含和并列关系。
|
||
|
||
在Markdown中,使用相应标题级别:
|
||
|
||
Level 1 标题用 ##
|
||
|
||
Level 2 标题用 ###
|
||
|
||
Level 3 标题用 ####
|
||
|
||
Level 4 标题用 #####
|
||
|
||
精确保留原文标题文字,不得修改、概括或润色。
|
||
|
||
处理正文内容: 对于每个标题下的正文内容区块(从该标题后开始,直到下一个同级或更高级别标题前):
|
||
|
||
直接保留原文文本,但根据内容结构适当格式化为Markdown。
|
||
|
||
如果内容是列表(如项目符号或编号列表),使用Markdown列表语法(例如 - 用于无序列表,1. 用于有序列表)。
|
||
|
||
保持段落和换行不变。
|
||
|
||
**重要:如果原文档中包含图片,请按以下方式处理:
|
||
1. 识别图片在文档中的位置和上下文
|
||
2. 根据图片内容生成准确的描述文字
|
||
3. 在相应位置插入图片占位符:
|
||
4. 图片描述要准确反映图片内容,图片路径可以是相对路径或占位符
|
||
5. 确保图片占位符放在逻辑上合适的位置**
|
||
|
||
输出格式: 输出必须是纯Markdown格式的文本,不得包含任何额外说明、JSON或非Markdown元素。确保输出与示例风格一致。直接输出Markdown内容,不要添加任何说明文字。`,be=G||"请将以下内容转换为结构化的Markdown格式:";try{const S=await fetch("http://127.0.0.1:8000/api/ai/generate-stream",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({system_prompt:ne,user_prompt:be,model:"glm-4.5",base_url:"https://open.bigmodel.cn/api/paas/v4/",api_key:"ce39bdd4fcf34ec0aec75072bc9ff988.hAp7HZTVUwy7vImn"})});if(!S.ok)throw new Error(`HTTP error! status: ${S.status}`);const C=S.body.getReader(),$=new TextDecoder;let q="",B=0;for(;;){const{done:U,value:Z}=await C.read();if(U)break;q+=$.decode(Z,{stream:!0});const ee=q.split(`
|
||
`);q=ee.pop()||"";for(const re of ee)if(re.startsWith("data: "))try{const K=JSON.parse(re.slice(6));if(K.type==="start")ge("AI开始生成内容...","info");else if(K.type==="chunk"){if(B++,s.value+=K.content,B%5===0)try{const le=oe(s.value),ae=Oe(le);a.value=JSON.stringify(ae,null,2),window.dispatchEvent(new CustomEvent("realtime-mindmap-update",{detail:{data:ae,title:ae.topic||"AI生成中...",source:"ai-streaming",chunkCount:B}}))}catch(le){console.warn("⚠️ 实时转换JSON失败:",le)}}else if(K.type==="end"){ge("AI内容生成完成!","success");try{const le=oe(s.value);console.log("🎯 最终内容长度:",le.length),console.log("🎯 最终内容预览:",le.substring(0,500)+"...");const ae=ze(le);console.log(`🖼️ 最终统计:共发现 ${ae.length} 张图片`);const pe=Oe(le);a.value=JSON.stringify(pe,null,2),window.dispatchEvent(new CustomEvent("realtime-mindmap-update",{detail:{data:pe,title:pe.topic||"AI生成完成",source:"ai-final",chunkCount:B}}))}catch(le){console.error("⚠️ 最终处理失败:",le)}}else if(K.type==="error")throw new Error(K.content)}catch(K){console.warn("解析流式数据失败:",K)}}}catch(S){throw console.error("流式AI API调用失败:",S),S}},ye=j=>{if(j.includes("|")&&j.includes("-")){const G=j.split(`
|
||
`);let J=!1,ne=!1;for(const be of G){const S=be.trim();S.includes("|")&&S.split("|").length>=3&&(J=!0),S.includes("|")&&S.includes("-")&&/^[\s\|\-\:]+$/.test(S)&&(ne=!0)}if(J&&ne)return console.log("🚫 formatMarkdownToText: 检测到表格内容,跳过转换"),j}return j.replace(/^### (.*$)/gim,"📋 $1").replace(/^## (.*$)/gim,"📌 $1").replace(/^# (.*$)/gim,"🎯 $1").replace(/\*\*(.*?)\*\*/g,(G,J)=>{if(J.includes(":")){const ne=J.split(":");if(ne.length>1)return`【${ne[0]}】: ${ne.slice(1).join(":")}`}return`【${J}】`}).replace(/\*(.*?)\*/g,"《$1》").replace(/^- (.*$)/gim," • $1").replace(/^\d+\. (.*$)/gim," $&").replace(/```(.*?)```/gims,"💻 $1").replace(/`(.*?)`/g,"「$1」").replace(/\[([^\]]+)\]\([^)]+\)/g,"🔗 $1").replace(/!\[([^\]]*)\]\(([^)]+)\)/g,"[图片: $1]").replace(/\n\n/g,`
|
||
`).replace(/\n/g,`
|
||
`).split(`
|
||
`).map(G=>G.length>80?G.substring(0,77)+"...":G).join(`
|
||
`).trim()},Le=async()=>{if(!s.value.trim()){ge("请输入Markdown内容","error");return}l.value=!0;try{const j=oe(s.value),G=Oe(j);a.value=JSON.stringify(G,null,2)}catch(j){console.error("转换失败:",j),ge("转换失败,请检查Markdown格式","error")}finally{l.value=!1}},ze=j=>{const G=/!\[([^\]]*)\]\(([^)]+)\)/g,J=[];let ne;for(;(ne=G.exec(j))!==null;){const be=ne[2],S=ne[1]||"";be&&be.trim()&&(be.startsWith("http")||be.startsWith("data:")||be.startsWith("/"))?(J.push({alt:S,url:be.trim(),fullMatch:ne[0]}),console.log(`✅ 有效图片URL: ${be}`)):console.warn(`⚠️ 跳过无效的图片URL: ${be}`)}return console.log(`🔍 从内容中提取到 ${J.length} 张图片:`,J),J},Ge=j=>j.replace(/!\[([^\]]*)\]\(([^)]+)\)/g,"").trim(),Oe=j=>{const G=j.split(`
|
||
`);let J=null;const ne=[];let be=0,S=[];if(G.forEach((C,$)=>{const q=C.trim(),B=q.match(/^(#{1,6})\s+(.+)$/);if(B){if(S.length>0&&ne.length>0){const le=S.join(`
|
||
`).trim();le&&(be=ke(le,ne[ne.length-1],be).nodeCounter),S=[]}const U=B[1].length,Z=B[2].trim(),ee=ze(Z),re=Ge(ye(Z));ee.length>0&&console.log(`🖼️ 在标题中发现 ${ee.length} 张图片: ${Z}`);const K={id:`node_${be++}`,topic:re,children:[],level:U,data:{}};if(ee.length>0){const le=ee[0];le.url&&le.url.trim()!==""?(K.image={url:le.url,width:200,height:150,fit:"contain"},console.log(`✅ 成功为标题节点设置图片: ${le.url}`)):console.error("❌ 标题图片URL无效:",le)}if(U===1&&!J)J=K,ne.length=0,ne.push(J);else{for(;ne.length>1&&ne[ne.length-1].level>=U;)ne.pop();ne.length>0&&ne[ne.length-1].children.push(K),ne.push(K)}}else q&&S.push(q)}),S.length>0&&ne.length>0){const C=S.join(`
|
||
`).trim();C&&(C.includes("|")&&console.log("🔍 处理最后的内容(包含表格):",C.substring(0,200)+"..."),be=ke(C,ne[ne.length-1],be).nodeCounter)}return J||(J={id:"root",topic:"根节点",children:[],data:{}}),J},ke=(j,G,J)=>{const ne=ze(j);if(ne.length>0){console.log(`🖼️ 在内容中发现 ${ne.length} 张图片`),ne.forEach((q,B)=>{console.log(`🖼️ 处理图片 ${B+1}:`,{alt:q.alt,url:q.url,urlLength:q.url.length});let U=q.url;U.includes("cdn-mineru.openxlab.org.cn")&&(U=`/proxy-image${U.replace("https://cdn-mineru.openxlab.org.cn","")}`,console.log(`🔄 转换图片URL: ${q.url} -> ${U}`));const Z={id:`node_${J++}`,topic:q.alt||`图片 ${B+1}`,children:[],level:(G.level||0)+1,image:{url:U,width:200,height:150,fit:"contain"},data:{}};if(!Z.image.url||Z.image.url.trim()===""){console.error(`❌ 图片节点 ${B+1} URL为空:`,Z);return}G.children.push(Z),console.log(`✅ 成功创建图片节点: ${Z.topic} - ${U}`)});const $=Ge(j);return $.trim()&&(J=ke($,G,J).nodeCounter),{nodeCounter:J}}if(he(j)){console.log("🎯 检测到表格内容,创建表格节点");const $=E0(j);console.log("🎯 表格HTML内容:",$);const q={id:`node_${J++}`,topic:"",dangerouslySetInnerHTML:$,children:[],level:(G.level||0)+1,data:{}};return G.children.push(q),{nodeCounter:J}}const be=j.split(`
|
||
`);let S=J,C=[];for(let $=0;$<be.length;$++){const B=be[$].trim(),U=B.match(/^[-*+]\s*【(.+)】/);if(U){const Z=U[1].trim(),ee={id:`node_${S++}`,topic:Z,children:[],level:(G.level||0)+1,data:{}};let re=[],K=$+1;for(;K<be.length;){const le=be[K].trim();if(le.match(/^[-*+]\s*【(.+)】/))break;const pe=le.match(/^[-*+]\s+(.+)$/);if(pe){const Se=pe[1].trim(),Re=ye(Se);re.push("• "+Re)}K++}if(re.length>0){const le=ye(re.join(`
|
||
`));ee.topic=ee.topic+`
|
||
|
||
`+le}G.children.push(ee),$=K-1}else B&&C.push(B)}if(C.length>0){const $=C.join(`
|
||
`).trim();if($)if(he($)){console.log("🎯 检测到表格内容,创建表格节点");const q=E0($);console.log("🎯 表格HTML内容:",q);const B={id:`node_${S++}`,topic:"",dangerouslySetInnerHTML:q,children:[],level:(G.level||0)+1,data:{}};G.children.push(B)}else $.split(`
|
||
|
||
`).filter(B=>B.trim()).forEach(B=>{const U=ye(B.trim());if(U){const Z={id:`node_${S++}`,topic:U,children:[],level:(G.level||0)+1,data:{}};G.children.push(Z)}})}return{nodeCounter:S}},he=j=>{if(!j||typeof j!="string")return!1;if(j.includes("<table")||j.includes("<tr")||j.includes("<td"))return console.log("🔍 检测到HTML表格内容"),!0;j.includes("|")&&console.log("🔍 检查Markdown表格内容:",j.substring(0,200)+"...");const J=j.split(`
|
||
`);let ne=!1,be=!1;for(const q of J){const B=q.trim();B.includes("|")&&B.split("|").length>=3&&(ne=!0,console.log("✅ 找到表格行:",B)),B.includes("|")&&B.includes("-")&&/^[\s\|\-\:]+$/.test(B)&&(be=!0,console.log("✅ 找到分隔符行:",B))}const S=(j.match(/\|/g)||[]).length,C=S>=4,$=ne&&be||ne&&C;return console.log("🔍 表格检测结果:",{hasTableRow:ne,hasSeparator:be,pipeCount:S,hasMultiplePipes:C,result:$}),$},je=async()=>{if(!s.value){ge("没有Markdown内容可复制","error");return}try{await navigator.clipboard.writeText(s.value),ge("Markdown已复制到剪贴板","success")}catch{const G=document.createElement("textarea");G.value=s.value,document.body.appendChild(G),G.select(),document.execCommand("copy"),G.remove(),ge("Markdown已复制到剪贴板","success")}},Ke=async()=>{try{await navigator.clipboard.writeText(a.value),ge("JSON已复制到剪贴板","success")}catch(j){console.error("复制失败:",j),ge("复制失败","error")}},Be=async()=>{if(!a.value){ge("请先生成或转换JSON数据","error");return}try{const j=JSON.parse(a.value),G=j.topic||j.title||`AI生成的思维导图_${new Date().toLocaleString()}`,J=new CustomEvent("save-preview-to-database",{detail:{data:j,title:G,source:"ai-generated",timestamp:Date.now()}});window.dispatchEvent(J),setTimeout(()=>{ge("思维导图已保存成功!","success"),b.value=null,g.value&&(g.value.value="")},2e3)}catch(j){console.error("JSON解析失败:",j),ge("JSON格式错误,请检查数据","error")}},ge=(j,G="info")=>{const J=document.createElement("div");switch(J.className=`notification notification-${G}`,J.textContent=j,J.style.cssText=`
|
||
position: fixed;
|
||
top: 20px;
|
||
right: 20px;
|
||
padding: 12px 20px;
|
||
border-radius: 8px;
|
||
font-size: 14px;
|
||
font-weight: 500;
|
||
z-index: 10000;
|
||
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
|
||
animation: slideIn 0.3s ease;
|
||
max-width: 300px;
|
||
word-wrap: break-word;
|
||
`,G){case"success":J.style.background="#4CAF50",J.style.color="white";break;case"error":J.style.background="#f44336",J.style.color="white";break;case"info":default:J.style.background="#2196F3",J.style.color="white";break}if(!document.querySelector("#notification-styles")){const ne=document.createElement("style");ne.id="notification-styles",ne.textContent=`
|
||
@keyframes slideIn {
|
||
from { transform: translateX(100%); opacity: 0; }
|
||
to { transform: translateX(0); opacity: 1; }
|
||
}
|
||
@keyframes slideOut {
|
||
from { transform: translateX(0); opacity: 1; }
|
||
to { transform: translateX(100%); opacity: 0; }
|
||
}
|
||
`,document.head.appendChild(ne)}document.body.appendChild(J),setTimeout(()=>{J.style.animation="slideOut 0.3s ease",setTimeout(()=>{J.parentNode&&J.parentNode.removeChild(J)},300)},3e3)},Ft=()=>{s.value="",a.value="",ge("内容已清空","info")},ht=(j,G,J=null)=>{const ne={title:j,content:G,mindmapId:J,timestamp:new Date};c.value.unshift(ne),c.value.length>10&&(c.value=c.value.slice(0,10)),localStorage.setItem("ai-sidebar-history",JSON.stringify(c.value))},yt=async j=>{j.mindmapId?window.dispatchEvent(new CustomEvent("loadMindmapFromHistory",{detail:{mindmapId:j.mindmapId,title:j.title}})):(s.value=j.content,await Le(),window.dispatchEvent(new CustomEvent("loadMindmapFromHistory",{detail:{markdown:j.content,json:a.value,title:j.title}})))},St=j=>new Date(j).toLocaleString("zh-CN");Ka(()=>{const j=localStorage.getItem("ai-sidebar-history");if(j)try{c.value=JSON.parse(j)}catch(G){console.error("加载历史记录失败:",G)}window.addEventListener("add-to-history",G=>{const{title:J,content:ne,timestamp:be}=G.detail;ht(J,ne,null)}),window.addEventListener("mindmap-saved",G=>{const{mindmapId:J,title:ne,timestamp:be}=G.detail,S=c.value.find(C=>C.title===ne||C.timestamp&&Math.abs(C.timestamp-be)<5e3);S?(S.mindmapId=J,localStorage.setItem("ai-sidebar-history",JSON.stringify(c.value))):ht(ne,"",J)}),p0(i,(G,J)=>{}),p0(s,(G,J)=>{})});const lt=async()=>{try{const j=await fetch("http://127.0.0.1:8000/api/ai/test-stream",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({test:"data"})});if(!j.ok)throw new Error(`HTTP error! status: ${j.status}`);const G=j.body.getReader(),J=new TextDecoder;let ne="";for(;;){const{done:be,value:S}=await G.read();if(be)break;ne+=J.decode(S,{stream:!0});const C=ne.split(`
|
||
`);ne=C.pop()||"";for(const $ of C)if($.startsWith("data: "))try{const q=JSON.parse($.slice(6))}catch(q){console.warn("解析测试数据失败:",q)}}}catch(j){console.error("❌ 测试流式API失败:",j)}};return window.testStreamAPI=lt,(j,G)=>(Fe(),He("div",W7,[Y("div",{class:"sidebar-toggle",onClick:x,title:n.value?"展开AI助手":"折叠AI助手",style:jn({left:n.value?"10px":"420px"})},[n.value?(Fe(),He("svg",K7,[...G[1]||(G[1]=[Y("path",{d:"M9 18l6-6-6-6"},null,-1)])])):(Fe(),He("svg",Y7,[...G[2]||(G[2]=[Y("path",{d:"M15 18l-6-6 6-6"},null,-1)])]))],12,G7),Y("div",{class:Un(["ai-sidebar",{"sidebar-collapsed":n.value}])},[Ai(Y("div",X7,[G[12]||(G[12]=Y("div",{class:"sidebar-header"},[Y("h3",null,"🤖 AI 助手"),Y("p",null,"文档转思维导图工具"),Y("div",{class:"collapse-hint"},[Y("small",null,"💡 点击右侧按钮可折叠侧边栏")])],-1)),Y("div",J7,[G[6]||(G[6]=Y("h4",null,"📁 生成思维导图",-1)),Y("div",Z7,[G[4]||(G[4]=Y("label",null,"上传文件:",-1)),Y("div",{class:"file-upload-area",onDrop:N,onDragover:y,onDragleave:k},[Y("input",{type:"file",ref_key:"fileInput",ref:g,onChange:w,accept:".txt,.md,.doc,.docx,.pdf",class:"file-input"},null,544),Y("div",{class:Un(["file-upload-placeholder",{"drag-over":u.value}])},[...G[3]||(G[3]=[Y("span",{class:"upload-icon"},"📎",-1),Y("span",{class:"upload-text"},"点击选择文件或拖拽文件到此处",-1),Y("span",{class:"upload-hint"},"支持 .txt, .md, .doc, .docx, .pdf 格式",-1)])],2)],32)]),b.value?(Fe(),He("div",Q7,[Y("div",eg,[Y("div",tg,[Y("span",rg,"📄 "+Zt(b.value.name),1),Y("span",ng,"("+Zt(D(b.value.size))+")",1)]),Y("button",{onClick:I,class:"btn-remove",title:"删除文件"},[...G[5]||(G[5]=[Y("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"},[Y("path",{d:"M3 6h18M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6m3 0V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2M10 11v6M14 11v6"})],-1)])])])])):yr("",!0),Y("div",ig,[Y("button",{onClick:O,disabled:!b.value||o.value,class:"btn-primary"},[o.value?(Fe(),He("span",ag,"AI生成中...")):(Fe(),He("span",og,"AI生成思维导图"))],8,sg)])]),c.value.length>0?(Fe(),He("div",lg,[G[7]||(G[7]=Y("h4",null,"📚 历史记录",-1)),Y("div",cg,[(Fe(!0),He(ur,null,Mu(c.value,(J,ne)=>(Fe(),He("div",{key:ne,class:"history-item",onClick:be=>yt(J)},[Y("div",dg,Zt(J.title),1),Y("div",hg,Zt(St(J.timestamp)),1)],8,ug))),128))])])):yr("",!0),Y("div",fg,[G[9]||(G[9]=Y("h4",null,"📝 AI生成的Markdown结果",-1)),Y("div",pg,[G[8]||(G[8]=Y("label",null,"Markdown内容:",-1)),Ai(Y("textarea",{"onUpdate:modelValue":G[0]||(G[0]=J=>s.value=J),placeholder:"AI生成的Markdown内容将显示在这里",rows:"6",readonly:"",class:"markdown-result"},null,512),[[eo,s.value]])]),Y("div",mg,[Y("button",{onClick:Le,disabled:l.value,class:"btn-secondary"},[l.value?(Fe(),He("span",vg,"转换中...")):(Fe(),He("span",bg,"🔄 转换为JSON"))],8,gg),Y("button",{onClick:Ft,class:"btn-clear"},"清空"),Y("button",{onClick:je,class:"btn-copy"},"📋 复制Markdown")])]),Y("div",yg,[G[11]||(G[11]=Y("h4",null,"📊 Markdown转JSON结果",-1)),f.value?(Fe(),He("div",wg,[G[10]||(G[10]=Y("div",{class:"spinner"},null,-1)),Y("span",null,Zt(p.value),1)])):yr("",!0),Y("div",xg,[Y("pre",kg,Zt(a.value||"JSON转换结果将显示在这里"),1),Y("div",Sg,[Y("button",{onClick:Ke,class:"btn-copy"},"📋 复制JSON"),Y("button",{onClick:Be,disabled:f.value,class:"btn-copy"},Zt(f.value?"处理中...":"👁️ 预览"),9,Tg)])])])],512),[[tp,!n.value]])],2)]))}},Eg=Go(Ag,[["__scopeId","data-v-28c77d5e"]]);const Cg={class:"markdown-test"},Mg={class:"test-section"},Ng={class:"test-section"},Ig=["innerHTML"],Rg={class:"test-section"},Dg={class:"test-cases"},Og=["onClick"],_g={__name:"MarkdownTest",setup(t){const e=De(`# 测试标题
|
||
|
||
这是一个**粗体**和*斜体*的测试。
|
||
|
||
## 表格测试
|
||
|
||
| 产品 | 价格 | 库存 |
|
||
|------|------|------|
|
||
| 苹果 | 4元 | 100个 |
|
||
| 香蕉 | 2元 | 50个 |
|
||
|
||
## 代码测试
|
||
|
||
\`\`\`javascript
|
||
function hello() {
|
||
console.log('Hello World!');
|
||
}
|
||
\`\`\`
|
||
|
||
行内代码:\`const name = 'test'\`
|
||
|
||
## 列表测试
|
||
|
||
- 项目1
|
||
- 项目2
|
||
- 子项目2.1
|
||
- 子项目2.2
|
||
- 项目3
|
||
|
||
## 链接测试
|
||
|
||
- [GitHub](https://github.com)
|
||
- [Vue.js](https://vuejs.org)`),r=De([{name:"基础表格",content:`# 产品价格表
|
||
|
||
| 产品 | 价格 |
|
||
|------|------|
|
||
| 苹果 | 4元 |
|
||
| 香蕉 | 2元 |`},{name:"复杂表格",content:`# 技术栈对比
|
||
|
||
| 技术 | 前端 | 后端 | 数据库 |
|
||
|------|------|------|--------|
|
||
| Vue.js | ✅ | ❌ | ❌ |
|
||
| Django | ❌ | ✅ | ❌ |
|
||
| PostgreSQL | ❌ | ❌ | ✅ |`},{name:"代码块",content:`# 代码示例
|
||
|
||
\`\`\`javascript
|
||
function markdownToJSON(markdown) {
|
||
const lines = markdown.split('\\n');
|
||
// 处理逻辑...
|
||
return result;
|
||
}
|
||
\`\`\``},{name:"混合内容",content:`# 混合内容测试
|
||
|
||
这是一个包含**粗体**、*斜体*和\`行内代码\`的段落。
|
||
|
||
## 表格
|
||
|
||
| 功能 | 状态 | 说明 |
|
||
|------|------|------|
|
||
| 表格渲染 | ✅ | 支持markdown表格 |
|
||
| 代码高亮 | ✅ | 支持代码块 |
|
||
|
||
## 代码
|
||
|
||
\`\`\`python
|
||
def hello_world():
|
||
print("Hello, World!")
|
||
\`\`\``}]),n=Ju(()=>{if(!e.value)return"";try{return E0(e.value)}catch(a){return`<div class="error">渲染失败: ${a.message}</div>`}}),i=()=>{},s=a=>{e.value=a.content};return(a,o)=>(Fe(),He("div",Cg,[o[4]||(o[4]=Y("h2",null,"Markdown渲染测试",-1)),Y("div",Mg,[o[1]||(o[1]=Y("h3",null,"输入Markdown内容",-1)),Ai(Y("textarea",{"onUpdate:modelValue":o[0]||(o[0]=l=>e.value=l),placeholder:"输入markdown内容...",rows:"10",class:"markdown-input"},null,512),[[eo,e.value]])]),Y("div",Ng,[o[2]||(o[2]=Y("h3",null,"渲染结果",-1)),Y("div",{class:"rendered-content",innerHTML:n.value},null,8,Ig)]),Y("div",Rg,[o[3]||(o[3]=Y("h3",null,"测试用例",-1)),Y("button",{onClick:i,class:"test-btn"},"加载测试用例"),Y("div",Dg,[(Fe(!0),He(ur,null,Mu(r.value,(l,c)=>(Fe(),He("button",{key:c,onClick:u=>s(l),class:"test-case-btn"},Zt(l.name),9,Og))),128))])])]))}},Lg=Go(_g,[["__scopeId","data-v-68a00828"]]);const zg={id:"app"},$g={class:"test-mode-toggle",style:{display:"none"}},Fg={key:0,class:"test-mode"},Bg={key:1},Pg={class:"main-content"},Hg={__name:"App",setup(t){const e=De(null),r=De(!1),n=()=>{r.value=!r.value},i=()=>{e.value&&e.value.showMindMapPage()};return(s,a)=>(Fe(),He("div",zg,[a[0]||(a[0]=Ku("« ",-1)),Y("div",$g,[Y("button",{onClick:n,class:"test-btn"},Zt(r.value?"切换到思维导图":"测试Markdown渲染"),1)]),r.value?(Fe(),He("div",Fg,[Xt(Lg)])):(Fe(),He("div",Bg,[Xt(Eg,{onStartRealtimeGeneration:i}),Y("div",Pg,[Xt(j7,{ref_key:"mindMapRef",ref:e},null,512)])]))]))}};xp(Hg).mount("#app");export{Gc as _,cc as c,Ug as g};
|