607 lines
578 KiB
JavaScript
607 lines
578 KiB
JavaScript
var Id=Object.defineProperty;var _d=(t,e,r)=>e in t?Id(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var Ge=(t,e,r)=>(_d(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 s of document.querySelectorAll('link[rel="modulepreload"]'))n(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const a of i.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&n(a)}).observe(document,{childList:!0,subtree:!0});function r(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function n(s){if(s.ep)return;s.ep=!0;const i=r(s);fetch(s.href,i)}})();/**
|
||
* @vue/shared v3.5.20
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**//*! #__NO_SIDE_EFFECTS__ */function wa(t){const e=Object.create(null);for(const r of t.split(","))e[r]=1;return r=>r in e}const Ye={},Cn=[],tr=()=>{},Rc=()=>!1,Rs=t=>t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&(t.charCodeAt(2)>122||t.charCodeAt(2)<97),xa=t=>t.startsWith("onUpdate:"),yt=Object.assign,ka=(t,e)=>{const r=t.indexOf(e);r>-1&&t.splice(r,1)},Od=Object.prototype.hasOwnProperty,He=(t,e)=>Od.call(t,e),Ce=Array.isArray,Mn=t=>Is(t)==="[object Map]",Ic=t=>Is(t)==="[object Set]",De=t=>typeof t=="function",ut=t=>typeof t=="string",Zr=t=>typeof t=="symbol",it=t=>t!==null&&typeof t=="object",_c=t=>(it(t)||De(t))&&De(t.then)&&De(t.catch),Oc=Object.prototype.toString,Is=t=>Oc.call(t),Ld=t=>Is(t).slice(8,-1),Lc=t=>Is(t)==="[object Object]",Sa=t=>ut(t)&&t!=="NaN"&&t[0]!=="-"&&""+parseInt(t,10)===t,Qn=wa(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),_s=t=>{const e=Object.create(null);return r=>e[r]||(e[r]=t(r))},zd=/-(\w)/g,Wr=_s(t=>t.replace(zd,(e,r)=>r?r.toUpperCase():"")),Fd=/\B([A-Z])/g,Qr=_s(t=>t.replace(Fd,"-$1").toLowerCase()),zc=_s(t=>t.charAt(0).toUpperCase()+t.slice(1)),ii=_s(t=>t?`on${zc(t)}`:""),Vr=(t,e)=>!Object.is(t,e),K0=(t,...e)=>{for(let r=0;r<t.length;r++)t[r](...e)},Fc=(t,e,r,n=!1)=>{Object.defineProperty(t,e,{configurable:!0,enumerable:!1,writable:n,value:r})},$i=t=>{const e=parseFloat(t);return isNaN(e)?t:e};let zo;const Os=()=>zo||(zo=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function On(t){if(Ce(t)){const e={};for(let r=0;r<t.length;r++){const n=t[r],s=ut(n)?Hd(n):On(n);if(s)for(const i in s)e[i]=s[i]}return e}else if(ut(t)||it(t))return t}const $d=/;(?![^(]*\))/g,Bd=/:([^]+)/,Pd=/\/\*[^]*?\*\//g;function Hd(t){const e={};return t.replace(Pd,"").split($d).forEach(r=>{if(r){const n=r.split(Bd);n.length>1&&(e[n[0].trim()]=n[1].trim())}}),e}function Ln(t){let e="";if(ut(t))e=t;else if(Ce(t))for(let r=0;r<t.length;r++){const n=Ln(t[r]);n&&(e+=n+" ")}else if(it(t))for(const r in t)t[r]&&(e+=r+" ");return e.trim()}const qd="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",jd=wa(qd);function $c(t){return!!t||t===""}const Bc=t=>!!(t&&t.__v_isRef===!0),ur=t=>ut(t)?t:t==null?"":Ce(t)||it(t)&&(t.toString===Oc||!De(t.toString))?Bc(t)?ur(t.value):JSON.stringify(t,Pc,2):String(t),Pc=(t,e)=>Bc(e)?Pc(t,e.value):Mn(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((r,[n,s],i)=>(r[ai(n,i)+" =>"]=s,r),{})}:Ic(e)?{[`Set(${e.size})`]:[...e.values()].map(r=>ai(r))}:Zr(e)?ai(e):it(e)&&!Ce(e)&&!Lc(e)?String(e):e,ai=(t,e="")=>{var r;return Zr(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 It;class Ud{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=It,!e&&It&&(this.index=(It.scopes||(It.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=It;try{return It=this,e()}finally{It=r}}}on(){++this._on===1&&(this.prevScope=It,It=this)}off(){this._on>0&&--this._on===0&&(It=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 s=this.parent.scopes.pop();s&&s!==this&&(this.parent.scopes[this.index]=s,s.index=this.index)}this.parent=void 0}}}function Vd(){return It}let Ze;const oi=new WeakSet;class Hc{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,It&&It.active&&It.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,oi.has(this)&&(oi.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||jc(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Fo(this),Uc(this);const e=Ze,r=rr;Ze=this,rr=!0;try{return this.fn()}finally{Vc(this),Ze=e,rr=r,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)Ea(e);this.deps=this.depsTail=void 0,Fo(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?oi.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Bi(this)&&this.run()}get dirty(){return Bi(this)}}let qc=0,e0,t0;function jc(t,e=!1){if(t.flags|=8,e){t.next=t0,t0=t;return}t.next=e0,e0=t}function Ta(){qc++}function Aa(){if(--qc>0)return;if(t0){let e=t0;for(t0=void 0;e;){const r=e.next;e.next=void 0,e.flags&=-9,e=r}}let t;for(;e0;){let e=e0;for(e0=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 Uc(t){for(let e=t.deps;e;e=e.nextDep)e.version=-1,e.prevActiveLink=e.dep.activeLink,e.dep.activeLink=e}function Vc(t){let e,r=t.depsTail,n=r;for(;n;){const s=n.prevDep;n.version===-1?(n===r&&(r=s),Ea(n),Wd(n)):e=n,n.dep.activeLink=n.prevActiveLink,n.prevActiveLink=void 0,n=s}t.deps=e,t.depsTail=r}function Bi(t){for(let e=t.deps;e;e=e.nextDep)if(e.dep.version!==e.version||e.dep.computed&&(Wc(e.dep.computed)||e.dep.version!==e.version))return!0;return!!t._dirty}function Wc(t){if(t.flags&4&&!(t.flags&16)||(t.flags&=-17,t.globalVersion===c0)||(t.globalVersion=c0,!t.isSSR&&t.flags&128&&(!t.deps&&!t._dirty||!Bi(t))))return;t.flags|=2;const e=t.dep,r=Ze,n=rr;Ze=t,rr=!0;try{Uc(t);const s=t.fn(t._value);(e.version===0||Vr(s,t._value))&&(t.flags|=128,t._value=s,e.version++)}catch(s){throw e.version++,s}finally{Ze=r,rr=n,Vc(t),t.flags&=-3}}function Ea(t,e=!1){const{dep:r,prevSub:n,nextSub:s}=t;if(n&&(n.nextSub=s,t.prevSub=void 0),s&&(s.prevSub=n,t.nextSub=void 0),r.subs===t&&(r.subs=n,!n&&r.computed)){r.computed.flags&=-5;for(let i=r.computed.deps;i;i=i.nextDep)Ea(i,!0)}!e&&!--r.sc&&r.map&&r.map.delete(r.key)}function Wd(t){const{prevDep:e,nextDep:r}=t;e&&(e.nextDep=r,t.prevDep=void 0),r&&(r.prevDep=e,t.nextDep=void 0)}let rr=!0;const Gc=[];function Rr(){Gc.push(rr),rr=!1}function Ir(){const t=Gc.pop();rr=t===void 0?!0:t}function Fo(t){const{cleanup:e}=t;if(t.cleanup=void 0,e){const r=Ze;Ze=void 0;try{e()}finally{Ze=r}}}let c0=0;class Gd{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 Ca{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(!Ze||!rr||Ze===this.computed)return;let r=this.activeLink;if(r===void 0||r.sub!==Ze)r=this.activeLink=new Gd(Ze,this),Ze.deps?(r.prevDep=Ze.depsTail,Ze.depsTail.nextDep=r,Ze.depsTail=r):Ze.deps=Ze.depsTail=r,Kc(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=Ze.depsTail,r.nextDep=void 0,Ze.depsTail.nextDep=r,Ze.depsTail=r,Ze.deps===r&&(Ze.deps=n)}return r}trigger(e){this.version++,c0++,this.notify(e)}notify(e){Ta();try{for(let r=this.subs;r;r=r.prevSub)r.sub.notify()&&r.sub.dep.notify()}finally{Aa()}}}function Kc(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)Kc(n)}const r=t.dep.subs;r!==t&&(t.prevSub=r,r&&(r.nextSub=t)),t.dep.subs=t}}const Pi=new WeakMap,hn=Symbol(""),Hi=Symbol(""),u0=Symbol("");function wt(t,e,r){if(rr&&Ze){let n=Pi.get(t);n||Pi.set(t,n=new Map);let s=n.get(r);s||(n.set(r,s=new Ca),s.map=n,s.key=r),s.track()}}function Ar(t,e,r,n,s,i){const a=Pi.get(t);if(!a){c0++;return}const o=l=>{l&&l.trigger()};if(Ta(),e==="clear")a.forEach(o);else{const l=Ce(t),c=l&&Sa(r);if(l&&r==="length"){const d=Number(n);a.forEach((f,p)=>{(p==="length"||p===u0||!Zr(p)&&p>=d)&&o(f)})}else switch((r!==void 0||a.has(void 0))&&o(a.get(r)),c&&o(a.get(u0)),e){case"add":l?c&&o(a.get("length")):(o(a.get(hn)),Mn(t)&&o(a.get(Hi)));break;case"delete":l||(o(a.get(hn)),Mn(t)&&o(a.get(Hi)));break;case"set":Mn(t)&&o(a.get(hn));break}}Aa()}function wn(t){const e=Pe(t);return e===t?e:(wt(e,"iterate",u0),Wt(t)?e:e.map(bt))}function Ls(t){return wt(t=Pe(t),"iterate",u0),t}const Kd={__proto__:null,[Symbol.iterator](){return li(this,Symbol.iterator,bt)},concat(...t){return wn(this).concat(...t.map(e=>Ce(e)?wn(e):e))},entries(){return li(this,"entries",t=>(t[1]=bt(t[1]),t))},every(t,e){return wr(this,"every",t,e,void 0,arguments)},filter(t,e){return wr(this,"filter",t,e,r=>r.map(bt),arguments)},find(t,e){return wr(this,"find",t,e,bt,arguments)},findIndex(t,e){return wr(this,"findIndex",t,e,void 0,arguments)},findLast(t,e){return wr(this,"findLast",t,e,bt,arguments)},findLastIndex(t,e){return wr(this,"findLastIndex",t,e,void 0,arguments)},forEach(t,e){return wr(this,"forEach",t,e,void 0,arguments)},includes(...t){return ci(this,"includes",t)},indexOf(...t){return ci(this,"indexOf",t)},join(t){return wn(this).join(t)},lastIndexOf(...t){return ci(this,"lastIndexOf",t)},map(t,e){return wr(this,"map",t,e,void 0,arguments)},pop(){return jn(this,"pop")},push(...t){return jn(this,"push",t)},reduce(t,...e){return $o(this,"reduce",t,e)},reduceRight(t,...e){return $o(this,"reduceRight",t,e)},shift(){return jn(this,"shift")},some(t,e){return wr(this,"some",t,e,void 0,arguments)},splice(...t){return jn(this,"splice",t)},toReversed(){return wn(this).toReversed()},toSorted(t){return wn(this).toSorted(t)},toSpliced(...t){return wn(this).toSpliced(...t)},unshift(...t){return jn(this,"unshift",t)},values(){return li(this,"values",bt)}};function li(t,e,r){const n=Ls(t),s=n[e]();return n!==t&&!Wt(t)&&(s._next=s.next,s.next=()=>{const i=s._next();return i.value&&(i.value=r(i.value)),i}),s}const Yd=Array.prototype;function wr(t,e,r,n,s,i){const a=Ls(t),o=a!==t&&!Wt(t),l=a[e];if(l!==Yd[e]){const f=l.apply(t,i);return o?bt(f):f}let c=r;a!==t&&(o?c=function(f,p){return r.call(this,bt(f),p,t)}:r.length>2&&(c=function(f,p){return r.call(this,f,p,t)}));const d=l.call(a,c,n);return o&&s?s(d):d}function $o(t,e,r,n){const s=Ls(t);let i=r;return s!==t&&(Wt(t)?r.length>3&&(i=function(a,o,l){return r.call(this,a,o,l,t)}):i=function(a,o,l){return r.call(this,a,bt(o),l,t)}),s[e](i,...n)}function ci(t,e,r){const n=Pe(t);wt(n,"iterate",u0);const s=n[e](...r);return(s===-1||s===!1)&&Ra(r[0])?(r[0]=Pe(r[0]),n[e](...r)):s}function jn(t,e,r=[]){Rr(),Ta();const n=Pe(t)[e].apply(t,r);return Aa(),Ir(),n}const Xd=wa("__proto__,__v_isRef,__isVue"),Yc=new Set(Object.getOwnPropertyNames(Symbol).filter(t=>t!=="arguments"&&t!=="caller").map(t=>Symbol[t]).filter(Zr));function Jd(t){Zr(t)||(t=String(t));const e=Pe(this);return wt(e,"has",t),e.hasOwnProperty(t)}class Xc{constructor(e=!1,r=!1){this._isReadonly=e,this._isShallow=r}get(e,r,n){if(r==="__v_skip")return e.__v_skip;const s=this._isReadonly,i=this._isShallow;if(r==="__v_isReactive")return!s;if(r==="__v_isReadonly")return s;if(r==="__v_isShallow")return i;if(r==="__v_raw")return n===(s?i?oh:eu:i?Qc:Zc).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;const a=Ce(e);if(!s){let l;if(a&&(l=Kd[r]))return l;if(r==="hasOwnProperty")return Jd}const o=Reflect.get(e,r,kt(e)?e:n);return(Zr(r)?Yc.has(r):Xd(r))||(s||wt(e,"get",r),i)?o:kt(o)?a&&Sa(r)?o:o.value:it(o)?s?tu(o):Na(o):o}}class Jc extends Xc{constructor(e=!1){super(!1,e)}set(e,r,n,s){let i=e[r];if(!this._isShallow){const l=Gr(i);if(!Wt(n)&&!Gr(n)&&(i=Pe(i),n=Pe(n)),!Ce(e)&&kt(i)&&!kt(n))return l||(i.value=n),!0}const a=Ce(e)&&Sa(r)?Number(r)<e.length:He(e,r),o=Reflect.set(e,r,n,kt(e)?e:s);return e===Pe(s)&&(a?Vr(n,i)&&Ar(e,"set",r,n):Ar(e,"add",r,n)),o}deleteProperty(e,r){const n=He(e,r);e[r];const s=Reflect.deleteProperty(e,r);return s&&n&&Ar(e,"delete",r,void 0),s}has(e,r){const n=Reflect.has(e,r);return(!Zr(r)||!Yc.has(r))&&wt(e,"has",r),n}ownKeys(e){return wt(e,"iterate",Ce(e)?"length":hn),Reflect.ownKeys(e)}}class Zd extends Xc{constructor(e=!1){super(!0,e)}set(e,r){return!0}deleteProperty(e,r){return!0}}const Qd=new Jc,eh=new Zd,th=new Jc(!0);const qi=t=>t,N0=t=>Reflect.getPrototypeOf(t);function rh(t,e,r){return function(...n){const s=this.__v_raw,i=Pe(s),a=Mn(i),o=t==="entries"||t===Symbol.iterator&&a,l=t==="keys"&&a,c=s[t](...n),d=r?qi:e?os:bt;return!e&&wt(i,"iterate",l?Hi:hn),{next(){const{value:f,done:p}=c.next();return p?{value:f,done:p}:{value:o?[d(f[0]),d(f[1])]:d(f),done:p}},[Symbol.iterator](){return this}}}}function D0(t){return function(...e){return t==="delete"?!1:t==="clear"?void 0:this}}function nh(t,e){const r={get(s){const i=this.__v_raw,a=Pe(i),o=Pe(s);t||(Vr(s,o)&&wt(a,"get",s),wt(a,"get",o));const{has:l}=N0(a),c=e?qi:t?os:bt;if(l.call(a,s))return c(i.get(s));if(l.call(a,o))return c(i.get(o));i!==a&&i.get(s)},get size(){const s=this.__v_raw;return!t&&wt(Pe(s),"iterate",hn),s.size},has(s){const i=this.__v_raw,a=Pe(i),o=Pe(s);return t||(Vr(s,o)&&wt(a,"has",s),wt(a,"has",o)),s===o?i.has(s):i.has(s)||i.has(o)},forEach(s,i){const a=this,o=a.__v_raw,l=Pe(o),c=e?qi:t?os:bt;return!t&&wt(l,"iterate",hn),o.forEach((d,f)=>s.call(i,c(d),c(f),a))}};return yt(r,t?{add:D0("add"),set:D0("set"),delete:D0("delete"),clear:D0("clear")}:{add(s){!e&&!Wt(s)&&!Gr(s)&&(s=Pe(s));const i=Pe(this);return N0(i).has.call(i,s)||(i.add(s),Ar(i,"add",s,s)),this},set(s,i){!e&&!Wt(i)&&!Gr(i)&&(i=Pe(i));const a=Pe(this),{has:o,get:l}=N0(a);let c=o.call(a,s);c||(s=Pe(s),c=o.call(a,s));const d=l.call(a,s);return a.set(s,i),c?Vr(i,d)&&Ar(a,"set",s,i):Ar(a,"add",s,i),this},delete(s){const i=Pe(this),{has:a,get:o}=N0(i);let l=a.call(i,s);l||(s=Pe(s),l=a.call(i,s)),o&&o.call(i,s);const c=i.delete(s);return l&&Ar(i,"delete",s,void 0),c},clear(){const s=Pe(this),i=s.size!==0,a=s.clear();return i&&Ar(s,"clear",void 0,void 0),a}}),["keys","values","entries",Symbol.iterator].forEach(s=>{r[s]=rh(s,t,e)}),r}function Ma(t,e){const r=nh(t,e);return(n,s,i)=>s==="__v_isReactive"?!t:s==="__v_isReadonly"?t:s==="__v_raw"?n:Reflect.get(He(r,s)&&s in n?r:n,s,i)}const sh={get:Ma(!1,!1)},ih={get:Ma(!1,!0)},ah={get:Ma(!0,!1)};const Zc=new WeakMap,Qc=new WeakMap,eu=new WeakMap,oh=new WeakMap;function lh(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function ch(t){return t.__v_skip||!Object.isExtensible(t)?0:lh(Ld(t))}function Na(t){return Gr(t)?t:Da(t,!1,Qd,sh,Zc)}function uh(t){return Da(t,!1,th,ih,Qc)}function tu(t){return Da(t,!0,eh,ah,eu)}function Da(t,e,r,n,s){if(!it(t)||t.__v_raw&&!(e&&t.__v_isReactive))return t;const i=ch(t);if(i===0)return t;const a=s.get(t);if(a)return a;const o=new Proxy(t,i===2?n:r);return s.set(t,o),o}function Nn(t){return Gr(t)?Nn(t.__v_raw):!!(t&&t.__v_isReactive)}function Gr(t){return!!(t&&t.__v_isReadonly)}function Wt(t){return!!(t&&t.__v_isShallow)}function Ra(t){return t?!!t.__v_raw:!1}function Pe(t){const e=t&&t.__v_raw;return e?Pe(e):t}function dh(t){return!He(t,"__v_skip")&&Object.isExtensible(t)&&Fc(t,"__v_skip",!0),t}const bt=t=>it(t)?Na(t):t,os=t=>it(t)?tu(t):t;function kt(t){return t?t.__v_isRef===!0:!1}function ze(t){return hh(t,!1)}function hh(t,e){return kt(t)?t:new fh(t,e)}class fh{constructor(e,r){this.dep=new Ca,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=r?e:Pe(e),this._value=r?e:bt(e),this.__v_isShallow=r}get value(){return this.dep.track(),this._value}set value(e){const r=this._rawValue,n=this.__v_isShallow||Wt(e)||Gr(e);e=n?e:Pe(e),Vr(e,r)&&(this._rawValue=e,this._value=n?e:bt(e),this.dep.trigger())}}function ph(t){return kt(t)?t.value:t}const mh={get:(t,e,r)=>e==="__v_raw"?t:ph(Reflect.get(t,e,r)),set:(t,e,r,n)=>{const s=t[e];return kt(s)&&!kt(r)?(s.value=r,!0):Reflect.set(t,e,r,n)}};function ru(t){return Nn(t)?t:new Proxy(t,mh)}class gh{constructor(e,r,n){this.fn=e,this.setter=r,this._value=void 0,this.dep=new Ca(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=c0-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!r,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&Ze!==this)return jc(this,!0),!0}get value(){const e=this.dep.track();return Wc(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}}function vh(t,e,r=!1){let n,s;return De(t)?n=t:(n=t.get,s=t.set),new gh(n,s,r)}const R0={},ls=new WeakMap;let cn;function bh(t,e=!1,r=cn){if(r){let n=ls.get(r);n||ls.set(r,n=[]),n.push(t)}}function yh(t,e,r=Ye){const{immediate:n,deep:s,once:i,scheduler:a,augmentJob:o,call:l}=r,c=N=>s?N:Wt(N)||s===!1||s===0?Er(N,1):Er(N);let d,f,p,b,v=!1,x=!1;if(kt(t)?(f=()=>t.value,v=Wt(t)):Nn(t)?(f=()=>c(t),v=!0):Ce(t)?(x=!0,v=t.some(N=>Nn(N)||Wt(N)),f=()=>t.map(N=>{if(kt(N))return N.value;if(Nn(N))return c(N);if(De(N))return l?l(N,2):N()})):De(t)?e?f=l?()=>l(t,2):t:f=()=>{if(p){Rr();try{p()}finally{Ir()}}const N=cn;cn=d;try{return l?l(t,3,[b]):t(b)}finally{cn=N}}:f=tr,e&&s){const N=f,I=s===!0?1/0:s;f=()=>Er(N(),I)}const y=Vd(),M=()=>{d.stop(),y&&y.active&&ka(y.effects,d)};if(i&&e){const N=e;e=(...I)=>{N(...I),M()}}let k=x?new Array(t.length).fill(R0):R0;const T=N=>{if(!(!(d.flags&1)||!d.dirty&&!N))if(e){const I=d.run();if(s||v||(x?I.some((O,z)=>Vr(O,k[z])):Vr(I,k))){p&&p();const O=cn;cn=d;try{const z=[I,k===R0?void 0:x&&k[0]===R0?[]:k,b];k=I,l?l(e,3,z):e(...z)}finally{cn=O}}}else d.run()};return o&&o(T),d=new Hc(f),d.scheduler=a?()=>a(T,!1):T,b=N=>bh(N,!1,d),p=d.onStop=()=>{const N=ls.get(d);if(N){if(l)l(N,4);else for(const I of N)I();ls.delete(d)}},e?n?T(!0):k=d.run():a?a(T.bind(null,!0),!0):d.run(),M.pause=d.pause.bind(d),M.resume=d.resume.bind(d),M.stop=M,M}function Er(t,e=1/0,r){if(e<=0||!it(t)||t.__v_skip||(r=r||new Set,r.has(t)))return t;if(r.add(t),e--,kt(t))Er(t.value,e,r);else if(Ce(t))for(let n=0;n<t.length;n++)Er(t[n],e,r);else if(Ic(t)||Mn(t))t.forEach(n=>{Er(n,e,r)});else if(Lc(t)){for(const n in t)Er(t[n],e,r);for(const n of Object.getOwnPropertySymbols(t))Object.prototype.propertyIsEnumerable.call(t,n)&&Er(t[n],e,r)}return t}/**
|
||
* @vue/runtime-core v3.5.20
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/function v0(t,e,r,n){try{return n?t(...n):t()}catch(s){zs(s,e,r)}}function mr(t,e,r,n){if(De(t)){const s=v0(t,e,r,n);return s&&_c(s)&&s.catch(i=>{zs(i,e,r)}),s}if(Ce(t)){const s=[];for(let i=0;i<t.length;i++)s.push(mr(t[i],e,r,n));return s}}function zs(t,e,r,n=!0){const s=e?e.vnode:null,{errorHandler:i,throwUnhandledErrorInProduction:a}=e&&e.appContext.config||Ye;if(e){let o=e.parent;const l=e.proxy,c=`https://vuejs.org/error-reference/#runtime-${r}`;for(;o;){const d=o.ec;if(d){for(let f=0;f<d.length;f++)if(d[f](t,l,c)===!1)return}o=o.parent}if(i){Rr(),v0(i,null,10,[t,l,c]),Ir();return}}wh(t,r,s,n,a)}function wh(t,e,r,n=!0,s=!1){if(s)throw t;console.error(t)}const Et=[];let cr=-1;const Dn=[];let qr=null,Tn=0;const nu=Promise.resolve();let cs=null;function Y0(t){const e=cs||nu;return t?e.then(this?t.bind(this):t):e}function xh(t){let e=cr+1,r=Et.length;for(;e<r;){const n=e+r>>>1,s=Et[n],i=d0(s);i<t||i===t&&s.flags&2?e=n+1:r=n}return e}function Ia(t){if(!(t.flags&1)){const e=d0(t),r=Et[Et.length-1];!r||!(t.flags&2)&&e>=d0(r)?Et.push(t):Et.splice(xh(e),0,t),t.flags|=1,su()}}function su(){cs||(cs=nu.then(au))}function kh(t){Ce(t)?Dn.push(...t):qr&&t.id===-1?qr.splice(Tn+1,0,t):t.flags&1||(Dn.push(t),t.flags|=1),su()}function Bo(t,e,r=cr+1){for(;r<Et.length;r++){const n=Et[r];if(n&&n.flags&2){if(t&&n.id!==t.uid)continue;Et.splice(r,1),r--,n.flags&4&&(n.flags&=-2),n(),n.flags&4||(n.flags&=-2)}}}function iu(t){if(Dn.length){const e=[...new Set(Dn)].sort((r,n)=>d0(r)-d0(n));if(Dn.length=0,qr){qr.push(...e);return}for(qr=e,Tn=0;Tn<qr.length;Tn++){const r=qr[Tn];r.flags&4&&(r.flags&=-2),r.flags&8||r(),r.flags&=-2}qr=null,Tn=0}}const d0=t=>t.id==null?t.flags&2?-1:1/0:t.id;function au(t){const e=tr;try{for(cr=0;cr<Et.length;cr++){const r=Et[cr];r&&!(r.flags&8)&&(r.flags&4&&(r.flags&=-2),v0(r,r.i,r.i?15:14),r.flags&4||(r.flags&=-2))}}finally{for(;cr<Et.length;cr++){const r=Et[cr];r&&(r.flags&=-2)}cr=-1,Et.length=0,iu(),cs=null,(Et.length||Dn.length)&&au()}}let Ut=null,ou=null;function us(t){const e=Ut;return Ut=t,ou=t&&t.type.__scopeId||null,e}function Sh(t,e=Ut,r){if(!e||t._n)return t;const n=(...s)=>{n._d&&Go(-1);const i=us(e);let a;try{a=t(...s)}finally{us(i),n._d&&Go(1)}return a};return n._n=!0,n._c=!0,n._d=!0,n}function ds(t,e){if(Ut===null)return t;const r=Ps(Ut),n=t.dirs||(t.dirs=[]);for(let s=0;s<e.length;s++){let[i,a,o,l=Ye]=e[s];i&&(De(i)&&(i={mounted:i,updated:i}),i.deep&&Er(a),n.push({dir:i,instance:r,value:a,oldValue:void 0,arg:o,modifiers:l}))}return t}function nn(t,e,r,n){const s=t.dirs,i=e&&e.dirs;for(let a=0;a<s.length;a++){const o=s[a];i&&(o.oldValue=i[a].value);let l=o.dir[n];l&&(Rr(),mr(l,r,8,[t.el,o,t,e]),Ir())}}const Th=Symbol("_vte"),Ah=t=>t.__isTeleport,Eh=Symbol("_leaveCb");function _a(t,e){t.shapeFlag&6&&t.component?(t.transition=e,_a(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 lu(t){t.ids=[t.ids[0]+t.ids[2]+++"-",0,0]}function r0(t,e,r,n,s=!1){if(Ce(t)){t.forEach((v,x)=>r0(v,e&&(Ce(e)?e[x]:e),r,n,s));return}if(n0(n)&&!s){n.shapeFlag&512&&n.type.__asyncResolved&&n.component.subTree.component&&r0(t,e,r,n.component.subTree);return}const i=n.shapeFlag&4?Ps(n.component):n.el,a=s?null:i,{i:o,r:l}=t,c=e&&e.r,d=o.refs===Ye?o.refs={}:o.refs,f=o.setupState,p=Pe(f),b=f===Ye?Rc:v=>He(p,v);if(c!=null&&c!==l){if(ut(c))d[c]=null,b(c)&&(f[c]=null);else if(kt(c)){c.value=null;const v=e;v.k&&(d[v.k]=null)}}if(De(l))v0(l,o,12,[a,d]);else{const v=ut(l),x=kt(l);if(v||x){const y=()=>{if(t.f){const M=v?b(l)?f[l]:d[l]:l.value;if(s)Ce(M)&&ka(M,i);else if(Ce(M))M.includes(i)||M.push(i);else if(v)d[l]=[i],b(l)&&(f[l]=d[l]);else{const k=[i];l.value=k,t.k&&(d[t.k]=k)}}else v?(d[l]=a,b(l)&&(f[l]=a)):x&&(l.value=a,t.k&&(d[t.k]=a))};a?(y.id=-1,zt(y,r)):y()}}}Os().requestIdleCallback;Os().cancelIdleCallback;const n0=t=>!!t.type.__asyncLoader,cu=t=>t.type.__isKeepAlive;function Ch(t,e){uu(t,"a",e)}function Mh(t,e){uu(t,"da",e)}function uu(t,e,r=Ct){const n=t.__wdc||(t.__wdc=()=>{let s=r;for(;s;){if(s.isDeactivated)return;s=s.parent}return t()});if(Fs(e,n,r),r){let s=r.parent;for(;s&&s.parent;)cu(s.parent.vnode)&&Nh(n,e,r,s),s=s.parent}}function Nh(t,e,r,n){const s=Fs(e,t,n,!0);La(()=>{ka(n[e],s)},r)}function Fs(t,e,r=Ct,n=!1){if(r){const s=r[t]||(r[t]=[]),i=e.__weh||(e.__weh=(...a)=>{Rr();const o=b0(r),l=mr(e,r,t,a);return o(),Ir(),l});return n?s.unshift(i):s.push(i),i}}const zr=t=>(e,r=Ct)=>{(!f0||t==="sp")&&Fs(t,(...n)=>e(...n),r)},Dh=zr("bm"),Oa=zr("m"),Rh=zr("bu"),Ih=zr("u"),_h=zr("bum"),La=zr("um"),Oh=zr("sp"),Lh=zr("rtg"),zh=zr("rtc");function Fh(t,e=Ct){Fs("ec",t,e)}const $h=Symbol.for("v-ndc");function du(t,e,r,n){let s;const i=r&&r[n],a=Ce(t);if(a||ut(t)){const o=a&&Nn(t);let l=!1,c=!1;o&&(l=!Wt(t),c=Gr(t),t=Ls(t)),s=new Array(t.length);for(let d=0,f=t.length;d<f;d++)s[d]=e(l?c?os(bt(t[d])):bt(t[d]):t[d],d,void 0,i&&i[d])}else if(typeof t=="number"){s=new Array(t);for(let o=0;o<t;o++)s[o]=e(o+1,o,void 0,i&&i[o])}else if(it(t))if(t[Symbol.iterator])s=Array.from(t,(o,l)=>e(o,l,void 0,i&&i[l]));else{const o=Object.keys(t);s=new Array(o.length);for(let l=0,c=o.length;l<c;l++){const d=o[l];s[l]=e(t[d],d,l,i&&i[l])}}else s=[];return r&&(r[n]=s),s}const ji=t=>t?Iu(t)?Ps(t):ji(t.parent):null,s0=yt(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=>ji(t.parent),$root:t=>ji(t.root),$host:t=>t.ce,$emit:t=>t.emit,$options:t=>za(t),$forceUpdate:t=>t.f||(t.f=()=>{Ia(t.update)}),$nextTick:t=>t.n||(t.n=Y0.bind(t.proxy)),$watch:t=>of.bind(t)}),ui=(t,e)=>t!==Ye&&!t.__isScriptSetup&&He(t,e),Bh={get({_:t},e){if(e==="__v_skip")return!0;const{ctx:r,setupState:n,data:s,props:i,accessCache:a,type:o,appContext:l}=t;let c;if(e[0]!=="$"){const b=a[e];if(b!==void 0)switch(b){case 1:return n[e];case 2:return s[e];case 4:return r[e];case 3:return i[e]}else{if(ui(n,e))return a[e]=1,n[e];if(s!==Ye&&He(s,e))return a[e]=2,s[e];if((c=t.propsOptions[0])&&He(c,e))return a[e]=3,i[e];if(r!==Ye&&He(r,e))return a[e]=4,r[e];Ui&&(a[e]=0)}}const d=s0[e];let f,p;if(d)return e==="$attrs"&&wt(t.attrs,"get",""),d(t);if((f=o.__cssModules)&&(f=f[e]))return f;if(r!==Ye&&He(r,e))return a[e]=4,r[e];if(p=l.config.globalProperties,He(p,e))return p[e]},set({_:t},e,r){const{data:n,setupState:s,ctx:i}=t;return ui(s,e)?(s[e]=r,!0):n!==Ye&&He(n,e)?(n[e]=r,!0):He(t.props,e)||e[0]==="$"&&e.slice(1)in t?!1:(i[e]=r,!0)},has({_:{data:t,setupState:e,accessCache:r,ctx:n,appContext:s,propsOptions:i,type:a}},o){let l,c;return!!(r[o]||t!==Ye&&o[0]!=="$"&&He(t,o)||ui(e,o)||(l=i[0])&&He(l,o)||He(n,o)||He(s0,o)||He(s.config.globalProperties,o)||(c=a.__cssModules)&&c[o])},defineProperty(t,e,r){return r.get!=null?t._.accessCache[e]=0:He(r,"value")&&this.set(t,e,r.value,null),Reflect.defineProperty(t,e,r)}};function Po(t){return Ce(t)?t.reduce((e,r)=>(e[r]=null,e),{}):t}let Ui=!0;function Ph(t){const e=za(t),r=t.proxy,n=t.ctx;Ui=!1,e.beforeCreate&&Ho(e.beforeCreate,t,"bc");const{data:s,computed:i,methods:a,watch:o,provide:l,inject:c,created:d,beforeMount:f,mounted:p,beforeUpdate:b,updated:v,activated:x,deactivated:y,beforeDestroy:M,beforeUnmount:k,destroyed:T,unmounted:N,render:I,renderTracked:O,renderTriggered:z,errorCaptured:W,serverPrefetch:U,expose:he,inheritAttrs:ge,components:Ae,directives:et,filters:Je}=e;if(c&&Hh(c,n,null),a)for(const Ie in a){const ve=a[Ie];De(ve)&&(n[Ie]=ve.bind(r))}if(s){const Ie=s.call(r,r);it(Ie)&&(t.data=Na(Ie))}if(Ui=!0,i)for(const Ie in i){const ve=i[Ie],Me=De(ve)?ve.bind(r,r):De(ve.get)?ve.get.bind(r,r):tr,tt=!De(ve)&&De(ve.set)?ve.set.bind(r):tr,We=Ou({get:Me,set:tt});Object.defineProperty(n,Ie,{enumerable:!0,configurable:!0,get:()=>We.value,set:_e=>We.value=_e})}if(o)for(const Ie in o)hu(o[Ie],n,r,Ie);if(l){const Ie=De(l)?l.call(r):l;Reflect.ownKeys(Ie).forEach(ve=>{Gh(ve,Ie[ve])})}d&&Ho(d,t,"c");function Fe(Ie,ve){Ce(ve)?ve.forEach(Me=>Ie(Me.bind(r))):ve&&Ie(ve.bind(r))}if(Fe(Dh,f),Fe(Oa,p),Fe(Rh,b),Fe(Ih,v),Fe(Ch,x),Fe(Mh,y),Fe(Fh,W),Fe(zh,O),Fe(Lh,z),Fe(_h,k),Fe(La,N),Fe(Oh,U),Ce(he))if(he.length){const Ie=t.exposed||(t.exposed={});he.forEach(ve=>{Object.defineProperty(Ie,ve,{get:()=>r[ve],set:Me=>r[ve]=Me,enumerable:!0})})}else t.exposed||(t.exposed={});I&&t.render===tr&&(t.render=I),ge!=null&&(t.inheritAttrs=ge),Ae&&(t.components=Ae),et&&(t.directives=et),U&&lu(t)}function Hh(t,e,r=tr){Ce(t)&&(t=Vi(t));for(const n in t){const s=t[n];let i;it(s)?"default"in s?i=X0(s.from||n,s.default,!0):i=X0(s.from||n):i=X0(s),kt(i)?Object.defineProperty(e,n,{enumerable:!0,configurable:!0,get:()=>i.value,set:a=>i.value=a}):e[n]=i}}function Ho(t,e,r){mr(Ce(t)?t.map(n=>n.bind(e.proxy)):t.bind(e.proxy),e,r)}function hu(t,e,r,n){let s=n.includes(".")?Au(r,n):()=>r[n];if(ut(t)){const i=e[t];De(i)&&i0(s,i)}else if(De(t))i0(s,t.bind(r));else if(it(t))if(Ce(t))t.forEach(i=>hu(i,e,r,n));else{const i=De(t.handler)?t.handler.bind(r):e[t.handler];De(i)&&i0(s,i,t)}}function za(t){const e=t.type,{mixins:r,extends:n}=e,{mixins:s,optionsCache:i,config:{optionMergeStrategies:a}}=t.appContext,o=i.get(e);let l;return o?l=o:!s.length&&!r&&!n?l=e:(l={},s.length&&s.forEach(c=>hs(l,c,a,!0)),hs(l,e,a)),it(e)&&i.set(e,l),l}function hs(t,e,r,n=!1){const{mixins:s,extends:i}=e;i&&hs(t,i,r,!0),s&&s.forEach(a=>hs(t,a,r,!0));for(const a in e)if(!(n&&a==="expose")){const o=qh[a]||r&&r[a];t[a]=o?o(t[a],e[a]):e[a]}return t}const qh={data:qo,props:jo,emits:jo,methods:Xn,computed:Xn,beforeCreate:At,created:At,beforeMount:At,mounted:At,beforeUpdate:At,updated:At,beforeDestroy:At,beforeUnmount:At,destroyed:At,unmounted:At,activated:At,deactivated:At,errorCaptured:At,serverPrefetch:At,components:Xn,directives:Xn,watch:Uh,provide:qo,inject:jh};function qo(t,e){return e?t?function(){return yt(De(t)?t.call(this,this):t,De(e)?e.call(this,this):e)}:e:t}function jh(t,e){return Xn(Vi(t),Vi(e))}function Vi(t){if(Ce(t)){const e={};for(let r=0;r<t.length;r++)e[t[r]]=t[r];return e}return t}function At(t,e){return t?[...new Set([].concat(t,e))]:e}function Xn(t,e){return t?yt(Object.create(null),t,e):e}function jo(t,e){return t?Ce(t)&&Ce(e)?[...new Set([...t,...e])]:yt(Object.create(null),Po(t),Po(e??{})):e}function Uh(t,e){if(!t)return e;if(!e)return t;const r=yt(Object.create(null),t);for(const n in e)r[n]=At(t[n],e[n]);return r}function fu(){return{app:null,config:{isNativeTag:Rc,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 Vh=0;function Wh(t,e){return function(n,s=null){De(n)||(n=yt({},n)),s!=null&&!it(s)&&(s=null);const i=fu(),a=new WeakSet,o=[];let l=!1;const c=i.app={_uid:Vh++,_component:n,_props:s,_container:null,_context:i,_instance:null,version:Nf,get config(){return i.config},set config(d){},use(d,...f){return a.has(d)||(d&&De(d.install)?(a.add(d),d.install(c,...f)):De(d)&&(a.add(d),d(c,...f))),c},mixin(d){return i.mixins.includes(d)||i.mixins.push(d),c},component(d,f){return f?(i.components[d]=f,c):i.components[d]},directive(d,f){return f?(i.directives[d]=f,c):i.directives[d]},mount(d,f,p){if(!l){const b=c._ceVNode||Ht(n,s);return b.appContext=i,p===!0?p="svg":p===!1&&(p=void 0),f&&e?e(b,d):t(b,d,p),l=!0,c._container=d,d.__vue_app__=c,Ps(b.component)}},onUnmount(d){o.push(d)},unmount(){l&&(mr(o,c._instance,16),t(null,c._container),delete c._container.__vue_app__)},provide(d,f){return i.provides[d]=f,c},runWithContext(d){const f=Rn;Rn=c;try{return d()}finally{Rn=f}}};return c}}let Rn=null;function Gh(t,e){if(Ct){let r=Ct.provides;const n=Ct.parent&&Ct.parent.provides;n===r&&(r=Ct.provides=Object.create(n)),r[t]=e}}function X0(t,e,r=!1){const n=Sf();if(n||Rn){let s=Rn?Rn._context.provides:n?n.parent==null||n.ce?n.vnode.appContext&&n.vnode.appContext.provides:n.parent.provides:void 0;if(s&&t in s)return s[t];if(arguments.length>1)return r&&De(e)?e.call(n&&n.proxy):e}}const pu={},mu=()=>Object.create(pu),gu=t=>Object.getPrototypeOf(t)===pu;function Kh(t,e,r,n=!1){const s={},i=mu();t.propsDefaults=Object.create(null),vu(t,e,s,i);for(const a in t.propsOptions[0])a in s||(s[a]=void 0);r?t.props=n?s:uh(s):t.type.props?t.props=s:t.props=i,t.attrs=i}function Yh(t,e,r,n){const{props:s,attrs:i,vnode:{patchFlag:a}}=t,o=Pe(s),[l]=t.propsOptions;let c=!1;if((n||a>0)&&!(a&16)){if(a&8){const d=t.vnode.dynamicProps;for(let f=0;f<d.length;f++){let p=d[f];if($s(t.emitsOptions,p))continue;const b=e[p];if(l)if(He(i,p))b!==i[p]&&(i[p]=b,c=!0);else{const v=Wr(p);s[v]=Wi(l,o,v,b,t,!1)}else b!==i[p]&&(i[p]=b,c=!0)}}}else{vu(t,e,s,i)&&(c=!0);let d;for(const f in o)(!e||!He(e,f)&&((d=Qr(f))===f||!He(e,d)))&&(l?r&&(r[f]!==void 0||r[d]!==void 0)&&(s[f]=Wi(l,o,f,void 0,t,!0)):delete s[f]);if(i!==o)for(const f in i)(!e||!He(e,f))&&(delete i[f],c=!0)}c&&Ar(t.attrs,"set","")}function vu(t,e,r,n){const[s,i]=t.propsOptions;let a=!1,o;if(e)for(let l in e){if(Qn(l))continue;const c=e[l];let d;s&&He(s,d=Wr(l))?!i||!i.includes(d)?r[d]=c:(o||(o={}))[d]=c:$s(t.emitsOptions,l)||(!(l in n)||c!==n[l])&&(n[l]=c,a=!0)}if(i){const l=Pe(r),c=o||Ye;for(let d=0;d<i.length;d++){const f=i[d];r[f]=Wi(s,l,f,c[f],t,!He(c,f))}}return a}function Wi(t,e,r,n,s,i){const a=t[r];if(a!=null){const o=He(a,"default");if(o&&n===void 0){const l=a.default;if(a.type!==Function&&!a.skipFactory&&De(l)){const{propsDefaults:c}=s;if(r in c)n=c[r];else{const d=b0(s);n=c[r]=l.call(null,e),d()}}else n=l;s.ce&&s.ce._setProp(r,n)}a[0]&&(i&&!o?n=!1:a[1]&&(n===""||n===Qr(r))&&(n=!0))}return n}const Xh=new WeakMap;function bu(t,e,r=!1){const n=r?Xh:e.propsCache,s=n.get(t);if(s)return s;const i=t.props,a={},o=[];let l=!1;if(!De(t)){const d=f=>{l=!0;const[p,b]=bu(f,e,!0);yt(a,p),b&&o.push(...b)};!r&&e.mixins.length&&e.mixins.forEach(d),t.extends&&d(t.extends),t.mixins&&t.mixins.forEach(d)}if(!i&&!l)return it(t)&&n.set(t,Cn),Cn;if(Ce(i))for(let d=0;d<i.length;d++){const f=Wr(i[d]);Uo(f)&&(a[f]=Ye)}else if(i)for(const d in i){const f=Wr(d);if(Uo(f)){const p=i[d],b=a[f]=Ce(p)||De(p)?{type:p}:yt({},p),v=b.type;let x=!1,y=!0;if(Ce(v))for(let M=0;M<v.length;++M){const k=v[M],T=De(k)&&k.name;if(T==="Boolean"){x=!0;break}else T==="String"&&(y=!1)}else x=De(v)&&v.name==="Boolean";b[0]=x,b[1]=y,(x||He(b,"default"))&&o.push(f)}}const c=[a,o];return it(t)&&n.set(t,c),c}function Uo(t){return t[0]!=="$"&&!Qn(t)}const Fa=t=>t==="_"||t==="_ctx"||t==="$stable",$a=t=>Ce(t)?t.map(dr):[dr(t)],Jh=(t,e,r)=>{if(e._n)return e;const n=Sh((...s)=>$a(e(...s)),r);return n._c=!1,n},yu=(t,e,r)=>{const n=t._ctx;for(const s in t){if(Fa(s))continue;const i=t[s];if(De(i))e[s]=Jh(s,i,n);else if(i!=null){const a=$a(i);e[s]=()=>a}}},wu=(t,e)=>{const r=$a(e);t.slots.default=()=>r},xu=(t,e,r)=>{for(const n in e)(r||!Fa(n))&&(t[n]=e[n])},Zh=(t,e,r)=>{const n=t.slots=mu();if(t.vnode.shapeFlag&32){const s=e._;s?(xu(n,e,r),r&&Fc(n,"_",s,!0)):yu(e,n)}else e&&wu(t,e)},Qh=(t,e,r)=>{const{vnode:n,slots:s}=t;let i=!0,a=Ye;if(n.shapeFlag&32){const o=e._;o?r&&o===1?i=!1:xu(s,e,r):(i=!e.$stable,yu(e,s)),a=e}else e&&(wu(t,e),a={default:1});if(i)for(const o in s)!Fa(o)&&a[o]==null&&delete s[o]},zt=pf;function ef(t){return tf(t)}function tf(t,e){const r=Os();r.__VUE__=!0;const{insert:n,remove:s,patchProp:i,createElement:a,createText:o,createComment:l,setText:c,setElementText:d,parentNode:f,nextSibling:p,setScopeId:b=tr,insertStaticContent:v}=t,x=(S,D,F,G=null,q=null,H=null,X=void 0,ne=null,se=!!D.dynamicChildren)=>{if(S===D)return;S&&!Un(S,D)&&(G=re(S),_e(S,q,H,!0),S=null),D.patchFlag===-2&&(se=!1,D.dynamicChildren=null);const{type:Q,ref:be,shapeFlag:le}=D;switch(Q){case Bs:y(S,D,F,G);break;case Kr:M(S,D,F,G);break;case J0:S==null&&k(D,F,G,X);break;case er:Ae(S,D,F,G,q,H,X,ne,se);break;default:le&1?I(S,D,F,G,q,H,X,ne,se):le&6?et(S,D,F,G,q,H,X,ne,se):(le&64||le&128)&&Q.process(S,D,F,G,q,H,X,ne,se,ye)}be!=null&&q?r0(be,S&&S.ref,H,D||S,!D):be==null&&S&&S.ref!=null&&r0(S.ref,null,H,S,!0)},y=(S,D,F,G)=>{if(S==null)n(D.el=o(D.children),F,G);else{const q=D.el=S.el;D.children!==S.children&&c(q,D.children)}},M=(S,D,F,G)=>{S==null?n(D.el=l(D.children||""),F,G):D.el=S.el},k=(S,D,F,G)=>{[S.el,S.anchor]=v(S.children,D,F,G,S.el,S.anchor)},T=({el:S,anchor:D},F,G)=>{let q;for(;S&&S!==D;)q=p(S),n(S,F,G),S=q;n(D,F,G)},N=({el:S,anchor:D})=>{let F;for(;S&&S!==D;)F=p(S),s(S),S=F;s(D)},I=(S,D,F,G,q,H,X,ne,se)=>{D.type==="svg"?X="svg":D.type==="math"&&(X="mathml"),S==null?O(D,F,G,q,H,X,ne,se):U(S,D,q,H,X,ne,se)},O=(S,D,F,G,q,H,X,ne)=>{let se,Q;const{props:be,shapeFlag:le,transition:pe,dirs:Se}=S;if(se=S.el=a(S.type,H,be&&be.is,be),le&8?d(se,S.children):le&16&&W(S.children,se,null,G,q,di(S,H),X,ne),Se&&nn(S,null,G,"created"),z(se,S,S.scopeId,X,G),be){for(const w in be)w!=="value"&&!Qn(w)&&i(se,w,null,be[w],H,G);"value"in be&&i(se,"value",null,be.value,H),(Q=be.onVnodeBeforeMount)&&ar(Q,G,S)}Se&&nn(S,null,G,"beforeMount");const Le=rf(q,pe);Le&&pe.beforeEnter(se),n(se,D,F),((Q=be&&be.onVnodeMounted)||Le||Se)&&zt(()=>{Q&&ar(Q,G,S),Le&&pe.enter(se),Se&&nn(S,null,G,"mounted")},q)},z=(S,D,F,G,q)=>{if(F&&b(S,F),G)for(let H=0;H<G.length;H++)b(S,G[H]);if(q){let H=q.subTree;if(D===H||Cu(H.type)&&(H.ssContent===D||H.ssFallback===D)){const X=q.vnode;z(S,X,X.scopeId,X.slotScopeIds,q.parent)}}},W=(S,D,F,G,q,H,X,ne,se=0)=>{for(let Q=se;Q<S.length;Q++){const be=S[Q]=ne?jr(S[Q]):dr(S[Q]);x(null,be,D,F,G,q,H,X,ne)}},U=(S,D,F,G,q,H,X)=>{const ne=D.el=S.el;let{patchFlag:se,dynamicChildren:Q,dirs:be}=D;se|=S.patchFlag&16;const le=S.props||Ye,pe=D.props||Ye;let Se;if(F&&sn(F,!1),(Se=pe.onVnodeBeforeUpdate)&&ar(Se,F,D,S),be&&nn(D,S,F,"beforeUpdate"),F&&sn(F,!0),(le.innerHTML&&pe.innerHTML==null||le.textContent&&pe.textContent==null)&&d(ne,""),Q?he(S.dynamicChildren,Q,ne,F,G,di(D,q),H):X||ve(S,D,ne,null,F,G,di(D,q),H,!1),se>0){if(se&16)ge(ne,le,pe,F,q);else if(se&2&&le.class!==pe.class&&i(ne,"class",null,pe.class,q),se&4&&i(ne,"style",le.style,pe.style,q),se&8){const Le=D.dynamicProps;for(let w=0;w<Le.length;w++){const E=Le[w],_=le[E],P=pe[E];(P!==_||E==="value")&&i(ne,E,_,P,q,F)}}se&1&&S.children!==D.children&&d(ne,D.children)}else!X&&Q==null&&ge(ne,le,pe,F,q);((Se=pe.onVnodeUpdated)||be)&&zt(()=>{Se&&ar(Se,F,D,S),be&&nn(D,S,F,"updated")},G)},he=(S,D,F,G,q,H,X)=>{for(let ne=0;ne<D.length;ne++){const se=S[ne],Q=D[ne],be=se.el&&(se.type===er||!Un(se,Q)||se.shapeFlag&198)?f(se.el):F;x(se,Q,be,null,G,q,H,X,!0)}},ge=(S,D,F,G,q)=>{if(D!==F){if(D!==Ye)for(const H in D)!Qn(H)&&!(H in F)&&i(S,H,D[H],null,q,G);for(const H in F){if(Qn(H))continue;const X=F[H],ne=D[H];X!==ne&&H!=="value"&&i(S,H,ne,X,q,G)}"value"in F&&i(S,"value",D.value,F.value,q)}},Ae=(S,D,F,G,q,H,X,ne,se)=>{const Q=D.el=S?S.el:o(""),be=D.anchor=S?S.anchor:o("");let{patchFlag:le,dynamicChildren:pe,slotScopeIds:Se}=D;Se&&(ne=ne?ne.concat(Se):Se),S==null?(n(Q,F,G),n(be,F,G),W(D.children||[],F,be,q,H,X,ne,se)):le>0&&le&64&&pe&&S.dynamicChildren?(he(S.dynamicChildren,pe,F,q,H,X,ne),(D.key!=null||q&&D===q.subTree)&&ku(S,D,!0)):ve(S,D,F,be,q,H,X,ne,se)},et=(S,D,F,G,q,H,X,ne,se)=>{D.slotScopeIds=ne,S==null?D.shapeFlag&512?q.ctx.activate(D,F,G,X,se):Je(D,F,G,q,H,X,se):ot(S,D,se)},Je=(S,D,F,G,q,H,X)=>{const ne=S.component=kf(S,G,q);if(cu(S)&&(ne.ctx.renderer=ye),Tf(ne,!1,X),ne.asyncDep){if(q&&q.registerDep(ne,Fe,X),!S.el){const se=ne.subTree=Ht(Kr);M(null,se,D,F),S.placeholder=se.el}}else Fe(ne,S,D,F,q,H,X)},ot=(S,D,F)=>{const G=D.component=S.component;if(hf(S,D,F))if(G.asyncDep&&!G.asyncResolved){Ie(G,D,F);return}else G.next=D,G.update();else D.el=S.el,G.vnode=D},Fe=(S,D,F,G,q,H,X)=>{const ne=()=>{if(S.isMounted){let{next:le,bu:pe,u:Se,parent:Le,vnode:w}=S;{const J=Su(S);if(J){le&&(le.el=w.el,Ie(S,le,X)),J.asyncDep.then(()=>{S.isUnmounted||ne()});return}}let E=le,_;sn(S,!1),le?(le.el=w.el,Ie(S,le,X)):le=w,pe&&K0(pe),(_=le.props&&le.props.onVnodeBeforeUpdate)&&ar(_,Le,le,w),sn(S,!0);const P=hi(S),Z=S.subTree;S.subTree=P,x(Z,P,f(Z.el),re(Z),S,q,H),le.el=P.el,E===null&&ff(S,P.el),Se&&zt(Se,q),(_=le.props&&le.props.onVnodeUpdated)&&zt(()=>ar(_,Le,le,w),q)}else{let le;const{el:pe,props:Se}=D,{bm:Le,m:w,parent:E,root:_,type:P}=S,Z=n0(D);if(sn(S,!1),Le&&K0(Le),!Z&&(le=Se&&Se.onVnodeBeforeMount)&&ar(le,E,D),sn(S,!0),pe&&Ue){const J=()=>{S.subTree=hi(S),Ue(pe,S.subTree,S,q,null)};Z&&P.__asyncHydrate?P.__asyncHydrate(pe,S,J):J()}else{_.ce&&_.ce._def.shadowRoot!==!1&&_.ce._injectChildStyle(P);const J=S.subTree=hi(S);x(null,J,F,G,S,q,H),D.el=J.el}if(w&&zt(w,q),!Z&&(le=Se&&Se.onVnodeMounted)){const J=D;zt(()=>ar(le,E,J),q)}(D.shapeFlag&256||E&&n0(E.vnode)&&E.vnode.shapeFlag&256)&&S.a&&zt(S.a,q),S.isMounted=!0,D=F=G=null}};S.scope.on();const se=S.effect=new Hc(ne);S.scope.off();const Q=S.update=se.run.bind(se),be=S.job=se.runIfDirty.bind(se);be.i=S,be.id=S.uid,se.scheduler=()=>Ia(be),sn(S,!0),Q()},Ie=(S,D,F)=>{D.component=S;const G=S.vnode.props;S.vnode=D,S.next=null,Yh(S,D.props,G,F),Qh(S,D.children,F),Rr(),Bo(S),Ir()},ve=(S,D,F,G,q,H,X,ne,se=!1)=>{const Q=S&&S.children,be=S?S.shapeFlag:0,le=D.children,{patchFlag:pe,shapeFlag:Se}=D;if(pe>0){if(pe&128){tt(Q,le,F,G,q,H,X,ne,se);return}else if(pe&256){Me(Q,le,F,G,q,H,X,ne,se);return}}Se&8?(be&16&&V(Q,q,H),le!==Q&&d(F,le)):be&16?Se&16?tt(Q,le,F,G,q,H,X,ne,se):V(Q,q,H,!0):(be&8&&d(F,""),Se&16&&W(le,F,G,q,H,X,ne,se))},Me=(S,D,F,G,q,H,X,ne,se)=>{S=S||Cn,D=D||Cn;const Q=S.length,be=D.length,le=Math.min(Q,be);let pe;for(pe=0;pe<le;pe++){const Se=D[pe]=se?jr(D[pe]):dr(D[pe]);x(S[pe],Se,F,null,q,H,X,ne,se)}Q>be?V(S,q,H,!0,!1,le):W(D,F,G,q,H,X,ne,se,le)},tt=(S,D,F,G,q,H,X,ne,se)=>{let Q=0;const be=D.length;let le=S.length-1,pe=be-1;for(;Q<=le&&Q<=pe;){const Se=S[Q],Le=D[Q]=se?jr(D[Q]):dr(D[Q]);if(Un(Se,Le))x(Se,Le,F,null,q,H,X,ne,se);else break;Q++}for(;Q<=le&&Q<=pe;){const Se=S[le],Le=D[pe]=se?jr(D[pe]):dr(D[pe]);if(Un(Se,Le))x(Se,Le,F,null,q,H,X,ne,se);else break;le--,pe--}if(Q>le){if(Q<=pe){const Se=pe+1,Le=Se<be?D[Se].el:G;for(;Q<=pe;)x(null,D[Q]=se?jr(D[Q]):dr(D[Q]),F,Le,q,H,X,ne,se),Q++}}else if(Q>pe)for(;Q<=le;)_e(S[Q],q,H,!0),Q++;else{const Se=Q,Le=Q,w=new Map;for(Q=Le;Q<=pe;Q++){const de=D[Q]=se?jr(D[Q]):dr(D[Q]);de.key!=null&&w.set(de.key,Q)}let E,_=0;const P=pe-Le+1;let Z=!1,J=0;const $=new Array(P);for(Q=0;Q<P;Q++)$[Q]=0;for(Q=Se;Q<=le;Q++){const de=S[Q];if(_>=P){_e(de,q,H,!0);continue}let me;if(de.key!=null)me=w.get(de.key);else for(E=Le;E<=pe;E++)if($[E-Le]===0&&Un(de,D[E])){me=E;break}me===void 0?_e(de,q,H,!0):($[me-Le]=Q+1,me>=J?J=me:Z=!0,x(de,D[me],F,null,q,H,X,ne,se),_++)}const ue=Z?nf($):Cn;for(E=ue.length-1,Q=P-1;Q>=0;Q--){const de=Le+Q,me=D[de],Oe=D[de+1],Be=de+1<be?Oe.el||Oe.placeholder:G;$[Q]===0?x(null,me,F,Be,q,H,X,ne,se):Z&&(E<0||Q!==ue[E]?We(me,F,Be,2):E--)}}},We=(S,D,F,G,q=null)=>{const{el:H,type:X,transition:ne,children:se,shapeFlag:Q}=S;if(Q&6){We(S.component.subTree,D,F,G);return}if(Q&128){S.suspense.move(D,F,G);return}if(Q&64){X.move(S,D,F,ye);return}if(X===er){n(H,D,F);for(let le=0;le<se.length;le++)We(se[le],D,F,G);n(S.anchor,D,F);return}if(X===J0){T(S,D,F);return}if(G!==2&&Q&1&&ne)if(G===0)ne.beforeEnter(H),n(H,D,F),zt(()=>ne.enter(H),q);else{const{leave:le,delayLeave:pe,afterLeave:Se}=ne,Le=()=>{S.ctx.isUnmounted?s(H):n(H,D,F)},w=()=>{H._isLeaving&&H[Eh](!0),le(H,()=>{Le(),Se&&Se()})};pe?pe(H,Le,w):w()}else n(H,D,F)},_e=(S,D,F,G=!1,q=!1)=>{const{type:H,props:X,ref:ne,children:se,dynamicChildren:Q,shapeFlag:be,patchFlag:le,dirs:pe,cacheIndex:Se}=S;if(le===-2&&(q=!1),ne!=null&&(Rr(),r0(ne,null,F,S,!0),Ir()),Se!=null&&(D.renderCache[Se]=void 0),be&256){D.ctx.deactivate(S);return}const Le=be&1&&pe,w=!n0(S);let E;if(w&&(E=X&&X.onVnodeBeforeUnmount)&&ar(E,D,S),be&6)j(S.component,F,G);else{if(be&128){S.suspense.unmount(F,G);return}Le&&nn(S,null,D,"beforeUnmount"),be&64?S.type.remove(S,D,F,ye,G):Q&&!Q.hasOnce&&(H!==er||le>0&&le&64)?V(Q,D,F,!1,!0):(H===er&&le&384||!q&&be&16)&&V(se,D,F),G&&St(S)}(w&&(E=X&&X.onVnodeUnmounted)||Le)&&zt(()=>{E&&ar(E,D,S),Le&&nn(S,null,D,"unmounted")},F)},St=S=>{const{type:D,el:F,anchor:G,transition:q}=S;if(D===er){mt(F,G);return}if(D===J0){N(S);return}const H=()=>{s(F),q&&!q.persisted&&q.afterLeave&&q.afterLeave()};if(S.shapeFlag&1&&q&&!q.persisted){const{leave:X,delayLeave:ne}=q,se=()=>X(F,H);ne?ne(S.el,H,se):se()}else H()},mt=(S,D)=>{let F;for(;S!==D;)F=p(S),s(S),S=F;s(D)},j=(S,D,F)=>{const{bum:G,scope:q,job:H,subTree:X,um:ne,m:se,a:Q}=S;Vo(se),Vo(Q),G&&K0(G),q.stop(),H&&(H.flags|=8,_e(X,S,D,F)),ne&&zt(ne,D),zt(()=>{S.isUnmounted=!0},D)},V=(S,D,F,G=!1,q=!1,H=0)=>{for(let X=H;X<S.length;X++)_e(S[X],D,F,G,q)},re=S=>{if(S.shapeFlag&6)return re(S.component.subTree);if(S.shapeFlag&128)return S.suspense.next();const D=p(S.anchor||S.el),F=D&&D[Th];return F?p(F):D};let ie=!1;const Ee=(S,D,F)=>{S==null?D._vnode&&_e(D._vnode,null,null,!0):x(D._vnode||null,S,D,null,null,null,F),D._vnode=S,ie||(ie=!0,Bo(),iu(),ie=!1)},ye={p:x,um:_e,m:We,r:St,mt:Je,mc:W,pc:ve,pbc:he,n:re,o:t};let fe,Ue;return e&&([fe,Ue]=e(ye)),{render:Ee,hydrate:fe,createApp:Wh(Ee,fe)}}function di({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 sn({effect:t,job:e},r){r?(t.flags|=32,e.flags|=4):(t.flags&=-33,e.flags&=-5)}function rf(t,e){return(!t||t&&!t.pendingBranch)&&e&&!e.persisted}function ku(t,e,r=!1){const n=t.children,s=e.children;if(Ce(n)&&Ce(s))for(let i=0;i<n.length;i++){const a=n[i];let o=s[i];o.shapeFlag&1&&!o.dynamicChildren&&((o.patchFlag<=0||o.patchFlag===32)&&(o=s[i]=jr(s[i]),o.el=a.el),!r&&o.patchFlag!==-2&&ku(a,o)),o.type===Bs&&o.patchFlag!==-1&&(o.el=a.el),o.type===Kr&&!o.el&&(o.el=a.el)}}function nf(t){const e=t.slice(),r=[0];let n,s,i,a,o;const l=t.length;for(n=0;n<l;n++){const c=t[n];if(c!==0){if(s=r[r.length-1],t[s]<c){e[n]=s,r.push(n);continue}for(i=0,a=r.length-1;i<a;)o=i+a>>1,t[r[o]]<c?i=o+1:a=o;c<t[r[i]]&&(i>0&&(e[n]=r[i-1]),r[i]=n)}}for(i=r.length,a=r[i-1];i-- >0;)r[i]=a,a=e[a];return r}function Su(t){const e=t.subTree.component;if(e)return e.asyncDep&&!e.asyncResolved?e:Su(e)}function Vo(t){if(t)for(let e=0;e<t.length;e++)t[e].flags|=8}const sf=Symbol.for("v-scx"),af=()=>X0(sf);function i0(t,e,r){return Tu(t,e,r)}function Tu(t,e,r=Ye){const{immediate:n,deep:s,flush:i,once:a}=r,o=yt({},r),l=e&&n||!e&&i!=="post";let c;if(f0){if(i==="sync"){const b=af();c=b.__watcherHandles||(b.__watcherHandles=[])}else if(!l){const b=()=>{};return b.stop=tr,b.resume=tr,b.pause=tr,b}}const d=Ct;o.call=(b,v,x)=>mr(b,d,v,x);let f=!1;i==="post"?o.scheduler=b=>{zt(b,d&&d.suspense)}:i!=="sync"&&(f=!0,o.scheduler=(b,v)=>{v?b():Ia(b)}),o.augmentJob=b=>{e&&(b.flags|=4),f&&(b.flags|=2,d&&(b.id=d.uid,b.i=d))};const p=yh(t,e,o);return f0&&(c?c.push(p):l&&p()),p}function of(t,e,r){const n=this.proxy,s=ut(t)?t.includes(".")?Au(n,t):()=>n[t]:t.bind(n,n);let i;De(e)?i=e:(i=e.handler,r=e);const a=b0(this),o=Tu(s,i.bind(n),r);return a(),o}function Au(t,e){const r=e.split(".");return()=>{let n=t;for(let s=0;s<r.length&&n;s++)n=n[r[s]];return n}}const lf=(t,e)=>e==="modelValue"||e==="model-value"?t.modelModifiers:t[`${e}Modifiers`]||t[`${Wr(e)}Modifiers`]||t[`${Qr(e)}Modifiers`];function cf(t,e,...r){if(t.isUnmounted)return;const n=t.vnode.props||Ye;let s=r;const i=e.startsWith("update:"),a=i&&lf(n,e.slice(7));a&&(a.trim&&(s=r.map(d=>ut(d)?d.trim():d)),a.number&&(s=r.map($i)));let o,l=n[o=ii(e)]||n[o=ii(Wr(e))];!l&&i&&(l=n[o=ii(Qr(e))]),l&&mr(l,t,6,s);const c=n[o+"Once"];if(c){if(!t.emitted)t.emitted={};else if(t.emitted[o])return;t.emitted[o]=!0,mr(c,t,6,s)}}function Eu(t,e,r=!1){const n=e.emitsCache,s=n.get(t);if(s!==void 0)return s;const i=t.emits;let a={},o=!1;if(!De(t)){const l=c=>{const d=Eu(c,e,!0);d&&(o=!0,yt(a,d))};!r&&e.mixins.length&&e.mixins.forEach(l),t.extends&&l(t.extends),t.mixins&&t.mixins.forEach(l)}return!i&&!o?(it(t)&&n.set(t,null),null):(Ce(i)?i.forEach(l=>a[l]=null):yt(a,i),it(t)&&n.set(t,a),a)}function $s(t,e){return!t||!Rs(e)?!1:(e=e.slice(2).replace(/Once$/,""),He(t,e[0].toLowerCase()+e.slice(1))||He(t,Qr(e))||He(t,e))}function hi(t){const{type:e,vnode:r,proxy:n,withProxy:s,propsOptions:[i],slots:a,attrs:o,emit:l,render:c,renderCache:d,props:f,data:p,setupState:b,ctx:v,inheritAttrs:x}=t,y=us(t);let M,k;try{if(r.shapeFlag&4){const N=s||n,I=N;M=dr(c.call(I,N,d,f,b,p,v)),k=o}else{const N=e;M=dr(N.length>1?N(f,{attrs:o,slots:a,emit:l}):N(f,null)),k=e.props?o:uf(o)}}catch(N){a0.length=0,zs(N,t,1),M=Ht(Kr)}let T=M;if(k&&x!==!1){const N=Object.keys(k),{shapeFlag:I}=T;N.length&&I&7&&(i&&N.some(xa)&&(k=df(k,i)),T=zn(T,k,!1,!0))}return r.dirs&&(T=zn(T,null,!1,!0),T.dirs=T.dirs?T.dirs.concat(r.dirs):r.dirs),r.transition&&_a(T,r.transition),M=T,us(y),M}const uf=t=>{let e;for(const r in t)(r==="class"||r==="style"||Rs(r))&&((e||(e={}))[r]=t[r]);return e},df=(t,e)=>{const r={};for(const n in t)(!xa(n)||!(n.slice(9)in e))&&(r[n]=t[n]);return r};function hf(t,e,r){const{props:n,children:s,component:i}=t,{props:a,children:o,patchFlag:l}=e,c=i.emitsOptions;if(e.dirs||e.transition)return!0;if(r&&l>=0){if(l&1024)return!0;if(l&16)return n?Wo(n,a,c):!!a;if(l&8){const d=e.dynamicProps;for(let f=0;f<d.length;f++){const p=d[f];if(a[p]!==n[p]&&!$s(c,p))return!0}}}else return(s||o)&&(!o||!o.$stable)?!0:n===a?!1:n?a?Wo(n,a,c):!0:!!a;return!1}function Wo(t,e,r){const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!0;for(let s=0;s<n.length;s++){const i=n[s];if(e[i]!==t[i]&&!$s(r,i))return!0}return!1}function ff({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 Cu=t=>t.__isSuspense;function pf(t,e){e&&e.pendingBranch?Ce(t)?e.effects.push(...t):e.effects.push(t):kh(t)}const er=Symbol.for("v-fgt"),Bs=Symbol.for("v-txt"),Kr=Symbol.for("v-cmt"),J0=Symbol.for("v-stc"),a0=[];let Pt=null;function Ve(t=!1){a0.push(Pt=t?null:[])}function mf(){a0.pop(),Pt=a0[a0.length-1]||null}let h0=1;function Go(t,e=!1){h0+=t,t<0&&Pt&&e&&(Pt.hasOnce=!0)}function Mu(t){return t.dynamicChildren=h0>0?Pt||Cn:null,mf(),h0>0&&Pt&&Pt.push(t),t}function Ke(t,e,r,n,s,i){return Mu(Y(t,e,r,n,s,i,!0))}function gf(t,e,r,n,s){return Mu(Ht(t,e,r,n,s,!0))}function Nu(t){return t?t.__v_isVNode===!0:!1}function Un(t,e){return t.type===e.type&&t.key===e.key}const Du=({key:t})=>t??null,Z0=({ref:t,ref_key:e,ref_for:r})=>(typeof t=="number"&&(t=""+t),t!=null?ut(t)||kt(t)||De(t)?{i:Ut,r:t,k:e,f:!!r}:t:null);function Y(t,e=null,r=null,n=0,s=null,i=t===er?0:1,a=!1,o=!1){const l={__v_isVNode:!0,__v_skip:!0,type:t,props:e,key:e&&Du(e),ref:e&&Z0(e),scopeId:ou,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:i,patchFlag:n,dynamicProps:s,dynamicChildren:null,appContext:null,ctx:Ut};return o?(Ba(l,r),i&128&&t.normalize(l)):r&&(l.shapeFlag|=ut(r)?8:16),h0>0&&!a&&Pt&&(l.patchFlag>0||i&6)&&l.patchFlag!==32&&Pt.push(l),l}const Ht=vf;function vf(t,e=null,r=null,n=0,s=null,i=!1){if((!t||t===$h)&&(t=Kr),Nu(t)){const o=zn(t,e,!0);return r&&Ba(o,r),h0>0&&!i&&Pt&&(o.shapeFlag&6?Pt[Pt.indexOf(t)]=o:Pt.push(o)),o.patchFlag=-2,o}if(Mf(t)&&(t=t.__vccOpts),e){e=bf(e);let{class:o,style:l}=e;o&&!ut(o)&&(e.class=Ln(o)),it(l)&&(Ra(l)&&!Ce(l)&&(l=yt({},l)),e.style=On(l))}const a=ut(t)?1:Cu(t)?128:Ah(t)?64:it(t)?4:De(t)?2:0;return Y(t,e,r,n,s,a,i,!0)}function bf(t){return t?Ra(t)||gu(t)?yt({},t):t:null}function zn(t,e,r=!1,n=!1){const{props:s,ref:i,patchFlag:a,children:o,transition:l}=t,c=e?yf(s||{},e):s,d={__v_isVNode:!0,__v_skip:!0,type:t.type,props:c,key:c&&Du(c),ref:e&&e.ref?r&&i?Ce(i)?i.concat(Z0(e)):[i,Z0(e)]:Z0(e):i,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!==er?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&&zn(t.ssContent),ssFallback:t.ssFallback&&zn(t.ssFallback),placeholder:t.placeholder,el:t.el,anchor:t.anchor,ctx:t.ctx,ce:t.ce};return l&&n&&_a(d,l.clone(d)),d}function Ru(t=" ",e=0){return Ht(Bs,null,t,e)}function Ko(t,e){const r=Ht(J0,null,t);return r.staticCount=e,r}function Sr(t="",e=!1){return e?(Ve(),gf(Kr,null,t)):Ht(Kr,null,t)}function dr(t){return t==null||typeof t=="boolean"?Ht(Kr):Ce(t)?Ht(er,null,t.slice()):Nu(t)?jr(t):Ht(Bs,null,String(t))}function jr(t){return t.el===null&&t.patchFlag!==-1||t.memo?t:zn(t)}function Ba(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 s=e.default;s&&(s._c&&(s._d=!1),Ba(t,s()),s._c&&(s._d=!0));return}else{r=32;const s=e._;!s&&!gu(e)?e._ctx=Ut:s===3&&Ut&&(Ut.slots._===1?e._=1:(e._=2,t.patchFlag|=1024))}else De(e)?(e={default:e,_ctx:Ut},r=32):(e=String(e),n&64?(r=16,e=[Ru(e)]):r=8);t.children=e,t.shapeFlag|=r}function yf(...t){const e={};for(let r=0;r<t.length;r++){const n=t[r];for(const s in n)if(s==="class")e.class!==n.class&&(e.class=Ln([e.class,n.class]));else if(s==="style")e.style=On([e.style,n.style]);else if(Rs(s)){const i=e[s],a=n[s];a&&i!==a&&!(Ce(i)&&i.includes(a))&&(e[s]=i?[].concat(i,a):a)}else s!==""&&(e[s]=n[s])}return e}function ar(t,e,r,n=null){mr(t,e,7,[r,n])}const wf=fu();let xf=0;function kf(t,e,r){const n=t.type,s=(e?e.appContext:t.appContext)||wf,i={uid:xf++,vnode:t,type:n,parent:e,appContext:s,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Ud(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:e?e.provides:Object.create(s.provides),ids:e?e.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:bu(n,s),emitsOptions:Eu(n,s),emit:null,emitted:null,propsDefaults:Ye,inheritAttrs:n.inheritAttrs,ctx:Ye,data:Ye,props:Ye,attrs:Ye,slots:Ye,refs:Ye,setupState:Ye,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 i.ctx={_:i},i.root=e?e.root:i,i.emit=cf.bind(null,i),t.ce&&t.ce(i),i}let Ct=null;const Sf=()=>Ct||Ut;let fs,Gi;{const t=Os(),e=(r,n)=>{let s;return(s=t[r])||(s=t[r]=[]),s.push(n),i=>{s.length>1?s.forEach(a=>a(i)):s[0](i)}};fs=e("__VUE_INSTANCE_SETTERS__",r=>Ct=r),Gi=e("__VUE_SSR_SETTERS__",r=>f0=r)}const b0=t=>{const e=Ct;return fs(t),t.scope.on(),()=>{t.scope.off(),fs(e)}},Yo=()=>{Ct&&Ct.scope.off(),fs(null)};function Iu(t){return t.vnode.shapeFlag&4}let f0=!1;function Tf(t,e=!1,r=!1){e&&Gi(e);const{props:n,children:s}=t.vnode,i=Iu(t);Kh(t,n,i,e),Zh(t,s,r||e);const a=i?Af(t,e):void 0;return e&&Gi(!1),a}function Af(t,e){const r=t.type;t.accessCache=Object.create(null),t.proxy=new Proxy(t.ctx,Bh);const{setup:n}=r;if(n){Rr();const s=t.setupContext=n.length>1?Cf(t):null,i=b0(t),a=v0(n,t,0,[t.props,s]),o=_c(a);if(Ir(),i(),(o||t.sp)&&!n0(t)&&lu(t),o){if(a.then(Yo,Yo),e)return a.then(l=>{Xo(t,l,e)}).catch(l=>{zs(l,t,0)});t.asyncDep=a}else Xo(t,a,e)}else _u(t,e)}function Xo(t,e,r){De(e)?t.type.__ssrInlineRender?t.ssrRender=e:t.render=e:it(e)&&(t.setupState=ru(e)),_u(t,r)}let Jo;function _u(t,e,r){const n=t.type;if(!t.render){if(!e&&Jo&&!n.render){const s=n.template||za(t).template;if(s){const{isCustomElement:i,compilerOptions:a}=t.appContext.config,{delimiters:o,compilerOptions:l}=n,c=yt(yt({isCustomElement:i,delimiters:o},a),l);n.render=Jo(s,c)}}t.render=n.render||tr}{const s=b0(t);Rr();try{Ph(t)}finally{Ir(),s()}}}const Ef={get(t,e){return wt(t,"get",""),t[e]}};function Cf(t){const e=r=>{t.exposed=r||{}};return{attrs:new Proxy(t.attrs,Ef),slots:t.slots,emit:t.emit,expose:e}}function Ps(t){return t.exposed?t.exposeProxy||(t.exposeProxy=new Proxy(ru(dh(t.exposed)),{get(e,r){if(r in e)return e[r];if(r in s0)return s0[r](t)},has(e,r){return r in e||r in s0}})):t.proxy}function Mf(t){return De(t)&&"__vccOpts"in t}const Ou=(t,e)=>vh(t,e,f0),Nf="3.5.20";/**
|
||
* @vue/runtime-dom v3.5.20
|
||
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
||
* @license MIT
|
||
**/let Ki;const Zo=typeof window<"u"&&window.trustedTypes;if(Zo)try{Ki=Zo.createPolicy("vue",{createHTML:t=>t})}catch{}const Lu=Ki?t=>Ki.createHTML(t):t=>t,Df="http://www.w3.org/2000/svg",Rf="http://www.w3.org/1998/Math/MathML",kr=typeof document<"u"?document:null,Qo=kr&&kr.createElement("template"),If={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 s=e==="svg"?kr.createElementNS(Df,t):e==="mathml"?kr.createElementNS(Rf,t):r?kr.createElement(t,{is:r}):kr.createElement(t);return t==="select"&&n&&n.multiple!=null&&s.setAttribute("multiple",n.multiple),s},createText:t=>kr.createTextNode(t),createComment:t=>kr.createComment(t),setText:(t,e)=>{t.nodeValue=e},setElementText:(t,e)=>{t.textContent=e},parentNode:t=>t.parentNode,nextSibling:t=>t.nextSibling,querySelector:t=>kr.querySelector(t),setScopeId(t,e){t.setAttribute(e,"")},insertStaticContent(t,e,r,n,s,i){const a=r?r.previousSibling:e.lastChild;if(s&&(s===i||s.nextSibling))for(;e.insertBefore(s.cloneNode(!0),r),!(s===i||!(s=s.nextSibling)););else{Qo.innerHTML=Lu(n==="svg"?`<svg>${t}</svg>`:n==="mathml"?`<math>${t}</math>`:t);const o=Qo.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]}},_f=Symbol("_vtc");function Of(t,e,r){const n=t[_f];n&&(e=(e?[e,...n]:[...n]).join(" ")),e==null?t.removeAttribute("class"):r?t.setAttribute("class",e):t.className=e}const ps=Symbol("_vod"),zu=Symbol("_vsh"),Lf={name:"show",beforeMount(t,{value:e},{transition:r}){t[ps]=t.style.display==="none"?"":t.style.display,r&&e?r.beforeEnter(t):Vn(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),Vn(t,!0),n.enter(t)):n.leave(t,()=>{Vn(t,!1)}):Vn(t,e))},beforeUnmount(t,{value:e}){Vn(t,e)}};function Vn(t,e){t.style.display=e?t[ps]:"none",t[zu]=!e}const zf=Symbol(""),Ff=/(^|;)\s*display\s*:/;function $f(t,e,r){const n=t.style,s=ut(r);let i=!1;if(r&&!s){if(e)if(ut(e))for(const a of e.split(";")){const o=a.slice(0,a.indexOf(":")).trim();r[o]==null&&Q0(n,o,"")}else for(const a in e)r[a]==null&&Q0(n,a,"");for(const a in r)a==="display"&&(i=!0),Q0(n,a,r[a])}else if(s){if(e!==r){const a=n[zf];a&&(r+=";"+a),n.cssText=r,i=Ff.test(r)}}else e&&t.removeAttribute("style");ps in t&&(t[ps]=i?n.display:"",t[zu]&&(n.display="none"))}const el=/\s*!important$/;function Q0(t,e,r){if(Ce(r))r.forEach(n=>Q0(t,e,n));else if(r==null&&(r=""),e.startsWith("--"))t.setProperty(e,r);else{const n=Bf(t,e);el.test(r)?t.setProperty(Qr(n),r.replace(el,""),"important"):t[n]=r}}const tl=["Webkit","Moz","ms"],fi={};function Bf(t,e){const r=fi[e];if(r)return r;let n=Wr(e);if(n!=="filter"&&n in t)return fi[e]=n;n=zc(n);for(let s=0;s<tl.length;s++){const i=tl[s]+n;if(i in t)return fi[e]=i}return e}const rl="http://www.w3.org/1999/xlink";function nl(t,e,r,n,s,i=jd(e)){n&&e.startsWith("xlink:")?r==null?t.removeAttributeNS(rl,e.slice(6,e.length)):t.setAttributeNS(rl,e,r):r==null||i&&!$c(r)?t.removeAttribute(e):t.setAttribute(e,i?"":Zr(r)?String(r):r)}function sl(t,e,r,n,s){if(e==="innerHTML"||e==="textContent"){r!=null&&(t[e]=e==="innerHTML"?Lu(r):r);return}const i=t.tagName;if(e==="value"&&i!=="PROGRESS"&&!i.includes("-")){const o=i==="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=$c(r):r==null&&o==="string"?(r="",a=!0):o==="number"&&(r=0,a=!0)}try{t[e]=r}catch{}a&&t.removeAttribute(s||e)}function An(t,e,r,n){t.addEventListener(e,r,n)}function Pf(t,e,r,n){t.removeEventListener(e,r,n)}const il=Symbol("_vei");function Hf(t,e,r,n,s=null){const i=t[il]||(t[il]={}),a=i[e];if(n&&a)a.value=n;else{const[o,l]=qf(e);if(n){const c=i[e]=Vf(n,s);An(t,o,c,l)}else a&&(Pf(t,o,a,l),i[e]=void 0)}}const al=/(?:Once|Passive|Capture)$/;function qf(t){let e;if(al.test(t)){e={};let n;for(;n=t.match(al);)t=t.slice(0,t.length-n[0].length),e[n[0].toLowerCase()]=!0}return[t[2]===":"?t.slice(3):Qr(t.slice(2)),e]}let pi=0;const jf=Promise.resolve(),Uf=()=>pi||(jf.then(()=>pi=0),pi=Date.now());function Vf(t,e){const r=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=r.attached)return;mr(Wf(n,r.value),e,5,[n])};return r.value=t,r.attached=Uf(),r}function Wf(t,e){if(Ce(e)){const r=t.stopImmediatePropagation;return t.stopImmediatePropagation=()=>{r.call(t),t._stopped=!0},e.map(n=>s=>!s._stopped&&n&&n(s))}else return e}const ol=t=>t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)>96&&t.charCodeAt(2)<123,Gf=(t,e,r,n,s,i)=>{const a=s==="svg";e==="class"?Of(t,n,a):e==="style"?$f(t,r,n):Rs(e)?xa(e)||Hf(t,e,r,n,i):(e[0]==="."?(e=e.slice(1),!0):e[0]==="^"?(e=e.slice(1),!1):Kf(t,e,n,a))?(sl(t,e,n),!t.tagName.includes("-")&&(e==="value"||e==="checked"||e==="selected")&&nl(t,e,n,a,i,e!=="value")):t._isVueCE&&(/[A-Z]/.test(e)||!ut(n))?sl(t,Wr(e),n,i,e):(e==="true-value"?t._trueValue=n:e==="false-value"&&(t._falseValue=n),nl(t,e,n,a))};function Kf(t,e,r,n){if(n)return!!(e==="innerHTML"||e==="textContent"||e in t&&ol(e)&&De(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 s=t.tagName;if(s==="IMG"||s==="VIDEO"||s==="CANVAS"||s==="SOURCE")return!1}return ol(e)&&ut(r)?!1:e in t}const ll=t=>{const e=t.props["onUpdate:modelValue"]||!1;return Ce(e)?r=>K0(e,r):e};function Yf(t){t.target.composing=!0}function cl(t){const e=t.target;e.composing&&(e.composing=!1,e.dispatchEvent(new Event("input")))}const mi=Symbol("_assign"),Pa={created(t,{modifiers:{lazy:e,trim:r,number:n}},s){t[mi]=ll(s);const i=n||s.props&&s.props.type==="number";An(t,e?"change":"input",a=>{if(a.target.composing)return;let o=t.value;r&&(o=o.trim()),i&&(o=$i(o)),t[mi](o)}),r&&An(t,"change",()=>{t.value=t.value.trim()}),e||(An(t,"compositionstart",Yf),An(t,"compositionend",cl),An(t,"change",cl))},mounted(t,{value:e}){t.value=e??""},beforeUpdate(t,{value:e,oldValue:r,modifiers:{lazy:n,trim:s,number:i}},a){if(t[mi]=ll(a),t.composing)return;const o=(i||t.type==="number")&&!/^0\d/.test(t.value)?$i(t.value):t.value,l=e??"";o!==l&&(document.activeElement===t&&t.type!=="range"&&(n&&e===r||s&&t.value.trim()===l)||(t.value=l))}},Xf=["ctrl","shift","alt","meta"],Jf={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)=>Xf.some(r=>t[`${r}Key`]&&!e.includes(r))},gi=(t,e)=>{const r=t._withMods||(t._withMods={}),n=e.join(".");return r[n]||(r[n]=(s,...i)=>{for(let a=0;a<e.length;a++){const o=Jf[e[a]];if(o&&o(s,e))return}return t(s,...i)})},Zf={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},vi=(t,e)=>{const r=t._withKeys||(t._withKeys={}),n=e.join(".");return r[n]||(r[n]=s=>{if(!("key"in s))return;const i=Qr(s.key);if(e.some(a=>a===i||Zf[a]===i))return t(s)})},Qf=yt({patchProp:Gf},If);let ul;function ep(){return ul||(ul=ef(Qf))}const tp=(...t)=>{const e=ep().createApp(...t),{mount:r}=e;return e.mount=n=>{const s=np(n);if(!s)return;const i=e._component;!De(i)&&!i.render&&!i.template&&(i.template=s.innerHTML),s.nodeType===1&&(s.textContent="");const a=r(s,!1,rp(s));return s instanceof Element&&(s.removeAttribute("v-cloak"),s.setAttribute("data-v-app","")),a},e};function rp(t){if(t instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&t instanceof MathMLElement)return"mathml"}function np(t){return ut(t)?document.querySelector(t):t}var sp=Object.defineProperty,ip=(t,e,r)=>e in t?sp(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,I0=(t,e,r)=>(ip(t,typeof e!="symbol"?e+"":e,r),r);const Ha={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"}},qa={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 Yi(t){return t.replace(/&/g,"&").replace(/</g,"<").replace(/"/g,""")}const ms=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=ms(t,e.children[r]);if(n)return n}return null}else return null},en=(t,e)=>{if(t.parent=e,t.children)for(let r=0;r<t.children.length;r++)en(t.children[r],t)},In=(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(s=>{In(s,e,n)})}else t.children.forEach(n=>{In(n,!1)})};function ja(t){if(t.id=gn(),t.children)for(let e=0;e<t.children.length;e++)ja(t.children[e])}function gs(t,e,r,n){const s=n-e,i=t-r;let a=Math.atan(Math.abs(s)/Math.abs(i))/3.14*180;if(isNaN(a))return;i<0&&s>0&&(a=180-a),i<0&&s<0&&(a=180+a),i>0&&s<0&&(a=360-a);const o=12,l=30,c=a+l,d=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*d/180)*o,y2:n-Math.sin(Math.PI*d/180)*o}}function gn(){return(new Date().getTime().toString(16)+Math.random().toString(16).substr(2)).substr(2,16)}const ap=function(){const t=gn();return{topic:this.newTopicName,id:t}};function Ua(t){return JSON.parse(JSON.stringify(t,(e,r)=>{if(e!=="parent")return r}))}const tn=(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}},ft=(t,e)=>{for(const r in e)t.setAttribute(r,e[r])},Xi=t=>t?t.tagName==="ME-TPC":!1,Hs=t=>t.filter(e=>e.nodeObj.parent).filter((e,r,n)=>{for(let s=0;s<n.length;s++){if(e===n[s])continue;const{parent:i}=e.nodeObj;if(i===n[s].nodeObj)return!1}return!0}),Fu=t=>{const e=/translate\(([^,]+),\s*([^)]+)\)/,r=t.match(e);return r?{x:parseFloat(r[1]),y:parseFloat(r[2])}:{x:0,y:0}},Va=function(t){for(let e=0;e<t.length;e++){const{dom:r,evt:n,func:s}=t[e];r.addEventListener(n,s)}return function(){for(let e=0;e<t.length;e++){const{dom:r,evt:n,func:s}=t[e];r.removeEventListener(n,s)}}};var sr=(t=>(t.LHS="lhs",t.RHS="rhs",t))(sr||{});const op=t=>{const e=t.map.querySelectorAll(".lhs>me-wrapper>me-parent>me-tpc");t.selectNode(e[Math.ceil(e.length/2)-1])},lp=t=>{const e=t.map.querySelectorAll(".rhs>me-wrapper>me-parent>me-tpc");t.selectNode(e[Math.ceil(e.length/2)-1])},cp=t=>{t.selectNode(t.map.querySelector("me-root>me-tpc"))},up=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)}},dl=function(t,e){var r,n;const s=t.currentNode||((r=t.currentNodes)==null?void 0:r[0]);if(!s)return;const i=s.nodeObj,a=s.offsetParent.offsetParent.parentElement;i.parent?a.className===e?dp(t,s):(n=i.parent)!=null&&n.parent?up(t,s):cp(t):e===sr.LHS?op(t):lp(t)},hl=function(t,e){const r=t.currentNode;if(!r||!r.nodeObj.parent)return;const n=e+"Sibling",s=r.parentElement.parentElement[n];s?t.selectNode(s.firstChild.firstChild):t.selectNode(r)},vs=function(t,e,r){const{scaleVal:n,scaleSensitivity:s}=t;switch(e){case"in":t.scale(n+s,r);break;case"out":t.scale(n-s,r)}};function hp(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,s=null;const i=o=>{const l=t.nodeData;if(o.key==="0")for(const c of l.children)In(c,!1);if(o.key==="=")for(const c of l.children)In(c,!0);if(["1","2","3","4","5","6","7","8","9"].includes(o.key))for(const c of l.children)In(c,!0,Number(o.key)-1);t.refresh(),t.toCenter(),n=!1,s&&(clearTimeout(s),s=null,t.container.removeEventListener("keydown",i))},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();hl(t,"previous")}},ArrowDown:o=>{o.altKey?t.moveDownNode():hl(t,"next")},ArrowLeft:o=>{if(o.metaKey||o.ctrlKey)return t.initLeft();dl(t,sr.LHS)},ArrowRight:o=>{if(o.metaKey||o.ctrlKey)return t.initRight();dl(t,sr.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)&&vs(t,"in")},"-":o=>{(o.metaKey||o.ctrlKey)&&vs(t,"out")},0:o=>{if(o.metaKey||o.ctrlKey){if(n)return;t.scale(1)}},k:o=>{(o.metaKey||o.ctrlKey)&&(n=!0,s&&(clearTimeout(s),t.container.removeEventListener("keydown",i)),s=window.setTimeout(()=>{n=!1,s=null},2e3),t.container.addEventListener("keydown",i))},Delete:r,Backspace:r,...e};t.container.onkeydown=o=>{if(o.preventDefault(),!t.editable)return;const l=a[o.key];l&&l(o)}}function fp(t){const{dragMoveHelper:e}=t,r=p=>{var b,v,x;if(p.button!==0)return;if((b=t.helper1)!=null&&b.moved){t.helper1.clear();return}if((v=t.helper2)!=null&&v.moved){t.helper2.clear();return}if(e.moved){e.clear();return}const y=p.target;if(y.tagName==="ME-EPD")p.ctrlKey||p.metaKey?t.expandNodeAll(y.previousSibling):t.expandNode(y.previousSibling);else if(y.tagName==="ME-TPC"&&t.currentNodes.length>1)t.selectNode(y);else if(!t.editable)return;const M=(x=y.parentElement)==null?void 0:x.parentElement;M.getAttribute("class")==="topiclinks"?t.selectArrow(y.parentElement):M.getAttribute("class")==="summary"&&t.selectSummary(y.parentElement)},n=p=>{var b;if(!t.editable)return;const v=p.target;Xi(v)&&t.beginEdit(v);const x=(b=v.parentElement)==null?void 0:b.parentElement;x.getAttribute("class")==="topiclinks"?t.editArrowLabel(v.parentElement):x.getAttribute("class")==="summary"&&t.editSummary(v.parentElement)};let s=0;const i=p=>{if(p.pointerType==="mouse")return;const b=new Date().getTime(),v=b-s;v<300&&v>0&&n(p),s=b},a=p=>{e.moved=!1;const b=t.mouseSelectionButton===0?2:0;if(p.button!==b&&p.pointerType==="mouse")return;e.x=p.clientX,e.y=p.clientY;const v=p.target;v.className!=="circle"&&v.contentEditable!=="plaintext-only"&&(e.mousedown=!0,v.setPointerCapture(p.pointerId))},o=p=>{if(p.target.contentEditable!=="plaintext-only"){const b=p.clientX-e.x,v=p.clientY-e.y;e.onMove(b,v)}e.x=p.clientX,e.y=p.clientY},l=p=>{const b=t.mouseSelectionButton===0?2:0;if(p.button!==b&&p.pointerType==="mouse")return;const v=p.target;v.hasPointerCapture&&v.hasPointerCapture(p.pointerId)&&v.releasePointerCapture(p.pointerId),e.clear()},c=p=>{if(p.preventDefault(),p.button!==2||!t.editable)return;const b=p.target;Xi(b)&&!b.classList.contains("selected")&&t.selectNode(b),setTimeout(()=>{t.dragMoveHelper.moved||t.bus.fire("showContextMenu",p)},200)},d=p=>{p.stopPropagation(),p.preventDefault(),p.ctrlKey||p.metaKey?p.deltaY<0?vs(t,"in",t.dragMoveHelper):t.scaleVal-t.scaleSensitivity>0&&vs(t,"out",t.dragMoveHelper):p.shiftKey?t.move(-p.deltaY,0):t.move(-p.deltaX,-p.deltaY)},{container:f}=t;return Va([{dom:f,evt:"pointerdown",func:a},{dom:f,evt:"pointermove",func:o},{dom:f,evt:"pointerup",func:l},{dom:f,evt:"pointerup",func:i},{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:d}])}function pp(){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 bs=document,mp=function(){this.nodes.innerHTML="";const t=this.createTopic(this.nodeData);Wa.call(this,t,this.nodeData),t.draggable=!1;const e=bs.createElement("me-root");e.appendChild(t);const r=this.nodeData.children||[];if(this.direction===2){let n=0,s=0;r.map(i=>{i.direction===0?n+=1:i.direction===1?s+=1:n<=s?(i.direction=0,n+=1):(i.direction=1,s+=1)})}gp(this,r,e)},gp=function(t,e,r){const n=bs.createElement("me-main");n.className=sr.LHS;const s=bs.createElement("me-main");s.className=sr.RHS;for(let i=0;i<e.length;i++){const a=e[i],{grp:o}=t.createWrapper(a);t.direction===2?a.direction===0?n.appendChild(o):s.appendChild(o):t.direction===0?n.appendChild(o):s.appendChild(o)}t.nodes.appendChild(n),t.nodes.appendChild(r),t.nodes.appendChild(s),t.nodes.appendChild(t.lines)},vp=function(t,e){const r=bs.createElement("me-children");for(let n=0;n<e.length;n++){const s=e[n],{grp:i}=t.createWrapper(s);r.appendChild(i)}return r},$t=document,$u=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},Wa=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){t.innerHTML=e.dangerouslySetInnerHTML;return}if(e.image){const r=e.image;if(r.url&&r.width&&r.height){const n=$t.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=$t.createElement("span");r.className="text",this.markdown?r.innerHTML=this.markdown(e.topic,e):r.textContent=e.topic,t.appendChild(r),t.text=r}if(e.hyperLink){const r=$t.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=$t.createElement("span");r.className="icons",r.innerHTML=e.icons.map(n=>`<span>${Yi(n)}</span>`).join(""),t.appendChild(r),t.icons=r}else t.icons&&(t.icons=void 0);if(e.tags&&e.tags.length){const r=$t.createElement("div");r.className="tags",e.tags.forEach(n=>{const s=$t.createElement("span");typeof n=="string"?s.textContent=n:(s.textContent=n.text,n.className&&(s.className=n.className),n.style&&Object.assign(s.style,n.style)),r.appendChild(s)}),t.appendChild(r),t.tags=r}else t.tags&&(t.tags=void 0)},bp=function(t,e){const r=$t.createElement("me-wrapper"),{p:n,tpc:s}=this.createParent(t);if(r.appendChild(n),!e&&t.children&&t.children.length>0){const i=Ga(t.expanded);if(n.appendChild(i),t.expanded!==!1){const a=vp(this,t.children);r.appendChild(a)}}return{grp:r,top:n,tpc:s}},yp=function(t){const e=$t.createElement("me-parent"),r=this.createTopic(t);return Wa.call(this,r,t),e.appendChild(r),{p:e,tpc:r}},wp=function(t){const e=$t.createElement("me-children");return e.append(...t),e},xp=function(t){const e=$t.createElement("me-tpc");return e.nodeObj=t,e.dataset.nodeid="me"+t.id,e.draggable=this.draggable,e};function Bu(t){const e=$t.createRange();e.selectNodeContents(t);const r=window.getSelection();r&&(r.removeAllRanges(),r.addRange(e))}const kp=function(t){if(!t)return;const e=$t.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 s=getComputedStyle(t);e.style.cssText=`min-width:${t.offsetWidth-8}px;
|
||
color:${s.color};
|
||
padding:${s.padding};
|
||
margin:${s.margin};
|
||
font:${s.font};
|
||
background-color:${s.backgroundColor!=="rgba(0, 0, 0, 0)"&&s.backgroundColor};
|
||
border-radius:${s.borderRadius};`,this.direction===0&&(e.style.right="0"),Bu(e),this.bus.fire("operation",{name:"beginEdit",obj:t.nodeObj}),e.addEventListener("keydown",i=>{i.stopPropagation();const a=i.key;if(a==="Enter"||a==="Tab"){if(i.shiftKey)return;i.preventDefault(),e.blur(),this.container.focus()}}),e.addEventListener("blur",()=>{var i;if(!e)return;const a=((i=e.textContent)==null?void 0:i.trim())||"";a===""?r.topic=n:(r.topic=a,this.markdown?t.text.innerHTML=this.markdown(r.topic,r):t.text.textContent=a),e.remove(),a!==n&&(this.linkDiv(),this.bus.fire("operation",{name:"finishEdit",obj:r,origin:n}))})},Ga=function(t){const e=$t.createElement("me-epd");return e.expanded=t!==!1,e.className=t!==!1?"minus":"",e},fn=document,Gt="http://www.w3.org/2000/svg",Ji=function(t,e,r,n={}){const{anchor:s="middle",color:i,dataType:a}=n,o=document.createElementNS(Gt,"text");return ft(o,{"text-anchor":s,x:e+"",y:r+"",fill:i||(s==="middle"?"rgb(235, 95, 82)":"#666")}),a&&(o.dataset.type=a),o.innerHTML=t,o},Pu=function(t,e,r){const n=fn.createElementNS(Gt,"path");return ft(n,{d:t,stroke:e||"#666",fill:"none","stroke-width":r}),n},Jn=function(t){const e=fn.createElementNS(Gt,"svg");return e.setAttribute("class",t),e.setAttribute("overflow","visible"),e},fl=function(){const t=fn.createElementNS(Gt,"line");return t.setAttribute("stroke","#4dc4ff"),t.setAttribute("fill","none"),t.setAttribute("stroke-width","2"),t.setAttribute("opacity","0.45"),t},Sp=function(t,e,r,n){const s=fn.createElementNS(Gt,"g");return[{name:"line",d:t},{name:"arrow1",d:e},{name:"arrow2",d:r}].forEach((i,a)=>{const o=i.d,l=fn.createElementNS(Gt,"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)),ft(l,c),a===0&&l.setAttribute("stroke-dasharray",(n==null?void 0:n.strokeDasharray)||"8,2");const d=fn.createElementNS(Gt,"path");ft(d,{d:o,stroke:"transparent",fill:"none","stroke-width":"15"}),s.appendChild(d),s.appendChild(l),s[i.name]=l}),s},Hu=function(t,e,r){if(!e)return;const n=fn.createElement("div");t.nodes.appendChild(n);const s=e.innerHTML;n.id="input-box",n.textContent=s,n.contentEditable="plaintext-only",n.spellcheck=!1;const i=e.getBBox();n.style.cssText=`
|
||
min-width:${Math.max(88,i.width)}px;
|
||
position:absolute;
|
||
left:${i.x}px;
|
||
top:${i.y}px;
|
||
padding: 2px 4px;
|
||
margin: -2px -4px;
|
||
`,Bu(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=s:r.label=o,n.remove(),o!==s&&(e.innerHTML=r.label,"parent"in r?t.bus.fire("operation",{name:"finishEditSummary",obj:r}):t.bus.fire("operation",{name:"finishEditArrowLabel",obj:r}))})},Tp=function(t){const e=this.map.querySelector("me-root"),r=e.offsetTop,n=e.offsetLeft,s=e.offsetWidth,i=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:d,offsetTop:f}=tn(this.nodes,c),p=c.offsetWidth,b=c.offsetHeight,v=l.parentNode.className,x=this.generateMainBranch({pT:r,pL:n,pW:s,pH:i,cT:f,cL:d,cW:p,cH:b,direction:v,containerHeight:this.nodes.offsetHeight}),y=this.theme.palette,M=c.nodeObj.branchColor||y[o%y.length];if(c.style.borderColor=M,this.lines.appendChild(Pu(x,M,"3")),t&&t!==l)continue;const k=Jn("subLines"),T=l.lastChild;T.tagName==="svg"&&T.remove(),l.appendChild(k),qu(this,k,M,l,v,!0)}this.renderArrow(),this.renderSummary(),this.bus.fire("linkDiv")},qu=function(t,e,r,n,s,i){const a=n.firstChild,o=n.children[1].children;if(o.length===0)return;const l=a.offsetTop,c=a.offsetLeft,d=a.offsetWidth,f=a.offsetHeight;for(let p=0;p<o.length;p++){const b=o[p],v=b.firstChild,x=v.offsetTop,y=v.offsetLeft,M=v.offsetWidth,k=v.offsetHeight,T=v.firstChild.nodeObj.branchColor||r,N=t.generateSubBranch({pT:l,pL:c,pW:d,pH:f,cT:x,cL:y,cW:M,cH:k,direction:s,isFirst:i});e.appendChild(Pu(N,T,"2"));const I=v.children[1];if(I){if(!I.expanded)continue}else continue;qu(t,e,T,b,s)}},pl={addChild:"插入子节点",addParent:"插入父节点",addSibling:"插入同级节点",removeNode:"删除节点",focus:"专注",cancelFocus:"取消专注",moveUp:"上移",moveDown:"下移",link:"连接",linkBidirectional:"双向连接",clickTips:"请点击目标节点",summary:"摘要"},ml={cn:pl,zh_CN:pl,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 Ap(t,e){e=e===!0?{focus:!0,link:!0}:e;const r=O=>{const z=document.createElement("div");return z.innerText=O,z.className="tips",z},n=(O,z,W)=>{const U=document.createElement("li");return U.id=O,U.innerHTML=`<span>${Yi(z)}</span><span ${W?'class="key"':""}>${Yi(W)}</span>`,U},s=ml[t.locale]?t.locale:"en",i=ml[s],a=n("cm-add_child",i.addChild,"Tab"),o=n("cm-add_parent",i.addParent,"Ctrl + Enter"),l=n("cm-add_sibling",i.addSibling,"Enter"),c=n("cm-remove_child",i.removeNode,"Delete"),d=n("cm-fucus",i.focus,""),f=n("cm-unfucus",i.cancelFocus,""),p=n("cm-up",i.moveUp,"PgUp"),b=n("cm-down",i.moveDown,"Pgdn"),v=n("cm-link",i.link,""),x=n("cm-link-bidirectional",i.linkBidirectional,""),y=n("cm-summary",i.summary,""),M=document.createElement("ul");if(M.className="menu-list",M.appendChild(a),M.appendChild(o),M.appendChild(l),M.appendChild(c),e.focus&&(M.appendChild(d),M.appendChild(f)),M.appendChild(p),M.appendChild(b),M.appendChild(y),e.link&&(M.appendChild(v),M.appendChild(x)),e&&e.extend)for(let O=0;O<e.extend.length;O++){const z=e.extend[O],W=n(z.name,z.name,z.key||"");M.appendChild(W),W.onclick=U=>{z.onclick(U)}}const k=document.createElement("div");k.className="context-menu",k.appendChild(M),k.hidden=!0,t.container.append(k);let T=!0;const N=O=>{const z=O.target;if(Xi(z)){z.parentElement.tagName==="ME-ROOT"?T=!0:T=!1,T?(d.className="disabled",p.className="disabled",b.className="disabled",o.className="disabled",l.className="disabled",c.className="disabled"):(d.className="",p.className="",b.className="",o.className="",l.className="",c.className=""),k.hidden=!1,M.style.top="",M.style.bottom="",M.style.left="",M.style.right="";const W=M.getBoundingClientRect(),U=M.offsetHeight,he=M.offsetWidth,ge=O.clientY-W.top,Ae=O.clientX-W.left;U+ge>window.innerHeight?(M.style.top="",M.style.bottom="0px"):(M.style.bottom="",M.style.top=ge+15+"px"),he+Ae>window.innerWidth?(M.style.left="",M.style.right="0px"):(M.style.right="",M.style.left=Ae+10+"px")}};t.bus.addListener("showContextMenu",N),k.onclick=O=>{O.target===k&&(k.hidden=!0)},a.onclick=()=>{t.addChild(),k.hidden=!0},o.onclick=()=>{t.insertParent(),k.hidden=!0},l.onclick=()=>{T||(t.insertSibling("after"),k.hidden=!0)},c.onclick=()=>{T||(t.removeNodes(t.currentNodes||[]),k.hidden=!0)},d.onclick=()=>{T||(t.focusNode(t.currentNode),k.hidden=!0)},f.onclick=()=>{t.cancelFocus(),k.hidden=!0},p.onclick=()=>{T||(t.moveUpNode(),k.hidden=!0)},b.onclick=()=>{T||(t.moveDownNode(),k.hidden=!0)};const I=O=>{k.hidden=!0;const z=t.currentNode,W=r(i.clickTips);t.container.appendChild(W),t.map.addEventListener("click",U=>{U.preventDefault(),W.remove();const he=U.target;(he.parentElement.tagName==="ME-PARENT"||he.parentElement.tagName==="ME-ROOT")&&t.createArrow(z,he,O)},{once:!0})};return v.onclick=()=>I(),x.onclick=()=>I({bidirectional:!0}),y.onclick=()=>{k.hidden=!0,t.createSummary(),t.unselectNodes(t.currentNodes)},()=>{a.onclick=null,o.onclick=null,l.onclick=null,c.onclick=null,d.onclick=null,f.onclick=null,p.onclick=null,b.onclick=null,v.onclick=null,y.onclick=null,k.onclick=null,t.container.oncontextmenu=null}}const Zi=document,Ep=function(t,e){if(!e)return Qi(t),t;let r=t.querySelector(".insert-preview");const n=`insert-preview ${e} show`;return r||(r=Zi.createElement("div"),t.appendChild(r)),r.className=n,t},Qi=function(t){if(!t)return;const e=t.querySelectorAll(".insert-preview");for(const r of e||[])r.remove()},gl=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},Cp=function(t){const e=document.createElement("div");return e.className="mind-elixir-ghost",t.container.appendChild(e),e};class Mp{constructor(e){I0(this,"mind"),I0(this,"isMoving",!1),I0(this,"interval",null),I0(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 Np(t){let e=null,r=null;const n=Cp(t),s=new Mp(t),i=l=>{t.selection.cancel();const c=l.target;if((c==null?void 0:c.tagName)!=="ME-TPC"){l.preventDefault();return}let d=t.currentNodes;d!=null&&d.includes(c)||(t.selectNode(c),d=t.currentNodes),t.dragged=d,d.length>1?n.innerHTML=d.length+"":n.innerHTML=c.innerHTML;for(const f of d)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;s.stop();for(const f of c)f.parentElement.parentElement.style.opacity="1";const d=l.target;d.style.opacity="",r&&(Qi(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:d}=t;if(!d)return;const f=t.container.getBoundingClientRect();l.clientX<f.x+50?s.move(1,0):l.clientX>f.x+f.width-50?s.move(-1,0):l.clientY<f.y+50?s.move(0,1):l.clientY>f.y+f.height-50?s.move(0,-1):s.stop(),Qi(r);const p=Zi.elementFromPoint(l.clientX,l.clientY-c);if(gl(p,d)){r=p;const b=p.getBoundingClientRect(),v=b.y;l.clientY>v+b.height?e="after":e="in"}else{const b=Zi.elementFromPoint(l.clientX,l.clientY+c),v=b.getBoundingClientRect();if(gl(b,d)){r=b;const x=v.y;l.clientY<x?e="before":e="in"}else e=r=null}r&&Ep(r,e)};return Va([{dom:t.map,evt:"dragstart",func:i},{dom:t.map,evt:"dragend",func:a},{dom:t.map,evt:"dragover",func:o}])}const Dp=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 Rp(t){let e=[],r=-1,n=t.getData(),s=[];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 i=function(l){if(l.name==="beginEdit")return;e=e.slice(0,r+1);const c=t.getData(),d={prev:n,operation:l.name,currentSelected:s.map(f=>f.id),currentTarget:Dp(l),next:c};e.push(d),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){s=t.currentNodes.map(c=>c.nodeObj)};return t.bus.addListener("operation",i),t.bus.addListener("selectNodes",o),t.container.addEventListener("keydown",a),()=>{t.bus.removeListener("operation",i),t.bus.removeListener("selectNodes",o),t.container.removeEventListener("keydown",a)}}const Ip='<?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>',_p='<?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>',Op='<?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>',Lp='<?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>',zp='<?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>',Fp='<?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>',$p='<?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>',Bp={side:Ip,left:_p,right:Op,full:Lp,living:zp,zoomin:Fp,zoomout:$p},un=(t,e)=>{const r=document.createElement("span");return r.id=t,r.innerHTML=Bp[e],r};function Pp(t){const e=document.createElement("div"),r=un("fullscreen","full"),n=un("toCenter","living"),s=un("zoomout","zoomout"),i=un("zoomin","zoomin"),a=document.createElement("span");return a.innerText="100%",e.appendChild(r),e.appendChild(n),e.appendChild(s),e.appendChild(i),e.className="mind-elixir-toolbar rb",r.onclick=()=>{document.fullscreenElement===t.el?document.exitFullscreen():t.el.requestFullscreen()},n.onclick=()=>{t.toCenter()},s.onclick=()=>{t.scale(t.scaleVal-t.scaleSensitivity)},i.onclick=()=>{t.scale(t.scaleVal+t.scaleSensitivity)},e}function Hp(t){const e=document.createElement("div"),r=un("tbltl","left"),n=un("tbltr","right"),s=un("tblts","side");return e.appendChild(r),e.appendChild(n),e.appendChild(s),e.className="mind-elixir-toolbar lt",r.onclick=()=>{t.initLeft()},n.onclick=()=>{t.initRight()},s.onclick=()=>{t.initSide()},e}function qp(t){t.container.append(Pp(t)),t.container.append(Hp(t))}/*! @viselect/vanilla v3.9.0 MIT | https://github.com/Simonwep/selection/tree/master/packages/vanilla */class jp{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 s of this._listeners.get(e)??[])n=s(...r)!==!1&&n;return n}unbindAllListeners(){this._listeners.clear()}}const vl=(t,e="px")=>typeof t=="number"?t+e:t,$r=({style:t},e,r)=>{if(typeof e=="object")for(const[n,s]of Object.entries(e))s!==void 0&&(t[n]=vl(s));else r!==void 0&&(t[e]=vl(r))},bl=(t=0,e=0,r=0,n=0)=>{const s={x:t,y:e,width:r,height:n,top:e,left:t,right:t+r,bottom:e+n};return{...s,toJSON:()=>JSON.stringify(s)}},Up=t=>{let e,r=-1,n=!1;return{next:(...s)=>{e=s,n||(n=!0,r=requestAnimationFrame(()=>{t(...e),n=!1}))},cancel:()=>{cancelAnimationFrame(r),n=!1}}},yl=(t,e,r="touch")=>{switch(r){case"center":{const n=e.left+e.width/2,s=e.top+e.height/2;return n>=t.left&&n<=t.right&&s>=t.top&&s<=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}},Vp=()=>matchMedia("(hover: none), (pointer: coarse)").matches,Wp=()=>"safari"in window,ea=t=>Array.isArray(t)?t:[t],ju=t=>(e,r,n,s={})=>{(e instanceof HTMLCollection||e instanceof NodeList)&&(e=Array.from(e)),r=ea(r),e=ea(e);for(const i of e)if(i)for(const a of r)i[t](a,n,{capture:!1,...s})},Br=ju("addEventListener"),Zt=ju("removeEventListener"),_0=t=>{var e;const{clientX:r,clientY:n,target:s}=((e=t.touches)==null?void 0:e[0])??t;return{x:r,y:n,target:s}},xn=(t,e=document)=>ea(t).map(r=>typeof r=="string"?Array.from(e.querySelectorAll(r)):r instanceof Element?r:null).flat().filter(Boolean),Gp=(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:an,max:wl,min:xl,ceil:kl}=Math,Sl=(t=[])=>({stored:t,selected:[],touched:[],changed:{added:[],removed:[]}}),Uu=class extends jp{constructor(e){var r,n,s,i,a;super(),this._selection=Sl(),this._targetBoundaryScrolled=!0,this._selectables=[],this._areaLocation={y1:0,x2:0,y2:0,x1:0},this._areaRect=bl(),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",...e,behaviour:{overlap:"invert",intersect:"touch",triggers:[0],...e.behaviour,startThreshold:(r=e.behaviour)!=null&&r.startThreshold?typeof e.behaviour.startThreshold=="number"?e.behaviour.startThreshold:{x:10,y:10,...e.behaviour.startThreshold}:{x:10,y:10},scrolling:{speedDivider:10,manualSpeed:750,...(n=e.behaviour)==null?void 0:n.scrolling,startScrollMargins:{x:0,y:0,...(i=(s=e.behaviour)==null?void 0:s.scrolling)==null?void 0:i.startScrollMargins}}},features:{range:!0,touch:!0,deselectOnBlur:!1,...e.features,singleTap:{allow:!0,intersect:"native",...(a=e.features)==null?void 0:a.singleTap}}};for(const d of Object.getOwnPropertyNames(Object.getPrototypeOf(this)))typeof this[d]=="function"&&(this[d]=this[d].bind(this));const{document:o,selectionAreaClass:l,selectionContainerClass:c}=this._options;this._area=o.createElement("div"),this._clippingElement=o.createElement("div"),this._clippingElement.appendChild(this._area),this._area.classList.add(l),c&&this._clippingElement.classList.add(c),$r(this._area,{willChange:"top, left, bottom, right, width, height",top:0,left:0,position:"fixed"}),$r(this._clippingElement,{overflow:"hidden",position:"fixed",transform:"translate3d(0, 0, 0)",pointerEvents:"none",zIndex:"1"}),this._frame=Up(d=>{this._recalculateSelectionAreaRect(),this._updateElementSelection(),this._emitEvent("move",d),this._redrawSelectionArea()}),this.enable()}_toggleStartEvents(e=!0){const{document:r,features:n}=this._options,s=e?Br:Zt;s(r,"mousedown",this._onTapStart),n.touch&&s(r,"touchstart",this._onTapStart,{passive:!1})}_onTapStart(e,r=!1){const{x:n,y:s,target:i}=_0(e),{document:a,startAreas:o,boundaries:l,features:c,behaviour:d}=this._options,f=i.getBoundingClientRect();if(e instanceof MouseEvent&&!Gp(e,d.triggers))return;const p=xn(o,a),b=xn(l,a);this._targetElement=b.find(M=>yl(M.getBoundingClientRect(),f));const v=e.composedPath(),x=p.find(M=>v.includes(M));if(this._targetBoundary=b.find(M=>v.includes(M)),!this._targetElement||!x||!this._targetBoundary||!r&&this._emitEvent("beforestart",e)===!1)return;this._areaLocation={x1:n,y1:s,x2:0,y2:0};const y=a.scrollingElement??a.body;this._scrollDelta={x:y.scrollLeft,y:y.scrollTop},this._singleClick=!0,this.clearSelection(!1,!0),Br(a,["touchmove","mousemove"],this._delayedTapMove,{passive:!1}),Br(a,["mouseup","touchcancel","touchend"],this._onTapStop),Br(a,"scroll",this._onScroll),c.deselectOnBlur&&(this._targetBoundaryScrolled=!1,Br(this._targetBoundary,"scroll",this._onStartAreaScroll))}_onSingleTap(e){const{singleTap:{intersect:r},range:n}=this._options.features,s=_0(e);let i;if(r==="native")i=s.target;else if(r==="touch"){this.resolveSelectables();const{x:o,y:l}=s;i=this._selectables.find(c=>{const{right:d,left:f,top:p,bottom:b}=c.getBoundingClientRect();return o<d&&o>f&&l<b&&l>p})}if(!i)return;for(this.resolveSelectables();!this._selectables.includes(i);)if(i.parentElement)i=i.parentElement;else{this._targetBoundaryScrolled||this.clearSelection();return}const{stored:a}=this._selection;if(this._emitEvent("start",e),e.shiftKey&&n&&this._latestElement){const o=this._latestElement,[l,c]=o.compareDocumentPosition(i)&4?[i,o]:[o,i],d=[...this._selectables.filter(f=>f.compareDocumentPosition(l)&4&&f.compareDocumentPosition(c)&2),l,c];this.select(d),this._latestElement=o}else a.includes(i)&&(a.length===1||e.ctrlKey||a.every(o=>this._selection.stored.includes(o)))?this.deselect(i):(this.select(i),this._latestElement=i)}_delayedTapMove(e){const{container:r,document:n,behaviour:{startThreshold:s}}=this._options,{x1:i,y1:a}=this._areaLocation,{x:o,y:l}=_0(e);if(typeof s=="number"&&an(o+l-(i+a))>=s||typeof s=="object"&&an(o-i)>=s.x||an(l-a)>=s.y){if(Zt(n,["mousemove","touchmove"],this._delayedTapMove,{passive:!1}),this._emitEvent("beforedrag",e)===!1){Zt(n,["mouseup","touchcancel","touchend"],this._onTapStop);return}Br(n,["mousemove","touchmove"],this._onTapMove,{passive:!1}),$r(this._area,"display","block"),xn(r,n)[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&&(Br(this._targetElement,"wheel",this._wheelScroll,{passive:!1}),Br(this._options.document,"keydown",this._keyboardScroll,{passive:!1}),this._selectables=this._selectables.filter(c=>this._targetElement.contains(c))),this._setupSelectionArea(),this._emitEvent("start",e),this._onTapMove(e)}this._handleMoveEvent(e)}_setupSelectionArea(){const{_clippingElement:e,_targetElement:r,_area:n}=this,s=this._targetRect=r.getBoundingClientRect();this._scrollAvailable?($r(e,{top:s.top,left:s.left,width:s.width,height:s.height}),$r(n,{marginTop:-s.top,marginLeft:-s.left})):($r(e,{top:0,left:0,width:"100%",height:"100%"}),$r(n,{marginTop:0,marginLeft:0}))}_onTapMove(e){const{_scrollSpeed:r,_areaLocation:n,_options:s,_frame:i}=this,{speedDivider:a}=s.behaviour.scrolling,o=this._targetElement,{x:l,y:c}=_0(e);if(n.x2=l,n.y2=c,this._lastMousePosition.x=l,this._lastMousePosition.y=c,this._scrollAvailable&&!this._scrollingActive&&(r.y||r.x)){this._scrollingActive=!0;const d=()=>{if(!r.x&&!r.y){this._scrollingActive=!1;return}const{scrollTop:f,scrollLeft:p}=o;r.y&&(o.scrollTop+=kl(r.y/a),n.y1-=o.scrollTop-f),r.x&&(o.scrollLeft+=kl(r.x/a),n.x1-=o.scrollLeft-p),i.next(e),requestAnimationFrame(d)};requestAnimationFrame(d)}else i.next(e);this._handleMoveEvent(e)}_handleMoveEvent(e){const{features:r}=this._options;(r.touch&&Vp()||this._scrollAvailable&&Wp())&&e.preventDefault()}_onScroll(){const{_scrollDelta:e,_options:{document:r}}=this,{scrollTop:n,scrollLeft:s}=r.scrollingElement??r.body;this._areaLocation.x1+=e.x-s,this._areaLocation.y1+=e.y-n,e.x=s,e.y=n,this._setupSelectionArea(),this._frame.next(null)}_onStartAreaScroll(){this._targetBoundaryScrolled=!0,Zt(this._targetElement,"scroll",this._onStartAreaScroll)}_wheelScroll(e){const{manualSpeed:r}=this._options.behaviour.scrolling,n=e.deltaY?e.deltaY>0?1:-1:0,s=e.deltaX?e.deltaX>0?1:-1:0;this._scrollSpeed.y+=n*r,this._scrollSpeed.x+=s*r,this._onTapMove(e),e.preventDefault()}_keyboardScroll(e){const{manualSpeed:r}=this._options.behaviour.scrolling,n=e.key==="ArrowLeft"?-1:e.key==="ArrowRight"?1:0,s=e.key==="ArrowUp"?-1:e.key==="ArrowDown"?1:0;this._scrollSpeed.x+=Math.sign(n)*r,this._scrollSpeed.y+=Math.sign(s)*r,e.preventDefault(),this._onTapMove({clientX:this._lastMousePosition.x,clientY:this._lastMousePosition.y,preventDefault:()=>{}})}_recalculateSelectionAreaRect(){const{_scrollSpeed:e,_areaLocation:r,_targetElement:n,_options:s}=this,{scrollTop:i,scrollHeight:a,clientHeight:o,scrollLeft:l,scrollWidth:c,clientWidth:d}=n,f=this._targetRect,{x1:p,y1:b}=r;let{x2:v,y2:x}=r;const{behaviour:{scrolling:{startScrollMargins:y}}}=s;v<f.left+y.x?(e.x=l?-an(f.left-v+y.x):0,v=v<f.left?f.left:v):v>f.right-y.x?(e.x=c-l-d?an(f.left+f.width-v-y.x):0,v=v>f.right?f.right:v):e.x=0,x<f.top+y.y?(e.y=i?-an(f.top-x+y.y):0,x=x<f.top?f.top:x):x>f.bottom-y.y?(e.y=a-i-o?an(f.top+f.height-x-y.y):0,x=x>f.bottom?f.bottom:x):e.y=0;const M=xl(p,v),k=xl(b,x),T=wl(p,v),N=wl(b,x);this._areaRect=bl(M,k,T-M,N-k)}_redrawSelectionArea(){const{x:e,y:r,width:n,height:s}=this._areaRect,{style:i}=this._area;i.left=`${e}px`,i.top=`${r}px`,i.width=`${n}px`,i.height=`${s}px`}_onTapStop(e,r){var n;const{document:s,features:i}=this._options,{_singleClick:a}=this;Zt(this._targetElement,"scroll",this._onStartAreaScroll),Zt(s,["mousemove","touchmove"],this._delayedTapMove),Zt(s,["touchmove","mousemove"],this._onTapMove),Zt(s,["mouseup","touchcancel","touchend"],this._onTapStop),Zt(s,"scroll",this._onScroll),this._keepSelection(),e&&a&&i.singleTap.allow?this._onSingleTap(e):!a&&!r&&(this._updateElementSelection(),this._emitEvent("stop",e)),this._scrollSpeed.x=0,this._scrollSpeed.y=0,Zt(this._targetElement,"wheel",this._wheelScroll,{passive:!0}),Zt(this._options.document,"keydown",this._keyboardScroll,{passive:!0}),this._clippingElement.remove(),(n=this._frame)==null||n.cancel(),$r(this._area,"display","none")}_updateElementSelection(){const{_selectables:e,_options:r,_selection:n,_areaRect:s}=this,{stored:i,selected:a,touched:o}=n,{intersect:l,overlap:c}=r.behaviour,d=c==="invert",f=[],p=[],b=[];for(let x=0;x<e.length;x++){const y=e[x];if(yl(s,y.getBoundingClientRect(),l)){if(a.includes(y))i.includes(y)&&!o.includes(y)&&o.push(y);else if(d&&i.includes(y)){b.push(y);continue}else p.push(y);f.push(y)}}d&&p.push(...i.filter(x=>!a.includes(x)));const v=c==="keep";for(let x=0;x<a.length;x++){const y=a[x];!f.includes(y)&&!(v&&i.includes(y))&&b.push(y)}n.selected=f,n.changed={added:p,removed:b},this._latestElement=void 0}_emitEvent(e,r){return this.emit(e,{event:r,store:this._selection,selection:this})}_keepSelection(){const{_options:e,_selection:r}=this,{selected:n,changed:s,touched:i,stored:a}=r,o=n.filter(l=>!a.includes(l));switch(e.behaviour.overlap){case"drop":{r.stored=[...o,...a.filter(l=>!i.includes(l))];break}case"invert":{r.stored=[...o,...a.filter(l=>!s.removed.includes(l))];break}case"keep":{r.stored=[...a,...n.filter(l=>!a.includes(l))];break}}}trigger(e,r=!0){this._onTapStart(e,r)}resolveSelectables(){this._selectables=xn(this._options.selectables,this._options.document)}clearSelection(e=!0,r=!1){const{selected:n,stored:s,changed:i}=this._selection;i.added=[],i.removed.push(...n,...e?s:[]),r||(this._emitEvent("move",null),this._emitEvent("stop",null)),this._selection=Sl(e?[]:s)}getSelection(){return this._selection.stored}getSelectionArea(){return this._area}getSelectables(){return this._selectables}setAreaLocation(e){Object.assign(this._areaLocation,e),this._redrawSelectionArea()}getAreaLocation(){return this._areaLocation}cancel(e=!1){this._onTapStop(null,!e)}destroy(){this.cancel(),this.disable(),this._clippingElement.remove(),super.unbindAllListeners()}select(e,r=!1){const{changed:n,selected:s,stored:i}=this._selection,a=xn(e,this._options.document).filter(o=>!s.includes(o)&&!i.includes(o));return i.push(...a),s.push(...a),n.added.push(...a),n.removed=[],this._latestElement=void 0,r||(this._emitEvent("move",null),this._emitEvent("stop",null)),a}deselect(e,r=!1){const{selected:n,stored:s,changed:i}=this._selection,a=xn(e,this._options.document).filter(o=>n.includes(o)||s.includes(o));this._selection.stored=s.filter(o=>!a.includes(o)),this._selection.selected=n.filter(o=>!a.includes(o)),this._selection.changed.added=[],this._selection.changed.removed.push(...a.filter(o=>!i.removed.includes(o))),this._latestElement=void 0,r||(this._emitEvent("move",null),this._emitEvent("stop",null))}};Uu.version="3.9.0";let Kp=Uu;function Yp(t){const e=t.mouseSelectionButton===2?[2]:[0],r=new Kp({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 s;const i=n.target;if(i.id==="input-box"||i.className==="circle"||(s=t.container.querySelector(".context-menu"))!=null&&s.contains(i))return!1;if(!n.ctrlKey&&!n.metaKey){if(i.tagName==="ME-TPC"&&i.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:s}}})=>{if(n.length>0||s.length>0,n.length>0){for(const i of n)i.className="selected";t.currentNodes=[...t.currentNodes,...n],t.bus.fire("selectNodes",n.map(i=>i.nodeObj))}if(s.length>0){for(const i of s)i.classList.remove("selected");t.currentNodes=t.currentNodes.filter(i=>!(s!=null&&s.includes(i))),t.bus.fire("unselectNodes",s.map(i=>i.nodeObj))}});t.selection=r}const Xp=function(t,e=!0){this.theme=t;const r={...(t.type==="dark"?qa:Ha).cssVar,...t.cssVar},n=Object.keys(r);for(let s=0;s<n.length;s++){const i=n[s];this.container.style.setProperty(i,r[i])}e&&this.refresh()},$n=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 Jp(t){const{siblings:e,index:r}=$n(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 Zp(t){const{siblings:e,index:r}=$n(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 Vu(t){const{siblings:e,index:r}=$n(t);return e===void 0?0:(e.splice(r,1),e.length)}function Qp(t,e,r){const{siblings:n,index:s}=$n(r);n!==void 0&&(e==="before"?n.splice(s,0,t):n.splice(s+1,0,t))}function e4(t,e){const{siblings:r,index:n}=$n(t);r!==void 0&&(r[n]=e,e.children=[t])}function Wu(t,e,r){var n;if(Vu(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:s,index:i}=$n(r);if(s===void 0)return;t==="before"?s.splice(i,0,e):s.splice(i+1,0,e)}}const t4=function({map:t,direction:e},r){var n,s;if(e===0)return 0;if(e===1)return 1;if(e===2){const i=((n=t.querySelector(".lhs"))==null?void 0:n.childElementCount)||0,a=((s=t.querySelector(".rhs"))==null?void 0:s.childElementCount)||0;return i<=a?(r.direction=0,0):(r.direction=1,1)}},Gu=function(t,e,r){var n,s;const i=r.children[0].children[0],a=e.parentElement;if(a.tagName==="ME-PARENT"){if(y0(i),a.children[1])a.nextSibling.appendChild(r);else{const o=t.createChildren([r]);a.appendChild(Ga(!0)),a.insertAdjacentElement("afterend",o)}t.linkDiv(r.offsetParent)}else a.tagName==="ME-ROOT"&&(t4(t,i.nodeObj)===0?(n=t.container.querySelector(".lhs"))==null||n.appendChild(r):(s=t.container.querySelector(".rhs"))==null||s.appendChild(r),t.linkDiv())},r4=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()},Ku={before:"beforebegin",after:"afterend"},y0=function(t){const e=t.parentElement.parentElement.lastElementChild;(e==null?void 0:e.tagName)==="svg"&&(e==null||e.remove())},n4=function(t,e){const r=t.nodeObj,n=Ua(r);n.style&&e.style&&(e.style=Object.assign(n.style,e.style));const s=Object.assign(r,e);Wa.call(this,t,s),this.linkDiv(),this.bus.fire("operation",{name:"reshapeNode",obj:s,origin:n})},Ka=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 s=r||t.generateNewObj();n.children?n.children.push(s):n.children=[s],en(t.nodeData);const{grp:i,top:a}=t.createWrapper(s);return Gu(t,e,i),{newTop:a,newNodeObj:s}},s4=function(t,e,r){var n,s,i,a;const o=e||this.currentNode;if(!o)return;const l=o.nodeObj;if(l.parent){if(!((n=l.parent)!=null&&n.parent)&&((i=(s=l.parent)==null?void 0:s.children)==null?void 0:i.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 b=o.closest("me-main").className===sr.LHS?0:1;c.direction=b}Qp(c,t,l),en(this.nodeData);const d=o.parentElement,{grp:f,top:p}=this.createWrapper(c);d.parentElement.insertAdjacentElement(Ku[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)},i4=function(t,e){const r=t||this.currentNode;if(!r)return;y0(r);const n=r.nodeObj;if(!n.parent)return;const s=e||this.generateNewObj();e4(n,s),en(this.nodeData);const i=r.parentElement.parentElement,{grp:a,top:o}=this.createWrapper(s,!0);o.appendChild(Ga(!0)),i.insertAdjacentElement("afterend",a);const l=this.createChildren([i]);o.insertAdjacentElement("afterend",l),this.linkDiv(),e||this.editTopic(o.firstChild),this.selectNode(o.firstChild,!0),this.bus.fire("operation",{name:"insertParent",obj:s})},a4=function(t,e){const r=t||this.currentNode;if(!r)return;const n=Ka(this,r,e);if(!n)return;const{newTop:s,newNodeObj:i}=n;this.bus.fire("operation",{name:"addChild",obj:i}),e||this.editTopic(s.firstChild),this.selectNode(s.firstChild,!0)},o4=function(t,e){const r=Ua(t.nodeObj);ja(r);const n=Ka(this,e,r);if(!n)return;const{newNodeObj:s}=n;this.selectNode(this.findEle(s.id)),this.bus.fire("operation",{name:"copyNode",obj:s})},l4=function(t,e){t=Hs(t);const r=[];for(let n=0;n<t.length;n++){const s=t[n],i=Ua(s.nodeObj);ja(i);const a=Ka(this,e,i);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})},c4=function(t){const e=t||this.currentNode;if(!e)return;const r=e.nodeObj;Jp(r);const n=e.parentNode.parentNode;n.parentNode.insertBefore(n,n.previousSibling),this.linkDiv(),this.bus.fire("operation",{name:"moveUpNode",obj:r})},u4=function(t){const e=t||this.currentNode;if(!e)return;const r=e.nodeObj;Zp(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})},d4=function(t){if(t.length===0)return;t=Hs(t);for(const r of t){const n=r.nodeObj,s=Vu(n);r4(r,s)}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)})},h4=function(t,e){t=Hs(t);const r=e.nodeObj;r.expanded===!1&&(this.expandNode(e,!0),e=this.findEle(r.id));for(const n of t){const s=n.nodeObj;Wu("in",s,r),en(this.nodeData);const i=n.parentElement;Gu(this,e,i.parentElement)}this.linkDiv(),this.bus.fire("operation",{name:"moveNodeIn",objs:t.map(n=>n.nodeObj),toObj:r})},Yu=(t,e,r,n)=>{t=Hs(t),e==="after"&&(t=t.reverse());const s=r.nodeObj,i=[];for(const a of t){const o=a.nodeObj;Wu(e,o,s),en(n.nodeData),y0(a);const l=a.parentElement.parentNode;i.includes(l.parentElement)||i.push(l.parentElement),r.parentElement.parentNode.insertAdjacentElement(Ku[e],l)}for(const a of i)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:s})},f4=function(t,e){Yu(t,"before",e,this)},p4=function(t,e){Yu(t,"after",e,this)},m4=function(t){const e=t||this.currentNode;e&&(e.nodeObj.dangerouslySetInnerHTML||this.editTopic(e))},g4=function(t,e){t.text.textContent=e,t.nodeObj.topic=e,this.linkDiv()},Xu=Object.freeze(Object.defineProperty({__proto__:null,addChild:a4,beginEdit:m4,copyNode:o4,copyNodes:l4,insertParent:i4,insertSibling:s4,moveDownNode:u4,moveNodeAfter:p4,moveNodeBefore:f4,moveNodeIn:h4,moveUpNode:c4,removeNodes:d4,reshapeNode:n4,rmSubline:y0,setNodeTopic:g4},Symbol.toStringTag,{value:"Module"}));function v4(t){return{nodeData:t.isFocusMode?t.nodeDataBackup:t.nodeData,arrows:t.arrows,summaries:t.summaries,direction:t.direction,theme:t.theme}}const b4=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 s=r.left+r.width/2,i=r.top+r.height/2,a=n.left+n.width/2,o=n.top+n.height/2,l=s-a,c=i-o;this.move(-l,-c,!0)}},y4=function(t,e,r){this.clearSelection(),this.scrollIntoView(t),this.selection.select(t),e&&this.bus.fire("selectNewNode",t.nodeObj)},w4=function(t){this.selection.select(t)},x4=function(t){this.selection.deselect(t)},k4=function(){this.unselectNodes(this.currentNodes),this.unselectSummary(),this.unselectArrow()},S4=function(){const t=v4(this);return JSON.stringify(t,(e,r)=>{if(!(e==="parent"&&typeof r!="string"))return r})},T4=function(){return JSON.parse(this.getDataString())},A4=function(){this.editable=!0},E4=function(){this.editable=!1},C4=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,s=e.y?e.y-r.top-r.height/2:0,{dx:i,dy:a}=Ju(this),o=this.map.style.transform,{x:l,y:c}=Fu(o),d=l-i,f=c-a,p=this.scaleVal,b=(-n+d)*(1-t/p),v=(-s+f)*(1-t/p);this.map.style.transform=`translate(${l-b}px, ${c-v}px) scale(${t})`,this.scaleVal=t,this.bus.fire("scale",t)},M4=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)},N4=function(t,e,r=!1){const{map:n,scaleVal:s,bus:i}=this,a=n.style.transform;let{x:o,y:l}=Fu(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(${s})`,i.fire("move",{dx:t,dy:e})},Ju=t=>{const{container:e,map:r,nodes:n}=t,s=r.querySelector("me-root"),i=s.offsetTop,a=s.offsetLeft,o=s.offsetWidth,l=s.offsetHeight;let c,d;return t.alignment==="root"?(c=e.offsetWidth/2-a-o/2,d=e.offsetHeight/2-i-l/2,r.style.transformOrigin=`${a+o/2}px 50%`):(c=(e.offsetWidth-n.offsetWidth)/2,d=(e.offsetHeight-n.offsetHeight)/2,r.style.transformOrigin="50% 50%"),{dx:c,dy:d}},D4=function(){const{map:t}=this,{dx:e,dy:r}=Ju(this);t.style.transform=`translate(${e}px, ${r}px) scale(${this.scaleVal})`},R4=function(t){t(this)},I4=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())},_4=function(){this.isFocusMode=!1,this.tempDirection!==null&&(this.nodeData=this.nodeDataBackup,this.direction=this.tempDirection,this.tempDirection=null,this.refresh(),this.toCenter())},O4=function(){this.direction=0,this.refresh(),this.toCenter()},L4=function(){this.direction=1,this.refresh(),this.toCenter()},z4=function(){this.direction=2,this.refresh(),this.toCenter()},F4=function(t){this.locale=t,this.refresh()},$4=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(),s={x:n.left,y:n.top},i=t.parentNode,a=i.children[1];if(a.expanded=r.expanded,a.className=r.expanded?"minus":"",y0(t),r.expanded){const f=this.createChildren(r.children.map(p=>this.createWrapper(p).grp));i.parentNode.appendChild(f)}else i.parentNode.children[1].remove();this.linkDiv(t.closest("me-main > me-wrapper"));const o=t.getBoundingClientRect(),l={x:o.left,y:o.top},c=s.x-l.x,d=s.y-l.y;this.move(c,d),this.bus.fire("expandNode",r)},B4=function(t,e){const r=t.nodeObj,n=t.getBoundingClientRect(),s={x:n.left,y:n.top};In(r,e??!r.expanded),this.refresh();const i=this.findEle(r.id).getBoundingClientRect(),a={x:i.left,y:i.top},o=s.x-a.x,l=s.y-a.y;this.move(o,l)},P4=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)),en(this.nodeData),this.layout(),this.linkDiv()},H4=Object.freeze(Object.defineProperty({__proto__:null,cancelFocus:_4,clearSelection:k4,disableEdit:E4,enableEdit:A4,expandNode:$4,expandNodeAll:B4,focusNode:I4,getData:T4,getDataString:S4,initLeft:O4,initRight:L4,initSide:z4,install:R4,move:N4,refresh:P4,scale:C4,scaleFit:M4,scrollIntoView:b4,selectNode:y4,selectNodes:w4,setLocale:F4,toCenter:D4,unselectNodes:x4},Symbol.toStringTag,{value:"Module"})),q4=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=Va([{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}}},Tl={create:q4},j4="#4dc4ff";function Zu(t,e,r,n,s,i,a,o){return{x:t/8+r*3/8+s*3/8+a/8,y:e/8+n*3/8+i*3/8+o/8}}function U4(t,e,r){ft(t,{x:e+"",y:r+""})}function O0(t,e,r,n,s){ft(t,{x1:e+"",y1:r+"",x2:n+"",y2:s+""})}function Al(t,e,r,n,s,i,a,o,l,c){var d;const f=`M ${e} ${r} C ${n} ${s} ${i} ${a} ${o} ${l}`;if(t.line.setAttribute("d",f),c.style){const y=c.style;y.stroke&&t.line.setAttribute("stroke",y.stroke),y.strokeWidth&&t.line.setAttribute("stroke-width",String(y.strokeWidth)),y.strokeDasharray&&t.line.setAttribute("stroke-dasharray",y.strokeDasharray),y.strokeLinecap&&t.line.setAttribute("stroke-linecap",y.strokeLinecap),y.opacity!==void 0&&t.line.setAttribute("opacity",String(y.opacity))}const p=t.querySelectorAll('path[stroke="transparent"]');p.length>0&&p[0].setAttribute("d",f);const b=gs(i,a,o,l);if(b){const y=`M ${b.x1} ${b.y1} L ${o} ${l} L ${b.x2} ${b.y2}`;if(t.arrow1.setAttribute("d",y),p.length>1&&p[1].setAttribute("d",y),c.style){const M=c.style;M.stroke&&t.arrow1.setAttribute("stroke",M.stroke),M.strokeWidth&&t.arrow1.setAttribute("stroke-width",String(M.strokeWidth)),M.strokeLinecap&&t.arrow1.setAttribute("stroke-linecap",M.strokeLinecap),M.opacity!==void 0&&t.arrow1.setAttribute("opacity",String(M.opacity))}}if(c.bidirectional){const y=gs(n,s,e,r);if(y){const M=`M ${y.x1} ${y.y1} L ${e} ${r} L ${y.x2} ${y.y2}`;if(t.arrow2.setAttribute("d",M),p.length>2&&p[2].setAttribute("d",M),c.style){const k=c.style;k.stroke&&t.arrow2.setAttribute("stroke",k.stroke),k.strokeWidth&&t.arrow2.setAttribute("stroke-width",String(k.strokeWidth)),k.strokeLinecap&&t.arrow2.setAttribute("stroke-linecap",k.strokeLinecap),k.opacity!==void 0&&t.arrow2.setAttribute("opacity",String(k.opacity))}}}const{x:v,y:x}=Zu(e,r,n,s,i,a,o,l);U4(t.label,v,x),(d=c.style)!=null&&d.labelColor&&t.label.setAttribute("fill",c.style.labelColor),Z4(t)}function ys(t,e,r){const{offsetLeft:n,offsetTop:s}=tn(t.nodes,e),i=e.offsetWidth,a=e.offsetHeight,o=n+i/2,l=s+a/2,c=o+r.x,d=l+r.y;return{w:i,h:a,cx:o,cy:l,ctrlX:c,ctrlY:d}}function En(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 Ya=function(t,e,r,n,s){var i;if(!e||!r)return;const a=ys(t,e,n.delta1),o=ys(t,r,n.delta2),{x:l,y:c}=En(a),{ctrlX:d,ctrlY:f}=a,{ctrlX:p,ctrlY:b}=o,{x:v,y:x}=En(o),y=gs(p,b,v,x);if(!y)return;const M=`M ${y.x1} ${y.y1} L ${v} ${x} L ${y.x2} ${y.y2}`;let k="";if(n.bidirectional){const W=gs(d,f,l,c);if(!W)return;k=`M ${W.x1} ${W.y1} L ${l} ${c} L ${W.x2} ${W.y2}`}const T=Sp(`M ${l} ${c} C ${d} ${f} ${p} ${b} ${v} ${x}`,M,k,n.style),{x:N,y:I}=Zu(l,c,d,f,p,b,v,x),O=(i=n.style)==null?void 0:i.labelColor,z=Ji(n.label,N,I,{anchor:"middle",color:O,dataType:"custom-link"});T.appendChild(z),T.label=z,T.arrowObj=n,T.dataset.linkid=n.id,t.linkSvgGroup.appendChild(T),s||(t.arrows.push(n),t.currentArrow=T,Qu(t,n,a,o))},V4=function(t,e,r={}){const n={id:gn(),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};Ya(this,t,e,n),this.bus.fire("operation",{name:"createArrow",obj:n})},W4=function(t){qs(this);const e={...t,id:gn()};Ya(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;qs(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}})},K4=function(t){this.currentArrow=t;const e=t.arrowObj,r=this.findEle(e.from),n=this.findEle(e.to),s=ys(this,r,e.delta1),i=ys(this,n,e.delta2);Qu(this,e,s,i)},Y4=function(){qs(this),this.currentArrow=null},bi=function(t,e){const r=document.createElementNS(Gt,"path");return ft(r,{d:t,stroke:e,fill:"none","stroke-width":"6","stroke-linecap":"round","stroke-linejoin":"round"}),r},X4=function(t,e){const r=document.createElementNS(Gt,"g");r.setAttribute("class","arrow-highlight"),r.setAttribute("opacity","0.45");const n=bi(t.line.getAttribute("d"),e);r.appendChild(n);const s=bi(t.arrow1.getAttribute("d"),e);if(r.appendChild(s),t.arrow2.getAttribute("d")){const i=bi(t.arrow2.getAttribute("d"),e);r.appendChild(i)}t.insertBefore(r,t.firstChild)},J4=function(t){const e=t.querySelector(".arrow-highlight");e&&e.remove()},Z4=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"))},qs=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&&J4(t.currentArrow)},Qu=function(t,e,r,n){const{linkController:s,P2:i,P3:a,line1:o,line2:l,nodes:c,map:d,currentArrow:f,bus:p}=t;if(!f)return;s.style.display="initial",i.style.display="initial",a.style.display="initial",c.appendChild(s),c.appendChild(i),c.appendChild(a),X4(f,j4);let{x:b,y:v}=En(r),{ctrlX:x,ctrlY:y}=r,{ctrlX:M,ctrlY:k}=n,{x:T,y:N}=En(n);i.style.cssText=`top:${y}px;left:${x}px;`,a.style.cssText=`top:${k}px;left:${M}px;`,O0(o,b,v,x,y),O0(l,M,k,T,N),t.helper1=Tl.create(i),t.helper2=Tl.create(a),t.helper1.init(d,(I,O)=>{x=x+I/t.scaleVal,y=y+O/t.scaleVal;const z=En({...r,ctrlX:x,ctrlY:y});b=z.x,v=z.y,i.style.top=y+"px",i.style.left=x+"px",Al(f,b,v,x,y,M,k,T,N,e),O0(o,b,v,x,y),e.delta1.x=x-r.cx,e.delta1.y=y-r.cy,p.fire("updateArrowDelta",e)}),t.helper2.init(d,(I,O)=>{M=M+I/t.scaleVal,k=k+O/t.scaleVal;const z=En({...n,ctrlX:M,ctrlY:k});T=z.x,N=z.y,a.style.top=k+"px",a.style.left=M+"px",Al(f,b,v,x,y,M,k,T,N,e),O0(l,M,k,T,N),e.delta2.x=M-n.cx,e.delta2.y=k-n.cy,p.fire("updateArrowDelta",e)})};function Q4(){this.linkSvgGroup.innerHTML="";for(let t=0;t<this.arrows.length;t++){const e=this.arrows[t];try{Ya(this,this.findEle(e.from),this.findEle(e.to),e,!0)}catch{}}this.nodes.appendChild(this.linkSvgGroup)}function em(t){if(qs(this),!t)return;const e=t.label;Hu(this,e,t.arrowObj)}function tm(){this.arrows=this.arrows.filter(t=>ms(t.from,this.nodeData)&&ms(t.to,this.nodeData))}const rm=Object.freeze(Object.defineProperty({__proto__:null,createArrow:V4,createArrowFrom:W4,editArrowLabel:em,removeArrow:G4,renderArrow:Q4,selectArrow:K4,tidyArrow:tm,unselectArrow:Y4},Symbol.toStringTag,{value:"Module"})),nm=function(t){var e,r;if(t.length===0)throw new Error("No selected node.");if(t.length===1){const d=t[0].nodeObj,f=t[0].nodeObj.parent;if(!f)throw new Error("Can not select root node.");const p=f.children.findIndex(b=>d===b);return{parent:f.id,start:p,end:p}}let n=0;const s=t.map(d=>{let f=d.nodeObj;const p=[];for(;f.parent;){const b=f.parent,v=b.children,x=v==null?void 0:v.indexOf(f);f=b,p.unshift({node:f,index:x})}return p.length>n&&(n=p.length),p});let i=0;e:for(;i<n;i++){const d=(e=s[0][i])==null?void 0:e.node;for(let f=1;f<s.length;f++)if(((r=s[f][i])==null?void 0:r.node)!==d)break e}if(!i)throw new Error("Can not select root node.");const a=s.map(d=>d[i-1].index).sort(),o=a[0]||0,l=a[a.length-1]||0,c=s[0][i-1].node;if(!c.parent)throw new Error("Please select nodes in the same main topic.");return{parent:c.id,start:o,end:l}},sm=function(t){const e=document.createElementNS(Gt,"g");return e.setAttribute("id",t),e},El=function(t,e){const r=document.createElementNS(Gt,"path");return ft(r,{d:t,stroke:e||"#666",fill:"none","stroke-linecap":"round","stroke-width":"2"}),r},im=t=>t.parentElement.parentElement,am=function(t,{parent:e,start:r}){const n=t.findEle(e),s=n.nodeObj;let i;return s.parent?i=n.closest("me-main").className:i=t.findEle(s.children[r].id).closest("me-main").className,i},Xa=function(t,e){var r;const{id:n,label:s,parent:i,start:a,end:o}=e,{nodes:l,theme:c,summarySvg:d}=t,f=t.findEle(i).nodeObj,p=am(t,e);let b=1/0,v=0,x=0,y=0;for(let W=a;W<=o;W++){const U=(r=f.children)==null?void 0:r[W];if(!U)return t.removeSummary(n),null;const he=im(t.findEle(U.id)),{offsetLeft:ge,offsetTop:Ae}=tn(l,he),et=a===o?10:20;W===a&&(x=Ae+et),W===o&&(y=Ae+he.offsetHeight-et),ge<b&&(b=ge),he.offsetWidth+ge>v&&(v=he.offsetWidth+ge)}let M,k;const T=x+10,N=y+10,I=(T+N)/2,O=c.cssVar["--color"];p===sr.LHS?(M=El(`M ${b+10} ${T} c -5 0 -10 5 -10 10 L ${b} ${N-10} c 0 5 5 10 10 10 M ${b} ${I} h -10`,O),k=Ji(s,b-20,I+6,{anchor:"end",color:O})):(M=El(`M ${v-10} ${T} c 5 0 10 5 10 10 L ${v} ${N-10} c 0 5 -5 10 -10 10 M ${v} ${I} h 10`,O),k=Ji(s,v+20,I+6,{anchor:"start",color:O}));const z=sm("s-"+n);return z.appendChild(M),z.appendChild(k),z.summaryObj=e,d.appendChild(z),z},om=function(){if(!this.currentNodes)return;const{currentNodes:t,summaries:e,bus:r}=this,{parent:n,start:s,end:i}=nm(t),a={id:gn(),parent:n,start:s,end:i,label:"summary"},o=Xa(this,a);e.push(a),this.editSummary(o),r.fire("operation",{name:"createSummary",obj:a})},lm=function(t){const e=gn(),r={...t,id:e};Xa(this,r),this.summaries.push(r),this.bus.fire("operation",{name:"createSummary",obj:r})},cm=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}})},um=function(t){const e=t.children[1].getBBox(),r=6,n=3,s=document.createElementNS(Gt,"rect");ft(s,{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(s),this.currentSummary=t},dm=function(){var t,e;(e=(t=this.currentSummary)==null?void 0:t.querySelector("rect"))==null||e.remove(),this.currentSummary=null},hm=function(){this.summarySvg.innerHTML="",this.summaries.forEach(t=>{try{Xa(this,t)}catch{}}),this.nodes.insertAdjacentElement("beforeend",this.summarySvg)},fm=function(t){if(!t)return;const e=t.childNodes[1];Hu(this,e,t.summaryObj)},pm=Object.freeze(Object.defineProperty({__proto__:null,createSummary:om,createSummaryFrom:lm,editSummary:fm,removeSummary:cm,renderSummary:hm,selectSummary:um,unselectSummary:dm},Symbol.toStringTag,{value:"Module"})),qt="http://www.w3.org/2000/svg";function mm(t,e){const r=document.createElementNS(qt,"svg");return ft(r,{version:"1.1",xmlns:qt,height:t,width:e}),r}function gm(t,e){return(parseInt(t)-parseInt(e))/2}function vm(t,e,r,n){const s=document.createElementNS(qt,"g");let i="";return t.text?i=t.text.textContent:i=t.childNodes[0].textContent,i.split(`
|
||
`).forEach((a,o)=>{const l=document.createElementNS(qt,"text");ft(l,{x:r+parseInt(e.paddingLeft)+"",y:n+parseInt(e.paddingTop)+gm(e.lineHeight,e.fontSize)*(o+1)+parseFloat(e.fontSize)*(o+1)+"","text-anchor":"start","font-family":e.fontFamily,"font-size":`${e.fontSize}`,"font-weight":`${e.fontWeight}`,fill:`${e.color}`}),l.innerHTML=a,s.appendChild(l)}),s}function bm(t,e,r,n){var s;let i="";(s=t.nodeObj)!=null&&s.dangerouslySetInnerHTML?i=t.nodeObj.dangerouslySetInnerHTML:t.text?i=t.text.textContent:i=t.childNodes[0].textContent;const a=document.createElementNS(qt,"foreignObject");ft(a,{x:r+parseInt(e.paddingLeft)+"",y:n+parseInt(e.paddingTop)+"",width:e.width,height:e.height});const o=document.createElement("div");return ft(o,{xmlns:"http://www.w3.org/1999/xhtml",style:`font-family: ${e.fontFamily}; font-size: ${e.fontSize}; font-weight: ${e.fontWeight}; color: ${e.color}; white-space: pre-wrap;`}),o.innerHTML=i,a.appendChild(o),a}function ym(t,e){const r=getComputedStyle(e),{offsetLeft:n,offsetTop:s}=tn(t.nodes,e),i=document.createElementNS(qt,"rect");return ft(i,{x:n+"",y:s+"",rx:r.borderRadius,ry:r.borderRadius,width:r.width,height:r.height,fill:r.backgroundColor,stroke:r.borderColor,"stroke-width":r.borderWidth}),i}function L0(t,e,r=!1){const n=getComputedStyle(e),{offsetLeft:s,offsetTop:i}=tn(t.nodes,e),a=document.createElementNS(qt,"rect");ft(a,{x:s+"",y:i+"",rx:n.borderRadius,ry:n.borderRadius,width:n.width,height:n.height,fill:n.backgroundColor,stroke:n.borderColor,"stroke-width":n.borderWidth});const o=document.createElementNS(qt,"g");o.appendChild(a);let l;return r?l=bm(e,n,s,i):l=vm(e,n,s,i),o.appendChild(l),o}function wm(t,e){const r=getComputedStyle(e),{offsetLeft:n,offsetTop:s}=tn(t.nodes,e),i=document.createElementNS(qt,"a"),a=document.createElementNS(qt,"text");return ft(a,{x:n+"",y:s+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,i.appendChild(a),i.setAttribute("href",e.href),i}function xm(t,e){const r=getComputedStyle(e),{offsetLeft:n,offsetTop:s}=tn(t.nodes,e),i=document.createElementNS(qt,"image");return ft(i,{x:n+"",y:s+"",width:r.width+"",height:r.height+"",href:e.src}),i}const z0=100,km='<?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">',Sm=(t,e=!1)=>{var r,n,s;const i=t.nodes,a=i.offsetHeight+z0*2,o=i.offsetWidth+z0*2,l=mm(a+"px",o+"px"),c=document.createElementNS(qt,"svg"),d=document.createElementNS(qt,"rect");ft(d,{x:"0",y:"0",width:`${o}`,height:`${a}`,fill:t.theme.cssVar["--bgcolor"]}),l.appendChild(d),i.querySelectorAll(".subLines").forEach(v=>{const x=v.cloneNode(!0),{offsetLeft:y,offsetTop:M}=tn(i,v.parentElement);x.setAttribute("x",`${y}`),x.setAttribute("y",`${M}`),c.appendChild(x)});const f=(r=i.querySelector(".lines"))==null?void 0:r.cloneNode(!0);f&&c.appendChild(f);const p=(n=i.querySelector(".topiclinks"))==null?void 0:n.cloneNode(!0);p&&c.appendChild(p);const b=(s=i.querySelector(".summary"))==null?void 0:s.cloneNode(!0);return b&&c.appendChild(b),i.querySelectorAll("me-tpc").forEach(v=>{v.nodeObj.dangerouslySetInnerHTML?c.appendChild(L0(t,v,!e)):(c.appendChild(ym(t,v)),c.appendChild(L0(t,v.text,!e)))}),i.querySelectorAll(".tags > span").forEach(v=>{c.appendChild(L0(t,v))}),i.querySelectorAll(".icons > span").forEach(v=>{c.appendChild(L0(t,v))}),i.querySelectorAll(".hyper-link").forEach(v=>{c.appendChild(wm(t,v))}),i.querySelectorAll("img").forEach(v=>{c.appendChild(xm(t,v))}),ft(c,{x:z0+"",y:z0+"",overflow:"visible"}),l.appendChild(c),l},Tm=(t,e)=>(e&&t.insertAdjacentHTML("afterbegin","<style>"+e+"</style>"),km+t.outerHTML);function Am(t){return new Promise((e,r)=>{const n=new FileReader;n.onload=s=>{e(s.target.result)},n.onerror=s=>{r(s)},n.readAsDataURL(t)})}const Em=function(t=!1,e){const r=Sm(this,t),n=Tm(r,e);return new Blob([n],{type:"image/svg+xml"})},Cm=async function(t=!1,e){const r=this.exportSvg(t,e),n=await Am(r);return new Promise((s,i)=>{const a=new Image;a.setAttribute("crossOrigin","anonymous"),a.onload=()=>{const o=document.createElement("canvas");o.width=a.width,o.height=a.height,o.getContext("2d").drawImage(a,0,0),o.toBlob(s,"image/png",1)},a.src=n,a.onerror=i})},Mm=Object.freeze(Object.defineProperty({__proto__:null,exportPng:Cm,exportSvg:Em},Symbol.toStringTag,{value:"Module"}));function Nm(t,e){return async function(...r){const n=this.before[e];n&&!await n.apply(this,r)||t.apply(this,r)}}const Cl=Object.keys(Xu),e1={};for(let t=0;t<Cl.length;t++){const e=Cl[t];e1[e]=Nm(Xu[e],e)}const Dm={getObjById:ms,generateNewObj:ap,layout:mp,linkDiv:Tp,editTopic:kp,createWrapper:bp,createParent:yp,createChildren:wp,createTopic:xp,findEle:$u,changeTheme:Xp,...H4,...e1,...rm,...pm,...Mm,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,en(this.nodeData),this.arrows=t.arrows||[],this.summaries=t.summaries||[],this.tidyArrow(),this.toolBar&&qp(this),this.keypress&&hp(this,this.keypress),this.editable&&Yp(this),this.contextMenu&&this.disposable.push(Ap(this,this.contextMenu)),this.draggable&&this.disposable.push(Np(this)),this.allowUndo&&this.disposable.push(Rp(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 Rm({pT:t,pL:e,pW:r,pH:n,cT:s,cL:i,cW:a,cH:o,direction:l,containerHeight:c}){let d=e+r/2;const f=t+n/2;let p;l===sr.LHS?p=i+a:p=i;const b=s+o/2,v=(1-Math.abs(b-f)/c)*.25*(r/2);return l===sr.LHS?d=d-r/10-v:d=d+r/10+v,`M ${d} ${f} Q ${d} ${b} ${p} ${b}`}function Im({pT:t,pL:e,pW:r,pH:n,cT:s,cL:i,cW:a,cH:o,direction:l,isFirst:c}){const d=parseInt(this.container.style.getPropertyValue("--node-gap-x"));let f=0,p=0;c?f=t+n/2:f=t+n;const b=s+o;let v=0,x=0,y=0;const M=Math.abs(f-b)/300*d;return l===sr.LHS?(y=e,v=y+d,x=y-d,p=i+d,`M ${v} ${f} C ${y} ${f} ${y+M} ${b} ${x} ${b} H ${p}`):(y=e+r,v=y-d,x=y+d,p=i+a-d,`M ${v} ${f} C ${y} ${f} ${y-M} ${b} ${x} ${b} H ${p}`)}const _m="5.1.1";function Om(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 Wn=document;function vt({el:t,direction:e,locale:r,draggable:n,editable:s,contextMenu:i,toolBar:a,keypress:o,mouseSelectionButton:l,selectionContainer:c,before:d,newTopicName:f,allowUndo:p,generateMainBranch:b,generateSubBranch:v,overflowHidden:x,theme:y,alignment:M,scaleSensitivity:k,scaleMax:T,scaleMin:N,handleWheel:I,markdown:O,imageProxy:z}){let W=null;const U=Object.prototype.toString.call(t);if(U==="[object HTMLDivElement]"?W=t:U==="[object String]"&&(W=document.querySelector(t)),!W)throw new Error("MindElixir: el is not a valid element");W.style.position="relative",W.innerHTML="",this.el=W,this.disposable=[],this.before=d||{},this.locale=r||"en",this.newTopicName=f||"New Node",this.contextMenu=i??!0,this.toolBar=a??!0,this.keypress=o??!0,this.mouseSelectionButton=l??0,this.direction=e??1,this.draggable=n??!0,this.editable=s??!0,this.allowUndo=p??!0,this.scaleSensitivity=k??.1,this.scaleMax=T??1.4,this.scaleMin=N??.2,this.generateMainBranch=b||Rm,this.generateSubBranch=v||Im,this.overflowHidden=x??!1,this.alignment=M??"root",this.handleWheel=I??!0,this.markdown=O||void 0,this.imageProxy=z||void 0,this.currentNodes=[],this.currentArrow=null,this.scaleVal=1,this.tempDirection=null,this.dragMoveHelper=Om(this),this.bus=pp(),this.container=Wn.createElement("div"),this.selectionContainer=c||this.container,this.container.className="map-container";const he=window.matchMedia("(prefers-color-scheme: dark)");this.theme=y||(he.matches?qa:Ha);const ge=Wn.createElement("div");ge.className="map-canvas",this.map=ge,this.container.setAttribute("tabindex","0"),this.container.appendChild(this.map),this.el.appendChild(this.container),this.nodes=Wn.createElement("me-nodes"),this.lines=Jn("lines"),this.summarySvg=Jn("summary"),this.linkController=Jn("linkcontroller"),this.P2=Wn.createElement("div"),this.P3=Wn.createElement("div"),this.P2.className=this.P3.className="circle",this.P2.style.display=this.P3.style.display="none",this.line1=fl(),this.line2=fl(),this.linkController.appendChild(this.line1),this.linkController.appendChild(this.line2),this.linkSvgGroup=Jn("topiclinks"),this.map.appendChild(this.nodes),this.overflowHidden?this.container.style.overflow="hidden":this.disposable.push(fp(this))}vt.prototype=Dm;Object.defineProperty(vt.prototype,"currentNode",{get(){return this.currentNodes[this.currentNodes.length-1]},enumerable:!0});vt.LEFT=0;vt.RIGHT=1;vt.SIDE=2;vt.THEME=Ha;vt.DARK_THEME=qa;vt.version=_m;vt.E=$u;vt.new=t=>({nodeData:{id:gn(),topic:t||"new topic",children:[]}});function t1(t,e){return function(){return t.apply(e,arguments)}}const{toString:Lm}=Object.prototype,{getPrototypeOf:Ja}=Object,{iterator:js,toStringTag:r1}=Symbol,Us=(t=>e=>{const r=Lm.call(e);return t[r]||(t[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),ir=t=>(t=t.toLowerCase(),e=>Us(e)===t),Vs=t=>e=>typeof e===t,{isArray:Bn}=Array,p0=Vs("undefined");function w0(t){return t!==null&&!p0(t)&&t.constructor!==null&&!p0(t.constructor)&&Ot(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const n1=ir("ArrayBuffer");function zm(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&n1(t.buffer),e}const Fm=Vs("string"),Ot=Vs("function"),s1=Vs("number"),x0=t=>t!==null&&typeof t=="object",$m=t=>t===!0||t===!1,es=t=>{if(Us(t)!=="object")return!1;const e=Ja(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(r1 in t)&&!(js in t)},Bm=t=>{if(!x0(t)||w0(t))return!1;try{return Object.keys(t).length===0&&Object.getPrototypeOf(t)===Object.prototype}catch{return!1}},Pm=ir("Date"),Hm=ir("File"),qm=ir("Blob"),jm=ir("FileList"),Um=t=>x0(t)&&Ot(t.pipe),Vm=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||Ot(t.append)&&((e=Us(t))==="formdata"||e==="object"&&Ot(t.toString)&&t.toString()==="[object FormData]"))},Wm=ir("URLSearchParams"),[Gm,Km,Ym,Xm]=["ReadableStream","Request","Response","Headers"].map(ir),Jm=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function k0(t,e,{allOwnKeys:r=!1}={}){if(t===null||typeof t>"u")return;let n,s;if(typeof t!="object"&&(t=[t]),Bn(t))for(n=0,s=t.length;n<s;n++)e.call(null,t[n],n,t);else{if(w0(t))return;const i=r?Object.getOwnPropertyNames(t):Object.keys(t),a=i.length;let o;for(n=0;n<a;n++)o=i[n],e.call(null,t[o],o,t)}}function i1(t,e){if(w0(t))return null;e=e.toLowerCase();const r=Object.keys(t);let n=r.length,s;for(;n-- >0;)if(s=r[n],e===s.toLowerCase())return s;return null}const dn=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),a1=t=>!p0(t)&&t!==dn;function ta(){const{caseless:t}=a1(this)&&this||{},e={},r=(n,s)=>{const i=t&&i1(e,s)||s;es(e[i])&&es(n)?e[i]=ta(e[i],n):es(n)?e[i]=ta({},n):Bn(n)?e[i]=n.slice():e[i]=n};for(let n=0,s=arguments.length;n<s;n++)arguments[n]&&k0(arguments[n],r);return e}const Zm=(t,e,r,{allOwnKeys:n}={})=>(k0(e,(s,i)=>{r&&Ot(s)?t[i]=t1(s,r):t[i]=s},{allOwnKeys:n}),t),Qm=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),e2=(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)},t2=(t,e,r,n)=>{let s,i,a;const o={};if(e=e||{},t==null)return e;do{for(s=Object.getOwnPropertyNames(t),i=s.length;i-- >0;)a=s[i],(!n||n(a,t,e))&&!o[a]&&(e[a]=t[a],o[a]=!0);t=r!==!1&&Ja(t)}while(t&&(!r||r(t,e))&&t!==Object.prototype);return e},r2=(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},n2=t=>{if(!t)return null;if(Bn(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},s2=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&Ja(Uint8Array)),i2=(t,e)=>{const n=(t&&t[js]).call(t);let s;for(;(s=n.next())&&!s.done;){const i=s.value;e.call(t,i[0],i[1])}},a2=(t,e)=>{let r;const n=[];for(;(r=t.exec(e))!==null;)n.push(r);return n},o2=ir("HTMLFormElement"),l2=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,s){return n.toUpperCase()+s}),Ml=(({hasOwnProperty:t})=>(e,r)=>t.call(e,r))(Object.prototype),c2=ir("RegExp"),o1=(t,e)=>{const r=Object.getOwnPropertyDescriptors(t),n={};k0(r,(s,i)=>{let a;(a=e(s,i,t))!==!1&&(n[i]=a||s)}),Object.defineProperties(t,n)},u2=t=>{o1(t,(e,r)=>{if(Ot(t)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=t[r];if(Ot(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=s=>{s.forEach(i=>{r[i]=!0})};return Bn(t)?n(t):n(String(t).split(e)),r},h2=()=>{},f2=(t,e)=>t!=null&&Number.isFinite(t=+t)?t:e;function p2(t){return!!(t&&Ot(t.append)&&t[r1]==="FormData"&&t[js])}const m2=t=>{const e=new Array(10),r=(n,s)=>{if(x0(n)){if(e.indexOf(n)>=0)return;if(w0(n))return n;if(!("toJSON"in n)){e[s]=n;const i=Bn(n)?[]:{};return k0(n,(a,o)=>{const l=r(a,s+1);!p0(l)&&(i[o]=l)}),e[s]=void 0,i}}return n};return r(t,0)},g2=ir("AsyncFunction"),v2=t=>t&&(x0(t)||Ot(t))&&Ot(t.then)&&Ot(t.catch),l1=((t,e)=>t?setImmediate:e?((r,n)=>(dn.addEventListener("message",({source:s,data:i})=>{s===dn&&i===r&&n.length&&n.shift()()},!1),s=>{n.push(s),dn.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",Ot(dn.postMessage)),b2=typeof queueMicrotask<"u"?queueMicrotask.bind(dn):typeof process<"u"&&process.nextTick||l1,y2=t=>t!=null&&Ot(t[js]),B={isArray:Bn,isArrayBuffer:n1,isBuffer:w0,isFormData:Vm,isArrayBufferView:zm,isString:Fm,isNumber:s1,isBoolean:$m,isObject:x0,isPlainObject:es,isEmptyObject:Bm,isReadableStream:Gm,isRequest:Km,isResponse:Ym,isHeaders:Xm,isUndefined:p0,isDate:Pm,isFile:Hm,isBlob:qm,isRegExp:c2,isFunction:Ot,isStream:Um,isURLSearchParams:Wm,isTypedArray:s2,isFileList:jm,forEach:k0,merge:ta,extend:Zm,trim:Jm,stripBOM:Qm,inherits:e2,toFlatObject:t2,kindOf:Us,kindOfTest:ir,endsWith:r2,toArray:n2,forEachEntry:i2,matchAll:a2,isHTMLForm:o2,hasOwnProperty:Ml,hasOwnProp:Ml,reduceDescriptors:o1,freezeMethods:u2,toObjectSet:d2,toCamelCase:l2,noop:h2,toFiniteNumber:f2,findKey:i1,global:dn,isContextDefined:a1,isSpecCompliantForm:p2,toJSONObject:m2,isAsyncFn:g2,isThenable:v2,setImmediate:l1,asap:b2,isIterable:y2};function Ne(t,e,r,n,s){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),s&&(this.response=s,this.status=s.status?s.status:null)}B.inherits(Ne,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:B.toJSONObject(this.config),code:this.code,status:this.status}}});const c1=Ne.prototype,u1={};["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=>{u1[t]={value:t}});Object.defineProperties(Ne,u1);Object.defineProperty(c1,"isAxiosError",{value:!0});Ne.from=(t,e,r,n,s,i)=>{const a=Object.create(c1);return B.toFlatObject(t,a,function(l){return l!==Error.prototype},o=>o!=="isAxiosError"),Ne.call(a,t.message,e,r,n,s),a.cause=t,a.name=t.name,i&&Object.assign(a,i),a};const w2=null;function ra(t){return B.isPlainObject(t)||B.isArray(t)}function d1(t){return B.endsWith(t,"[]")?t.slice(0,-2):t}function Nl(t,e,r){return t?t.concat(e).map(function(s,i){return s=d1(s),!r&&i?"["+s+"]":s}).join(r?".":""):e}function x2(t){return B.isArray(t)&&!t.some(ra)}const k2=B.toFlatObject(B,{},null,function(e){return/^is[A-Z]/.test(e)});function Ws(t,e,r){if(!B.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,r=B.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(x,y){return!B.isUndefined(y[x])});const n=r.metaTokens,s=r.visitor||d,i=r.dots,a=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&B.isSpecCompliantForm(e);if(!B.isFunction(s))throw new TypeError("visitor must be a function");function c(v){if(v===null)return"";if(B.isDate(v))return v.toISOString();if(B.isBoolean(v))return v.toString();if(!l&&B.isBlob(v))throw new Ne("Blob is not supported. Use a Buffer instead.");return B.isArrayBuffer(v)||B.isTypedArray(v)?l&&typeof Blob=="function"?new Blob([v]):Buffer.from(v):v}function d(v,x,y){let M=v;if(v&&!y&&typeof v=="object"){if(B.endsWith(x,"{}"))x=n?x:x.slice(0,-2),v=JSON.stringify(v);else if(B.isArray(v)&&x2(v)||(B.isFileList(v)||B.endsWith(x,"[]"))&&(M=B.toArray(v)))return x=d1(x),M.forEach(function(T,N){!(B.isUndefined(T)||T===null)&&e.append(a===!0?Nl([x],N,i):a===null?x:x+"[]",c(T))}),!1}return ra(v)?!0:(e.append(Nl(y,x,i),c(v)),!1)}const f=[],p=Object.assign(k2,{defaultVisitor:d,convertValue:c,isVisitable:ra});function b(v,x){if(!B.isUndefined(v)){if(f.indexOf(v)!==-1)throw Error("Circular reference detected in "+x.join("."));f.push(v),B.forEach(v,function(M,k){(!(B.isUndefined(M)||M===null)&&s.call(e,M,B.isString(k)?k.trim():k,x,p))===!0&&b(M,x?x.concat(k):[k])}),f.pop()}}if(!B.isObject(t))throw new TypeError("data must be an object");return b(t),e}function Dl(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(n){return e[n]})}function Za(t,e){this._pairs=[],t&&Ws(t,this,e)}const h1=Za.prototype;h1.append=function(e,r){this._pairs.push([e,r])};h1.toString=function(e){const r=e?function(n){return e.call(this,n,Dl)}:Dl;return this._pairs.map(function(s){return r(s[0])+"="+r(s[1])},"").join("&")};function S2(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function f1(t,e,r){if(!e)return t;const n=r&&r.encode||S2;B.isFunction(r)&&(r={serialize:r});const s=r&&r.serialize;let i;if(s?i=s(e,r):i=B.isURLSearchParams(e)?e.toString():new Za(e,r).toString(n),i){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+i}return t}class T2{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){B.forEach(this.handlers,function(n){n!==null&&e(n)})}}const Rl=T2,p1={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},A2=typeof URLSearchParams<"u"?URLSearchParams:Za,E2=typeof FormData<"u"?FormData:null,C2=typeof Blob<"u"?Blob:null,M2={isBrowser:!0,classes:{URLSearchParams:A2,FormData:E2,Blob:C2},protocols:["http","https","file","blob","url","data"]},Qa=typeof window<"u"&&typeof document<"u",na=typeof navigator=="object"&&navigator||void 0,N2=Qa&&(!na||["ReactNative","NativeScript","NS"].indexOf(na.product)<0),D2=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),R2=Qa&&window.location.href||"http://localhost",I2=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Qa,hasStandardBrowserEnv:N2,hasStandardBrowserWebWorkerEnv:D2,navigator:na,origin:R2},Symbol.toStringTag,{value:"Module"})),xt={...I2,...M2};function _2(t,e){return Ws(t,new xt.classes.URLSearchParams,{visitor:function(r,n,s,i){return xt.isNode&&B.isBuffer(r)?(this.append(n,r.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)},...e})}function O2(t){return B.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function L2(t){const e={},r=Object.keys(t);let n;const s=r.length;let i;for(n=0;n<s;n++)i=r[n],e[i]=t[i];return e}function m1(t){function e(r,n,s,i){let a=r[i++];if(a==="__proto__")return!0;const o=Number.isFinite(+a),l=i>=r.length;return a=!a&&B.isArray(s)?s.length:a,l?(B.hasOwnProp(s,a)?s[a]=[s[a],n]:s[a]=n,!o):((!s[a]||!B.isObject(s[a]))&&(s[a]=[]),e(r,n,s[a],i)&&B.isArray(s[a])&&(s[a]=L2(s[a])),!o)}if(B.isFormData(t)&&B.isFunction(t.entries)){const r={};return B.forEachEntry(t,(n,s)=>{e(O2(n),s,r,0)}),r}return null}function z2(t,e,r){if(B.isString(t))try{return(e||JSON.parse)(t),B.trim(t)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(t)}const eo={transitional:p1,adapter:["xhr","http","fetch"],transformRequest:[function(e,r){const n=r.getContentType()||"",s=n.indexOf("application/json")>-1,i=B.isObject(e);if(i&&B.isHTMLForm(e)&&(e=new FormData(e)),B.isFormData(e))return s?JSON.stringify(m1(e)):e;if(B.isArrayBuffer(e)||B.isBuffer(e)||B.isStream(e)||B.isFile(e)||B.isBlob(e)||B.isReadableStream(e))return e;if(B.isArrayBufferView(e))return e.buffer;if(B.isURLSearchParams(e))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let o;if(i){if(n.indexOf("application/x-www-form-urlencoded")>-1)return _2(e,this.formSerializer).toString();if((o=B.isFileList(e))||n.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return Ws(o?{"files[]":e}:e,l&&new l,this.formSerializer)}}return i||s?(r.setContentType("application/json",!1),z2(e)):e}],transformResponse:[function(e){const r=this.transitional||eo.transitional,n=r&&r.forcedJSONParsing,s=this.responseType==="json";if(B.isResponse(e)||B.isReadableStream(e))return e;if(e&&B.isString(e)&&(n&&!this.responseType||s)){const a=!(r&&r.silentJSONParsing)&&s;try{return JSON.parse(e)}catch(o){if(a)throw o.name==="SyntaxError"?Ne.from(o,Ne.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:xt.classes.FormData,Blob:xt.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};B.forEach(["delete","get","head","post","put","patch"],t=>{eo.headers[t]={}});const to=eo,F2=B.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"]),$2=t=>{const e={};let r,n,s;return t&&t.split(`
|
||
`).forEach(function(a){s=a.indexOf(":"),r=a.substring(0,s).trim().toLowerCase(),n=a.substring(s+1).trim(),!(!r||e[r]&&F2[r])&&(r==="set-cookie"?e[r]?e[r].push(n):e[r]=[n]:e[r]=e[r]?e[r]+", "+n:n)}),e},Il=Symbol("internals");function Gn(t){return t&&String(t).trim().toLowerCase()}function ts(t){return t===!1||t==null?t:B.isArray(t)?t.map(ts):String(t)}function B2(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 P2=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function yi(t,e,r,n,s){if(B.isFunction(n))return n.call(this,e,r);if(s&&(e=r),!!B.isString(e)){if(B.isString(n))return e.indexOf(n)!==-1;if(B.isRegExp(n))return n.test(e)}}function H2(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,r,n)=>r.toUpperCase()+n)}function q2(t,e){const r=B.toCamelCase(" "+e);["get","set","has"].forEach(n=>{Object.defineProperty(t,n+r,{value:function(s,i,a){return this[n].call(this,e,s,i,a)},configurable:!0})})}class Gs{constructor(e){e&&this.set(e)}set(e,r,n){const s=this;function i(o,l,c){const d=Gn(l);if(!d)throw new Error("header name must be a non-empty string");const f=B.findKey(s,d);(!f||s[f]===void 0||c===!0||c===void 0&&s[f]!==!1)&&(s[f||l]=ts(o))}const a=(o,l)=>B.forEach(o,(c,d)=>i(c,d,l));if(B.isPlainObject(e)||e instanceof this.constructor)a(e,r);else if(B.isString(e)&&(e=e.trim())&&!P2(e))a($2(e),r);else if(B.isObject(e)&&B.isIterable(e)){let o={},l,c;for(const d of e){if(!B.isArray(d))throw TypeError("Object iterator must return a key-value pair");o[c=d[0]]=(l=o[c])?B.isArray(l)?[...l,d[1]]:[l,d[1]]:d[1]}a(o,r)}else e!=null&&i(r,e,n);return this}get(e,r){if(e=Gn(e),e){const n=B.findKey(this,e);if(n){const s=this[n];if(!r)return s;if(r===!0)return B2(s);if(B.isFunction(r))return r.call(this,s,n);if(B.isRegExp(r))return r.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,r){if(e=Gn(e),e){const n=B.findKey(this,e);return!!(n&&this[n]!==void 0&&(!r||yi(this,this[n],n,r)))}return!1}delete(e,r){const n=this;let s=!1;function i(a){if(a=Gn(a),a){const o=B.findKey(n,a);o&&(!r||yi(n,n[o],o,r))&&(delete n[o],s=!0)}}return B.isArray(e)?e.forEach(i):i(e),s}clear(e){const r=Object.keys(this);let n=r.length,s=!1;for(;n--;){const i=r[n];(!e||yi(this,this[i],i,e,!0))&&(delete this[i],s=!0)}return s}normalize(e){const r=this,n={};return B.forEach(this,(s,i)=>{const a=B.findKey(n,i);if(a){r[a]=ts(s),delete r[i];return}const o=e?H2(i):String(i).trim();o!==i&&delete r[i],r[o]=ts(s),n[o]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const r=Object.create(null);return B.forEach(this,(n,s)=>{n!=null&&n!==!1&&(r[s]=e&&B.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(s=>n.set(s)),n}static accessor(e){const n=(this[Il]=this[Il]={accessors:{}}).accessors,s=this.prototype;function i(a){const o=Gn(a);n[o]||(q2(s,a),n[o]=!0)}return B.isArray(e)?e.forEach(i):i(e),this}}Gs.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);B.reduceDescriptors(Gs.prototype,({value:t},e)=>{let r=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(n){this[r]=n}}});B.freezeMethods(Gs);const nr=Gs;function wi(t,e){const r=this||to,n=e||r,s=nr.from(n.headers);let i=n.data;return B.forEach(t,function(o){i=o.call(r,i,s.normalize(),e?e.status:void 0)}),s.normalize(),i}function g1(t){return!!(t&&t.__CANCEL__)}function Pn(t,e,r){Ne.call(this,t??"canceled",Ne.ERR_CANCELED,e,r),this.name="CanceledError"}B.inherits(Pn,Ne,{__CANCEL__:!0});function v1(t,e,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?t(r):e(new Ne("Request failed with status code "+r.status,[Ne.ERR_BAD_REQUEST,Ne.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function j2(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function U2(t,e){t=t||10;const r=new Array(t),n=new Array(t);let s=0,i=0,a;return e=e!==void 0?e:1e3,function(l){const c=Date.now(),d=n[i];a||(a=c),r[s]=l,n[s]=c;let f=i,p=0;for(;f!==s;)p+=r[f++],f=f%t;if(s=(s+1)%t,s===i&&(i=(i+1)%t),c-a<e)return;const b=d&&c-d;return b?Math.round(p*1e3/b):void 0}}function V2(t,e){let r=0,n=1e3/e,s,i;const a=(c,d=Date.now())=>{r=d,s=null,i&&(clearTimeout(i),i=null),t(...c)};return[(...c)=>{const d=Date.now(),f=d-r;f>=n?a(c,d):(s=c,i||(i=setTimeout(()=>{i=null,a(s)},n-f)))},()=>s&&a(s)]}const ws=(t,e,r=3)=>{let n=0;const s=U2(50,250);return V2(i=>{const a=i.loaded,o=i.lengthComputable?i.total:void 0,l=a-n,c=s(l),d=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&&d?(o-a)/c:void 0,event:i,lengthComputable:o!=null,[e?"download":"upload"]:!0};t(f)},r)},_l=(t,e)=>{const r=t!=null;return[n=>e[0]({lengthComputable:r,total:t,loaded:n}),e[1]]},Ol=t=>(...e)=>B.asap(()=>t(...e)),W2=xt.hasStandardBrowserEnv?((t,e)=>r=>(r=new URL(r,xt.origin),t.protocol===r.protocol&&t.host===r.host&&(e||t.port===r.port)))(new URL(xt.origin),xt.navigator&&/(msie|trident)/i.test(xt.navigator.userAgent)):()=>!0,G2=xt.hasStandardBrowserEnv?{write(t,e,r,n,s,i){const a=[t+"="+encodeURIComponent(e)];B.isNumber(r)&&a.push("expires="+new Date(r).toGMTString()),B.isString(n)&&a.push("path="+n),B.isString(s)&&a.push("domain="+s),i===!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 K2(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function Y2(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function b1(t,e,r){let n=!K2(e);return t&&(n||r==!1)?Y2(t,e):e}const Ll=t=>t instanceof nr?{...t}:t;function pn(t,e){e=e||{};const r={};function n(c,d,f,p){return B.isPlainObject(c)&&B.isPlainObject(d)?B.merge.call({caseless:p},c,d):B.isPlainObject(d)?B.merge({},d):B.isArray(d)?d.slice():d}function s(c,d,f,p){if(B.isUndefined(d)){if(!B.isUndefined(c))return n(void 0,c,f,p)}else return n(c,d,f,p)}function i(c,d){if(!B.isUndefined(d))return n(void 0,d)}function a(c,d){if(B.isUndefined(d)){if(!B.isUndefined(c))return n(void 0,c)}else return n(void 0,d)}function o(c,d,f){if(f in e)return n(c,d);if(f in t)return n(void 0,c)}const l={url:i,method:i,data:i,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,d,f)=>s(Ll(c),Ll(d),f,!0)};return B.forEach(Object.keys({...t,...e}),function(d){const f=l[d]||s,p=f(t[d],e[d],d);B.isUndefined(p)&&f!==o||(r[d]=p)}),r}const y1=t=>{const e=pn({},t);let{data:r,withXSRFToken:n,xsrfHeaderName:s,xsrfCookieName:i,headers:a,auth:o}=e;e.headers=a=nr.from(a),e.url=f1(b1(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(B.isFormData(r)){if(xt.hasStandardBrowserEnv||xt.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((l=a.getContentType())!==!1){const[c,...d]=l?l.split(";").map(f=>f.trim()).filter(Boolean):[];a.setContentType([c||"multipart/form-data",...d].join("; "))}}if(xt.hasStandardBrowserEnv&&(n&&B.isFunction(n)&&(n=n(e)),n||n!==!1&&W2(e.url))){const c=s&&i&&G2.read(i);c&&a.set(s,c)}return e},X2=typeof XMLHttpRequest<"u",J2=X2&&function(t){return new Promise(function(r,n){const s=y1(t);let i=s.data;const a=nr.from(s.headers).normalize();let{responseType:o,onUploadProgress:l,onDownloadProgress:c}=s,d,f,p,b,v;function x(){b&&b(),v&&v(),s.cancelToken&&s.cancelToken.unsubscribe(d),s.signal&&s.signal.removeEventListener("abort",d)}let y=new XMLHttpRequest;y.open(s.method.toUpperCase(),s.url,!0),y.timeout=s.timeout;function M(){if(!y)return;const T=nr.from("getAllResponseHeaders"in y&&y.getAllResponseHeaders()),I={data:!o||o==="text"||o==="json"?y.responseText:y.response,status:y.status,statusText:y.statusText,headers:T,config:t,request:y};v1(function(z){r(z),x()},function(z){n(z),x()},I),y=null}"onloadend"in y?y.onloadend=M:y.onreadystatechange=function(){!y||y.readyState!==4||y.status===0&&!(y.responseURL&&y.responseURL.indexOf("file:")===0)||setTimeout(M)},y.onabort=function(){y&&(n(new Ne("Request aborted",Ne.ECONNABORTED,t,y)),y=null)},y.onerror=function(){n(new Ne("Network Error",Ne.ERR_NETWORK,t,y)),y=null},y.ontimeout=function(){let N=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const I=s.transitional||p1;s.timeoutErrorMessage&&(N=s.timeoutErrorMessage),n(new Ne(N,I.clarifyTimeoutError?Ne.ETIMEDOUT:Ne.ECONNABORTED,t,y)),y=null},i===void 0&&a.setContentType(null),"setRequestHeader"in y&&B.forEach(a.toJSON(),function(N,I){y.setRequestHeader(I,N)}),B.isUndefined(s.withCredentials)||(y.withCredentials=!!s.withCredentials),o&&o!=="json"&&(y.responseType=s.responseType),c&&([p,v]=ws(c,!0),y.addEventListener("progress",p)),l&&y.upload&&([f,b]=ws(l),y.upload.addEventListener("progress",f),y.upload.addEventListener("loadend",b)),(s.cancelToken||s.signal)&&(d=T=>{y&&(n(!T||T.type?new Pn(null,t,y):T),y.abort(),y=null)},s.cancelToken&&s.cancelToken.subscribe(d),s.signal&&(s.signal.aborted?d():s.signal.addEventListener("abort",d)));const k=j2(s.url);if(k&&xt.protocols.indexOf(k)===-1){n(new Ne("Unsupported protocol "+k+":",Ne.ERR_BAD_REQUEST,t));return}y.send(i||null)})},Z2=(t,e)=>{const{length:r}=t=t?t.filter(Boolean):[];if(e||r){let n=new AbortController,s;const i=function(c){if(!s){s=!0,o();const d=c instanceof Error?c:this.reason;n.abort(d instanceof Ne?d:new Pn(d instanceof Error?d.message:d))}};let a=e&&setTimeout(()=>{a=null,i(new Ne(`timeout ${e} of ms exceeded`,Ne.ETIMEDOUT))},e);const o=()=>{t&&(a&&clearTimeout(a),a=null,t.forEach(c=>{c.unsubscribe?c.unsubscribe(i):c.removeEventListener("abort",i)}),t=null)};t.forEach(c=>c.addEventListener("abort",i));const{signal:l}=n;return l.unsubscribe=()=>B.asap(o),l}},Q2=Z2,e3=function*(t,e){let r=t.byteLength;if(!e||r<e){yield t;return}let n=0,s;for(;n<r;)s=n+e,yield t.slice(n,s),n=s},t3=async function*(t,e){for await(const r of r3(t))yield*e3(r,e)},r3=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()}},zl=(t,e,r,n)=>{const s=t3(t,e);let i=0,a,o=l=>{a||(a=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:c,value:d}=await s.next();if(c){o(),l.close();return}let f=d.byteLength;if(r){let p=i+=f;r(p)}l.enqueue(new Uint8Array(d))}catch(c){throw o(c),c}},cancel(l){return o(l),s.return()}},{highWaterMark:2})},Ks=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",w1=Ks&&typeof ReadableStream=="function",n3=Ks&&(typeof TextEncoder=="function"?(t=>e=>t.encode(e))(new TextEncoder):async t=>new Uint8Array(await new Response(t).arrayBuffer())),x1=(t,...e)=>{try{return!!t(...e)}catch{return!1}},s3=w1&&x1(()=>{let t=!1;const e=new Request(xt.origin,{body:new ReadableStream,method:"POST",get duplex(){return t=!0,"half"}}).headers.has("Content-Type");return t&&!e}),Fl=64*1024,sa=w1&&x1(()=>B.isReadableStream(new Response("").body)),xs={stream:sa&&(t=>t.body)};Ks&&(t=>{["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!xs[e]&&(xs[e]=B.isFunction(t[e])?r=>r[e]():(r,n)=>{throw new Ne(`Response type '${e}' is not supported`,Ne.ERR_NOT_SUPPORT,n)})})})(new Response);const i3=async t=>{if(t==null)return 0;if(B.isBlob(t))return t.size;if(B.isSpecCompliantForm(t))return(await new Request(xt.origin,{method:"POST",body:t}).arrayBuffer()).byteLength;if(B.isArrayBufferView(t)||B.isArrayBuffer(t))return t.byteLength;if(B.isURLSearchParams(t)&&(t=t+""),B.isString(t))return(await n3(t)).byteLength},a3=async(t,e)=>{const r=B.toFiniteNumber(t.getContentLength());return r??i3(e)},o3=Ks&&(async t=>{let{url:e,method:r,data:n,signal:s,cancelToken:i,timeout:a,onDownloadProgress:o,onUploadProgress:l,responseType:c,headers:d,withCredentials:f="same-origin",fetchOptions:p}=y1(t);c=c?(c+"").toLowerCase():"text";let b=Q2([s,i&&i.toAbortSignal()],a),v;const x=b&&b.unsubscribe&&(()=>{b.unsubscribe()});let y;try{if(l&&s3&&r!=="get"&&r!=="head"&&(y=await a3(d,n))!==0){let I=new Request(e,{method:"POST",body:n,duplex:"half"}),O;if(B.isFormData(n)&&(O=I.headers.get("content-type"))&&d.setContentType(O),I.body){const[z,W]=_l(y,ws(Ol(l)));n=zl(I.body,Fl,z,W)}}B.isString(f)||(f=f?"include":"omit");const M="credentials"in Request.prototype;v=new Request(e,{...p,signal:b,method:r.toUpperCase(),headers:d.normalize().toJSON(),body:n,duplex:"half",credentials:M?f:void 0});let k=await fetch(v,p);const T=sa&&(c==="stream"||c==="response");if(sa&&(o||T&&x)){const I={};["status","statusText","headers"].forEach(U=>{I[U]=k[U]});const O=B.toFiniteNumber(k.headers.get("content-length")),[z,W]=o&&_l(O,ws(Ol(o),!0))||[];k=new Response(zl(k.body,Fl,z,()=>{W&&W(),x&&x()}),I)}c=c||"text";let N=await xs[B.findKey(xs,c)||"text"](k,t);return!T&&x&&x(),await new Promise((I,O)=>{v1(I,O,{data:N,headers:nr.from(k.headers),status:k.status,statusText:k.statusText,config:t,request:v})})}catch(M){throw x&&x(),M&&M.name==="TypeError"&&/Load failed|fetch/i.test(M.message)?Object.assign(new Ne("Network Error",Ne.ERR_NETWORK,t,v),{cause:M.cause||M}):Ne.from(M,M&&M.code,t,v)}}),ia={http:w2,xhr:J2,fetch:o3};B.forEach(ia,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const $l=t=>`- ${t}`,l3=t=>B.isFunction(t)||t===null||t===!1,k1={getAdapter:t=>{t=B.isArray(t)?t:[t];const{length:e}=t;let r,n;const s={};for(let i=0;i<e;i++){r=t[i];let a;if(n=r,!l3(r)&&(n=ia[(a=String(r)).toLowerCase()],n===void 0))throw new Ne(`Unknown adapter '${a}'`);if(n)break;s[a||"#"+i]=n}if(!n){const i=Object.entries(s).map(([o,l])=>`adapter ${o} `+(l===!1?"is not supported by the environment":"is not available in the build"));let a=e?i.length>1?`since :
|
||
`+i.map($l).join(`
|
||
`):" "+$l(i[0]):"as no adapter specified";throw new Ne("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return n},adapters:ia};function xi(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new Pn(null,t)}function Bl(t){return xi(t),t.headers=nr.from(t.headers),t.data=wi.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),k1.getAdapter(t.adapter||to.adapter)(t).then(function(n){return xi(t),n.data=wi.call(t,t.transformResponse,n),n.headers=nr.from(n.headers),n},function(n){return g1(n)||(xi(t),n&&n.response&&(n.response.data=wi.call(t,t.transformResponse,n.response),n.response.headers=nr.from(n.response.headers))),Promise.reject(n)})}const S1="1.11.0",Ys={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{Ys[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}});const Pl={};Ys.transitional=function(e,r,n){function s(i,a){return"[Axios v"+S1+"] Transitional option '"+i+"'"+a+(n?". "+n:"")}return(i,a,o)=>{if(e===!1)throw new Ne(s(a," has been removed"+(r?" in "+r:"")),Ne.ERR_DEPRECATED);return r&&!Pl[a]&&(Pl[a]=!0,console.warn(s(a," has been deprecated since v"+r+" and will be removed in the near future"))),e?e(i,a,o):!0}};Ys.spelling=function(e){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${e}`),!0)};function c3(t,e,r){if(typeof t!="object")throw new Ne("options must be an object",Ne.ERR_BAD_OPTION_VALUE);const n=Object.keys(t);let s=n.length;for(;s-- >0;){const i=n[s],a=e[i];if(a){const o=t[i],l=o===void 0||a(o,i,t);if(l!==!0)throw new Ne("option "+i+" must be "+l,Ne.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new Ne("Unknown option "+i,Ne.ERR_BAD_OPTION)}}const rs={assertOptions:c3,validators:Ys},or=rs.validators;class ks{constructor(e){this.defaults=e||{},this.interceptors={request:new Rl,response:new Rl}}async request(e,r){try{return await this._request(e,r)}catch(n){if(n instanceof Error){let s={};Error.captureStackTrace?Error.captureStackTrace(s):s=new Error;const i=s.stack?s.stack.replace(/^.+\n/,""):"";try{n.stack?i&&!String(n.stack).endsWith(i.replace(/^.+\n.+\n/,""))&&(n.stack+=`
|
||
`+i):n.stack=i}catch{}}throw n}}_request(e,r){typeof e=="string"?(r=r||{},r.url=e):r=e||{},r=pn(this.defaults,r);const{transitional:n,paramsSerializer:s,headers:i}=r;n!==void 0&&rs.assertOptions(n,{silentJSONParsing:or.transitional(or.boolean),forcedJSONParsing:or.transitional(or.boolean),clarifyTimeoutError:or.transitional(or.boolean)},!1),s!=null&&(B.isFunction(s)?r.paramsSerializer={serialize:s}:rs.assertOptions(s,{encode:or.function,serialize:or.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),rs.assertOptions(r,{baseUrl:or.spelling("baseURL"),withXsrfToken:or.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let a=i&&B.merge(i.common,i[r.method]);i&&B.forEach(["delete","get","head","post","put","patch","common"],v=>{delete i[v]}),r.headers=nr.concat(a,i);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 d,f=0,p;if(!l){const v=[Bl.bind(this),void 0];for(v.unshift(...o),v.push(...c),p=v.length,d=Promise.resolve(r);f<p;)d=d.then(v[f++],v[f++]);return d}p=o.length;let b=r;for(f=0;f<p;){const v=o[f++],x=o[f++];try{b=v(b)}catch(y){x.call(this,y);break}}try{d=Bl.call(this,b)}catch(v){return Promise.reject(v)}for(f=0,p=c.length;f<p;)d=d.then(c[f++],c[f++]);return d}getUri(e){e=pn(this.defaults,e);const r=b1(e.baseURL,e.url,e.allowAbsoluteUrls);return f1(r,e.params,e.paramsSerializer)}}B.forEach(["delete","get","head","options"],function(e){ks.prototype[e]=function(r,n){return this.request(pn(n||{},{method:e,url:r,data:(n||{}).data}))}});B.forEach(["post","put","patch"],function(e){function r(n){return function(i,a,o){return this.request(pn(o||{},{method:e,headers:n?{"Content-Type":"multipart/form-data"}:{},url:i,data:a}))}}ks.prototype[e]=r(),ks.prototype[e+"Form"]=r(!0)});const ns=ks;class ro{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(i){r=i});const n=this;this.promise.then(s=>{if(!n._listeners)return;let i=n._listeners.length;for(;i-- >0;)n._listeners[i](s);n._listeners=null}),this.promise.then=s=>{let i;const a=new Promise(o=>{n.subscribe(o),i=o}).then(s);return a.cancel=function(){n.unsubscribe(i)},a},e(function(i,a,o){n.reason||(n.reason=new Pn(i,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 ro(function(s){e=s}),cancel:e}}}const u3=ro;function d3(t){return function(r){return t.apply(null,r)}}function h3(t){return B.isObject(t)&&t.isAxiosError===!0}const aa={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(aa).forEach(([t,e])=>{aa[e]=t});const f3=aa;function T1(t){const e=new ns(t),r=t1(ns.prototype.request,e);return B.extend(r,ns.prototype,e,{allOwnKeys:!0}),B.extend(r,e,null,{allOwnKeys:!0}),r.create=function(s){return T1(pn(t,s))},r}const dt=T1(to);dt.Axios=ns;dt.CanceledError=Pn;dt.CancelToken=u3;dt.isCancel=g1;dt.VERSION=S1;dt.toFormData=Ws;dt.AxiosError=Ne;dt.Cancel=dt.CanceledError;dt.all=function(e){return Promise.all(e)};dt.spread=d3;dt.isAxiosError=h3;dt.mergeConfig=pn;dt.AxiosHeaders=nr;dt.formToJSON=t=>m1(B.isHTMLForm(t)?new FormData(t):t);dt.getAdapter=k1.getAdapter;dt.HttpStatusCode=f3;dt.default=dt;const p3=dt,m3="http://127.0.0.1:8000/api",kn=p3.create({baseURL:m3,timeout:1e4,headers:{"Content-Type":"application/json"}}),lt={createMindmap:(t="思维导图",e=null)=>kn.post("/mindMaps",{title:t,data:e}),getMindmap:t=>kn.get(`/mindMaps/${t}`),getAllMindmaps:()=>kn.get("/mindmaps"),addNodes:(t,e)=>kn.post("/mindMaps/addNodes",{mindMapId:t,nodes:e}),updateNode:(t,e)=>kn.patch("/mindMaps/updateNode",{id:t,...e}),deleteNodes:t=>kn.delete("/mindMaps/deleteNodes",{data:{nodeIds:t}})};function no(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var vn=no();function A1(t){vn=t}var o0={exec:()=>null};function je(t,e=""){let r=typeof t=="string"?t:t.source,n={replace:(s,i)=>{let a=typeof i=="string"?i:i.source;return a=a.replace(Mt.caret,"$1"),r=r.replace(s,a),n},getRegex:()=>new RegExp(r,e)};return n}var Mt={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")},g3=/^(?:[ \t]*(?:\n|$))+/,v3=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,b3=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,S0=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,y3=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,so=/(?:[*+-]|\d{1,9}[.)])/,E1=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,C1=je(E1).replace(/bull/g,so).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(),w3=je(E1).replace(/bull/g,so).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(),io=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,x3=/^[^\n]+/,ao=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,k3=je(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",ao).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),S3=je(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,so).getRegex(),Xs="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",oo=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,T3=je("^ {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",oo).replace("tag",Xs).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),M1=je(io).replace("hr",S0).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",Xs).getRegex(),A3=je(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",M1).getRegex(),lo={blockquote:A3,code:v3,def:k3,fences:b3,heading:y3,hr:S0,html:T3,lheading:C1,list:S3,newline:g3,paragraph:M1,table:o0,text:x3},Hl=je("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",S0).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",Xs).getRegex(),E3={...lo,lheading:w3,table:Hl,paragraph:je(io).replace("hr",S0).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Hl).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",Xs).getRegex()},C3={...lo,html:je(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",oo).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:o0,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:je(io).replace("hr",S0).replace("heading",` *#{1,6} *[^
|
||
]`).replace("lheading",C1).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},M3=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,N3=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,N1=/^( {2,}|\\)\n(?!\s*$)/,D3=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Js=/[\p{P}\p{S}]/u,co=/[\s\p{P}\p{S}]/u,D1=/[^\s\p{P}\p{S}]/u,R3=je(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,co).getRegex(),R1=/(?!~)[\p{P}\p{S}]/u,I3=/(?!~)[\s\p{P}\p{S}]/u,_3=/(?:[^\s\p{P}\p{S}]|~)/u,O3=/\[[^\[\]]*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)|`[^`]*?`|<(?! )[^<>]*?>/g,I1=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,L3=je(I1,"u").replace(/punct/g,Js).getRegex(),z3=je(I1,"u").replace(/punct/g,R1).getRegex(),_1="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",F3=je(_1,"gu").replace(/notPunctSpace/g,D1).replace(/punctSpace/g,co).replace(/punct/g,Js).getRegex(),$3=je(_1,"gu").replace(/notPunctSpace/g,_3).replace(/punctSpace/g,I3).replace(/punct/g,R1).getRegex(),B3=je("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,D1).replace(/punctSpace/g,co).replace(/punct/g,Js).getRegex(),P3=je(/\\(punct)/,"gu").replace(/punct/g,Js).getRegex(),H3=je(/^<(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(),q3=je(oo).replace("(?:-->|$)","-->").getRegex(),j3=je("^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",q3).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Ss=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`[^`]*`|[^\[\]\\`])*?/,U3=je(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",Ss).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),O1=je(/^!?\[(label)\]\[(ref)\]/).replace("label",Ss).replace("ref",ao).getRegex(),L1=je(/^!?\[(ref)\](?:\[\])?/).replace("ref",ao).getRegex(),V3=je("reflink|nolink(?!\\()","g").replace("reflink",O1).replace("nolink",L1).getRegex(),uo={_backpedal:o0,anyPunctuation:P3,autolink:H3,blockSkip:O3,br:N1,code:N3,del:o0,emStrongLDelim:L3,emStrongRDelimAst:F3,emStrongRDelimUnd:B3,escape:M3,link:U3,nolink:L1,punctuation:R3,reflink:O1,reflinkSearch:V3,tag:j3,text:D3,url:o0},W3={...uo,link:je(/^!?\[(label)\]\((.*?)\)/).replace("label",Ss).getRegex(),reflink:je(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",Ss).getRegex()},oa={...uo,emStrongRDelimAst:$3,emStrongLDelim:z3,url:je(/^((?: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.!#$%&'*+\/=?_`{\|}~-]+@)))/},G3={...oa,br:je(N1).replace("{2,}","*").getRegex(),text:je(oa.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},F0={normal:lo,gfm:E3,pedantic:C3},Kn={normal:uo,gfm:oa,breaks:G3,pedantic:W3},K3={"&":"&","<":"<",">":">",'"':""","'":"'"},ql=t=>K3[t];function lr(t,e){if(e){if(Mt.escapeTest.test(t))return t.replace(Mt.escapeReplace,ql)}else if(Mt.escapeTestNoEncode.test(t))return t.replace(Mt.escapeReplaceNoEncode,ql);return t}function jl(t){try{t=encodeURI(t).replace(Mt.percentDecode,"%")}catch{return null}return t}function Ul(t,e){var i;let r=t.replace(Mt.findPipe,(a,o,l)=>{let c=!1,d=o;for(;--d>=0&&l[d]==="\\";)c=!c;return c?"|":" |"}),n=r.split(Mt.splitPipe),s=0;if(n[0].trim()||n.shift(),n.length>0&&!((i=n.at(-1))!=null&&i.trim())&&n.pop(),e)if(n.length>e)n.splice(e);else for(;n.length<e;)n.push("");for(;s<n.length;s++)n[s]=n[s].trim().replace(Mt.slashPipe,"|");return n}function Yn(t,e,r){let n=t.length;if(n===0)return"";let s=0;for(;s<n;){let i=t.charAt(n-s-1);if(i===e&&!r)s++;else if(i!==e&&r)s++;else break}return t.slice(0,n-s)}function Y3(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 Vl(t,e,r,n,s){let i=e.href,a=e.title||null,o=t[1].replace(s.other.outputLinkReplace,"$1");n.state.inLink=!0;let l={type:t[0].charAt(0)==="!"?"image":"link",raw:r,href:i,title:a,text:o,tokens:n.inlineTokens(o)};return n.state.inLink=!1,l}function X3(t,e,r){let n=t.match(r.other.indentCodeCompensation);if(n===null)return e;let s=n[1];return e.split(`
|
||
`).map(i=>{let a=i.match(r.other.beginningSpace);if(a===null)return i;let[o]=a;return o.length>=s.length?i.slice(s.length):i}).join(`
|
||
`)}var Ts=class{constructor(t){Ge(this,"options");Ge(this,"rules");Ge(this,"lexer");this.options=t||vn}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:Yn(r,`
|
||
`)}}}fences(t){let e=this.rules.block.fences.exec(t);if(e){let r=e[0],n=X3(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=Yn(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:Yn(e[0],`
|
||
`)}}blockquote(t){let e=this.rules.block.blockquote.exec(t);if(e){let r=Yn(e[0],`
|
||
`).split(`
|
||
`),n="",s="",i=[];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(`
|
||
`),d=c.replace(this.rules.other.blockquoteSetextReplace,`
|
||
$1`).replace(this.rules.other.blockquoteSetextReplace2,"");n=n?`${n}
|
||
${c}`:c,s=s?`${s}
|
||
${d}`:d;let f=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(d,i,!0),this.lexer.state.top=f,r.length===0)break;let p=i.at(-1);if((p==null?void 0:p.type)==="code")break;if((p==null?void 0:p.type)==="blockquote"){let b=p,v=b.raw+`
|
||
`+r.join(`
|
||
`),x=this.blockquote(v);i[i.length-1]=x,n=n.substring(0,n.length-b.raw.length)+x.raw,s=s.substring(0,s.length-b.text.length)+x.text;break}else if((p==null?void 0:p.type)==="list"){let b=p,v=b.raw+`
|
||
`+r.join(`
|
||
`),x=this.list(v);i[i.length-1]=x,n=n.substring(0,n.length-p.raw.length)+x.raw,s=s.substring(0,s.length-b.raw.length)+x.raw,r=v.substring(i.at(-1).raw.length).split(`
|
||
`);continue}}return{type:"blockquote",raw:n,tokens:i,text:s}}}list(t){let e=this.rules.block.list.exec(t);if(e){let r=e[1].trim(),n=r.length>1,s={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 i=this.rules.other.listItemRegex(r),a=!1;for(;t;){let l=!1,c="",d="";if(!(e=i.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,M=>" ".repeat(3*M.length)),p=t.split(`
|
||
`,1)[0],b=!f.trim(),v=0;if(this.options.pedantic?(v=2,d=f.trimStart()):b?v=e[1].length+1:(v=e[2].search(this.rules.other.nonSpaceChar),v=v>4?1:v,d=f.slice(v),v+=e[1].length),b&&this.rules.other.blankLine.test(p)&&(c+=p+`
|
||
`,t=t.substring(p.length+1),l=!0),!l){let M=this.rules.other.nextBulletRegex(v),k=this.rules.other.hrRegex(v),T=this.rules.other.fencesBeginRegex(v),N=this.rules.other.headingBeginRegex(v),I=this.rules.other.htmlBeginRegex(v);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," "),T.test(p)||N.test(p)||I.test(p)||M.test(p)||k.test(p))break;if(z.search(this.rules.other.nonSpaceChar)>=v||!p.trim())d+=`
|
||
`+z.slice(v);else{if(b||f.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||T.test(f)||N.test(f)||k.test(f))break;d+=`
|
||
`+p}!b&&!p.trim()&&(b=!0),c+=O+`
|
||
`,t=t.substring(O.length+1),f=z.slice(v)}}s.loose||(a?s.loose=!0:this.rules.other.doubleBlankLine.test(c)&&(a=!0));let x=null,y;this.options.gfm&&(x=this.rules.other.listIsTask.exec(d),x&&(y=x[0]!=="[ ] ",d=d.replace(this.rules.other.listReplaceTask,""))),s.items.push({type:"list_item",raw:c,task:!!x,checked:y,loose:!1,text:d,tokens:[]}),s.raw+=c}let o=s.items.at(-1);if(o)o.raw=o.raw.trimEnd(),o.text=o.text.trimEnd();else return;s.raw=s.raw.trimEnd();for(let l=0;l<s.items.length;l++)if(this.lexer.state.top=!1,s.items[l].tokens=this.lexer.blockTokens(s.items[l].text,[]),!s.loose){let c=s.items[l].tokens.filter(f=>f.type==="space"),d=c.length>0&&c.some(f=>this.rules.other.anyLine.test(f.raw));s.loose=d}if(s.loose)for(let l=0;l<s.items.length;l++)s.items[l].loose=!0;return s}}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"):"",s=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:s}}}table(t){var a;let e=this.rules.block.table.exec(t);if(!e||!this.rules.other.tableDelimiter.test(e[2]))return;let r=Ul(e[1]),n=e[2].replace(this.rules.other.tableAlignChars,"").split("|"),s=(a=e[3])!=null&&a.trim()?e[3].replace(this.rules.other.tableRowBlankLine,"").split(`
|
||
`):[],i={type:"table",raw:e[0],header:[],align:[],rows:[]};if(r.length===n.length){for(let o of n)this.rules.other.tableAlignRight.test(o)?i.align.push("right"):this.rules.other.tableAlignCenter.test(o)?i.align.push("center"):this.rules.other.tableAlignLeft.test(o)?i.align.push("left"):i.align.push(null);for(let o=0;o<r.length;o++)i.header.push({text:r[o],tokens:this.lexer.inline(r[o]),header:!0,align:i.align[o]});for(let o of s)i.rows.push(Ul(o,i.header.length).map((l,c)=>({text:l,tokens:this.lexer.inline(l),header:!1,align:i.align[c]})));return i}}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 i=Yn(r.slice(0,-1),"\\");if((r.length-i.length)%2===0)return}else{let i=Y3(e[2],"()");if(i===-2)return;if(i>-1){let a=(e[0].indexOf("!")===0?5:4)+e[1].length+i;e[2]=e[2].substring(0,i),e[0]=e[0].substring(0,a).trim(),e[3]=""}}let n=e[2],s="";if(this.options.pedantic){let i=this.rules.other.pedanticHrefTitle.exec(n);i&&(n=i[1],s=i[3])}else s=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)),Vl(e,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:s&&s.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," "),s=e[n.toLowerCase()];if(!s){let i=r[0].charAt(0);return{type:"text",raw:i,text:i}}return Vl(r,s,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 s=[...n[0]].length-1,i,a,o=s,l=0,c=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,e=e.slice(-1*t.length+s);(n=c.exec(e))!=null;){if(i=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!i)continue;if(a=[...i].length,n[3]||n[4]){o+=a;continue}else if((n[5]||n[6])&&s%3&&!((s+a)%3)){l+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o+l);let d=[...n[0]][0].length,f=t.slice(0,s+n.index+d+a);if(Math.min(s,a)%2){let b=f.slice(1,-1);return{type:"em",raw:f,text:b,tokens:this.lexer.inlineTokens(b)}}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),s=this.rules.other.startingSpaceChar.test(r)&&this.rules.other.endingSpaceChar.test(r);return n&&s&&(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,s;if(e[2]==="@")n=e[0],s="mailto:"+n;else{let i;do i=e[0],e[0]=((r=this.rules.inline._backpedal.exec(e[0]))==null?void 0:r[0])??"";while(i!==e[0]);n=e[0],e[1]==="www."?s="http://"+e[0]:s=e[0]}return{type:"link",raw:e[0],text:n,href:s,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}}}},Cr=class la{constructor(e){Ge(this,"tokens");Ge(this,"options");Ge(this,"state");Ge(this,"tokenizer");Ge(this,"inlineQueue");this.tokens=[],this.tokens.links=Object.create(null),this.options=e||vn,this.options.tokenizer=this.options.tokenizer||new Ts,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:Mt,block:F0.normal,inline:Kn.normal};this.options.pedantic?(r.block=F0.pedantic,r.inline=Kn.pedantic):this.options.gfm&&(r.block=F0.gfm,this.options.breaks?r.inline=Kn.breaks:r.inline=Kn.gfm),this.tokenizer.rules=r}static get rules(){return{block:F0,inline:Kn}}static lex(e,r){return new la(r).lex(e)}static lexInline(e,r){return new la(r).inlineTokens(e)}lex(e){e=e.replace(Mt.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 s,i,a;for(this.options.pedantic&&(e=e.replace(Mt.tabCharGlobal," ").replace(Mt.spaceLine,""));e;){let o;if((i=(s=this.options.extensions)==null?void 0:s.block)!=null&&i.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,d=e.slice(1),f;this.options.extensions.startBlock.forEach(p=>{f=p.call({lexer:this},d),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,s=null;if(this.tokens.links){let d=Object.keys(this.tokens.links);if(d.length>0)for(;(s=this.tokenizer.rules.inline.reflinkSearch.exec(n))!=null;)d.includes(s[0].slice(s[0].lastIndexOf("[")+1,-1))&&(n=n.slice(0,s.index)+"["+"a".repeat(s[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(s=this.tokenizer.rules.inline.anyPunctuation.exec(n))!=null;)n=n.slice(0,s.index)+"++"+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;(s=this.tokenizer.rules.inline.blockSkip.exec(n))!=null;)n=n.slice(0,s.index)+"["+"a".repeat(s[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);let i=!1,a="";for(;e;){i||(a=""),i=!1;let d;if((l=(o=this.options.extensions)==null?void 0:o.inline)!=null&&l.some(p=>(d=p.call({lexer:this},e,r))?(e=e.substring(d.raw.length),r.push(d),!0):!1))continue;if(d=this.tokenizer.escape(e)){e=e.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.tag(e)){e=e.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.link(e)){e=e.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(d.raw.length);let p=r.at(-1);d.type==="text"&&(p==null?void 0:p.type)==="text"?(p.raw+=d.raw,p.text+=d.text):r.push(d);continue}if(d=this.tokenizer.emStrong(e,n,a)){e=e.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.codespan(e)){e=e.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.br(e)){e=e.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.del(e)){e=e.substring(d.raw.length),r.push(d);continue}if(d=this.tokenizer.autolink(e)){e=e.substring(d.raw.length),r.push(d);continue}if(!this.state.inLink&&(d=this.tokenizer.url(e))){e=e.substring(d.raw.length),r.push(d);continue}let f=e;if((c=this.options.extensions)!=null&&c.startInline){let p=1/0,b=e.slice(1),v;this.options.extensions.startInline.forEach(x=>{v=x.call({lexer:this},b),typeof v=="number"&&v>=0&&(p=Math.min(p,v))}),p<1/0&&p>=0&&(f=e.substring(0,p+1))}if(d=this.tokenizer.inlineText(f)){e=e.substring(d.raw.length),d.raw.slice(-1)!=="_"&&(a=d.raw.slice(-1)),i=!0;let p=r.at(-1);(p==null?void 0:p.type)==="text"?(p.raw+=d.raw,p.text+=d.text):r.push(d);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}},As=class{constructor(t){Ge(this,"options");Ge(this,"parser");this.options=t||vn}space(t){return""}code({text:t,lang:e,escaped:r}){var i;let n=(i=(e||"").match(Mt.notSpaceStart))==null?void 0:i[0],s=t.replace(Mt.endingNewline,"")+`
|
||
`;return n?'<pre><code class="language-'+lr(n)+'">'+(r?s:lr(s,!0))+`</code></pre>
|
||
`:"<pre><code>"+(r?s:lr(s,!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 s=e?"ol":"ul",i=e&&r!==1?' start="'+r+'"':"";return"<"+s+i+`>
|
||
`+n+"</"+s+`>
|
||
`}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+" "+lr(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 s=0;s<t.header.length;s++)r+=this.tablecell(t.header[s]);e+=this.tablerow({text:r});let n="";for(let s=0;s<t.rows.length;s++){let i=t.rows[s];r="";for(let a=0;a<i.length;a++)r+=this.tablecell(i[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>${lr(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),s=jl(t);if(s===null)return n;t=s;let i='<a href="'+t+'"';return e&&(i+=' title="'+lr(e)+'"'),i+=">"+n+"</a>",i}image({href:t,title:e,text:r,tokens:n}){n&&(r=this.parser.parseInline(n,this.parser.textRenderer));let s=jl(t);if(s===null)return lr(r);t=s;let i=`<img src="${t}" alt="${r}"`;return e&&(i+=` title="${lr(e)}"`),i+=">",i}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:lr(t.text)}},ho=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""}},Mr=class ca{constructor(e){Ge(this,"options");Ge(this,"renderer");Ge(this,"textRenderer");this.options=e||vn,this.options.renderer=this.options.renderer||new As,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new ho}static parse(e,r){return new ca(r).parse(e)}static parseInline(e,r){return new ca(r).parseInline(e)}parse(e,r=!0){var s,i;let n="";for(let a=0;a<e.length;a++){let o=e[a];if((i=(s=this.options.extensions)==null?void 0:s.renderers)!=null&&i[o.type]){let c=o,d=this.options.extensions.renderers[c.type].call({parser:this},c);if(d!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(c.type)){n+=d||"";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,d=this.renderer.text(c);for(;a+1<e.length&&e[a+1].type==="text";)c=e[++a],d+=`
|
||
`+this.renderer.text(c);r?n+=this.renderer.paragraph({type:"paragraph",raw:d,text:d,tokens:[{type:"text",raw:d,text:d,escaped:!0}]}):n+=d;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 s,i;let n="";for(let a=0;a<e.length;a++){let o=e[a];if((i=(s=this.options.extensions)==null?void 0:s.renderers)!=null&&i[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}},Fi,ss=(Fi=class{constructor(t){Ge(this,"options");Ge(this,"block");this.options=t||vn}preprocess(t){return t}postprocess(t){return t}processAllTokens(t){return t}provideLexer(){return this.block?Cr.lex:Cr.lexInline}provideParser(){return this.block?Mr.parse:Mr.parseInline}},Ge(Fi,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens"])),Fi),J3=class{constructor(...t){Ge(this,"defaults",no());Ge(this,"options",this.setOptions);Ge(this,"parse",this.parseMarkdown(!0));Ge(this,"parseInline",this.parseMarkdown(!1));Ge(this,"Parser",Mr);Ge(this,"Renderer",As);Ge(this,"TextRenderer",ho);Ge(this,"Lexer",Cr);Ge(this,"Tokenizer",Ts);Ge(this,"Hooks",ss);this.use(...t)}walkTokens(t,e){var n,s;let r=[];for(let i of t)switch(r=r.concat(e.call(this,i)),i.type){case"table":{let a=i;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=i;r=r.concat(this.walkTokens(a.items,e));break}default:{let a=i;(s=(n=this.defaults.extensions)==null?void 0:n.childTokens)!=null&&s[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(s=>{if(!s.name)throw new Error("extension name required");if("renderer"in s){let i=e.renderers[s.name];i?e.renderers[s.name]=function(...a){let o=s.renderer.apply(this,a);return o===!1&&(o=i.apply(this,a)),o}:e.renderers[s.name]=s.renderer}if("tokenizer"in s){if(!s.level||s.level!=="block"&&s.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let i=e[s.level];i?i.unshift(s.tokenizer):e[s.level]=[s.tokenizer],s.start&&(s.level==="block"?e.startBlock?e.startBlock.push(s.start):e.startBlock=[s.start]:s.level==="inline"&&(e.startInline?e.startInline.push(s.start):e.startInline=[s.start]))}"childTokens"in s&&s.childTokens&&(e.childTokens[s.name]=s.childTokens)}),n.extensions=e),r.renderer){let s=this.defaults.renderer||new As(this.defaults);for(let i in r.renderer){if(!(i in s))throw new Error(`renderer '${i}' does not exist`);if(["options","parser"].includes(i))continue;let a=i,o=r.renderer[a],l=s[a];s[a]=(...c)=>{let d=o.apply(s,c);return d===!1&&(d=l.apply(s,c)),d||""}}n.renderer=s}if(r.tokenizer){let s=this.defaults.tokenizer||new Ts(this.defaults);for(let i in r.tokenizer){if(!(i in s))throw new Error(`tokenizer '${i}' does not exist`);if(["options","rules","lexer"].includes(i))continue;let a=i,o=r.tokenizer[a],l=s[a];s[a]=(...c)=>{let d=o.apply(s,c);return d===!1&&(d=l.apply(s,c)),d}}n.tokenizer=s}if(r.hooks){let s=this.defaults.hooks||new ss;for(let i in r.hooks){if(!(i in s))throw new Error(`hook '${i}' does not exist`);if(["options","block"].includes(i))continue;let a=i,o=r.hooks[a],l=s[a];ss.passThroughHooks.has(i)?s[a]=c=>{if(this.defaults.async)return Promise.resolve(o.call(s,c)).then(f=>l.call(s,f));let d=o.call(s,c);return l.call(s,d)}:s[a]=(...c)=>{let d=o.apply(s,c);return d===!1&&(d=l.apply(s,c)),d}}n.hooks=s}if(r.walkTokens){let s=this.defaults.walkTokens,i=r.walkTokens;n.walkTokens=function(a){let o=[];return o.push(i.call(this,a)),s&&(o=o.concat(s.call(this,a))),o}}this.defaults={...this.defaults,...n}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,e){return Cr.lex(t,e??this.defaults)}parser(t,e){return Mr.parse(t,e??this.defaults)}parseMarkdown(t){return(e,r)=>{let n={...r},s={...this.defaults,...n},i=this.onError(!!s.silent,!!s.async);if(this.defaults.async===!0&&n.async===!1)return i(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 i(new Error("marked(): input parameter is undefined or null"));if(typeof e!="string")return i(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected"));s.hooks&&(s.hooks.options=s,s.hooks.block=t);let a=s.hooks?s.hooks.provideLexer():t?Cr.lex:Cr.lexInline,o=s.hooks?s.hooks.provideParser():t?Mr.parse:Mr.parseInline;if(s.async)return Promise.resolve(s.hooks?s.hooks.preprocess(e):e).then(l=>a(l,s)).then(l=>s.hooks?s.hooks.processAllTokens(l):l).then(l=>s.walkTokens?Promise.all(this.walkTokens(l,s.walkTokens)).then(()=>l):l).then(l=>o(l,s)).then(l=>s.hooks?s.hooks.postprocess(l):l).catch(i);try{s.hooks&&(e=s.hooks.preprocess(e));let l=a(e,s);s.hooks&&(l=s.hooks.processAllTokens(l)),s.walkTokens&&this.walkTokens(l,s.walkTokens);let c=o(l,s);return s.hooks&&(c=s.hooks.postprocess(c)),c}catch(l){return i(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>"+lr(r.message+"",!0)+"</pre>";return e?Promise.resolve(n):n}if(e)return Promise.reject(r);throw r}}},mn=new J3;function qe(t,e){return mn.parse(t,e)}qe.options=qe.setOptions=function(t){return mn.setOptions(t),qe.defaults=mn.defaults,A1(qe.defaults),qe};qe.getDefaults=no;qe.defaults=vn;qe.use=function(...t){return mn.use(...t),qe.defaults=mn.defaults,A1(qe.defaults),qe};qe.walkTokens=function(t,e){return mn.walkTokens(t,e)};qe.parseInline=mn.parseInline;qe.Parser=Mr;qe.parser=Mr.parse;qe.Renderer=As;qe.TextRenderer=ho;qe.Lexer=Cr;qe.lexer=Cr.lex;qe.Tokenizer=Ts;qe.Hooks=ss;qe.parse=qe;qe.options;qe.setOptions;qe.use;qe.walkTokens;qe.parseInline;Mr.parse;Cr.lex;var Wl=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Z3(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function v8(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 s=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,s.get?s:{enumerable:!0,get:function(){return t[n]}})}),r}var z1={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 s=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,i=0,a={},o={manual:n.Prism&&n.Prism.manual,disableWorkerMessageHandler:n.Prism&&n.Prism.disableWorkerMessageHandler,util:{encode:function k(T){return T instanceof l?new l(T.type,k(T.content),T.alias):Array.isArray(T)?T.map(k):T.replace(/&/g,"&").replace(/</g,"<").replace(/\u00a0/g," ")},type:function(k){return Object.prototype.toString.call(k).slice(8,-1)},objId:function(k){return k.__id||Object.defineProperty(k,"__id",{value:++i}),k.__id},clone:function k(T,N){N=N||{};var I,O;switch(o.util.type(T)){case"Object":if(O=o.util.objId(T),N[O])return N[O];I={},N[O]=I;for(var z in T)T.hasOwnProperty(z)&&(I[z]=k(T[z],N));return I;case"Array":return O=o.util.objId(T),N[O]?N[O]:(I=[],N[O]=I,T.forEach(function(W,U){I[U]=k(W,N)}),I);default:return T}},getLanguage:function(k){for(;k;){var T=s.exec(k.className);if(T)return T[1].toLowerCase();k=k.parentElement}return"none"},setLanguage:function(k,T){k.className=k.className.replace(RegExp(s,"gi"),""),k.classList.add("language-"+T)},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(I){var k=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(I.stack)||[])[1];if(k){var T=document.getElementsByTagName("script");for(var N in T)if(T[N].src==k)return T[N]}return null}},isActive:function(k,T,N){for(var I="no-"+T;k;){var O=k.classList;if(O.contains(T))return!0;if(O.contains(I))return!1;k=k.parentElement}return!!N}},languages:{plain:a,plaintext:a,text:a,txt:a,extend:function(k,T){var N=o.util.clone(o.languages[k]);for(var I in T)N[I]=T[I];return N},insertBefore:function(k,T,N,I){I=I||o.languages;var O=I[k],z={};for(var W in O)if(O.hasOwnProperty(W)){if(W==T)for(var U in N)N.hasOwnProperty(U)&&(z[U]=N[U]);N.hasOwnProperty(W)||(z[W]=O[W])}var he=I[k];return I[k]=z,o.languages.DFS(o.languages,function(ge,Ae){Ae===he&&ge!=k&&(this[ge]=z)}),z},DFS:function k(T,N,I,O){O=O||{};var z=o.util.objId;for(var W in T)if(T.hasOwnProperty(W)){N.call(T,W,T[W],I||W);var U=T[W],he=o.util.type(U);he==="Object"&&!O[z(U)]?(O[z(U)]=!0,k(U,N,null,O)):he==="Array"&&!O[z(U)]&&(O[z(U)]=!0,k(U,N,W,O))}}},plugins:{},highlightAll:function(k,T){o.highlightAllUnder(document,k,T)},highlightAllUnder:function(k,T,N){var I={callback:N,container:k,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};o.hooks.run("before-highlightall",I),I.elements=Array.prototype.slice.apply(I.container.querySelectorAll(I.selector)),o.hooks.run("before-all-elements-highlight",I);for(var O=0,z;z=I.elements[O++];)o.highlightElement(z,T===!0,I.callback)},highlightElement:function(k,T,N){var I=o.util.getLanguage(k),O=o.languages[I];o.util.setLanguage(k,I);var z=k.parentElement;z&&z.nodeName.toLowerCase()==="pre"&&o.util.setLanguage(z,I);var W=k.textContent,U={element:k,language:I,grammar:O,code:W};function he(Ae){U.highlightedCode=Ae,o.hooks.run("before-insert",U),U.element.innerHTML=U.highlightedCode,o.hooks.run("after-highlight",U),o.hooks.run("complete",U),N&&N.call(U.element)}if(o.hooks.run("before-sanity-check",U),z=U.element.parentElement,z&&z.nodeName.toLowerCase()==="pre"&&!z.hasAttribute("tabindex")&&z.setAttribute("tabindex","0"),!U.code){o.hooks.run("complete",U),N&&N.call(U.element);return}if(o.hooks.run("before-highlight",U),!U.grammar){he(o.util.encode(U.code));return}if(T&&n.Worker){var ge=new Worker(o.filename);ge.onmessage=function(Ae){he(Ae.data)},ge.postMessage(JSON.stringify({language:U.language,code:U.code,immediateClose:!0}))}else he(o.highlight(U.code,U.grammar,U.language))},highlight:function(k,T,N){var I={code:k,grammar:T,language:N};if(o.hooks.run("before-tokenize",I),!I.grammar)throw new Error('The language "'+I.language+'" has no grammar.');return I.tokens=o.tokenize(I.code,I.grammar),o.hooks.run("after-tokenize",I),l.stringify(o.util.encode(I.tokens),I.language)},tokenize:function(k,T){var N=T.rest;if(N){for(var I in N)T[I]=N[I];delete T.rest}var O=new f;return p(O,O.head,k),d(k,O,T,O.head,0),v(O)},hooks:{all:{},add:function(k,T){var N=o.hooks.all;N[k]=N[k]||[],N[k].push(T)},run:function(k,T){var N=o.hooks.all[k];if(!(!N||!N.length))for(var I=0,O;O=N[I++];)O(T)}},Token:l};n.Prism=o;function l(k,T,N,I){this.type=k,this.content=T,this.alias=N,this.length=(I||"").length|0}l.stringify=function k(T,N){if(typeof T=="string")return T;if(Array.isArray(T)){var I="";return T.forEach(function(he){I+=k(he,N)}),I}var O={type:T.type,content:k(T.content,N),tag:"span",classes:["token",T.type],attributes:{},language:N},z=T.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 U in O.attributes)W+=" "+U+'="'+(O.attributes[U]||"").replace(/"/g,""")+'"';return"<"+O.tag+' class="'+O.classes.join(" ")+'"'+W+">"+O.content+"</"+O.tag+">"};function c(k,T,N,I){k.lastIndex=T;var O=k.exec(N);if(O&&I&&O[1]){var z=O[1].length;O.index+=z,O[0]=O[0].slice(z)}return O}function d(k,T,N,I,O,z){for(var W in N)if(!(!N.hasOwnProperty(W)||!N[W])){var U=N[W];U=Array.isArray(U)?U:[U];for(var he=0;he<U.length;++he){if(z&&z.cause==W+","+he)return;var ge=U[he],Ae=ge.inside,et=!!ge.lookbehind,Je=!!ge.greedy,ot=ge.alias;if(Je&&!ge.pattern.global){var Fe=ge.pattern.toString().match(/[imsuy]*$/)[0];ge.pattern=RegExp(ge.pattern.source,Fe+"g")}for(var Ie=ge.pattern||ge,ve=I.next,Me=O;ve!==T.tail&&!(z&&Me>=z.reach);Me+=ve.value.length,ve=ve.next){var tt=ve.value;if(T.length>k.length)return;if(!(tt instanceof l)){var We=1,_e;if(Je){if(_e=c(Ie,Me,k,et),!_e||_e.index>=k.length)break;var V=_e.index,St=_e.index+_e[0].length,mt=Me;for(mt+=ve.value.length;V>=mt;)ve=ve.next,mt+=ve.value.length;if(mt-=ve.value.length,Me=mt,ve.value instanceof l)continue;for(var j=ve;j!==T.tail&&(mt<St||typeof j.value=="string");j=j.next)We++,mt+=j.value.length;We--,tt=k.slice(Me,mt),_e.index-=Me}else if(_e=c(Ie,0,tt,et),!_e)continue;var V=_e.index,re=_e[0],ie=tt.slice(0,V),Ee=tt.slice(V+re.length),ye=Me+tt.length;z&&ye>z.reach&&(z.reach=ye);var fe=ve.prev;ie&&(fe=p(T,fe,ie),Me+=ie.length),b(T,fe,We);var Ue=new l(W,Ae?o.tokenize(re,Ae):re,ot,re);if(ve=p(T,fe,Ue),Ee&&p(T,ve,Ee),We>1){var S={cause:W+","+he,reach:ye};d(k,T,N,ve.prev,Me,S),z&&S.reach>z.reach&&(z.reach=S.reach)}}}}}}function f(){var k={value:null,prev:null,next:null},T={value:null,prev:k,next:null};k.next=T,this.head=k,this.tail=T,this.length=0}function p(k,T,N){var I=T.next,O={value:N,prev:T,next:I};return T.next=O,I.prev=O,k.length++,O}function b(k,T,N){for(var I=T.next,O=0;O<N&&I!==k.tail;O++)I=I.next;T.next=I,I.prev=T,k.length-=O}function v(k){for(var T=[],N=k.head.next;N!==k.tail;)T.push(N.value),N=N.next;return T}if(!n.document)return n.addEventListener&&(o.disableWorkerMessageHandler||n.addEventListener("message",function(k){var T=JSON.parse(k.data),N=T.language,I=T.code,O=T.immediateClose;n.postMessage(o.highlight(I,o.languages[N],N)),O&&n.close()},!1)),o;var x=o.util.currentScript();x&&(o.filename=x.src,x.hasAttribute("data-manual")&&(o.manual=!0));function y(){o.manual||o.highlightAll()}if(!o.manual){var M=document.readyState;M==="loading"||M==="interactive"&&x&&x.defer?document.addEventListener("DOMContentLoaded",y):window.requestAnimationFrame?window.requestAnimationFrame(y):window.setTimeout(y,16)}return o}(e);t.exports&&(t.exports=r),typeof Wl<"u"&&(Wl.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(s,i){var a={};a["language-"+i]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:r.languages[i]},a.cdata=/^<!\[CDATA\[|\]\]>$/i;var o={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:a}};o["language-"+i]={pattern:/[\s\S]+/,inside:r.languages[i]};var l={};l[s]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return s}),"i"),lookbehind:!0,greedy:!0,inside:o},r.languages.insertBefore("markup","cdata",l)}}),Object.defineProperty(r.languages.markup.tag,"addAttribute",{value:function(n,s){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:[s,"language-"+s],inside:r.languages[s]},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 s=/(?:"(?:\\(?:\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+"|"+s.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\\((?:"+s.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+s.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+s.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:s,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 i=n.languages.markup;i&&(i.tag.addInlined("style","css"),i.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…",s=function(x,y){return"✖ Error "+x+" while fetching file: "+y},i="✖ 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",d="failed",f="pre[data-src]:not(["+o+'="'+c+'"]):not(['+o+'="'+l+'"])';function p(x,y,M){var k=new XMLHttpRequest;k.open("GET",x,!0),k.onreadystatechange=function(){k.readyState==4&&(k.status<400&&k.responseText?y(k.responseText):k.status>=400?M(s(k.status,k.statusText)):M(i))},k.send(null)}function b(x){var y=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(x||"");if(y){var M=Number(y[1]),k=y[2],T=y[3];return k?T?[M,Number(T)]:[M,void 0]:[M,M]}}r.hooks.add("before-highlightall",function(x){x.selector+=", "+f}),r.hooks.add("before-sanity-check",function(x){var y=x.element;if(y.matches(f)){x.code="",y.setAttribute(o,l);var M=y.appendChild(document.createElement("CODE"));M.textContent=n;var k=y.getAttribute("data-src"),T=x.language;if(T==="none"){var N=(/\.(\w+)$/.exec(k)||[,"none"])[1];T=a[N]||N}r.util.setLanguage(M,T),r.util.setLanguage(y,T);var I=r.plugins.autoloader;I&&I.loadLanguages(T),p(k,function(O){y.setAttribute(o,c);var z=b(y.getAttribute("data-range"));if(z){var W=O.split(/\r\n?|\n/g),U=z[0],he=z[1]==null?W.length:z[1];U<0&&(U+=W.length),U=Math.max(0,Math.min(U-1,W.length)),he<0&&(he+=W.length),he=Math.max(0,Math.min(he,W.length)),O=W.slice(U,he).join(`
|
||
`),y.hasAttribute("data-start")||y.setAttribute("data-start",String(U+1))}M.textContent=O,r.highlightElement(M)},function(O){y.setAttribute(o,d),M.textContent=O})}}),r.plugins.fileHighlight={highlight:function(y){for(var M=(y||document).querySelectorAll(f),k=0,T;T=M[k++];)r.highlightElement(T)}};var v=!1;r.fileHighlight=function(){v||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),v=!0),r.plugins.fileHighlight.highlight.apply(this,arguments)}}()})(z1);var Q3=z1.exports;const Gl=Z3(Q3);class Ft{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 Ft(e.loc.lexer,e.loc.start,r.loc.end):e&&e.loc}}class Kt{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 Kt(r,Ft.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,s,i,a=r&&r.loc;if(a&&a.start<=a.end){var o=a.lexer.input;s=a.start,i=a.end,s===o.length?n+=" at end of input: ":n+=" at position "+(s+1)+": ";var l=o.slice(s,i).replace(/[^]/g,"$&̲"),c;s>15?c="…"+o.slice(s-15,s):c=o.slice(0,s);var d;i+15<o.length?d=o.slice(i,i+15)+"…":d=o.slice(i),n+=c+l+d}var f=new Error(n);return f.name="ParseError",f.__proto__=te.prototype,f.position=s,s!=null&&i!=null&&(f.length=i-s),f.rawMessage=e,f}}te.prototype.__proto__=Error.prototype;var e6=function(e,r){return e.indexOf(r)!==-1},t6=function(e,r){return e===void 0?r:e},r6=/([A-Z])/g,n6=function(e){return e.replace(r6,"-$1").toLowerCase()},s6={"&":"&",">":">","<":"<",'"':""","'":"'"},i6=/[&><"']/g;function a6(t){return String(t).replace(i6,e=>s6[e])}var F1=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},o6=function(e){var r=F1(e);return r.type==="mathord"||r.type==="textord"||r.type==="atom"},l6=function(e){if(!e)throw new Error("Expected non-null, but got "+String(e));return e},c6=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"},we={contains:e6,deflt:t6,escape:a6,hyphenate:n6,getBaseElem:F1,isCharacterBox:o6,protocolFromUrl:c6},is={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 u6(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 fo{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 is)if(is.hasOwnProperty(r)){var n=is[r];this[r]=e[r]!==void 0?n.processor?n.processor(e[r]):e[r]:u6(n)}}reportNonstrict(e,r,n){var s=this.strict;if(typeof s=="function"&&(s=s(e,r,n)),!(!s||s==="ignore")){if(s===!0||s==="error")throw new te("LaTeX-incompatible input and strict mode is set to 'error': "+(r+" ["+e+"]"),n);s==="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 '"+s+"': "+r+" ["+e+"]"))}}useStrictBehavior(e,r,n){var s=this.strict;if(typeof s=="function")try{s=s(e,r,n)}catch{s="error"}return!s||s==="ignore"?!1:s===!0||s==="error"?!0:s==="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 '"+s+"': "+r+" ["+e+"]")),!1)}isTrusted(e){if(e.url&&!e.protocol){var r=we.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 Pr{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 hr[d6[this.id]]}sub(){return hr[h6[this.id]]}fracNum(){return hr[f6[this.id]]}fracDen(){return hr[p6[this.id]]}cramp(){return hr[m6[this.id]]}text(){return hr[g6[this.id]]}isTight(){return this.size>=2}}var po=0,Es=1,_n=2,Nr=3,m0=4,Vt=5,Fn=6,Nt=7,hr=[new Pr(po,0,!1),new Pr(Es,0,!0),new Pr(_n,1,!1),new Pr(Nr,1,!0),new Pr(m0,2,!1),new Pr(Vt,2,!0),new Pr(Fn,3,!1),new Pr(Nt,3,!0)],d6=[m0,Vt,m0,Vt,Fn,Nt,Fn,Nt],h6=[Vt,Vt,Vt,Vt,Nt,Nt,Nt,Nt],f6=[_n,Nr,m0,Vt,Fn,Nt,Fn,Nt],p6=[Nr,Nr,Vt,Vt,Nt,Nt,Nt,Nt],m6=[Es,Es,Nr,Nr,Vt,Vt,Nt,Nt],g6=[po,Es,_n,Nr,_n,Nr,_n,Nr],ke={DISPLAY:hr[po],TEXT:hr[_n],SCRIPT:hr[m0],SCRIPTSCRIPT:hr[Fn]},ua=[{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 v6(t){for(var e=0;e<ua.length;e++)for(var r=ua[e],n=0;n<r.blocks.length;n++){var s=r.blocks[n];if(t>=s[0]&&t<=s[1])return r.name}return null}var as=[];ua.forEach(t=>t.blocks.forEach(e=>as.push(...e)));function $1(t){for(var e=0;e<as.length;e+=2)if(t>=as[e]&&t<=as[e+1])return!0;return!1}var Sn=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"},y6=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"},w6=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"},x6=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"},k6=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"},S6=function(e){var r=e/2;return"M400000 "+e+" H0 L"+r+" 0 l65 45 L145 "+(e-80)+" H400000z"},T6=function(e,r,n){var s=n-54-r-e;return"M702 "+(e+r)+"H400000"+(40+e)+`
|
||
H742v`+s+`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"},A6=function(e,r,n){r=1e3*r;var s="";switch(e){case"sqrtMain":s=b6(r,Sn);break;case"sqrtSize1":s=y6(r,Sn);break;case"sqrtSize2":s=w6(r,Sn);break;case"sqrtSize3":s=x6(r,Sn);break;case"sqrtSize4":s=k6(r,Sn);break;case"sqrtTall":s=T6(r,Sn,n)}return s},E6=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""}},Kl={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`},C6=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 T0{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 we.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 fr={"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]}},$0={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]},Yl={Å:"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 M6(t,e){fr[t]=e}function mo(t,e,r){if(!fr[e])throw new Error("Font metrics not found for font: "+e+".");var n=t.charCodeAt(0),s=fr[e][n];if(!s&&t[0]in Yl&&(n=Yl[t[0]].charCodeAt(0),s=fr[e][n]),!s&&r==="text"&&$1(n)&&(s=fr[e][77]),s)return{depth:s[0],height:s[1],italic:s[2],skew:s[3],width:s[4]}}var ki={};function N6(t){var e;if(t>=5?e=0:t>=3?e=1:e=2,!ki[e]){var r=ki[e]={cssEmPerMu:$0.quad[e]/18};for(var n in $0)$0.hasOwnProperty(n)&&(r[n]=$0[n][e])}return ki[e]}var D6=[[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]],Xl=[.5,.6,.7,.8,.9,1,1.2,1.44,1.728,2.074,2.488],Jl=function(e,r){return r.size<2?e:D6[e-1][r.size-1]};class Tr{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||Tr.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=Xl[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 Tr(r)}havingStyle(e){return this.style===e?this:this.extend({style:e,size:Jl(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:Xl[e-1]})}havingBaseStyle(e){e=e||this.style.text();var r=Jl(Tr.BASESIZE,e);return this.size===r&&this.textSize===Tr.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!==Tr.BASESIZE?["sizing","reset-size"+this.size,"size"+Tr.BASESIZE]:[]}fontMetrics(){return this._fontMetrics||(this._fontMetrics=N6(this.size)),this._fontMetrics}getColor(){return this.phantom?"transparent":this.color}}Tr.BASESIZE=6;var da={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},R6={ex:!0,em:!0,mu:!0},B1=function(e){return typeof e!="string"&&(e=e.unit),e in da||e in R6||e==="ex"},st=function(e,r){var n;if(e.unit in da)n=da[e.unit]/r.fontMetrics().ptPerEm/r.sizeMultiplier;else if(e.unit==="mu")n=r.fontMetrics().cssEmPerMu;else{var s;if(r.style.isTight()?s=r.havingStyle(r.style.text()):s=r,e.unit==="ex")n=s.fontMetrics().xHeight;else if(e.unit==="em")n=s.fontMetrics().quad;else throw new te("Invalid unit: '"+e.unit+"'");s!==r&&(n*=s.sizeMultiplier/r.sizeMultiplier)}return Math.min(e.number*n,r.maxSize)},ae=function(e){return+e.toFixed(4)+"em"},Yr=function(e){return e.filter(r=>r).join(" ")},P1=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 s=r.getColor();s&&(this.style.color=s)}},H1=function(e){var r=document.createElement(e);r.className=Yr(this.classes);for(var n in this.style)this.style.hasOwnProperty(n)&&(r.style[n]=this.style[n]);for(var s in this.attributes)this.attributes.hasOwnProperty(s)&&r.setAttribute(s,this.attributes[s]);for(var i=0;i<this.children.length;i++)r.appendChild(this.children[i].toNode());return r},I6=/[\s"'>/=\x00-\x1f]/,q1=function(e){var r="<"+e;this.classes.length&&(r+=' class="'+we.escape(Yr(this.classes))+'"');var n="";for(var s in this.style)this.style.hasOwnProperty(s)&&(n+=we.hyphenate(s)+":"+this.style[s]+";");n&&(r+=' style="'+we.escape(n)+'"');for(var i in this.attributes)if(this.attributes.hasOwnProperty(i)){if(I6.test(i))throw new te("Invalid attribute name '"+i+"'");r+=" "+i+'="'+we.escape(this.attributes[i])+'"'}r+=">";for(var a=0;a<this.children.length;a++)r+=this.children[a].toMarkup();return r+="</"+e+">",r};class A0{constructor(e,r,n,s){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,P1.call(this,e,n,s),this.children=r||[]}setAttribute(e,r){this.attributes[e]=r}hasClass(e){return we.contains(this.classes,e)}toNode(){return H1.call(this,"span")}toMarkup(){return q1.call(this,"span")}}class go{constructor(e,r,n,s){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,P1.call(this,r,s),this.children=n||[],this.setAttribute("href",e)}setAttribute(e,r){this.attributes[e]=r}hasClass(e){return we.contains(this.classes,e)}toNode(){return H1.call(this,"a")}toMarkup(){return q1.call(this,"a")}}class _6{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 we.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="'+we.escape(this.src)+'"'+(' alt="'+we.escape(this.alt)+'"'),r="";for(var n in this.style)this.style.hasOwnProperty(n)&&(r+=we.hyphenate(n)+":"+this.style[n]+";");return r&&(e+=' style="'+we.escape(r)+'"'),e+="'/>",e}}var O6={î:"ı̂",ï:"ı̈",í:"ı́",ì:"ı̀"};class Yt{constructor(e,r,n,s,i,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=s||0,this.skew=i||0,this.width=a||0,this.classes=o||[],this.style=l||{},this.maxFontSize=0;var c=v6(this.text.charCodeAt(0));c&&this.classes.push(c+"_fallback"),/[îïíì]/.test(this.text)&&(this.text=O6[this.text])}hasClass(e){return we.contains(this.classes,e)}toNode(){var e=document.createTextNode(this.text),r=null;this.italic>0&&(r=document.createElement("span"),r.style.marginRight=ae(this.italic)),this.classes.length>0&&(r=r||document.createElement("span"),r.className=Yr(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+=we.escape(Yr(this.classes)),r+='"');var n="";this.italic>0&&(n+="margin-right:"+this.italic+"em;");for(var s in this.style)this.style.hasOwnProperty(s)&&(n+=we.hyphenate(s)+":"+this.style[s]+";");n&&(e=!0,r+=' style="'+we.escape(n)+'"');var i=we.escape(this.text);return e?(r+=">",r+=i,r+="</span>",r):i}}class _r{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 s=0;s<this.children.length;s++)r.appendChild(this.children[s].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+'="'+we.escape(this.attributes[r])+'"');e+=">";for(var n=0;n<this.children.length;n++)e+=this.children[n].toMarkup();return e+="</svg>",e}}class Xr{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",Kl[this.pathName]),r}toMarkup(){return this.alternate?'<path d="'+we.escape(this.alternate)+'"/>':'<path d="'+we.escape(Kl[this.pathName])+'"/>'}}class ha{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+'="'+we.escape(this.attributes[r])+'"');return e+="/>",e}}function Zl(t){if(t instanceof Yt)return t;throw new Error("Expected symbolNode but got "+String(t)+".")}function L6(t){if(t instanceof A0)return t;throw new Error("Expected span<HtmlDomNode> but got "+String(t)+".")}var z6={bin:1,close:1,inner:1,open:1,punct:1,rel:1},F6={"accent-token":1,mathord:1,"op-token":1,spacing:1,textord:1},Qe={math:{},text:{}};function u(t,e,r,n,s,i){Qe[t][s]={font:e,group:r,replace:n},i&&n&&(Qe[t][n]=Qe[t][s])}var h="math",K="text",m="main",A="ams",rt="accent-token",ce="bin",Dt="close",Hn="inner",xe="mathord",ht="op-token",jt="open",Zs="punct",C="rel",Fr="spacing",R="textord";u(h,m,C,"≡","\\equiv",!0);u(h,m,C,"≺","\\prec",!0);u(h,m,C,"≻","\\succ",!0);u(h,m,C,"∼","\\sim",!0);u(h,m,C,"⊥","\\perp");u(h,m,C,"⪯","\\preceq",!0);u(h,m,C,"⪰","\\succeq",!0);u(h,m,C,"≃","\\simeq",!0);u(h,m,C,"∣","\\mid",!0);u(h,m,C,"≪","\\ll",!0);u(h,m,C,"≫","\\gg",!0);u(h,m,C,"≍","\\asymp",!0);u(h,m,C,"∥","\\parallel");u(h,m,C,"⋈","\\bowtie",!0);u(h,m,C,"⌣","\\smile",!0);u(h,m,C,"⊑","\\sqsubseteq",!0);u(h,m,C,"⊒","\\sqsupseteq",!0);u(h,m,C,"≐","\\doteq",!0);u(h,m,C,"⌢","\\frown",!0);u(h,m,C,"∋","\\ni",!0);u(h,m,C,"∝","\\propto",!0);u(h,m,C,"⊢","\\vdash",!0);u(h,m,C,"⊣","\\dashv",!0);u(h,m,C,"∋","\\owns");u(h,m,Zs,".","\\ldotp");u(h,m,Zs,"⋅","\\cdotp");u(h,m,R,"#","\\#");u(K,m,R,"#","\\#");u(h,m,R,"&","\\&");u(K,m,R,"&","\\&");u(h,m,R,"ℵ","\\aleph",!0);u(h,m,R,"∀","\\forall",!0);u(h,m,R,"ℏ","\\hbar",!0);u(h,m,R,"∃","\\exists",!0);u(h,m,R,"∇","\\nabla",!0);u(h,m,R,"♭","\\flat",!0);u(h,m,R,"ℓ","\\ell",!0);u(h,m,R,"♮","\\natural",!0);u(h,m,R,"♣","\\clubsuit",!0);u(h,m,R,"℘","\\wp",!0);u(h,m,R,"♯","\\sharp",!0);u(h,m,R,"♢","\\diamondsuit",!0);u(h,m,R,"ℜ","\\Re",!0);u(h,m,R,"♡","\\heartsuit",!0);u(h,m,R,"ℑ","\\Im",!0);u(h,m,R,"♠","\\spadesuit",!0);u(h,m,R,"§","\\S",!0);u(K,m,R,"§","\\S");u(h,m,R,"¶","\\P",!0);u(K,m,R,"¶","\\P");u(h,m,R,"†","\\dag");u(K,m,R,"†","\\dag");u(K,m,R,"†","\\textdagger");u(h,m,R,"‡","\\ddag");u(K,m,R,"‡","\\ddag");u(K,m,R,"‡","\\textdaggerdbl");u(h,m,Dt,"⎱","\\rmoustache",!0);u(h,m,jt,"⎰","\\lmoustache",!0);u(h,m,Dt,"⟯","\\rgroup",!0);u(h,m,jt,"⟮","\\lgroup",!0);u(h,m,ce,"∓","\\mp",!0);u(h,m,ce,"⊖","\\ominus",!0);u(h,m,ce,"⊎","\\uplus",!0);u(h,m,ce,"⊓","\\sqcap",!0);u(h,m,ce,"∗","\\ast");u(h,m,ce,"⊔","\\sqcup",!0);u(h,m,ce,"◯","\\bigcirc",!0);u(h,m,ce,"∙","\\bullet",!0);u(h,m,ce,"‡","\\ddagger");u(h,m,ce,"≀","\\wr",!0);u(h,m,ce,"⨿","\\amalg");u(h,m,ce,"&","\\And");u(h,m,C,"⟵","\\longleftarrow",!0);u(h,m,C,"⇐","\\Leftarrow",!0);u(h,m,C,"⟸","\\Longleftarrow",!0);u(h,m,C,"⟶","\\longrightarrow",!0);u(h,m,C,"⇒","\\Rightarrow",!0);u(h,m,C,"⟹","\\Longrightarrow",!0);u(h,m,C,"↔","\\leftrightarrow",!0);u(h,m,C,"⟷","\\longleftrightarrow",!0);u(h,m,C,"⇔","\\Leftrightarrow",!0);u(h,m,C,"⟺","\\Longleftrightarrow",!0);u(h,m,C,"↦","\\mapsto",!0);u(h,m,C,"⟼","\\longmapsto",!0);u(h,m,C,"↗","\\nearrow",!0);u(h,m,C,"↩","\\hookleftarrow",!0);u(h,m,C,"↪","\\hookrightarrow",!0);u(h,m,C,"↘","\\searrow",!0);u(h,m,C,"↼","\\leftharpoonup",!0);u(h,m,C,"⇀","\\rightharpoonup",!0);u(h,m,C,"↙","\\swarrow",!0);u(h,m,C,"↽","\\leftharpoondown",!0);u(h,m,C,"⇁","\\rightharpoondown",!0);u(h,m,C,"↖","\\nwarrow",!0);u(h,m,C,"⇌","\\rightleftharpoons",!0);u(h,A,C,"≮","\\nless",!0);u(h,A,C,"","\\@nleqslant");u(h,A,C,"","\\@nleqq");u(h,A,C,"⪇","\\lneq",!0);u(h,A,C,"≨","\\lneqq",!0);u(h,A,C,"","\\@lvertneqq");u(h,A,C,"⋦","\\lnsim",!0);u(h,A,C,"⪉","\\lnapprox",!0);u(h,A,C,"⊀","\\nprec",!0);u(h,A,C,"⋠","\\npreceq",!0);u(h,A,C,"⋨","\\precnsim",!0);u(h,A,C,"⪹","\\precnapprox",!0);u(h,A,C,"≁","\\nsim",!0);u(h,A,C,"","\\@nshortmid");u(h,A,C,"∤","\\nmid",!0);u(h,A,C,"⊬","\\nvdash",!0);u(h,A,C,"⊭","\\nvDash",!0);u(h,A,C,"⋪","\\ntriangleleft");u(h,A,C,"⋬","\\ntrianglelefteq",!0);u(h,A,C,"⊊","\\subsetneq",!0);u(h,A,C,"","\\@varsubsetneq");u(h,A,C,"⫋","\\subsetneqq",!0);u(h,A,C,"","\\@varsubsetneqq");u(h,A,C,"≯","\\ngtr",!0);u(h,A,C,"","\\@ngeqslant");u(h,A,C,"","\\@ngeqq");u(h,A,C,"⪈","\\gneq",!0);u(h,A,C,"≩","\\gneqq",!0);u(h,A,C,"","\\@gvertneqq");u(h,A,C,"⋧","\\gnsim",!0);u(h,A,C,"⪊","\\gnapprox",!0);u(h,A,C,"⊁","\\nsucc",!0);u(h,A,C,"⋡","\\nsucceq",!0);u(h,A,C,"⋩","\\succnsim",!0);u(h,A,C,"⪺","\\succnapprox",!0);u(h,A,C,"≆","\\ncong",!0);u(h,A,C,"","\\@nshortparallel");u(h,A,C,"∦","\\nparallel",!0);u(h,A,C,"⊯","\\nVDash",!0);u(h,A,C,"⋫","\\ntriangleright");u(h,A,C,"⋭","\\ntrianglerighteq",!0);u(h,A,C,"","\\@nsupseteqq");u(h,A,C,"⊋","\\supsetneq",!0);u(h,A,C,"","\\@varsupsetneq");u(h,A,C,"⫌","\\supsetneqq",!0);u(h,A,C,"","\\@varsupsetneqq");u(h,A,C,"⊮","\\nVdash",!0);u(h,A,C,"⪵","\\precneqq",!0);u(h,A,C,"⪶","\\succneqq",!0);u(h,A,C,"","\\@nsubseteqq");u(h,A,ce,"⊴","\\unlhd");u(h,A,ce,"⊵","\\unrhd");u(h,A,C,"↚","\\nleftarrow",!0);u(h,A,C,"↛","\\nrightarrow",!0);u(h,A,C,"⇍","\\nLeftarrow",!0);u(h,A,C,"⇏","\\nRightarrow",!0);u(h,A,C,"↮","\\nleftrightarrow",!0);u(h,A,C,"⇎","\\nLeftrightarrow",!0);u(h,A,C,"△","\\vartriangle");u(h,A,R,"ℏ","\\hslash");u(h,A,R,"▽","\\triangledown");u(h,A,R,"◊","\\lozenge");u(h,A,R,"Ⓢ","\\circledS");u(h,A,R,"®","\\circledR");u(K,A,R,"®","\\circledR");u(h,A,R,"∡","\\measuredangle",!0);u(h,A,R,"∄","\\nexists");u(h,A,R,"℧","\\mho");u(h,A,R,"Ⅎ","\\Finv",!0);u(h,A,R,"⅁","\\Game",!0);u(h,A,R,"‵","\\backprime");u(h,A,R,"▲","\\blacktriangle");u(h,A,R,"▼","\\blacktriangledown");u(h,A,R,"■","\\blacksquare");u(h,A,R,"⧫","\\blacklozenge");u(h,A,R,"★","\\bigstar");u(h,A,R,"∢","\\sphericalangle",!0);u(h,A,R,"∁","\\complement",!0);u(h,A,R,"ð","\\eth",!0);u(K,m,R,"ð","ð");u(h,A,R,"╱","\\diagup");u(h,A,R,"╲","\\diagdown");u(h,A,R,"□","\\square");u(h,A,R,"□","\\Box");u(h,A,R,"◊","\\Diamond");u(h,A,R,"¥","\\yen",!0);u(K,A,R,"¥","\\yen",!0);u(h,A,R,"✓","\\checkmark",!0);u(K,A,R,"✓","\\checkmark");u(h,A,R,"ℶ","\\beth",!0);u(h,A,R,"ℸ","\\daleth",!0);u(h,A,R,"ℷ","\\gimel",!0);u(h,A,R,"ϝ","\\digamma",!0);u(h,A,R,"ϰ","\\varkappa");u(h,A,jt,"┌","\\@ulcorner",!0);u(h,A,Dt,"┐","\\@urcorner",!0);u(h,A,jt,"└","\\@llcorner",!0);u(h,A,Dt,"┘","\\@lrcorner",!0);u(h,A,C,"≦","\\leqq",!0);u(h,A,C,"⩽","\\leqslant",!0);u(h,A,C,"⪕","\\eqslantless",!0);u(h,A,C,"≲","\\lesssim",!0);u(h,A,C,"⪅","\\lessapprox",!0);u(h,A,C,"≊","\\approxeq",!0);u(h,A,ce,"⋖","\\lessdot");u(h,A,C,"⋘","\\lll",!0);u(h,A,C,"≶","\\lessgtr",!0);u(h,A,C,"⋚","\\lesseqgtr",!0);u(h,A,C,"⪋","\\lesseqqgtr",!0);u(h,A,C,"≑","\\doteqdot");u(h,A,C,"≓","\\risingdotseq",!0);u(h,A,C,"≒","\\fallingdotseq",!0);u(h,A,C,"∽","\\backsim",!0);u(h,A,C,"⋍","\\backsimeq",!0);u(h,A,C,"⫅","\\subseteqq",!0);u(h,A,C,"⋐","\\Subset",!0);u(h,A,C,"⊏","\\sqsubset",!0);u(h,A,C,"≼","\\preccurlyeq",!0);u(h,A,C,"⋞","\\curlyeqprec",!0);u(h,A,C,"≾","\\precsim",!0);u(h,A,C,"⪷","\\precapprox",!0);u(h,A,C,"⊲","\\vartriangleleft");u(h,A,C,"⊴","\\trianglelefteq");u(h,A,C,"⊨","\\vDash",!0);u(h,A,C,"⊪","\\Vvdash",!0);u(h,A,C,"⌣","\\smallsmile");u(h,A,C,"⌢","\\smallfrown");u(h,A,C,"≏","\\bumpeq",!0);u(h,A,C,"≎","\\Bumpeq",!0);u(h,A,C,"≧","\\geqq",!0);u(h,A,C,"⩾","\\geqslant",!0);u(h,A,C,"⪖","\\eqslantgtr",!0);u(h,A,C,"≳","\\gtrsim",!0);u(h,A,C,"⪆","\\gtrapprox",!0);u(h,A,ce,"⋗","\\gtrdot");u(h,A,C,"⋙","\\ggg",!0);u(h,A,C,"≷","\\gtrless",!0);u(h,A,C,"⋛","\\gtreqless",!0);u(h,A,C,"⪌","\\gtreqqless",!0);u(h,A,C,"≖","\\eqcirc",!0);u(h,A,C,"≗","\\circeq",!0);u(h,A,C,"≜","\\triangleq",!0);u(h,A,C,"∼","\\thicksim");u(h,A,C,"≈","\\thickapprox");u(h,A,C,"⫆","\\supseteqq",!0);u(h,A,C,"⋑","\\Supset",!0);u(h,A,C,"⊐","\\sqsupset",!0);u(h,A,C,"≽","\\succcurlyeq",!0);u(h,A,C,"⋟","\\curlyeqsucc",!0);u(h,A,C,"≿","\\succsim",!0);u(h,A,C,"⪸","\\succapprox",!0);u(h,A,C,"⊳","\\vartriangleright");u(h,A,C,"⊵","\\trianglerighteq");u(h,A,C,"⊩","\\Vdash",!0);u(h,A,C,"∣","\\shortmid");u(h,A,C,"∥","\\shortparallel");u(h,A,C,"≬","\\between",!0);u(h,A,C,"⋔","\\pitchfork",!0);u(h,A,C,"∝","\\varpropto");u(h,A,C,"◀","\\blacktriangleleft");u(h,A,C,"∴","\\therefore",!0);u(h,A,C,"∍","\\backepsilon");u(h,A,C,"▶","\\blacktriangleright");u(h,A,C,"∵","\\because",!0);u(h,A,C,"⋘","\\llless");u(h,A,C,"⋙","\\gggtr");u(h,A,ce,"⊲","\\lhd");u(h,A,ce,"⊳","\\rhd");u(h,A,C,"≂","\\eqsim",!0);u(h,m,C,"⋈","\\Join");u(h,A,C,"≑","\\Doteq",!0);u(h,A,ce,"∔","\\dotplus",!0);u(h,A,ce,"∖","\\smallsetminus");u(h,A,ce,"⋒","\\Cap",!0);u(h,A,ce,"⋓","\\Cup",!0);u(h,A,ce,"⩞","\\doublebarwedge",!0);u(h,A,ce,"⊟","\\boxminus",!0);u(h,A,ce,"⊞","\\boxplus",!0);u(h,A,ce,"⋇","\\divideontimes",!0);u(h,A,ce,"⋉","\\ltimes",!0);u(h,A,ce,"⋊","\\rtimes",!0);u(h,A,ce,"⋋","\\leftthreetimes",!0);u(h,A,ce,"⋌","\\rightthreetimes",!0);u(h,A,ce,"⋏","\\curlywedge",!0);u(h,A,ce,"⋎","\\curlyvee",!0);u(h,A,ce,"⊝","\\circleddash",!0);u(h,A,ce,"⊛","\\circledast",!0);u(h,A,ce,"⋅","\\centerdot");u(h,A,ce,"⊺","\\intercal",!0);u(h,A,ce,"⋒","\\doublecap");u(h,A,ce,"⋓","\\doublecup");u(h,A,ce,"⊠","\\boxtimes",!0);u(h,A,C,"⇢","\\dashrightarrow",!0);u(h,A,C,"⇠","\\dashleftarrow",!0);u(h,A,C,"⇇","\\leftleftarrows",!0);u(h,A,C,"⇆","\\leftrightarrows",!0);u(h,A,C,"⇚","\\Lleftarrow",!0);u(h,A,C,"↞","\\twoheadleftarrow",!0);u(h,A,C,"↢","\\leftarrowtail",!0);u(h,A,C,"↫","\\looparrowleft",!0);u(h,A,C,"⇋","\\leftrightharpoons",!0);u(h,A,C,"↶","\\curvearrowleft",!0);u(h,A,C,"↺","\\circlearrowleft",!0);u(h,A,C,"↰","\\Lsh",!0);u(h,A,C,"⇈","\\upuparrows",!0);u(h,A,C,"↿","\\upharpoonleft",!0);u(h,A,C,"⇃","\\downharpoonleft",!0);u(h,m,C,"⊶","\\origof",!0);u(h,m,C,"⊷","\\imageof",!0);u(h,A,C,"⊸","\\multimap",!0);u(h,A,C,"↭","\\leftrightsquigarrow",!0);u(h,A,C,"⇉","\\rightrightarrows",!0);u(h,A,C,"⇄","\\rightleftarrows",!0);u(h,A,C,"↠","\\twoheadrightarrow",!0);u(h,A,C,"↣","\\rightarrowtail",!0);u(h,A,C,"↬","\\looparrowright",!0);u(h,A,C,"↷","\\curvearrowright",!0);u(h,A,C,"↻","\\circlearrowright",!0);u(h,A,C,"↱","\\Rsh",!0);u(h,A,C,"⇊","\\downdownarrows",!0);u(h,A,C,"↾","\\upharpoonright",!0);u(h,A,C,"⇂","\\downharpoonright",!0);u(h,A,C,"⇝","\\rightsquigarrow",!0);u(h,A,C,"⇝","\\leadsto");u(h,A,C,"⇛","\\Rrightarrow",!0);u(h,A,C,"↾","\\restriction");u(h,m,R,"‘","`");u(h,m,R,"$","\\$");u(K,m,R,"$","\\$");u(K,m,R,"$","\\textdollar");u(h,m,R,"%","\\%");u(K,m,R,"%","\\%");u(h,m,R,"_","\\_");u(K,m,R,"_","\\_");u(K,m,R,"_","\\textunderscore");u(h,m,R,"∠","\\angle",!0);u(h,m,R,"∞","\\infty",!0);u(h,m,R,"′","\\prime");u(h,m,R,"△","\\triangle");u(h,m,R,"Γ","\\Gamma",!0);u(h,m,R,"Δ","\\Delta",!0);u(h,m,R,"Θ","\\Theta",!0);u(h,m,R,"Λ","\\Lambda",!0);u(h,m,R,"Ξ","\\Xi",!0);u(h,m,R,"Π","\\Pi",!0);u(h,m,R,"Σ","\\Sigma",!0);u(h,m,R,"Υ","\\Upsilon",!0);u(h,m,R,"Φ","\\Phi",!0);u(h,m,R,"Ψ","\\Psi",!0);u(h,m,R,"Ω","\\Omega",!0);u(h,m,R,"A","Α");u(h,m,R,"B","Β");u(h,m,R,"E","Ε");u(h,m,R,"Z","Ζ");u(h,m,R,"H","Η");u(h,m,R,"I","Ι");u(h,m,R,"K","Κ");u(h,m,R,"M","Μ");u(h,m,R,"N","Ν");u(h,m,R,"O","Ο");u(h,m,R,"P","Ρ");u(h,m,R,"T","Τ");u(h,m,R,"X","Χ");u(h,m,R,"¬","\\neg",!0);u(h,m,R,"¬","\\lnot");u(h,m,R,"⊤","\\top");u(h,m,R,"⊥","\\bot");u(h,m,R,"∅","\\emptyset");u(h,A,R,"∅","\\varnothing");u(h,m,xe,"α","\\alpha",!0);u(h,m,xe,"β","\\beta",!0);u(h,m,xe,"γ","\\gamma",!0);u(h,m,xe,"δ","\\delta",!0);u(h,m,xe,"ϵ","\\epsilon",!0);u(h,m,xe,"ζ","\\zeta",!0);u(h,m,xe,"η","\\eta",!0);u(h,m,xe,"θ","\\theta",!0);u(h,m,xe,"ι","\\iota",!0);u(h,m,xe,"κ","\\kappa",!0);u(h,m,xe,"λ","\\lambda",!0);u(h,m,xe,"μ","\\mu",!0);u(h,m,xe,"ν","\\nu",!0);u(h,m,xe,"ξ","\\xi",!0);u(h,m,xe,"ο","\\omicron",!0);u(h,m,xe,"π","\\pi",!0);u(h,m,xe,"ρ","\\rho",!0);u(h,m,xe,"σ","\\sigma",!0);u(h,m,xe,"τ","\\tau",!0);u(h,m,xe,"υ","\\upsilon",!0);u(h,m,xe,"ϕ","\\phi",!0);u(h,m,xe,"χ","\\chi",!0);u(h,m,xe,"ψ","\\psi",!0);u(h,m,xe,"ω","\\omega",!0);u(h,m,xe,"ε","\\varepsilon",!0);u(h,m,xe,"ϑ","\\vartheta",!0);u(h,m,xe,"ϖ","\\varpi",!0);u(h,m,xe,"ϱ","\\varrho",!0);u(h,m,xe,"ς","\\varsigma",!0);u(h,m,xe,"φ","\\varphi",!0);u(h,m,ce,"∗","*",!0);u(h,m,ce,"+","+");u(h,m,ce,"−","-",!0);u(h,m,ce,"⋅","\\cdot",!0);u(h,m,ce,"∘","\\circ",!0);u(h,m,ce,"÷","\\div",!0);u(h,m,ce,"±","\\pm",!0);u(h,m,ce,"×","\\times",!0);u(h,m,ce,"∩","\\cap",!0);u(h,m,ce,"∪","\\cup",!0);u(h,m,ce,"∖","\\setminus",!0);u(h,m,ce,"∧","\\land");u(h,m,ce,"∨","\\lor");u(h,m,ce,"∧","\\wedge",!0);u(h,m,ce,"∨","\\vee",!0);u(h,m,R,"√","\\surd");u(h,m,jt,"⟨","\\langle",!0);u(h,m,jt,"∣","\\lvert");u(h,m,jt,"∥","\\lVert");u(h,m,Dt,"?","?");u(h,m,Dt,"!","!");u(h,m,Dt,"⟩","\\rangle",!0);u(h,m,Dt,"∣","\\rvert");u(h,m,Dt,"∥","\\rVert");u(h,m,C,"=","=");u(h,m,C,":",":");u(h,m,C,"≈","\\approx",!0);u(h,m,C,"≅","\\cong",!0);u(h,m,C,"≥","\\ge");u(h,m,C,"≥","\\geq",!0);u(h,m,C,"←","\\gets");u(h,m,C,">","\\gt",!0);u(h,m,C,"∈","\\in",!0);u(h,m,C,"","\\@not");u(h,m,C,"⊂","\\subset",!0);u(h,m,C,"⊃","\\supset",!0);u(h,m,C,"⊆","\\subseteq",!0);u(h,m,C,"⊇","\\supseteq",!0);u(h,A,C,"⊈","\\nsubseteq",!0);u(h,A,C,"⊉","\\nsupseteq",!0);u(h,m,C,"⊨","\\models");u(h,m,C,"←","\\leftarrow",!0);u(h,m,C,"≤","\\le");u(h,m,C,"≤","\\leq",!0);u(h,m,C,"<","\\lt",!0);u(h,m,C,"→","\\rightarrow",!0);u(h,m,C,"→","\\to");u(h,A,C,"≱","\\ngeq",!0);u(h,A,C,"≰","\\nleq",!0);u(h,m,Fr," ","\\ ");u(h,m,Fr," ","\\space");u(h,m,Fr," ","\\nobreakspace");u(K,m,Fr," ","\\ ");u(K,m,Fr," "," ");u(K,m,Fr," ","\\space");u(K,m,Fr," ","\\nobreakspace");u(h,m,Fr,null,"\\nobreak");u(h,m,Fr,null,"\\allowbreak");u(h,m,Zs,",",",");u(h,m,Zs,";",";");u(h,A,ce,"⊼","\\barwedge",!0);u(h,A,ce,"⊻","\\veebar",!0);u(h,m,ce,"⊙","\\odot",!0);u(h,m,ce,"⊕","\\oplus",!0);u(h,m,ce,"⊗","\\otimes",!0);u(h,m,R,"∂","\\partial",!0);u(h,m,ce,"⊘","\\oslash",!0);u(h,A,ce,"⊚","\\circledcirc",!0);u(h,A,ce,"⊡","\\boxdot",!0);u(h,m,ce,"△","\\bigtriangleup");u(h,m,ce,"▽","\\bigtriangledown");u(h,m,ce,"†","\\dagger");u(h,m,ce,"⋄","\\diamond");u(h,m,ce,"⋆","\\star");u(h,m,ce,"◃","\\triangleleft");u(h,m,ce,"▹","\\triangleright");u(h,m,jt,"{","\\{");u(K,m,R,"{","\\{");u(K,m,R,"{","\\textbraceleft");u(h,m,Dt,"}","\\}");u(K,m,R,"}","\\}");u(K,m,R,"}","\\textbraceright");u(h,m,jt,"{","\\lbrace");u(h,m,Dt,"}","\\rbrace");u(h,m,jt,"[","\\lbrack",!0);u(K,m,R,"[","\\lbrack",!0);u(h,m,Dt,"]","\\rbrack",!0);u(K,m,R,"]","\\rbrack",!0);u(h,m,jt,"(","\\lparen",!0);u(h,m,Dt,")","\\rparen",!0);u(K,m,R,"<","\\textless",!0);u(K,m,R,">","\\textgreater",!0);u(h,m,jt,"⌊","\\lfloor",!0);u(h,m,Dt,"⌋","\\rfloor",!0);u(h,m,jt,"⌈","\\lceil",!0);u(h,m,Dt,"⌉","\\rceil",!0);u(h,m,R,"\\","\\backslash");u(h,m,R,"∣","|");u(h,m,R,"∣","\\vert");u(K,m,R,"|","\\textbar",!0);u(h,m,R,"∥","\\|");u(h,m,R,"∥","\\Vert");u(K,m,R,"∥","\\textbardbl");u(K,m,R,"~","\\textasciitilde");u(K,m,R,"\\","\\textbackslash");u(K,m,R,"^","\\textasciicircum");u(h,m,C,"↑","\\uparrow",!0);u(h,m,C,"⇑","\\Uparrow",!0);u(h,m,C,"↓","\\downarrow",!0);u(h,m,C,"⇓","\\Downarrow",!0);u(h,m,C,"↕","\\updownarrow",!0);u(h,m,C,"⇕","\\Updownarrow",!0);u(h,m,ht,"∐","\\coprod");u(h,m,ht,"⋁","\\bigvee");u(h,m,ht,"⋀","\\bigwedge");u(h,m,ht,"⨄","\\biguplus");u(h,m,ht,"⋂","\\bigcap");u(h,m,ht,"⋃","\\bigcup");u(h,m,ht,"∫","\\int");u(h,m,ht,"∫","\\intop");u(h,m,ht,"∬","\\iint");u(h,m,ht,"∭","\\iiint");u(h,m,ht,"∏","\\prod");u(h,m,ht,"∑","\\sum");u(h,m,ht,"⨂","\\bigotimes");u(h,m,ht,"⨁","\\bigoplus");u(h,m,ht,"⨀","\\bigodot");u(h,m,ht,"∮","\\oint");u(h,m,ht,"∯","\\oiint");u(h,m,ht,"∰","\\oiiint");u(h,m,ht,"⨆","\\bigsqcup");u(h,m,ht,"∫","\\smallint");u(K,m,Hn,"…","\\textellipsis");u(h,m,Hn,"…","\\mathellipsis");u(K,m,Hn,"…","\\ldots",!0);u(h,m,Hn,"…","\\ldots",!0);u(h,m,Hn,"⋯","\\@cdots",!0);u(h,m,Hn,"⋱","\\ddots",!0);u(h,m,R,"⋮","\\varvdots");u(K,m,R,"⋮","\\varvdots");u(h,m,rt,"ˊ","\\acute");u(h,m,rt,"ˋ","\\grave");u(h,m,rt,"¨","\\ddot");u(h,m,rt,"~","\\tilde");u(h,m,rt,"ˉ","\\bar");u(h,m,rt,"˘","\\breve");u(h,m,rt,"ˇ","\\check");u(h,m,rt,"^","\\hat");u(h,m,rt,"⃗","\\vec");u(h,m,rt,"˙","\\dot");u(h,m,rt,"˚","\\mathring");u(h,m,xe,"","\\@imath");u(h,m,xe,"","\\@jmath");u(h,m,R,"ı","ı");u(h,m,R,"ȷ","ȷ");u(K,m,R,"ı","\\i",!0);u(K,m,R,"ȷ","\\j",!0);u(K,m,R,"ß","\\ss",!0);u(K,m,R,"æ","\\ae",!0);u(K,m,R,"œ","\\oe",!0);u(K,m,R,"ø","\\o",!0);u(K,m,R,"Æ","\\AE",!0);u(K,m,R,"Œ","\\OE",!0);u(K,m,R,"Ø","\\O",!0);u(K,m,rt,"ˊ","\\'");u(K,m,rt,"ˋ","\\`");u(K,m,rt,"ˆ","\\^");u(K,m,rt,"˜","\\~");u(K,m,rt,"ˉ","\\=");u(K,m,rt,"˘","\\u");u(K,m,rt,"˙","\\.");u(K,m,rt,"¸","\\c");u(K,m,rt,"˚","\\r");u(K,m,rt,"ˇ","\\v");u(K,m,rt,"¨",'\\"');u(K,m,rt,"˝","\\H");u(K,m,rt,"◯","\\textcircled");var j1={"--":!0,"---":!0,"``":!0,"''":!0};u(K,m,R,"–","--",!0);u(K,m,R,"–","\\textendash");u(K,m,R,"—","---",!0);u(K,m,R,"—","\\textemdash");u(K,m,R,"‘","`",!0);u(K,m,R,"‘","\\textquoteleft");u(K,m,R,"’","'",!0);u(K,m,R,"’","\\textquoteright");u(K,m,R,"“","``",!0);u(K,m,R,"“","\\textquotedblleft");u(K,m,R,"”","''",!0);u(K,m,R,"”","\\textquotedblright");u(h,m,R,"°","\\degree",!0);u(K,m,R,"°","\\degree");u(K,m,R,"°","\\textdegree",!0);u(h,m,R,"£","\\pounds");u(h,m,R,"£","\\mathsterling",!0);u(K,m,R,"£","\\pounds");u(K,m,R,"£","\\textsterling",!0);u(h,A,R,"✠","\\maltese");u(K,A,R,"✠","\\maltese");var Ql='0123456789/@."';for(var Si=0;Si<Ql.length;Si++){var ec=Ql.charAt(Si);u(h,m,R,ec,ec)}var tc='0123456789!@*()-=+";:?/.,';for(var Ti=0;Ti<tc.length;Ti++){var rc=tc.charAt(Ti);u(K,m,R,rc,rc)}var Cs="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";for(var Ai=0;Ai<Cs.length;Ai++){var B0=Cs.charAt(Ai);u(h,m,xe,B0,B0),u(K,m,R,B0,B0)}u(h,A,R,"C","ℂ");u(K,A,R,"C","ℂ");u(h,A,R,"H","ℍ");u(K,A,R,"H","ℍ");u(h,A,R,"N","ℕ");u(K,A,R,"N","ℕ");u(h,A,R,"P","ℙ");u(K,A,R,"P","ℙ");u(h,A,R,"Q","ℚ");u(K,A,R,"Q","ℚ");u(h,A,R,"R","ℝ");u(K,A,R,"R","ℝ");u(h,A,R,"Z","ℤ");u(K,A,R,"Z","ℤ");u(h,m,xe,"h","ℎ");u(K,m,xe,"h","ℎ");var Te="";for(var Tt=0;Tt<Cs.length;Tt++){var at=Cs.charAt(Tt);Te=String.fromCharCode(55349,56320+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56372+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56424+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56580+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56684+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56736+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56788+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56840+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56944+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Tt<26&&(Te=String.fromCharCode(55349,56632+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te),Te=String.fromCharCode(55349,56476+Tt),u(h,m,xe,at,Te),u(K,m,R,at,Te))}Te=String.fromCharCode(55349,56668);u(h,m,xe,"k",Te);u(K,m,R,"k",Te);for(var on=0;on<10;on++){var Hr=on.toString();Te=String.fromCharCode(55349,57294+on),u(h,m,xe,Hr,Te),u(K,m,R,Hr,Te),Te=String.fromCharCode(55349,57314+on),u(h,m,xe,Hr,Te),u(K,m,R,Hr,Te),Te=String.fromCharCode(55349,57324+on),u(h,m,xe,Hr,Te),u(K,m,R,Hr,Te),Te=String.fromCharCode(55349,57334+on),u(h,m,xe,Hr,Te),u(K,m,R,Hr,Te)}var fa="ÐÞþ";for(var Ei=0;Ei<fa.length;Ei++){var P0=fa.charAt(Ei);u(h,m,xe,P0,P0),u(K,m,R,P0,P0)}var H0=[["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"]],nc=[["mathbf","textbf","Main-Bold"],["","",""],["mathsf","textsf","SansSerif-Regular"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathtt","texttt","Typewriter-Regular"]],$6=function(e,r){var n=e.charCodeAt(0),s=e.charCodeAt(1),i=(n-55296)*1024+(s-56320)+65536,a=r==="math"?0:1;if(119808<=i&&i<120484){var o=Math.floor((i-119808)/26);return[H0[o][2],H0[o][a]]}else if(120782<=i&&i<=120831){var l=Math.floor((i-120782)/10);return[nc[l][2],nc[l][a]]}else{if(i===120485||i===120486)return[H0[0][2],H0[0][a]];if(120486<i&&i<120782)return["",""];throw new te("Unsupported character: "+e)}},Qs=function(e,r,n){return Qe[n][e]&&Qe[n][e].replace&&(e=Qe[n][e].replace),{value:e,metrics:mo(e,r,n)}},Qt=function(e,r,n,s,i){var a=Qs(e,r,n),o=a.metrics;e=a.value;var l;if(o){var c=o.italic;(n==="text"||s&&s.font==="mathit")&&(c=0),l=new Yt(e,o.height,o.depth,c,o.skew,o.width,i)}else typeof console<"u"&&console.warn("No character metrics "+("for '"+e+"' in style '"+r+"' and mode '"+n+"'")),l=new Yt(e,0,0,0,0,0,i);if(s){l.maxFontSize=s.sizeMultiplier,s.style.isTight()&&l.classes.push("mtight");var d=s.getColor();d&&(l.style.color=d)}return l},B6=function(e,r,n,s){return s===void 0&&(s=[]),n.font==="boldsymbol"&&Qs(e,"Main-Bold",r).metrics?Qt(e,"Main-Bold",r,n,s.concat(["mathbf"])):e==="\\"||Qe[r][e].font==="main"?Qt(e,"Main-Regular",r,n,s):Qt(e,"AMS-Regular",r,n,s.concat(["amsrm"]))},P6=function(e,r,n,s,i){return i!=="textord"&&Qs(e,"Math-BoldItalic",r).metrics?{fontName:"Math-BoldItalic",fontClass:"boldsymbol"}:{fontName:"Main-Bold",fontClass:"mathbf"}},H6=function(e,r,n){var s=e.mode,i=e.text,a=["mord"],o=s==="math"||s==="text"&&r.font,l=o?r.font:r.fontFamily,c="",d="";if(i.charCodeAt(0)===55349&&([c,d]=$6(i,s)),c.length>0)return Qt(i,c,s,r,a.concat(d));if(l){var f,p;if(l==="boldsymbol"){var b=P6(i,s,r,a,n);f=b.fontName,p=[b.fontClass]}else o?(f=W1[l].fontName,p=[l]):(f=q0(l,r.fontWeight,r.fontShape),p=[l,r.fontWeight,r.fontShape]);if(Qs(i,f,s).metrics)return Qt(i,f,s,r,a.concat(p));if(j1.hasOwnProperty(i)&&f.slice(0,10)==="Typewriter"){for(var v=[],x=0;x<i.length;x++)v.push(Qt(i[x],f,s,r,a.concat(p)));return V1(v)}}if(n==="mathord")return Qt(i,"Math-Italic",s,r,a.concat(["mathnormal"]));if(n==="textord"){var y=Qe[s][i]&&Qe[s][i].font;if(y==="ams"){var M=q0("amsrm",r.fontWeight,r.fontShape);return Qt(i,M,s,r,a.concat("amsrm",r.fontWeight,r.fontShape))}else if(y==="main"||!y){var k=q0("textrm",r.fontWeight,r.fontShape);return Qt(i,k,s,r,a.concat(r.fontWeight,r.fontShape))}else{var T=q0(y,r.fontWeight,r.fontShape);return Qt(i,T,s,r,a.concat(T,r.fontWeight,r.fontShape))}}else throw new Error("unexpected type: "+n+" in makeOrd")},q6=(t,e)=>{if(Yr(t.classes)!==Yr(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 s in e.style)if(e.style.hasOwnProperty(s)&&t.style[s]!==e.style[s])return!1;return!0},j6=t=>{for(var e=0;e<t.length-1;e++){var r=t[e],n=t[e+1];r instanceof Yt&&n instanceof Yt&&q6(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},vo=function(e){for(var r=0,n=0,s=0,i=0;i<e.children.length;i++){var a=e.children[i];a.height>r&&(r=a.height),a.depth>n&&(n=a.depth),a.maxFontSize>s&&(s=a.maxFontSize)}e.height=r,e.depth=n,e.maxFontSize=s},_t=function(e,r,n,s){var i=new A0(e,r,n,s);return vo(i),i},U1=(t,e,r,n)=>new A0(t,e,r,n),U6=function(e,r,n){var s=_t([e],[],r);return s.height=Math.max(n||r.fontMetrics().defaultRuleThickness,r.minRuleThickness),s.style.borderBottomWidth=ae(s.height),s.maxFontSize=1,s},V6=function(e,r,n,s){var i=new go(e,r,n,s);return vo(i),i},V1=function(e){var r=new T0(e);return vo(r),r},W6=function(e,r){return e instanceof T0?_t([],[e],r):e},G6=function(e){if(e.positionType==="individualShift"){for(var r=e.children,n=[r[0]],s=-r[0].shift-r[0].elem.depth,i=s,a=1;a<r.length;a++){var o=-r[a].shift-i-r[a].elem.depth,l=o-(r[a-1].elem.height+r[a-1].elem.depth);i=i+o,n.push({type:"kern",size:l}),n.push(r[a])}return{children:n,depth:s}}var c;if(e.positionType==="top"){for(var d=e.positionData,f=0;f<e.children.length;f++){var p=e.children[f];d-=p.type==="kern"?p.size:p.elem.height+p.elem.depth}c=d}else if(e.positionType==="bottom")c=-e.positionData;else{var b=e.children[0];if(b.type!=="elem")throw new Error('First child must have type "elem".');if(e.positionType==="shift")c=-b.elem.depth-e.positionData;else if(e.positionType==="firstBaseline")c=-b.elem.depth;else throw new Error("Invalid positionType "+e.positionType+".")}return{children:e.children,depth:c}},K6=function(e,r){for(var{children:n,depth:s}=G6(e),i=0,a=0;a<n.length;a++){var o=n[a];if(o.type==="elem"){var l=o.elem;i=Math.max(i,l.maxFontSize,l.height)}}i+=2;var c=_t(["pstrut"],[]);c.style.height=ae(i);for(var d=[],f=s,p=s,b=s,v=0;v<n.length;v++){var x=n[v];if(x.type==="kern")b+=x.size;else{var y=x.elem,M=x.wrapperClasses||[],k=x.wrapperStyle||{},T=_t(M,[c,y],void 0,k);T.style.top=ae(-i-b-y.depth),x.marginLeft&&(T.style.marginLeft=x.marginLeft),x.marginRight&&(T.style.marginRight=x.marginRight),d.push(T),b+=y.height+y.depth}f=Math.min(f,b),p=Math.max(p,b)}var N=_t(["vlist"],d);N.style.height=ae(p);var I;if(f<0){var O=_t([],[]),z=_t(["vlist"],[O]);z.style.height=ae(-f);var W=_t(["vlist-s"],[new Yt("")]);I=[_t(["vlist-r"],[N,W]),_t(["vlist-r"],[z])]}else I=[_t(["vlist-r"],[N])];var U=_t(["vlist-t"],I);return I.length===2&&U.classes.push("vlist-t2"),U.height=p,U.depth=-f,U},Y6=(t,e)=>{var r=_t(["mspace"],[],e),n=st(t,e);return r.style.marginRight=ae(n),r},q0=function(e,r,n){var s="";switch(e){case"amsrm":s="AMS";break;case"textrm":s="Main";break;case"textsf":s="SansSerif";break;case"texttt":s="Typewriter";break;default:s=e}var i;return r==="textbf"&&n==="textit"?i="BoldItalic":r==="textbf"?i="Bold":r==="textit"?i="Italic":i="Regular",s+"-"+i},W1={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"}},G1={vec:["vec",.471,.714],oiintSize1:["oiintSize1",.957,.499],oiintSize2:["oiintSize2",1.472,.659],oiiintSize1:["oiiintSize1",1.304,.499],oiiintSize2:["oiiintSize2",1.98,.659]},X6=function(e,r){var[n,s,i]=G1[e],a=new Xr(n),o=new _r([a],{width:ae(s),height:ae(i),style:"width:"+ae(s),viewBox:"0 0 "+1e3*s+" "+1e3*i,preserveAspectRatio:"xMinYMin"}),l=U1(["overlay"],[o],r);return l.height=i,l.style.height=ae(i),l.style.width=ae(s),l},L={fontMap:W1,makeSymbol:Qt,mathsym:B6,makeSpan:_t,makeSvgSpan:U1,makeLineSpan:U6,makeAnchor:V6,makeFragment:V1,wrapFragment:W6,makeVList:K6,makeOrd:H6,makeGlue:Y6,staticSvg:X6,svgData:G1,tryCombineChars:j6},nt={number:3,unit:"mu"},ln={number:4,unit:"mu"},xr={number:5,unit:"mu"},J6={mord:{mop:nt,mbin:ln,mrel:xr,minner:nt},mop:{mord:nt,mop:nt,mrel:xr,minner:nt},mbin:{mord:ln,mop:ln,mopen:ln,minner:ln},mrel:{mord:xr,mop:xr,mopen:xr,minner:xr},mopen:{},mclose:{mop:nt,mbin:ln,mrel:xr,minner:nt},mpunct:{mord:nt,mop:nt,mrel:xr,mopen:nt,mclose:nt,mpunct:nt,minner:nt},minner:{mord:nt,mop:nt,mbin:ln,mrel:xr,mopen:nt,mpunct:nt,minner:nt}},Z6={mord:{mop:nt},mop:{mord:nt,mop:nt},mbin:{},mrel:{},mopen:{},mclose:{mop:nt},mpunct:{},minner:{mop:nt}},K1={},Ms={},Ns={};function oe(t){for(var{type:e,names:r,props:n,handler:s,htmlBuilder:i,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:s},l=0;l<r.length;++l)K1[r[l]]=o;e&&(i&&(Ms[e]=i),a&&(Ns[e]=a))}function bn(t){var{type:e,htmlBuilder:r,mathmlBuilder:n}=t;oe({type:e,names:[],props:{numArgs:0},handler(){throw new Error("Should never be called.")},htmlBuilder:r,mathmlBuilder:n})}var Ds=function(e){return e.type==="ordgroup"&&e.body.length===1?e.body[0]:e},ct=function(e){return e.type==="ordgroup"?e.body:[e]},Or=L.makeSpan,Q6=["leftmost","mbin","mopen","mrel","mop","mpunct"],e5=["rightmost","mrel","mclose","mpunct"],t5={display:ke.DISPLAY,text:ke.TEXT,script:ke.SCRIPT,scriptscript:ke.SCRIPTSCRIPT},r5={mord:"mord",mop:"mop",mbin:"mbin",mrel:"mrel",mopen:"mopen",mclose:"mclose",mpunct:"mpunct",minner:"minner"},pt=function(e,r,n,s){s===void 0&&(s=[null,null]);for(var i=[],a=0;a<e.length;a++){var o=$e(e[a],r);if(o instanceof T0){var l=o.children;i.push(...l)}else i.push(o)}if(L.tryCombineChars(i),!n)return i;var c=r;if(e.length===1){var d=e[0];d.type==="sizing"?c=r.havingSize(d.size):d.type==="styling"&&(c=r.havingStyle(t5[d.style]))}var f=Or([s[0]||"leftmost"],[],r),p=Or([s[1]||"rightmost"],[],r),b=n==="root";return sc(i,(v,x)=>{var y=x.classes[0],M=v.classes[0];y==="mbin"&&we.contains(e5,M)?x.classes[0]="mord":M==="mbin"&&we.contains(Q6,y)&&(v.classes[0]="mord")},{node:f},p,b),sc(i,(v,x)=>{var y=pa(x),M=pa(v),k=y&&M?v.hasClass("mtight")?Z6[y][M]:J6[y][M]:null;if(k)return L.makeGlue(k,c)},{node:f},p,b),i},sc=function t(e,r,n,s,i){s&&e.push(s);for(var a=0;a<e.length;a++){var o=e[a],l=Y1(o);if(l){t(l.children,r,n,null,i);continue}var c=!o.hasClass("mspace");if(c){var d=r(o,n.node);d&&(n.insertAfter?n.insertAfter(d):(e.unshift(d),a++))}c?n.node=o:i&&o.hasClass("newline")&&(n.node=Or(["leftmost"])),n.insertAfter=(f=>p=>{e.splice(f+1,0,p),a++})(a)}s&&e.pop()},Y1=function(e){return e instanceof T0||e instanceof go||e instanceof A0&&e.hasClass("enclosing")?e:null},n5=function t(e,r){var n=Y1(e);if(n){var s=n.children;if(s.length){if(r==="right")return t(s[s.length-1],"right");if(r==="left")return t(s[0],"left")}}return e},pa=function(e,r){return e?(r&&(e=n5(e,r)),r5[e.classes[0]]||null):null},g0=function(e,r){var n=["nulldelimiter"].concat(e.baseSizingClasses());return Or(r.concat(n))},$e=function(e,r,n){if(!e)return Or();if(Ms[e.type]){var s=Ms[e.type](e,r);if(n&&r.size!==n.size){s=Or(r.sizingClasses(n),[s],r);var i=r.sizeMultiplier/n.sizeMultiplier;s.height*=i,s.depth*=i}return s}else throw new te("Got group of unknown type: '"+e.type+"'")};function j0(t,e){var r=Or(["base"],t,e),n=Or(["strut"]);return n.style.height=ae(r.height+r.depth),r.depth&&(n.style.verticalAlign=ae(-r.depth)),r.children.unshift(n),r}function ma(t,e){var r=null;t.length===1&&t[0].type==="tag"&&(r=t[0].tag,t=t[0].body);var n=pt(t,e,"root"),s;n.length===2&&n[1].hasClass("tag")&&(s=n.pop());for(var i=[],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||(i.push(j0(a,e)),a=[])}else n[o].hasClass("newline")&&(a.pop(),a.length>0&&(i.push(j0(a,e)),a=[]),i.push(n[o]));a.length>0&&i.push(j0(a,e));var c;r?(c=j0(pt(r,e,!0)),c.classes=["tag"],i.push(c)):s&&i.push(s);var d=Or(["katex-html"],i);if(d.setAttribute("aria-hidden","true"),c){var f=c.children[0];f.style.height=ae(d.height+d.depth),d.depth&&(f.style.verticalAlign=ae(-d.depth))}return d}function X1(t){return new T0(t)}class Bt{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=Yr(this.classes));for(var n=0;n<this.children.length;n++)if(this.children[n]instanceof pr&&this.children[n+1]instanceof pr){for(var s=this.children[n].toText()+this.children[++n].toText();this.children[n+1]instanceof pr;)s+=this.children[++n].toText();e.appendChild(new pr(s).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+=we.escape(this.attributes[r]),e+='"');this.classes.length>0&&(e+=' class ="'+we.escape(Yr(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 pr{constructor(e){this.text=void 0,this.text=e}toNode(){return document.createTextNode(this.text)}toMarkup(){return we.escape(this.toText())}toText(){return this.text}}class s5{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",ae(this.width)),e}toMarkup(){return this.character?"<mtext>"+this.character+"</mtext>":'<mspace width="'+ae(this.width)+'"/>'}toText(){return this.character?this.character:" "}}var ee={MathNode:Bt,TextNode:pr,SpaceNode:s5,newDocumentFragment:X1},Xt=function(e,r,n){return Qe[r][e]&&Qe[r][e].replace&&e.charCodeAt(0)!==55349&&!(j1.hasOwnProperty(e)&&n&&(n.fontFamily&&n.fontFamily.slice(4,6)==="tt"||n.font&&n.font.slice(4,6)==="tt"))&&(e=Qe[r][e].replace),new ee.TextNode(e)},bo=function(e){return e.length===1?e[0]:new ee.MathNode("mrow",e)},yo=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 s=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 i=e.text;if(we.contains(["\\imath","\\jmath"],i))return null;Qe[s][i]&&Qe[s][i].replace&&(i=Qe[s][i].replace);var a=L.fontMap[n].fontName;return mo(i,a,s)?L.fontMap[n].variant:null};function Ci(t){if(!t)return!1;if(t.type==="mi"&&t.children.length===1){var e=t.children[0];return e instanceof pr&&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 pr&&r.text===","}else return!1}var Lt=function(e,r,n){if(e.length===1){var s=Xe(e[0],r);return n&&s instanceof Bt&&s.type==="mo"&&(s.setAttribute("lspace","0em"),s.setAttribute("rspace","0em")),[s]}for(var i=[],a,o=0;o<e.length;o++){var l=Xe(e[o],r);if(l instanceof Bt&&a instanceof Bt){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(Ci(l)&&a.type==="mn"){a.children.push(...l.children);continue}else if(l.type==="mn"&&Ci(a))l.children=[...a.children,...l.children],i.pop();else if((l.type==="msup"||l.type==="msub")&&l.children.length>=1&&(a.type==="mn"||Ci(a))){var c=l.children[0];c instanceof Bt&&c.type==="mn"&&(c.children=[...a.children,...c.children],i.pop())}else if(a.type==="mi"&&a.children.length===1){var d=a.children[0];if(d instanceof pr&&d.text==="̸"&&(l.type==="mo"||l.type==="mi"||l.type==="mn")){var f=l.children[0];f instanceof pr&&f.text.length>0&&(f.text=f.text.slice(0,1)+"̸"+f.text.slice(1),i.pop())}}}i.push(l),a=l}return i},Jr=function(e,r,n){return bo(Lt(e,r,n))},Xe=function(e,r){if(!e)return new ee.MathNode("mrow");if(Ns[e.type]){var n=Ns[e.type](e,r);return n}else throw new te("Got group of unknown type: '"+e.type+"'")};function ic(t,e,r,n,s){var i=Lt(t,r),a;i.length===1&&i[0]instanceof Bt&&we.contains(["mrow","mtable"],i[0].type)?a=i[0]:a=new ee.MathNode("mrow",i);var o=new ee.MathNode("annotation",[new ee.TextNode(e)]);o.setAttribute("encoding","application/x-tex");var l=new ee.MathNode("semantics",[a,o]),c=new ee.MathNode("math",[l]);c.setAttribute("xmlns","http://www.w3.org/1998/Math/MathML"),n&&c.setAttribute("display","block");var d=s?"katex":"katex-mathml";return L.makeSpan([d],[c])}var J1=function(e){return new Tr({style:e.displayMode?ke.DISPLAY:ke.TEXT,maxSize:e.maxSize,minRuleThickness:e.minRuleThickness})},Z1=function(e,r){if(r.displayMode){var n=["katex-display"];r.leqno&&n.push("leqno"),r.fleqn&&n.push("fleqn"),e=L.makeSpan(n,[e])}return e},i5=function(e,r,n){var s=J1(n),i;if(n.output==="mathml")return ic(e,r,s,n.displayMode,!0);if(n.output==="html"){var a=ma(e,s);i=L.makeSpan(["katex"],[a])}else{var o=ic(e,r,s,n.displayMode,!1),l=ma(e,s);i=L.makeSpan(["katex"],[o,l])}return Z1(i,n)},a5=function(e,r,n){var s=J1(n),i=ma(e,s),a=L.makeSpan(["katex"],[i]);return Z1(a,n)},o5={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":"="},l5=function(e){var r=new ee.MathNode("mo",[new ee.TextNode(o5[e.replace(/^\\/,"")])]);return r.setAttribute("stretchy","true"),r},c5={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]},u5=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(we.contains(["widehat","widecheck","widetilde","utilde"],l)){var c=e,d=u5(c.base),f,p,b;if(d>5)l==="widehat"||l==="widecheck"?(f=420,o=2364,b=.42,p=l+"4"):(f=312,o=2340,b=.34,p="tilde4");else{var v=[1,1,2,2,3,3][d];l==="widehat"||l==="widecheck"?(o=[0,1062,2364,2364,2364][v],f=[0,239,300,360,420][v],b=[0,.24,.3,.3,.36,.42][v],p=l+v):(o=[0,600,1033,2339,2340][v],f=[0,260,286,306,312][v],b=[0,.26,.286,.3,.306,.34][v],p="tilde"+v)}var x=new Xr(p),y=new _r([x],{width:"100%",height:ae(b),viewBox:"0 0 "+o+" "+f,preserveAspectRatio:"none"});return{span:L.makeSvgSpan([],[y],r),minWidth:0,height:b}}else{var M=[],k=c5[l],[T,N,I]=k,O=I/1e3,z=T.length,W,U;if(z===1){var he=k[3];W=["hide-tail"],U=[he]}else if(z===2)W=["halfarrow-left","halfarrow-right"],U=["xMinYMin","xMaxYMin"];else if(z===3)W=["brace-left","brace-center","brace-right"],U=["xMinYMin","xMidYMin","xMaxYMin"];else throw new Error(`Correct katexImagesData or update code here to support
|
||
`+z+" children.");for(var ge=0;ge<z;ge++){var Ae=new Xr(T[ge]),et=new _r([Ae],{width:"400em",height:ae(O),viewBox:"0 0 "+o+" "+I,preserveAspectRatio:U[ge]+" slice"}),Je=L.makeSvgSpan([W[ge]],[et],r);if(z===1)return{span:Je,minWidth:N,height:O};Je.style.height=ae(O),M.push(Je)}return{span:L.makeSpan(["stretchy"],M,r),minWidth:N,height:O}}}var{span:s,minWidth:i,height:a}=n();return s.height=a,s.style.height=ae(a),i>0&&(s.style.minWidth=ae(i)),s},h5=function(e,r,n,s,i){var a,o=e.height+e.depth+n+s;if(/fbox|color|angl/.test(r)){if(a=L.makeSpan(["stretchy",r],[],i),r==="fbox"){var l=i.color&&i.getColor();l&&(a.style.borderColor=l)}}else{var c=[];/^[bx]cancel$/.test(r)&&c.push(new ha({x1:"0",y1:"0",x2:"100%",y2:"100%","stroke-width":"0.046em"})),/^x?cancel$/.test(r)&&c.push(new ha({x1:"0",y1:"100%",x2:"100%",y2:"0","stroke-width":"0.046em"}));var d=new _r(c,{width:"100%",height:ae(o)});a=L.makeSvgSpan([],[d],i)}return a.height=o,a.style.height=ae(o),a},Lr={encloseSpan:h5,mathMLnode:l5,svgSpan:d5};function Re(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 wo(t){var e=ei(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 ei(t){return t&&(t.type==="atom"||F6.hasOwnProperty(t.type))?t:null}var xo=(t,e)=>{var r,n,s;t&&t.type==="supsub"?(n=Re(t.base,"accent"),r=n.base,t.base=r,s=L6($e(t,e)),t.base=n):(n=Re(t,"accent"),r=n.base);var i=$e(r,e.havingCrampedStyle()),a=n.isShifty&&we.isCharacterBox(r),o=0;if(a){var l=we.getBaseElem(r),c=$e(l,e.havingCrampedStyle());o=Zl(c).skew}var d=n.label==="\\c",f=d?i.height+i.depth:Math.min(i.height,e.fontMetrics().xHeight),p;if(n.isStretchy)p=Lr.svgSpan(n,e),p=L.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i},{type:"elem",elem:p,wrapperClasses:["svg-align"],wrapperStyle:o>0?{width:"calc(100% - "+ae(2*o)+")",marginLeft:ae(2*o)}:void 0}]},e);else{var b,v;n.label==="\\vec"?(b=L.staticSvg("vec",e),v=L.svgData.vec[1]):(b=L.makeOrd({mode:n.mode,text:n.label},e,"textord"),b=Zl(b),b.italic=0,v=b.width,d&&(f+=b.depth)),p=L.makeSpan(["accent-body"],[b]);var x=n.label==="\\textcircled";x&&(p.classes.push("accent-full"),f=i.height);var y=o;x||(y-=v/2),p.style.left=ae(y),n.label==="\\textcircled"&&(p.style.top=".2em"),p=L.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i},{type:"kern",size:-f},{type:"elem",elem:p}]},e)}var M=L.makeSpan(["mord","accent"],[p],e);return s?(s.children[0]=M,s.height=Math.max(M.height,s.height),s.classes[0]="mord",s):M},Q1=(t,e)=>{var r=t.isStretchy?Lr.mathMLnode(t.label):new ee.MathNode("mo",[Xt(t.label,t.mode)]),n=new ee.MathNode("mover",[Xe(t.base,e),r]);return n.setAttribute("accent","true"),n},f5=new RegExp(["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring"].map(t=>"\\"+t).join("|"));oe({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=Ds(e[0]),n=!f5.test(t.funcName),s=!n||t.funcName==="\\widehat"||t.funcName==="\\widetilde"||t.funcName==="\\widecheck";return{type:"accent",mode:t.parser.mode,label:t.funcName,isStretchy:n,isShifty:s,base:r}},htmlBuilder:xo,mathmlBuilder:Q1});oe({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:xo,mathmlBuilder:Q1});oe({type:"accentUnder",names:["\\underleftarrow","\\underrightarrow","\\underleftrightarrow","\\undergroup","\\underlinesegment","\\utilde"],props:{numArgs:1},handler:(t,e)=>{var{parser:r,funcName:n}=t,s=e[0];return{type:"accentUnder",mode:r.mode,label:n,base:s}},htmlBuilder:(t,e)=>{var r=$e(t.base,e),n=Lr.svgSpan(t,e),s=t.label==="\\utilde"?.12:0,i=L.makeVList({positionType:"top",positionData:r.height,children:[{type:"elem",elem:n,wrapperClasses:["svg-align"]},{type:"kern",size:s},{type:"elem",elem:r}]},e);return L.makeSpan(["mord","accentunder"],[i],e)},mathmlBuilder:(t,e)=>{var r=Lr.mathMLnode(t.label),n=new ee.MathNode("munder",[Xe(t.base,e),r]);return n.setAttribute("accentunder","true"),n}});var U0=t=>{var e=new ee.MathNode("mpadded",t?[t]:[]);return e.setAttribute("width","+0.6em"),e.setAttribute("lspace","0.3em"),e};oe({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:s}=t;return{type:"xArrow",mode:n.mode,label:s,body:e[0],below:r[0]}},htmlBuilder(t,e){var r=e.style,n=e.havingStyle(r.sup()),s=L.wrapFragment($e(t.body,n,e),e),i=t.label.slice(0,2)==="\\x"?"x":"cd";s.classes.push(i+"-arrow-pad");var a;t.below&&(n=e.havingStyle(r.sub()),a=L.wrapFragment($e(t.below,n,e),e),a.classes.push(i+"-arrow-pad"));var o=Lr.svgSpan(t,e),l=-e.fontMetrics().axisHeight+.5*o.height,c=-e.fontMetrics().axisHeight-.5*o.height-.111;(s.depth>.25||t.label==="\\xleftequilibrium")&&(c-=s.depth);var d;if(a){var f=-e.fontMetrics().axisHeight+a.height+.5*o.height+.111;d=L.makeVList({positionType:"individualShift",children:[{type:"elem",elem:s,shift:c},{type:"elem",elem:o,shift:l},{type:"elem",elem:a,shift:f}]},e)}else d=L.makeVList({positionType:"individualShift",children:[{type:"elem",elem:s,shift:c},{type:"elem",elem:o,shift:l}]},e);return d.children[0].children[0].children[1].classes.push("svg-align"),L.makeSpan(["mrel","x-arrow"],[d],e)},mathmlBuilder(t,e){var r=Lr.mathMLnode(t.label);r.setAttribute("minsize",t.label.charAt(0)==="x"?"1.75em":"3.0em");var n;if(t.body){var s=U0(Xe(t.body,e));if(t.below){var i=U0(Xe(t.below,e));n=new ee.MathNode("munderover",[r,i,s])}else n=new ee.MathNode("mover",[r,s])}else if(t.below){var a=U0(Xe(t.below,e));n=new ee.MathNode("munder",[r,a])}else n=U0(),n=new ee.MathNode("mover",[r,n]);return n}});var p5=L.makeSpan;function ed(t,e){var r=pt(t.body,e,!0);return p5([t.mclass],r,e)}function td(t,e){var r,n=Lt(t.body,e);return t.mclass==="minner"?r=new ee.MathNode("mpadded",n):t.mclass==="mord"?t.isCharacterBox?(r=n[0],r.type="mi"):r=new ee.MathNode("mi",n):(t.isCharacterBox?(r=n[0],r.type="mo"):r=new ee.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}oe({type:"mclass",names:["\\mathord","\\mathbin","\\mathrel","\\mathopen","\\mathclose","\\mathpunct","\\mathinner"],props:{numArgs:1,primitive:!0},handler(t,e){var{parser:r,funcName:n}=t,s=e[0];return{type:"mclass",mode:r.mode,mclass:"m"+n.slice(5),body:ct(s),isCharacterBox:we.isCharacterBox(s)}},htmlBuilder:ed,mathmlBuilder:td});var ti=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"};oe({type:"mclass",names:["\\@binrel"],props:{numArgs:2},handler(t,e){var{parser:r}=t;return{type:"mclass",mode:r.mode,mclass:ti(e[0]),body:ct(e[1]),isCharacterBox:we.isCharacterBox(e[1])}}});oe({type:"mclass",names:["\\stackrel","\\overset","\\underset"],props:{numArgs:2},handler(t,e){var{parser:r,funcName:n}=t,s=e[1],i=e[0],a;n!=="\\stackrel"?a=ti(s):a="mrel";var o={type:"op",mode:s.mode,limits:!0,alwaysHandleSupSub:!0,parentIsSupSub:!1,symbol:!1,suppressBaseShift:n!=="\\stackrel",body:ct(s)},l={type:"supsub",mode:i.mode,base:o,sup:n==="\\underset"?null:i,sub:n==="\\underset"?i:null};return{type:"mclass",mode:r.mode,mclass:a,body:[l],isCharacterBox:we.isCharacterBox(l)}},htmlBuilder:ed,mathmlBuilder:td});oe({type:"pmb",names:["\\pmb"],props:{numArgs:1,allowedInText:!0},handler(t,e){var{parser:r}=t;return{type:"pmb",mode:r.mode,mclass:ti(e[0]),body:ct(e[0])}},htmlBuilder(t,e){var r=pt(t.body,e,!0),n=L.makeSpan([t.mclass],r,e);return n.style.textShadow="0.02em 0.01em 0.04px",n},mathmlBuilder(t,e){var r=Lt(t.body,e),n=new ee.MathNode("mstyle",r);return n.setAttribute("style","text-shadow: 0.02em 0.01em 0.04px"),n}});var m5={">":"\\\\cdrightarrow","<":"\\\\cdleftarrow","=":"\\\\cdlongequal",A:"\\uparrow",V:"\\downarrow","|":"\\Vert",".":"no arrow"},ac=()=>({type:"styling",body:[],mode:"math",style:"display"}),oc=t=>t.type==="textord"&&t.text==="@",g5=(t,e)=>(t.type==="mathord"||t.type==="atom")&&t.text===e;function v5(t,e,r){var n=m5[t];switch(n){case"\\\\cdrightarrow":case"\\\\cdleftarrow":return r.callFunction(n,[e[0]],[e[1]]);case"\\uparrow":case"\\downarrow":{var s=r.callFunction("\\\\cdleft",[e[0]],[]),i={type:"atom",text:n,mode:"math",family:"rel"},a=r.callFunction("\\Big",[i],[]),o=r.callFunction("\\\\cdright",[e[1]],[]),l={type:"ordgroup",mode:"math",body:[s,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=[],s=[n],i=0;i<e.length;i++){for(var a=e[i],o=ac(),l=0;l<a.length;l++)if(!oc(a[l]))o.body.push(a[l]);else{n.push(o),l+=1;var c=wo(a[l]).text,d=new Array(2);if(d[0]={type:"ordgroup",mode:"math",body:[]},d[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,b=l+1;b<a.length;b++){if(g5(a[b],c)){p=!1,l=b;break}if(oc(a[b]))throw new te("Missing a "+c+" character to complete a CD arrow.",a[b]);d[f].body.push(a[b])}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 v=v5(c,d,t),x={type:"styling",body:[v],mode:"math",style:"display"};n.push(x),o=ac()}i%2===0?n.push(o):n.shift(),n=[],s.push(n)}t.gullet.endGroup(),t.gullet.endGroup();var y=new Array(s[0].length).fill({type:"align",align:"c",pregap:.25,postgap:.25});return{type:"array",mode:"math",body:s,arraystretch:1,addJot:!0,rowGaps:[null],cols:y,colSeparationType:"CD",hLinesBeforeRow:new Array(s.length+1).fill([])}}oe({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=L.wrapFragment($e(t.label,r,e),e);return n.classes.push("cd-label-"+t.side),n.style.bottom=ae(.8-n.depth),n.height=0,n.depth=0,n},mathmlBuilder(t,e){var r=new ee.MathNode("mrow",[Xe(t.label,e)]);return r=new ee.MathNode("mpadded",[r]),r.setAttribute("width","0"),t.side==="left"&&r.setAttribute("lspace","-1width"),r.setAttribute("voffset","0.7em"),r=new ee.MathNode("mstyle",[r]),r.setAttribute("displaystyle","false"),r.setAttribute("scriptlevel","1"),r}});oe({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=L.wrapFragment($e(t.fragment,e),e);return r.classes.push("cd-vert-arrow"),r},mathmlBuilder(t,e){return new ee.MathNode("mrow",[Xe(t.fragment,e)])}});oe({type:"textord",names:["\\@char"],props:{numArgs:1,allowedInText:!0},handler(t,e){for(var{parser:r}=t,n=Re(e[0],"ordgroup"),s=n.body,i="",a=0;a<s.length;a++){var o=Re(s[a],"textord");i+=o.text}var l=parseInt(i),c;if(isNaN(l))throw new te("\\@char has non-numeric argument "+i);if(l<0||l>=1114111)throw new te("\\@char with invalid code point "+i);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 rd=(t,e)=>{var r=pt(t.body,e.withColor(t.color),!1);return L.makeFragment(r)},nd=(t,e)=>{var r=Lt(t.body,e.withColor(t.color)),n=new ee.MathNode("mstyle",r);return n.setAttribute("mathcolor",t.color),n};oe({type:"color",names:["\\textcolor"],props:{numArgs:2,allowedInText:!0,argTypes:["color","original"]},handler(t,e){var{parser:r}=t,n=Re(e[0],"color-token").color,s=e[1];return{type:"color",mode:r.mode,color:n,body:ct(s)}},htmlBuilder:rd,mathmlBuilder:nd});oe({type:"color",names:["\\color"],props:{numArgs:1,allowedInText:!0,argTypes:["color"]},handler(t,e){var{parser:r,breakOnTokenText:n}=t,s=Re(e[0],"color-token").color;r.gullet.macros.set("\\current@color",s);var i=r.parseExpression(!0,n);return{type:"color",mode:r.mode,color:s,body:i}},htmlBuilder:rd,mathmlBuilder:nd});oe({type:"cr",names:["\\\\"],props:{numArgs:0,numOptionalArgs:0,allowedInText:!0},handler(t,e,r){var{parser:n}=t,s=n.gullet.future().text==="["?n.parseSizeGroup(!0):null,i=!n.settings.displayMode||!n.settings.useStrictBehavior("newLineInDisplayMode","In LaTeX, \\\\ or \\newline does nothing in display mode");return{type:"cr",mode:n.mode,newLine:i,size:s&&Re(s,"size").value}},htmlBuilder(t,e){var r=L.makeSpan(["mspace"],[],e);return t.newLine&&(r.classes.push("newline"),t.size&&(r.style.marginTop=ae(st(t.size,e)))),r},mathmlBuilder(t,e){var r=new ee.MathNode("mspace");return t.newLine&&(r.setAttribute("linebreak","newline"),t.size&&r.setAttribute("height",ae(st(t.size,e)))),r}});var ga={"\\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},y5=t=>{var e=t.gullet.popToken();return e.text==="="&&(e=t.gullet.popToken(),e.text===" "&&(e=t.gullet.popToken())),e},id=(t,e,r,n)=>{var s=t.gullet.macros.get(r.text);s==null&&(r.noexpand=!0,s={tokens:[r],numArgs:0,unexpandable:!t.gullet.isExpandable(r.text)}),t.gullet.macros.set(e,s,n)};oe({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(ga[n.text])return(r==="\\global"||r==="\\\\globallong")&&(n.text=ga[n.text]),Re(e.parseFunction(),"internal");throw new te("Invalid token after macro prefix",n)}});oe({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(),s=n.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(s))throw new te("Expected a control sequence",n);for(var i=0,a,o=[[]];e.gullet.future().text!=="{";)if(n=e.gullet.popToken(),n.text==="#"){if(e.gullet.future().text==="{"){a=e.gullet.future(),o[i].push("{");break}if(n=e.gullet.popToken(),!/^[1-9]$/.test(n.text))throw new te('Invalid argument number "'+n.text+'"');if(parseInt(n.text)!==i+1)throw new te('Argument number "'+n.text+'" out of order');i++,o.push([])}else{if(n.text==="EOF")throw new te("Expected a macro definition");o[i].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(s,{tokens:l,numArgs:i,delimiters:o},r===ga[r]),{type:"internal",mode:e.mode}}});oe({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 s=y5(e);return id(e,n,s,r==="\\\\globallet"),{type:"internal",mode:e.mode}}});oe({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()),s=e.gullet.popToken(),i=e.gullet.popToken();return id(e,n,i,r==="\\\\globalfuture"),e.gullet.pushToken(i),e.gullet.pushToken(s),{type:"internal",mode:e.mode}}});var Zn=function(e,r,n){var s=Qe.math[e]&&Qe.math[e].replace,i=mo(s||e,r,n);if(!i)throw new Error("Unsupported symbol "+e+" and font size "+r+".");return i},ko=function(e,r,n,s){var i=n.havingBaseStyle(r),a=L.makeSpan(s.concat(i.sizingClasses(n)),[e],n),o=i.sizeMultiplier/n.sizeMultiplier;return a.height*=o,a.depth*=o,a.maxFontSize=i.sizeMultiplier,a},ad=function(e,r,n){var s=r.havingBaseStyle(n),i=(1-r.sizeMultiplier/s.sizeMultiplier)*r.fontMetrics().axisHeight;e.classes.push("delimcenter"),e.style.top=ae(i),e.height-=i,e.depth+=i},w5=function(e,r,n,s,i,a){var o=L.makeSymbol(e,"Main-Regular",i,s),l=ko(o,r,s,a);return n&&ad(l,s,r),l},x5=function(e,r,n,s){return L.makeSymbol(e,"Size"+r+"-Regular",n,s)},od=function(e,r,n,s,i,a){var o=x5(e,r,i,s),l=ko(L.makeSpan(["delimsizing","size"+r],[o],s),ke.TEXT,s,a);return n&&ad(l,s,ke.TEXT),l},Mi=function(e,r,n){var s;r==="Size1-Regular"?s="delim-size1":s="delim-size4";var i=L.makeSpan(["delimsizinginner",s],[L.makeSpan([],[L.makeSymbol(e,r,n)])]);return{type:"elem",elem:i}},Ni=function(e,r,n){var s=fr["Size4-Regular"][e.charCodeAt(0)]?fr["Size4-Regular"][e.charCodeAt(0)][4]:fr["Size1-Regular"][e.charCodeAt(0)][4],i=new Xr("inner",E6(e,Math.round(1e3*r))),a=new _r([i],{width:ae(s),height:ae(r),style:"width:"+ae(s),viewBox:"0 0 "+1e3*s+" "+Math.round(1e3*r),preserveAspectRatio:"xMinYMin"}),o=L.makeSvgSpan([],[a],n);return o.height=r,o.style.height=ae(r),o.style.width=ae(s),{type:"elem",elem:o}},va=.008,V0={type:"kern",size:-1*va},k5=["|","\\lvert","\\rvert","\\vert"],S5=["\\|","\\lVert","\\rVert","\\Vert"],ld=function(e,r,n,s,i,a){var o,l,c,d,f="",p=0;o=c=d=e,l=null;var b="Size1-Regular";e==="\\uparrow"?c=d="⏐":e==="\\Uparrow"?c=d="‖":e==="\\downarrow"?o=c="⏐":e==="\\Downarrow"?o=c="‖":e==="\\updownarrow"?(o="\\uparrow",c="⏐",d="\\downarrow"):e==="\\Updownarrow"?(o="\\Uparrow",c="‖",d="\\Downarrow"):we.contains(k5,e)?(c="∣",f="vert",p=333):we.contains(S5,e)?(c="∥",f="doublevert",p=556):e==="["||e==="\\lbrack"?(o="⎡",c="⎢",d="⎣",b="Size4-Regular",f="lbrack",p=667):e==="]"||e==="\\rbrack"?(o="⎤",c="⎥",d="⎦",b="Size4-Regular",f="rbrack",p=667):e==="\\lfloor"||e==="⌊"?(c=o="⎢",d="⎣",b="Size4-Regular",f="lfloor",p=667):e==="\\lceil"||e==="⌈"?(o="⎡",c=d="⎢",b="Size4-Regular",f="lceil",p=667):e==="\\rfloor"||e==="⌋"?(c=o="⎥",d="⎦",b="Size4-Regular",f="rfloor",p=667):e==="\\rceil"||e==="⌉"?(o="⎤",c=d="⎥",b="Size4-Regular",f="rceil",p=667):e==="("||e==="\\lparen"?(o="⎛",c="⎜",d="⎝",b="Size4-Regular",f="lparen",p=875):e===")"||e==="\\rparen"?(o="⎞",c="⎟",d="⎠",b="Size4-Regular",f="rparen",p=875):e==="\\{"||e==="\\lbrace"?(o="⎧",l="⎨",d="⎩",c="⎪",b="Size4-Regular"):e==="\\}"||e==="\\rbrace"?(o="⎫",l="⎬",d="⎭",c="⎪",b="Size4-Regular"):e==="\\lgroup"||e==="⟮"?(o="⎧",d="⎩",c="⎪",b="Size4-Regular"):e==="\\rgroup"||e==="⟯"?(o="⎫",d="⎭",c="⎪",b="Size4-Regular"):e==="\\lmoustache"||e==="⎰"?(o="⎧",d="⎭",c="⎪",b="Size4-Regular"):(e==="\\rmoustache"||e==="⎱")&&(o="⎫",d="⎩",c="⎪",b="Size4-Regular");var v=Zn(o,b,i),x=v.height+v.depth,y=Zn(c,b,i),M=y.height+y.depth,k=Zn(d,b,i),T=k.height+k.depth,N=0,I=1;if(l!==null){var O=Zn(l,b,i);N=O.height+O.depth,I=2}var z=x+T+N,W=Math.max(0,Math.ceil((r-z)/(I*M))),U=z+W*I*M,he=s.fontMetrics().axisHeight;n&&(he*=s.sizeMultiplier);var ge=U/2-he,Ae=[];if(f.length>0){var et=U-x-T,Je=Math.round(U*1e3),ot=C6(f,Math.round(et*1e3)),Fe=new Xr(f,ot),Ie=(p/1e3).toFixed(3)+"em",ve=(Je/1e3).toFixed(3)+"em",Me=new _r([Fe],{width:Ie,height:ve,viewBox:"0 0 "+p+" "+Je}),tt=L.makeSvgSpan([],[Me],s);tt.height=Je/1e3,tt.style.width=Ie,tt.style.height=ve,Ae.push({type:"elem",elem:tt})}else{if(Ae.push(Mi(d,b,i)),Ae.push(V0),l===null){var We=U-x-T+2*va;Ae.push(Ni(c,We,s))}else{var _e=(U-x-T-N)/2+2*va;Ae.push(Ni(c,_e,s)),Ae.push(V0),Ae.push(Mi(l,b,i)),Ae.push(V0),Ae.push(Ni(c,_e,s))}Ae.push(V0),Ae.push(Mi(o,b,i))}var St=s.havingBaseStyle(ke.TEXT),mt=L.makeVList({positionType:"bottom",positionData:ge,children:Ae},St);return ko(L.makeSpan(["delimsizing","mult"],[mt],St),ke.TEXT,s,a)},Di=80,Ri=.08,Ii=function(e,r,n,s,i){var a=A6(e,s,n),o=new Xr(e,a),l=new _r([o],{width:"400em",height:ae(r),viewBox:"0 0 400000 "+n,preserveAspectRatio:"xMinYMin slice"});return L.makeSvgSpan(["hide-tail"],[l],i)},T5=function(e,r){var n=r.havingBaseSizing(),s=hd("\\surd",e*n.sizeMultiplier,dd,n),i=n.sizeMultiplier,a=Math.max(0,r.minRuleThickness-r.fontMetrics().sqrtRuleThickness),o,l=0,c=0,d=0,f;return s.type==="small"?(d=1e3+1e3*a+Di,e<1?i=1:e<1.4&&(i=.7),l=(1+a+Ri)/i,c=(1+a)/i,o=Ii("sqrtMain",l,d,a,r),o.style.minWidth="0.853em",f=.833/i):s.type==="large"?(d=(1e3+Di)*l0[s.size],c=(l0[s.size]+a)/i,l=(l0[s.size]+a+Ri)/i,o=Ii("sqrtSize"+s.size,l,d,a,r),o.style.minWidth="1.02em",f=1/i):(l=e+a+Ri,c=e+a,d=Math.floor(1e3*e+a)+Di,o=Ii("sqrtTall",l,d,a,r),o.style.minWidth="0.742em",f=1.056),o.height=c,o.style.height=ae(l),{span:o,advanceWidth:f,ruleWidth:(r.fontMetrics().sqrtRuleThickness+a)*i}},cd=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","\\surd"],A5=["\\uparrow","\\downarrow","\\updownarrow","\\Uparrow","\\Downarrow","\\Updownarrow","|","\\|","\\vert","\\Vert","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱"],ud=["<",">","\\langle","\\rangle","/","\\backslash","\\lt","\\gt"],l0=[0,1.2,1.8,2.4,3],E5=function(e,r,n,s,i){if(e==="<"||e==="\\lt"||e==="⟨"?e="\\langle":(e===">"||e==="\\gt"||e==="⟩")&&(e="\\rangle"),we.contains(cd,e)||we.contains(ud,e))return od(e,r,!1,n,s,i);if(we.contains(A5,e))return ld(e,l0[r],!1,n,s,i);throw new te("Illegal delimiter: '"+e+"'")},C5=[{type:"small",style:ke.SCRIPTSCRIPT},{type:"small",style:ke.SCRIPT},{type:"small",style:ke.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4}],M5=[{type:"small",style:ke.SCRIPTSCRIPT},{type:"small",style:ke.SCRIPT},{type:"small",style:ke.TEXT},{type:"stack"}],dd=[{type:"small",style:ke.SCRIPTSCRIPT},{type:"small",style:ke.SCRIPT},{type:"small",style:ke.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4},{type:"stack"}],N5=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.")},hd=function(e,r,n,s){for(var i=Math.min(2,3-s.style.size),a=i;a<n.length&&n[a].type!=="stack";a++){var o=Zn(e,N5(n[a]),"math"),l=o.height+o.depth;if(n[a].type==="small"){var c=s.havingBaseStyle(n[a].style);l*=c.sizeMultiplier}if(l>r)return n[a]}return n[n.length-1]},fd=function(e,r,n,s,i,a){e==="<"||e==="\\lt"||e==="⟨"?e="\\langle":(e===">"||e==="\\gt"||e==="⟩")&&(e="\\rangle");var o;we.contains(ud,e)?o=C5:we.contains(cd,e)?o=dd:o=M5;var l=hd(e,r,o,s);return l.type==="small"?w5(e,l.style,n,s,i,a):l.type==="large"?od(e,l.size,n,s,i,a):ld(e,r,n,s,i,a)},D5=function(e,r,n,s,i,a){var o=s.fontMetrics().axisHeight*s.sizeMultiplier,l=901,c=5/s.fontMetrics().ptPerEm,d=Math.max(r-o,n+o),f=Math.max(d/500*l,2*d-c);return fd(e,f,!0,s,i,a)},Dr={sqrtImage:T5,sizedDelim:E5,sizeToMaxHeight:l0,customSizedDelim:fd,leftRightDelim:D5},lc={"\\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}},R5=["(","\\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 ri(t,e){var r=ei(t);if(r&&we.contains(R5,r.text))return r;throw r?new te("Invalid delimiter '"+r.text+"' after '"+e.funcName+"'",t):new te("Invalid delimiter type '"+t.type+"'",t)}oe({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=ri(e[0],t);return{type:"delimsizing",mode:t.parser.mode,size:lc[t.funcName].size,mclass:lc[t.funcName].mclass,delim:r.text}},htmlBuilder:(t,e)=>t.delim==="."?L.makeSpan([t.mclass]):Dr.sizedDelim(t.delim,t.size,e,t.mode,[t.mclass]),mathmlBuilder:t=>{var e=[];t.delim!=="."&&e.push(Xt(t.delim,t.mode));var r=new ee.MathNode("mo",e);t.mclass==="mopen"||t.mclass==="mclose"?r.setAttribute("fence","true"):r.setAttribute("fence","false"),r.setAttribute("stretchy","true");var n=ae(Dr.sizeToMaxHeight[t.size]);return r.setAttribute("minsize",n),r.setAttribute("maxsize",n),r}});function cc(t){if(!t.body)throw new Error("Bug: The leftright ParseNode wasn't fully parsed.")}oe({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:ri(e[0],t).text,color:r}}});oe({type:"leftright",names:["\\left"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var r=ri(e[0],t),n=t.parser;++n.leftrightDepth;var s=n.parseExpression(!1);--n.leftrightDepth,n.expect("\\right",!1);var i=Re(n.parseFunction(),"leftright-right");return{type:"leftright",mode:n.mode,body:s,left:r.text,right:i.delim,rightColor:i.color}},htmlBuilder:(t,e)=>{cc(t);for(var r=pt(t.body,e,!0,["mopen","mclose"]),n=0,s=0,i=!1,a=0;a<r.length;a++)r[a].isMiddle?i=!0:(n=Math.max(r[a].height,n),s=Math.max(r[a].depth,s));n*=e.sizeMultiplier,s*=e.sizeMultiplier;var o;if(t.left==="."?o=g0(e,["mopen"]):o=Dr.leftRightDelim(t.left,n,s,e,t.mode,["mopen"]),r.unshift(o),i)for(var l=1;l<r.length;l++){var c=r[l],d=c.isMiddle;d&&(r[l]=Dr.leftRightDelim(d.delim,n,s,d.options,t.mode,[]))}var f;if(t.right===".")f=g0(e,["mclose"]);else{var p=t.rightColor?e.withColor(t.rightColor):e;f=Dr.leftRightDelim(t.right,n,s,p,t.mode,["mclose"])}return r.push(f),L.makeSpan(["minner"],r,e)},mathmlBuilder:(t,e)=>{cc(t);var r=Lt(t.body,e);if(t.left!=="."){var n=new ee.MathNode("mo",[Xt(t.left,t.mode)]);n.setAttribute("fence","true"),r.unshift(n)}if(t.right!=="."){var s=new ee.MathNode("mo",[Xt(t.right,t.mode)]);s.setAttribute("fence","true"),t.rightColor&&s.setAttribute("mathcolor",t.rightColor),r.push(s)}return bo(r)}});oe({type:"middle",names:["\\middle"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var r=ri(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=g0(e,[]);else{r=Dr.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==="|"?Xt("|","text"):Xt(t.delim,t.mode),n=new ee.MathNode("mo",[r]);return n.setAttribute("fence","true"),n.setAttribute("lspace","0.05em"),n.setAttribute("rspace","0.05em"),n}});var So=(t,e)=>{var r=L.wrapFragment($e(t.body,e),e),n=t.label.slice(1),s=e.sizeMultiplier,i,a=0,o=we.isCharacterBox(t.body);if(n==="sout")i=L.makeSpan(["stretchy","sout"]),i.height=e.fontMetrics().defaultRuleThickness/s,a=-.5*e.fontMetrics().xHeight;else if(n==="phase"){var l=st({number:.6,unit:"pt"},e),c=st({number:.35,unit:"ex"},e),d=e.havingBaseSizing();s=s/d.sizeMultiplier;var f=r.height+r.depth+l+c;r.style.paddingLeft=ae(f/2+l);var p=Math.floor(1e3*f*s),b=S6(p),v=new _r([new Xr("phase",b)],{width:"400em",height:ae(p/1e3),viewBox:"0 0 400000 "+p,preserveAspectRatio:"xMinYMin slice"});i=L.makeSvgSpan(["hide-tail"],[v],e),i.style.height=ae(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,y=0,M=0;/box/.test(n)?(M=Math.max(e.fontMetrics().fboxrule,e.minRuleThickness),x=e.fontMetrics().fboxsep+(n==="colorbox"?0:M),y=x):n==="angl"?(M=Math.max(e.fontMetrics().defaultRuleThickness,e.minRuleThickness),x=4*M,y=Math.max(0,.25-r.depth)):(x=o?.2:0,y=x),i=Lr.encloseSpan(r,n,x,y,e),/fbox|boxed|fcolorbox/.test(n)?(i.style.borderStyle="solid",i.style.borderWidth=ae(M)):n==="angl"&&M!==.049&&(i.style.borderTopWidth=ae(M),i.style.borderRightWidth=ae(M)),a=r.depth+y,t.backgroundColor&&(i.style.backgroundColor=t.backgroundColor,t.borderColor&&(i.style.borderColor=t.borderColor))}var k;if(t.backgroundColor)k=L.makeVList({positionType:"individualShift",children:[{type:"elem",elem:i,shift:a},{type:"elem",elem:r,shift:0}]},e);else{var T=/cancel|phase/.test(n)?["svg-align"]:[];k=L.makeVList({positionType:"individualShift",children:[{type:"elem",elem:r,shift:0},{type:"elem",elem:i,shift:a,wrapperClasses:T}]},e)}return/cancel/.test(n)&&(k.height=r.height,k.depth=r.depth),/cancel/.test(n)&&!o?L.makeSpan(["mord","cancel-lap"],[k],e):L.makeSpan(["mord"],[k],e)},To=(t,e)=>{var r=0,n=new ee.MathNode(t.label.indexOf("colorbox")>-1?"mpadded":"menclose",[Xe(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 s=Math.max(e.fontMetrics().fboxrule,e.minRuleThickness);n.setAttribute("style","border: "+s+"em solid "+String(t.borderColor))}break;case"\\xcancel":n.setAttribute("notation","updiagonalstrike downdiagonalstrike");break}return t.backgroundColor&&n.setAttribute("mathbackground",t.backgroundColor),n};oe({type:"enclose",names:["\\colorbox"],props:{numArgs:2,allowedInText:!0,argTypes:["color","text"]},handler(t,e,r){var{parser:n,funcName:s}=t,i=Re(e[0],"color-token").color,a=e[1];return{type:"enclose",mode:n.mode,label:s,backgroundColor:i,body:a}},htmlBuilder:So,mathmlBuilder:To});oe({type:"enclose",names:["\\fcolorbox"],props:{numArgs:3,allowedInText:!0,argTypes:["color","color","text"]},handler(t,e,r){var{parser:n,funcName:s}=t,i=Re(e[0],"color-token").color,a=Re(e[1],"color-token").color,o=e[2];return{type:"enclose",mode:n.mode,label:s,backgroundColor:a,borderColor:i,body:o}},htmlBuilder:So,mathmlBuilder:To});oe({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]}}});oe({type:"enclose",names:["\\cancel","\\bcancel","\\xcancel","\\sout","\\phase"],props:{numArgs:1},handler(t,e){var{parser:r,funcName:n}=t,s=e[0];return{type:"enclose",mode:r.mode,label:n,body:s}},htmlBuilder:So,mathmlBuilder:To});oe({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 pd={};function gr(t){for(var{type:e,names:r,props:n,handler:s,htmlBuilder:i,mathmlBuilder:a}=t,o={type:e,numArgs:n.numArgs||0,allowedInText:!1,numOptionalArgs:0,handler:s},l=0;l<r.length;++l)pd[r[l]]=o;i&&(Ms[e]=i),a&&(Ns[e]=a)}var md={};function g(t,e){md[t]=e}function uc(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 ni=t=>{var e=t.parser.settings;if(!e.displayMode)throw new te("{"+t.envName+"} can be used only in display mode.")};function Ao(t){if(t.indexOf("ed")===-1)return t.indexOf("*")===-1}function rn(t,e,r){var{hskipBeforeAndAfter:n,addJot:s,cols:i,arraystretch:a,colSeparationType:o,autoTag:l,singleRow:c,emptySingleRow:d,maxNumCols:f,leqno:p}=e;if(t.gullet.beginGroup(),c||t.gullet.macros.set("\\cr","\\\\\\relax"),!a){var b=t.gullet.expandMacroAsText("\\arraystretch");if(b==null)a=1;else if(a=parseFloat(b),!a||a<0)throw new te("Invalid \\arraystretch: "+b)}t.gullet.beginGroup();var v=[],x=[v],y=[],M=[],k=l!=null?[]:void 0;function T(){l&&t.gullet.macros.set("\\@eqnsw","1",!0)}function N(){k&&(t.gullet.macros.get("\\df@tag")?(k.push(t.subparse([new Kt("\\df@tag")])),t.gullet.macros.set("\\df@tag",void 0,!0)):k.push(!!l&&t.gullet.macros.get("\\@eqnsw")==="1"))}for(T(),M.push(uc(t));;){var I=t.parseExpression(!1,c?"\\end":"\\\\");t.gullet.endGroup(),t.gullet.beginGroup(),I={type:"ordgroup",mode:t.mode,body:I},r&&(I={type:"styling",mode:t.mode,style:r,body:[I]}),v.push(I);var O=t.fetch().text;if(O==="&"){if(f&&v.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"){N(),v.length===1&&I.type==="styling"&&I.body[0].body.length===0&&(x.length>1||!d)&&x.pop(),M.length<x.length+1&&M.push([]);break}else if(O==="\\\\"){t.consume();var z=void 0;t.gullet.future().text!==" "&&(z=t.parseSizeGroup(!0)),y.push(z?z.value:null),N(),M.push(uc(t)),v=[],x.push(v),T()}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:s,arraystretch:a,body:x,cols:i,rowGaps:y,hskipBeforeAndAfter:n,hLinesBeforeRow:M,colSeparationType:o,tags:k,leqno:p}}function Eo(t){return t.slice(0,1)==="d"?"display":"text"}var vr=function(e,r){var n,s,i=e.body.length,a=e.hLinesBeforeRow,o=0,l=new Array(i),c=[],d=Math.max(r.fontMetrics().arrayRuleWidth,r.minRuleThickness),f=1/r.fontMetrics().ptPerEm,p=5*f;if(e.colSeparationType&&e.colSeparationType==="small"){var b=r.havingStyle(ke.SCRIPT).sizeMultiplier;p=.2778*(b/r.sizeMultiplier)}var v=e.colSeparationType==="CD"?st({number:3,unit:"ex"},r):12*f,x=3*f,y=e.arraystretch*v,M=.7*y,k=.3*y,T=0;function N(H){for(var X=0;X<H.length;++X)X>0&&(T+=.25),c.push({pos:T,isDashed:H[X]})}for(N(a[0]),n=0;n<e.body.length;++n){var I=e.body[n],O=M,z=k;o<I.length&&(o=I.length);var W=new Array(I.length);for(s=0;s<I.length;++s){var U=$e(I[s],r);z<U.depth&&(z=U.depth),O<U.height&&(O=U.height),W[s]=U}var he=e.rowGaps[n],ge=0;he&&(ge=st(he,r),ge>0&&(ge+=k,z<ge&&(z=ge),ge=0)),e.addJot&&(z+=x),W.height=O,W.depth=z,T+=O,W.pos=T,T+=z+ge,l[n]=W,N(a[n+1])}var Ae=T/2+r.fontMetrics().axisHeight,et=e.cols||[],Je=[],ot,Fe,Ie=[];if(e.tags&&e.tags.some(H=>H))for(n=0;n<i;++n){var ve=l[n],Me=ve.pos-Ae,tt=e.tags[n],We=void 0;tt===!0?We=L.makeSpan(["eqn-num"],[],r):tt===!1?We=L.makeSpan([],[],r):We=L.makeSpan([],pt(tt,r,!0),r),We.depth=ve.depth,We.height=ve.height,Ie.push({type:"elem",elem:We,shift:Me})}for(s=0,Fe=0;s<o||Fe<et.length;++s,++Fe){for(var _e=et[Fe]||{},St=!0;_e.type==="separator";){if(St||(ot=L.makeSpan(["arraycolsep"],[]),ot.style.width=ae(r.fontMetrics().doubleRuleSep),Je.push(ot)),_e.separator==="|"||_e.separator===":"){var mt=_e.separator==="|"?"solid":"dashed",j=L.makeSpan(["vertical-separator"],[],r);j.style.height=ae(T),j.style.borderRightWidth=ae(d),j.style.borderRightStyle=mt,j.style.margin="0 "+ae(-d/2);var V=T-Ae;V&&(j.style.verticalAlign=ae(-V)),Je.push(j)}else throw new te("Invalid separator type: "+_e.separator);Fe++,_e=et[Fe]||{},St=!1}if(!(s>=o)){var re=void 0;(s>0||e.hskipBeforeAndAfter)&&(re=we.deflt(_e.pregap,p),re!==0&&(ot=L.makeSpan(["arraycolsep"],[]),ot.style.width=ae(re),Je.push(ot)));var ie=[];for(n=0;n<i;++n){var Ee=l[n],ye=Ee[s];if(ye){var fe=Ee.pos-Ae;ye.depth=Ee.depth,ye.height=Ee.height,ie.push({type:"elem",elem:ye,shift:fe})}}ie=L.makeVList({positionType:"individualShift",children:ie},r),ie=L.makeSpan(["col-align-"+(_e.align||"c")],[ie]),Je.push(ie),(s<o-1||e.hskipBeforeAndAfter)&&(re=we.deflt(_e.postgap,p),re!==0&&(ot=L.makeSpan(["arraycolsep"],[]),ot.style.width=ae(re),Je.push(ot)))}}if(l=L.makeSpan(["mtable"],Je),c.length>0){for(var Ue=L.makeLineSpan("hline",r,d),S=L.makeLineSpan("hdashline",r,d),D=[{type:"elem",elem:l,shift:0}];c.length>0;){var F=c.pop(),G=F.pos-Ae;F.isDashed?D.push({type:"elem",elem:S,shift:G}):D.push({type:"elem",elem:Ue,shift:G})}l=L.makeVList({positionType:"individualShift",children:D},r)}if(Ie.length===0)return L.makeSpan(["mord"],[l],r);var q=L.makeVList({positionType:"individualShift",children:Ie},r);return q=L.makeSpan(["tag"],[q],r),L.makeFragment([l,q])},I5={c:"center ",l:"left ",r:"right "},br=function(e,r){for(var n=[],s=new ee.MathNode("mtd",[],["mtr-glue"]),i=new ee.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 ee.MathNode("mtd",[Xe(o[c],r)]));e.tags&&e.tags[a]&&(l.unshift(s),l.push(s),e.leqno?l.unshift(i):l.push(i)),n.push(new ee.MathNode("mtr",l))}var d=new ee.MathNode("mtable",n),f=e.arraystretch===.5?.1:.16+e.arraystretch-1+(e.addJot?.09:0);d.setAttribute("rowspacing",ae(f));var p="",b="";if(e.cols&&e.cols.length>0){var v=e.cols,x="",y=!1,M=0,k=v.length;v[0].type==="separator"&&(p+="top ",M=1),v[v.length-1].type==="separator"&&(p+="bottom ",k-=1);for(var T=M;T<k;T++)v[T].type==="align"?(b+=I5[v[T].align],y&&(x+="none "),y=!0):v[T].type==="separator"&&y&&(x+=v[T].separator==="|"?"solid ":"dashed ",y=!1);d.setAttribute("columnalign",b.trim()),/[sd]/.test(x)&&d.setAttribute("columnlines",x.trim())}if(e.colSeparationType==="align"){for(var N=e.cols||[],I="",O=1;O<N.length;O++)I+=O%2?"0em ":"1em ";d.setAttribute("columnspacing",I.trim())}else e.colSeparationType==="alignat"||e.colSeparationType==="gather"?d.setAttribute("columnspacing","0em"):e.colSeparationType==="small"?d.setAttribute("columnspacing","0.2778em"):e.colSeparationType==="CD"?d.setAttribute("columnspacing","0.5em"):d.setAttribute("columnspacing","1em");var z="",W=e.hLinesBeforeRow;p+=W[0].length>0?"left ":"",p+=W[W.length-1].length>0?"right ":"";for(var U=1;U<W.length-1;U++)z+=W[U].length===0?"none ":W[U][0]?"dashed ":"solid ";return/[sd]/.test(z)&&d.setAttribute("rowlines",z.trim()),p!==""&&(d=new ee.MathNode("menclose",[d]),d.setAttribute("notation",p.trim())),e.arraystretch&&e.arraystretch<1&&(d=new ee.MathNode("mstyle",[d]),d.setAttribute("scriptlevel","1")),d},gd=function(e,r){e.envName.indexOf("ed")===-1&&ni(e);var n=[],s=e.envName.indexOf("at")>-1?"alignat":"align",i=e.envName==="split",a=rn(e.parser,{cols:n,addJot:!0,autoTag:i?void 0:Ao(e.envName),emptySingleRow:!0,colSeparationType:s,maxNumCols:i?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 d="",f=0;f<r[0].body.length;f++){var p=Re(r[0].body[f],"textord");d+=p.text}o=Number(d),l=o*2}var b=!l;a.body.forEach(function(M){for(var k=1;k<M.length;k+=2){var T=Re(M[k],"styling"),N=Re(T.body[0],"ordgroup");N.body.unshift(c)}if(b)l<M.length&&(l=M.length);else{var I=M.length/2;if(o<I)throw new te("Too many math in a row: "+("expected "+o+", but got "+I),M[0])}});for(var v=0;v<l;++v){var x="r",y=0;v%2===1?x="l":v>0&&b&&(y=1),n[v]={type:"align",align:x,pregap:y,postgap:0}}return a.colSeparationType=b?"align":"alignat",a};gr({type:"array",names:["array","darray"],props:{numArgs:1},handler(t,e){var r=ei(e[0]),n=r?[e[0]]:Re(e[0],"ordgroup").body,s=n.map(function(a){var o=wo(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)}),i={cols:s,hskipBeforeAndAfter:!0,maxNumCols:s.length};return rn(t.parser,i,Eo(t.envName))},htmlBuilder:vr,mathmlBuilder:br});gr({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 s=t.parser;if(s.consumeSpaces(),s.fetch().text==="["){if(s.consume(),s.consumeSpaces(),r=s.fetch().text,"lcr".indexOf(r)===-1)throw new te("Expected l or c or r",s.nextToken);s.consume(),s.consumeSpaces(),s.expect("]"),s.consume(),n.cols=[{type:"align",align:r}]}}var i=rn(t.parser,n,Eo(t.envName)),a=Math.max(0,...i.body.map(o=>o.length));return i.cols=new Array(a).fill({type:"align",align:r}),e?{type:"leftright",mode:t.mode,body:[i],left:e[0],right:e[1],rightColor:void 0}:i},htmlBuilder:vr,mathmlBuilder:br});gr({type:"array",names:["smallmatrix"],props:{numArgs:0},handler(t){var e={arraystretch:.5},r=rn(t.parser,e,"script");return r.colSeparationType="small",r},htmlBuilder:vr,mathmlBuilder:br});gr({type:"array",names:["subarray"],props:{numArgs:1},handler(t,e){var r=ei(e[0]),n=r?[e[0]]:Re(e[0],"ordgroup").body,s=n.map(function(a){var o=wo(a),l=o.text;if("lc".indexOf(l)!==-1)return{type:"align",align:l};throw new te("Unknown column alignment: "+l,a)});if(s.length>1)throw new te("{subarray} can contain only one column");var i={cols:s,hskipBeforeAndAfter:!1,arraystretch:.5};if(i=rn(t.parser,i,"script"),i.body.length>0&&i.body[0].length>1)throw new te("{subarray} can contain only one column");return i},htmlBuilder:vr,mathmlBuilder:br});gr({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=rn(t.parser,e,Eo(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:vr,mathmlBuilder:br});gr({type:"array",names:["align","align*","aligned","split"],props:{numArgs:0},handler:gd,htmlBuilder:vr,mathmlBuilder:br});gr({type:"array",names:["gathered","gather","gather*"],props:{numArgs:0},handler(t){we.contains(["gather","gather*"],t.envName)&&ni(t);var e={cols:[{type:"align",align:"c"}],addJot:!0,colSeparationType:"gather",autoTag:Ao(t.envName),emptySingleRow:!0,leqno:t.parser.settings.leqno};return rn(t.parser,e,"display")},htmlBuilder:vr,mathmlBuilder:br});gr({type:"array",names:["alignat","alignat*","alignedat"],props:{numArgs:1},handler:gd,htmlBuilder:vr,mathmlBuilder:br});gr({type:"array",names:["equation","equation*"],props:{numArgs:0},handler(t){ni(t);var e={autoTag:Ao(t.envName),emptySingleRow:!0,singleRow:!0,maxNumCols:1,leqno:t.parser.settings.leqno};return rn(t.parser,e,"display")},htmlBuilder:vr,mathmlBuilder:br});gr({type:"array",names:["CD"],props:{numArgs:0},handler(t){return ni(t),b5(t.parser)},htmlBuilder:vr,mathmlBuilder:br});g("\\nonumber","\\gdef\\@eqnsw{0}");g("\\notag","\\nonumber");oe({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 dc=pd;oe({type:"environment",names:["\\begin","\\end"],props:{numArgs:1,argTypes:["text"]},handler(t,e){var{parser:r,funcName:n}=t,s=e[0];if(s.type!=="ordgroup")throw new te("Invalid environment name",s);for(var i="",a=0;a<s.body.length;++a)i+=Re(s.body[a],"textord").text;if(n==="\\begin"){if(!dc.hasOwnProperty(i))throw new te("No such environment: "+i,s);var o=dc[i],{args:l,optArgs:c}=r.parseArguments("\\begin{"+i+"}",o),d={mode:r.mode,envName:i,parser:r},f=o.handler(d,l,c);r.expect("\\end",!1);var p=r.nextToken,b=Re(r.parseFunction(),"environment");if(b.name!==i)throw new te("Mismatch: \\begin{"+i+"} matched by \\end{"+b.name+"}",p);return f}return{type:"environment",mode:r.mode,name:i,nameGroup:s}}});var vd=(t,e)=>{var r=t.font,n=e.withFont(r);return $e(t.body,n)},bd=(t,e)=>{var r=t.font,n=e.withFont(r);return Xe(t.body,n)},hc={"\\Bbb":"\\mathbb","\\bold":"\\mathbf","\\frak":"\\mathfrak","\\bm":"\\boldsymbol"};oe({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,s=Ds(e[0]),i=n;return i in hc&&(i=hc[i]),{type:"font",mode:r.mode,font:i.slice(1),body:s}},htmlBuilder:vd,mathmlBuilder:bd});oe({type:"mclass",names:["\\boldsymbol","\\bm"],props:{numArgs:1},handler:(t,e)=>{var{parser:r}=t,n=e[0],s=we.isCharacterBox(n);return{type:"mclass",mode:r.mode,mclass:ti(n),body:[{type:"font",mode:r.mode,font:"boldsymbol",body:n}],isCharacterBox:s}}});oe({type:"font",names:["\\rm","\\sf","\\tt","\\bf","\\it","\\cal"],props:{numArgs:0,allowedInText:!0},handler:(t,e)=>{var{parser:r,funcName:n,breakOnTokenText:s}=t,{mode:i}=r,a=r.parseExpression(!0,s),o="math"+n.slice(1);return{type:"font",mode:i,font:o,body:{type:"ordgroup",mode:r.mode,body:a}}},htmlBuilder:vd,mathmlBuilder:bd});var yd=(t,e)=>{var r=e;return t==="display"?r=r.id>=ke.SCRIPT.id?r.text():ke.DISPLAY:t==="text"&&r.size===ke.DISPLAY.size?r=ke.TEXT:t==="script"?r=ke.SCRIPT:t==="scriptscript"&&(r=ke.SCRIPTSCRIPT),r},Co=(t,e)=>{var r=yd(t.size,e.style),n=r.fracNum(),s=r.fracDen(),i;i=e.havingStyle(n);var a=$e(t.numer,i,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}i=e.havingStyle(s);var c=$e(t.denom,i,e),d,f,p;t.hasBarLine?(t.barSize?(f=st(t.barSize,e),d=L.makeLineSpan("frac-line",e,f)):d=L.makeLineSpan("frac-line",e),f=d.height,p=d.height):(d=null,f=0,p=e.fontMetrics().defaultRuleThickness);var b,v,x;r.size===ke.DISPLAY.size||t.size==="display"?(b=e.fontMetrics().num1,f>0?v=3*p:v=7*p,x=e.fontMetrics().denom1):(f>0?(b=e.fontMetrics().num2,v=p):(b=e.fontMetrics().num3,v=3*p),x=e.fontMetrics().denom2);var y;if(d){var k=e.fontMetrics().axisHeight;b-a.depth-(k+.5*f)<v&&(b+=v-(b-a.depth-(k+.5*f))),k-.5*f-(c.height-x)<v&&(x+=v-(k-.5*f-(c.height-x)));var T=-(k-.5*f);y=L.makeVList({positionType:"individualShift",children:[{type:"elem",elem:c,shift:x},{type:"elem",elem:d,shift:T},{type:"elem",elem:a,shift:-b}]},e)}else{var M=b-a.depth-(c.height-x);M<v&&(b+=.5*(v-M),x+=.5*(v-M)),y=L.makeVList({positionType:"individualShift",children:[{type:"elem",elem:c,shift:x},{type:"elem",elem:a,shift:-b}]},e)}i=e.havingStyle(r),y.height*=i.sizeMultiplier/e.sizeMultiplier,y.depth*=i.sizeMultiplier/e.sizeMultiplier;var N;r.size===ke.DISPLAY.size?N=e.fontMetrics().delim1:r.size===ke.SCRIPTSCRIPT.size?N=e.havingStyle(ke.SCRIPT).fontMetrics().delim2:N=e.fontMetrics().delim2;var I,O;return t.leftDelim==null?I=g0(e,["mopen"]):I=Dr.customSizedDelim(t.leftDelim,N,!0,e.havingStyle(r),t.mode,["mopen"]),t.continued?O=L.makeSpan([]):t.rightDelim==null?O=g0(e,["mclose"]):O=Dr.customSizedDelim(t.rightDelim,N,!0,e.havingStyle(r),t.mode,["mclose"]),L.makeSpan(["mord"].concat(i.sizingClasses(e)),[I,L.makeSpan(["mfrac"],[y]),O],e)},Mo=(t,e)=>{var r=new ee.MathNode("mfrac",[Xe(t.numer,e),Xe(t.denom,e)]);if(!t.hasBarLine)r.setAttribute("linethickness","0px");else if(t.barSize){var n=st(t.barSize,e);r.setAttribute("linethickness",ae(n))}var s=yd(t.size,e.style);if(s.size!==e.style.size){r=new ee.MathNode("mstyle",[r]);var i=s.size===ke.DISPLAY.size?"true":"false";r.setAttribute("displaystyle",i),r.setAttribute("scriptlevel","0")}if(t.leftDelim!=null||t.rightDelim!=null){var a=[];if(t.leftDelim!=null){var o=new ee.MathNode("mo",[new ee.TextNode(t.leftDelim.replace("\\",""))]);o.setAttribute("fence","true"),a.push(o)}if(a.push(r),t.rightDelim!=null){var l=new ee.MathNode("mo",[new ee.TextNode(t.rightDelim.replace("\\",""))]);l.setAttribute("fence","true"),a.push(l)}return bo(a)}return r};oe({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,s=e[0],i=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:s,denom:i,hasBarLine:a,leftDelim:o,rightDelim:l,size:c,barSize:null}},htmlBuilder:Co,mathmlBuilder:Mo});oe({type:"genfrac",names:["\\cfrac"],props:{numArgs:2},handler:(t,e)=>{var{parser:r,funcName:n}=t,s=e[0],i=e[1];return{type:"genfrac",mode:r.mode,continued:!0,numer:s,denom:i,hasBarLine:!0,leftDelim:null,rightDelim:null,size:"display",barSize:null}}});oe({type:"infix",names:["\\over","\\choose","\\atop","\\brace","\\brack"],props:{numArgs:0,infix:!0},handler(t){var{parser:e,funcName:r,token:n}=t,s;switch(r){case"\\over":s="\\frac";break;case"\\choose":s="\\binom";break;case"\\atop":s="\\\\atopfrac";break;case"\\brace":s="\\\\bracefrac";break;case"\\brack":s="\\\\brackfrac";break;default:throw new Error("Unrecognized infix genfrac command")}return{type:"infix",mode:e.mode,replaceWith:s,token:n}}});var fc=["display","text","script","scriptscript"],pc=function(e){var r=null;return e.length>0&&(r=e,r=r==="."?null:r),r};oe({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],s=e[5],i=Ds(e[0]),a=i.type==="atom"&&i.family==="open"?pc(i.text):null,o=Ds(e[1]),l=o.type==="atom"&&o.family==="close"?pc(o.text):null,c=Re(e[2],"size"),d,f=null;c.isBlank?d=!0:(f=c.value,d=f.number>0);var p="auto",b=e[3];if(b.type==="ordgroup"){if(b.body.length>0){var v=Re(b.body[0],"textord");p=fc[Number(v.text)]}}else b=Re(b,"textord"),p=fc[Number(b.text)];return{type:"genfrac",mode:r.mode,numer:n,denom:s,continued:!1,hasBarLine:d,barSize:f,leftDelim:a,rightDelim:l,size:p}},htmlBuilder:Co,mathmlBuilder:Mo});oe({type:"infix",names:["\\above"],props:{numArgs:1,argTypes:["size"],infix:!0},handler(t,e){var{parser:r,funcName:n,token:s}=t;return{type:"infix",mode:r.mode,replaceWith:"\\\\abovefrac",size:Re(e[0],"size").value,token:s}}});oe({type:"genfrac",names:["\\\\abovefrac"],props:{numArgs:3,argTypes:["math","size","math"]},handler:(t,e)=>{var{parser:r,funcName:n}=t,s=e[0],i=l6(Re(e[1],"infix").size),a=e[2],o=i.number>0;return{type:"genfrac",mode:r.mode,numer:s,denom:a,continued:!1,hasBarLine:o,barSize:i,leftDelim:null,rightDelim:null,size:"auto"}},htmlBuilder:Co,mathmlBuilder:Mo});var wd=(t,e)=>{var r=e.style,n,s;t.type==="supsub"?(n=t.sup?$e(t.sup,e.havingStyle(r.sup()),e):$e(t.sub,e.havingStyle(r.sub()),e),s=Re(t.base,"horizBrace")):s=Re(t,"horizBrace");var i=$e(s.base,e.havingBaseStyle(ke.DISPLAY)),a=Lr.svgSpan(s,e),o;if(s.isOver?(o=L.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i},{type:"kern",size:.1},{type:"elem",elem:a}]},e),o.children[0].children[0].children[1].classes.push("svg-align")):(o=L.makeVList({positionType:"bottom",positionData:i.depth+.1+a.height,children:[{type:"elem",elem:a},{type:"kern",size:.1},{type:"elem",elem:i}]},e),o.children[0].children[0].children[0].classes.push("svg-align")),n){var l=L.makeSpan(["mord",s.isOver?"mover":"munder"],[o],e);s.isOver?o=L.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:l},{type:"kern",size:.2},{type:"elem",elem:n}]},e):o=L.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 L.makeSpan(["mord",s.isOver?"mover":"munder"],[o],e)},_5=(t,e)=>{var r=Lr.mathMLnode(t.label);return new ee.MathNode(t.isOver?"mover":"munder",[Xe(t.base,e),r])};oe({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:wd,mathmlBuilder:_5});oe({type:"href",names:["\\href"],props:{numArgs:2,argTypes:["url","original"],allowedInText:!0},handler:(t,e)=>{var{parser:r}=t,n=e[1],s=Re(e[0],"url").url;return r.settings.isTrusted({command:"\\href",url:s})?{type:"href",mode:r.mode,href:s,body:ct(n)}:r.formatUnsupportedCmd("\\href")},htmlBuilder:(t,e)=>{var r=pt(t.body,e,!1);return L.makeAnchor(t.href,[],r,e)},mathmlBuilder:(t,e)=>{var r=Jr(t.body,e);return r instanceof Bt||(r=new Bt("mrow",[r])),r.setAttribute("href",t.href),r}});oe({type:"href",names:["\\url"],props:{numArgs:1,argTypes:["url"],allowedInText:!0},handler:(t,e)=>{var{parser:r}=t,n=Re(e[0],"url").url;if(!r.settings.isTrusted({command:"\\url",url:n}))return r.formatUnsupportedCmd("\\url");for(var s=[],i=0;i<n.length;i++){var a=n[i];a==="~"&&(a="\\textasciitilde"),s.push({type:"textord",mode:"text",text:a})}var o={type:"text",mode:r.mode,font:"\\texttt",body:s};return{type:"href",mode:r.mode,href:n,body:ct(o)}}});oe({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:ct(e[0])}},htmlBuilder(t,e){var r=pt(t.body,e,!1);return L.makeFragment(r)},mathmlBuilder(t,e){return new ee.MathNode("mrow",Lt(t.body,e))}});oe({type:"html",names:["\\htmlClass","\\htmlId","\\htmlStyle","\\htmlData"],props:{numArgs:2,argTypes:["raw","original"],allowedInText:!0},handler:(t,e)=>{var{parser:r,funcName:n,token:s}=t,i=Re(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=i,o={command:"\\htmlClass",class:i};break;case"\\htmlId":l.id=i,o={command:"\\htmlId",id:i};break;case"\\htmlStyle":l.style=i,o={command:"\\htmlStyle",style:i};break;case"\\htmlData":{for(var c=i.split(","),d=0;d<c.length;d++){var f=c[d].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:ct(a)}:r.formatUnsupportedCmd(n)},htmlBuilder:(t,e)=>{var r=pt(t.body,e,!1),n=["enclosing"];t.attributes.class&&n.push(...t.attributes.class.trim().split(/\s+/));var s=L.makeSpan(n,r,e);for(var i in t.attributes)i!=="class"&&t.attributes.hasOwnProperty(i)&&s.setAttribute(i,t.attributes[i]);return s},mathmlBuilder:(t,e)=>Jr(t.body,e)});oe({type:"htmlmathml",names:["\\html@mathml"],props:{numArgs:2,allowedInText:!0},handler:(t,e)=>{var{parser:r}=t;return{type:"htmlmathml",mode:r.mode,html:ct(e[0]),mathml:ct(e[1])}},htmlBuilder:(t,e)=>{var r=pt(t.html,e,!1);return L.makeFragment(r)},mathmlBuilder:(t,e)=>Jr(t.mathml,e)});var _i=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(!B1(n))throw new te("Invalid unit: '"+n.unit+"' in \\includegraphics.");return n};oe({type:"includegraphics",names:["\\includegraphics"],props:{numArgs:1,numOptionalArgs:1,argTypes:["raw","url"],allowedInText:!1},handler:(t,e,r)=>{var{parser:n}=t,s={number:0,unit:"em"},i={number:.9,unit:"em"},a={number:0,unit:"em"},o="";if(r[0])for(var l=Re(r[0],"raw").string,c=l.split(","),d=0;d<c.length;d++){var f=c[d].split("=");if(f.length===2){var p=f[1].trim();switch(f[0].trim()){case"alt":o=p;break;case"width":s=_i(p);break;case"height":i=_i(p);break;case"totalheight":a=_i(p);break;default:throw new te("Invalid key: '"+f[0]+"' in \\includegraphics.")}}}var b=Re(e[0],"url").url;return o===""&&(o=b,o=o.replace(/^.*[\\/]/,""),o=o.substring(0,o.lastIndexOf("."))),n.settings.isTrusted({command:"\\includegraphics",url:b})?{type:"includegraphics",mode:n.mode,alt:o,width:s,height:i,totalheight:a,src:b}:n.formatUnsupportedCmd("\\includegraphics")},htmlBuilder:(t,e)=>{var r=st(t.height,e),n=0;t.totalheight.number>0&&(n=st(t.totalheight,e)-r);var s=0;t.width.number>0&&(s=st(t.width,e));var i={height:ae(r+n)};s>0&&(i.width=ae(s)),n>0&&(i.verticalAlign=ae(-n));var a=new _6(t.src,t.alt,i);return a.height=r,a.depth=n,a},mathmlBuilder:(t,e)=>{var r=new ee.MathNode("mglyph",[]);r.setAttribute("alt",t.alt);var n=st(t.height,e),s=0;if(t.totalheight.number>0&&(s=st(t.totalheight,e)-n,r.setAttribute("valign",ae(-s))),r.setAttribute("height",ae(n+s)),t.width.number>0){var i=st(t.width,e);r.setAttribute("width",ae(i))}return r.setAttribute("src",t.src),r}});oe({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,s=Re(e[0],"size");if(r.settings.strict){var i=n[1]==="m",a=s.value.unit==="mu";i?(a||r.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+n+" supports only mu units, "+("not "+s.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:s.value}},htmlBuilder(t,e){return L.makeGlue(t.dimension,e)},mathmlBuilder(t,e){var r=st(t.dimension,e);return new ee.SpaceNode(r)}});oe({type:"lap",names:["\\mathllap","\\mathrlap","\\mathclap"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:r,funcName:n}=t,s=e[0];return{type:"lap",mode:r.mode,alignment:n.slice(5),body:s}},htmlBuilder:(t,e)=>{var r;t.alignment==="clap"?(r=L.makeSpan([],[$e(t.body,e)]),r=L.makeSpan(["inner"],[r],e)):r=L.makeSpan(["inner"],[$e(t.body,e)]);var n=L.makeSpan(["fix"],[]),s=L.makeSpan([t.alignment],[r,n],e),i=L.makeSpan(["strut"]);return i.style.height=ae(s.height+s.depth),s.depth&&(i.style.verticalAlign=ae(-s.depth)),s.children.unshift(i),s=L.makeSpan(["thinbox"],[s],e),L.makeSpan(["mord","vbox"],[s],e)},mathmlBuilder:(t,e)=>{var r=new ee.MathNode("mpadded",[Xe(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}});oe({type:"styling",names:["\\(","$"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(t,e){var{funcName:r,parser:n}=t,s=n.mode;n.switchMode("math");var i=r==="\\("?"\\)":"$",a=n.parseExpression(!1,i);return n.expect(i),n.switchMode(s),{type:"styling",mode:n.mode,style:"text",body:a}}});oe({type:"text",names:["\\)","\\]"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(t,e){throw new te("Mismatched "+t.funcName)}});var mc=(t,e)=>{switch(e.style.size){case ke.DISPLAY.size:return t.display;case ke.TEXT.size:return t.text;case ke.SCRIPT.size:return t.script;case ke.SCRIPTSCRIPT.size:return t.scriptscript;default:return t.text}};oe({type:"mathchoice",names:["\\mathchoice"],props:{numArgs:4,primitive:!0},handler:(t,e)=>{var{parser:r}=t;return{type:"mathchoice",mode:r.mode,display:ct(e[0]),text:ct(e[1]),script:ct(e[2]),scriptscript:ct(e[3])}},htmlBuilder:(t,e)=>{var r=mc(t,e),n=pt(r,e,!1);return L.makeFragment(n)},mathmlBuilder:(t,e)=>{var r=mc(t,e);return Jr(r,e)}});var xd=(t,e,r,n,s,i,a)=>{t=L.makeSpan([],[t]);var o=r&&we.isCharacterBox(r),l,c;if(e){var d=$e(e,n.havingStyle(s.sup()),n);c={elem:d,kern:Math.max(n.fontMetrics().bigOpSpacing1,n.fontMetrics().bigOpSpacing3-d.depth)}}if(r){var f=$e(r,n.havingStyle(s.sub()),n);l={elem:f,kern:Math.max(n.fontMetrics().bigOpSpacing2,n.fontMetrics().bigOpSpacing4-f.height)}}var p;if(c&&l){var b=n.fontMetrics().bigOpSpacing5+l.elem.height+l.elem.depth+l.kern+t.depth+a;p=L.makeVList({positionType:"bottom",positionData:b,children:[{type:"kern",size:n.fontMetrics().bigOpSpacing5},{type:"elem",elem:l.elem,marginLeft:ae(-i)},{type:"kern",size:l.kern},{type:"elem",elem:t},{type:"kern",size:c.kern},{type:"elem",elem:c.elem,marginLeft:ae(i)},{type:"kern",size:n.fontMetrics().bigOpSpacing5}]},n)}else if(l){var v=t.height-a;p=L.makeVList({positionType:"top",positionData:v,children:[{type:"kern",size:n.fontMetrics().bigOpSpacing5},{type:"elem",elem:l.elem,marginLeft:ae(-i)},{type:"kern",size:l.kern},{type:"elem",elem:t}]},n)}else if(c){var x=t.depth+a;p=L.makeVList({positionType:"bottom",positionData:x,children:[{type:"elem",elem:t},{type:"kern",size:c.kern},{type:"elem",elem:c.elem,marginLeft:ae(i)},{type:"kern",size:n.fontMetrics().bigOpSpacing5}]},n)}else return t;var y=[p];if(l&&i!==0&&!o){var M=L.makeSpan(["mspace"],[],n);M.style.marginRight=ae(i),y.unshift(M)}return L.makeSpan(["mop","op-limits"],y,n)},kd=["\\smallint"],qn=(t,e)=>{var r,n,s=!1,i;t.type==="supsub"?(r=t.sup,n=t.sub,i=Re(t.base,"op"),s=!0):i=Re(t,"op");var a=e.style,o=!1;a.size===ke.DISPLAY.size&&i.symbol&&!we.contains(kd,i.name)&&(o=!0);var l;if(i.symbol){var c=o?"Size2-Regular":"Size1-Regular",d="";if((i.name==="\\oiint"||i.name==="\\oiiint")&&(d=i.name.slice(1),i.name=d==="oiint"?"\\iint":"\\iiint"),l=L.makeSymbol(i.name,c,"math",e,["mop","op-symbol",o?"large-op":"small-op"]),d.length>0){var f=l.italic,p=L.staticSvg(d+"Size"+(o?"2":"1"),e);l=L.makeVList({positionType:"individualShift",children:[{type:"elem",elem:l,shift:0},{type:"elem",elem:p,shift:o?.08:0}]},e),i.name="\\"+d,l.classes.unshift("mop"),l.italic=f}}else if(i.body){var b=pt(i.body,e,!0);b.length===1&&b[0]instanceof Yt?(l=b[0],l.classes[0]="mop"):l=L.makeSpan(["mop"],b,e)}else{for(var v=[],x=1;x<i.name.length;x++)v.push(L.mathsym(i.name[x],i.mode,e));l=L.makeSpan(["mop"],v,e)}var y=0,M=0;return(l instanceof Yt||i.name==="\\oiint"||i.name==="\\oiiint")&&!i.suppressBaseShift&&(y=(l.height-l.depth)/2-e.fontMetrics().axisHeight,M=l.italic),s?xd(l,r,n,e,a,M,y):(y&&(l.style.position="relative",l.style.top=ae(y)),l)},E0=(t,e)=>{var r;if(t.symbol)r=new Bt("mo",[Xt(t.name,t.mode)]),we.contains(kd,t.name)&&r.setAttribute("largeop","false");else if(t.body)r=new Bt("mo",Lt(t.body,e));else{r=new Bt("mi",[new pr(t.name.slice(1))]);var n=new Bt("mo",[Xt("","text")]);t.parentIsSupSub?r=new Bt("mrow",[r,n]):r=X1([r,n])}return r},O5={"∏":"\\prod","∐":"\\coprod","∑":"\\sum","⋀":"\\bigwedge","⋁":"\\bigvee","⋂":"\\bigcap","⋃":"\\bigcup","⨀":"\\bigodot","⨁":"\\bigoplus","⨂":"\\bigotimes","⨄":"\\biguplus","⨆":"\\bigsqcup"};oe({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,s=n;return s.length===1&&(s=O5[s]),{type:"op",mode:r.mode,limits:!0,parentIsSupSub:!1,symbol:!0,name:s}},htmlBuilder:qn,mathmlBuilder:E0});oe({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:ct(n)}},htmlBuilder:qn,mathmlBuilder:E0});var L5={"∫":"\\int","∬":"\\iint","∭":"\\iiint","∮":"\\oint","∯":"\\oiint","∰":"\\oiiint"};oe({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:qn,mathmlBuilder:E0});oe({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:qn,mathmlBuilder:E0});oe({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=L5[n]),{type:"op",mode:e.mode,limits:!1,parentIsSupSub:!1,symbol:!0,name:n}},htmlBuilder:qn,mathmlBuilder:E0});var Sd=(t,e)=>{var r,n,s=!1,i;t.type==="supsub"?(r=t.sup,n=t.sub,i=Re(t.base,"operatorname"),s=!0):i=Re(t,"operatorname");var a;if(i.body.length>0){for(var o=i.body.map(f=>{var p=f.text;return typeof p=="string"?{type:"textord",mode:f.mode,text:p}:f}),l=pt(o,e.withFont("mathrm"),!0),c=0;c<l.length;c++){var d=l[c];d instanceof Yt&&(d.text=d.text.replace(/\u2212/,"-").replace(/\u2217/,"*"))}a=L.makeSpan(["mop"],l,e)}else a=L.makeSpan(["mop"],[],e);return s?xd(a,r,n,e,e.style,0,0):a},z5=(t,e)=>{for(var r=Lt(t.body,e.withFont("mathrm")),n=!0,s=0;s<r.length;s++){var i=r[s];if(!(i instanceof ee.SpaceNode))if(i instanceof ee.MathNode)switch(i.type){case"mi":case"mn":case"ms":case"mspace":case"mtext":break;case"mo":{var a=i.children[0];i.children.length===1&&a instanceof ee.TextNode?a.text=a.text.replace(/\u2212/,"-").replace(/\u2217/,"*"):n=!1;break}default:n=!1}else n=!1}if(n){var o=r.map(d=>d.toText()).join("");r=[new ee.TextNode(o)]}var l=new ee.MathNode("mi",r);l.setAttribute("mathvariant","normal");var c=new ee.MathNode("mo",[Xt("","text")]);return t.parentIsSupSub?new ee.MathNode("mrow",[l,c]):ee.newDocumentFragment([l,c])};oe({type:"operatorname",names:["\\operatorname@","\\operatornamewithlimits"],props:{numArgs:1},handler:(t,e)=>{var{parser:r,funcName:n}=t,s=e[0];return{type:"operatorname",mode:r.mode,body:ct(s),alwaysHandleSupSub:n==="\\operatornamewithlimits",limits:!1,parentIsSupSub:!1}},htmlBuilder:Sd,mathmlBuilder:z5});g("\\operatorname","\\@ifstar\\operatornamewithlimits\\operatorname@");bn({type:"ordgroup",htmlBuilder(t,e){return t.semisimple?L.makeFragment(pt(t.body,e,!1)):L.makeSpan(["mord"],pt(t.body,e,!0),e)},mathmlBuilder(t,e){return Jr(t.body,e,!0)}});oe({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=L.makeLineSpan("overline-line",e),s=e.fontMetrics().defaultRuleThickness,i=L.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r},{type:"kern",size:3*s},{type:"elem",elem:n},{type:"kern",size:s}]},e);return L.makeSpan(["mord","overline"],[i],e)},mathmlBuilder(t,e){var r=new ee.MathNode("mo",[new ee.TextNode("‾")]);r.setAttribute("stretchy","true");var n=new ee.MathNode("mover",[Xe(t.body,e),r]);return n.setAttribute("accent","true"),n}});oe({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:ct(n)}},htmlBuilder:(t,e)=>{var r=pt(t.body,e.withPhantom(),!1);return L.makeFragment(r)},mathmlBuilder:(t,e)=>{var r=Lt(t.body,e);return new ee.MathNode("mphantom",r)}});oe({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=L.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=L.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r}]},e),L.makeSpan(["mord"],[r],e)},mathmlBuilder:(t,e)=>{var r=Lt(ct(t.body),e),n=new ee.MathNode("mphantom",r),s=new ee.MathNode("mpadded",[n]);return s.setAttribute("height","0px"),s.setAttribute("depth","0px"),s}});oe({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=L.makeSpan(["inner"],[$e(t.body,e.withPhantom())]),n=L.makeSpan(["fix"],[]);return L.makeSpan(["mord","rlap"],[r,n],e)},mathmlBuilder:(t,e)=>{var r=Lt(ct(t.body),e),n=new ee.MathNode("mphantom",r),s=new ee.MathNode("mpadded",[n]);return s.setAttribute("width","0px"),s}});oe({type:"raisebox",names:["\\raisebox"],props:{numArgs:2,argTypes:["size","hbox"],allowedInText:!0},handler(t,e){var{parser:r}=t,n=Re(e[0],"size").value,s=e[1];return{type:"raisebox",mode:r.mode,dy:n,body:s}},htmlBuilder(t,e){var r=$e(t.body,e),n=st(t.dy,e);return L.makeVList({positionType:"shift",positionData:-n,children:[{type:"elem",elem:r}]},e)},mathmlBuilder(t,e){var r=new ee.MathNode("mpadded",[Xe(t.body,e)]),n=t.dy.number+t.dy.unit;return r.setAttribute("voffset",n),r}});oe({type:"internal",names:["\\relax"],props:{numArgs:0,allowedInText:!0,allowedInArgument:!0},handler(t){var{parser:e}=t;return{type:"internal",mode:e.mode}}});oe({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,s=r[0],i=Re(e[0],"size"),a=Re(e[1],"size");return{type:"rule",mode:n.mode,shift:s&&Re(s,"size").value,width:i.value,height:a.value}},htmlBuilder(t,e){var r=L.makeSpan(["mord","rule"],[],e),n=st(t.width,e),s=st(t.height,e),i=t.shift?st(t.shift,e):0;return r.style.borderRightWidth=ae(n),r.style.borderTopWidth=ae(s),r.style.bottom=ae(i),r.width=n,r.height=s+i,r.depth=-i,r.maxFontSize=s*1.125*e.sizeMultiplier,r},mathmlBuilder(t,e){var r=st(t.width,e),n=st(t.height,e),s=t.shift?st(t.shift,e):0,i=e.color&&e.getColor()||"black",a=new ee.MathNode("mspace");a.setAttribute("mathbackground",i),a.setAttribute("width",ae(r)),a.setAttribute("height",ae(n));var o=new ee.MathNode("mpadded",[a]);return s>=0?o.setAttribute("height",ae(s)):(o.setAttribute("height",ae(s)),o.setAttribute("depth",ae(-s))),o.setAttribute("voffset",ae(s)),o}});function Td(t,e,r){for(var n=pt(t,e,!1),s=e.sizeMultiplier/r.sizeMultiplier,i=0;i<n.length;i++){var a=n[i].classes.indexOf("sizing");a<0?Array.prototype.push.apply(n[i].classes,e.sizingClasses(r)):n[i].classes[a+1]==="reset-size"+e.size&&(n[i].classes[a+1]="reset-size"+r.size),n[i].height*=s,n[i].depth*=s}return L.makeFragment(n)}var gc=["\\tiny","\\sixptsize","\\scriptsize","\\footnotesize","\\small","\\normalsize","\\large","\\Large","\\LARGE","\\huge","\\Huge"],F5=(t,e)=>{var r=e.havingSize(t.size);return Td(t.body,r,e)};oe({type:"sizing",names:gc,props:{numArgs:0,allowedInText:!0},handler:(t,e)=>{var{breakOnTokenText:r,funcName:n,parser:s}=t,i=s.parseExpression(!1,r);return{type:"sizing",mode:s.mode,size:gc.indexOf(n)+1,body:i}},htmlBuilder:F5,mathmlBuilder:(t,e)=>{var r=e.havingSize(t.size),n=Lt(t.body,r),s=new ee.MathNode("mstyle",n);return s.setAttribute("mathsize",ae(r.sizeMultiplier)),s}});oe({type:"smash",names:["\\smash"],props:{numArgs:1,numOptionalArgs:1,allowedInText:!0},handler:(t,e,r)=>{var{parser:n}=t,s=!1,i=!1,a=r[0]&&Re(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")s=!0;else if(o==="b")i=!0;else{s=!1,i=!1;break}}else s=!0,i=!0;var d=e[0];return{type:"smash",mode:n.mode,body:d,smashHeight:s,smashDepth:i}},htmlBuilder:(t,e)=>{var r=L.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 s=0;s<r.children.length;s++)r.children[s].depth=0;var i=L.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r}]},e);return L.makeSpan(["mord"],[i],e)},mathmlBuilder:(t,e)=>{var r=new ee.MathNode("mpadded",[Xe(t.body,e)]);return t.smashHeight&&r.setAttribute("height","0px"),t.smashDepth&&r.setAttribute("depth","0px"),r}});oe({type:"sqrt",names:["\\sqrt"],props:{numArgs:1,numOptionalArgs:1},handler(t,e,r){var{parser:n}=t,s=r[0],i=e[0];return{type:"sqrt",mode:n.mode,body:i,index:s}},htmlBuilder(t,e){var r=$e(t.body,e.havingCrampedStyle());r.height===0&&(r.height=e.fontMetrics().xHeight),r=L.wrapFragment(r,e);var n=e.fontMetrics(),s=n.defaultRuleThickness,i=s;e.style.id<ke.TEXT.id&&(i=e.fontMetrics().xHeight);var a=s+i/4,o=r.height+r.depth+a+s,{span:l,ruleWidth:c,advanceWidth:d}=Dr.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=ae(d);var b=L.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 v=e.havingStyle(ke.SCRIPTSCRIPT),x=$e(t.index,v,e),y=.6*(b.height-b.depth),M=L.makeVList({positionType:"shift",positionData:-y,children:[{type:"elem",elem:x}]},e),k=L.makeSpan(["root"],[M]);return L.makeSpan(["mord","sqrt"],[k,b],e)}else return L.makeSpan(["mord","sqrt"],[b],e)},mathmlBuilder(t,e){var{body:r,index:n}=t;return n?new ee.MathNode("mroot",[Xe(r,e),Xe(n,e)]):new ee.MathNode("msqrt",[Xe(r,e)])}});var vc={display:ke.DISPLAY,text:ke.TEXT,script:ke.SCRIPT,scriptscript:ke.SCRIPTSCRIPT};oe({type:"styling",names:["\\displaystyle","\\textstyle","\\scriptstyle","\\scriptscriptstyle"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t,e){var{breakOnTokenText:r,funcName:n,parser:s}=t,i=s.parseExpression(!0,r),a=n.slice(1,n.length-5);return{type:"styling",mode:s.mode,style:a,body:i}},htmlBuilder(t,e){var r=vc[t.style],n=e.havingStyle(r).withFont("");return Td(t.body,n,e)},mathmlBuilder(t,e){var r=vc[t.style],n=e.havingStyle(r),s=Lt(t.body,n),i=new ee.MathNode("mstyle",s),a={display:["0","true"],text:["0","false"],script:["1","false"],scriptscript:["2","false"]},o=a[t.style];return i.setAttribute("scriptlevel",o[0]),i.setAttribute("displaystyle",o[1]),i}});var $5=function(e,r){var n=e.base;if(n)if(n.type==="op"){var s=n.limits&&(r.style.size===ke.DISPLAY.size||n.alwaysHandleSupSub);return s?qn:null}else if(n.type==="operatorname"){var i=n.alwaysHandleSupSub&&(r.style.size===ke.DISPLAY.size||n.limits);return i?Sd:null}else{if(n.type==="accent")return we.isCharacterBox(n.base)?xo:null;if(n.type==="horizBrace"){var a=!e.sub;return a===n.isOver?wd:null}else return null}else return null};bn({type:"supsub",htmlBuilder(t,e){var r=$5(t,e);if(r)return r(t,e);var{base:n,sup:s,sub:i}=t,a=$e(n,e),o,l,c=e.fontMetrics(),d=0,f=0,p=n&&we.isCharacterBox(n);if(s){var b=e.havingStyle(e.style.sup());o=$e(s,b,e),p||(d=a.height-b.fontMetrics().supDrop*b.sizeMultiplier/e.sizeMultiplier)}if(i){var v=e.havingStyle(e.style.sub());l=$e(i,v,e),p||(f=a.depth+v.fontMetrics().subDrop*v.sizeMultiplier/e.sizeMultiplier)}var x;e.style===ke.DISPLAY?x=c.sup1:e.style.cramped?x=c.sup3:x=c.sup2;var y=e.sizeMultiplier,M=ae(.5/c.ptPerEm/y),k=null;if(l){var T=t.base&&t.base.type==="op"&&t.base.name&&(t.base.name==="\\oiint"||t.base.name==="\\oiiint");(a instanceof Yt||T)&&(k=ae(-a.italic))}var N;if(o&&l){d=Math.max(d,x,o.depth+.25*c.xHeight),f=Math.max(f,c.sub2);var I=c.defaultRuleThickness,O=4*I;if(d-o.depth-(l.height-f)<O){f=O-(d-o.depth)+l.height;var z=.8*c.xHeight-(d-o.depth);z>0&&(d+=z,f-=z)}var W=[{type:"elem",elem:l,shift:f,marginRight:M,marginLeft:k},{type:"elem",elem:o,shift:-d,marginRight:M}];N=L.makeVList({positionType:"individualShift",children:W},e)}else if(l){f=Math.max(f,c.sub1,l.height-.8*c.xHeight);var U=[{type:"elem",elem:l,marginLeft:k,marginRight:M}];N=L.makeVList({positionType:"shift",positionData:f,children:U},e)}else if(o)d=Math.max(d,x,o.depth+.25*c.xHeight),N=L.makeVList({positionType:"shift",positionData:-d,children:[{type:"elem",elem:o,marginRight:M}]},e);else throw new Error("supsub must have either sup or sub.");var he=pa(a,"right")||"mord";return L.makeSpan([he],[a,L.makeSpan(["msupsub"],[N])],e)},mathmlBuilder(t,e){var r=!1,n,s;t.base&&t.base.type==="horizBrace"&&(s=!!t.sup,s===t.base.isOver&&(r=!0,n=t.base.isOver)),t.base&&(t.base.type==="op"||t.base.type==="operatorname")&&(t.base.parentIsSupSub=!0);var i=[Xe(t.base,e)];t.sub&&i.push(Xe(t.sub,e)),t.sup&&i.push(Xe(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===ke.DISPLAY||c&&c.type==="operatorname"&&c.alwaysHandleSupSub&&(e.style===ke.DISPLAY||c.limits)?a="munderover":a="msubsup"}else{var l=t.base;l&&l.type==="op"&&l.limits&&(e.style===ke.DISPLAY||l.alwaysHandleSupSub)||l&&l.type==="operatorname"&&l.alwaysHandleSupSub&&(l.limits||e.style===ke.DISPLAY)?a="munder":a="msub"}else{var o=t.base;o&&o.type==="op"&&o.limits&&(e.style===ke.DISPLAY||o.alwaysHandleSupSub)||o&&o.type==="operatorname"&&o.alwaysHandleSupSub&&(o.limits||e.style===ke.DISPLAY)?a="mover":a="msup"}return new ee.MathNode(a,i)}});bn({type:"atom",htmlBuilder(t,e){return L.mathsym(t.text,t.mode,e,["m"+t.family])},mathmlBuilder(t,e){var r=new ee.MathNode("mo",[Xt(t.text,t.mode)]);if(t.family==="bin"){var n=yo(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 Ad={mi:"italic",mn:"normal",mtext:"normal"};bn({type:"mathord",htmlBuilder(t,e){return L.makeOrd(t,e,"mathord")},mathmlBuilder(t,e){var r=new ee.MathNode("mi",[Xt(t.text,t.mode,e)]),n=yo(t,e)||"italic";return n!==Ad[r.type]&&r.setAttribute("mathvariant",n),r}});bn({type:"textord",htmlBuilder(t,e){return L.makeOrd(t,e,"textord")},mathmlBuilder(t,e){var r=Xt(t.text,t.mode,e),n=yo(t,e)||"normal",s;return t.mode==="text"?s=new ee.MathNode("mtext",[r]):/[0-9]/.test(t.text)?s=new ee.MathNode("mn",[r]):t.text==="\\prime"?s=new ee.MathNode("mo",[r]):s=new ee.MathNode("mi",[r]),n!==Ad[s.type]&&s.setAttribute("mathvariant",n),s}});var Oi={"\\nobreak":"nobreak","\\allowbreak":"allowbreak"},Li={" ":{},"\\ ":{},"~":{className:"nobreak"},"\\space":{},"\\nobreakspace":{className:"nobreak"}};bn({type:"spacing",htmlBuilder(t,e){if(Li.hasOwnProperty(t.text)){var r=Li[t.text].className||"";if(t.mode==="text"){var n=L.makeOrd(t,e,"textord");return n.classes.push(r),n}else return L.makeSpan(["mspace",r],[L.mathsym(t.text,t.mode,e)],e)}else{if(Oi.hasOwnProperty(t.text))return L.makeSpan(["mspace",Oi[t.text]],[],e);throw new te('Unknown type of space "'+t.text+'"')}},mathmlBuilder(t,e){var r;if(Li.hasOwnProperty(t.text))r=new ee.MathNode("mtext",[new ee.TextNode(" ")]);else{if(Oi.hasOwnProperty(t.text))return new ee.MathNode("mspace");throw new te('Unknown type of space "'+t.text+'"')}return r}});var bc=()=>{var t=new ee.MathNode("mtd",[]);return t.setAttribute("width","50%"),t};bn({type:"tag",mathmlBuilder(t,e){var r=new ee.MathNode("mtable",[new ee.MathNode("mtr",[bc(),new ee.MathNode("mtd",[Jr(t.body,e)]),bc(),new ee.MathNode("mtd",[Jr(t.tag,e)])])]);return r.setAttribute("width","100%"),r}});var yc={"\\text":void 0,"\\textrm":"textrm","\\textsf":"textsf","\\texttt":"texttt","\\textnormal":"textrm"},wc={"\\textbf":"textbf","\\textmd":"textmd"},B5={"\\textit":"textit","\\textup":"textup"},xc=(t,e)=>{var r=t.font;if(r){if(yc[r])return e.withTextFontFamily(yc[r]);if(wc[r])return e.withTextFontWeight(wc[r]);if(r==="\\emph")return e.fontShape==="textit"?e.withTextFontShape("textup"):e.withTextFontShape("textit")}else return e;return e.withTextFontShape(B5[r])};oe({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,s=e[0];return{type:"text",mode:r.mode,body:ct(s),font:n}},htmlBuilder(t,e){var r=xc(t,e),n=pt(t.body,r,!0);return L.makeSpan(["mord","text"],n,r)},mathmlBuilder(t,e){var r=xc(t,e);return Jr(t.body,r)}});oe({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=L.makeLineSpan("underline-line",e),s=e.fontMetrics().defaultRuleThickness,i=L.makeVList({positionType:"top",positionData:r.height,children:[{type:"kern",size:s},{type:"elem",elem:n},{type:"kern",size:3*s},{type:"elem",elem:r}]},e);return L.makeSpan(["mord","underline"],[i],e)},mathmlBuilder(t,e){var r=new ee.MathNode("mo",[new ee.TextNode("‾")]);r.setAttribute("stretchy","true");var n=new ee.MathNode("munder",[Xe(t.body,e),r]);return n.setAttribute("accentunder","true"),n}});oe({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,s=.5*(r.height-n-(r.depth+n));return L.makeVList({positionType:"shift",positionData:s,children:[{type:"elem",elem:r}]},e)},mathmlBuilder(t,e){return new ee.MathNode("mpadded",[Xe(t.body,e)],["vcenter"])}});oe({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=kc(t),n=[],s=e.havingStyle(e.style.text()),i=0;i<r.length;i++){var a=r[i];a==="~"&&(a="\\textasciitilde"),n.push(L.makeSymbol(a,"Typewriter-Regular",t.mode,s,["mord","texttt"]))}return L.makeSpan(["mord","text"].concat(s.sizingClasses(e)),L.tryCombineChars(n),s)},mathmlBuilder(t,e){var r=new ee.TextNode(kc(t)),n=new ee.MathNode("mtext",[r]);return n.setAttribute("mathvariant","monospace"),n}});var kc=t=>t.body.replace(/ /g,t.star?"␣":" "),Ur=K1,Ed=`[ \r
|
||
]`,P5="\\\\[a-zA-Z@]+",H5="\\\\[^\uD800-\uDFFF]",q5="("+P5+")"+Ed+"*",j5=`\\\\(
|
||
|[ \r ]+
|
||
?)[ \r ]*`,ba="[̀-ͯ]",U5=new RegExp(ba+"+$"),V5="("+Ed+"+)|"+(j5+"|")+"([!-\\[\\]-‧-豈-]"+(ba+"*")+"|[\uD800-\uDBFF][\uDC00-\uDFFF]"+(ba+"*")+"|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5"+("|"+q5)+("|"+H5+")");class Sc{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(V5,"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 Kt("EOF",new Ft(this,r,r));var n=this.tokenRegex.exec(e);if(n===null||n.index!==r)throw new te("Unexpected character: '"+e[r]+"'",new Kt(e[r],new Ft(this,r,r+1)));var s=n[6]||n[3]||(n[2]?"\\ ":" ");if(this.catcodes[s]===14){var i=e.indexOf(`
|
||
`,this.tokenRegex.lastIndex);return i===-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=i+1,this.lex()}return new Kt(s,new Ft(this,r,this.tokenRegex.lastIndex))}}class W5{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 s=0;s<this.undefStack.length;s++)delete this.undefStack[s][e];this.undefStack.length>0&&(this.undefStack[this.undefStack.length-1][e]=r)}else{var i=this.undefStack[this.undefStack.length-1];i&&!i.hasOwnProperty(e)&&(i[e]=this.current[e])}r==null?delete this.current[e]:this.current[e]=r}}var G5=md;g("\\noexpand",function(t){var e=t.popToken();return t.isExpandable(e.text)&&(e.noexpand=!0,e.treatAsRelax=!0),{tokens:[e],numArgs:0}});g("\\expandafter",function(t){var e=t.popToken();return t.expandOnce(!0),{tokens:[e],numArgs:0}});g("\\@firstoftwo",function(t){var e=t.consumeArgs(2);return{tokens:e[0],numArgs:0}});g("\\@secondoftwo",function(t){var e=t.consumeArgs(2);return{tokens:e[1],numArgs:0}});g("\\@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}});g("\\@ifstar","\\@ifnextchar *{\\@firstoftwo{#1}}");g("\\TextOrMath",function(t){var e=t.consumeArgs(2);return t.mode==="text"?{tokens:e[0],numArgs:0}:{tokens:e[1],numArgs:0}});var Tc={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};g("\\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=Tc[e.text],n==null||n>=r)throw new te("Invalid base-"+r+" digit "+e.text);for(var s;(s=Tc[t.future().text])!=null&&s<r;)n*=r,n+=s,t.popToken()}return"\\@char{"+n+"}"});var No=(t,e,r,n)=>{var s=t.consumeArg().tokens;if(s.length!==1)throw new te("\\newcommand's first argument must be a macro name");var i=s[0].text,a=t.isDefined(i);if(a&&!e)throw new te("\\newcommand{"+i+"} attempting to redefine "+(i+"; use \\renewcommand"));if(!a&&!r)throw new te("\\renewcommand{"+i+"} when command "+i+" does not yet exist; use \\newcommand");var o=0;if(s=t.consumeArg().tokens,s.length===1&&s[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),s=t.consumeArg().tokens}return a&&n||t.macros.set(i,{tokens:s,numArgs:o}),""};g("\\newcommand",t=>No(t,!1,!0,!1));g("\\renewcommand",t=>No(t,!0,!1,!1));g("\\providecommand",t=>No(t,!0,!0,!0));g("\\message",t=>{var e=t.consumeArgs(1)[0];return console.log(e.reverse().map(r=>r.text).join("")),""});g("\\errmessage",t=>{var e=t.consumeArgs(1)[0];return console.error(e.reverse().map(r=>r.text).join("")),""});g("\\show",t=>{var e=t.popToken(),r=e.text;return console.log(e,t.macros.get(r),Ur[r],Qe.math[r],Qe.text[r]),""});g("\\bgroup","{");g("\\egroup","}");g("~","\\nobreakspace");g("\\lq","`");g("\\rq","'");g("\\aa","\\r a");g("\\AA","\\r A");g("\\textcopyright","\\html@mathml{\\textcircled{c}}{\\char`©}");g("\\copyright","\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}");g("\\textregistered","\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`®}");g("ℬ","\\mathscr{B}");g("ℰ","\\mathscr{E}");g("ℱ","\\mathscr{F}");g("ℋ","\\mathscr{H}");g("ℐ","\\mathscr{I}");g("ℒ","\\mathscr{L}");g("ℳ","\\mathscr{M}");g("ℛ","\\mathscr{R}");g("ℭ","\\mathfrak{C}");g("ℌ","\\mathfrak{H}");g("ℨ","\\mathfrak{Z}");g("\\Bbbk","\\Bbb{k}");g("·","\\cdotp");g("\\llap","\\mathllap{\\textrm{#1}}");g("\\rlap","\\mathrlap{\\textrm{#1}}");g("\\clap","\\mathclap{\\textrm{#1}}");g("\\mathstrut","\\vphantom{(}");g("\\underbar","\\underline{\\text{#1}}");g("\\not",'\\html@mathml{\\mathrel{\\mathrlap\\@not}}{\\char"338}');g("\\neq","\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`≠}}");g("\\ne","\\neq");g("≠","\\neq");g("\\notin","\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`∉}}");g("∉","\\notin");g("≘","\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`≘}}");g("≙","\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`≘}}");g("≚","\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`≚}}");g("≛","\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`≛}}");g("≝","\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`≝}}");g("≞","\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`≞}}");g("≟","\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`≟}}");g("⟂","\\perp");g("‼","\\mathclose{!\\mkern-0.8mu!}");g("∌","\\notni");g("⌜","\\ulcorner");g("⌝","\\urcorner");g("⌞","\\llcorner");g("⌟","\\lrcorner");g("©","\\copyright");g("®","\\textregistered");g("️","\\textregistered");g("\\ulcorner",'\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}');g("\\urcorner",'\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}');g("\\llcorner",'\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}');g("\\lrcorner",'\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}');g("\\vdots","{\\varvdots\\rule{0pt}{15pt}}");g("⋮","\\vdots");g("\\varGamma","\\mathit{\\Gamma}");g("\\varDelta","\\mathit{\\Delta}");g("\\varTheta","\\mathit{\\Theta}");g("\\varLambda","\\mathit{\\Lambda}");g("\\varXi","\\mathit{\\Xi}");g("\\varPi","\\mathit{\\Pi}");g("\\varSigma","\\mathit{\\Sigma}");g("\\varUpsilon","\\mathit{\\Upsilon}");g("\\varPhi","\\mathit{\\Phi}");g("\\varPsi","\\mathit{\\Psi}");g("\\varOmega","\\mathit{\\Omega}");g("\\substack","\\begin{subarray}{c}#1\\end{subarray}");g("\\colon","\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax");g("\\boxed","\\fbox{$\\displaystyle{#1}$}");g("\\iff","\\DOTSB\\;\\Longleftrightarrow\\;");g("\\implies","\\DOTSB\\;\\Longrightarrow\\;");g("\\impliedby","\\DOTSB\\;\\Longleftarrow\\;");g("\\dddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ...}}{#1}}");g("\\ddddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ....}}{#1}}");var Ac={",":"\\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"};g("\\dots",function(t){var e="\\dotso",r=t.expandAfterFuture().text;return r in Ac?e=Ac[r]:(r.slice(0,4)==="\\not"||r in Qe.math&&we.contains(["bin","rel"],Qe.math[r].group))&&(e="\\dotsb"),e});var Do={")":!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};g("\\dotso",function(t){var e=t.future().text;return e in Do?"\\ldots\\,":"\\ldots"});g("\\dotsc",function(t){var e=t.future().text;return e in Do&&e!==","?"\\ldots\\,":"\\ldots"});g("\\cdots",function(t){var e=t.future().text;return e in Do?"\\@cdots\\,":"\\@cdots"});g("\\dotsb","\\cdots");g("\\dotsm","\\cdots");g("\\dotsi","\\!\\cdots");g("\\dotsx","\\ldots\\,");g("\\DOTSI","\\relax");g("\\DOTSB","\\relax");g("\\DOTSX","\\relax");g("\\tmspace","\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax");g("\\,","\\tmspace+{3mu}{.1667em}");g("\\thinspace","\\,");g("\\>","\\mskip{4mu}");g("\\:","\\tmspace+{4mu}{.2222em}");g("\\medspace","\\:");g("\\;","\\tmspace+{5mu}{.2777em}");g("\\thickspace","\\;");g("\\!","\\tmspace-{3mu}{.1667em}");g("\\negthinspace","\\!");g("\\negmedspace","\\tmspace-{4mu}{.2222em}");g("\\negthickspace","\\tmspace-{5mu}{.277em}");g("\\enspace","\\kern.5em ");g("\\enskip","\\hskip.5em\\relax");g("\\quad","\\hskip1em\\relax");g("\\qquad","\\hskip2em\\relax");g("\\tag","\\@ifstar\\tag@literal\\tag@paren");g("\\tag@paren","\\tag@literal{({#1})}");g("\\tag@literal",t=>{if(t.macros.get("\\df@tag"))throw new te("Multiple \\tag");return"\\gdef\\df@tag{\\text{#1}}"});g("\\bmod","\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}");g("\\pod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)");g("\\pmod","\\pod{{\\rm mod}\\mkern6mu#1}");g("\\mod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1");g("\\newline","\\\\\\relax");g("\\TeX","\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}");var Cd=ae(fr["Main-Regular"]["T".charCodeAt(0)][1]-.7*fr["Main-Regular"]["A".charCodeAt(0)][1]);g("\\LaTeX","\\textrm{\\html@mathml{"+("L\\kern-.36em\\raisebox{"+Cd+"}{\\scriptstyle A}")+"\\kern-.15em\\TeX}{LaTeX}}");g("\\KaTeX","\\textrm{\\html@mathml{"+("K\\kern-.17em\\raisebox{"+Cd+"}{\\scriptstyle A}")+"\\kern-.15em\\TeX}{KaTeX}}");g("\\hspace","\\@ifstar\\@hspacer\\@hspace");g("\\@hspace","\\hskip #1\\relax");g("\\@hspacer","\\rule{0pt}{0pt}\\hskip #1\\relax");g("\\ordinarycolon",":");g("\\vcentcolon","\\mathrel{\\mathop\\ordinarycolon}");g("\\dblcolon",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}');g("\\coloneqq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}');g("\\Coloneqq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}');g("\\coloneq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}');g("\\Coloneq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}');g("\\eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}');g("\\Eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}');g("\\eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}');g("\\Eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}');g("\\colonapprox",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}');g("\\Colonapprox",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}');g("\\colonsim",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}');g("\\Colonsim",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}');g("∷","\\dblcolon");g("∹","\\eqcolon");g("≔","\\coloneqq");g("≕","\\eqqcolon");g("⩴","\\Coloneqq");g("\\ratio","\\vcentcolon");g("\\coloncolon","\\dblcolon");g("\\colonequals","\\coloneqq");g("\\coloncolonequals","\\Coloneqq");g("\\equalscolon","\\eqqcolon");g("\\equalscoloncolon","\\Eqqcolon");g("\\colonminus","\\coloneq");g("\\coloncolonminus","\\Coloneq");g("\\minuscolon","\\eqcolon");g("\\minuscoloncolon","\\Eqcolon");g("\\coloncolonapprox","\\Colonapprox");g("\\coloncolonsim","\\Colonsim");g("\\simcolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}");g("\\simcoloncolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}");g("\\approxcolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}");g("\\approxcoloncolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}");g("\\notni","\\html@mathml{\\not\\ni}{\\mathrel{\\char`∌}}");g("\\limsup","\\DOTSB\\operatorname*{lim\\,sup}");g("\\liminf","\\DOTSB\\operatorname*{lim\\,inf}");g("\\injlim","\\DOTSB\\operatorname*{inj\\,lim}");g("\\projlim","\\DOTSB\\operatorname*{proj\\,lim}");g("\\varlimsup","\\DOTSB\\operatorname*{\\overline{lim}}");g("\\varliminf","\\DOTSB\\operatorname*{\\underline{lim}}");g("\\varinjlim","\\DOTSB\\operatorname*{\\underrightarrow{lim}}");g("\\varprojlim","\\DOTSB\\operatorname*{\\underleftarrow{lim}}");g("\\gvertneqq","\\html@mathml{\\@gvertneqq}{≩}");g("\\lvertneqq","\\html@mathml{\\@lvertneqq}{≨}");g("\\ngeqq","\\html@mathml{\\@ngeqq}{≱}");g("\\ngeqslant","\\html@mathml{\\@ngeqslant}{≱}");g("\\nleqq","\\html@mathml{\\@nleqq}{≰}");g("\\nleqslant","\\html@mathml{\\@nleqslant}{≰}");g("\\nshortmid","\\html@mathml{\\@nshortmid}{∤}");g("\\nshortparallel","\\html@mathml{\\@nshortparallel}{∦}");g("\\nsubseteqq","\\html@mathml{\\@nsubseteqq}{⊈}");g("\\nsupseteqq","\\html@mathml{\\@nsupseteqq}{⊉}");g("\\varsubsetneq","\\html@mathml{\\@varsubsetneq}{⊊}");g("\\varsubsetneqq","\\html@mathml{\\@varsubsetneqq}{⫋}");g("\\varsupsetneq","\\html@mathml{\\@varsupsetneq}{⊋}");g("\\varsupsetneqq","\\html@mathml{\\@varsupsetneqq}{⫌}");g("\\imath","\\html@mathml{\\@imath}{ı}");g("\\jmath","\\html@mathml{\\@jmath}{ȷ}");g("\\llbracket","\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`⟦}}");g("\\rrbracket","\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`⟧}}");g("⟦","\\llbracket");g("⟧","\\rrbracket");g("\\lBrace","\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`⦃}}");g("\\rBrace","\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`⦄}}");g("⦃","\\lBrace");g("⦄","\\rBrace");g("\\minuso","\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`⦵}}");g("⦵","\\minuso");g("\\darr","\\downarrow");g("\\dArr","\\Downarrow");g("\\Darr","\\Downarrow");g("\\lang","\\langle");g("\\rang","\\rangle");g("\\uarr","\\uparrow");g("\\uArr","\\Uparrow");g("\\Uarr","\\Uparrow");g("\\N","\\mathbb{N}");g("\\R","\\mathbb{R}");g("\\Z","\\mathbb{Z}");g("\\alef","\\aleph");g("\\alefsym","\\aleph");g("\\Alpha","\\mathrm{A}");g("\\Beta","\\mathrm{B}");g("\\bull","\\bullet");g("\\Chi","\\mathrm{X}");g("\\clubs","\\clubsuit");g("\\cnums","\\mathbb{C}");g("\\Complex","\\mathbb{C}");g("\\Dagger","\\ddagger");g("\\diamonds","\\diamondsuit");g("\\empty","\\emptyset");g("\\Epsilon","\\mathrm{E}");g("\\Eta","\\mathrm{H}");g("\\exist","\\exists");g("\\harr","\\leftrightarrow");g("\\hArr","\\Leftrightarrow");g("\\Harr","\\Leftrightarrow");g("\\hearts","\\heartsuit");g("\\image","\\Im");g("\\infin","\\infty");g("\\Iota","\\mathrm{I}");g("\\isin","\\in");g("\\Kappa","\\mathrm{K}");g("\\larr","\\leftarrow");g("\\lArr","\\Leftarrow");g("\\Larr","\\Leftarrow");g("\\lrarr","\\leftrightarrow");g("\\lrArr","\\Leftrightarrow");g("\\Lrarr","\\Leftrightarrow");g("\\Mu","\\mathrm{M}");g("\\natnums","\\mathbb{N}");g("\\Nu","\\mathrm{N}");g("\\Omicron","\\mathrm{O}");g("\\plusmn","\\pm");g("\\rarr","\\rightarrow");g("\\rArr","\\Rightarrow");g("\\Rarr","\\Rightarrow");g("\\real","\\Re");g("\\reals","\\mathbb{R}");g("\\Reals","\\mathbb{R}");g("\\Rho","\\mathrm{P}");g("\\sdot","\\cdot");g("\\sect","\\S");g("\\spades","\\spadesuit");g("\\sub","\\subset");g("\\sube","\\subseteq");g("\\supe","\\supseteq");g("\\Tau","\\mathrm{T}");g("\\thetasym","\\vartheta");g("\\weierp","\\wp");g("\\Zeta","\\mathrm{Z}");g("\\argmin","\\DOTSB\\operatorname*{arg\\,min}");g("\\argmax","\\DOTSB\\operatorname*{arg\\,max}");g("\\plim","\\DOTSB\\mathop{\\operatorname{plim}}\\limits");g("\\bra","\\mathinner{\\langle{#1}|}");g("\\ket","\\mathinner{|{#1}\\rangle}");g("\\braket","\\mathinner{\\langle{#1}\\rangle}");g("\\Bra","\\left\\langle#1\\right|");g("\\Ket","\\left|#1\\right\\rangle");var Md=t=>e=>{var r=e.consumeArg().tokens,n=e.consumeArg().tokens,s=e.consumeArg().tokens,i=e.consumeArg().tokens,a=e.macros.get("|"),o=e.macros.get("\\|");e.macros.beginGroup();var l=f=>p=>{t&&(p.macros.set("|",a),s.length&&p.macros.set("\\|",o));var b=f;if(!f&&s.length){var v=p.future();v.text==="|"&&(p.popToken(),b=!0)}return{tokens:b?s:n,numArgs:0}};e.macros.set("|",l(!1)),s.length&&e.macros.set("\\|",l(!0));var c=e.consumeArg().tokens,d=e.expandTokens([...i,...c,...r]);return e.macros.endGroup(),{tokens:d.reverse(),numArgs:0}};g("\\bra@ket",Md(!1));g("\\bra@set",Md(!0));g("\\Braket","\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}");g("\\Set","\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}");g("\\set","\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}");g("\\angln","{\\angl n}");g("\\blue","\\textcolor{##6495ed}{#1}");g("\\orange","\\textcolor{##ffa500}{#1}");g("\\pink","\\textcolor{##ff00af}{#1}");g("\\red","\\textcolor{##df0030}{#1}");g("\\green","\\textcolor{##28ae7b}{#1}");g("\\gray","\\textcolor{gray}{#1}");g("\\purple","\\textcolor{##9d38bd}{#1}");g("\\blueA","\\textcolor{##ccfaff}{#1}");g("\\blueB","\\textcolor{##80f6ff}{#1}");g("\\blueC","\\textcolor{##63d9ea}{#1}");g("\\blueD","\\textcolor{##11accd}{#1}");g("\\blueE","\\textcolor{##0c7f99}{#1}");g("\\tealA","\\textcolor{##94fff5}{#1}");g("\\tealB","\\textcolor{##26edd5}{#1}");g("\\tealC","\\textcolor{##01d1c1}{#1}");g("\\tealD","\\textcolor{##01a995}{#1}");g("\\tealE","\\textcolor{##208170}{#1}");g("\\greenA","\\textcolor{##b6ffb0}{#1}");g("\\greenB","\\textcolor{##8af281}{#1}");g("\\greenC","\\textcolor{##74cf70}{#1}");g("\\greenD","\\textcolor{##1fab54}{#1}");g("\\greenE","\\textcolor{##0d923f}{#1}");g("\\goldA","\\textcolor{##ffd0a9}{#1}");g("\\goldB","\\textcolor{##ffbb71}{#1}");g("\\goldC","\\textcolor{##ff9c39}{#1}");g("\\goldD","\\textcolor{##e07d10}{#1}");g("\\goldE","\\textcolor{##a75a05}{#1}");g("\\redA","\\textcolor{##fca9a9}{#1}");g("\\redB","\\textcolor{##ff8482}{#1}");g("\\redC","\\textcolor{##f9685d}{#1}");g("\\redD","\\textcolor{##e84d39}{#1}");g("\\redE","\\textcolor{##bc2612}{#1}");g("\\maroonA","\\textcolor{##ffbde0}{#1}");g("\\maroonB","\\textcolor{##ff92c6}{#1}");g("\\maroonC","\\textcolor{##ed5fa6}{#1}");g("\\maroonD","\\textcolor{##ca337c}{#1}");g("\\maroonE","\\textcolor{##9e034e}{#1}");g("\\purpleA","\\textcolor{##ddd7ff}{#1}");g("\\purpleB","\\textcolor{##c6b9fc}{#1}");g("\\purpleC","\\textcolor{##aa87ff}{#1}");g("\\purpleD","\\textcolor{##7854ab}{#1}");g("\\purpleE","\\textcolor{##543b78}{#1}");g("\\mintA","\\textcolor{##f5f9e8}{#1}");g("\\mintB","\\textcolor{##edf2df}{#1}");g("\\mintC","\\textcolor{##e0e5cc}{#1}");g("\\grayA","\\textcolor{##f6f7f7}{#1}");g("\\grayB","\\textcolor{##f0f1f2}{#1}");g("\\grayC","\\textcolor{##e3e5e6}{#1}");g("\\grayD","\\textcolor{##d6d8da}{#1}");g("\\grayE","\\textcolor{##babec2}{#1}");g("\\grayF","\\textcolor{##888d93}{#1}");g("\\grayG","\\textcolor{##626569}{#1}");g("\\grayH","\\textcolor{##3b3e40}{#1}");g("\\grayI","\\textcolor{##21242c}{#1}");g("\\kaBlue","\\textcolor{##314453}{#1}");g("\\kaGreen","\\textcolor{##71B307}{#1}");var Nd={"^":!0,_:!0,"\\limits":!0,"\\nolimits":!0};class K5{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 W5(G5,r.macros),this.mode=n,this.stack=[]}feed(e){this.lexer=new Sc(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,s;if(e){if(this.consumeSpaces(),this.future().text!=="[")return null;r=this.popToken(),{tokens:s,end:n}=this.consumeArg(["]"])}else({tokens:s,start:r,end:n}=this.consumeArg());return this.pushToken(new Kt("EOF",n.loc)),this.pushTokens(s),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 s=this.future(),i,a=0,o=0;do{if(i=this.popToken(),r.push(i),i.text==="{")++a;else if(i.text==="}"){if(--a,a===-1)throw new te("Extra }",i)}else if(i.text==="EOF")throw new te("Unexpected end of input in a macro argument, expected '"+(e&&n?e[o]:"}")+"'",i);if(e&&n)if((a===0||a===1&&e[o]==="{")&&i.text===e[o]){if(++o,o===e.length){r.splice(-o,o);break}}else o=0}while(a!==0||n);return s.text==="{"&&r[r.length-1].text==="}"&&(r.pop(),r.shift()),r.reverse(),{tokens:r,start:s,end:i}}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],s=0;s<n.length;s++){var i=this.popToken();if(n[s]!==i.text)throw new te("Use of the macro doesn't match its definition",i)}}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,s=r.noexpand?null:this._getExpansion(n);if(s==null||e&&s.unexpandable){if(e&&s==null&&n[0]==="\\"&&!this.isDefined(n))throw new te("Undefined control sequence: "+n);return this.pushToken(r),!1}this.countExpansion(1);var i=s.tokens,a=this.consumeArgs(s.numArgs,s.delimiters);if(s.numArgs){i=i.slice();for(var o=i.length-1;o>=0;--o){var l=i[o];if(l.text==="#"){if(o===0)throw new te("Incomplete placeholder at end of macro body",l);if(l=i[--o],l.text==="#")i.splice(o+1,1);else if(/^[1-9]$/.test(l.text))i.splice(o,2,...a[+l.text-1]);else throw new te("Not a valid argument number",l)}}}return this.pushTokens(i),i.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 Kt(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 s=this.stack.pop();s.treatAsRelax&&(s.noexpand=!1,s.treatAsRelax=!1),r.push(s)}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 s=typeof r=="function"?r(this):r;if(typeof s=="string"){var i=0;if(s.indexOf("#")!==-1)for(var a=s.replace(/##/g,"");a.indexOf("#"+(i+1))!==-1;)++i;for(var o=new Sc(s,this.settings),l=[],c=o.lex();c.text!=="EOF";)l.push(c),c=o.lex();l.reverse();var d={tokens:l,numArgs:i};return d}return s}isDefined(e){return this.macros.has(e)||Ur.hasOwnProperty(e)||Qe.math.hasOwnProperty(e)||Qe.text.hasOwnProperty(e)||Nd.hasOwnProperty(e)}isExpandable(e){var r=this.macros.get(e);return r!=null?typeof r=="string"||typeof r=="function"||!r.unexpandable:Ur.hasOwnProperty(e)&&!Ur[e].primitive}}var Ec=/^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/,W0=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","ᵝ":"β","ᵞ":"γ","ᵟ":"δ","ᵠ":"ϕ","ᵡ":"χ","ᶿ":"θ"}),zi={"́":{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"}},Cc={á:"á",à:"à",ä:"ä",ǟ:"ǟ",ã:"ã",ā:"ā",ă:"ă",ắ:"ắ",ằ:"ằ",ẵ:"ẵ",ǎ:"ǎ",â:"â",ấ:"ấ",ầ:"ầ",ẫ:"ẫ",ȧ:"ȧ",ǡ:"ǡ",å:"å",ǻ:"ǻ",ḃ:"ḃ",ć:"ć",ḉ:"ḉ",č:"č",ĉ:"ĉ",ċ:"ċ",ç:"ç",ď:"ď",ḋ:"ḋ",ḑ:"ḑ",é:"é",è:"è",ë:"ë",ẽ:"ẽ",ē:"ē",ḗ:"ḗ",ḕ:"ḕ",ĕ:"ĕ",ḝ:"ḝ",ě:"ě",ê:"ê",ế:"ế",ề:"ề",ễ:"ễ",ė:"ė",ȩ:"ȩ",ḟ:"ḟ",ǵ:"ǵ",ḡ:"ḡ",ğ:"ğ",ǧ:"ǧ",ĝ:"ĝ",ġ:"ġ",ģ:"ģ",ḧ:"ḧ",ȟ:"ȟ",ĥ:"ĥ",ḣ:"ḣ",ḩ:"ḩ",í:"í",ì:"ì",ï:"ï",ḯ:"ḯ",ĩ:"ĩ",ī:"ī",ĭ:"ĭ",ǐ:"ǐ",î:"î",ǰ:"ǰ",ĵ:"ĵ",ḱ:"ḱ",ǩ:"ǩ",ķ:"ķ",ĺ:"ĺ",ľ:"ľ",ļ:"ļ",ḿ:"ḿ",ṁ:"ṁ",ń:"ń",ǹ:"ǹ",ñ:"ñ",ň:"ň",ṅ:"ṅ",ņ:"ņ",ó:"ó",ò:"ò",ö:"ö",ȫ:"ȫ",õ:"õ",ṍ:"ṍ",ṏ:"ṏ",ȭ:"ȭ",ō:"ō",ṓ:"ṓ",ṑ:"ṑ",ŏ:"ŏ",ǒ:"ǒ",ô:"ô",ố:"ố",ồ:"ồ",ỗ:"ỗ",ȯ:"ȯ",ȱ:"ȱ",ő:"ő",ṕ:"ṕ",ṗ:"ṗ",ŕ:"ŕ",ř:"ř",ṙ:"ṙ",ŗ:"ŗ",ś:"ś",ṥ:"ṥ",š:"š",ṧ:"ṧ",ŝ:"ŝ",ṡ:"ṡ",ş:"ş",ẗ:"ẗ",ť:"ť",ṫ:"ṫ",ţ:"ţ",ú:"ú",ù:"ù",ü:"ü",ǘ:"ǘ",ǜ:"ǜ",ǖ:"ǖ",ǚ:"ǚ",ũ:"ũ",ṹ:"ṹ",ū:"ū",ṻ:"ṻ",ŭ:"ŭ",ǔ:"ǔ",û:"û",ů:"ů",ű:"ű",ṽ:"ṽ",ẃ:"ẃ",ẁ:"ẁ",ẅ:"ẅ",ŵ:"ŵ",ẇ:"ẇ",ẘ:"ẘ",ẍ:"ẍ",ẋ:"ẋ",ý:"ý",ỳ:"ỳ",ÿ:"ÿ",ỹ:"ỹ",ȳ:"ȳ",ŷ:"ŷ",ẏ:"ẏ",ẙ:"ẙ",ź:"ź",ž:"ž",ẑ:"ẑ",ż:"ż",Á:"Á",À:"À",Ä:"Ä",Ǟ:"Ǟ",Ã:"Ã",Ā:"Ā",Ă:"Ă",Ắ:"Ắ",Ằ:"Ằ",Ẵ:"Ẵ",Ǎ:"Ǎ",Â:"Â",Ấ:"Ấ",Ầ:"Ầ",Ẫ:"Ẫ",Ȧ:"Ȧ",Ǡ:"Ǡ",Å:"Å",Ǻ:"Ǻ",Ḃ:"Ḃ",Ć:"Ć",Ḉ:"Ḉ",Č:"Č",Ĉ:"Ĉ",Ċ:"Ċ",Ç:"Ç",Ď:"Ď",Ḋ:"Ḋ",Ḑ:"Ḑ",É:"É",È:"È",Ë:"Ë",Ẽ:"Ẽ",Ē:"Ē",Ḗ:"Ḗ",Ḕ:"Ḕ",Ĕ:"Ĕ",Ḝ:"Ḝ",Ě:"Ě",Ê:"Ê",Ế:"Ế",Ề:"Ề",Ễ:"Ễ",Ė:"Ė",Ȩ:"Ȩ",Ḟ:"Ḟ",Ǵ:"Ǵ",Ḡ:"Ḡ",Ğ:"Ğ",Ǧ:"Ǧ",Ĝ:"Ĝ",Ġ:"Ġ",Ģ:"Ģ",Ḧ:"Ḧ",Ȟ:"Ȟ",Ĥ:"Ĥ",Ḣ:"Ḣ",Ḩ:"Ḩ",Í:"Í",Ì:"Ì",Ï:"Ï",Ḯ:"Ḯ",Ĩ:"Ĩ",Ī:"Ī",Ĭ:"Ĭ",Ǐ:"Ǐ",Î:"Î",İ:"İ",Ĵ:"Ĵ",Ḱ:"Ḱ",Ǩ:"Ǩ",Ķ:"Ķ",Ĺ:"Ĺ",Ľ:"Ľ",Ļ:"Ļ",Ḿ:"Ḿ",Ṁ:"Ṁ",Ń:"Ń",Ǹ:"Ǹ",Ñ:"Ñ",Ň:"Ň",Ṅ:"Ṅ",Ņ:"Ņ",Ó:"Ó",Ò:"Ò",Ö:"Ö",Ȫ:"Ȫ",Õ:"Õ",Ṍ:"Ṍ",Ṏ:"Ṏ",Ȭ:"Ȭ",Ō:"Ō",Ṓ:"Ṓ",Ṑ:"Ṑ",Ŏ:"Ŏ",Ǒ:"Ǒ",Ô:"Ô",Ố:"Ố",Ồ:"Ồ",Ỗ:"Ỗ",Ȯ:"Ȯ",Ȱ:"Ȱ",Ő:"Ő",Ṕ:"Ṕ",Ṗ:"Ṗ",Ŕ:"Ŕ",Ř:"Ř",Ṙ:"Ṙ",Ŗ:"Ŗ",Ś:"Ś",Ṥ:"Ṥ",Š:"Š",Ṧ:"Ṧ",Ŝ:"Ŝ",Ṡ:"Ṡ",Ş:"Ş",Ť:"Ť",Ṫ:"Ṫ",Ţ:"Ţ",Ú:"Ú",Ù:"Ù",Ü:"Ü",Ǘ:"Ǘ",Ǜ:"Ǜ",Ǖ:"Ǖ",Ǚ:"Ǚ",Ũ:"Ũ",Ṹ:"Ṹ",Ū:"Ū",Ṻ:"Ṻ",Ŭ:"Ŭ",Ǔ:"Ǔ",Û:"Û",Ů:"Ů",Ű:"Ű",Ṽ:"Ṽ",Ẃ:"Ẃ",Ẁ:"Ẁ",Ẅ:"Ẅ",Ŵ:"Ŵ",Ẇ:"Ẇ",Ẍ:"Ẍ",Ẋ:"Ẋ",Ý:"Ý",Ỳ:"Ỳ",Ÿ:"Ÿ",Ỹ:"Ỹ",Ȳ:"Ȳ",Ŷ:"Ŷ",Ẏ:"Ẏ",Ź:"Ź",Ž:"Ž",Ẑ:"Ẑ",Ż:"Ż",ά:"ά",ὰ:"ὰ",ᾱ:"ᾱ",ᾰ:"ᾰ",έ:"έ",ὲ:"ὲ",ή:"ή",ὴ:"ὴ",ί:"ί",ὶ:"ὶ",ϊ:"ϊ",ΐ:"ΐ",ῒ:"ῒ",ῑ:"ῑ",ῐ:"ῐ",ό:"ό",ὸ:"ὸ",ύ:"ύ",ὺ:"ὺ",ϋ:"ϋ",ΰ:"ΰ",ῢ:"ῢ",ῡ:"ῡ",ῠ:"ῠ",ώ:"ώ",ὼ:"ὼ",Ύ:"Ύ",Ὺ:"Ὺ",Ϋ:"Ϋ",Ῡ:"Ῡ",Ῠ:"Ῠ",Ώ:"Ώ",Ὼ:"Ὼ"};class si{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 K5(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 Kt("}")),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 s=this.fetch();if(si.endOfExpression.indexOf(s.text)!==-1||r&&s.text===r||e&&Ur[s.text]&&Ur[s.text].infix)break;var i=this.parseAtom(r);if(i){if(i.type==="internal")continue}else break;n.push(i)}return this.mode==="text"&&this.formLigatures(n),this.handleInfixNodes(n)}handleInfixNodes(e){for(var r=-1,n,s=0;s<e.length;s++)if(e[s].type==="infix"){if(r!==-1)throw new te("only one infix operator per group",e[s].token);r=s,n=e[s].replaceWith}if(r!==-1&&n){var i,a,o=e.slice(0,r),l=e.slice(r+1);o.length===1&&o[0].type==="ordgroup"?i=o[0]:i={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,[i,e[r],a],[]):c=this.callFunction(n,[i,a],[]),[c]}else return e}handleSupSubscript(e){var r=this.fetch(),n=r.text;this.consume(),this.consumeSpaces();var s;do{var i;s=this.parseGroup(e)}while(((i=s)==null?void 0:i.type)==="internal");if(!s)throw new te("Expected group after '"+n+"'",r);return s}formatUnsupportedCmd(e){for(var r=[],n=0;n<e.length;n++)r.push({type:"textord",mode:"text",text:e[n]});var s={type:"text",mode:this.mode,body:r},i={type:"color",mode:this.mode,color:this.settings.errorColor,body:[s]};return i}parseAtom(e){var r=this.parseGroup("atom",e);if((r==null?void 0:r.type)==="internal"||this.mode==="text")return r;for(var n,s;;){this.consumeSpaces();var i=this.fetch();if(i.text==="\\limits"||i.text==="\\nolimits"){if(r&&r.type==="op"){var a=i.text==="\\limits";r.limits=a,r.alwaysHandleSupSub=!0}else if(r&&r.type==="operatorname")r.alwaysHandleSupSub&&(r.limits=i.text==="\\limits");else throw new te("Limit controls must follow a math operator",i);this.consume()}else if(i.text==="^"){if(n)throw new te("Double superscript",i);n=this.handleSupSubscript("superscript")}else if(i.text==="_"){if(s)throw new te("Double subscript",i);s=this.handleSupSubscript("subscript")}else if(i.text==="'"){if(n)throw new te("Double superscript",i);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(W0[i.text]){var c=Ec.test(i.text),d=[];for(d.push(new Kt(W0[i.text])),this.consume();;){var f=this.fetch().text;if(!W0[f]||Ec.test(f)!==c)break;d.unshift(new Kt(W0[f])),this.consume()}var p=this.subparse(d);c?s={type:"ordgroup",mode:"math",body:p}:n={type:"ordgroup",mode:"math",body:p}}else break}return n||s?{type:"supsub",mode:this.mode,base:r,sup:n,sub:s}:r}parseFunction(e,r){var n=this.fetch(),s=n.text,i=Ur[s];if(!i)return null;if(this.consume(),r&&r!=="atom"&&!i.allowedInArgument)throw new te("Got function '"+s+"' with no arguments"+(r?" as "+r:""),n);if(this.mode==="text"&&!i.allowedInText)throw new te("Can't use function '"+s+"' in text mode",n);if(this.mode==="math"&&i.allowedInMath===!1)throw new te("Can't use function '"+s+"' in math mode",n);var{args:a,optArgs:o}=this.parseArguments(s,i);return this.callFunction(s,a,o,n,e)}callFunction(e,r,n,s,i){var a={funcName:e,parser:this,token:s,breakOnTokenText:i},o=Ur[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 s=[],i=[],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&&i[0]==null)&&(o="primitive");var c=this.parseGroupOfType("argument to '"+e+"'",o,l);if(l)i.push(c);else if(c!=null)s.push(c);else throw new te("Null argument, please report this as a bug")}return{args:s,optArgs:i}}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 s=this.parseArgumentGroup(n,"text");return s!=null?{type:"styling",mode:s.mode,body:[s],style:"text"}:null}case"raw":{var i=this.parseStringGroup("raw",n);return i!=null?{type:"raw",mode:"text",string:i.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 s="",i;(i=this.fetch()).text!=="EOF";)s+=i.text,this.consume();return this.consume(),n.text=s,n}parseRegexGroup(e,r){for(var n=this.fetch(),s=n,i="",a;(a=this.fetch()).text!=="EOF"&&e.test(i+a.text);)s=a,i+=s.text,this.consume();if(i==="")throw new te("Invalid "+r+": '"+n.text+"'",n);return n.range(s,i)}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 s=n[0];return/^[0-9a-f]{6}$/i.test(s)&&(s="#"+s),{type:"color-token",mode:this.mode,color:s}}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 s=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(r.text);if(!s)throw new te("Invalid size: '"+r.text+"'",r);var i={number:+(s[1]+s[2]),unit:s[3]};if(!B1(i))throw new te("Invalid unit: '"+i.unit+"'",r);return{type:"size",mode:this.mode,value:i,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 s=this.mode;r&&this.switchMode(r),this.gullet.beginGroup();var i=this.parseExpression(!1,"EOF");this.expect("EOF"),this.gullet.endGroup();var a={type:"ordgroup",mode:this.mode,loc:n.loc,body:i};return r&&this.switchMode(s),a}parseGroup(e,r){var n=this.fetch(),s=n.text,i;if(s==="{"||s==="\\begingroup"){this.consume();var a=s==="{"?"}":"\\endgroup";this.gullet.beginGroup();var o=this.parseExpression(!1,a),l=this.fetch();this.expect(a),this.gullet.endGroup(),i={type:"ordgroup",mode:this.mode,loc:Ft.range(n,l),body:o,semisimple:s==="\\begingroup"||void 0}}else if(i=this.parseFunction(r,e)||this.parseSymbol(),i==null&&s[0]==="\\"&&!Nd.hasOwnProperty(s)){if(this.settings.throwOnError)throw new te("Undefined control sequence: "+s,n);i=this.formatUnsupportedCmd(s),this.consume()}return i}formLigatures(e){for(var r=e.length-1,n=0;n<r;++n){var s=e[n],i=s.text;i==="-"&&e[n+1].text==="-"&&(n+1<r&&e[n+2].text==="-"?(e.splice(n,3,{type:"textord",mode:"text",loc:Ft.range(s,e[n+2]),text:"---"}),r-=2):(e.splice(n,2,{type:"textord",mode:"text",loc:Ft.range(s,e[n+1]),text:"--"}),r-=1)),(i==="'"||i==="`")&&e[n+1].text===i&&(e.splice(n,2,{type:"textord",mode:"text",loc:Ft.range(s,e[n+1]),text:i+i}),r-=1)}}parseSymbol(){var e=this.fetch(),r=e.text;if(/^\\verb[^a-zA-Z]/.test(r)){this.consume();var n=r.slice(5),s=n.charAt(0)==="*";if(s&&(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:s}}Cc.hasOwnProperty(r[0])&&!Qe[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=Cc[r[0]]+r.slice(1));var i=U5.exec(r);i&&(r=r.substring(0,i.index),r==="i"?r="ı":r==="j"&&(r="ȷ"));var a;if(Qe[this.mode][r]){this.settings.strict&&this.mode==="math"&&fa.indexOf(r)>=0&&this.settings.reportNonstrict("unicodeTextInMathMode",'Latin-1/Unicode text character "'+r[0]+'" used in math mode',e);var o=Qe[this.mode][r].group,l=Ft.range(e),c;if(z6.hasOwnProperty(o)){var d=o;c={type:"atom",mode:this.mode,family:d,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&&($1(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:Ft.range(e),text:r};else return null;if(this.consume(),i)for(var f=0;f<i[0].length;f++){var p=i[0][f];if(!zi[p])throw new te("Unknown accent ' "+p+"'",e);var b=zi[p][this.mode]||zi[p].text;if(!b)throw new te("Accent "+p+" unsupported in "+this.mode+" mode",e);a={type:"accent",mode:this.mode,loc:Ft.range(e),label:b,isStretchy:!1,isShifty:!0,base:a}}return a}}si.endOfExpression=["}","\\endgroup","\\end","\\right","&"];var Ro=function(e,r){if(!(typeof e=="string"||e instanceof String))throw new TypeError("KaTeX can only parse string typed expression");var n=new si(e,r);delete n.gullet.macros.current["\\df@tag"];var s=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");s=[{type:"tag",mode:"text",body:s,tag:n.subparse([new Kt("\\df@tag")])}]}return s},Dd=function(e,r,n){r.textContent="";var s=Io(e,n).toNode();r.appendChild(s)};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."),Dd=function(){throw new te("KaTeX doesn't work in quirks mode.")});var Y5=function(e,r){var n=Io(e,r).toMarkup();return n},X5=function(e,r){var n=new fo(r);return Ro(e,n)},Rd=function(e,r,n){if(n.throwOnError||!(e instanceof te))throw e;var s=L.makeSpan(["katex-error"],[new Yt(r)]);return s.setAttribute("title",e.toString()),s.setAttribute("style","color:"+n.errorColor),s},Io=function(e,r){var n=new fo(r);try{var s=Ro(e,n);return i5(s,e,n)}catch(i){return Rd(i,e,n)}},J5=function(e,r){var n=new fo(r);try{var s=Ro(e,n);return a5(s,e,n)}catch(i){return Rd(i,e,n)}},Z5="0.16.22",Q5={Span:A0,Anchor:go,SymbolNode:Yt,SvgNode:_r,PathNode:Xr,LineNode:ha},Mc={version:Z5,render:Dd,renderToString:Y5,ParseError:te,SETTINGS_SCHEMA:is,__parse:X5,__renderToDomTree:Io,__renderToHTMLTree:J5,__setFontMetrics:M6,__defineSymbol:u,__defineFunction:oe,__defineMacro:g,__domTree:Q5};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:/[;[\]()`,.]/};qe.setOptions({breaks:!0,gfm:!0,tables:!0,sanitize:!1});const ya=t=>{if(!t||typeof t!="string")return"";try{const e=e7(t),r=qe.parse(e);return t7(r)}catch(e){return console.error("Markdown渲染失败:",e),`<div class="markdown-error">渲染失败: ${e.message}</div>`}},e7=t=>t.replace(/\$\$([\s\S]*?)\$\$/g,(e,r)=>{try{return`<div class="math-block">${Mc.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">${Mc.renderToString(r.trim(),{displayMode:!1,throwOnError:!1})}</span>`}catch(n){return console.warn("数学公式渲染失败:",n),`<span class="math-error">数学公式错误: ${r}</span>`}return e}),t7=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(s=>{const i=s.className.match(/language-(\w+)/);if(i)try{s.innerHTML=Gl.highlight(s.textContent,Gl.languages[i[1]],i[1])}catch(a){console.warn("语法高亮失败:",a)}}),r.innerHTML},r7=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 s=(t.match(/\|/g)||[]).length,i=s>=6;return r&&n||r&&i||r&&s>=4},n7=t=>!t||typeof t!="string"?!1:r7(t)?!0:[/#{1,6}\s+/,/\*\*.*?\*\*/,/\*.*?\*/,/`.*?`/,/```[\s\S]*?```/,/^\s*[-*+]\s+/m,/^\s*\d+\.\s+/m,/\[.*?\]\(.*?\)/,/!\[.*?\]\(.*?\)/,/\$\$.*?\$\$/,/\$.*?\$/].some(r=>r.test(t)),G0=t=>!t||typeof t!="string"?t||"":n7(t)||t.includes("|")?ya(t):t;const _o=(t,e)=>{const r=t.__vccOpts||t;for(const[n,s]of e)r[n]=s;return r},s7={class:"mindmap-container"},i7={key:0,class:"welcome-page"},a7={class:"ai-input-content"},o7=["disabled","onKeydown"],l7={class:"ai-input-actions"},c7=["disabled"],u7=["disabled"],d7={key:0},h7={key:1},f7={key:3,class:"save-controls"},p7={__name:"MindMap",setup(t,{expose:e}){const r=ze(null),n=ze(null),s=ze(null),i=ze({}),a=ze({}),o=ze(null),l=ze(1),c=ze(!0),d=ze(!1),f=ze(!1),p=ze(null),b=ze(""),v=ze(!1);ze(new Map),ze(!1),ze({x:0,y:0}),ze(null);const x=()=>{c.value=!0,r.value&&(r.value.innerHTML=""),n.value&&(n.value=null)},y=()=>{c.value=!1},M=()=>{c.value=!1},k=()=>{if(!n.value||!r.value)return null;try{const w=r.value.querySelector(".map-canvas");if(w){const E=w.style.transform,_=n.value.scaleVal||1;return console.log("📍 保存位置:",{transform:E,scaleVal:_}),{transform:E,scaleVal:_}}}catch(w){console.warn("保存位置失败:",w)}return null},T=w=>{if(!(!w||!r.value||!n.value))try{const E=r.value.querySelector(".map-canvas");E&&w.transform&&(E.style.setProperty("transform",w.transform,"important"),w.scaleVal&&n.value.scaleVal!==w.scaleVal&&(n.value.scaleVal=w.scaleVal),E.style.setProperty("transform-origin","center center","important"),console.log("📍 恢复位置:",{transform:w.transform,scaleVal:w.scaleVal}))}catch(E){console.warn("恢复位置失败:",E)}},N=async(w,E=!1,_=!0)=>{try{const P=E?k():null;P?console.log("📍 保存当前位置用于保持原位:",P):!E&&!_&&console.log("📍 添加节点模式:不保存位置,等待居中到新节点"),console.log("🔍 loadMindmapData 被调用,数据:",w),console.log("🔍 数据字段:",Object.keys(w||{})),w&&w.id?(o.value=w.id,console.log("🔍 设置当前思维导图ID (data.id):",w.id)):w&&w.mindmapId?(o.value=w.mindmapId,console.log("🔍 设置当前思维导图ID (data.mindmapId):",w.mindmapId)):w&&w.nodeData&&w.nodeData.mindmapId?(o.value=w.nodeData.mindmapId,console.log("🔍 设置当前思维导图ID (data.nodeData.mindmapId):",w.nodeData.mindmapId)):w&&w.nodeData&&w.nodeData.mindmap_id?(o.value=w.nodeData.mindmap_id,console.log("🔍 设置当前思维导图ID (data.nodeData.mindmap_id):",w.nodeData.mindmap_id)):(console.warn("⚠️ 数据中没有找到 id 或 mindmapId 字段"),console.log("🔍 可用的字段:",Object.keys(w||{})),w&&w.nodeData&&console.log("🔍 nodeData字段:",Object.keys(w.nodeData||{}))),console.log("🔍 设置后的 currentMindmapId.value:",o.value),y(),await Y0(),r.value||(console.warn("⚠️ 思维导图容器未准备好,等待DOM更新..."),await new Promise(Z=>setTimeout(Z,100)),r.value||console.warn("⚠️ 思维导图容器仍未准备好,尝试继续执行..."));try{if(r.value){console.log("🔍 创建Mind Elixir实例,设置markdown函数"),n.value=new vt({el:r.value,direction:vt.RIGHT,draggable:!0,contextMenu:!1,toolBar:!0,nodeMenu:!1,keypress:!1,autoCenter:!1,infinite:!0,maxScale:5,minScale:.1,markdown:(J,$)=>{if(console.log("🔍 Mind Elixir markdown函数被调用:",J.substring(0,100)+"..."),J.includes("|")||J.includes("**")||J.includes("`")||J.includes("#")){console.log("🎨 检测到markdown内容,开始渲染:",J.substring(0,100)+"...");const ue=G0(J);return console.log("🎨 渲染结果:",ue.substring(0,200)+"..."),ue}return console.log("🔍 内容不包含markdown语法,返回原文本"),J}}),console.log("✅ Mind Elixir实例创建完成,markdown函数已设置"),console.log("🔍 初始化Mind Elixir数据:",w);const Z=n.value.init(w);console.log("✅ Mind Elixir实例创建成功,初始化结果:",Z),P?(T(P),console.log("📍 初始化后立即恢复位置"),setTimeout(()=>{T(P),console.log("📍 二次确认位置恢复")},100)):!E&&!_&&console.log("📍 跳过根节点居中,等待居中新节点")}else{console.warn("⚠️ 容器未准备好,延迟创建Mind Elixir实例..."),setTimeout(()=>{if(r.value){n.value=new vt({el:r.value,direction:vt.RIGHT,draggable:!0,contextMenu:!1,toolBar:!0,nodeMenu:!1,keypress:!1,autoCenter:!1,infinite:!0,maxScale:5,minScale:.1,markdown:(J,$)=>J.includes("|")||J.includes("**")||J.includes("`")||J.includes("#")?G0(J):J});const Z=n.value.init(w);console.log("✅ Mind Elixir实例延迟创建成功"),P?(T(P),console.log("📍 延迟创建后立即恢复位置"),setTimeout(()=>{T(P),console.log("📍 延迟创建后二次确认位置恢复")},100)):!E&&!_&&console.log("📍 延迟创建后跳过根节点居中,等待居中新节点"),setTimeout(()=>{P?T(P):_&&O(),X(),I()},300)}},200);return}}catch{setTimeout(()=>{try{if(r.value){n.value=new vt({el:r.value,direction:vt.RIGHT,draggable:!0,contextMenu:!1,toolBar:!0,nodeMenu:!1,keypress:!1,autoCenter:!1,infinite:!0,maxScale:5,minScale:.1,markdown:($,ue)=>$.includes("|")||$.includes("**")||$.includes("`")||$.includes("#")?G0($):$});const J=n.value.init(w);P?(T(P),console.log("📍 重试创建后立即恢复位置"),setTimeout(()=>{T(P),console.log("📍 重试创建后二次确认位置恢复")},100)):!E&&!_&&console.log("📍 重试创建后跳过根节点居中,等待居中新节点"),setTimeout(()=>{P?T(P):_&&O(),X(),I()},300)}}catch(J){console.error("❌ Mind Elixir实例重试创建失败:",J)}},500);return}setTimeout(()=>{E&&P?T(P):_&&O(),y(),X(),setTimeout(P?()=>{T(P),I()}:_?()=>{O(),I()}:()=>{I()},500)},100)}catch{}},I=()=>{n.value&&r.value&&setTimeout(()=>{r.value.querySelectorAll("me-tpc, .topic, [data-id]").forEach((E,_)=>{var $;const P=E.getAttribute("data-id")||E.id||E.getAttribute("nodeid")||(($=E.querySelector("[data-id]"))==null?void 0:$.getAttribute("data-id"));if(!P)return;const Z=(ue,de)=>{for(const me of ue){if(me.id===de)return me;if(me.children){const Oe=Z(me.children,de);if(Oe)return Oe}}return null},J=Z(n.value.data.nodeData,P);if(J&&J.data&&J.data.des){let ue=E.querySelector(".node-description");ue||(ue=document.createElement("div"),ue.className="node-description",ue.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;
|
||
`,E.appendChild(ue));const de=J.data.des;de.length>150?(ue.textContent=de.substring(0,150)+"...",ue.title=de):ue.textContent=de}})},1e3)},O=()=>{try{if(n.value&&n.value.toCenter){n.value.toCenter(),console.log("✅ 使用 MindElixir toCenter 方法实现根节点居中");return}const w=r.value;if(!w)return;const E=w.querySelector(".map-canvas");if(!E)return;const _=E.querySelectorAll("me-tpc");if(_.length===0)return;let P=1/0,Z=-1/0,J=1/0,$=-1/0;_.forEach(C0=>{const yn=C0.getBoundingClientRect(),M0=w.getBoundingClientRect(),Oo=yn.left-M0.left,Lo=yn.top-M0.top;P=Math.min(P,Oo),Z=Math.max(Z,Oo+yn.width),J=Math.min(J,Lo),$=Math.max($,Lo+yn.height)});const ue=(P+Z)/2,de=(J+$)/2,me=w.clientWidth/2,Oe=w.clientHeight/2,Be=me-ue,gt=Oe-de;E.style.transform=`translate(${Be}px, ${gt}px)`,E.style.opacity="1",E.style.transition="opacity 0.3s ease";const Rt=100,Jt=Math.max(Be,Rt),yr=Math.max(gt,Rt);E.style.transform=`translate(${Jt}px, ${yr}px)`,E.style.opacity="1",E.style.visibility="visible"}catch{}},z=async w=>{if(!(!n.value||!w))try{console.log("🎯 开始处理新节点:",w);let E=null,_=0;const P=5;for(;!E&&_<P;)E=n.value.findEle(w),E||(_++,await new Promise(Z=>setTimeout(Z,50)));E?(console.log("✅ 找到节点元素:",E),n.value.scrollIntoView&&(n.value.scrollIntoView(E),console.log("✅ 节点已平滑居中显示")),setTimeout(()=>{n.value.beginEdit&&(n.value.beginEdit(E),console.log("✅ 节点已进入编辑状态"))},350)):console.error("❌ 多次尝试后仍未找到节点元素:",w)}catch(E){console.error("❌ 居中显示节点失败:",E)}},W=()=>{if(!s.value)return;if(n.value&&n.value.getNodeById)try{const E=n.value.getNodeById(s.value.id);if(E){const _=E.getBoundingClientRect(),P=r.value.getBoundingClientRect(),Z=_.left-P.left+_.width/2,J=_.bottom-P.top+10;i.value={left:`${Z}px`,top:`${J}px`};return}}catch{}let w=document.querySelector(`[data-id="${s.value.id}"]`);if(w||(w=document.querySelector(`.topic[data-id="${s.value.id}"]`)),w||(w=document.querySelector(`[data-node-id="${s.value.id}"]`)),w||(w=document.querySelector(`[data-nodeid="me${s.value.id}"]`)),!w){const E=document.querySelectorAll("me-tpc");for(const _ of E)if(_.getAttribute("data-nodeid")===`me${s.value.id}`){w=_;break}}if(!w){const E=document.querySelectorAll(".topic");for(const _ of E)if(_.textContent.trim()===s.value.topic){w=_;break}}if(w){const E=w.getBoundingClientRect(),_=r.value.getBoundingClientRect(),P=E.left-_.left+E.width/2,Z=E.bottom-_.top+10;i.value={left:`${P}px`,top:`${Z}px`}}else i.value={left:"50%",top:"50%",transform:"translate(-50%, -50%)"}},U=async()=>{s.value&&(await ye(s.value),s.value=null)},he=async()=>{s.value&&(await fe(s.value),s.value=null)},ge=async()=>{s.value&&(await Ue(s.value),s.value=null)},Ae=async()=>{if(!s.value)return;console.log("Ask AI for node:",s.value);const w=parseFloat(i.value.left)||0,E=parseFloat(i.value.top)||0;a.value={left:`${w}px`,top:`${E+60}px`,transform:"translateX(-50%)"},f.value=!0,p.value=s.value},et=()=>{f.value=!1,p.value=null,b.value="",v.value=!1,s.value=null},Je=w=>{if(!w)return"";const E=[];return w.parent&&w.parent.topic&&E.push(`父节点: ${w.parent.topic}`),w.parent&&w.parent.parent&&w.parent.parent.topic&&E.push(`祖父节点: ${w.parent.parent.topic}`),E.join(" | ")},ot=w=>{w.ctrlKey||w.metaKey||(w.preventDefault(),Fe())},Fe=async()=>{if(!(!b.value.trim()||!p.value||v.value)){v.value=!0;try{const w="你是一个专业的思维导图分析助手。请根据用户的问题和提供的节点信息,给出专业、有用的回答。",E=`节点信息:
|
||
当前节点:${p.value.topic}
|
||
上下文:${Je(p.value)}
|
||
|
||
用户问题:${b.value}
|
||
|
||
请给出详细的回答,回答应该:
|
||
1. 直接回答用户的问题
|
||
2. 提供具体的建议或改进方案
|
||
3. 保持专业和有用的语调
|
||
4. 回答长度适中,便于在思维导图中展示`;console.log("发送AI请求:",{systemPrompt:w,userPrompt:E});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:w,user_prompt:E,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 P="";const Z=_.body.getReader(),J=new TextDecoder;let $="";for(;;){const{done:ue,value:de}=await Z.read();if(ue)break;$+=J.decode(de,{stream:!0});const me=$.split(`
|
||
`);$=me.pop()||"";for(const Oe of me)if(Oe.startsWith("data: "))try{const Be=JSON.parse(Oe.slice(6));if(Be.type==="chunk")P+=Be.content;else if(Be.type==="error")throw new Error(Be.content)}catch(Be){console.warn("解析流式数据失败:",Be)}}await tt(p.value,b.value,P),et()}catch(w){console.error("AI请求失败:",w),alert("AI请求失败,请稍后重试")}finally{v.value=!1}}},Ie=w=>w.replace(/^### (.*$)/gim,"📋 $1").replace(/^## (.*$)/gim,"📌 $1").replace(/^# (.*$)/gim,"🎯 $1").replace(/\*\*(.*?)\*\*/g,(E,_)=>{if(_.includes(":")){const P=_.split(":");if(P.length>1)return`【${P[0]}】: ${P.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,`
|
||
`),ve=(w,E,_)=>{const P=w.split(`
|
||
`);let Z=_,J=[];for(let $=0;$<P.length;$++){const de=P[$].trim(),me=de.match(/^[-*+]\s*【(.+)】/);if(me){const Oe=me[1].trim(),Be={id:`node_${Z++}`,topic:Oe,children:[],level:(E.level||0)+1,data:{}};let gt=[],Rt=$+1;for(;Rt<P.length;){const Jt=P[Rt].trim();if(Jt.match(/^[-*+]\s*【(.+)】/))break;const C0=Jt.match(/^[-*+]\s+(.+)$/);if(C0){const yn=C0[1].trim(),M0=Ie(yn);gt.push("• "+M0)}Rt++}if(gt.length>0){const Jt=Ie(gt.join(`
|
||
`));Be.topic=Be.topic+`
|
||
|
||
`+Jt}E.children.push(Be),$=Rt-1}else de&&J.push(de)}if(J.length>0){const $=J.join(`
|
||
`).trim();$&&$.split(`
|
||
|
||
`).filter(de=>de.trim()).forEach(de=>{const me=Ie(de.trim());if(me){const Oe={id:`node_${Z++}`,topic:me,children:[],level:(E.level||0)+1,data:{}};E.children.push(Oe)}})}return{nodeCounter:Z}},Me=w=>{const E=w.split(`
|
||
`);let _=null;const P=[];let Z=0,J=[];if(E.forEach(($,ue)=>{const de=$.trim(),me=de.match(/^(#{1,6})\s+(.+)$/);if(me){if(J.length>0&&P.length>0){const Jt=J.join(`
|
||
`).trim();Jt&&(Z=ve(Jt,P[P.length-1],Z).nodeCounter),J=[]}const Oe=me[1].length,Be=me[2].trim(),gt=Ie(Be),Rt={id:`node_${Z++}`,topic:gt,children:[],level:Oe,data:{}};if(Oe===1&&!_)_=Rt,P.length=0,P.push(_);else{for(;P.length>1&&P[P.length-1].level>=Oe;)P.pop();P.length>0&&P[P.length-1].children.push(Rt),P.push(Rt)}}else de&&J.push(de)}),J.length>0&&P.length>0){const $=J.join(`
|
||
`).trim();$&&(Z=ve($,P[P.length-1],Z).nodeCounter)}return _||(_={id:"root",topic:"根节点",children:[],data:{}}),_},tt=async(w,E,_)=>{var P,Z,J;try{const ue=(yr=>yr.replace(/^#+\s*/gm,"").replace(/\*\*(.*?)\*\*/g,"$1").replace(/\*(.*?)\*/g,"$1").replace(/^\s*[-*+]\s*(?![|])/gm,"• ").replace(/\n{3,}/g,`
|
||
|
||
`).trim())(_),de=`# ${E}
|
||
|
||
${ue}`,me=Me(de),Oe={title:E,des:`AI追问产生的节点 - ${new Date().toLocaleString()}`,parentId:w.id,isRoot:!1},Be=[];if(me.children&&me.children.length>0&&me.children.forEach(yr=>{Be.push({title:yr.topic,des:"",parentId:null,isRoot:!1})}),console.log("当前思维导图ID:",o.value),!o.value)throw new Error("没有找到当前思维导图ID,无法创建节点");const gt=await lt.addNodes(o.value,[Oe]);if(!gt.data||!gt.data.success)throw new Error("AI父节点创建失败");const Rt=(J=(Z=(P=gt.data.data)==null?void 0:P.nodes)==null?void 0:Z[0])==null?void 0:J.id;if(!Rt)throw new Error("无法获取创建的父节点ID");Be.forEach(yr=>{yr.parentId=Rt});let Jt=null;if(Be.length>0&&(Jt=await lt.addNodes(o.value,Be)),gt.data&>.data.success)await be();else throw new Error("AI父节点创建失败")}catch($){console.error("创建AI节点失败:",$),alert("创建AI回答节点失败: "+$.message)}},We=async()=>{if(s.value){try{const w=s.value.topic||s.value.title||"无标题";if(navigator.clipboard&&window.isSecureContext)await navigator.clipboard.writeText(w),_e();else{const E=document.createElement("textarea");E.value=w,E.style.position="fixed",E.style.left="-999999px",E.style.top="-999999px",document.body.appendChild(E),E.focus(),E.select();const _=document.execCommand("copy");document.body.removeChild(E),_?_e():St()}}catch{St()}s.value=null}},_e=()=>{const w=document.createElement("div");w.textContent="文本已复制到剪贴板",w.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 E=document.createElement("style");E.textContent=`
|
||
@keyframes slideIn {
|
||
from { transform: translateX(100%); opacity: 0; }
|
||
to { transform: translateX(0); opacity: 1; }
|
||
}
|
||
`,document.head.appendChild(E),document.body.appendChild(w),setTimeout(()=>{w.parentNode&&w.parentNode.removeChild(w),E.parentNode&&E.parentNode.removeChild(E)},3e3)},St=()=>{const w=document.createElement("div");w.textContent="复制失败,请手动复制",w.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(w),setTimeout(()=>{w.parentNode&&w.parentNode.removeChild(w)},3e3)},mt=(w,E="success")=>{const _=document.createElement("div");_.textContent=w;const P=E==="success"?"#4CAF50":E==="error"?"#f44336":"#ff9800";_.style.cssText=`
|
||
position: fixed;
|
||
top: 20px;
|
||
right: 20px;
|
||
background: ${P};
|
||
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)},j=()=>{const w=document.createElement("div");w.textContent="✅ 节点编辑已保存",w.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(w),setTimeout(()=>{w.parentNode&&w.parentNode.removeChild(w)},2e3)},V=()=>{const w=document.createElement("div");w.textContent="❌ 节点编辑保存失败",w.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(w),setTimeout(()=>{w.parentNode&&w.parentNode.removeChild(w)},3e3)},re=async w=>{try{console.log("🎯 处理节点拖拽操作:",w.name),console.log("📦 操作详情:",{name:w.name,objs:w.objs,toObj:w.toObj}),setTimeout(async()=>{var E;try{const _=w.objs||[],P=w.toObj;if(!_.length||!P){console.warn("⚠️ 拖拽操作缺少必要信息");return}console.log(`📦 准备保存 ${_.length} 个节点的父子关系`);let Z=null;w.name==="moveNodeIn"?(Z=P.id,console.log(`📌 拖入操作:新父节点为 ${Z}`)):(w.name==="moveNodeBefore"||w.name==="moveNodeAfter")&&(Z=((E=P.parent)==null?void 0:E.id)||null,console.log(`📌 拖到兄弟位置:新父节点为 ${Z||"根节点"}`));const J=_.map(async me=>{try{console.log(`🔄 更新节点 ${me.id} 的父节点为 ${Z||"根节点"}`);const Oe=await lt.updateNode(me.id,{newParentId:Z});return Oe.data&&Oe.data.success?(console.log(`✅ 节点 ${me.id} 父子关系更新成功`),{success:!0,nodeId:me.id}):(console.warn(`⚠️ 节点 ${me.id} 父子关系更新失败:`,Oe),{success:!1,nodeId:me.id})}catch(Oe){return console.error(`❌ 节点 ${me.id} 父子关系更新失败:`,Oe),{success:!1,nodeId:me.id,error:Oe}}}),$=await Promise.all(J),ue=$.filter(me=>me.success).length,de=$.filter(me=>!me.success).length;console.log(`📊 拖拽保存结果: ${ue} 成功, ${de} 失败`)}catch(_){console.error("❌ 保存拖拽后的结构失败:",_),mt("❌ 节点拖拽保存失败","error")}},500)}catch(E){console.error("❌ 处理节点拖拽操作失败:",E)}},ie=async w=>{try{const E=w.obj;E?await Ee(E):console.error("无法解析编辑操作:",w)}catch(E){console.error("处理编辑完成失败:",E)}},Ee=async w=>{var E,_;try{if(!o.value){console.error("无法获取思维导图ID");return}const P=await lt.updateNode(w.id,{newTitle:w.topic,newDes:((E=w.data)==null?void 0:E.des)||"",newParentId:w.parentId||((_=w.parent)==null?void 0:_.id)});P.data&&P.data.success?j():(console.error("更新节点编辑失败:",P.data),V())}catch(P){console.error("更新节点编辑失败:",P),V()}},ye=async w=>{var E;try{await S();const _=o.value||w.mindmap_id||w.mindmapId;if(!_){console.error("无法获取思维导图ID");return}const P=await lt.addNodes(_,[{title:"新子节点",des:"子节点描述",parentId:w.id}]);if(P.data&&P.data.success){const Z=((E=P.data.data)==null?void 0:E.nodes)||[];if(Z.length>0){const J=Z[0];try{await new Promise(ue=>setTimeout(ue,800));const $=await lt.getMindmap(_);if($.data&&$.data.nodeData){await N($.data,!1,!1);try{console.log("🎯 开始居中显示新子节点:",J.id),await z(J.id)}catch(ue){console.error("居中显示新节点失败:",ue)}}else throw new Error("无法获取思维导图数据")}catch($){console.error("刷新思维导图失败:",$)}}}}catch(_){console.error("添加子节点失败:",_)}},fe=async w=>{var E;try{await S(),console.log("添加兄弟节点到API:",w.id),console.log("节点信息:",{id:w.id,parentId:w.parentId,parent:w.parent,mindmap_id:w.mindmap_id,mindmapId:w.mindmapId});const _=o.value||w.mindmap_id||w.mindmapId;if(!_){console.error("无法获取思维导图ID");return}let P=w.parentId;!P&&w.parent&&(P=w.parent.id);const Z=await lt.addNodes(_,[{title:"新兄弟节点",des:"兄弟节点描述",parentId:P}]);if(console.log("添加兄弟节点响应:",Z),Z.data&&Z.data.success){const J=((E=Z.data.data)==null?void 0:E.nodes)||[];if(J.length>0){const $=J[0];console.log("新创建的兄弟节点:",$),console.log("🎯 使用MindElixir init方法重新初始化数据...");try{const ue=await lt.getMindmap(_);if(ue.data&&ue.data.nodeData){await N(ue.data,!1,!1),console.log("✅ 思维导图刷新成功");try{console.log("🎯 开始居中显示新兄弟节点:",$.id),await z($.id)}catch(de){console.error("居中显示新节点失败:",de)}}else throw new Error("无法获取思维导图数据")}catch(ue){console.error("重新初始化失败,使用完整重新加载:",ue);const de=await lt.getMindmap(_);de.data&&de.data.nodeData&&await N(de.data,!0,!1)}}}}catch(_){console.error("添加兄弟节点失败:",_)}},Ue=async w=>{try{await S(),console.log("删除节点从API:",w.id);const E=await lt.deleteNodes([w.id]);if(console.log("删除节点响应:",E),E.data&&E.data.success){const _=o.value||w.mindmap_id||w.mindmapId;if(_){const P=await lt.getMindmap(_);P.data&&P.data.nodeData&&(await N(P.data,!0,!1),console.log("✅ 删除节点后思维导图已刷新,保持当前位置"))}}}catch(E){console.error("删除节点失败:",E)}},S=async()=>{const w=r.value;if(w){const E=w.querySelector("input:focus");if(E&&s.value){const _=E.value;_!==s.value.topic&&_.trim()!==""&&(console.log("保存当前编辑:",_),s.value.topic=_,await D(s.value))}}},D=async w=>{var E,_,P,Z,J;try{console.log("保存Mind Elixir编辑,节点ID:",w.id),console.log("编辑内容:",{newTitle:w.topic,newDes:((E=w.data)==null?void 0:E.des)||""});const $=String(w.id),ue=await lt.updateNode($,{newTitle:w.topic,newDes:((_=w.data)==null?void 0:_.des)||""});console.log("更新节点API响应:",ue),console.log("节点编辑已保存到后端"),console.log("✅ 节点编辑已保存,无需重新加载")}catch($){console.error("保存Mind Elixir编辑失败:",$),console.error("错误详情:",(P=$.response)==null?void 0:P.data),alert("保存编辑失败: "+(((J=(Z=$.response)==null?void 0:Z.data)==null?void 0:J.detail)||$.message))}},F=w=>{console.log("打开编辑模态框:",w),n.value.editText(w)},G=async(w,E,_)=>{var P,Z,J;try{console.log("开始创建节点:",w.topic,"父节点ID:",_);const $=await lt.addNodes(E,{title:w.topic||w.title||"无标题",des:((P=w.data)==null?void 0:P.des)||"",parentId:_});if(console.log("创建节点响应:",$),$.data&&$.data.success){const de=(J=(((Z=$.data.data)==null?void 0:Z.nodes)||[])[0])==null?void 0:J.id;if(console.log("当前节点ID:",de),w.children&&w.children.length>0){console.log("开始创建子节点,数量:",w.children.length);for(const me of w.children)await G(me,E,de)}else console.log("节点没有子节点,创建完成")}else console.error("创建节点失败,响应:",$)}catch($){console.error("创建节点失败:",$)}};let q=null,H=null;const X=()=>{if(!n.value)return;console.log("绑定事件监听器..."),q&&r.value.removeEventListener("wheel",q),H&&r.value.removeEventListener("click",H),q=_=>{if(_.ctrlKey||_.metaKey){_.preventDefault();const P=_.deltaY>0?.9:1.1,Z=Math.max(.3,Math.min(3,l.value*P));if(n.value){const J=r.value.querySelector(".map-container");J&&(J.style.transform=`scale(${Z})`,l.value=Z,localStorage.setItem("mindmap-zoom-level",Z.toString()))}}},r.value.addEventListener("wheel",q),n.value.bus.addListener("select",_=>{s.value=_,setTimeout(()=>{W()},50)}),n.value.bus.addListener("selectNode",_=>{s.value=_,setTimeout(()=>{W()},50)}),n.value.bus.addListener("scale",_=>{Math.abs(_-1)<.01&&Math.abs(l.value-1)>.01&&setTimeout(()=>{ne()},50)}),window.zoomIntervalId&&clearInterval(window.zoomIntervalId);const w=setInterval(()=>{l.value!==1&&r.value&&se()},500);window.zoomIntervalId=w;let E=0;H=_=>{const P=Date.now();if(P-E<100)return;E=P;const Z=_.target,J=Z.closest("me-tpc")||Z.closest(".topic")||(Z.classList.contains("topic")?Z:null)||(Z.tagName==="ME-TPC"?Z:null);if(J){const $=J.nodeObj;if($){s.value=$;const ue=r.value.getBoundingClientRect(),de=J.getBoundingClientRect(),me=de.left-ue.left+de.width/2,Oe=de.bottom-ue.top+8;i.value={left:`${me}px`,top:`${Oe}px`}}}else s.value=null,f.value&&(f.value=!1,p.value=null,b.value="",v.value=!1)},r.value.addEventListener("click",H),n.value.bus.addListener("edit",_=>{console.log("edit事件触发:",_),F(_)}),n.value.bus.addListener("editFinish",_=>{console.log("editFinish事件触发:",_),ie(_)}),n.value.bus.addListener("operation",_=>{console.log("Mind Elixir操作事件:",_),_.name==="moveNodeIn"||_.name==="moveNodeBefore"||_.name==="moveNodeAfter"?(console.log("检测到节点拖拽操作:",_.name,_),re(_)):_.name==="finishEdit"&&(console.log("检测到编辑完成操作:",_),ie(_))}),n.value.bus.addListener("removeNode",_=>{console.log("删除节点:",_),Ue(_)})},ne=()=>{if(n.value){const w=localStorage.getItem("mindmap-zoom-level");if(w){const E=parseFloat(w);if(E>=.3&&E<=3){const _=r.value.querySelector(".map-container");_&&(_.style.transform=`scale(${E})`,l.value=E)}}}},se=()=>{if(n.value&&l.value!==1&&r.value){const w=r.value.querySelector(".map-container");w&&(w.style.transform=`scale(${l.value})`)}},Q=async()=>{var w;if(console.log("🚀🚀🚀 保存函数被调用 🚀🚀🚀"),console.log("🔍 mindElixir.value:",n.value),console.log("🔍 currentMindmapId.value:",o.value),console.log("🔍 mindmapEl.value:",r.value),console.log("🔍🔍🔍 全局状态检查开始 🔍🔍🔍"),console.log("🔍 - showWelcome:",c.value),console.log("🔍 - 是否有思维导图容器:",!!r.value),console.log("🔍 - MindElixir实例状态:",!!n.value),console.log("🔍🔍🔍 全局状态检查结束 🔍🔍🔍"),n.value&&n.value.data?(console.log("🔍🔍🔍 MindElixir数据检查开始 🔍🔍🔍"),console.log("🔍 - 数据对象:",n.value.data),console.log("🔍 - 数据字段:",Object.keys(n.value.data)),console.log("🔍 - 是否有nodeData:",!!n.value.data.nodeData),console.log("🔍 - 是否有nodes:",!!n.value.data.nodes),console.log("🔍🔍🔍 MindElixir数据检查结束 🔍🔍🔍")):console.log("⚠️ MindElixir数据不存在或为空"),!n.value||!o.value){if(console.warn("⚠️ 没有可保存的思维导图数据"),console.warn("🔍 mindElixir.value 状态:",!!n.value),console.warn("🔍 currentMindmapId.value 状态:",!!o.value),n.value&&n.value.data&&(console.log("🔍 尝试从MindElixir数据中获取ID"),console.log("🔍 MindElixir数据:",n.value.data),n.value.data.mindmapId?(o.value=n.value.data.mindmapId,console.log("🔍 从MindElixir数据中获取到mindmapId:",n.value.data.mindmapId)):n.value.data.mindmap_id&&(o.value=n.value.data.mindmap_id,console.log("🔍 从MindElixir数据中获取到mindmap_id:",n.value.data.mindmap_id))),!o.value&&n.value){if(console.log("🔍 尝试重新初始化MindElixir数据..."),console.log("🔍 MindElixir实例属性:",Object.keys(n.value)),console.log("🔍 MindElixir实例方法:",Object.getOwnPropertyNames(Object.getPrototypeOf(n.value))),n.value.getData){const E=n.value.getData();console.log("🔍 通过getData()获取的数据:",E),E&&E.nodeData&&(console.log("🔍 nodeData详情:",E.nodeData),E.nodeData.mindmapId?(o.value=E.nodeData.mindmapId,console.log("🔍 从nodeData.mindmapId获取到ID:",E.nodeData.mindmapId)):E.nodeData.mindmap_id?(o.value=E.nodeData.mindmap_id,console.log("🔍 从nodeData.mindmap_id获取到ID:",E.nodeData.mindmap_id)):(console.log("🔍 nodeData中没有找到mindmapId字段"),console.log("🔍 nodeData字段:",Object.keys(E.nodeData)))),!o.value&&E&&(console.log("🔍 检查其他可能的ID字段..."),E.id?(o.value=E.id,console.log("🔍 从data.id获取到ID:",E.id)):E.mindmapId&&(o.value=E.mindmapId,console.log("🔍 从data.mindmapId获取到ID:",E.mindmapId)))}n.value.mindElixirData&&(console.log("🔍 mindElixirData:",n.value.mindElixirData),n.value.mindElixirData.id&&(o.value=n.value.mindElixirData.id,console.log("🔍 从mindElixirData获取到ID:",n.value.mindElixirData.id)))}if(!o.value){console.warn("⚠️ 仍然无法获取思维导图ID,无法保存"),console.warn("🔍 建议:请先加载一个思维导图,然后再尝试保存");return}}try{console.log("💾 开始保存思维导图..."),console.log("🔍 当前思维导图ID:",o.value),console.log("🔍 MindElixir实例:",n.value);let E=null;if(n.value&&n.value.getData?(E=n.value.getData(),console.log("🔍 通过getData()获取的数据:",E)):(E=n.value.data,console.log("🔍 通过data属性获取的数据:",E)),!E){console.warn("⚠️ MindElixir数据为空");return}let _=[];console.log("🔍 数据结构分析:"),console.log("🔍 - currentData.nodeData:",E.nodeData),console.log("🔍 - currentData.nodes:",E.nodes),console.log("🔍 - currentData.nodeData.children:",(w=E.nodeData)==null?void 0:w.children);const P=$=>{$&&$.id&&(_.push($),console.log(`🔍 收集节点: ${$.id} - ${$.topic||$.content||"无标题"}`),$.children&&$.children.length>0&&$.children.forEach(ue=>P(ue)))};if(E.nodeData)P(E.nodeData),console.log("🔍 从根节点收集到节点数量:",_.length);else if(E.nodes&&Array.isArray(E.nodes))E.nodes.forEach($=>P($)),console.log("🔍 从nodes数组收集到节点数量:",_.length);else if(Array.isArray(E))E.forEach($=>P($)),console.log("🔍 从currentData数组收集到节点数量:",_.length);else{console.warn("⚠️ 无法找到节点数据"),console.log("🔍 可用的数据字段:",Object.keys(E));return}if(_.length===0){console.warn("⚠️ 没有收集到任何节点");return}console.log("🔍 找到节点数据:",_),console.log("🔍 节点数量:",_.length),console.log("🔍 节点数据类型:",Array.isArray(_)?"数组":typeof _);const Z=[];if(_.forEach(($,ue)=>{if(console.log(`🔍 处理节点 ${ue}:`,$),$&&$.id){const de=$.topic||$.content||$.text||"",me=$.x||$.offsetX||0,Oe=$.y||$.offsetY||0;console.log(`🔍 节点 ${$.id} 内容:`,de,"位置:",{x:me,y:Oe});const Be={content:de,position:{x:me,y:Oe}};($.parentId||$.parent)&&(Be.parentId=$.parentId||$.parent,console.log(`🔍 节点 ${$.id} 父节点:`,Be.parentId)),console.log(`🔍 准备保存节点 ${$.id}:`,Be),Z.push(lt.updateNode($.id,Be).then(gt=>{console.log(`✅ 节点 ${$.id} 保存成功:`,gt)}).catch(gt=>{console.error(`❌ 节点 ${$.id} 保存失败:`,gt)}))}else console.warn(`⚠️ 节点 ${ue} 缺少ID:`,$)}),console.log("🔍 准备保存的节点数量:",Z.length),Z.length===0){console.warn("⚠️ 没有找到需要保存的节点");return}const J=await Promise.all(Z);console.log("🔍 保存结果:",J),console.log("🎉 思维导图保存完成!"),console.log("🔄 保存完成,开始自动刷新..."),await be()}catch(E){console.error("❌ 保存思维导图失败:",E)}},be=async()=>{if(!o.value){console.warn("⚠️ 没有当前思维导图ID,无法刷新");return}try{console.log("🔄 开始刷新思维导图...");const w=await lt.getMindmap(o.value);w.data&&w.data.nodeData?(console.log("✅ 获取到最新数据,开始刷新显示..."),await N(w.data,!0,!1),console.log("🎉 思维导图刷新完成!")):console.warn("⚠️ 无法获取思维导图数据")}catch(w){console.error("❌ 刷新思维导图失败:",w)}},le=async(w,E)=>{try{const _=String(o.value||"");if(n.value&&_&&_.startsWith("temp-")){console.log("🔄 检测到实时渲染的思维导图,将保存到数据库并更新ID");const J=k();console.log("📍 保存当前位置:",J);const $=await lt.createMindmap(E||"预览思维导图",w);if(console.log("🔄 创建思维导图响应:",$),$.data&&$.data.id){const ue=$.data.id;console.log("🎉 创建思维导图成功,新思维导图的ID是:",ue);const de=o.value;if(o.value=ue,n.value&&n.value.data){n.value.data.mindmapId=ue,n.value.data.id=ue;const me=Oe=>{Oe&&(Oe.mindmapId=ue,Oe.children&&Oe.children.forEach(Be=>me(Be)))};n.value.data.nodeData&&me(n.value.data.nodeData)}console.log("✅ 已更新思维导图ID,保持视图状态"),console.log("🔄 从临时ID",de,"更新为正式ID",ue),J&&setTimeout(()=>{T(J),console.log("📍 已恢复位置和缩放状态")},100),window.dispatchEvent(new CustomEvent("mindmap-saved",{detail:{mindmapId:ue,title:E,timestamp:Date.now(),fromRealtime:!0}}));return}}console.log("🔄 没有检测到实时渲染的思维导图,使用标准保存流程");const Z=await lt.createMindmap(E||"预览思维导图",w);if(console.log("🔄 创建思维导图响应:",Z),Z.data&&Z.data.id){const J=Z.data.id;if(console.log("🎉 创建思维导图成功,新思维导图的ID是:",J),console.log("📊 响应数据详情:",Z.data),Z.data.nodeData)console.log("✅ 思维导图创建时已包含节点数据,直接加载"),o.value=J,y(),await N(Z.data),window.dispatchEvent(new CustomEvent("mindmap-saved",{detail:{mindmapId:J,title:E,timestamp:Date.now()}})),setTimeout(async()=>{try{console.log("🔄 重新加载思维导图数据...");const $=await lt.getMindmap(J);$.data&&$.data.nodeData&&(await N($.data),console.log("✅ 思维导图数据重新加载成功"))}catch($){console.error("❌ 重新加载思维导图失败:",$)}},1500);else{console.log("🔧 需要递归创建节点"),await G(w,J,null),console.log("📥 开始加载新创建的思维导图,ID:",J);const $=await lt.getMindmap(J);console.log("🔄 加载思维导图响应:",$),$.data&&$.data.nodeData?(console.log("✅ 成功获取思维导图数据,开始加载显示"),o.value=J,y(),await N($.data),window.dispatchEvent(new CustomEvent("mindmap-saved",{detail:{mindmapId:J,title:E,timestamp:Date.now()}})),setTimeout(async()=>{try{console.log("🔄 重新加载思维导图数据...");const ue=await lt.getMindmap(J);ue.data&&ue.data.nodeData&&(await N(ue.data),console.log("✅ 思维导图数据重新加载成功"))}catch(ue){console.error("❌ 重新加载思维导图失败:",ue)}},1500)):console.error("❌ 获取思维导图数据失败:",$)}}}catch(_){console.error("❌ 保存预览数据到数据库失败:",_)}},pe=async w=>{try{if(console.log("📚 开始从历史记录加载思维导图:",w.title),y(),w.mindmapId){console.log("🎯 使用思维导图ID加载:",w.mindmapId);const E=await lt.getMindmap(w.mindmapId);if(E.data&&E.data.nodeData)await N(E.data);else throw new Error("无法获取思维导图数据")}else if(w.json)console.log("📊 使用历史记录中的JSON数据"),await N(w.json);else if(w.markdown){console.log("📝 使用历史记录中的Markdown数据,尝试转换为JSON");try{const E=await convertMarkdownToJSON(w.markdown);if(E)await N(E);else throw new Error("Markdown转换失败")}catch(E){console.error("Markdown转换失败:",E)}}}catch(E){console.error("❌ 从历史记录加载思维导图失败:",E)}};Oa(async()=>{window.addEventListener("save-preview-to-database",w=>{console.log("🎯 收到保存到数据库事件:",w.detail),console.log("📋 事件详情 - 标题:",w.detail.title,"来源:",w.detail.source,"时间戳:",new Date(w.detail.timestamp).toLocaleString()),le(w.detail.data,w.detail.title)}),window.addEventListener("realtime-mindmap-update",w=>{console.log("🔄 收到实时思维导图更新事件:",w.detail),Le(w.detail.data,w.detail.title)}),window.addEventListener("loadMindmapFromHistory",w=>{console.log("📚 收到从历史记录加载思维导图事件:",w.detail),console.log("🔍 事件数据详情:",w.detail),pe(w.detail)}),window.addEventListener("ai-sidebar-toggle",w=>{console.log("🤖 AI侧边栏折叠状态变化:",w.detail.isCollapsed),d.value=w.detail.isCollapsed}),x()});const Se=()=>{window.zoomIntervalId&&(clearInterval(window.zoomIntervalId),window.zoomIntervalId=null),r.value&&(q&&(r.value.removeEventListener("wheel",q),q=null),H&&(r.value.removeEventListener("click",H),H=null)),console.log("✅ 已清理所有定时器和事件监听器")};La(()=>{Se()}),e({showMindMapPage:M,cleanupIntervals:Se});const Le=async(w,E)=>{try{if(n.value){console.log("🔄 更新现有思维导图数据");try{const _=k(),P=String(o.value||""),Z=P&&P.startsWith("temp-")?P:`temp-${Date.now()}`,J={nodeData:w,mindmapId:Z,id:Z,title:E||"AI生成中..."};(!P||!P.startsWith("temp-"))&&(o.value=Z,console.log("🆔 更新临时思维导图ID:",Z));const $=n.value.init(J);_&&setTimeout(()=>{T(_)},100)}catch(_){console.error("❌ 更新思维导图数据失败:",_)}}else{y(),await Y0();let _=0;for(;!r.value&&_<20;)await new Promise($=>setTimeout($,50)),await Y0(),_++;if(!r.value){console.error("❌ 思维导图容器仍未准备好,跳过此次更新");return}n.value=new vt({el:r.value,direction:vt.RIGHT,draggable:!0,contextMenu:!1,toolBar:!0,nodeMenu:!0,keypress:!1,autoCenter:!1,infinite:!0,maxScale:5,minScale:.1,markdown:($,ue)=>{if($.includes("|")||$.includes("**")||$.includes("`")||$.includes("#")||$.includes("$")){console.log("🎨 实时更新 检测到markdown内容,开始渲染:",$.substring(0,100)+"...");const de=G0($);return console.log("🎨 实时更新 渲染结果:",de.substring(0,200)+"..."),de}return console.log("🔍 实时更新 内容不包含markdown语法,返回原文本"),$}});const P=`temp-${Date.now()}`,Z={nodeData:w,mindmapId:P,id:P,title:E||"AI生成中..."};o.value=P,console.log("🆔 设置临时思维导图ID:",P);const J=n.value.init(Z);console.log("✅ 实时思维导图实例创建成功"),X(),O()}}catch(_){console.error("❌ 实时更新思维导图失败:",_)}};return(w,E)=>(Ve(),Ke("div",s7,[c.value?(Ve(),Ke("div",i7,[Y("div",{class:Ln(["welcome-content",{"ai-sidebar-collapsed":d.value}])},[...E[1]||(E[1]=[Ko('<div class="welcome-header" data-v-ce711d91><h1 data-v-ce711d91>🧠 思维导图工具</h1><p class="welcome-subtitle" data-v-ce711d91>可视化您的想法,构建知识体系</p></div><div class="welcome-features" data-v-ce711d91><div class="feature-item" data-v-ce711d91><div class="feature-icon" data-v-ce711d91>🎯</div><div class="feature-text" data-v-ce711d91><h3 data-v-ce711d91>智能AI生成</h3><p data-v-ce711d91>上传文档,AI自动生成思维导图结构</p></div></div><div class="feature-item" data-v-ce711d91><div class="feature-icon" data-v-ce711d91>✏️</div><div class="feature-text" data-v-ce711d91><h3 data-v-ce711d91>灵活编辑</h3><p data-v-ce711d91>拖拽节点,自由调整思维导图布局</p></div></div><div class="feature-item" data-v-ce711d91><div class="feature-icon" data-v-ce711d91>💾</div><div class="feature-text" data-v-ce711d91><h3 data-v-ce711d91>云端存储</h3><p data-v-ce711d91>自动保存,多设备同步访问</p></div></div></div><div class="welcome-tips" data-v-ce711d91><p data-v-ce711d91>💡 提示:使用左侧AI侧边栏可以快速生成思维导图内容</p></div>',3)])],2)])):Sr("",!0),f.value?(Ve(),Ke("div",{key:1,class:"ai-input-area",style:On(a.value)},[Y("div",{class:"ai-input-header"},[E[2]||(E[2]=Y("span",{class:"ai-input-title"},"🤖 询问AI",-1)),Y("button",{onClick:et,class:"ai-close-btn"},"×")]),Y("div",a7,[ds(Y("textarea",{"onUpdate:modelValue":E[0]||(E[0]=_=>b.value=_),placeholder:"请输入您的问题...",rows:"2",disabled:v.value,onKeydown:[vi(gi(ot,["exact"]),["enter"]),vi(gi(Fe,["ctrl"]),["enter"]),vi(gi(Fe,["meta"]),["enter"])]},null,40,o7),[[Pa,b.value]]),Y("div",l7,[Y("button",{onClick:et,class:"btn-cancel",disabled:v.value}," 取消 ",8,c7),Y("button",{onClick:Fe,class:"btn-submit",disabled:!b.value.trim()||v.value},[v.value?(Ve(),Ke("span",d7,"AI思考中...")):(Ve(),Ke("span",h7,"询问AI"))],8,u7)])])],4)):Sr("",!0),c.value?Sr("",!0):(Ve(),Ke("div",{key:2,ref_key:"mindmapEl",ref:r,class:"mindmap-el"},null,512)),c.value?Sr("",!0):(Ve(),Ke("div",f7,[Y("button",{onClick:Q,class:"save-btn",title:"保存思维导图",style:{display:"none"}},[...E[3]||(E[3]=[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:be,class:"refresh-btn",title:"刷新思维导图",style:{display:"none"}},[...E[4]||(E[4]=[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?(Ve(),Ke("div",{key:4,class:"context-menu",style:On(i.value)},[s.value.parentId||s.value.parent?(Ve(),Ke("div",{key:0,class:"context-menu-item",onClick:he,title:"Add a sibling card"},[...E[5]||(E[5]=[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)])])):Sr("",!0),Y("div",{class:"context-menu-item",onClick:U,title:"Add a child card"},[...E[6]||(E[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:"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:We,title:"Copy text"},[...E[7]||(E[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:"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:Ae,title:"Ask AI"},[...E[8]||(E[8]=[Ko('<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-ce711d91><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-ce711d91></path><path d="M13 8H7" data-v-ce711d91></path><path d="M17 12H7" data-v-ce711d91></path><circle cx="17" cy="8" r="1" data-v-ce711d91></circle></svg>',1)])]),Y("div",{class:"context-menu-item delete",onClick:ge,title:"Delete"},[...E[9]||(E[9]=[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)):Sr("",!0)]))}},m7=_o(p7,[["__scopeId","data-v-ce711d91"]]),g7="modulepreload",v7=function(t){return"/"+t},Nc={},Dc=function(e,r,n){if(!r||r.length===0)return e();const s=document.getElementsByTagName("link");return Promise.all(r.map(i=>{if(i=v7(i),i in Nc)return;Nc[i]=!0;const a=i.endsWith(".css"),o=a?'[rel="stylesheet"]':"";if(!!n)for(let d=s.length-1;d>=0;d--){const f=s[d];if(f.href===i&&(!a||f.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${i}"]${o}`))return;const c=document.createElement("link");if(c.rel=a?"stylesheet":g7,a||(c.as="script",c.crossOrigin=""),c.href=i,document.head.appendChild(c),a)return new Promise((d,f)=>{c.addEventListener("load",d),c.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${i}`)))})})).then(()=>e()).catch(i=>{const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=i,window.dispatchEvent(a),!a.defaultPrevented)throw i})};const b7={class:"ai-sidebar-wrapper"},y7=["title"],w7={key:0,width:"22",height:"22",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5"},x7={key:1,width:"22",height:"22",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5"},k7={class:"sidebar-content"},S7={class:"section"},T7={class:"input-group"},A7={key:0,class:"file-info"},E7={class:"file-details"},C7={class:"file-info-left"},M7={class:"file-name"},N7={class:"file-size"},D7={class:"button-group file-action-buttons"},R7=["disabled"],I7={key:0},_7={key:1},O7={key:0,class:"section"},L7={class:"history-list"},z7=["onClick"],F7={class:"history-title"},$7={class:"history-time"},B7={class:"section"},P7={class:"input-group"},H7={class:"button-group"},q7=["disabled"],j7={key:0},U7={key:1},V7={class:"section"},W7={key:0,class:"processing-status"},G7={class:"result-container"},K7={class:"json-result"},Y7={class:"button-group"},X7=["disabled"],J7={__name:"AISidebar",emits:["start-realtime-generation"],setup(t,{emit:e}){const r=e,n=ze(!1),s=ze(""),i=ze(""),a=ze(""),o=ze(!1),l=ze(!1),c=ze([]),d=ze(!1);ze(""),ze("");const f=ze(!1),p=ze(""),b=ze(null),v=ze(null),x=()=>{n.value=!n.value,window.dispatchEvent(new CustomEvent("ai-sidebar-toggle",{detail:{isCollapsed:n.value}}))},y=j=>{const V=j.target.files[0];V&&(v.value=V,Me("文件上传成功!","success"))},M=j=>{j.preventDefault(),d.value=!1;const V=j.dataTransfer.files;if(V.length>0){const re=V[0],ie=[".txt",".md",".doc",".docx",".pdf"],Ee="."+re.name.split(".").pop().toLowerCase();ie.includes(Ee)?(v.value=re,Me("文件拖拽上传成功!","success")):Me("不支持的文件格式!请上传 .txt, .md, .doc, .docx, .pdf 格式的文件","error")}},k=j=>{j.preventDefault(),d.value=!0},T=j=>{j.preventDefault(),d.value=!1},N=()=>{v.value=null,b.value&&(b.value.value="")},I=j=>{if(j===0)return"0 Bytes";const V=1024,re=["Bytes","KB","MB","GB"],ie=Math.floor(Math.log(j)/Math.log(V));return parseFloat((j/Math.pow(V,ie)).toFixed(2))+" "+re[ie]},O=async()=>{if(!v.value){Me("请先上传文件","error");return}o.value=!0,r("start-realtime-generation");try{const j=await z(v.value);i.value="";const V="你是一个专业的文档分析专家。请分析上传的文档内容,生成结构化的Markdown格式思维导图。要求:1. 提取主要主题和关键概念 2. 组织成层次分明的结构 3. 使用清晰的标题和子标题 4. 保持内容的逻辑性和完整性",re=`请分析以下文档内容并生成结构化Markdown:
|
||
|
||
${j}`;await he(V,re),await Ae(),We(v.value.name,i.value),setTimeout(async()=>{try{await ve()}catch(ie){console.error("自动保存失败:",ie)}},1500)}catch(j){console.error("从文件生成Markdown失败:",j),Me("生成失败: "+j.message,"error")}finally{o.value=!1}},z=j=>new Promise(async(V,re)=>{try{const ie=j.type.includes("text")||j.name.endsWith(".txt")||j.name.endsWith(".md"),Ee=j.type==="application/vnd.openxmlformats-officedocument.wordprocessingml.document"||j.type==="application/msword"||j.name.endsWith(".docx")||j.name.endsWith(".doc"),ye=j.type==="application/pdf"||j.name.endsWith(".pdf");if(ie){const fe=new FileReader;fe.onload=Ue=>V(Ue.target.result),fe.onerror=()=>re(new Error("文本文件读取失败")),fe.readAsText(j)}else if(Ee){const fe=await W(j);V(fe)}else if(ye){const fe=await U(j);V(fe)}else{const fe=new FileReader;fe.onload=Ue=>V(Ue.target.result),fe.onerror=()=>re(new Error("文件读取失败")),fe.readAsText(j)}}catch(ie){re(ie)}}),W=async j=>{try{if(j.name.endsWith(".docx")){const V=await Dc(()=>import("./index-c6bfb612.js").then(Ee=>Ee.i),[]),re=await j.arrayBuffer();return(await V.extractRawText({arrayBuffer:re})).value}else if(j.name.endsWith(".doc"))throw new Error("请将.doc文件转换为.docx格式,或安装相应的解析库")}catch(V){throw new Error(`Office文档解析失败: ${V.message}`)}},U=async j=>{try{const V=await Dc(()=>import("./pdf-869d0c0b.js"),[]);V.GlobalWorkerOptions.workerSrc="/pdf.worker.min.mjs";const re=await j.arrayBuffer(),ie=await V.getDocument({data:re}).promise;let Ee="";for(let ye=1;ye<=ie.numPages;ye++){const S=(await(await ie.getPage(ye)).getTextContent()).items.map(D=>D.str).join(" ");Ee+=S+`
|
||
`}return Ee}catch(V){throw new Error(`PDF文件解析失败: ${V.message}`)}},he=async(j,V)=>{const ie=j||`你是一位Markdown格式转换专家。你的任务是将用户提供的文章内容精确转换为结构化的Markdown格式。请遵循以下步骤:
|
||
|
||
提取主标题: 识别文章最顶层的主标题(通常为文章题目或书名),并使用Markdown的 # 级别表示。
|
||
|
||
识别层级标题: 从文章内容中提取所有层级的内容标题(从主标题后的第一个标题开始,Level 1 至 Level 4)。判断层级依据:
|
||
|
||
视觉与结构特征: 如独立成行/段、位置(行首)、格式(加粗、编号如 1., 1.1, (1), - 等)。
|
||
|
||
语义逻辑: 标题之间的包含和并列关系。
|
||
|
||
在Markdown中,使用相应标题级别:
|
||
|
||
Level 1 标题用 ##
|
||
|
||
Level 2 标题用 ###
|
||
|
||
Level 3 标题用 ####
|
||
|
||
Level 4 标题用 #####
|
||
|
||
精确保留原文标题文字,不得修改、概括或润色。
|
||
|
||
处理正文内容: 对于每个标题下的正文内容区块(从该标题后开始,直到下一个同级或更高级别标题前):
|
||
|
||
直接保留原文文本,但根据内容结构适当格式化为Markdown。
|
||
|
||
如果内容是列表(如项目符号或编号列表),使用Markdown列表语法(例如 - 用于无序列表,1. 用于有序列表)。
|
||
|
||
保持段落和换行不变。
|
||
|
||
输出格式: 输出必须是纯Markdown格式的文本,不得包含任何额外说明、JSON或非Markdown元素。确保输出与示例风格一致。`,Ee=V||"请将以下内容转换为结构化的Markdown格式:";try{const ye=await fetch("http://127.0.0.1:8000/api/ai/generate-stream",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({system_prompt:ie,user_prompt:Ee,model:"glm-4.5",base_url:"https://open.bigmodel.cn/api/paas/v4/",api_key:"ce39bdd4fcf34ec0aec75072bc9ff988.hAp7HZTVUwy7vImn"})});if(!ye.ok)throw new Error(`HTTP error! status: ${ye.status}`);const fe=ye.body.getReader(),Ue=new TextDecoder;let S="",D=0;for(;;){const{done:F,value:G}=await fe.read();if(F)break;S+=Ue.decode(G,{stream:!0});const q=S.split(`
|
||
`);S=q.pop()||"";for(const H of q)if(H.startsWith("data: "))try{const X=JSON.parse(H.slice(6));if(X.type==="start")Me("AI开始生成内容...","info");else if(X.type==="chunk"){D++,i.value+=X.content;try{const ne=et(i.value);a.value=JSON.stringify(ne,null,2),window.dispatchEvent(new CustomEvent("realtime-mindmap-update",{detail:{data:ne,title:ne.topic||"AI生成中...",source:"ai-streaming",chunkCount:D}}))}catch(ne){console.warn("⚠️ 实时转换JSON失败:",ne),console.warn("⚠️ 当前Markdown内容:",i.value)}}else if(X.type==="end")Me("AI内容生成完成!","success");else if(X.type==="error")throw new Error(X.content)}catch(X){console.warn("解析流式数据失败:",X)}}}catch(ye){throw console.error("流式AI API调用失败:",ye),ye}},ge=j=>{if(j.includes("|")&&j.includes("-")){const V=j.split(`
|
||
`);let re=!1,ie=!1;for(const Ee of V){const ye=Ee.trim();ye.includes("|")&&ye.split("|").length>=3&&(re=!0),ye.includes("|")&&ye.includes("-")&&/^[\s\|\-\:]+$/.test(ye)&&(ie=!0)}if(re&&ie)return console.log("🚫 formatMarkdownToText: 检测到表格内容,跳过转换"),j}return j.replace(/^### (.*$)/gim,"📋 $1").replace(/^## (.*$)/gim,"📌 $1").replace(/^# (.*$)/gim,"🎯 $1").replace(/\*\*(.*?)\*\*/g,(V,re)=>{if(re.includes(":")){const ie=re.split(":");if(ie.length>1)return`【${ie[0]}】: ${ie.slice(1).join(":")}`}return`【${re}】`}).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,`
|
||
`)},Ae=async()=>{if(!i.value.trim()){Me("请输入Markdown内容","error");return}l.value=!0;try{const j=et(i.value);a.value=JSON.stringify(j,null,2)}catch(j){console.error("转换失败:",j),Me("转换失败,请检查Markdown格式","error")}finally{l.value=!1}},et=j=>{const V=j.split(`
|
||
`);let re=null;const ie=[];let Ee=0,ye=[];if(V.forEach((fe,Ue)=>{const S=fe.trim(),D=S.match(/^(#{1,6})\s+(.+)$/);if(D){if(ye.length>0&&ie.length>0){const X=ye.join(`
|
||
`).trim();X&&(Ee=Je(X,ie[ie.length-1],Ee).nodeCounter),ye=[]}const F=D[1].length,G=D[2].trim(),q=ge(G),H={id:`node_${Ee++}`,topic:q,children:[],level:F,data:{}};if(F===1&&!re)re=H,ie.length=0,ie.push(re);else{for(;ie.length>1&&ie[ie.length-1].level>=F;)ie.pop();ie.length>0&&ie[ie.length-1].children.push(H),ie.push(H)}}else S&&ye.push(S)}),ye.length>0&&ie.length>0){const fe=ye.join(`
|
||
`).trim();fe&&(fe.includes("|")&&console.log("🔍 处理最后的内容(包含表格):",fe.substring(0,200)+"..."),Ee=Je(fe,ie[ie.length-1],Ee).nodeCounter)}return re||(re={id:"root",topic:"根节点",children:[],data:{}}),re},Je=(j,V,re)=>{if(ot(j)){console.log("🎯 检测到表格内容,创建表格节点");const fe={id:`node_${re++}`,topic:j,children:[],level:(V.level||0)+1,data:{}};return V.children.push(fe),{nodeCounter:re}}const ie=j.split(`
|
||
`);let Ee=re,ye=[];for(let fe=0;fe<ie.length;fe++){const S=ie[fe].trim(),D=S.match(/^[-*+]\s*【(.+)】/);if(D){const F=D[1].trim(),G={id:`node_${Ee++}`,topic:F,children:[],level:(V.level||0)+1,data:{}};let q=[],H=fe+1;for(;H<ie.length;){const X=ie[H].trim();if(X.match(/^[-*+]\s*【(.+)】/))break;const se=X.match(/^[-*+]\s+(.+)$/);if(se){const Q=se[1].trim(),be=ge(Q);q.push("• "+be)}H++}if(q.length>0){const X=ge(q.join(`
|
||
`));G.topic=G.topic+`
|
||
|
||
`+X}V.children.push(G),fe=H-1}else S&&ye.push(S)}if(ye.length>0){const fe=ye.join(`
|
||
`).trim();if(fe)if(ot(fe)){console.log("🎯 检测到表格内容,创建表格节点");const Ue={id:`node_${Ee++}`,topic:fe,children:[],level:(V.level||0)+1,data:{}};V.children.push(Ue)}else fe.split(`
|
||
|
||
`).filter(S=>S.trim()).forEach(S=>{const D=ge(S.trim());if(D){const F={id:`node_${Ee++}`,topic:D,children:[],level:(V.level||0)+1,data:{}};V.children.push(F)}})}return{nodeCounter:Ee}},ot=j=>{if(!j||typeof j!="string")return!1;j.includes("|")&&console.log("🔍 检查表格内容:",j.substring(0,200)+"...");const V=j.split(`
|
||
`);let re=!1,ie=!1;for(const Ue of V){const S=Ue.trim();S.includes("|")&&S.split("|").length>=3&&(re=!0,console.log("✅ 找到表格行:",S)),S.includes("|")&&S.includes("-")&&/^[\s\|\-\:]+$/.test(S)&&(ie=!0,console.log("✅ 找到分隔符行:",S))}const Ee=(j.match(/\|/g)||[]).length,ye=Ee>=4,fe=re&&ie||re&&ye;return console.log("🔍 表格检测结果:",{hasTableRow:re,hasSeparator:ie,pipeCount:Ee,hasMultiplePipes:ye,result:fe}),fe},Fe=async()=>{if(!i.value){Me("没有Markdown内容可复制","error");return}try{await navigator.clipboard.writeText(i.value),Me("Markdown已复制到剪贴板","success")}catch{const V=document.createElement("textarea");V.value=i.value,document.body.appendChild(V),V.select(),document.execCommand("copy"),V.remove(),Me("Markdown已复制到剪贴板","success")}},Ie=async()=>{try{await navigator.clipboard.writeText(a.value),Me("JSON已复制到剪贴板","success")}catch(j){console.error("复制失败:",j),Me("复制失败","error")}},ve=async()=>{if(!a.value){Me("请先生成或转换JSON数据","error");return}try{const j=JSON.parse(a.value),V=j.topic||j.title||`AI生成的思维导图_${new Date().toLocaleString()}`,re=new CustomEvent("save-preview-to-database",{detail:{data:j,title:V,source:"ai-generated",timestamp:Date.now()}});window.dispatchEvent(re),setTimeout(()=>{Me("思维导图已保存成功!","success"),v.value=null,b.value&&(b.value.value="")},2e3)}catch(j){console.error("JSON解析失败:",j),Me("JSON格式错误,请检查数据","error")}},Me=(j,V="info")=>{const re=document.createElement("div");switch(re.className=`notification notification-${V}`,re.textContent=j,re.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;
|
||
`,V){case"success":re.style.background="#4CAF50",re.style.color="white";break;case"error":re.style.background="#f44336",re.style.color="white";break;case"info":default:re.style.background="#2196F3",re.style.color="white";break}if(!document.querySelector("#notification-styles")){const ie=document.createElement("style");ie.id="notification-styles",ie.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(ie)}document.body.appendChild(re),setTimeout(()=>{re.style.animation="slideOut 0.3s ease",setTimeout(()=>{re.parentNode&&re.parentNode.removeChild(re)},300)},3e3)},tt=()=>{i.value="",a.value="",Me("内容已清空","info")},We=(j,V,re=null)=>{const ie={title:j,content:V,mindmapId:re,timestamp:new Date};c.value.unshift(ie),c.value.length>10&&(c.value=c.value.slice(0,10)),localStorage.setItem("ai-sidebar-history",JSON.stringify(c.value))},_e=async j=>{j.mindmapId?window.dispatchEvent(new CustomEvent("loadMindmapFromHistory",{detail:{mindmapId:j.mindmapId,title:j.title}})):(i.value=j.content,await Ae(),window.dispatchEvent(new CustomEvent("loadMindmapFromHistory",{detail:{markdown:j.content,json:a.value,title:j.title}})))},St=j=>new Date(j).toLocaleString("zh-CN");Oa(()=>{const j=localStorage.getItem("ai-sidebar-history");if(j)try{c.value=JSON.parse(j)}catch(V){console.error("加载历史记录失败:",V)}window.addEventListener("add-to-history",V=>{const{title:re,content:ie,timestamp:Ee}=V.detail;We(re,ie,null)}),window.addEventListener("mindmap-saved",V=>{const{mindmapId:re,title:ie,timestamp:Ee}=V.detail,ye=c.value.find(fe=>fe.title===ie||fe.timestamp&&Math.abs(fe.timestamp-Ee)<5e3);ye?(ye.mindmapId=re,localStorage.setItem("ai-sidebar-history",JSON.stringify(c.value))):We(ie,"",re)}),i0(s,(V,re)=>{}),i0(i,(V,re)=>{})});const mt=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 V=j.body.getReader(),re=new TextDecoder;let ie="";for(;;){const{done:Ee,value:ye}=await V.read();if(Ee)break;ie+=re.decode(ye,{stream:!0});const fe=ie.split(`
|
||
`);ie=fe.pop()||"";for(const Ue of fe)if(Ue.startsWith("data: "))try{const S=JSON.parse(Ue.slice(6))}catch(S){console.warn("解析测试数据失败:",S)}}}catch(j){console.error("❌ 测试流式API失败:",j)}};return window.testStreamAPI=mt,(j,V)=>(Ve(),Ke("div",b7,[Y("div",{class:"sidebar-toggle",onClick:x,title:n.value?"展开AI助手":"折叠AI助手",style:On({left:n.value?"10px":"420px"})},[n.value?(Ve(),Ke("svg",w7,[...V[1]||(V[1]=[Y("path",{d:"M9 18l6-6-6-6"},null,-1)])])):(Ve(),Ke("svg",x7,[...V[2]||(V[2]=[Y("path",{d:"M15 18l-6-6 6-6"},null,-1)])]))],12,y7),Y("div",{class:Ln(["ai-sidebar",{"sidebar-collapsed":n.value}])},[ds(Y("div",k7,[V[12]||(V[12]=Y("div",{class:"sidebar-header"},[Y("h3",null,"🤖 AI 助手"),Y("p",null,"文档转思维导图工具"),Y("div",{class:"collapse-hint"},[Y("small",null,"💡 点击右侧按钮可折叠侧边栏")])],-1)),Y("div",S7,[V[6]||(V[6]=Y("h4",null,"📁 生成思维导图",-1)),Y("div",T7,[V[4]||(V[4]=Y("label",null,"上传文件:",-1)),Y("div",{class:"file-upload-area",onDrop:M,onDragover:k,onDragleave:T},[Y("input",{type:"file",ref_key:"fileInput",ref:b,onChange:y,accept:".txt,.md,.doc,.docx,.pdf",class:"file-input"},null,544),Y("div",{class:Ln(["file-upload-placeholder",{"drag-over":d.value}])},[...V[3]||(V[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)]),v.value?(Ve(),Ke("div",A7,[Y("div",E7,[Y("div",C7,[Y("span",M7,"📄 "+ur(v.value.name),1),Y("span",N7,"("+ur(I(v.value.size))+")",1)]),Y("button",{onClick:N,class:"btn-remove",title:"删除文件"},[...V[5]||(V[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)])])])])):Sr("",!0),Y("div",D7,[Y("button",{onClick:O,disabled:!v.value||o.value,class:"btn-primary"},[o.value?(Ve(),Ke("span",I7,"AI生成中...")):(Ve(),Ke("span",_7,"AI生成思维导图"))],8,R7)])]),c.value.length>0?(Ve(),Ke("div",O7,[V[7]||(V[7]=Y("h4",null,"📚 历史记录",-1)),Y("div",L7,[(Ve(!0),Ke(er,null,du(c.value,(re,ie)=>(Ve(),Ke("div",{key:ie,class:"history-item",onClick:Ee=>_e(re)},[Y("div",F7,ur(re.title),1),Y("div",$7,ur(St(re.timestamp)),1)],8,z7))),128))])])):Sr("",!0),Y("div",B7,[V[9]||(V[9]=Y("h4",null,"📝 AI生成的Markdown结果",-1)),Y("div",P7,[V[8]||(V[8]=Y("label",null,"Markdown内容:",-1)),ds(Y("textarea",{"onUpdate:modelValue":V[0]||(V[0]=re=>i.value=re),placeholder:"AI生成的Markdown内容将显示在这里",rows:"6",readonly:"",class:"markdown-result"},null,512),[[Pa,i.value]])]),Y("div",H7,[Y("button",{onClick:Ae,disabled:l.value,class:"btn-secondary"},[l.value?(Ve(),Ke("span",j7,"转换中...")):(Ve(),Ke("span",U7,"🔄 转换为JSON"))],8,q7),Y("button",{onClick:tt,class:"btn-clear"},"清空"),Y("button",{onClick:Fe,class:"btn-copy"},"📋 复制Markdown")])]),Y("div",V7,[V[11]||(V[11]=Y("h4",null,"📊 Markdown转JSON结果",-1)),f.value?(Ve(),Ke("div",W7,[V[10]||(V[10]=Y("div",{class:"spinner"},null,-1)),Y("span",null,ur(p.value),1)])):Sr("",!0),Y("div",G7,[Y("pre",K7,ur(a.value||"JSON转换结果将显示在这里"),1),Y("div",Y7,[Y("button",{onClick:Ie,class:"btn-copy"},"📋 复制JSON"),Y("button",{onClick:ve,disabled:f.value,class:"btn-copy"},ur(f.value?"处理中...":"👁️ 预览"),9,X7)])])])],512),[[Lf,!n.value]])],2)]))}},Z7=_o(J7,[["__scopeId","data-v-d0b1a702"]]);const Q7={class:"markdown-test"},e8={class:"test-section"},t8={class:"test-section"},r8=["innerHTML"],n8={class:"test-section"},s8={class:"test-cases"},i8=["onClick"],a8={__name:"MarkdownTest",setup(t){const e=ze(`# 测试标题
|
||
|
||
这是一个**粗体**和*斜体*的测试。
|
||
|
||
## 表格测试
|
||
|
||
| 产品 | 价格 | 库存 |
|
||
|------|------|------|
|
||
| 苹果 | 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=ze([{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=Ou(()=>{if(!e.value)return"";try{return ya(e.value)}catch(a){return`<div class="error">渲染失败: ${a.message}</div>`}}),s=()=>{},i=a=>{e.value=a.content};return(a,o)=>(Ve(),Ke("div",Q7,[o[4]||(o[4]=Y("h2",null,"Markdown渲染测试",-1)),Y("div",e8,[o[1]||(o[1]=Y("h3",null,"输入Markdown内容",-1)),ds(Y("textarea",{"onUpdate:modelValue":o[0]||(o[0]=l=>e.value=l),placeholder:"输入markdown内容...",rows:"10",class:"markdown-input"},null,512),[[Pa,e.value]])]),Y("div",t8,[o[2]||(o[2]=Y("h3",null,"渲染结果",-1)),Y("div",{class:"rendered-content",innerHTML:n.value},null,8,r8)]),Y("div",n8,[o[3]||(o[3]=Y("h3",null,"测试用例",-1)),Y("button",{onClick:s,class:"test-btn"},"加载测试用例"),Y("div",s8,[(Ve(!0),Ke(er,null,du(r.value,(l,c)=>(Ve(),Ke("button",{key:c,onClick:d=>i(l),class:"test-case-btn"},ur(l.name),9,i8))),128))])])]))}},o8=_o(a8,[["__scopeId","data-v-68a00828"]]);const l8={id:"app"},c8={class:"test-mode-toggle",style:{display:"none"}},u8={key:0,class:"test-mode"},d8={key:1},h8={class:"main-content"},f8={__name:"App",setup(t){const e=ze(null),r=ze(!1),n=()=>{r.value=!r.value},s=()=>{e.value&&e.value.showMindMapPage()};return(i,a)=>(Ve(),Ke("div",l8,[a[0]||(a[0]=Ru("« ",-1)),Y("div",c8,[Y("button",{onClick:n,class:"test-btn"},ur(r.value?"切换到思维导图":"测试Markdown渲染"),1)]),r.value?(Ve(),Ke("div",u8,[Ht(o8)])):(Ve(),Ke("div",d8,[Ht(Z7,{onStartRealtimeGeneration:s}),Y("div",h8,[Ht(m7,{ref_key:"mindMapRef",ref:e},null,512)])]))]))}};tp(f8).mount("#app");export{Dc as _,Wl as c,v8 as g};
|