function ownKeys(t,e){var i,r=Object.keys(t);return Object.getOwnPropertySymbols&&(i=Object.getOwnPropertySymbols(t),e&&(i=i.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,i)),r}function _objectSpread(t){for(var e=1;e=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(t){throw t},f:e};throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _unsupportedIterableToArray(t,e){var i;if(t)return"string"==typeof t?_arrayLikeToArray(t,e):"Map"===(i="Object"===(i={}.toString.call(t).slice(8,-1))&&t.constructor?t.constructor.name:i)||"Set"===i?Array.from(t):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?_arrayLikeToArray(t,e):void 0}function _arrayLikeToArray(t,e){(null==e||e>t.length)&&(e=t.length);for(var i=0,r=Array(e);i=Y[e]&&t<=Y[e+1])return!0;return!1}function i(t,i,r){if(!Z[i])throw new Error("Font metrics not found for font: "+i+".");var n=t.charCodeAt(0),a=Z[i][n];if(!a&&t[0]in Q&&(n=Q[t[0]].charCodeAt(0),a=Z[i][n]),a||"text"!==r||e(n)&&(a=Z[i][77]),a)return{depth:a[0],height:a[1],italic:a[2],skew:a[3],width:a[4]}}function r(t){if(t instanceof yt)return t;throw new Error("Expected symbolNode but got "+String(t)+".")}function n(t,e,i,r,n,a){Mt[t][n]={font:e,group:i,replace:r},a&&r&&(Mt[t][r]=Mt[t][n])}function a(t){for(var e=t.type,i=t.names,r=t.props,n=t.handler,a=t.htmlBuilder,o=t.mathmlBuilder,s={type:e,numArgs:r.numArgs,argTypes:r.argTypes,allowedInArgument:!!r.allowedInArgument,allowedInText:!!r.allowedInText,allowedInMath:void 0===r.allowedInMath||r.allowedInMath,numOptionalArgs:r.numOptionalArgs||0,infix:!!r.infix,primitive:!!r.primitive,handler:n},l=0;l0&&(o.push(s(l,e)),l=[]),o.push(n[h]));l.length>0&&o.push(s(l,e)),i?((a=s(Ie(i,e,!0))).classes=["tag"],o.push(a)):r&&o.push(r);var d=ze(["katex-html"],o);if(d.setAttribute("aria-hidden","true"),a){var u=a.children[0];u.style.height=ct(d.height+d.depth),d.depth&&(u.style.verticalAlign=ct(-d.depth))}return d}function h(t){return new K(t)}function c(t,e,i,r,n){var a,o=Ye(t,i);a=1===o.length&&o[0]instanceof Ve&&I.contains(["mrow","mtable"],o[0].type)?o[0]:new je.MathNode("mrow",o);var s=new je.MathNode("annotation",[new je.TextNode(e)]);s.setAttribute("encoding","application/x-tex");var l=new je.MathNode("semantics",[a,s]),h=new je.MathNode("math",[l]);h.setAttribute("xmlns","http://www.w3.org/1998/Math/MathML"),r&&h.setAttribute("display","block");var c=n?"katex":"katex-mathml";return be.makeSpan([c],[h])}function d(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 u(t){var e=p(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 p(t){return t&&("atom"===t.type||St.hasOwnProperty(t.type))?t:null}function m(t,e){var i=Ie(t.body,e,!0);return li([t.mclass],i,e)}function f(t,e){var i,r=Ye(t.body,e);return"minner"===t.mclass?i=new je.MathNode("mpadded",r):"mord"===t.mclass?t.isCharacterBox?(i=r[0]).type="mi":i=new je.MathNode("mi",r):(t.isCharacterBox?(i=r[0]).type="mo":i=new je.MathNode("mo",r),"mbin"===t.mclass?(i.attributes.lspace="0.22em",i.attributes.rspace="0.22em"):"mpunct"===t.mclass?(i.attributes.lspace="0em",i.attributes.rspace="0.17em"):"mopen"===t.mclass||"mclose"===t.mclass?(i.attributes.lspace="0em",i.attributes.rspace="0em"):"minner"===t.mclass&&(i.attributes.lspace="0.0556em",i.attributes.width="+0.1111em")),i}function g(t,e,i){var r=ci[t];switch(r){case"\\\\cdrightarrow":case"\\\\cdleftarrow":return i.callFunction(r,[e[0]],[e[1]]);case"\\uparrow":case"\\downarrow":var n={type:"atom",text:r,mode:"math",family:"rel"},a={type:"ordgroup",mode:"math",body:[i.callFunction("\\\\cdleft",[e[0]],[]),i.callFunction("\\Big",[n],[]),i.callFunction("\\\\cdright",[e[1]],[])]};return i.callFunction("\\\\cdparent",[a],[]);case"\\\\cdlongequal":return i.callFunction("\\\\cdlongequal",[],[]);case"\\Vert":return i.callFunction("\\Big",[{type:"textord",text:"\\Vert",mode:"math"}],[]);default:return{type:"textord",text:" ",mode:"math"}}}function v(t,e){var i=p(t);if(i&&I.contains(Vi,i.text))return i;throw new z(i?"Invalid delimiter '"+i.text+"' after '"+e.funcName+"'":"Invalid delimiter type '"+t.type+"'",t)}function b(t){if(!t.body)throw new Error("Bug: The leftright ParseNode wasn't fully parsed.")}function y(t){for(var e=t.type,i=t.names,r=t.props,n=t.handler,a=t.htmlBuilder,o=t.mathmlBuilder,s={type:e,numArgs:r.numArgs||0,allowedInText:!1,numOptionalArgs:0,handler:n},l=0;l1||!u)&&v.pop(),y.length15?"\u2026"+o.slice(i-15,i):o.slice(0,i))+s+(r+15":">","<":"<",'"':""","'":"'"},P=/[&><"']/g,E=function an(t){return"ordgroup"===t.type||"color"===t.type?1===t.body.length?an(t.body[0]):t:"font"===t.type?an(t.body):t},I={contains:function(t,e){return-1!==t.indexOf(e)},deflt:function(t,e){return void 0===t?e:t},escape:function(t){return String(t).replace(P,function(t){return L[t]})},hyphenate:function(t){return t.replace(O,"-$1").toLowerCase()},getBaseElem:E,isCharacterBox:function(t){var e=E(t);return"mathord"===e.type||"textord"===e.type||"atom"===e.type},protocolFromUrl:function(t){var e=/^\s*([^\\/#]*?)(?::|�*58|�*3a)/i.exec(t);return null!=e?e[1]:"_relative"}},D={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 "},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 ",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:function(t){return"#"+t}},macros:{type:"object",cli:"-m, --macro ",cliDescription:"Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).",cliDefault:[],cliProcessor:function(t,e){return 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:function(t){return Math.max(0,t)},cli:"--min-rule-thickness ",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:function(t){return Math.max(0,t)},cli:"-s, --max-size ",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:function(t){return Math.max(0,t)},cli:"-e, --max-expand ",cliProcessor:function(t){return"Infinity"===t?1/0:parseInt(t)}},globalGroup:{type:"boolean",cli:!1}},B=function(){function e(e){for(var i in 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||{},D)if(D.hasOwnProperty(i)){var r=D[i];this[i]=void 0!==e[i]?r.processor?r.processor(e[i]):e[i]:t(r)}}var i=e.prototype;return i.reportNonstrict=function(t,e,i){var r=this.strict;if("function"==typeof r&&(r=r(t,e,i)),r&&"ignore"!==r){if(!0===r||"error"===r)throw new z("LaTeX-incompatible input and strict mode is set to 'error': "+e+" ["+t+"]",i);"warn"===r?"undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+e+" ["+t+"]"):"undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to unrecognized '"+r+"': "+e+" ["+t+"]")}},i.useStrictBehavior=function(t,e,i){var r=this.strict;if("function"==typeof r)try{r=r(t,e,i)}catch(t){r="error"}return!(!r||"ignore"===r||!0!==r&&"error"!==r&&("warn"===r?("undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+e+" ["+t+"]"),1):("undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to unrecognized '"+r+"': "+e+" ["+t+"]"),1)))},i.isTrusted=function(t){t.url&&!t.protocol&&(t.protocol=I.protocolFromUrl(t.url));var e="function"==typeof this.trust?this.trust(t):this.trust;return Boolean(e)},e}(),R=function(){function t(t,e,i){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=t,this.size=e,this.cramped=i}var e=t.prototype;return e.sup=function(){return N[F[this.id]]},e.sub=function(){return N[H[this.id]]},e.fracNum=function(){return N[V[this.id]]},e.fracDen=function(){return N[q[this.id]]},e.cramp=function(){return N[j[this.id]]},e.text=function(){return N[W[this.id]]},e.isTight=function(){return this.size>=2},t}(),N=[new R(0,0,!1),new R(1,0,!0),new R(2,1,!1),new R(3,1,!0),new R(4,2,!1),new R(5,2,!0),new R(6,3,!1),new R(7,3,!0)],F=[4,5,4,5,6,7,6,7],H=[5,5,5,5,7,7,7,7],V=[2,3,4,5,6,7,6,7],q=[3,3,5,5,7,7,7,7],j=[1,1,3,3,5,5,7,7],W=[0,1,2,3,2,3,2,3],U={DISPLAY:N[0],TEXT:N[2],SCRIPT:N[4],SCRIPTSCRIPT:N[6]},G=[{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]]}],Y=[];G.forEach(function(t){return t.blocks.forEach(function(t){return Y.push.apply(Y,t)})});var $=80,X={doubleleftarrow:"M262 157\nl10-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\n 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\n 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\nc2 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\n 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\n-86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7\n-2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z\nm8 0v40h399730v-40zm0 194v40h399730v-40z",doublerightarrow:"M399738 392l\n-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\n 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\n-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\n-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\n-13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782\nc-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\n-107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z",leftarrow:"M400000 241H110l3-3c68.7-52.7 113.7-120\n 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\n-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\nc-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\n 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\n 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\n l-3-3h399890zM100 241v40h399900v-40z",leftbrace:"M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117\n-45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7\n 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\n 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\n 0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7\n-331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z",leftgroup:"M400000 80\nH435C64 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\n 435 0h399565z",leftgroupunder:"M400000 262\nH435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219\n 435 219h399565z",leftharpoon:"M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3\n-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\n-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\n-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\n 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\n-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\n-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z\nm0 0v40h400000v-40z",leftharpoondown:"M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333\n 5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5\n 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\n-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\n 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\n-2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0\nv40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z",lefthook:"M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5\n-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\n-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\n 71.5 23h399859zM103 281v-40h399897v40z",leftlinesegment:"M40 281 V428 H0 V94 H40 V241 H400000 v40z\nM40 281 V428 H0 V94 H40 V241 H400000 v40z",leftmapsto:"M40 281 V448H0V74H40V241H400000v40z\nM40 281 V448H0V74H40V241H400000v40z",leftToFrom:"M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23\n-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8\nc28.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\n 68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z",longequal:"M0 50 h400000 v40H0z m0 194h40000v40H0z\nM0 50 h400000 v40H0z m0 194h40000v40H0z",midbrace:"M200428 334\nc-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\n-53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7\n 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\n 12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z",midbraceunder:"M199572 214\nc100.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\n 53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3\n 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\n-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\n-320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z\nm368.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\n60.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\n-451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z\nm502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2\nc0 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\n-480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z\nm525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0\n85.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\n-707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z\nm770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1\nc0 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\n-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\n 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\n 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\n-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\n-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\n 151.7 139 205zm0 0v40h399900v-40z",rightbrace:"M400000 542l\n-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\ns-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1\nc124.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\n 28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237\n-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\n 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\n 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\n-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\n-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\n 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\n-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\n 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\nm0 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\n 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\n-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\n-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\n 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\n 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\n-64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z\nm0-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\n 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\n-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\n 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\nM399960 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\n 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32\n-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\n-167z M100 147v40h399900v-40zM0 341v40h399900v-40z",twoheadleftarrow:"M0 167c68 40\n 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\n-70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3\n-40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19\n-37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101\n 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\nc-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\n 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\n 18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333\n-19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70\n 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\n-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\n 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\n 4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128\n-68.267.847-113-73.952-191-73.952z",tilde2:"M344 55.266c-142 0-300.638 81.316-311.5 86.418\n-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\n 31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114\nc1 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\n 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\n-11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0\n 411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697\n 16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696\n -338 0-409-156.573-744-156.573z",tilde4:"M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345\n-11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409\n 177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9\n 14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409\n -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\n3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11\n10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63\n-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\n-7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59\nH213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359\nc-16-25.333-24-45-24-59z",widehat1:"M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22\nc-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\n-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\n-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\n-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,\n-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,\n-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,\n-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,\n-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\nc4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5\nc-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\ns-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\n121.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\ns2.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\nc0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z\nM100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z",rightarrowabovebar:"M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32\n-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\n13.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\n-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\n-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\n-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\n151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z",baraboveshortleftharpoon:"M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11\nc1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17\nc2,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\nc-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40\nc-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z\nM0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z",rightharpoonaboveshortbar:"M0,241 l0,40c399126,0,399993,0,399993,0\nc4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,\n-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\nc-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\nM0 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\nc1.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,\n1c0,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,\n-152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z\nM93 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\nc4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,\n-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\nc-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\nM500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z"},K=function(){function t(t){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=t,this.classes=[],this.height=0,this.depth=0,this.maxFontSize=0,this.style={}}var e=t.prototype;return e.hasClass=function(t){return I.contains(this.classes,t)},e.toNode=function(){for(var t=document.createDocumentFragment(),e=0;e=5?0:t>=3?1:2]){var i=tt[e]={cssEmPerMu:J.quad[e]/18};for(var r in J)J.hasOwnProperty(r)&&(i[r]=J[r][e])}return tt[e]}(this.size)),this._fontMetrics},e.getColor=function(){return this.phantom?"transparent":this.color},t}();nt.BASESIZE=6;var at=nt,ot={pt:1,mm:7227/2540,cm:7227/254,"in":72.27,bp:1.00375,pc:12,dd:1238/1157,cc:14856/1157,nd:685/642,nc:1370/107,sp:1/65536,px:1.00375},st={ex:!0,em:!0,mu:!0},lt=function(t){return"string"!=typeof t&&(t=t.unit),t in ot||t in st||"ex"===t},ht=function(t,e){var i;if(t.unit in ot)i=ot[t.unit]/e.fontMetrics().ptPerEm/e.sizeMultiplier;else if("mu"===t.unit)i=e.fontMetrics().cssEmPerMu;else{var r;if(r=e.style.isTight()?e.havingStyle(e.style.text()):e,"ex"===t.unit)i=r.fontMetrics().xHeight;else{if("em"!==t.unit)throw new z("Invalid unit: '"+t.unit+"'");i=r.fontMetrics().quad}r!==e&&(i*=r.sizeMultiplier/e.sizeMultiplier)}return Math.min(t.number*i,e.maxSize)},ct=function(t){return+t.toFixed(4)+"em"},dt=function(t){return t.filter(function(t){return t}).join(" ")},ut=function(t,e,i){if(this.classes=t||[],this.attributes={},this.height=0,this.depth=0,this.maxFontSize=0,this.style=i||{},e){e.style.isTight()&&this.classes.push("mtight");var r=e.getColor();r&&(this.style.color=r)}},pt=function(t){var e=document.createElement(t);for(var i in e.className=dt(this.classes),this.style)this.style.hasOwnProperty(i)&&(e.style[i]=this.style[i]);for(var r in this.attributes)this.attributes.hasOwnProperty(r)&&e.setAttribute(r,this.attributes[r]);for(var n=0;n"},ft=function(){function t(t,e,i,r){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,ut.call(this,t,i,r),this.children=e||[]}var e=t.prototype;return e.setAttribute=function(t,e){this.attributes[t]=e},e.hasClass=function(t){return I.contains(this.classes,t)},e.toNode=function(){return pt.call(this,"span")},e.toMarkup=function(){return mt.call(this,"span")},t}(),gt=function(){function t(t,e,i,r){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,ut.call(this,e,r),this.children=i||[],this.setAttribute("href",t)}var e=t.prototype;return e.setAttribute=function(t,e){this.attributes[t]=e},e.hasClass=function(t){return I.contains(this.classes,t)},e.toNode=function(){return pt.call(this,"a")},e.toMarkup=function(){return mt.call(this,"a")},t}(),vt=function(){function t(t,e,i){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=e,this.src=t,this.classes=["mord"],this.style=i}var e=t.prototype;return e.hasClass=function(t){return I.contains(this.classes,t)},e.toNode=function(){var t=document.createElement("img");for(var e in t.src=this.src,t.alt=this.alt,t.className="mord",this.style)this.style.hasOwnProperty(e)&&(t.style[e]=this.style[e]);return t},e.toMarkup=function(){var t=""+this.alt+""},t}(),bt={"\xee":"\u0131\u0302","\xef":"\u0131\u0308","\xed":"\u0131\u0301","\xec":"\u0131\u0300"},yt=function(){function t(t,e,i,r,n,a,o,s){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=t,this.height=e||0,this.depth=i||0,this.italic=r||0,this.skew=n||0,this.width=a||0,this.classes=o||[],this.style=s||{},this.maxFontSize=0;var l=function(t){for(var e=0;e=n[0]&&t<=n[1])return i.name}return null}(this.text.charCodeAt(0));l&&this.classes.push(l+"_fallback"),/[\xee\xef\xed\xec]/.test(this.text)&&(this.text=bt[this.text])}var e=t.prototype;return e.hasClass=function(t){return I.contains(this.classes,t)},e.toNode=function(){var t=document.createTextNode(this.text),e=null;for(var i in this.italic>0&&((e=document.createElement("span")).style.marginRight=ct(this.italic)),this.classes.length>0&&((e=e||document.createElement("span")).className=dt(this.classes)),this.style)this.style.hasOwnProperty(i)&&((e=e||document.createElement("span")).style[i]=this.style[i]);return e?(e.appendChild(t),e):t},e.toMarkup=function(){var t=!1,e="0&&(i+="margin-right:"+this.italic+"em;"),this.style)this.style.hasOwnProperty(r)&&(i+=I.hyphenate(r)+":"+this.style[r]+";");i&&(t=!0,e+=' style="'+I.escape(i)+'"');var n=I.escape(this.text);return t?(e+=">",e+=n,e+=""):n},t}(),xt=function(){function t(t,e){this.children=void 0,this.attributes=void 0,this.children=t||[],this.attributes=e||{}}var e=t.prototype;return e.toNode=function(){var t=document.createElementNS("http://www.w3.org/2000/svg","svg");for(var e in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,e)&&t.setAttribute(e,this.attributes[e]);for(var i=0;i"},t}(),wt=function(){function t(t,e){this.pathName=void 0,this.alternate=void 0,this.pathName=t,this.alternate=e}var e=t.prototype;return e.toNode=function(){var t=document.createElementNS("http://www.w3.org/2000/svg","path");return this.alternate?t.setAttribute("d",this.alternate):t.setAttribute("d",X[this.pathName]),t},e.toMarkup=function(){return this.alternate?"":""},t}(),kt=function(){function t(t){this.attributes=void 0,this.attributes=t||{}}var e=t.prototype;return e.toNode=function(){var t=document.createElementNS("http://www.w3.org/2000/svg","line");for(var e in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,e)&&t.setAttribute(e,this.attributes[e]);return t},e.toMarkup=function(){var t=""},t}(),_t={bin:1,close:1,inner:1,open:1,punct:1,rel:1},St={"accent-token":1,mathord:1,"op-token":1,spacing:1,textord:1},Mt={math:{},text:{}},At=Mt,Tt="math",Ct="text",zt="main",Ot="ams",Lt="accent-token",Pt="bin",Et="close",It="inner",Dt="mathord",Bt="op-token",Rt="open",Nt="punct",Ft="rel",Ht="spacing",Vt="textord";n(Tt,zt,Ft,"\u2261","\\equiv",!0),n(Tt,zt,Ft,"\u227a","\\prec",!0),n(Tt,zt,Ft,"\u227b","\\succ",!0),n(Tt,zt,Ft,"\u223c","\\sim",!0),n(Tt,zt,Ft,"\u22a5","\\perp"),n(Tt,zt,Ft,"\u2aaf","\\preceq",!0),n(Tt,zt,Ft,"\u2ab0","\\succeq",!0),n(Tt,zt,Ft,"\u2243","\\simeq",!0),n(Tt,zt,Ft,"\u2223","\\mid",!0),n(Tt,zt,Ft,"\u226a","\\ll",!0),n(Tt,zt,Ft,"\u226b","\\gg",!0),n(Tt,zt,Ft,"\u224d","\\asymp",!0),n(Tt,zt,Ft,"\u2225","\\parallel"),n(Tt,zt,Ft,"\u22c8","\\bowtie",!0),n(Tt,zt,Ft,"\u2323","\\smile",!0),n(Tt,zt,Ft,"\u2291","\\sqsubseteq",!0),n(Tt,zt,Ft,"\u2292","\\sqsupseteq",!0),n(Tt,zt,Ft,"\u2250","\\doteq",!0),n(Tt,zt,Ft,"\u2322","\\frown",!0),n(Tt,zt,Ft,"\u220b","\\ni",!0),n(Tt,zt,Ft,"\u221d","\\propto",!0),n(Tt,zt,Ft,"\u22a2","\\vdash",!0),n(Tt,zt,Ft,"\u22a3","\\dashv",!0),n(Tt,zt,Ft,"\u220b","\\owns"),n(Tt,zt,Nt,".","\\ldotp"),n(Tt,zt,Nt,"\u22c5","\\cdotp"),n(Tt,zt,Vt,"#","\\#"),n(Ct,zt,Vt,"#","\\#"),n(Tt,zt,Vt,"&","\\&"),n(Ct,zt,Vt,"&","\\&"),n(Tt,zt,Vt,"\u2135","\\aleph",!0),n(Tt,zt,Vt,"\u2200","\\forall",!0),n(Tt,zt,Vt,"\u210f","\\hbar",!0),n(Tt,zt,Vt,"\u2203","\\exists",!0),n(Tt,zt,Vt,"\u2207","\\nabla",!0),n(Tt,zt,Vt,"\u266d","\\flat",!0),n(Tt,zt,Vt,"\u2113","\\ell",!0),n(Tt,zt,Vt,"\u266e","\\natural",!0),n(Tt,zt,Vt,"\u2663","\\clubsuit",!0),n(Tt,zt,Vt,"\u2118","\\wp",!0),n(Tt,zt,Vt,"\u266f","\\sharp",!0),n(Tt,zt,Vt,"\u2662","\\diamondsuit",!0),n(Tt,zt,Vt,"\u211c","\\Re",!0),n(Tt,zt,Vt,"\u2661","\\heartsuit",!0),n(Tt,zt,Vt,"\u2111","\\Im",!0),n(Tt,zt,Vt,"\u2660","\\spadesuit",!0),n(Tt,zt,Vt,"\xa7","\\S",!0),n(Ct,zt,Vt,"\xa7","\\S"),n(Tt,zt,Vt,"\xb6","\\P",!0),n(Ct,zt,Vt,"\xb6","\\P"),n(Tt,zt,Vt,"\u2020","\\dag"),n(Ct,zt,Vt,"\u2020","\\dag"),n(Ct,zt,Vt,"\u2020","\\textdagger"),n(Tt,zt,Vt,"\u2021","\\ddag"),n(Ct,zt,Vt,"\u2021","\\ddag"),n(Ct,zt,Vt,"\u2021","\\textdaggerdbl"),n(Tt,zt,Et,"\u23b1","\\rmoustache",!0),n(Tt,zt,Rt,"\u23b0","\\lmoustache",!0),n(Tt,zt,Et,"\u27ef","\\rgroup",!0),n(Tt,zt,Rt,"\u27ee","\\lgroup",!0),n(Tt,zt,Pt,"\u2213","\\mp",!0),n(Tt,zt,Pt,"\u2296","\\ominus",!0),n(Tt,zt,Pt,"\u228e","\\uplus",!0),n(Tt,zt,Pt,"\u2293","\\sqcap",!0),n(Tt,zt,Pt,"\u2217","\\ast"),n(Tt,zt,Pt,"\u2294","\\sqcup",!0),n(Tt,zt,Pt,"\u25ef","\\bigcirc",!0),n(Tt,zt,Pt,"\u2219","\\bullet",!0),n(Tt,zt,Pt,"\u2021","\\ddagger"),n(Tt,zt,Pt,"\u2240","\\wr",!0),n(Tt,zt,Pt,"\u2a3f","\\amalg"),n(Tt,zt,Pt,"&","\\And"),n(Tt,zt,Ft,"\u27f5","\\longleftarrow",!0),n(Tt,zt,Ft,"\u21d0","\\Leftarrow",!0),n(Tt,zt,Ft,"\u27f8","\\Longleftarrow",!0),n(Tt,zt,Ft,"\u27f6","\\longrightarrow",!0),n(Tt,zt,Ft,"\u21d2","\\Rightarrow",!0),n(Tt,zt,Ft,"\u27f9","\\Longrightarrow",!0),n(Tt,zt,Ft,"\u2194","\\leftrightarrow",!0),n(Tt,zt,Ft,"\u27f7","\\longleftrightarrow",!0),n(Tt,zt,Ft,"\u21d4","\\Leftrightarrow",!0),n(Tt,zt,Ft,"\u27fa","\\Longleftrightarrow",!0),n(Tt,zt,Ft,"\u21a6","\\mapsto",!0),n(Tt,zt,Ft,"\u27fc","\\longmapsto",!0),n(Tt,zt,Ft,"\u2197","\\nearrow",!0),n(Tt,zt,Ft,"\u21a9","\\hookleftarrow",!0),n(Tt,zt,Ft,"\u21aa","\\hookrightarrow",!0),n(Tt,zt,Ft,"\u2198","\\searrow",!0),n(Tt,zt,Ft,"\u21bc","\\leftharpoonup",!0),n(Tt,zt,Ft,"\u21c0","\\rightharpoonup",!0),n(Tt,zt,Ft,"\u2199","\\swarrow",!0),n(Tt,zt,Ft,"\u21bd","\\leftharpoondown",!0),n(Tt,zt,Ft,"\u21c1","\\rightharpoondown",!0),n(Tt,zt,Ft,"\u2196","\\nwarrow",!0),n(Tt,zt,Ft,"\u21cc","\\rightleftharpoons",!0),n(Tt,Ot,Ft,"\u226e","\\nless",!0),n(Tt,Ot,Ft,"\ue010","\\@nleqslant"),n(Tt,Ot,Ft,"\ue011","\\@nleqq"),n(Tt,Ot,Ft,"\u2a87","\\lneq",!0),n(Tt,Ot,Ft,"\u2268","\\lneqq",!0),n(Tt,Ot,Ft,"\ue00c","\\@lvertneqq"),n(Tt,Ot,Ft,"\u22e6","\\lnsim",!0),n(Tt,Ot,Ft,"\u2a89","\\lnapprox",!0),n(Tt,Ot,Ft,"\u2280","\\nprec",!0),n(Tt,Ot,Ft,"\u22e0","\\npreceq",!0),n(Tt,Ot,Ft,"\u22e8","\\precnsim",!0),n(Tt,Ot,Ft,"\u2ab9","\\precnapprox",!0),n(Tt,Ot,Ft,"\u2241","\\nsim",!0),n(Tt,Ot,Ft,"\ue006","\\@nshortmid"),n(Tt,Ot,Ft,"\u2224","\\nmid",!0),n(Tt,Ot,Ft,"\u22ac","\\nvdash",!0),n(Tt,Ot,Ft,"\u22ad","\\nvDash",!0),n(Tt,Ot,Ft,"\u22ea","\\ntriangleleft"),n(Tt,Ot,Ft,"\u22ec","\\ntrianglelefteq",!0),n(Tt,Ot,Ft,"\u228a","\\subsetneq",!0),n(Tt,Ot,Ft,"\ue01a","\\@varsubsetneq"),n(Tt,Ot,Ft,"\u2acb","\\subsetneqq",!0),n(Tt,Ot,Ft,"\ue017","\\@varsubsetneqq"),n(Tt,Ot,Ft,"\u226f","\\ngtr",!0),n(Tt,Ot,Ft,"\ue00f","\\@ngeqslant"),n(Tt,Ot,Ft,"\ue00e","\\@ngeqq"),n(Tt,Ot,Ft,"\u2a88","\\gneq",!0),n(Tt,Ot,Ft,"\u2269","\\gneqq",!0),n(Tt,Ot,Ft,"\ue00d","\\@gvertneqq"),n(Tt,Ot,Ft,"\u22e7","\\gnsim",!0),n(Tt,Ot,Ft,"\u2a8a","\\gnapprox",!0),n(Tt,Ot,Ft,"\u2281","\\nsucc",!0),n(Tt,Ot,Ft,"\u22e1","\\nsucceq",!0),n(Tt,Ot,Ft,"\u22e9","\\succnsim",!0),n(Tt,Ot,Ft,"\u2aba","\\succnapprox",!0),n(Tt,Ot,Ft,"\u2246","\\ncong",!0),n(Tt,Ot,Ft,"\ue007","\\@nshortparallel"),n(Tt,Ot,Ft,"\u2226","\\nparallel",!0),n(Tt,Ot,Ft,"\u22af","\\nVDash",!0),n(Tt,Ot,Ft,"\u22eb","\\ntriangleright"),n(Tt,Ot,Ft,"\u22ed","\\ntrianglerighteq",!0),n(Tt,Ot,Ft,"\ue018","\\@nsupseteqq"),n(Tt,Ot,Ft,"\u228b","\\supsetneq",!0),n(Tt,Ot,Ft,"\ue01b","\\@varsupsetneq"),n(Tt,Ot,Ft,"\u2acc","\\supsetneqq",!0),n(Tt,Ot,Ft,"\ue019","\\@varsupsetneqq"),n(Tt,Ot,Ft,"\u22ae","\\nVdash",!0),n(Tt,Ot,Ft,"\u2ab5","\\precneqq",!0),n(Tt,Ot,Ft,"\u2ab6","\\succneqq",!0),n(Tt,Ot,Ft,"\ue016","\\@nsubseteqq"),n(Tt,Ot,Pt,"\u22b4","\\unlhd"),n(Tt,Ot,Pt,"\u22b5","\\unrhd"),n(Tt,Ot,Ft,"\u219a","\\nleftarrow",!0),n(Tt,Ot,Ft,"\u219b","\\nrightarrow",!0),n(Tt,Ot,Ft,"\u21cd","\\nLeftarrow",!0),n(Tt,Ot,Ft,"\u21cf","\\nRightarrow",!0),n(Tt,Ot,Ft,"\u21ae","\\nleftrightarrow",!0),n(Tt,Ot,Ft,"\u21ce","\\nLeftrightarrow",!0),n(Tt,Ot,Ft,"\u25b3","\\vartriangle"),n(Tt,Ot,Vt,"\u210f","\\hslash"),n(Tt,Ot,Vt,"\u25bd","\\triangledown"),n(Tt,Ot,Vt,"\u25ca","\\lozenge"),n(Tt,Ot,Vt,"\u24c8","\\circledS"),n(Tt,Ot,Vt,"\xae","\\circledR"),n(Ct,Ot,Vt,"\xae","\\circledR"),n(Tt,Ot,Vt,"\u2221","\\measuredangle",!0),n(Tt,Ot,Vt,"\u2204","\\nexists"),n(Tt,Ot,Vt,"\u2127","\\mho"),n(Tt,Ot,Vt,"\u2132","\\Finv",!0),n(Tt,Ot,Vt,"\u2141","\\Game",!0),n(Tt,Ot,Vt,"\u2035","\\backprime"),n(Tt,Ot,Vt,"\u25b2","\\blacktriangle"),n(Tt,Ot,Vt,"\u25bc","\\blacktriangledown"),n(Tt,Ot,Vt,"\u25a0","\\blacksquare"),n(Tt,Ot,Vt,"\u29eb","\\blacklozenge"),n(Tt,Ot,Vt,"\u2605","\\bigstar"),n(Tt,Ot,Vt,"\u2222","\\sphericalangle",!0),n(Tt,Ot,Vt,"\u2201","\\complement",!0),n(Tt,Ot,Vt,"\xf0","\\eth",!0),n(Ct,zt,Vt,"\xf0","\xf0"),n(Tt,Ot,Vt,"\u2571","\\diagup"),n(Tt,Ot,Vt,"\u2572","\\diagdown"),n(Tt,Ot,Vt,"\u25a1","\\square"),n(Tt,Ot,Vt,"\u25a1","\\Box"),n(Tt,Ot,Vt,"\u25ca","\\Diamond"),n(Tt,Ot,Vt,"\xa5","\\yen",!0),n(Ct,Ot,Vt,"\xa5","\\yen",!0),n(Tt,Ot,Vt,"\u2713","\\checkmark",!0),n(Ct,Ot,Vt,"\u2713","\\checkmark"),n(Tt,Ot,Vt,"\u2136","\\beth",!0),n(Tt,Ot,Vt,"\u2138","\\daleth",!0),n(Tt,Ot,Vt,"\u2137","\\gimel",!0),n(Tt,Ot,Vt,"\u03dd","\\digamma",!0),n(Tt,Ot,Vt,"\u03f0","\\varkappa"),n(Tt,Ot,Rt,"\u250c","\\@ulcorner",!0),n(Tt,Ot,Et,"\u2510","\\@urcorner",!0),n(Tt,Ot,Rt,"\u2514","\\@llcorner",!0),n(Tt,Ot,Et,"\u2518","\\@lrcorner",!0),n(Tt,Ot,Ft,"\u2266","\\leqq",!0),n(Tt,Ot,Ft,"\u2a7d","\\leqslant",!0),n(Tt,Ot,Ft,"\u2a95","\\eqslantless",!0),n(Tt,Ot,Ft,"\u2272","\\lesssim",!0),n(Tt,Ot,Ft,"\u2a85","\\lessapprox",!0),n(Tt,Ot,Ft,"\u224a","\\approxeq",!0),n(Tt,Ot,Pt,"\u22d6","\\lessdot"),n(Tt,Ot,Ft,"\u22d8","\\lll",!0),n(Tt,Ot,Ft,"\u2276","\\lessgtr",!0),n(Tt,Ot,Ft,"\u22da","\\lesseqgtr",!0),n(Tt,Ot,Ft,"\u2a8b","\\lesseqqgtr",!0),n(Tt,Ot,Ft,"\u2251","\\doteqdot"),n(Tt,Ot,Ft,"\u2253","\\risingdotseq",!0),n(Tt,Ot,Ft,"\u2252","\\fallingdotseq",!0),n(Tt,Ot,Ft,"\u223d","\\backsim",!0),n(Tt,Ot,Ft,"\u22cd","\\backsimeq",!0),n(Tt,Ot,Ft,"\u2ac5","\\subseteqq",!0),n(Tt,Ot,Ft,"\u22d0","\\Subset",!0),n(Tt,Ot,Ft,"\u228f","\\sqsubset",!0),n(Tt,Ot,Ft,"\u227c","\\preccurlyeq",!0),n(Tt,Ot,Ft,"\u22de","\\curlyeqprec",!0),n(Tt,Ot,Ft,"\u227e","\\precsim",!0),n(Tt,Ot,Ft,"\u2ab7","\\precapprox",!0),n(Tt,Ot,Ft,"\u22b2","\\vartriangleleft"),n(Tt,Ot,Ft,"\u22b4","\\trianglelefteq"),n(Tt,Ot,Ft,"\u22a8","\\vDash",!0),n(Tt,Ot,Ft,"\u22aa","\\Vvdash",!0),n(Tt,Ot,Ft,"\u2323","\\smallsmile"),n(Tt,Ot,Ft,"\u2322","\\smallfrown"),n(Tt,Ot,Ft,"\u224f","\\bumpeq",!0),n(Tt,Ot,Ft,"\u224e","\\Bumpeq",!0),n(Tt,Ot,Ft,"\u2267","\\geqq",!0),n(Tt,Ot,Ft,"\u2a7e","\\geqslant",!0),n(Tt,Ot,Ft,"\u2a96","\\eqslantgtr",!0),n(Tt,Ot,Ft,"\u2273","\\gtrsim",!0),n(Tt,Ot,Ft,"\u2a86","\\gtrapprox",!0),n(Tt,Ot,Pt,"\u22d7","\\gtrdot"),n(Tt,Ot,Ft,"\u22d9","\\ggg",!0),n(Tt,Ot,Ft,"\u2277","\\gtrless",!0),n(Tt,Ot,Ft,"\u22db","\\gtreqless",!0),n(Tt,Ot,Ft,"\u2a8c","\\gtreqqless",!0),n(Tt,Ot,Ft,"\u2256","\\eqcirc",!0),n(Tt,Ot,Ft,"\u2257","\\circeq",!0),n(Tt,Ot,Ft,"\u225c","\\triangleq",!0),n(Tt,Ot,Ft,"\u223c","\\thicksim"),n(Tt,Ot,Ft,"\u2248","\\thickapprox"),n(Tt,Ot,Ft,"\u2ac6","\\supseteqq",!0),n(Tt,Ot,Ft,"\u22d1","\\Supset",!0),n(Tt,Ot,Ft,"\u2290","\\sqsupset",!0),n(Tt,Ot,Ft,"\u227d","\\succcurlyeq",!0),n(Tt,Ot,Ft,"\u22df","\\curlyeqsucc",!0),n(Tt,Ot,Ft,"\u227f","\\succsim",!0),n(Tt,Ot,Ft,"\u2ab8","\\succapprox",!0),n(Tt,Ot,Ft,"\u22b3","\\vartriangleright"),n(Tt,Ot,Ft,"\u22b5","\\trianglerighteq"),n(Tt,Ot,Ft,"\u22a9","\\Vdash",!0),n(Tt,Ot,Ft,"\u2223","\\shortmid"),n(Tt,Ot,Ft,"\u2225","\\shortparallel"),n(Tt,Ot,Ft,"\u226c","\\between",!0),n(Tt,Ot,Ft,"\u22d4","\\pitchfork",!0),n(Tt,Ot,Ft,"\u221d","\\varpropto"),n(Tt,Ot,Ft,"\u25c0","\\blacktriangleleft"),n(Tt,Ot,Ft,"\u2234","\\therefore",!0),n(Tt,Ot,Ft,"\u220d","\\backepsilon"),n(Tt,Ot,Ft,"\u25b6","\\blacktriangleright"),n(Tt,Ot,Ft,"\u2235","\\because",!0),n(Tt,Ot,Ft,"\u22d8","\\llless"),n(Tt,Ot,Ft,"\u22d9","\\gggtr"),n(Tt,Ot,Pt,"\u22b2","\\lhd"),n(Tt,Ot,Pt,"\u22b3","\\rhd"),n(Tt,Ot,Ft,"\u2242","\\eqsim",!0),n(Tt,zt,Ft,"\u22c8","\\Join"),n(Tt,Ot,Ft,"\u2251","\\Doteq",!0),n(Tt,Ot,Pt,"\u2214","\\dotplus",!0),n(Tt,Ot,Pt,"\u2216","\\smallsetminus"),n(Tt,Ot,Pt,"\u22d2","\\Cap",!0),n(Tt,Ot,Pt,"\u22d3","\\Cup",!0),n(Tt,Ot,Pt,"\u2a5e","\\doublebarwedge",!0),n(Tt,Ot,Pt,"\u229f","\\boxminus",!0),n(Tt,Ot,Pt,"\u229e","\\boxplus",!0),n(Tt,Ot,Pt,"\u22c7","\\divideontimes",!0),n(Tt,Ot,Pt,"\u22c9","\\ltimes",!0),n(Tt,Ot,Pt,"\u22ca","\\rtimes",!0),n(Tt,Ot,Pt,"\u22cb","\\leftthreetimes",!0),n(Tt,Ot,Pt,"\u22cc","\\rightthreetimes",!0),n(Tt,Ot,Pt,"\u22cf","\\curlywedge",!0),n(Tt,Ot,Pt,"\u22ce","\\curlyvee",!0),n(Tt,Ot,Pt,"\u229d","\\circleddash",!0),n(Tt,Ot,Pt,"\u229b","\\circledast",!0),n(Tt,Ot,Pt,"\u22c5","\\centerdot"),n(Tt,Ot,Pt,"\u22ba","\\intercal",!0),n(Tt,Ot,Pt,"\u22d2","\\doublecap"),n(Tt,Ot,Pt,"\u22d3","\\doublecup"),n(Tt,Ot,Pt,"\u22a0","\\boxtimes",!0),n(Tt,Ot,Ft,"\u21e2","\\dashrightarrow",!0),n(Tt,Ot,Ft,"\u21e0","\\dashleftarrow",!0),n(Tt,Ot,Ft,"\u21c7","\\leftleftarrows",!0),n(Tt,Ot,Ft,"\u21c6","\\leftrightarrows",!0),n(Tt,Ot,Ft,"\u21da","\\Lleftarrow",!0),n(Tt,Ot,Ft,"\u219e","\\twoheadleftarrow",!0),n(Tt,Ot,Ft,"\u21a2","\\leftarrowtail",!0),n(Tt,Ot,Ft,"\u21ab","\\looparrowleft",!0),n(Tt,Ot,Ft,"\u21cb","\\leftrightharpoons",!0),n(Tt,Ot,Ft,"\u21b6","\\curvearrowleft",!0),n(Tt,Ot,Ft,"\u21ba","\\circlearrowleft",!0),n(Tt,Ot,Ft,"\u21b0","\\Lsh",!0),n(Tt,Ot,Ft,"\u21c8","\\upuparrows",!0),n(Tt,Ot,Ft,"\u21bf","\\upharpoonleft",!0),n(Tt,Ot,Ft,"\u21c3","\\downharpoonleft",!0),n(Tt,zt,Ft,"\u22b6","\\origof",!0),n(Tt,zt,Ft,"\u22b7","\\imageof",!0),n(Tt,Ot,Ft,"\u22b8","\\multimap",!0),n(Tt,Ot,Ft,"\u21ad","\\leftrightsquigarrow",!0),n(Tt,Ot,Ft,"\u21c9","\\rightrightarrows",!0),n(Tt,Ot,Ft,"\u21c4","\\rightleftarrows",!0),n(Tt,Ot,Ft,"\u21a0","\\twoheadrightarrow",!0),n(Tt,Ot,Ft,"\u21a3","\\rightarrowtail",!0),n(Tt,Ot,Ft,"\u21ac","\\looparrowright",!0),n(Tt,Ot,Ft,"\u21b7","\\curvearrowright",!0),n(Tt,Ot,Ft,"\u21bb","\\circlearrowright",!0),n(Tt,Ot,Ft,"\u21b1","\\Rsh",!0),n(Tt,Ot,Ft,"\u21ca","\\downdownarrows",!0),n(Tt,Ot,Ft,"\u21be","\\upharpoonright",!0),n(Tt,Ot,Ft,"\u21c2","\\downharpoonright",!0),n(Tt,Ot,Ft,"\u21dd","\\rightsquigarrow",!0),n(Tt,Ot,Ft,"\u21dd","\\leadsto"),n(Tt,Ot,Ft,"\u21db","\\Rrightarrow",!0),n(Tt,Ot,Ft,"\u21be","\\restriction"),n(Tt,zt,Vt,"\u2018","`"),n(Tt,zt,Vt,"$","\\$"),n(Ct,zt,Vt,"$","\\$"),n(Ct,zt,Vt,"$","\\textdollar"),n(Tt,zt,Vt,"%","\\%"),n(Ct,zt,Vt,"%","\\%"),n(Tt,zt,Vt,"_","\\_"),n(Ct,zt,Vt,"_","\\_"),n(Ct,zt,Vt,"_","\\textunderscore"),n(Tt,zt,Vt,"\u2220","\\angle",!0),n(Tt,zt,Vt,"\u221e","\\infty",!0),n(Tt,zt,Vt,"\u2032","\\prime"),n(Tt,zt,Vt,"\u25b3","\\triangle"),n(Tt,zt,Vt,"\u0393","\\Gamma",!0),n(Tt,zt,Vt,"\u0394","\\Delta",!0),n(Tt,zt,Vt,"\u0398","\\Theta",!0),n(Tt,zt,Vt,"\u039b","\\Lambda",!0),n(Tt,zt,Vt,"\u039e","\\Xi",!0),n(Tt,zt,Vt,"\u03a0","\\Pi",!0),n(Tt,zt,Vt,"\u03a3","\\Sigma",!0),n(Tt,zt,Vt,"\u03a5","\\Upsilon",!0),n(Tt,zt,Vt,"\u03a6","\\Phi",!0),n(Tt,zt,Vt,"\u03a8","\\Psi",!0),n(Tt,zt,Vt,"\u03a9","\\Omega",!0),n(Tt,zt,Vt,"A","\u0391"),n(Tt,zt,Vt,"B","\u0392"),n(Tt,zt,Vt,"E","\u0395"),n(Tt,zt,Vt,"Z","\u0396"),n(Tt,zt,Vt,"H","\u0397"),n(Tt,zt,Vt,"I","\u0399"),n(Tt,zt,Vt,"K","\u039a"),n(Tt,zt,Vt,"M","\u039c"),n(Tt,zt,Vt,"N","\u039d"),n(Tt,zt,Vt,"O","\u039f"),n(Tt,zt,Vt,"P","\u03a1"),n(Tt,zt,Vt,"T","\u03a4"),n(Tt,zt,Vt,"X","\u03a7"),n(Tt,zt,Vt,"\xac","\\neg",!0),n(Tt,zt,Vt,"\xac","\\lnot"),n(Tt,zt,Vt,"\u22a4","\\top"),n(Tt,zt,Vt,"\u22a5","\\bot"),n(Tt,zt,Vt,"\u2205","\\emptyset"),n(Tt,Ot,Vt,"\u2205","\\varnothing"),n(Tt,zt,Dt,"\u03b1","\\alpha",!0),n(Tt,zt,Dt,"\u03b2","\\beta",!0),n(Tt,zt,Dt,"\u03b3","\\gamma",!0),n(Tt,zt,Dt,"\u03b4","\\delta",!0),n(Tt,zt,Dt,"\u03f5","\\epsilon",!0),n(Tt,zt,Dt,"\u03b6","\\zeta",!0),n(Tt,zt,Dt,"\u03b7","\\eta",!0),n(Tt,zt,Dt,"\u03b8","\\theta",!0),n(Tt,zt,Dt,"\u03b9","\\iota",!0),n(Tt,zt,Dt,"\u03ba","\\kappa",!0),n(Tt,zt,Dt,"\u03bb","\\lambda",!0),n(Tt,zt,Dt,"\u03bc","\\mu",!0),n(Tt,zt,Dt,"\u03bd","\\nu",!0),n(Tt,zt,Dt,"\u03be","\\xi",!0),n(Tt,zt,Dt,"\u03bf","\\omicron",!0),n(Tt,zt,Dt,"\u03c0","\\pi",!0),n(Tt,zt,Dt,"\u03c1","\\rho",!0),n(Tt,zt,Dt,"\u03c3","\\sigma",!0),n(Tt,zt,Dt,"\u03c4","\\tau",!0),n(Tt,zt,Dt,"\u03c5","\\upsilon",!0),n(Tt,zt,Dt,"\u03d5","\\phi",!0),n(Tt,zt,Dt,"\u03c7","\\chi",!0),n(Tt,zt,Dt,"\u03c8","\\psi",!0),n(Tt,zt,Dt,"\u03c9","\\omega",!0),n(Tt,zt,Dt,"\u03b5","\\varepsilon",!0),n(Tt,zt,Dt,"\u03d1","\\vartheta",!0),n(Tt,zt,Dt,"\u03d6","\\varpi",!0),n(Tt,zt,Dt,"\u03f1","\\varrho",!0),n(Tt,zt,Dt,"\u03c2","\\varsigma",!0),n(Tt,zt,Dt,"\u03c6","\\varphi",!0),n(Tt,zt,Pt,"\u2217","*",!0),n(Tt,zt,Pt,"+","+"),n(Tt,zt,Pt,"\u2212","-",!0),n(Tt,zt,Pt,"\u22c5","\\cdot",!0),n(Tt,zt,Pt,"\u2218","\\circ",!0),n(Tt,zt,Pt,"\xf7","\\div",!0),n(Tt,zt,Pt,"\xb1","\\pm",!0),n(Tt,zt,Pt,"\xd7","\\times",!0),n(Tt,zt,Pt,"\u2229","\\cap",!0),n(Tt,zt,Pt,"\u222a","\\cup",!0),n(Tt,zt,Pt,"\u2216","\\setminus",!0),n(Tt,zt,Pt,"\u2227","\\land"),n(Tt,zt,Pt,"\u2228","\\lor"),n(Tt,zt,Pt,"\u2227","\\wedge",!0),n(Tt,zt,Pt,"\u2228","\\vee",!0),n(Tt,zt,Vt,"\u221a","\\surd"),n(Tt,zt,Rt,"\u27e8","\\langle",!0),n(Tt,zt,Rt,"\u2223","\\lvert"),n(Tt,zt,Rt,"\u2225","\\lVert"),n(Tt,zt,Et,"?","?"),n(Tt,zt,Et,"!","!"),n(Tt,zt,Et,"\u27e9","\\rangle",!0),n(Tt,zt,Et,"\u2223","\\rvert"),n(Tt,zt,Et,"\u2225","\\rVert"),n(Tt,zt,Ft,"=","="),n(Tt,zt,Ft,":",":"),n(Tt,zt,Ft,"\u2248","\\approx",!0),n(Tt,zt,Ft,"\u2245","\\cong",!0),n(Tt,zt,Ft,"\u2265","\\ge"),n(Tt,zt,Ft,"\u2265","\\geq",!0),n(Tt,zt,Ft,"\u2190","\\gets"),n(Tt,zt,Ft,">","\\gt",!0),n(Tt,zt,Ft,"\u2208","\\in",!0),n(Tt,zt,Ft,"\ue020","\\@not"),n(Tt,zt,Ft,"\u2282","\\subset",!0),n(Tt,zt,Ft,"\u2283","\\supset",!0),n(Tt,zt,Ft,"\u2286","\\subseteq",!0),n(Tt,zt,Ft,"\u2287","\\supseteq",!0),n(Tt,Ot,Ft,"\u2288","\\nsubseteq",!0),n(Tt,Ot,Ft,"\u2289","\\nsupseteq",!0),n(Tt,zt,Ft,"\u22a8","\\models"),n(Tt,zt,Ft,"\u2190","\\leftarrow",!0),n(Tt,zt,Ft,"\u2264","\\le"),n(Tt,zt,Ft,"\u2264","\\leq",!0),n(Tt,zt,Ft,"<","\\lt",!0),n(Tt,zt,Ft,"\u2192","\\rightarrow",!0),n(Tt,zt,Ft,"\u2192","\\to"),n(Tt,Ot,Ft,"\u2271","\\ngeq",!0),n(Tt,Ot,Ft,"\u2270","\\nleq",!0),n(Tt,zt,Ht,"\xa0","\\ "),n(Tt,zt,Ht,"\xa0","\\space"),n(Tt,zt,Ht,"\xa0","\\nobreakspace"),n(Ct,zt,Ht,"\xa0","\\ "),n(Ct,zt,Ht,"\xa0"," "),n(Ct,zt,Ht,"\xa0","\\space"),n(Ct,zt,Ht,"\xa0","\\nobreakspace"),n(Tt,zt,Ht,null,"\\nobreak"),n(Tt,zt,Ht,null,"\\allowbreak"),n(Tt,zt,Nt,",",","),n(Tt,zt,Nt,";",";"),n(Tt,Ot,Pt,"\u22bc","\\barwedge",!0),n(Tt,Ot,Pt,"\u22bb","\\veebar",!0),n(Tt,zt,Pt,"\u2299","\\odot",!0),n(Tt,zt,Pt,"\u2295","\\oplus",!0),n(Tt,zt,Pt,"\u2297","\\otimes",!0),n(Tt,zt,Vt,"\u2202","\\partial",!0),n(Tt,zt,Pt,"\u2298","\\oslash",!0),n(Tt,Ot,Pt,"\u229a","\\circledcirc",!0),n(Tt,Ot,Pt,"\u22a1","\\boxdot",!0),n(Tt,zt,Pt,"\u25b3","\\bigtriangleup"),n(Tt,zt,Pt,"\u25bd","\\bigtriangledown"),n(Tt,zt,Pt,"\u2020","\\dagger"),n(Tt,zt,Pt,"\u22c4","\\diamond"),n(Tt,zt,Pt,"\u22c6","\\star"),n(Tt,zt,Pt,"\u25c3","\\triangleleft"),n(Tt,zt,Pt,"\u25b9","\\triangleright"),n(Tt,zt,Rt,"{","\\{"),n(Ct,zt,Vt,"{","\\{"),n(Ct,zt,Vt,"{","\\textbraceleft"),n(Tt,zt,Et,"}","\\}"),n(Ct,zt,Vt,"}","\\}"),n(Ct,zt,Vt,"}","\\textbraceright"),n(Tt,zt,Rt,"{","\\lbrace"),n(Tt,zt,Et,"}","\\rbrace"),n(Tt,zt,Rt,"[","\\lbrack",!0),n(Ct,zt,Vt,"[","\\lbrack",!0),n(Tt,zt,Et,"]","\\rbrack",!0),n(Ct,zt,Vt,"]","\\rbrack",!0),n(Tt,zt,Rt,"(","\\lparen",!0),n(Tt,zt,Et,")","\\rparen",!0),n(Ct,zt,Vt,"<","\\textless",!0),n(Ct,zt,Vt,">","\\textgreater",!0),n(Tt,zt,Rt,"\u230a","\\lfloor",!0),n(Tt,zt,Et,"\u230b","\\rfloor",!0),n(Tt,zt,Rt,"\u2308","\\lceil",!0),n(Tt,zt,Et,"\u2309","\\rceil",!0),n(Tt,zt,Vt,"\\","\\backslash"),n(Tt,zt,Vt,"\u2223","|"),n(Tt,zt,Vt,"\u2223","\\vert"),n(Ct,zt,Vt,"|","\\textbar",!0),n(Tt,zt,Vt,"\u2225","\\|"),n(Tt,zt,Vt,"\u2225","\\Vert"),n(Ct,zt,Vt,"\u2225","\\textbardbl"),n(Ct,zt,Vt,"~","\\textasciitilde"),n(Ct,zt,Vt,"\\","\\textbackslash"),n(Ct,zt,Vt,"^","\\textasciicircum"),n(Tt,zt,Ft,"\u2191","\\uparrow",!0),n(Tt,zt,Ft,"\u21d1","\\Uparrow",!0),n(Tt,zt,Ft,"\u2193","\\downarrow",!0),n(Tt,zt,Ft,"\u21d3","\\Downarrow",!0),n(Tt,zt,Ft,"\u2195","\\updownarrow",!0),n(Tt,zt,Ft,"\u21d5","\\Updownarrow",!0),n(Tt,zt,Bt,"\u2210","\\coprod"),n(Tt,zt,Bt,"\u22c1","\\bigvee"),n(Tt,zt,Bt,"\u22c0","\\bigwedge"),n(Tt,zt,Bt,"\u2a04","\\biguplus"),n(Tt,zt,Bt,"\u22c2","\\bigcap"),n(Tt,zt,Bt,"\u22c3","\\bigcup"),n(Tt,zt,Bt,"\u222b","\\int"),n(Tt,zt,Bt,"\u222b","\\intop"),n(Tt,zt,Bt,"\u222c","\\iint"),n(Tt,zt,Bt,"\u222d","\\iiint"),n(Tt,zt,Bt,"\u220f","\\prod"),n(Tt,zt,Bt,"\u2211","\\sum"),n(Tt,zt,Bt,"\u2a02","\\bigotimes"),n(Tt,zt,Bt,"\u2a01","\\bigoplus"),n(Tt,zt,Bt,"\u2a00","\\bigodot"),n(Tt,zt,Bt,"\u222e","\\oint"),n(Tt,zt,Bt,"\u222f","\\oiint"),n(Tt,zt,Bt,"\u2230","\\oiiint"),n(Tt,zt,Bt,"\u2a06","\\bigsqcup"),n(Tt,zt,Bt,"\u222b","\\smallint"),n(Ct,zt,It,"\u2026","\\textellipsis"),n(Tt,zt,It,"\u2026","\\mathellipsis"),n(Ct,zt,It,"\u2026","\\ldots",!0),n(Tt,zt,It,"\u2026","\\ldots",!0),n(Tt,zt,It,"\u22ef","\\@cdots",!0),n(Tt,zt,It,"\u22f1","\\ddots",!0),n(Tt,zt,Vt,"\u22ee","\\varvdots"),n(Tt,zt,Lt,"\u02ca","\\acute"),n(Tt,zt,Lt,"\u02cb","\\grave"),n(Tt,zt,Lt,"\xa8","\\ddot"),n(Tt,zt,Lt,"~","\\tilde"),n(Tt,zt,Lt,"\u02c9","\\bar"),n(Tt,zt,Lt,"\u02d8","\\breve"),n(Tt,zt,Lt,"\u02c7","\\check"),n(Tt,zt,Lt,"^","\\hat"),n(Tt,zt,Lt,"\u20d7","\\vec"),n(Tt,zt,Lt,"\u02d9","\\dot"),n(Tt,zt,Lt,"\u02da","\\mathring"),n(Tt,zt,Dt,"\ue131","\\@imath"),n(Tt,zt,Dt,"\ue237","\\@jmath"),n(Tt,zt,Vt,"\u0131","\u0131"),n(Tt,zt,Vt,"\u0237","\u0237"),n(Ct,zt,Vt,"\u0131","\\i",!0),n(Ct,zt,Vt,"\u0237","\\j",!0),n(Ct,zt,Vt,"\xdf","\\ss",!0),n(Ct,zt,Vt,"\xe6","\\ae",!0),n(Ct,zt,Vt,"\u0153","\\oe",!0),n(Ct,zt,Vt,"\xf8","\\o",!0),n(Ct,zt,Vt,"\xc6","\\AE",!0),n(Ct,zt,Vt,"\u0152","\\OE",!0),n(Ct,zt,Vt,"\xd8","\\O",!0),n(Ct,zt,Lt,"\u02ca","\\'"),n(Ct,zt,Lt,"\u02cb","\\`"),n(Ct,zt,Lt,"\u02c6","\\^"),n(Ct,zt,Lt,"\u02dc","\\~"),n(Ct,zt,Lt,"\u02c9","\\="),n(Ct,zt,Lt,"\u02d8","\\u"),n(Ct,zt,Lt,"\u02d9","\\."),n(Ct,zt,Lt,"\xb8","\\c"),n(Ct,zt,Lt,"\u02da","\\r"),n(Ct,zt,Lt,"\u02c7","\\v"),n(Ct,zt,Lt,"\xa8",'\\"'),n(Ct,zt,Lt,"\u02dd","\\H"),n(Ct,zt,Lt,"\u25ef","\\textcircled");var qt={"--":!0,"---":!0,"``":!0,"''":!0};n(Ct,zt,Vt,"\u2013","--",!0),n(Ct,zt,Vt,"\u2013","\\textendash"),n(Ct,zt,Vt,"\u2014","---",!0),n(Ct,zt,Vt,"\u2014","\\textemdash"),n(Ct,zt,Vt,"\u2018","`",!0),n(Ct,zt,Vt,"\u2018","\\textquoteleft"),n(Ct,zt,Vt,"\u2019","'",!0),n(Ct,zt,Vt,"\u2019","\\textquoteright"),n(Ct,zt,Vt,"\u201c","``",!0),n(Ct,zt,Vt,"\u201c","\\textquotedblleft"),n(Ct,zt,Vt,"\u201d","''",!0),n(Ct,zt,Vt,"\u201d","\\textquotedblright"),n(Tt,zt,Vt,"\xb0","\\degree",!0),n(Ct,zt,Vt,"\xb0","\\degree"),n(Ct,zt,Vt,"\xb0","\\textdegree",!0),n(Tt,zt,Vt,"\xa3","\\pounds"),n(Tt,zt,Vt,"\xa3","\\mathsterling",!0),n(Ct,zt,Vt,"\xa3","\\pounds"),n(Ct,zt,Vt,"\xa3","\\textsterling",!0),n(Tt,Ot,Vt,"\u2720","\\maltese"),n(Ct,Ot,Vt,"\u2720","\\maltese");for(var jt='0123456789/@."',Wt=0;Wte&&(e=a.height),a.depth>i&&(i=a.depth),a.maxFontSize>r&&(r=a.maxFontSize)}t.height=e,t.depth=i,t.maxFontSize=r},ue=function(t,e,i,r){var n=new ft(t,e,i,r);return de(n),n},pe=function(t,e,i,r){return new ft(t,e,i,r)},me=function(t){var e=new K(t);return de(e),e},fe=function(t,e,i){var r="";switch(t){case"amsrm":r="AMS";break;case"textrm":r="Main";break;case"textsf":r="SansSerif";break;case"texttt":r="Typewriter";break;default:r=t}return r+"-"+("textbf"===e&&"textit"===i?"BoldItalic":"textbf"===e?"Bold":"textit"===e?"Italic":"Regular")},ge={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"},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"}},ve={vec:["vec",.471,.714],oiintSize1:["oiintSize1",.957,.499],oiintSize2:["oiintSize2",1.472,.659],oiiintSize1:["oiiintSize1",1.304,.499],oiiintSize2:["oiiintSize2",1.98,.659]},be={fontMap:ge,makeSymbol:he,mathsym:function(t,e,i,r){return void 0===r&&(r=[]),"boldsymbol"===i.font&&le(t,"Main-Bold",e).metrics?he(t,"Main-Bold",e,i,r.concat(["mathbf"])):"\\"===t||"main"===At[e][t].font?he(t,"Main-Regular",e,i,r):he(t,"AMS-Regular",e,i,r.concat(["amsrm"]))},makeSpan:ue,makeSvgSpan:pe,makeLineSpan:function(t,e,i){var r=ue([t],[],e);return r.height=Math.max(i||e.fontMetrics().defaultRuleThickness,e.minRuleThickness),r.style.borderBottomWidth=ct(r.height),r.maxFontSize=1,r},makeAnchor:function(t,e,i,r){var n=new gt(t,e,i,r);return de(n),n},makeFragment:me,wrapFragment:function(t,e){return t instanceof K?ue([],[t],e):t},makeVList:function(t){for(var e=function(t){if("individualShift"===t.positionType){for(var e=t.children,i=[e[0]],r=-e[0].shift-e[0].elem.depth,n=r,a=1;a0)return he(n,l,r,e,a.concat(h));if(s){var d,u;if("boldsymbol"===s){var p=function(t,e,i,r,a){return"textord"!==a&&le(n,"Math-BoldItalic",e).metrics?{fontName:"Math-BoldItalic",fontClass:"boldsymbol"}:{fontName:"Main-Bold",fontClass:"mathbf"}}(0,r,0,0,i);d=p.fontName,u=[p.fontClass]}else o?(d=ge[s].fontName,u=[s]):(d=fe(s,e.fontWeight,e.fontShape),u=[s,e.fontWeight,e.fontShape]);if(le(n,d,r).metrics)return he(n,d,r,e,a.concat(u));if(qt.hasOwnProperty(n)&&"Typewriter"===d.slice(0,10)){for(var m=[],f=0;f0&&(t.className=dt(this.classes));for(var i=0;i0&&(t+=' class ="'+I.escape(dt(this.classes))+'"'),t+=">";for(var i=0;i"},e.toText=function(){return this.children.map(function(t){return t.toText()}).join("")},t}(),qe=function(){function t(t){this.text=void 0,this.text=t}var e=t.prototype;return e.toNode=function(){return document.createTextNode(this.text)},e.toMarkup=function(){return I.escape(this.toText())},e.toText=function(){return this.text},t}(),je={MathNode:Ve,TextNode:qe,SpaceNode:function(){function t(t){this.width=void 0,this.character=void 0,this.width=t,this.character=t>=.05555&&t<=.05556?"\u200a":t>=.1666&&t<=.1667?"\u2009":t>=.2222&&t<=.2223?"\u2005":t>=.2777&&t<=.2778?"\u2005\u200a":t>=-.05556&&t<=-.05555?"\u200a\u2063":t>=-.1667&&t<=-.1666?"\u2009\u2063":t>=-.2223&&t<=-.2222?"\u205f\u2063":t>=-.2778&&t<=-.2777?"\u2005\u2063":null}var e=t.prototype;return e.toNode=function(){if(this.character)return document.createTextNode(this.character);var t=document.createElementNS("http://www.w3.org/1998/Math/MathML","mspace");return t.setAttribute("width",ct(this.width)),t},e.toMarkup=function(){return this.character?""+this.character+"":''},e.toText=function(){return this.character?this.character:" "},t}(),newDocumentFragment:h},We=function(t,e,i){return!At[e][t]||!At[e][t].replace||55349===t.charCodeAt(0)||qt.hasOwnProperty(t)&&i&&(i.fontFamily&&"tt"===i.fontFamily.slice(4,6)||i.font&&"tt"===i.font.slice(4,6))||(t=At[e][t].replace),new je.TextNode(t)},Ue=function(t){return 1===t.length?t[0]:new je.MathNode("mrow",t)},Ge=function(t,e){if("texttt"===e.fontFamily)return"monospace";if("textsf"===e.fontFamily)return"textit"===e.fontShape&&"textbf"===e.fontWeight?"sans-serif-bold-italic":"textit"===e.fontShape?"sans-serif-italic":"textbf"===e.fontWeight?"bold-sans-serif":"sans-serif";if("textit"===e.fontShape&&"textbf"===e.fontWeight)return"bold-italic";if("textit"===e.fontShape)return"italic";if("textbf"===e.fontWeight)return"bold";var r=e.font;if(!r||"mathnormal"===r)return null;var n=t.mode;if("mathit"===r)return"italic";if("boldsymbol"===r)return"textord"===t.type?"bold":"bold-italic";if("mathbf"===r)return"bold";if("mathbb"===r)return"double-struck";if("mathfrak"===r)return"fraktur";if("mathscr"===r||"mathcal"===r)return"script";if("mathsf"===r)return"sans-serif";if("mathtt"===r)return"monospace";var a=t.text;return I.contains(["\\imath","\\jmath"],a)?null:(At[n][a]&&At[n][a].replace&&(a=At[n][a].replace),i(a,be.fontMap[r].fontName,n)?be.fontMap[r].variant:null)},Ye=function(t,e,i){if(1===t.length){var r=Xe(t[0],e);return i&&r instanceof Ve&&"mo"===r.type&&(r.setAttribute("lspace","0em"),r.setAttribute("rspace","0em")),[r]}for(var n,a=[],o=0;o0&&(p.text=p.text.slice(0,1)+"\u0338"+p.text.slice(1),a.pop())}}}a.push(s),n=s}return a},$e=function(t,e,i){return Ue(Ye(t,e,i))},Xe=function(t,e){if(!t)return new je.MathNode("mrow");if(Ae[t.type])return Ae[t.type](t,e);throw new z("Got group of unknown type: '"+t.type+"'")},Ke=function(t){return new at({style:t.displayMode?U.DISPLAY:U.TEXT,maxSize:t.maxSize,minRuleThickness:t.minRuleThickness})},Ze=function(t,e){if(e.displayMode){var i=["katex-display"];e.leqno&&i.push("leqno"),e.fleqn&&i.push("fleqn"),t=be.makeSpan(i,[t])}return t},Je=function(t,e,i){var r,n=Ke(i);if("mathml"===i.output)return c(t,e,n,i.displayMode,!0);if("html"===i.output){var a=l(t,n);r=be.makeSpan(["katex"],[a])}else{var o=c(t,e,n,i.displayMode,!1),s=l(t,n);r=be.makeSpan(["katex"],[o,s])}return Ze(r,i)},Qe={widehat:"^",widecheck:"\u02c7",widetilde:"~",utilde:"~",overleftarrow:"\u2190",underleftarrow:"\u2190",xleftarrow:"\u2190",overrightarrow:"\u2192",underrightarrow:"\u2192",xrightarrow:"\u2192",underbrace:"\u23df",overbrace:"\u23de",overgroup:"\u23e0",undergroup:"\u23e1",overleftrightarrow:"\u2194",underleftrightarrow:"\u2194",xleftrightarrow:"\u2194",Overrightarrow:"\u21d2",xRightarrow:"\u21d2",overleftharpoon:"\u21bc",xleftharpoonup:"\u21bc",overrightharpoon:"\u21c0",xrightharpoonup:"\u21c0",xLeftarrow:"\u21d0",xLeftrightarrow:"\u21d4",xhookleftarrow:"\u21a9",xhookrightarrow:"\u21aa",xmapsto:"\u21a6",xrightharpoondown:"\u21c1",xleftharpoondown:"\u21bd",xrightleftharpoons:"\u21cc",xleftrightharpoons:"\u21cb",xtwoheadleftarrow:"\u219e",xtwoheadrightarrow:"\u21a0",xlongequal:"=",xtofrom:"\u21c4",xrightleftarrows:"\u21c4",xrightequilibrium:"\u21cc",xleftequilibrium:"\u21cb","\\cdrightarrow":"\u2192","\\cdleftarrow":"\u2190","\\cdlongequal":"="},ti={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]},ei=function(t,e,i,r,n){var a,o=t.height+t.depth+i+r;if(/fbox|color|angl/.test(e)){if(a=be.makeSpan(["stretchy",e],[],n),"fbox"===e){var s=n.color&&n.getColor();s&&(a.style.borderColor=s)}}else{var l=[];/^[bx]cancel$/.test(e)&&l.push(new kt({x1:"0",y1:"0",x2:"100%",y2:"100%","stroke-width":"0.046em"})),/^x?cancel$/.test(e)&&l.push(new kt({x1:"0",y1:"100%",x2:"100%",y2:"0","stroke-width":"0.046em"}));var h=new xt(l,{width:"100%",height:ct(o)});a=be.makeSvgSpan([],[h],n)}return a.height=o,a.style.height=ct(o),a},ii=function(t){var e=new je.MathNode("mo",[new je.TextNode(Qe[t.replace(/^\\/,"")])]);return e.setAttribute("stretchy","true"),e},ri=function(t,e){var i=function(){var i=4e5,r=t.label.slice(1);if(I.contains(["widehat","widecheck","widetilde","utilde"],r)){var n,a,o,s="ordgroup"===(p=t.base).type?p.body.length:1;if(s>5)"widehat"===r||"widecheck"===r?(n=420,i=2364,o=.42,a=r+"4"):(n=312,i=2340,o=.34,a="tilde4");else{var l=[1,1,2,2,3,3][s];"widehat"===r||"widecheck"===r?(i=[0,1062,2364,2364,2364][l],n=[0,239,300,360,420][l],o=[0,.24,.3,.3,.36,.42][l],a=r+l):(i=[0,600,1033,2339,2340][l],n=[0,260,286,306,312][l],o=[0,.26,.286,.3,.306,.34][l],a="tilde"+l)}var h=new wt(a),c=new xt([h],{width:"100%",height:ct(o),viewBox:"0 0 "+i+" "+n,preserveAspectRatio:"none"});return{span:be.makeSvgSpan([],[c],e),minWidth:0,height:o}}var d,u,p,m=[],f=ti[r],g=f[0],v=f[1],b=f[2],y=b/1e3,x=g.length;if(1===x)d=["hide-tail"],u=[f[3]];else if(2===x)d=["halfarrow-left","halfarrow-right"],u=["xMinYMin","xMaxYMin"];else{if(3!==x)throw new Error("Correct katexImagesData or update code here to support\n "+x+" children.");d=["brace-left","brace-center","brace-right"],u=["xMinYMin","xMidYMin","xMaxYMin"]}for(var w=0;w0&&(r.style.minWidth=ct(n)),r},ni=function(t,e){var i,n,a;t&&"supsub"===t.type?(i=(n=d(t.base,"accent")).base,t.base=i,a=function(t){if(t instanceof ft)return t;throw new Error("Expected span but got "+String(t)+".")}(He(t,e)),t.base=n):i=(n=d(t,"accent")).base;var o=He(i,e.havingCrampedStyle()),s=0;if(n.isShifty&&I.isCharacterBox(i)){var l=I.getBaseElem(i);s=r(He(l,e.havingCrampedStyle())).skew}var h,c="\\c"===n.label,u=c?o.height+o.depth:Math.min(o.height,e.fontMetrics().xHeight);if(n.isStretchy)h=ri(n,e),h=be.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:o},{type:"elem",elem:h,wrapperClasses:["svg-align"],wrapperStyle:s>0?{width:"calc(100% - "+ct(2*s)+")",marginLeft:ct(2*s)}:void 0}]},e);else{var p,m;"\\vec"===n.label?(p=be.staticSvg("vec",e),m=be.svgData.vec[1]):((p=r(p=be.makeOrd({mode:n.mode,text:n.label},e,"textord"))).italic=0,m=p.width,c&&(u+=p.depth)),h=be.makeSpan(["accent-body"],[p]);var f="\\textcircled"===n.label;f&&(h.classes.push("accent-full"),u=o.height);var g=s;f||(g-=m/2),h.style.left=ct(g),"\\textcircled"===n.label&&(h.style.top=".2em"),h=be.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:o},{type:"kern",size:-u},{type:"elem",elem:h}]},e)}var v=be.makeSpan(["mord","accent"],[h],e);return a?(a.children[0]=v,a.height=Math.max(v.height,a.height),a.classes[0]="mord",a):v},ai=function(t,e){var i=t.isStretchy?ii(t.label):new je.MathNode("mo",[We(t.label,t.mode)]),r=new je.MathNode("mover",[Xe(t.base,e),i]);return r.setAttribute("accent","true"),r},oi=new RegExp(["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring"].map(function(t){return"\\"+t}).join("|"));a({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:function(t,e){var i=Te(e[0]),r=!oi.test(t.funcName),n=!r||"\\widehat"===t.funcName||"\\widetilde"===t.funcName||"\\widecheck"===t.funcName;return{type:"accent",mode:t.parser.mode,label:t.funcName,isStretchy:r,isShifty:n,base:i}},htmlBuilder:ni,mathmlBuilder:ai}),a({type:"accent",names:["\\'","\\`","\\^","\\~","\\=","\\u","\\.",'\\"',"\\c","\\r","\\H","\\v","\\textcircled"],props:{numArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["primitive"]},handler:function(t,e){var i=e[0],r=t.parser.mode;return"math"===r&&(t.parser.settings.reportNonstrict("mathVsTextAccents","LaTeX's accent "+t.funcName+" works only in text mode"),r="text"),{type:"accent",mode:r,label:t.funcName,isStretchy:!1,isShifty:!0,base:i}},htmlBuilder:ni,mathmlBuilder:ai}),a({type:"accentUnder",names:["\\underleftarrow","\\underrightarrow","\\underleftrightarrow","\\undergroup","\\underlinesegment","\\utilde"],props:{numArgs:1},handler:function(t,e){var i=t.parser,r=t.funcName,n=e[0];return{type:"accentUnder",mode:i.mode,label:r,base:n}},htmlBuilder:function(t,e){var i=He(t.base,e),r=ri(t,e),n="\\utilde"===t.label?.12:0,a=be.makeVList({positionType:"top",positionData:i.height,children:[{type:"elem",elem:r,wrapperClasses:["svg-align"]},{type:"kern",size:n},{type:"elem",elem:i}]},e);return be.makeSpan(["mord","accentunder"],[a],e)},mathmlBuilder:function(t,e){var i=ii(t.label),r=new je.MathNode("munder",[Xe(t.base,e),i]);return r.setAttribute("accentunder","true"),r}});var si=function(t){var e=new je.MathNode("mpadded",t?[t]:[]);return e.setAttribute("width","+0.6em"),e.setAttribute("lspace","0.3em"),e};a({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:function(t,e,i){var r=t.parser,n=t.funcName;return{type:"xArrow",mode:r.mode,label:n,body:e[0],below:i[0]}},htmlBuilder:function(t,e){var i,r=e.style,n=e.havingStyle(r.sup()),a=be.wrapFragment(He(t.body,n,e),e),o="\\x"===t.label.slice(0,2)?"x":"cd";a.classes.push(o+"-arrow-pad"),t.below&&(n=e.havingStyle(r.sub()),(i=be.wrapFragment(He(t.below,n,e),e)).classes.push(o+"-arrow-pad"));var s,l=ri(t,e),h=-e.fontMetrics().axisHeight+.5*l.height,c=-e.fontMetrics().axisHeight-.5*l.height-.111;if((a.depth>.25||"\\xleftequilibrium"===t.label)&&(c-=a.depth),i){var d=-e.fontMetrics().axisHeight+i.height+.5*l.height+.111;s=be.makeVList({positionType:"individualShift",children:[{type:"elem",elem:a,shift:c},{type:"elem",elem:l,shift:h},{type:"elem",elem:i,shift:d}]},e)}else s=be.makeVList({positionType:"individualShift",children:[{type:"elem",elem:a,shift:c},{type:"elem",elem:l,shift:h}]},e);return s.children[0].children[0].children[1].classes.push("svg-align"),be.makeSpan(["mrel","x-arrow"],[s],e)},mathmlBuilder:function(t,e){var i,r=ii(t.label);if(r.setAttribute("minsize","x"===t.label.charAt(0)?"1.75em":"3.0em"),t.body){var n=si(Xe(t.body,e));if(t.below){var a=si(Xe(t.below,e));i=new je.MathNode("munderover",[r,a,n])}else i=new je.MathNode("mover",[r,n])}else if(t.below){var o=si(Xe(t.below,e));i=new je.MathNode("munder",[r,o])}else i=si(),i=new je.MathNode("mover",[r,i]);return i}});var li=be.makeSpan;a({type:"mclass",names:["\\mathord","\\mathbin","\\mathrel","\\mathopen","\\mathclose","\\mathpunct","\\mathinner"],props:{numArgs:1,primitive:!0},handler:function(t,e){var i=t.parser,r=t.funcName,n=e[0];return{type:"mclass",mode:i.mode,mclass:"m"+r.slice(5),body:Ce(n),isCharacterBox:I.isCharacterBox(n)}},htmlBuilder:m,mathmlBuilder:f});var hi=function(t){var e="ordgroup"===t.type&&t.body.length?t.body[0]:t;return"atom"!==e.type||"bin"!==e.family&&"rel"!==e.family?"mord":"m"+e.family};a({type:"mclass",names:["\\@binrel"],props:{numArgs:2},handler:function(t,e){return{type:"mclass",mode:t.parser.mode,mclass:hi(e[0]),body:Ce(e[1]),isCharacterBox:I.isCharacterBox(e[1])}}}),a({type:"mclass",names:["\\stackrel","\\overset","\\underset"],props:{numArgs:2},handler:function(t,e){var i,r=t.parser,n=t.funcName,a=e[1],o=e[0];i="\\stackrel"!==n?hi(a):"mrel";var s={type:"op",mode:a.mode,limits:!0,alwaysHandleSupSub:!0,parentIsSupSub:!1,symbol:!1,suppressBaseShift:"\\stackrel"!==n,body:Ce(a)},l={type:"supsub",mode:o.mode,base:s,sup:"\\underset"===n?null:o,sub:"\\underset"===n?o:null};return{type:"mclass",mode:r.mode,mclass:i,body:[l],isCharacterBox:I.isCharacterBox(l)}},htmlBuilder:m,mathmlBuilder:f}),a({type:"pmb",names:["\\pmb"],props:{numArgs:1,allowedInText:!0},handler:function(t,e){return{type:"pmb",mode:t.parser.mode,mclass:hi(e[0]),body:Ce(e[0])}},htmlBuilder:function(t,e){var i=Ie(t.body,e,!0),r=be.makeSpan([t.mclass],i,e);return r.style.textShadow="0.02em 0.01em 0.04px",r},mathmlBuilder:function(t,e){var i=Ye(t.body,e),r=new je.MathNode("mstyle",i);return r.setAttribute("style","text-shadow: 0.02em 0.01em 0.04px"),r}});var ci={">":"\\\\cdrightarrow","<":"\\\\cdleftarrow","=":"\\\\cdlongequal",A:"\\uparrow",V:"\\downarrow","|":"\\Vert",".":"no arrow"},di=function(t){return"textord"===t.type&&"@"===t.text};a({type:"cdlabel",names:["\\\\cdleft","\\\\cdright"],props:{numArgs:1},handler:function(t,e){var i=t.parser,r=t.funcName;return{type:"cdlabel",mode:i.mode,side:r.slice(4),label:e[0]}},htmlBuilder:function(t,e){var i=e.havingStyle(e.style.sup()),r=be.wrapFragment(He(t.label,i,e),e);return r.classes.push("cd-label-"+t.side),r.style.bottom=ct(.8-r.depth),r.height=0,r.depth=0,r},mathmlBuilder:function(t,e){var i=new je.MathNode("mrow",[Xe(t.label,e)]);return(i=new je.MathNode("mpadded",[i])).setAttribute("width","0"),"left"===t.side&&i.setAttribute("lspace","-1width"),i.setAttribute("voffset","0.7em"),(i=new je.MathNode("mstyle",[i])).setAttribute("displaystyle","false"),i.setAttribute("scriptlevel","1"),i}}),a({type:"cdlabelparent",names:["\\\\cdparent"],props:{numArgs:1},handler:function(t,e){return{type:"cdlabelparent",mode:t.parser.mode,fragment:e[0]}},htmlBuilder:function(t,e){var i=be.wrapFragment(He(t.fragment,e),e);return i.classes.push("cd-vert-arrow"),i},mathmlBuilder:function(t,e){return new je.MathNode("mrow",[Xe(t.fragment,e)])}}),a({type:"textord",names:["\\@char"],props:{numArgs:1,allowedInText:!0},handler:function(t,e){for(var i=t.parser,r=d(e[0],"ordgroup").body,n="",a=0;a=1114111)throw new z("\\@char with invalid code point "+n);return s<=65535?o=String.fromCharCode(s):(s-=65536,o=String.fromCharCode(55296+(s>>10),56320+(1023&s))),{type:"textord",mode:i.mode,text:o}}});var ui=function(t,e){var i=Ie(t.body,e.withColor(t.color),!1);return be.makeFragment(i)},pi=function(t,e){var i=Ye(t.body,e.withColor(t.color)),r=new je.MathNode("mstyle",i);return r.setAttribute("mathcolor",t.color),r};a({type:"color",names:["\\textcolor"],props:{numArgs:2,allowedInText:!0,argTypes:["color","original"]},handler:function(t,e){var i=t.parser,r=d(e[0],"color-token").color,n=e[1];return{type:"color",mode:i.mode,color:r,body:Ce(n)}},htmlBuilder:ui,mathmlBuilder:pi}),a({type:"color",names:["\\color"],props:{numArgs:1,allowedInText:!0,argTypes:["color"]},handler:function(t,e){var i=t.parser,r=t.breakOnTokenText,n=d(e[0],"color-token").color;i.gullet.macros.set("\\current@color",n);var a=i.parseExpression(!0,r);return{type:"color",mode:i.mode,color:n,body:a}},htmlBuilder:ui,mathmlBuilder:pi}),a({type:"cr",names:["\\\\"],props:{numArgs:0,numOptionalArgs:0,allowedInText:!0},handler:function(t){var e=t.parser,i="["===e.gullet.future().text?e.parseSizeGroup(!0):null,r=!e.settings.displayMode||!e.settings.useStrictBehavior("newLineInDisplayMode","In LaTeX, \\\\ or \\newline does nothing in display mode");return{type:"cr",mode:e.mode,newLine:r,size:i&&d(i,"size").value}},htmlBuilder:function(t,e){var i=be.makeSpan(["mspace"],[],e);return t.newLine&&(i.classes.push("newline"),t.size&&(i.style.marginTop=ct(ht(t.size,e)))),i},mathmlBuilder:function(t,e){var i=new je.MathNode("mspace");return t.newLine&&(i.setAttribute("linebreak","newline"),t.size&&i.setAttribute("height",ct(ht(t.size,e)))),i}});var mi={"\\global":"\\global","\\long":"\\\\globallong","\\\\globallong":"\\\\globallong","\\def":"\\gdef","\\gdef":"\\gdef","\\edef":"\\xdef","\\xdef":"\\xdef","\\let":"\\\\globallet","\\futurelet":"\\\\globalfuture"},fi=function(t){var e=t.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(e))throw new z("Expected a control sequence",t);return e},gi=function(t,e,i,r){var n=t.gullet.macros.get(i.text);null==n&&(i.noexpand=!0,n={tokens:[i],numArgs:0,unexpandable:!t.gullet.isExpandable(i.text)}),t.gullet.macros.set(e,n,r)};a({type:"internal",names:["\\global","\\long","\\\\globallong"],props:{numArgs:0,allowedInText:!0},handler:function(t){var e=t.parser,i=t.funcName;e.consumeSpaces();var r=e.fetch();if(mi[r.text])return"\\global"!==i&&"\\\\globallong"!==i||(r.text=mi[r.text]),d(e.parseFunction(),"internal");throw new z("Invalid token after macro prefix",r)}}),a({type:"internal",names:["\\def","\\gdef","\\edef","\\xdef"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler:function(t){var e=t.parser,i=t.funcName,r=e.gullet.popToken(),n=r.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(n))throw new z("Expected a control sequence",r);for(var a,o=0,s=[[]];"{"!==e.gullet.future().text;)if("#"===(r=e.gullet.popToken()).text){if("{"===e.gullet.future().text){a=e.gullet.future(),s[o].push("{");break}if(r=e.gullet.popToken(),!/^[1-9]$/.test(r.text))throw new z('Invalid argument number "'+r.text+'"');if(parseInt(r.text)!==o+1)throw new z('Argument number "'+r.text+'" out of order');o++,s.push([])}else{if("EOF"===r.text)throw new z("Expected a macro definition");s[o].push(r.text)}var l=e.gullet.consumeArg().tokens;return a&&l.unshift(a),"\\edef"!==i&&"\\xdef"!==i||(l=e.gullet.expandTokens(l)).reverse(),e.gullet.macros.set(n,{tokens:l,numArgs:o,delimiters:s},i===mi[i]),{type:"internal",mode:e.mode}}}),a({type:"internal",names:["\\let","\\\\globallet"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler:function(t){var e=t.parser,i=t.funcName,r=fi(e.gullet.popToken());e.gullet.consumeSpaces();var n=function(t){var e=t.gullet.popToken();return"="===e.text&&" "===(e=t.gullet.popToken()).text&&(e=t.gullet.popToken()),e}(e);return gi(e,r,n,"\\\\globallet"===i),{type:"internal",mode:e.mode}}}),a({type:"internal",names:["\\futurelet","\\\\globalfuture"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler:function(t){var e=t.parser,i=t.funcName,r=fi(e.gullet.popToken()),n=e.gullet.popToken(),a=e.gullet.popToken();return gi(e,r,a,"\\\\globalfuture"===i),e.gullet.pushToken(a),e.gullet.pushToken(n),{type:"internal",mode:e.mode}}});var vi=function(t,e,r){var n=i(At.math[t]&&At.math[t].replace||t,e,r);if(!n)throw new Error("Unsupported symbol "+t+" and font size "+e+".");return n},bi=function(t,e,i,r){var n=i.havingBaseStyle(e),a=be.makeSpan(r.concat(n.sizingClasses(i)),[t],i),o=n.sizeMultiplier/i.sizeMultiplier;return a.height*=o,a.depth*=o,a.maxFontSize=n.sizeMultiplier,a},yi=function(t,e,i){var r=e.havingBaseStyle(i),n=(1-e.sizeMultiplier/r.sizeMultiplier)*e.fontMetrics().axisHeight;t.classes.push("delimcenter"),t.style.top=ct(n),t.height-=n,t.depth+=n},xi=function(t,e,i,r,n,a){var o=function(t,e,i,r){return be.makeSymbol(t,"Size"+e+"-Regular",i,r)}(t,e,n,r),s=bi(be.makeSpan(["delimsizing","size"+e],[o],r),U.TEXT,r,a);return i&&yi(s,r,U.TEXT),s},wi=function(t,e,i){var r;return r="Size1-Regular"===e?"delim-size1":"delim-size4",{type:"elem",elem:be.makeSpan(["delimsizinginner",r],[be.makeSpan([],[be.makeSymbol(t,e,i)])])}},ki=function(t,e,i){var r=Z["Size4-Regular"][t.charCodeAt(0)]?Z["Size4-Regular"][t.charCodeAt(0)][4]:Z["Size1-Regular"][t.charCodeAt(0)][4],n=new wt("inner",function(t,e){switch(t){case"\u239c":return"M291 0 H417 V"+e+" H291z M291 0 H417 V"+e+" H291z";case"\u2223":return"M145 0 H188 V"+e+" H145z M145 0 H188 V"+e+" H145z";case"\u2225":return"M145 0 H188 V"+e+" H145z M145 0 H188 V"+e+" H145zM367 0 H410 V"+e+" H367z M367 0 H410 V"+e+" H367z";case"\u239f":return"M457 0 H583 V"+e+" H457z M457 0 H583 V"+e+" H457z";case"\u23a2":return"M319 0 H403 V"+e+" H319z M319 0 H403 V"+e+" H319z";case"\u23a5":return"M263 0 H347 V"+e+" H263z M263 0 H347 V"+e+" H263z";case"\u23aa":return"M384 0 H504 V"+e+" H384z M384 0 H504 V"+e+" H384z";case"\u23d0":return"M312 0 H355 V"+e+" H312z M312 0 H355 V"+e+" H312z";case"\u2016":return"M257 0 H300 V"+e+" H257z M257 0 H300 V"+e+" H257zM478 0 H521 V"+e+" H478z M478 0 H521 V"+e+" H478z";default:return""}}(t,Math.round(1e3*e))),a=new xt([n],{width:ct(r),height:ct(e),style:"width:"+ct(r),viewBox:"0 0 "+1e3*r+" "+Math.round(1e3*e),preserveAspectRatio:"xMinYMin"}),o=be.makeSvgSpan([],[a],i);return o.height=e,o.style.height=ct(e),o.style.width=ct(r),{type:"elem",elem:o}},_i={type:"kern",size:-.008},Si=["|","\\lvert","\\rvert","\\vert"],Mi=["\\|","\\lVert","\\rVert","\\Vert"],Ai=function(t,e,i,r,n,a){var o,s,l,h,c="",d=0;o=l=h=t,s=null;var u="Size1-Regular";"\\uparrow"===t?l=h="\u23d0":"\\Uparrow"===t?l=h="\u2016":"\\downarrow"===t?o=l="\u23d0":"\\Downarrow"===t?o=l="\u2016":"\\updownarrow"===t?(o="\\uparrow",l="\u23d0",h="\\downarrow"):"\\Updownarrow"===t?(o="\\Uparrow",l="\u2016",h="\\Downarrow"):I.contains(Si,t)?(l="\u2223",c="vert",d=333):I.contains(Mi,t)?(l="\u2225",c="doublevert",d=556):"["===t||"\\lbrack"===t?(o="\u23a1",l="\u23a2",h="\u23a3",u="Size4-Regular",c="lbrack",d=667):"]"===t||"\\rbrack"===t?(o="\u23a4",l="\u23a5",h="\u23a6",u="Size4-Regular",c="rbrack",d=667):"\\lfloor"===t||"\u230a"===t?(l=o="\u23a2",h="\u23a3",u="Size4-Regular",c="lfloor",d=667):"\\lceil"===t||"\u2308"===t?(o="\u23a1",l=h="\u23a2",u="Size4-Regular",c="lceil",d=667):"\\rfloor"===t||"\u230b"===t?(l=o="\u23a5",h="\u23a6",u="Size4-Regular",c="rfloor",d=667):"\\rceil"===t||"\u2309"===t?(o="\u23a4",l=h="\u23a5",u="Size4-Regular",c="rceil",d=667):"("===t||"\\lparen"===t?(o="\u239b",l="\u239c",h="\u239d",u="Size4-Regular",c="lparen",d=875):")"===t||"\\rparen"===t?(o="\u239e",l="\u239f",h="\u23a0",u="Size4-Regular",c="rparen",d=875):"\\{"===t||"\\lbrace"===t?(o="\u23a7",s="\u23a8",h="\u23a9",l="\u23aa",u="Size4-Regular"):"\\}"===t||"\\rbrace"===t?(o="\u23ab",s="\u23ac",h="\u23ad",l="\u23aa",u="Size4-Regular"):"\\lgroup"===t||"\u27ee"===t?(o="\u23a7",h="\u23a9",l="\u23aa", u="Size4-Regular"):"\\rgroup"===t||"\u27ef"===t?(o="\u23ab",h="\u23ad",l="\u23aa",u="Size4-Regular"):"\\lmoustache"===t||"\u23b0"===t?(o="\u23a7",h="\u23ad",l="\u23aa",u="Size4-Regular"):"\\rmoustache"!==t&&"\u23b1"!==t||(o="\u23ab",h="\u23a9",l="\u23aa",u="Size4-Regular");var p=vi(o,u,n),m=p.height+p.depth,f=vi(l,u,n),g=f.height+f.depth,v=vi(h,u,n),b=v.height+v.depth,y=0,x=1;if(null!==s){var w=vi(s,u,n);y=w.height+w.depth,x=2}var k=m+b+y,_=k+Math.max(0,Math.ceil((e-k)/(x*g)))*x*g,S=r.fontMetrics().axisHeight;i&&(S*=r.sizeMultiplier);var M=_/2-S,A=[];if(c.length>0){var T=_-m-b,C=Math.round(1e3*_),z=function(t,e){switch(t){case"lbrack":return"M403 1759 V84 H666 V0 H319 V1759 v"+e+" v1759 h347 v-84\nH403z M403 1759 V0 H319 V1759 v"+e+" v1759 h84z";case"rbrack":return"M347 1759 V0 H0 V84 H263 V1759 v"+e+" v1759 H0 v84 H347z\nM347 1759 V0 H263 V1759 v"+e+" v1759 h84z";case"vert":return"M145 15 v585 v"+e+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-e+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M188 15 H145 v585 v"+e+" v585 h43z";case"doublevert":return"M145 15 v585 v"+e+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-e+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M188 15 H145 v585 v"+e+" v585 h43z\nM367 15 v585 v"+e+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-e+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M410 15 H367 v585 v"+e+" v585 h43z";case"lfloor":return"M319 602 V0 H403 V602 v"+e+" v1715 h263 v84 H319z\nMM319 602 V0 H403 V602 v"+e+" v1715 H319z";case"rfloor":return"M319 602 V0 H403 V602 v"+e+" v1799 H0 v-84 H319z\nMM319 602 V0 H403 V602 v"+e+" v1715 H319z";case"lceil":return"M403 1759 V84 H666 V0 H319 V1759 v"+e+" v602 h84z\nM403 1759 V0 H319 V1759 v"+e+" v602 h84z";case"rceil":return"M347 1759 V0 H0 V84 H263 V1759 v"+e+" v602 h84z\nM347 1759 V0 h-84 V1759 v"+e+" 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\nc-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,\n-36,557 l0,"+(e+84)+"c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210,\n949.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\nc0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5,\n-544.7,-112.5,-882c-2,-104,-3,-167,-3,-189\nl0,-"+(e+92)+"c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3,\n-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,\n63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5\nc11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0,"+(e+9)+"\nc-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\nc-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\nc0,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\nc242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558\nl0,-"+(e+144)+"c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7,\n-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.")}}(c,Math.round(1e3*T)),O=new wt(c,z),L=(d/1e3).toFixed(3)+"em",P=(C/1e3).toFixed(3)+"em",E=new xt([O],{width:L,height:P,viewBox:"0 0 "+d+" "+C}),D=be.makeSvgSpan([],[E],r);D.height=C/1e3,D.style.width=L,D.style.height=P,A.push({type:"elem",elem:D})}else{if(A.push(wi(h,u,n)),A.push(_i),null===s){var B=_-m-b+.016;A.push(ki(l,B,r))}else{var R=(_-m-b-y)/2+.016;A.push(ki(l,R,r)),A.push(_i),A.push(wi(s,u,n)),A.push(_i),A.push(ki(l,R,r))}A.push(_i),A.push(wi(o,u,n))}var N=r.havingBaseStyle(U.TEXT),F=be.makeVList({positionType:"bottom",positionData:M,children:A},N);return bi(be.makeSpan(["delimsizing","mult"],[F],N),U.TEXT,r,a)},Ti=.08,Ci=function(t,e,i,r,n){var a=function(t,e,i){e*=1e3;var r="";switch(t){case"sqrtMain":r=function(t){return"M95,"+(622+t+$)+"\nc-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14\nc0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54\nc44.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\ns173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429\nc69,-144,104.5,-217.7,106.5,-221\nl"+t/2.075+" -"+t+"\nc5.3,-9.3,12,-14,20,-14\nH400000v"+(40+t)+"H845.2724\ns-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7\nc-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z\nM"+(834+t)+" "+$+"h400000v"+(40+t)+"h-400000z"}(e);break;case"sqrtSize1":r=function(t){return"M263,"+(601+t+$)+"c0.7,0,18,39.7,52,119\nc34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120\nc340,-704.7,510.7,-1060.3,512,-1067\nl"+t/2.084+" -"+t+"\nc4.7,-7.3,11,-11,19,-11\nH40000v"+(40+t)+"H1012.3\ns-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232\nc-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1\ns-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26\nc-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z\nM"+(1001+t)+" "+$+"h400000v"+(40+t)+"h-400000z"}(e);break;case"sqrtSize2":r=function(t){return"M983 "+(10+t+$)+"\nl"+t/3.13+" -"+t+"\nc4,-6.7,10,-10,18,-10 H400000v"+(40+t)+"\nH1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7\ns-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744\nc-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30\nc26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722\nc56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5\nc53.7,-170.3,84.5,-266.8,92.5,-289.5z\nM"+(1001+t)+" "+$+"h400000v"+(40+t)+"h-400000z"}(e);break;case"sqrtSize3":r=function(t){return"M424,"+(2398+t+$)+"\nc-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514\nc0,-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\ns-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121\ns209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081\nl"+t/4.223+" -"+t+"c4,-6.7,10,-10,18,-10 H400000\nv"+(40+t)+"H1014.6\ns-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185\nc-2,6,-10,9,-24,9\nc-8,0,-12,-0.7,-12,-2z M"+(1001+t)+" "+$+"\nh400000v"+(40+t)+"h-400000z"}(e);break;case"sqrtSize4":r=function(t){return"M473,"+(2713+t+$)+"\nc339.3,-1799.3,509.3,-2700,510,-2702 l"+t/5.298+" -"+t+"\nc3.3,-7.3,9.3,-11,18,-11 H400000v"+(40+t)+"H1017.7\ns-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9\nc-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200\nc0,-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\ns76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104,\n606zM"+(1001+t)+" "+$+"h400000v"+(40+t)+"H1017.7z"}(e);break;case"sqrtTall":r=function(t,e,i){return"M702 "+(t+$)+"H400000"+(40+t)+"\nH742v"+(i-54-$-t)+"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\nh-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170\nc-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667\n219 661 l218 661zM702 "+$+"H400000v"+(40+t)+"H742z"}(e,0,i)}return r}(t,r,i),o=new wt(t,a),s=new xt([o],{width:"400em",height:ct(e),viewBox:"0 0 400000 "+i,preserveAspectRatio:"xMinYMin slice"});return be.makeSvgSpan(["hide-tail"],[s],n)},zi=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","\u230a","\u230b","\\lceil","\\rceil","\u2308","\u2309","\\surd"],Oi=["\\uparrow","\\downarrow","\\updownarrow","\\Uparrow","\\Downarrow","\\Updownarrow","|","\\|","\\vert","\\Vert","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","\u27ee","\u27ef","\\lmoustache","\\rmoustache","\u23b0","\u23b1"],Li=["<",">","\\langle","\\rangle","/","\\backslash","\\lt","\\gt"],Pi=[0,1.2,1.8,2.4,3],Ei=[{type:"small",style:U.SCRIPTSCRIPT},{type:"small",style:U.SCRIPT},{type:"small",style:U.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4}],Ii=[{type:"small",style:U.SCRIPTSCRIPT},{type:"small",style:U.SCRIPT},{type:"small",style:U.TEXT},{type:"stack"}],Di=[{type:"small",style:U.SCRIPTSCRIPT},{type:"small",style:U.SCRIPT},{type:"small",style:U.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4},{type:"stack"}],Bi=function(t){if("small"===t.type)return"Main-Regular";if("large"===t.type)return"Size"+t.size+"-Regular";if("stack"===t.type)return"Size4-Regular";throw new Error("Add support for delim type '"+t.type+"' here.")},Ri=function(t,e,i,r){for(var n=Math.min(2,3-r.style.size);ne)return i[n]}return i[i.length-1]},Ni=function(t,e,i,r,n,a){var o;"<"===t||"\\lt"===t||"\u27e8"===t?t="\\langle":">"!==t&&"\\gt"!==t&&"\u27e9"!==t||(t="\\rangle"),o=I.contains(Li,t)?Ei:I.contains(zi,t)?Di:Ii;var s=Ri(t,e,o,r);return"small"===s.type?function(t,e,i,r,n,a){var o=be.makeSymbol(t,"Main-Regular",n,r),s=bi(o,e,r,a);return i&&yi(s,r,e),s}(t,s.style,i,r,n,a):"large"===s.type?xi(t,s.size,i,r,n,a):Ai(t,e,i,r,n,a)},Fi={sqrtImage:function(t,e){var i,r,n=e.havingBaseSizing(),a=Ri("\\surd",t*n.sizeMultiplier,Di,n),o=n.sizeMultiplier,s=Math.max(0,e.minRuleThickness-e.fontMetrics().sqrtRuleThickness),l=0,h=0,c=0;return"small"===a.type?(t<1?o=1:t<1.4&&(o=.7),h=(1+s)/o,(i=Ci("sqrtMain",l=(1+s+Ti)/o,c=1e3+1e3*s+80,s,e)).style.minWidth="0.853em",r=.833/o):"large"===a.type?(c=1080*Pi[a.size],h=(Pi[a.size]+s)/o,l=(Pi[a.size]+s+Ti)/o,(i=Ci("sqrtSize"+a.size,l,c,s,e)).style.minWidth="1.02em",r=1/o):(l=t+s+Ti,h=t+s,c=Math.floor(1e3*t+s)+80,(i=Ci("sqrtTall",l,c,s,e)).style.minWidth="0.742em",r=1.056),i.height=h,i.style.height=ct(l),{span:i,advanceWidth:r,ruleWidth:(e.fontMetrics().sqrtRuleThickness+s)*o}},sizedDelim:function(t,e,i,r,n){if("<"===t||"\\lt"===t||"\u27e8"===t?t="\\langle":">"!==t&&"\\gt"!==t&&"\u27e9"!==t||(t="\\rangle"),I.contains(zi,t)||I.contains(Li,t))return xi(t,e,!1,i,r,n);if(I.contains(Oi,t))return Ai(t,Pi[e],!1,i,r,n);throw new z("Illegal delimiter: '"+t+"'")},sizeToMaxHeight:Pi,customSizedDelim:Ni,leftRightDelim:function(t,e,i,r,n,a){var o=r.fontMetrics().axisHeight*r.sizeMultiplier,s=5/r.fontMetrics().ptPerEm,l=Math.max(e-o,i+o),h=Math.max(l/500*901,2*l-s);return Ni(t,h,!0,r,n,a)}},Hi={"\\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}},Vi=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","\u230a","\u230b","\\lceil","\\rceil","\u2308","\u2309","<",">","\\langle","\u27e8","\\rangle","\u27e9","\\lt","\\gt","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","\u27ee","\u27ef","\\lmoustache","\\rmoustache","\u23b0","\u23b1","/","\\backslash","|","\\vert","\\|","\\Vert","\\uparrow","\\Uparrow","\\downarrow","\\Downarrow","\\updownarrow","\\Updownarrow","."];a({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:function(t,e){var i=v(e[0],t);return{type:"delimsizing",mode:t.parser.mode,size:Hi[t.funcName].size,mclass:Hi[t.funcName].mclass,delim:i.text}},htmlBuilder:function(t,e){return"."===t.delim?be.makeSpan([t.mclass]):Fi.sizedDelim(t.delim,t.size,e,t.mode,[t.mclass])},mathmlBuilder:function(t){var e=[];"."!==t.delim&&e.push(We(t.delim,t.mode));var i=new je.MathNode("mo",e);"mopen"===t.mclass||"mclose"===t.mclass?i.setAttribute("fence","true"):i.setAttribute("fence","false"),i.setAttribute("stretchy","true");var r=ct(Fi.sizeToMaxHeight[t.size]);return i.setAttribute("minsize",r),i.setAttribute("maxsize",r),i}}),a({type:"leftright-right",names:["\\right"],props:{numArgs:1,primitive:!0},handler:function(t,e){var i=t.parser.gullet.macros.get("\\current@color");if(i&&"string"!=typeof i)throw new z("\\current@color set to non-string in \\right");return{type:"leftright-right",mode:t.parser.mode,delim:v(e[0],t).text,color:i}}}),a({type:"leftright",names:["\\left"],props:{numArgs:1,primitive:!0},handler:function(t,e){var i=v(e[0],t),r=t.parser;++r.leftrightDepth;var n=r.parseExpression(!1);--r.leftrightDepth,r.expect("\\right",!1);var a=d(r.parseFunction(),"leftright-right");return{type:"leftright",mode:r.mode,body:n,left:i.text,right:a.delim,rightColor:a.color}},htmlBuilder:function(t,e){b(t);for(var i,r,n=Ie(t.body,e,!0,["mopen","mclose"]),a=0,o=0,s=!1,l=0;l-1?"mpadded":"menclose",[Xe(t.body,e)]);switch(t.label){case"\\cancel":r.setAttribute("notation","updiagonalstrike");break;case"\\bcancel":r.setAttribute("notation","downdiagonalstrike");break;case"\\phase":r.setAttribute("notation","phasorangle");break;case"\\sout":r.setAttribute("notation","horizontalstrike");break;case"\\fbox":r.setAttribute("notation","box");break;case"\\angl":r.setAttribute("notation","actuarial");break;case"\\fcolorbox":case"\\colorbox":if(i=e.fontMetrics().fboxsep*e.fontMetrics().ptPerEm,r.setAttribute("width","+"+2*i+"pt"),r.setAttribute("height","+"+2*i+"pt"),r.setAttribute("lspace",i+"pt"),r.setAttribute("voffset",i+"pt"),"\\fcolorbox"===t.label){var n=Math.max(e.fontMetrics().fboxrule,e.minRuleThickness);r.setAttribute("style","border: "+n+"em solid "+String(t.borderColor))}break;case"\\xcancel":r.setAttribute("notation","updiagonalstrike downdiagonalstrike")}return t.backgroundColor&&r.setAttribute("mathbackground",t.backgroundColor),r};a({type:"enclose",names:["\\colorbox"],props:{numArgs:2,allowedInText:!0,argTypes:["color","text"]},handler:function(t,e){var i=t.parser,r=t.funcName,n=d(e[0],"color-token").color,a=e[1];return{type:"enclose",mode:i.mode,label:r,backgroundColor:n,body:a}},htmlBuilder:qi,mathmlBuilder:ji}),a({type:"enclose",names:["\\fcolorbox"],props:{numArgs:3,allowedInText:!0,argTypes:["color","color","text"]},handler:function(t,e){var i=t.parser,r=t.funcName,n=d(e[0],"color-token").color,a=d(e[1],"color-token").color,o=e[2];return{type:"enclose",mode:i.mode,label:r,backgroundColor:a,borderColor:n,body:o}},htmlBuilder:qi,mathmlBuilder:ji}),a({type:"enclose",names:["\\fbox"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!0},handler:function(t,e){return{type:"enclose",mode:t.parser.mode,label:"\\fbox",body:e[0]}}}),a({type:"enclose",names:["\\cancel","\\bcancel","\\xcancel","\\sout","\\phase"],props:{numArgs:1},handler:function(t,e){var i=t.parser,r=t.funcName,n=e[0];return{type:"enclose",mode:i.mode,label:r,body:n}},htmlBuilder:qi,mathmlBuilder:ji}),a({type:"enclose",names:["\\angl"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!1},handler:function(t,e){return{type:"enclose",mode:t.parser.mode,label:"\\angl",body:e[0]}}});var Wi={},Ui={},Gi=function(){function t(t,e,i){this.lexer=void 0,this.start=void 0,this.end=void 0,this.lexer=t,this.start=e,this.end=i}return t.range=function(e,i){return i?e&&e.loc&&i.loc&&e.loc.lexer===i.loc.lexer?new t(e.loc.lexer,e.loc.start,i.loc.end):null:e&&e.loc},t}(),Yi=function(){function t(t,e){this.text=void 0,this.loc=void 0,this.noexpand=void 0,this.treatAsRelax=void 0,this.text=t,this.loc=e}return t.prototype.range=function(e,i){return new t(i,Gi.range(this,e))},t}(),$i=function(t){if(!t.parser.settings.displayMode)throw new z("{"+t.envName+"} can be used only in display mode.")},Xi=function(t,e){function i(t){for(var e=0;e0&&(b+=.25),h.push({pos:b,isDashed:t[e]})}var r,n,a=t.body.length,o=t.hLinesBeforeRow,s=0,l=new Array(a),h=[],c=Math.max(e.fontMetrics().arrayRuleWidth,e.minRuleThickness),d=1/e.fontMetrics().ptPerEm,u=5*d;t.colSeparationType&&"small"===t.colSeparationType&&(u=e.havingStyle(U.SCRIPT).sizeMultiplier/e.sizeMultiplier*.2778);var p="CD"===t.colSeparationType?ht({number:3,unit:"ex"},e):12*d,m=3*d,f=t.arraystretch*p,g=.7*f,v=.3*f,b=0;for(i(o[0]),r=0;r0&&(w<(M+=v)&&(w=M),M=0),t.addJot&&(w+=m),k.height=x,k.depth=w,b+=x,k.pos=b,b+=w+M,l[r]=k,i(o[r+1])}var A,T,C=b/2+e.fontMetrics().axisHeight,O=t.cols||[],L=[],P=[];if(t.tags&&t.tags.some(function(t){return t}))for(r=0;r=s)){var j=void 0;(n>0||t.hskipBeforeAndAfter)&&0!==(j=I.deflt(N.pregap,u))&&((A=be.makeSpan(["arraycolsep"],[])).style.width=ct(j),L.push(A));var W=[];for(r=0;r0){for(var X=be.makeLineSpan("hline",e,c),K=be.makeLineSpan("hdashline",e,c),Z=[{type:"elem",elem:l,shift:0}];h.length>0;){var J=h.pop(),Q=J.pos-C;J.isDashed?Z.push({type:"elem",elem:K,shift:Q}):Z.push({type:"elem",elem:X,shift:Q})}l=be.makeVList({positionType:"individualShift",children:Z},e)}if(0===P.length)return be.makeSpan(["mord"],[l],e);var tt=be.makeVList({positionType:"individualShift",children:P},e);return tt=be.makeSpan(["tag"],[tt],e),be.makeFragment([l,tt])},Ki={c:"center ",l:"left ",r:"right "},Zi=function(t,e){for(var i=[],r=new je.MathNode("mtd",[],["mtr-glue"]),n=new je.MathNode("mtd",[],["mml-eqn-num"]),a=0;a0){var p=t.cols,m="",f=!1,g=0,v=p.length;"separator"===p[0].type&&(d+="top ",g=1),"separator"===p[p.length-1].type&&(d+="bottom ",v-=1);for(var b=g;b0?"left ":"",d+=_[_.length-1].length>0?"right ":"";for(var S=1;S<_.length-1;S++)k+=0===_[S].length?"none ":_[S][0]?"dashed ":"solid ";return/[sd]/.test(k)&&h.setAttribute("rowlines",k.trim()),""!==d&&(h=new je.MathNode("menclose",[h])).setAttribute("notation",d.trim()),t.arraystretch&&t.arraystretch<1&&(h=new je.MathNode("mstyle",[h])).setAttribute("scriptlevel","1"),h},Ji=function(t,e){-1===t.envName.indexOf("ed")&&$i(t);var i,r=[],n=t.envName.indexOf("at")>-1?"alignat":"align",a="split"===t.envName,o=_(t.parser,{cols:r,addJot:!0,autoTag:a?void 0:k(t.envName),emptySingleRow:!0,colSeparationType:n,maxNumCols:a?2:void 0,leqno:t.parser.settings.leqno},"display"),s=0,l={type:"ordgroup",mode:t.mode,body:[]};if(e[0]&&"ordgroup"===e[0].type){for(var h="",c=0;c0&&u&&(f=1),r[p]={type:"align",align:m,pregap:f,postgap:0}}return o.colSeparationType=u?"align":"alignat",o};y({type:"array",names:["array","darray"],props:{numArgs:1},handler:function(t,e){var i=(p(e[0])?[e[0]]:d(e[0],"ordgroup").body).map(function(t){var e=u(t).text;if(-1!=="lcr".indexOf(e))return{type:"align",align:e};if("|"===e)return{type:"separator",separator:"|"};if(":"===e)return{type:"separator",separator:":"};throw new z("Unknown column alignment: "+e,t)}),r={cols:i,hskipBeforeAndAfter:!0,maxNumCols:i.length};return _(t.parser,r,S(t.envName))},htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["matrix","pmatrix","bmatrix","Bmatrix","vmatrix","Vmatrix","matrix*","pmatrix*","bmatrix*","Bmatrix*","vmatrix*","Vmatrix*"],props:{numArgs:0},handler:function(t){var e={matrix:null,pmatrix:["(",")"],bmatrix:["[","]"],Bmatrix:["\\{","\\}"],vmatrix:["|","|"],Vmatrix:["\\Vert","\\Vert"]}[t.envName.replace("*","")],i="c",r={hskipBeforeAndAfter:!1,cols:[{type:"align",align:i}]};if("*"===t.envName.charAt(t.envName.length-1)){var n=t.parser;if(n.consumeSpaces(),"["===n.fetch().text){if(n.consume(),n.consumeSpaces(),i=n.fetch().text,-1==="lcr".indexOf(i))throw new z("Expected l or c or r",n.nextToken);n.consume(),n.consumeSpaces(),n.expect("]"),n.consume(),r.cols=[{type:"align",align:i}]}}var a=_(t.parser,r,S(t.envName)),o=Math.max.apply(Math,[0].concat(a.body.map(function(t){return t.length})));return a.cols=new Array(o).fill({type:"align",align:i}),e?{type:"leftright",mode:t.mode,body:[a],left:e[0],right:e[1],rightColor:void 0}:a},htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["smallmatrix"],props:{numArgs:0},handler:function(t){var e=_(t.parser,{arraystretch:.5},"script");return e.colSeparationType="small",e},htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["subarray"],props:{numArgs:1},handler:function(t,e){var i=(p(e[0])?[e[0]]:d(e[0],"ordgroup").body).map(function(t){var e=u(t).text;if(-1!=="lc".indexOf(e))return{type:"align",align:e};throw new z("Unknown column alignment: "+e,t)});if(i.length>1)throw new z("{subarray} can contain only one column");var r={cols:i,hskipBeforeAndAfter:!1,arraystretch:.5};if((r=_(t.parser,r,"script")).body.length>0&&r.body[0].length>1)throw new z("{subarray} can contain only one column");return r},htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["cases","dcases","rcases","drcases"],props:{numArgs:0},handler:function(t){var e=_(t.parser,{arraystretch:1.2,cols:[{type:"align",align:"l",pregap:0,postgap:1},{type:"align",align:"l",pregap:0,postgap:0}]},S(t.envName));return{type:"leftright",mode:t.mode,body:[e],left:t.envName.indexOf("r")>-1?".":"\\{",right:t.envName.indexOf("r")>-1?"\\}":".",rightColor:void 0}},htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["align","align*","aligned","split"],props:{numArgs:0},handler:Ji,htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["gathered","gather","gather*"],props:{numArgs:0},handler:function(t){I.contains(["gather","gather*"],t.envName)&&$i(t);var e={cols:[{type:"align",align:"c"}],addJot:!0,colSeparationType:"gather",autoTag:k(t.envName),emptySingleRow:!0,leqno:t.parser.settings.leqno};return _(t.parser,e,"display")},htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["alignat","alignat*","alignedat"],props:{numArgs:1},handler:Ji,htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["equation","equation*"],props:{numArgs:0},handler:function(t){$i(t);var e={autoTag:k(t.envName),emptySingleRow:!0,singleRow:!0,maxNumCols:1,leqno:t.parser.settings.leqno};return _(t.parser,e,"display")},htmlBuilder:Xi,mathmlBuilder:Zi}),y({type:"array",names:["CD"],props:{numArgs:0},handler:function(t){return $i(t),function(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 i=t.fetch().text;if("&"!==i&&"\\\\"!==i){if("\\end"===i){0===e[e.length-1].length&&e.pop();break}throw new z("Expected \\\\ or \\cr or \\end",t.nextToken)}t.consume()}for(var r,n,a=[],o=[a],s=0;s-1);else{if(!("<>AV".indexOf(d)>-1))throw new z('Expected one of "<>AV=|." after @',l[c]);for(var m=0;m<2;m++){for(var f=!0,v=c+1;v=U.SCRIPT.id?i.text():U.DISPLAY:"text"===t&&i.size===U.DISPLAY.size?i=U.TEXT:"script"===t?i=U.SCRIPT:"scriptscript"===t&&(i=U.SCRIPTSCRIPT),i},nr=function(t,e){var i,r=rr(t.size,e.style),n=r.fracNum(),a=r.fracDen();i=e.havingStyle(n);var o=He(t.numer,i,e);if(t.continued){var s=8.5/e.fontMetrics().ptPerEm,l=3.5/e.fontMetrics().ptPerEm;o.height=o.height0?3*d:7*d,m=e.fontMetrics().denom1):(c>0?(u=e.fontMetrics().num2,p=d):(u=e.fontMetrics().num3,p=3*d),m=e.fontMetrics().denom2),h){var x=e.fontMetrics().axisHeight;u-o.depth-(x+.5*c)0&&(e="."===(e=t)?null:e),e};a({type:"genfrac",names:["\\genfrac"],props:{numArgs:6,allowedInArgument:!0,argTypes:["math","math","size","text","math","math"]},handler:function(t,e){var i,r=t.parser,n=e[4],a=e[5],o=Te(e[0]),s="atom"===o.type&&"open"===o.family?sr(o.text):null,l=Te(e[1]),h="atom"===l.type&&"close"===l.family?sr(l.text):null,c=d(e[2],"size"),u=null;i=!!c.isBlank||(u=c.value).number>0;var p="auto",m=e[3];if("ordgroup"===m.type){if(m.body.length>0){var f=d(m.body[0],"textord");p=or[Number(f.text)]}}else m=d(m,"textord"),p=or[Number(m.text)];return{type:"genfrac",mode:r.mode,numer:n,denom:a,continued:!1,hasBarLine:i,barSize:u,leftDelim:s,rightDelim:h,size:p}},htmlBuilder:nr,mathmlBuilder:ar}),a({type:"infix",names:["\\above"],props:{numArgs:1,argTypes:["size"],infix:!0},handler:function(t,e){var i=t.parser,r=(t.funcName,t.token);return{type:"infix",mode:i.mode,replaceWith:"\\\\abovefrac",size:d(e[0],"size").value,token:r}}}),a({type:"genfrac",names:["\\\\abovefrac"],props:{numArgs:3,argTypes:["math","size","math"]},handler:function(t,e){var i=t.parser,r=(t.funcName,e[0]),n=function(t){if(!t)throw new Error("Expected non-null, but got "+String(t));return t}(d(e[1],"infix").size),a=e[2],o=n.number>0;return{type:"genfrac",mode:i.mode,numer:r,denom:a,continued:!1,hasBarLine:o,barSize:n,leftDelim:null,rightDelim:null,size:"auto"}},htmlBuilder:nr,mathmlBuilder:ar});var lr=function(t,e){var i,r,n=e.style;"supsub"===t.type?(i=t.sup?He(t.sup,e.havingStyle(n.sup()),e):He(t.sub,e.havingStyle(n.sub()),e),r=d(t.base,"horizBrace")):r=d(t,"horizBrace");var a,o=He(r.base,e.havingBaseStyle(U.DISPLAY)),s=ri(r,e);if(r.isOver?(a=be.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:o},{type:"kern",size:.1},{type:"elem",elem:s}]},e)).children[0].children[0].children[1].classes.push("svg-align"):(a=be.makeVList({positionType:"bottom",positionData:o.depth+.1+s.height,children:[{type:"elem",elem:s},{type:"kern",size:.1},{type:"elem",elem:o}]},e)).children[0].children[0].children[0].classes.push("svg-align"),i){var l=be.makeSpan(["mord",r.isOver?"mover":"munder"],[a],e);a=r.isOver?be.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:l},{type:"kern",size:.2},{type:"elem",elem:i}]},e):be.makeVList({positionType:"bottom",positionData:l.depth+.2+i.height+i.depth,children:[{type:"elem",elem:i},{type:"kern",size:.2},{type:"elem",elem:l}]},e)}return be.makeSpan(["mord",r.isOver?"mover":"munder"],[a],e)};a({type:"horizBrace",names:["\\overbrace","\\underbrace"],props:{numArgs:1},handler:function(t,e){var i=t.parser,r=t.funcName;return{type:"horizBrace",mode:i.mode,label:r,isOver:/^\\over/.test(r),base:e[0]}},htmlBuilder:lr,mathmlBuilder:function(t,e){var i=ii(t.label);return new je.MathNode(t.isOver?"mover":"munder",[Xe(t.base,e),i])}}),a({type:"href",names:["\\href"],props:{numArgs:2,argTypes:["url","original"],allowedInText:!0},handler:function(t,e){var i=t.parser,r=e[1],n=d(e[0],"url").url;return i.settings.isTrusted({command:"\\href",url:n})?{type:"href",mode:i.mode,href:n,body:Ce(r)}:i.formatUnsupportedCmd("\\href")},htmlBuilder:function(t,e){var i=Ie(t.body,e,!1);return be.makeAnchor(t.href,[],i,e)},mathmlBuilder:function(t,e){var i=$e(t.body,e);return i instanceof Ve||(i=new Ve("mrow",[i])),i.setAttribute("href",t.href),i}}),a({type:"href",names:["\\url"],props:{numArgs:1,argTypes:["url"],allowedInText:!0},handler:function(t,e){var i=t.parser,r=d(e[0],"url").url;if(!i.settings.isTrusted({command:"\\url",url:r}))return i.formatUnsupportedCmd("\\url");for(var n=[],a=0;a0&&(r=ht(t.totalheight,e)-i);var n=0;t.width.number>0&&(n=ht(t.width,e));var a={height:ct(i+r)};n>0&&(a.width=ct(n)),r>0&&(a.verticalAlign=ct(-r));var o=new vt(t.src,t.alt,a);return o.height=i,o.depth=r,o},mathmlBuilder:function(t,e){var i=new je.MathNode("mglyph",[]);i.setAttribute("alt",t.alt);var r=ht(t.height,e),n=0;if(t.totalheight.number>0&&(n=ht(t.totalheight,e)-r,i.setAttribute("valign",ct(-n))),i.setAttribute("height",ct(r+n)),t.width.number>0){var a=ht(t.width,e);i.setAttribute("width",ct(a))}return i.setAttribute("src",t.src),i}}),a({type:"kern",names:["\\kern","\\mkern","\\hskip","\\mskip"],props:{numArgs:1,argTypes:["size"],primitive:!0,allowedInText:!0},handler:function(t,e){var i=t.parser,r=t.funcName,n=d(e[0],"size");if(i.settings.strict){var a="m"===r[1],o="mu"===n.value.unit;a?(o||i.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" supports only mu units, not "+n.value.unit+" units"),"math"!==i.mode&&i.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" works only in math mode")):o&&i.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" doesn't support mu units")}return{type:"kern",mode:i.mode,dimension:n.value}},htmlBuilder:function(t,e){return be.makeGlue(t.dimension,e)},mathmlBuilder:function(t,e){var i=ht(t.dimension,e);return new je.SpaceNode(i)}}),a({type:"lap",names:["\\mathllap","\\mathrlap","\\mathclap"],props:{numArgs:1,allowedInText:!0},handler:function(t,e){var i=t.parser,r=t.funcName,n=e[0];return{type:"lap",mode:i.mode,alignment:r.slice(5),body:n}},htmlBuilder:function(t,e){var i;"clap"===t.alignment?(i=be.makeSpan([],[He(t.body,e)]),i=be.makeSpan(["inner"],[i],e)):i=be.makeSpan(["inner"],[He(t.body,e)]);var r=be.makeSpan(["fix"],[]),n=be.makeSpan([t.alignment],[i,r],e),a=be.makeSpan(["strut"]);return a.style.height=ct(n.height+n.depth),n.depth&&(a.style.verticalAlign=ct(-n.depth)),n.children.unshift(a),n=be.makeSpan(["thinbox"],[n],e),be.makeSpan(["mord","vbox"],[n],e)},mathmlBuilder:function(t,e){var i=new je.MathNode("mpadded",[Xe(t.body,e)]);if("rlap"!==t.alignment){var r="llap"===t.alignment?"-1":"-0.5";i.setAttribute("lspace",r+"width")}return i.setAttribute("width","0px"),i}}),a({type:"styling",names:["\\(","$"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler:function(t){var e=t.funcName,i=t.parser,r=i.mode;i.switchMode("math");var n="\\("===e?"\\)":"$",a=i.parseExpression(!1,n);return i.expect(n),i.switchMode(r),{type:"styling",mode:i.mode,style:"text",body:a}}}),a({type:"text",names:["\\)","\\]"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler:function(t){throw new z("Mismatched "+t.funcName)}});var cr=function(t,e){switch(e.style.size){case U.DISPLAY.size:return t.display;case U.TEXT.size:return t.text;case U.SCRIPT.size:return t.script;case U.SCRIPTSCRIPT.size:return t.scriptscript;default:return t.text}};a({type:"mathchoice",names:["\\mathchoice"],props:{numArgs:4,primitive:!0},handler:function(t,e){return{type:"mathchoice",mode:t.parser.mode,display:Ce(e[0]),text:Ce(e[1]),script:Ce(e[2]),scriptscript:Ce(e[3])}},htmlBuilder:function(t,e){var i=cr(t,e),r=Ie(i,e,!1);return be.makeFragment(r)},mathmlBuilder:function(t,e){var i=cr(t,e);return $e(i,e)}});var dr=function(t,e,i,r,n,a,o){t=be.makeSpan([],[t]);var s,l,h,c=i&&I.isCharacterBox(i);if(e){var d=He(e,r.havingStyle(n.sup()),r);l={elem:d,kern:Math.max(r.fontMetrics().bigOpSpacing1,r.fontMetrics().bigOpSpacing3-d.depth)}}if(i){var u=He(i,r.havingStyle(n.sub()),r);s={elem:u,kern:Math.max(r.fontMetrics().bigOpSpacing2,r.fontMetrics().bigOpSpacing4-u.height)}}if(l&&s){var p=r.fontMetrics().bigOpSpacing5+s.elem.height+s.elem.depth+s.kern+t.depth+o;h=be.makeVList({positionType:"bottom",positionData:p,children:[{type:"kern",size:r.fontMetrics().bigOpSpacing5},{type:"elem",elem:s.elem,marginLeft:ct(-a)},{type:"kern",size:s.kern},{type:"elem",elem:t},{type:"kern",size:l.kern},{type:"elem",elem:l.elem,marginLeft:ct(a)},{type:"kern",size:r.fontMetrics().bigOpSpacing5}]},r)}else if(s){var m=t.height-o;h=be.makeVList({positionType:"top",positionData:m,children:[{type:"kern",size:r.fontMetrics().bigOpSpacing5},{type:"elem",elem:s.elem,marginLeft:ct(-a)},{type:"kern",size:s.kern},{type:"elem",elem:t}]},r)}else{if(!l)return t;var f=t.depth+o;h=be.makeVList({positionType:"bottom",positionData:f,children:[{type:"elem",elem:t},{type:"kern",size:l.kern},{type:"elem",elem:l.elem,marginLeft:ct(a)},{type:"kern",size:r.fontMetrics().bigOpSpacing5}]},r)}var g=[h];if(s&&0!==a&&!c){var v=be.makeSpan(["mspace"],[],r);v.style.marginRight=ct(a),g.unshift(v)}return be.makeSpan(["mop","op-limits"],g,r)},ur=["\\smallint"],pr=function(t,e){var i,r,n,a=!1;"supsub"===t.type?(i=t.sup,r=t.sub,n=d(t.base,"op"),a=!0):n=d(t,"op");var o,s=e.style,l=!1;if(s.size===U.DISPLAY.size&&n.symbol&&!I.contains(ur,n.name)&&(l=!0),n.symbol){var h=l?"Size2-Regular":"Size1-Regular",c="";if("\\oiint"!==n.name&&"\\oiiint"!==n.name||(c=n.name.slice(1),n.name="oiint"===c?"\\iint":"\\iiint"),o=be.makeSymbol(n.name,h,"math",e,["mop","op-symbol",l?"large-op":"small-op"]),c.length>0){var u=o.italic,p=be.staticSvg(c+"Size"+(l?"2":"1"),e);o=be.makeVList({positionType:"individualShift",children:[{type:"elem",elem:o,shift:0},{type:"elem",elem:p,shift:l?.08:0}]},e),n.name="\\"+c,o.classes.unshift("mop"),o.italic=u}}else if(n.body){var m=Ie(n.body,e,!0);1===m.length&&m[0]instanceof yt?(o=m[0]).classes[0]="mop":o=be.makeSpan(["mop"],m,e)}else{for(var f=[],g=1;g0){for(var s=n.body.map(function(t){var e=t.text;return"string"==typeof e?{type:"textord",mode:t.mode,text:e}:t}),l=Ie(s,e.withFont("mathrm"),!0),h=0;h=0?s.setAttribute("height",ct(n)):(s.setAttribute("height",ct(n)),s.setAttribute("depth",ct(-n))),s.setAttribute("voffset",ct(n)),s}});var br=["\\tiny","\\sixptsize","\\scriptsize","\\footnotesize","\\small","\\normalsize","\\large","\\Large","\\LARGE","\\huge","\\Huge"];a({type:"sizing",names:br,props:{numArgs:0,allowedInText:!0},handler:function(t){var e=t.breakOnTokenText,i=t.funcName,r=t.parser,n=r.parseExpression(!1,e);return{type:"sizing",mode:r.mode,size:br.indexOf(i)+1,body:n}},htmlBuilder:function(t,e){var i=e.havingSize(t.size);return M(t.body,i,e)},mathmlBuilder:function(t,e){var i=e.havingSize(t.size),r=Ye(t.body,i),n=new je.MathNode("mstyle",r);return n.setAttribute("mathsize",ct(i.sizeMultiplier)),n}}),a({type:"smash",names:["\\smash"],props:{numArgs:1,numOptionalArgs:1,allowedInText:!0},handler:function(t,e,i){var r=t.parser,n=!1,a=!1,o=i[0]&&d(i[0],"ordgroup");if(o)for(var s="",l=0;li.height+i.depth+a&&(a=(a+d-i.height-i.depth)/2);var u=l.height-i.height-a-h;i.style.paddingLeft=ct(c);var p=be.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i,wrapperClasses:["svg-align"]},{type:"kern",size:-(i.height+u)},{type:"elem",elem:l},{type:"kern",size:h}]},e);if(t.index){var m=e.havingStyle(U.SCRIPTSCRIPT),f=He(t.index,m,e),g=.6*(p.height-p.depth),v=be.makeVList({positionType:"shift",positionData:-g,children:[{type:"elem",elem:f}]},e),b=be.makeSpan(["root"],[v]);return be.makeSpan(["mord","sqrt"],[b,p],e)}return be.makeSpan(["mord","sqrt"],[p],e)},mathmlBuilder:function(t,e){var i=t.body,r=t.index;return r?new je.MathNode("mroot",[Xe(i,e),Xe(r,e)]):new je.MathNode("msqrt",[Xe(i,e)])}});var yr={display:U.DISPLAY,text:U.TEXT,script:U.SCRIPT,scriptscript:U.SCRIPTSCRIPT};a({type:"styling",names:["\\displaystyle","\\textstyle","\\scriptstyle","\\scriptscriptstyle"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler:function(t){var e=t.breakOnTokenText,i=t.funcName,r=t.parser,n=r.parseExpression(!0,e),a=i.slice(1,i.length-5);return{type:"styling",mode:r.mode,style:a,body:n}},htmlBuilder:function(t,e){var i=yr[t.style],r=e.havingStyle(i).withFont("");return M(t.body,r,e)},mathmlBuilder:function(t,e){var i=yr[t.style],r=e.havingStyle(i),n=Ye(t.body,r),a=new je.MathNode("mstyle",n),o={display:["0","true"],text:["0","false"],script:["1","false"],scriptscript:["2","false"]}[t.style];return a.setAttribute("scriptlevel",o[0]),a.setAttribute("displaystyle",o[1]),a}});var xr=function(t,e){var i=t.base;return i?"op"===i.type?i.limits&&(e.style.size===U.DISPLAY.size||i.alwaysHandleSupSub)?pr:null:"operatorname"===i.type?i.alwaysHandleSupSub&&(e.style.size===U.DISPLAY.size||i.limits)?vr:null:"accent"===i.type?I.isCharacterBox(i.base)?ni:null:"horizBrace"===i.type&&!t.sub===i.isOver?lr:null:null};o({type:"supsub",htmlBuilder:function(t,e){var i=xr(t,e);if(i)return i(t,e);var r,n,a,o=t.base,s=t.sup,l=t.sub,h=He(o,e),c=e.fontMetrics(),d=0,u=0,p=o&&I.isCharacterBox(o);if(s){var m=e.havingStyle(e.style.sup());r=He(s,m,e),p||(d=h.height-m.fontMetrics().supDrop*m.sizeMultiplier/e.sizeMultiplier)}if(l){var f=e.havingStyle(e.style.sub());n=He(l,f,e),p||(u=h.depth+f.fontMetrics().subDrop*f.sizeMultiplier/e.sizeMultiplier)}a=e.style===U.DISPLAY?c.sup1:e.style.cramped?c.sup3:c.sup2;var g,v=e.sizeMultiplier,b=ct(.5/c.ptPerEm/v),y=null;if(n){var x=t.base&&"op"===t.base.type&&t.base.name&&("\\oiint"===t.base.name||"\\oiiint"===t.base.name);(h instanceof yt||x)&&(y=ct(-h.italic))}if(r&&n){d=Math.max(d,a,r.depth+.25*c.xHeight),u=Math.max(u,c.sub2);var w=4*c.defaultRuleThickness;if(d-r.depth-(n.height-u)0&&(d+=k,u-=k)}var _=[{type:"elem",elem:n,shift:u,marginRight:b,marginLeft:y},{type:"elem",elem:r,shift:-d,marginRight:b}];g=be.makeVList({positionType:"individualShift",children:_},e)}else if(n){u=Math.max(u,c.sub1,n.height-.8*c.xHeight);var S=[{type:"elem",elem:n,marginLeft:y,marginRight:b}];g=be.makeVList({positionType:"shift",positionData:u,children:S},e)}else{if(!r)throw new Error("supsub must have either sup or sub.");d=Math.max(d,a,r.depth+.25*c.xHeight),g=be.makeVList({positionType:"shift",positionData:-d,children:[{type:"elem",elem:r,marginRight:b}]},e)}var M=Ne(h,"right")||"mord";return be.makeSpan([M],[h,be.makeSpan(["msupsub"],[g])],e)},mathmlBuilder:function(t,e){var i,r=!1;t.base&&"horizBrace"===t.base.type&&!!t.sup===t.base.isOver&&(r=!0,i=t.base.isOver),!t.base||"op"!==t.base.type&&"operatorname"!==t.base.type||(t.base.parentIsSupSub=!0);var n,a=[Xe(t.base,e)];if(t.sub&&a.push(Xe(t.sub,e)),t.sup&&a.push(Xe(t.sup,e)),r)n=i?"mover":"munder";else if(t.sub)if(t.sup){var o=t.base;n=o&&"op"===o.type&&o.limits&&e.style===U.DISPLAY||o&&"operatorname"===o.type&&o.alwaysHandleSupSub&&(e.style===U.DISPLAY||o.limits)?"munderover":"msubsup"}else{var s=t.base;n=s&&"op"===s.type&&s.limits&&(e.style===U.DISPLAY||s.alwaysHandleSupSub)||s&&"operatorname"===s.type&&s.alwaysHandleSupSub&&(s.limits||e.style===U.DISPLAY)?"munder":"msub"}else{var l=t.base;n=l&&"op"===l.type&&l.limits&&(e.style===U.DISPLAY||l.alwaysHandleSupSub)||l&&"operatorname"===l.type&&l.alwaysHandleSupSub&&(l.limits||e.style===U.DISPLAY)?"mover":"msup"}return new je.MathNode(n,a)}}),o({type:"atom",htmlBuilder:function(t,e){return be.mathsym(t.text,t.mode,e,["m"+t.family])},mathmlBuilder:function(t,e){var i=new je.MathNode("mo",[We(t.text,t.mode)]);if("bin"===t.family){var r=Ge(t,e);"bold-italic"===r&&i.setAttribute("mathvariant",r)}else"punct"===t.family?i.setAttribute("separator","true"):"open"!==t.family&&"close"!==t.family||i.setAttribute("stretchy","false");return i}});var wr={mi:"italic",mn:"normal",mtext:"normal"};o({type:"mathord",htmlBuilder:function(t,e){return be.makeOrd(t,e,"mathord")},mathmlBuilder:function(t,e){var i=new je.MathNode("mi",[We(t.text,t.mode,e)]),r=Ge(t,e)||"italic";return r!==wr[i.type]&&i.setAttribute("mathvariant",r),i}}),o({type:"textord",htmlBuilder:function(t,e){return be.makeOrd(t,e,"textord")},mathmlBuilder:function(t,e){var i,r=We(t.text,t.mode,e),n=Ge(t,e)||"normal";return i="text"===t.mode?new je.MathNode("mtext",[r]):/[0-9]/.test(t.text)?new je.MathNode("mn",[r]):"\\prime"===t.text?new je.MathNode("mo",[r]):new je.MathNode("mi",[r]),n!==wr[i.type]&&i.setAttribute("mathvariant",n),i}});var kr={"\\nobreak":"nobreak","\\allowbreak":"allowbreak"},_r={" ":{},"\\ ":{},"~":{className:"nobreak"},"\\space":{},"\\nobreakspace":{className:"nobreak"}};o({type:"spacing",htmlBuilder:function(t,e){if(_r.hasOwnProperty(t.text)){var i=_r[t.text].className||"";if("text"===t.mode){var r=be.makeOrd(t,e,"textord");return r.classes.push(i),r}return be.makeSpan(["mspace",i],[be.mathsym(t.text,t.mode,e)],e)}if(kr.hasOwnProperty(t.text))return be.makeSpan(["mspace",kr[t.text]],[],e);throw new z('Unknown type of space "'+t.text+'"')},mathmlBuilder:function(t){if(!_r.hasOwnProperty(t.text)){if(kr.hasOwnProperty(t.text))return new je.MathNode("mspace");throw new z('Unknown type of space "'+t.text+'"')}return new je.MathNode("mtext",[new je.TextNode("\xa0")])}});var Sr=function(){ var t=new je.MathNode("mtd",[]);return t.setAttribute("width","50%"),t};o({type:"tag",mathmlBuilder:function(t,e){var i=new je.MathNode("mtable",[new je.MathNode("mtr",[Sr(),new je.MathNode("mtd",[$e(t.body,e)]),Sr(),new je.MathNode("mtd",[$e(t.tag,e)])])]);return i.setAttribute("width","100%"),i}});var Mr={"\\text":void 0,"\\textrm":"textrm","\\textsf":"textsf","\\texttt":"texttt","\\textnormal":"textrm"},Ar={"\\textbf":"textbf","\\textmd":"textmd"},Tr={"\\textit":"textit","\\textup":"textup"},Cr=function(t,e){var i=t.font;return i?Mr[i]?e.withTextFontFamily(Mr[i]):Ar[i]?e.withTextFontWeight(Ar[i]):e.withTextFontShape(Tr[i]):e};a({type:"text",names:["\\text","\\textrm","\\textsf","\\texttt","\\textnormal","\\textbf","\\textmd","\\textit","\\textup"],props:{numArgs:1,argTypes:["text"],allowedInArgument:!0,allowedInText:!0},handler:function(t,e){var i=t.parser,r=t.funcName,n=e[0];return{type:"text",mode:i.mode,body:Ce(n),font:r}},htmlBuilder:function(t,e){var i=Cr(t,e),r=Ie(t.body,i,!0);return be.makeSpan(["mord","text"],r,i)},mathmlBuilder:function(t,e){var i=Cr(t,e);return $e(t.body,i)}}),a({type:"underline",names:["\\underline"],props:{numArgs:1,allowedInText:!0},handler:function(t,e){return{type:"underline",mode:t.parser.mode,body:e[0]}},htmlBuilder:function(t,e){var i=He(t.body,e),r=be.makeLineSpan("underline-line",e),n=e.fontMetrics().defaultRuleThickness,a=be.makeVList({positionType:"top",positionData:i.height,children:[{type:"kern",size:n},{type:"elem",elem:r},{type:"kern",size:3*n},{type:"elem",elem:i}]},e);return be.makeSpan(["mord","underline"],[a],e)},mathmlBuilder:function(t,e){var i=new je.MathNode("mo",[new je.TextNode("\u203e")]);i.setAttribute("stretchy","true");var r=new je.MathNode("munder",[Xe(t.body,e),i]);return r.setAttribute("accentunder","true"),r}}),a({type:"vcenter",names:["\\vcenter"],props:{numArgs:1,argTypes:["original"],allowedInText:!1},handler:function(t,e){return{type:"vcenter",mode:t.parser.mode,body:e[0]}},htmlBuilder:function(t,e){var i=He(t.body,e),r=e.fontMetrics().axisHeight,n=.5*(i.height-r-(i.depth+r));return be.makeVList({positionType:"shift",positionData:n,children:[{type:"elem",elem:i}]},e)},mathmlBuilder:function(t,e){return new je.MathNode("mpadded",[Xe(t.body,e)],["vcenter"])}}),a({type:"verb",names:["\\verb"],props:{numArgs:0,allowedInText:!0},handler:function(){throw new z("\\verb ended by end of line instead of matching delimiter")},htmlBuilder:function(t,e){for(var i=zr(t),r=[],n=e.havingStyle(e.style.text()),a=0;a0;)this.endGroup()},e.has=function(t){return this.current.hasOwnProperty(t)||this.builtins.hasOwnProperty(t)},e.get=function(t){return this.current.hasOwnProperty(t)?this.current[t]:this.builtins[t]},e.set=function(t,e,i){if(void 0===i&&(i=!1),i){for(var r=0;r0&&(this.undefStack[this.undefStack.length-1][t]=e)}else{var n=this.undefStack[this.undefStack.length-1];n&&!n.hasOwnProperty(t)&&(n[t]=this.current[t])}null==e?delete this.current[t]:this.current[t]=e},t}(),Nr=Ui;x("\\noexpand",function(t){var e=t.popToken();return t.isExpandable(e.text)&&(e.noexpand=!0,e.treatAsRelax=!0),{tokens:[e],numArgs:0}}),x("\\expandafter",function(t){var e=t.popToken();return t.expandOnce(!0),{tokens:[e],numArgs:0}}),x("\\@firstoftwo",function(t){return{tokens:t.consumeArgs(2)[0],numArgs:0}}),x("\\@secondoftwo",function(t){return{tokens:t.consumeArgs(2)[1],numArgs:0}}),x("\\@ifnextchar",function(t){var e=t.consumeArgs(3);t.consumeSpaces();var i=t.future();return 1===e[0].length&&e[0][0].text===i.text?{tokens:e[1],numArgs:0}:{tokens:e[2],numArgs:0}}),x("\\@ifstar","\\@ifnextchar *{\\@firstoftwo{#1}}"),x("\\TextOrMath",function(t){var e=t.consumeArgs(2);return"text"===t.mode?{tokens:e[0],numArgs:0}:{tokens:e[1],numArgs:0}});var Fr={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};x("\\char",function(t){var e,i=t.popToken(),r="";if("'"===i.text)e=8,i=t.popToken();else if('"'===i.text)e=16,i=t.popToken();else if("`"===i.text)if("\\"===(i=t.popToken()).text[0])r=i.text.charCodeAt(1);else{if("EOF"===i.text)throw new z("\\char` missing argument");r=i.text.charCodeAt(0)}else e=10;if(e){if(null==(r=Fr[i.text])||r>=e)throw new z("Invalid base-"+e+" digit "+i.text);for(var n;null!=(n=Fr[t.future().text])&&n":"\\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"};x("\\dots",function(t){var e="\\dotso",i=t.expandAfterFuture().text;return i in Vr?e=Vr[i]:("\\not"===i.slice(0,4)||i in At.math&&I.contains(["bin","rel"],At.math[i].group))&&(e="\\dotsb"),e});var qr={")":!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};x("\\dotso",function(t){return t.future().text in qr?"\\ldots\\,":"\\ldots"}),x("\\dotsc",function(t){var e=t.future().text;return e in qr&&","!==e?"\\ldots\\,":"\\ldots"}),x("\\cdots",function(t){return t.future().text in qr?"\\@cdots\\,":"\\@cdots"}),x("\\dotsb","\\cdots"),x("\\dotsm","\\cdots"),x("\\dotsi","\\!\\cdots"),x("\\dotsx","\\ldots\\,"),x("\\DOTSI","\\relax"),x("\\DOTSB","\\relax"),x("\\DOTSX","\\relax"),x("\\tmspace","\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax"),x("\\,","\\tmspace+{3mu}{.1667em}"),x("\\thinspace","\\,"),x("\\>","\\mskip{4mu}"),x("\\:","\\tmspace+{4mu}{.2222em}"),x("\\medspace","\\:"),x("\\;","\\tmspace+{5mu}{.2777em}"),x("\\thickspace","\\;"),x("\\!","\\tmspace-{3mu}{.1667em}"),x("\\negthinspace","\\!"),x("\\negmedspace","\\tmspace-{4mu}{.2222em}"),x("\\negthickspace","\\tmspace-{5mu}{.277em}"),x("\\enspace","\\kern.5em "),x("\\enskip","\\hskip.5em\\relax"),x("\\quad","\\hskip1em\\relax"),x("\\qquad","\\hskip2em\\relax"),x("\\tag","\\@ifstar\\tag@literal\\tag@paren"),x("\\tag@paren","\\tag@literal{({#1})}"),x("\\tag@literal",function(t){if(t.macros.get("\\df@tag"))throw new z("Multiple \\tag");return"\\gdef\\df@tag{\\text{#1}}"}),x("\\bmod","\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}"),x("\\pod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)"),x("\\pmod","\\pod{{\\rm mod}\\mkern6mu#1}"),x("\\mod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1"),x("\\newline","\\\\\\relax"),x("\\TeX","\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}");var jr=ct(Z["Main-Regular"]["T".charCodeAt(0)][1]-.7*Z["Main-Regular"]["A".charCodeAt(0)][1]);x("\\LaTeX","\\textrm{\\html@mathml{L\\kern-.36em\\raisebox{"+jr+"}{\\scriptstyle A}\\kern-.15em\\TeX}{LaTeX}}"),x("\\KaTeX","\\textrm{\\html@mathml{K\\kern-.17em\\raisebox{"+jr+"}{\\scriptstyle A}\\kern-.15em\\TeX}{KaTeX}}"),x("\\hspace","\\@ifstar\\@hspacer\\@hspace"),x("\\@hspace","\\hskip #1\\relax"),x("\\@hspacer","\\rule{0pt}{0pt}\\hskip #1\\relax"),x("\\ordinarycolon",":"),x("\\vcentcolon","\\mathrel{\\mathop\\ordinarycolon}"),x("\\dblcolon",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}'),x("\\coloneqq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}'),x("\\Coloneqq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}'),x("\\coloneq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}'),x("\\Coloneq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}'),x("\\eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}'),x("\\Eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}'),x("\\eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}'),x("\\Eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}'),x("\\colonapprox",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}'),x("\\Colonapprox",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}'),x("\\colonsim",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}'),x("\\Colonsim",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}'),x("\u2237","\\dblcolon"),x("\u2239","\\eqcolon"),x("\u2254","\\coloneqq"),x("\u2255","\\eqqcolon"),x("\u2a74","\\Coloneqq"),x("\\ratio","\\vcentcolon"),x("\\coloncolon","\\dblcolon"),x("\\colonequals","\\coloneqq"),x("\\coloncolonequals","\\Coloneqq"),x("\\equalscolon","\\eqqcolon"),x("\\equalscoloncolon","\\Eqqcolon"),x("\\colonminus","\\coloneq"),x("\\coloncolonminus","\\Coloneq"),x("\\minuscolon","\\eqcolon"),x("\\minuscoloncolon","\\Eqcolon"),x("\\coloncolonapprox","\\Colonapprox"),x("\\coloncolonsim","\\Colonsim"),x("\\simcolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}"),x("\\simcoloncolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}"),x("\\approxcolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}"),x("\\approxcoloncolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}"),x("\\notni","\\html@mathml{\\not\\ni}{\\mathrel{\\char`\u220c}}"),x("\\limsup","\\DOTSB\\operatorname*{lim\\,sup}"),x("\\liminf","\\DOTSB\\operatorname*{lim\\,inf}"),x("\\injlim","\\DOTSB\\operatorname*{inj\\,lim}"),x("\\projlim","\\DOTSB\\operatorname*{proj\\,lim}"),x("\\varlimsup","\\DOTSB\\operatorname*{\\overline{lim}}"),x("\\varliminf","\\DOTSB\\operatorname*{\\underline{lim}}"),x("\\varinjlim","\\DOTSB\\operatorname*{\\underrightarrow{lim}}"),x("\\varprojlim","\\DOTSB\\operatorname*{\\underleftarrow{lim}}"),x("\\gvertneqq","\\html@mathml{\\@gvertneqq}{\u2269}"),x("\\lvertneqq","\\html@mathml{\\@lvertneqq}{\u2268}"),x("\\ngeqq","\\html@mathml{\\@ngeqq}{\u2271}"),x("\\ngeqslant","\\html@mathml{\\@ngeqslant}{\u2271}"),x("\\nleqq","\\html@mathml{\\@nleqq}{\u2270}"),x("\\nleqslant","\\html@mathml{\\@nleqslant}{\u2270}"),x("\\nshortmid","\\html@mathml{\\@nshortmid}{\u2224}"),x("\\nshortparallel","\\html@mathml{\\@nshortparallel}{\u2226}"),x("\\nsubseteqq","\\html@mathml{\\@nsubseteqq}{\u2288}"),x("\\nsupseteqq","\\html@mathml{\\@nsupseteqq}{\u2289}"),x("\\varsubsetneq","\\html@mathml{\\@varsubsetneq}{\u228a}"),x("\\varsubsetneqq","\\html@mathml{\\@varsubsetneqq}{\u2acb}"),x("\\varsupsetneq","\\html@mathml{\\@varsupsetneq}{\u228b}"),x("\\varsupsetneqq","\\html@mathml{\\@varsupsetneqq}{\u2acc}"),x("\\imath","\\html@mathml{\\@imath}{\u0131}"),x("\\jmath","\\html@mathml{\\@jmath}{\u0237}"),x("\\llbracket","\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`\u27e6}}"),x("\\rrbracket","\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`\u27e7}}"),x("\u27e6","\\llbracket"),x("\u27e7","\\rrbracket"),x("\\lBrace","\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`\u2983}}"),x("\\rBrace","\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`\u2984}}"),x("\u2983","\\lBrace"),x("\u2984","\\rBrace"),x("\\minuso","\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`\u29b5}}"),x("\u29b5","\\minuso"),x("\\darr","\\downarrow"),x("\\dArr","\\Downarrow"),x("\\Darr","\\Downarrow"),x("\\lang","\\langle"),x("\\rang","\\rangle"),x("\\uarr","\\uparrow"),x("\\uArr","\\Uparrow"),x("\\Uarr","\\Uparrow"),x("\\N","\\mathbb{N}"),x("\\R","\\mathbb{R}"),x("\\Z","\\mathbb{Z}"),x("\\alef","\\aleph"),x("\\alefsym","\\aleph"),x("\\Alpha","\\mathrm{A}"),x("\\Beta","\\mathrm{B}"),x("\\bull","\\bullet"),x("\\Chi","\\mathrm{X}"),x("\\clubs","\\clubsuit"),x("\\cnums","\\mathbb{C}"),x("\\Complex","\\mathbb{C}"),x("\\Dagger","\\ddagger"),x("\\diamonds","\\diamondsuit"),x("\\empty","\\emptyset"),x("\\Epsilon","\\mathrm{E}"),x("\\Eta","\\mathrm{H}"),x("\\exist","\\exists"),x("\\harr","\\leftrightarrow"),x("\\hArr","\\Leftrightarrow"),x("\\Harr","\\Leftrightarrow"),x("\\hearts","\\heartsuit"),x("\\image","\\Im"),x("\\infin","\\infty"),x("\\Iota","\\mathrm{I}"),x("\\isin","\\in"),x("\\Kappa","\\mathrm{K}"),x("\\larr","\\leftarrow"),x("\\lArr","\\Leftarrow"),x("\\Larr","\\Leftarrow"),x("\\lrarr","\\leftrightarrow"),x("\\lrArr","\\Leftrightarrow"),x("\\Lrarr","\\Leftrightarrow"),x("\\Mu","\\mathrm{M}"),x("\\natnums","\\mathbb{N}"),x("\\Nu","\\mathrm{N}"),x("\\Omicron","\\mathrm{O}"),x("\\plusmn","\\pm"),x("\\rarr","\\rightarrow"),x("\\rArr","\\Rightarrow"),x("\\Rarr","\\Rightarrow"),x("\\real","\\Re"),x("\\reals","\\mathbb{R}"),x("\\Reals","\\mathbb{R}"),x("\\Rho","\\mathrm{P}"),x("\\sdot","\\cdot"),x("\\sect","\\S"),x("\\spades","\\spadesuit"),x("\\sub","\\subset"),x("\\sube","\\subseteq"),x("\\supe","\\supseteq"),x("\\Tau","\\mathrm{T}"),x("\\thetasym","\\vartheta"),x("\\weierp","\\wp"),x("\\Zeta","\\mathrm{Z}"),x("\\argmin","\\DOTSB\\operatorname*{arg\\,min}"),x("\\argmax","\\DOTSB\\operatorname*{arg\\,max}"),x("\\plim","\\DOTSB\\mathop{\\operatorname{plim}}\\limits"),x("\\bra","\\mathinner{\\langle{#1}|}"),x("\\ket","\\mathinner{|{#1}\\rangle}"),x("\\braket","\\mathinner{\\langle{#1}\\rangle}"),x("\\Bra","\\left\\langle#1\\right|"),x("\\Ket","\\left|#1\\right\\rangle");var Wr=function(t){return function(e){var i=e.consumeArg().tokens,r=e.consumeArg().tokens,n=e.consumeArg().tokens,a=e.consumeArg().tokens,o=e.macros.get("|"),s=e.macros.get("\\|");e.macros.beginGroup();var l=function(e){return function(i){t&&(i.macros.set("|",o),n.length&&i.macros.set("\\|",s));var a=e;return!e&&n.length&&"|"===i.future().text&&(i.popToken(),a=!0),{tokens:a?n:r,numArgs:0}}};e.macros.set("|",l(!1)),n.length&&e.macros.set("\\|",l(!0));var h=e.consumeArg().tokens,c=e.expandTokens([].concat(a,h,i));return e.macros.endGroup(),{tokens:c.reverse(),numArgs:0}}};x("\\bra@ket",Wr(!1)),x("\\bra@set",Wr(!0)),x("\\Braket","\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}"),x("\\Set","\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}"),x("\\set","\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}"),x("\\angln","{\\angl n}"),x("\\blue","\\textcolor{##6495ed}{#1}"),x("\\orange","\\textcolor{##ffa500}{#1}"),x("\\pink","\\textcolor{##ff00af}{#1}"),x("\\red","\\textcolor{##df0030}{#1}"),x("\\green","\\textcolor{##28ae7b}{#1}"),x("\\gray","\\textcolor{gray}{#1}"),x("\\purple","\\textcolor{##9d38bd}{#1}"),x("\\blueA","\\textcolor{##ccfaff}{#1}"),x("\\blueB","\\textcolor{##80f6ff}{#1}"),x("\\blueC","\\textcolor{##63d9ea}{#1}"),x("\\blueD","\\textcolor{##11accd}{#1}"),x("\\blueE","\\textcolor{##0c7f99}{#1}"),x("\\tealA","\\textcolor{##94fff5}{#1}"),x("\\tealB","\\textcolor{##26edd5}{#1}"),x("\\tealC","\\textcolor{##01d1c1}{#1}"),x("\\tealD","\\textcolor{##01a995}{#1}"),x("\\tealE","\\textcolor{##208170}{#1}"),x("\\greenA","\\textcolor{##b6ffb0}{#1}"),x("\\greenB","\\textcolor{##8af281}{#1}"),x("\\greenC","\\textcolor{##74cf70}{#1}"),x("\\greenD","\\textcolor{##1fab54}{#1}"),x("\\greenE","\\textcolor{##0d923f}{#1}"),x("\\goldA","\\textcolor{##ffd0a9}{#1}"),x("\\goldB","\\textcolor{##ffbb71}{#1}"),x("\\goldC","\\textcolor{##ff9c39}{#1}"),x("\\goldD","\\textcolor{##e07d10}{#1}"),x("\\goldE","\\textcolor{##a75a05}{#1}"),x("\\redA","\\textcolor{##fca9a9}{#1}"),x("\\redB","\\textcolor{##ff8482}{#1}"),x("\\redC","\\textcolor{##f9685d}{#1}"),x("\\redD","\\textcolor{##e84d39}{#1}"),x("\\redE","\\textcolor{##bc2612}{#1}"),x("\\maroonA","\\textcolor{##ffbde0}{#1}"),x("\\maroonB","\\textcolor{##ff92c6}{#1}"),x("\\maroonC","\\textcolor{##ed5fa6}{#1}"),x("\\maroonD","\\textcolor{##ca337c}{#1}"),x("\\maroonE","\\textcolor{##9e034e}{#1}"),x("\\purpleA","\\textcolor{##ddd7ff}{#1}"),x("\\purpleB","\\textcolor{##c6b9fc}{#1}"),x("\\purpleC","\\textcolor{##aa87ff}{#1}"),x("\\purpleD","\\textcolor{##7854ab}{#1}"),x("\\purpleE","\\textcolor{##543b78}{#1}"),x("\\mintA","\\textcolor{##f5f9e8}{#1}"),x("\\mintB","\\textcolor{##edf2df}{#1}"),x("\\mintC","\\textcolor{##e0e5cc}{#1}"),x("\\grayA","\\textcolor{##f6f7f7}{#1}"),x("\\grayB","\\textcolor{##f0f1f2}{#1}"),x("\\grayC","\\textcolor{##e3e5e6}{#1}"),x("\\grayD","\\textcolor{##d6d8da}{#1}"),x("\\grayE","\\textcolor{##babec2}{#1}"),x("\\grayF","\\textcolor{##888d93}{#1}"),x("\\grayG","\\textcolor{##626569}{#1}"),x("\\grayH","\\textcolor{##3b3e40}{#1}"),x("\\grayI","\\textcolor{##21242c}{#1}"),x("\\kaBlue","\\textcolor{##314453}{#1}"),x("\\kaGreen","\\textcolor{##71B307}{#1}");var Ur={"^":!0,_:!0,"\\limits":!0,"\\nolimits":!0},Gr=function(){function t(t,e,i){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=e,this.expansionCount=0,this.feed(t),this.macros=new Rr(Nr,e.macros),this.mode=i,this.stack=[]}var e=t.prototype;return e.feed=function(t){this.lexer=new Br(t,this.settings)},e.switchMode=function(t){this.mode=t},e.beginGroup=function(){this.macros.beginGroup()},e.endGroup=function(){this.macros.endGroup()},e.endGroups=function(){this.macros.endGroups()},e.future=function(){return 0===this.stack.length&&this.pushToken(this.lexer.lex()),this.stack[this.stack.length-1]},e.popToken=function(){return this.future(),this.stack.pop()},e.pushToken=function(t){this.stack.push(t)},e.pushTokens=function(t){var e;(e=this.stack).push.apply(e,t)},e.scanArgument=function(t){var e,i,r;if(t){if(this.consumeSpaces(),"["!==this.future().text)return null;e=this.popToken();var n=this.consumeArg(["]"]);r=n.tokens,i=n.end}else{var a=this.consumeArg();r=a.tokens,e=a.start,i=a.end}return this.pushToken(new Yi("EOF",i.loc)),this.pushTokens(r),e.range(i,"")},e.consumeSpaces=function(){for(;" "===this.future().text;)this.stack.pop()},e.consumeArg=function(t){var e=[],i=t&&t.length>0;i||this.consumeSpaces();var r,n=this.future(),a=0,o=0;do{if(r=this.popToken(),e.push(r),"{"===r.text)++a;else if("}"===r.text){if(-1==--a)throw new z("Extra }",r)}else if("EOF"===r.text)throw new z("Unexpected end of input in a macro argument, expected '"+(t&&i?t[o]:"}")+"'",r);if(t&&i)if((0===a||1===a&&"{"===t[o])&&r.text===t[o]){if(++o===t.length){e.splice(-o,o);break}}else o=0}while(0!==a||i);return"{"===n.text&&"}"===e[e.length-1].text&&(e.pop(),e.shift()),e.reverse(),{tokens:e,start:n,end:r}},e.consumeArgs=function(t,e){if(e){if(e.length!==t+1)throw new z("The length of delimiters doesn't match the number of args!");for(var i=e[0],r=0;rthis.settings.maxExpand)throw new z("Too many expansions: infinite loop or need to increase maxExpand setting");var n=r.tokens,a=this.consumeArgs(r.numArgs,r.delimiters);if(r.numArgs)for(var o=(n=n.slice()).length-1;o>=0;--o){var s=n[o];if("#"===s.text){if(0===o)throw new z("Incomplete placeholder at end of macro body",s);if("#"===(s=n[--o]).text)n.splice(o+1,1);else{if(!/^[1-9]$/.test(s.text))throw new z("Not a valid argument number",s);var l;(l=n).splice.apply(l,[o,2].concat(a[+s.text-1]))}}}return this.pushTokens(n),n.length},e.expandAfterFuture=function(){return this.expandOnce(),this.future()},e.expandNextToken=function(){for(;;)if(!1===this.expandOnce()){var t=this.stack.pop();return t.treatAsRelax&&(t.text="\\relax"),t}throw new Error},e.expandMacro=function(t){return this.macros.has(t)?this.expandTokens([new Yi(t)]):void 0},e.expandTokens=function(t){var e=[],i=this.stack.length;for(this.pushTokens(t);this.stack.length>i;)if(!1===this.expandOnce(!0)){var r=this.stack.pop();r.treatAsRelax&&(r.noexpand=!1,r.treatAsRelax=!1),e.push(r)}return e},e.expandMacroAsText=function(t){var e=this.expandMacro(t);return e?e.map(function(t){return t.text}).join(""):e},e._getExpansion=function(t){var e=this.macros.get(t);if(null==e)return e;if(1===t.length){var i=this.lexer.catcodes[t];if(null!=i&&13!==i)return}var r="function"==typeof e?e(this):e;if("string"==typeof r){var n=0;if(-1!==r.indexOf("#"))for(var a=r.replace(/##/g,"");-1!==a.indexOf("#"+(n+1));)++n;for(var o=new Br(r,this.settings),s=[],l=o.lex();"EOF"!==l.text;)s.push(l),l=o.lex();return s.reverse(),{tokens:s,numArgs:n}}return r},e.isDefined=function(t){return this.macros.has(t)||Or.hasOwnProperty(t)||At.math.hasOwnProperty(t)||At.text.hasOwnProperty(t)||Ur.hasOwnProperty(t)},e.isExpandable=function(t){var e=this.macros.get(t);return null!=e?"string"==typeof e||"function"==typeof e||!e.unexpandable:Or.hasOwnProperty(t)&&!Or[t].primitive},t}(),Yr=/^[\u208a\u208b\u208c\u208d\u208e\u2080\u2081\u2082\u2083\u2084\u2085\u2086\u2087\u2088\u2089\u2090\u2091\u2095\u1d62\u2c7c\u2096\u2097\u2098\u2099\u2092\u209a\u1d63\u209b\u209c\u1d64\u1d65\u2093\u1d66\u1d67\u1d68\u1d69\u1d6a]/,$r=Object.freeze({"\u208a":"+","\u208b":"-","\u208c":"=","\u208d":"(","\u208e":")","\u2080":"0","\u2081":"1","\u2082":"2","\u2083":"3","\u2084":"4","\u2085":"5","\u2086":"6","\u2087":"7","\u2088":"8","\u2089":"9","\u2090":"a","\u2091":"e","\u2095":"h","\u1d62":"i","\u2c7c":"j","\u2096":"k","\u2097":"l","\u2098":"m","\u2099":"n","\u2092":"o","\u209a":"p","\u1d63":"r","\u209b":"s","\u209c":"t","\u1d64":"u","\u1d65":"v","\u2093":"x","\u1d66":"\u03b2","\u1d67":"\u03b3","\u1d68":"\u03c1","\u1d69":"\u03d5","\u1d6a":"\u03c7","\u207a":"+","\u207b":"-","\u207c":"=","\u207d":"(","\u207e":")","\u2070":"0","\xb9":"1","\xb2":"2","\xb3":"3","\u2074":"4","\u2075":"5","\u2076":"6","\u2077":"7","\u2078":"8","\u2079":"9","\u1d2c":"A","\u1d2e":"B","\u1d30":"D","\u1d31":"E","\u1d33":"G","\u1d34":"H","\u1d35":"I","\u1d36":"J","\u1d37":"K","\u1d38":"L","\u1d39":"M","\u1d3a":"N","\u1d3c":"O","\u1d3e":"P","\u1d3f":"R","\u1d40":"T","\u1d41":"U","\u2c7d":"V","\u1d42":"W","\u1d43":"a","\u1d47":"b","\u1d9c":"c","\u1d48":"d","\u1d49":"e","\u1da0":"f","\u1d4d":"g","\u02b0":"h","\u2071":"i","\u02b2":"j","\u1d4f":"k","\u02e1":"l","\u1d50":"m","\u207f":"n","\u1d52":"o","\u1d56":"p","\u02b3":"r","\u02e2":"s","\u1d57":"t","\u1d58":"u","\u1d5b":"v","\u02b7":"w","\u02e3":"x","\u02b8":"y","\u1dbb":"z","\u1d5d":"\u03b2","\u1d5e":"\u03b3","\u1d5f":"\u03b4","\u1d60":"\u03d5","\u1d61":"\u03c7","\u1dbf":"\u03b8"}),Xr={"\u0301":{text:"\\'",math:"\\acute"},"\u0300":{text:"\\`",math:"\\grave"},"\u0308":{text:'\\"',math:"\\ddot"},"\u0303":{text:"\\~",math:"\\tilde"},"\u0304":{text:"\\=",math:"\\bar"},"\u0306":{text:"\\u",math:"\\breve"},"\u030c":{text:"\\v",math:"\\check"},"\u0302":{text:"\\^",math:"\\hat"},"\u0307":{text:"\\.",math:"\\dot"},"\u030a":{text:"\\r",math:"\\mathring"},"\u030b":{text:"\\H"},"\u0327":{text:"\\c"}},Kr={"\xe1":"a\u0301","\xe0":"a\u0300","\xe4":"a\u0308","\u01df":"a\u0308\u0304","\xe3":"a\u0303","\u0101":"a\u0304","\u0103":"a\u0306","\u1eaf":"a\u0306\u0301","\u1eb1":"a\u0306\u0300","\u1eb5":"a\u0306\u0303","\u01ce":"a\u030c","\xe2":"a\u0302","\u1ea5":"a\u0302\u0301","\u1ea7":"a\u0302\u0300","\u1eab":"a\u0302\u0303","\u0227":"a\u0307","\u01e1":"a\u0307\u0304","\xe5":"a\u030a","\u01fb":"a\u030a\u0301","\u1e03":"b\u0307","\u0107":"c\u0301","\u1e09":"c\u0327\u0301","\u010d":"c\u030c","\u0109":"c\u0302","\u010b":"c\u0307","\xe7":"c\u0327","\u010f":"d\u030c","\u1e0b":"d\u0307","\u1e11":"d\u0327","\xe9":"e\u0301","\xe8":"e\u0300","\xeb":"e\u0308","\u1ebd":"e\u0303","\u0113":"e\u0304","\u1e17":"e\u0304\u0301","\u1e15":"e\u0304\u0300","\u0115":"e\u0306","\u1e1d":"e\u0327\u0306","\u011b":"e\u030c","\xea":"e\u0302","\u1ebf":"e\u0302\u0301","\u1ec1":"e\u0302\u0300","\u1ec5":"e\u0302\u0303","\u0117":"e\u0307","\u0229":"e\u0327","\u1e1f":"f\u0307","\u01f5":"g\u0301","\u1e21":"g\u0304","\u011f":"g\u0306","\u01e7":"g\u030c","\u011d":"g\u0302","\u0121":"g\u0307","\u0123":"g\u0327","\u1e27":"h\u0308","\u021f":"h\u030c","\u0125":"h\u0302","\u1e23":"h\u0307","\u1e29":"h\u0327","\xed":"i\u0301","\xec":"i\u0300","\xef":"i\u0308","\u1e2f":"i\u0308\u0301","\u0129":"i\u0303","\u012b":"i\u0304","\u012d":"i\u0306","\u01d0":"i\u030c","\xee":"i\u0302","\u01f0":"j\u030c","\u0135":"j\u0302","\u1e31":"k\u0301","\u01e9":"k\u030c","\u0137":"k\u0327","\u013a":"l\u0301","\u013e":"l\u030c","\u013c":"l\u0327","\u1e3f":"m\u0301","\u1e41":"m\u0307","\u0144":"n\u0301","\u01f9":"n\u0300","\xf1":"n\u0303","\u0148":"n\u030c","\u1e45":"n\u0307","\u0146":"n\u0327","\xf3":"o\u0301","\xf2":"o\u0300","\xf6":"o\u0308","\u022b":"o\u0308\u0304","\xf5":"o\u0303","\u1e4d":"o\u0303\u0301","\u1e4f":"o\u0303\u0308","\u022d":"o\u0303\u0304","\u014d":"o\u0304","\u1e53":"o\u0304\u0301","\u1e51":"o\u0304\u0300","\u014f":"o\u0306","\u01d2":"o\u030c","\xf4":"o\u0302","\u1ed1":"o\u0302\u0301","\u1ed3":"o\u0302\u0300","\u1ed7":"o\u0302\u0303","\u022f":"o\u0307","\u0231":"o\u0307\u0304", "\u0151":"o\u030b","\u1e55":"p\u0301","\u1e57":"p\u0307","\u0155":"r\u0301","\u0159":"r\u030c","\u1e59":"r\u0307","\u0157":"r\u0327","\u015b":"s\u0301","\u1e65":"s\u0301\u0307","\u0161":"s\u030c","\u1e67":"s\u030c\u0307","\u015d":"s\u0302","\u1e61":"s\u0307","\u015f":"s\u0327","\u1e97":"t\u0308","\u0165":"t\u030c","\u1e6b":"t\u0307","\u0163":"t\u0327","\xfa":"u\u0301","\xf9":"u\u0300","\xfc":"u\u0308","\u01d8":"u\u0308\u0301","\u01dc":"u\u0308\u0300","\u01d6":"u\u0308\u0304","\u01da":"u\u0308\u030c","\u0169":"u\u0303","\u1e79":"u\u0303\u0301","\u016b":"u\u0304","\u1e7b":"u\u0304\u0308","\u016d":"u\u0306","\u01d4":"u\u030c","\xfb":"u\u0302","\u016f":"u\u030a","\u0171":"u\u030b","\u1e7d":"v\u0303","\u1e83":"w\u0301","\u1e81":"w\u0300","\u1e85":"w\u0308","\u0175":"w\u0302","\u1e87":"w\u0307","\u1e98":"w\u030a","\u1e8d":"x\u0308","\u1e8b":"x\u0307","\xfd":"y\u0301","\u1ef3":"y\u0300","\xff":"y\u0308","\u1ef9":"y\u0303","\u0233":"y\u0304","\u0177":"y\u0302","\u1e8f":"y\u0307","\u1e99":"y\u030a","\u017a":"z\u0301","\u017e":"z\u030c","\u1e91":"z\u0302","\u017c":"z\u0307","\xc1":"A\u0301","\xc0":"A\u0300","\xc4":"A\u0308","\u01de":"A\u0308\u0304","\xc3":"A\u0303","\u0100":"A\u0304","\u0102":"A\u0306","\u1eae":"A\u0306\u0301","\u1eb0":"A\u0306\u0300","\u1eb4":"A\u0306\u0303","\u01cd":"A\u030c","\xc2":"A\u0302","\u1ea4":"A\u0302\u0301","\u1ea6":"A\u0302\u0300","\u1eaa":"A\u0302\u0303","\u0226":"A\u0307","\u01e0":"A\u0307\u0304","\xc5":"A\u030a","\u01fa":"A\u030a\u0301","\u1e02":"B\u0307","\u0106":"C\u0301","\u1e08":"C\u0327\u0301","\u010c":"C\u030c","\u0108":"C\u0302","\u010a":"C\u0307","\xc7":"C\u0327","\u010e":"D\u030c","\u1e0a":"D\u0307","\u1e10":"D\u0327","\xc9":"E\u0301","\xc8":"E\u0300","\xcb":"E\u0308","\u1ebc":"E\u0303","\u0112":"E\u0304","\u1e16":"E\u0304\u0301","\u1e14":"E\u0304\u0300","\u0114":"E\u0306","\u1e1c":"E\u0327\u0306","\u011a":"E\u030c","\xca":"E\u0302","\u1ebe":"E\u0302\u0301","\u1ec0":"E\u0302\u0300","\u1ec4":"E\u0302\u0303","\u0116":"E\u0307","\u0228":"E\u0327","\u1e1e":"F\u0307","\u01f4":"G\u0301","\u1e20":"G\u0304","\u011e":"G\u0306","\u01e6":"G\u030c","\u011c":"G\u0302","\u0120":"G\u0307","\u0122":"G\u0327","\u1e26":"H\u0308","\u021e":"H\u030c","\u0124":"H\u0302","\u1e22":"H\u0307","\u1e28":"H\u0327","\xcd":"I\u0301","\xcc":"I\u0300","\xcf":"I\u0308","\u1e2e":"I\u0308\u0301","\u0128":"I\u0303","\u012a":"I\u0304","\u012c":"I\u0306","\u01cf":"I\u030c","\xce":"I\u0302","\u0130":"I\u0307","\u0134":"J\u0302","\u1e30":"K\u0301","\u01e8":"K\u030c","\u0136":"K\u0327","\u0139":"L\u0301","\u013d":"L\u030c","\u013b":"L\u0327","\u1e3e":"M\u0301","\u1e40":"M\u0307","\u0143":"N\u0301","\u01f8":"N\u0300","\xd1":"N\u0303","\u0147":"N\u030c","\u1e44":"N\u0307","\u0145":"N\u0327","\xd3":"O\u0301","\xd2":"O\u0300","\xd6":"O\u0308","\u022a":"O\u0308\u0304","\xd5":"O\u0303","\u1e4c":"O\u0303\u0301","\u1e4e":"O\u0303\u0308","\u022c":"O\u0303\u0304","\u014c":"O\u0304","\u1e52":"O\u0304\u0301","\u1e50":"O\u0304\u0300","\u014e":"O\u0306","\u01d1":"O\u030c","\xd4":"O\u0302","\u1ed0":"O\u0302\u0301","\u1ed2":"O\u0302\u0300","\u1ed6":"O\u0302\u0303","\u022e":"O\u0307","\u0230":"O\u0307\u0304","\u0150":"O\u030b","\u1e54":"P\u0301","\u1e56":"P\u0307","\u0154":"R\u0301","\u0158":"R\u030c","\u1e58":"R\u0307","\u0156":"R\u0327","\u015a":"S\u0301","\u1e64":"S\u0301\u0307","\u0160":"S\u030c","\u1e66":"S\u030c\u0307","\u015c":"S\u0302","\u1e60":"S\u0307","\u015e":"S\u0327","\u0164":"T\u030c","\u1e6a":"T\u0307","\u0162":"T\u0327","\xda":"U\u0301","\xd9":"U\u0300","\xdc":"U\u0308","\u01d7":"U\u0308\u0301","\u01db":"U\u0308\u0300","\u01d5":"U\u0308\u0304","\u01d9":"U\u0308\u030c","\u0168":"U\u0303","\u1e78":"U\u0303\u0301","\u016a":"U\u0304","\u1e7a":"U\u0304\u0308","\u016c":"U\u0306","\u01d3":"U\u030c","\xdb":"U\u0302","\u016e":"U\u030a","\u0170":"U\u030b","\u1e7c":"V\u0303","\u1e82":"W\u0301","\u1e80":"W\u0300","\u1e84":"W\u0308","\u0174":"W\u0302","\u1e86":"W\u0307","\u1e8c":"X\u0308","\u1e8a":"X\u0307","\xdd":"Y\u0301","\u1ef2":"Y\u0300","\u0178":"Y\u0308","\u1ef8":"Y\u0303","\u0232":"Y\u0304","\u0176":"Y\u0302","\u1e8e":"Y\u0307","\u0179":"Z\u0301","\u017d":"Z\u030c","\u1e90":"Z\u0302","\u017b":"Z\u0307","\u03ac":"\u03b1\u0301","\u1f70":"\u03b1\u0300","\u1fb1":"\u03b1\u0304","\u1fb0":"\u03b1\u0306","\u03ad":"\u03b5\u0301","\u1f72":"\u03b5\u0300","\u03ae":"\u03b7\u0301","\u1f74":"\u03b7\u0300","\u03af":"\u03b9\u0301","\u1f76":"\u03b9\u0300","\u03ca":"\u03b9\u0308","\u0390":"\u03b9\u0308\u0301","\u1fd2":"\u03b9\u0308\u0300","\u1fd1":"\u03b9\u0304","\u1fd0":"\u03b9\u0306","\u03cc":"\u03bf\u0301","\u1f78":"\u03bf\u0300","\u03cd":"\u03c5\u0301","\u1f7a":"\u03c5\u0300","\u03cb":"\u03c5\u0308","\u03b0":"\u03c5\u0308\u0301","\u1fe2":"\u03c5\u0308\u0300","\u1fe1":"\u03c5\u0304","\u1fe0":"\u03c5\u0306","\u03ce":"\u03c9\u0301","\u1f7c":"\u03c9\u0300","\u038e":"\u03a5\u0301","\u1fea":"\u03a5\u0300","\u03ab":"\u03a5\u0308","\u1fe9":"\u03a5\u0304","\u1fe8":"\u03a5\u0306","\u038f":"\u03a9\u0301","\u1ffa":"\u03a9\u0300"},Zr=function(){function t(t,e){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 Gr(t,e,this.mode),this.settings=e,this.leftrightDepth=0}var i=t.prototype;return i.expect=function(t,e){if(void 0===e&&(e=!0),this.fetch().text!==t)throw new z("Expected '"+t+"', got '"+this.fetch().text+"'",this.fetch());e&&this.consume()},i.consume=function(){this.nextToken=null},i.fetch=function(){return null==this.nextToken&&(this.nextToken=this.gullet.expandNextToken()),this.nextToken},i.switchMode=function(t){this.mode=t,this.gullet.switchMode(t)},i.parse=function(){this.settings.globalGroup||this.gullet.beginGroup(),this.settings.colorIsTextColor&&this.gullet.macros.set("\\color","\\textcolor");try{var t=this.parseExpression(!1);return this.expect("EOF"),this.settings.globalGroup||this.gullet.endGroup(),t}finally{this.gullet.endGroups()}},i.subparse=function(t){var e=this.nextToken;this.consume(),this.gullet.pushToken(new Yi("}")),this.gullet.pushTokens(t);var i=this.parseExpression(!1);return this.expect("}"),this.nextToken=e,i},i.parseExpression=function(e,i){for(var r=[];;){"math"===this.mode&&this.consumeSpaces();var n=this.fetch();if(-1!==t.endOfExpression.indexOf(n.text))break;if(i&&n.text===i)break;if(e&&Or[n.text]&&Or[n.text].infix)break;var a=this.parseAtom(i);if(!a)break;"internal"!==a.type&&r.push(a)}return"text"===this.mode&&this.formLigatures(r),this.handleInfixNodes(r)},i.handleInfixNodes=function(t){for(var e,i=-1,r=0;r=0&&this.settings.reportNonstrict("unicodeTextInMathMode",'Latin-1/Unicode text character "'+i[0]+'" used in math mode',t);var s,l=At[this.mode][i].group,h=Gi.range(t);if(_t.hasOwnProperty(l)){var c=l;s={type:"atom",mode:this.mode,family:c,loc:h,text:i}}else s={type:l,mode:this.mode,loc:h,text:i};a=s}else{if(!(i.charCodeAt(0)>=128))return null;this.settings.strict&&(e(i.charCodeAt(0))?"math"===this.mode&&this.settings.reportNonstrict("unicodeTextInMathMode",'Unicode text character "'+i[0]+'" used in math mode',t):this.settings.reportNonstrict("unknownSymbol",'Unrecognized Unicode character "'+i[0]+'" ('+i.charCodeAt(0)+")",t)),a={type:"textord",mode:"text",loc:Gi.range(t),text:i}}if(this.consume(),o)for(var d=0;d0&&(n.push({type:"text",data:t.slice(0,i)}),t=t.slice(i));var s=e.findIndex(function(e){return t.startsWith(e.left)});if(-1===(i=r(e[s].right,t,e[s].left.length)))break;var l=t.slice(0,i+e[s].right.length),h=a.test(l)?l:t.slice(e[s].left.length,i);n.push({type:"math",data:h,rawData:l,display:e[s].display}),t=t.slice(i+e[s].right.length)}return""!==t&&n.push({type:"text",data:t}),n},s=function(t,e){var r=o(t,e.delimiters);if(1===r.length&&"text"===r[0].type)return null;for(var n=document.createDocumentFragment(),a=0;ar.c||536==r.c&&11>r.g))}function w(t,e,i){return(t=t.match(e))&&t[i]?t[i]:""}function k(t){this.la=t||"-"}function _(t,e){this.M=t,this.Y=4,this.N="n";var i=(e||"n4").match(/^([nio])([1-9])$/i);i&&(this.N=i[1],this.Y=parseInt(i[2],10))}function S(t){return t.N+t.Y}function M(t){var e=4,i="n",r=null;return t&&((r=t.match(/(normal|oblique|italic)/i))&&r[1]&&(i=r[1].substr(0,1).toLowerCase()),(r=t.match(/([1-9]00|normal|bold)/i))&&r[1]&&(/bold/i.test(r[1])?e=7:/[1-9]00/.test(r[1])&&(e=parseInt(r[1].substr(0,1),10)))),i+e}function A(t,e){this.d=t,this.p=t.t.document.documentElement,this.P=e,this.j="wf",this.h=new k("-"),this.ga=!1!==e.events,this.B=!1!==e.classes}function T(t){if(t.B){var e=h(t.p,t.h.e(t.j,"active")),i=[],r=[t.h.e(t.j,"loading")];e||i.push(t.h.e(t.j,"inactive")),l(t.p,i,r)}C(t,"inactive")}function C(t,e,i){t.ga&&t.P[e]&&(i?t.P[e](i.getName(),S(i)):t.P[e]())}function z(){this.w={}}function O(t,e){this.d=t,this.G=e,this.m=this.d.createElement("span",{"aria-hidden":"true"},this.G)}function L(t){o(t.d,"body",t.m)}function P(t){var e;e=[];for(var i=t.M.split(/,\s*/),r=0;r=t.W?t.k.fa&&I(t,e,i)&&(null===t.ba||t.ba.hasOwnProperty(t.s.getName()))?R(t,t.Z):R(t,t.ja):B(t):R(t,t.Z)}function B(t){setTimeout(n(function(){D(this)},t),25)}function R(t,e){t.D.remove(),t.F.remove(),e(t.s)}function N(t,e,i,r){this.d=e,this.u=i,this.R=0,this.da=this.aa=!1,this.W=r,this.k=t.k}function F(t,e,i,r,a){if(i=i||{},0===e.length&&a)T(t.u);else for(t.R+=e.length,a&&(t.aa=a),a=0;at.c||this.c===t.c&&this.g>t.g||this.c===t.c&&this.g===t.g&&this.A>t.A?1:this.c{var i,r=_createForOfIteratorHelper(t);try{for(r.s();!(i=r.n()).done;){var n=i.value;if(""===n)break;e=e&&e[n]}}catch(e){r.e(e)}finally{r.f()}return e}}()))(t)}function b(t){return t.charAt(0).toUpperCase()+t.slice(1)}function y(t){return"mouseup"===t.type||"click"===t.type||"contextmenu"===t.type}function x(t,e,i){return Math.abs(t-e)t-e).pop(),i}function _(t){return!("symbol"==typeof(e=t)||"object"==typeof e&&null!==e&&!(Symbol.toPrimitive in e||"toString"in e||"valueOf"in e)||isNaN(parseFloat(t)))&&isFinite(t);var e}function S(t,e){var i=Math.round(t);return i-e<=t&&t<=i+e}function M(t,e,i){let r,n,a;for(r=0,n=t.length;r=Math.min(e,i)-r&&t<=Math.max(e,i)+r}function R(t,e,i){i=i||(i=>t[i]>1)?a=r:n=r;return{lo:a,hi:n}}function N(t,e,i){let r=0,n=t.length;for(;rr&&t[n-1]>i;)n--;return 0{const i="_onData"+b(e),r=t[e];Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value(...e){var n=r.apply(this,e);return t._chartjs.listeners.forEach(t=>{"function"==typeof t[i]&&t[i](...e)}),n}})}))}function H(t,e){var i=t._chartjs;i&&(-1!==(e=(i=i.listeners).indexOf(e))&&i.splice(e,1),0{delete t[e]}),delete t._chartjs))}function V(t){var e=new Set(t);return e.size===t.length?t:Array.from(e)}function q(t,e){let i,r=!1;return function(...n){i=n,r||(r=!0,Nr.call(window,()=>{r=!1,t.apply(e,i)}))}}function j(t,e){let i;return function(...r){return e?(clearTimeout(i),i=setTimeout(t,e,r)):t.apply(this,r),e}}function W(t,i,r){let n=i.length,a=0,o=n;if(t._sorted){let s=t.iScale,l=t.vScale,h=t._parsed,c=t.dataset&&t.dataset.options?t.dataset.options.spanGaps:null,d=s.axis,u=s.getUserBounds(),p=u.min,m=u.max,f=u.minDefined,g=u.maxDefined;if(f){if(a=Math.min(Dr(h,d,p).lo,r?n:Dr(i,d,s.getPixelForValue(p)).lo),c){const t=h.slice(0,a+1).reverse().findIndex(t=>!e(t[l.axis]));a-=Math.max(0,t)}a=I(a,0,n-1)}if(g){let t=Math.max(Dr(h,s.axis,m,!0).hi+1,r?0:Dr(i,d,s.getPixelForValue(m),!0).hi+1);if(c){const i=h.slice(t-1).findIndex(t=>!e(t[l.axis]));t+=Math.max(0,i)}o=I(t,a,n)-a}else o=n-a}return{start:a,count:o}}function U(t){var e=t.xScale,i=t.yScale,r=t._scaleRanges,n={xmin:e.min,xmax:e.max,ymin:i.min,ymax:i.max};return r?(e=r.xmin!==e.min||r.xmax!==e.max||r.ymin!==i.min||r.ymax!==i.max,Object.assign(r,n),e):(t._scaleRanges=n,!0)} /*! * @kurkle/color v0.3.2 * https://github.com/kurkle/color#readme * (c) 2023 Jukka Kurkela * Released under the MIT License */ function G(t){return t+.5|0}function Y(t){return jr(G(2.55*t),0,255)}function $(t){return jr(G(255*t),0,255)}function X(t){return jr(G(t/2.55)/100,0,1)}function K(t){return jr(G(100*t),0,100)}function Z(t,e,i){const r=e*Math.min(i,1-i),n=(e,n=(e+t/30)%12)=>i-r*Math.max(Math.min(n-3,9-n,1),-1);return[n(0),n(8),n(4)]}function J(t,e,i){var r=(r,n=(r+t/60)%6)=>i-i*e*Math.max(Math.min(n,4-n,1),0);return[r(5),r(3),r(1)]}function Q(t,e,i){let r,n=Z(t,1,.5);for(1t.height&&(c=t.height,h=mn(Math.floor(c*r))),{width:h,height:c}}function xt(t,e,i){e=e||1;var r=mn(t.height*e),n=mn(t.width*e),a=(t.height=mn(t.height),t.width=mn(t.width),t.canvas);return a.style&&(i||!a.style.height&&!a.style.width)&&(a.style.height=t.height+"px",a.style.width=t.width+"px"),(t.currentDevicePixelRatio!==e||a.height!==r||a.width!==n)&&(t.currentDevicePixelRatio=e,a.height=r,a.width=n,t.ctx.setTransform(e,0,0,e,0,0),!0)}function wt(t,e){return(e=(t=gt(t,e))&&t.match(/^(\d+)(\.\d+)?px$/))?+e[1]:void 0}function kt(t){return!t||e(t.size)||e(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}function _t(t,e,i,r,n){let a=e[n];return a||(a=e[n]=t.measureText(n).width,i.push(n)),a>r?a:r}function St(t,e,r,n){let a,o,s,l,h,c=(n=n||{}).data=n.data||{},d=n.garbageCollect=n.garbageCollect||[],u=(n.font!==e&&(c=n.data={},d=n.garbageCollect=[],n.font=e),t.save(),t.font=e,0),p=r.length;for(a=0;ar.length){for(a=0;ae.left-i&&t.xe.top-i&&t.yt[0])){const a=i||t;return void 0===r&&(r=jt("_fallback",t)),i={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:t,_rootScopes:a,_fallback:r,_getTarget:n,override:i=>Bt([i,...t],e,a,r)},new Proxy(i,{deleteProperty:(e,i)=>(delete e[i],delete e._keys,delete t[0][i],!0),get:(i,r)=>Ft(i,r,()=>{var n,a=r,o=t,s=i,l=_createForOfIteratorHelper(e);try{for(l.s();!(n=l.n()).done;){var h,c=n.value;if(void 0!==(h=jt(gn(c,a),o)))return vn(a,h)?Vt(o,s,a,h):h}}catch(n){l.e(n)}finally{l.f()}}),getOwnPropertyDescriptor:(t,e)=>Reflect.getOwnPropertyDescriptor(t._scopes[0],e),getPrototypeOf:()=>Reflect.getPrototypeOf(t[0]),has:(t,e)=>Wt(t).includes(e),ownKeys:t=>Wt(t),set(t,e,i){var r=t._storage||(t._storage=n());return t[e]=r[e]=i,delete t._keys,!0}})}function Rt(t,e,n,a){var o={_cacheable:!1,_proxy:t,_context:e,_subProxy:n,_stack:new Set,_descriptors:Nt(t,a),setContext:e=>Rt(t,e,n,a),override:i=>Rt(t.override(i),e,n,a)};return new Proxy(o,{deleteProperty:(e,i)=>(delete e[i],delete t[i],!0),get:(t,e,n)=>Ft(t,e,()=>{{var a=t,o=e,s=n,l=a._proxy,h=a._context,c=a._subProxy,d=a._descriptors;let u=l[o];return i(u=_r(u)&&d.isScriptable(o)?function(t,e,i){var r=a._proxy,n=a._context,o=a._subProxy,s=a._stack;if(s.has(t))throw new Error("Recursion detected: "+Array.from(s).join("->")+"->"+t);return s.add(t),e=e(n,o||i),s["delete"](t),vn(t,e)?Vt(r._scopes,r,t,e):e}(o,u,s):u)&&u.length&&(u=function(t,e,i,n){var a=i._proxy,o=i._context,s=i._subProxy,l=i._descriptors;if(void 0!==o.index&&n(t))return e[o.index%e.length];if(r(e[0])){const i=e,r=a._scopes.filter(t=>t!==i);e=[];var h,c=_createForOfIteratorHelper(i);try{for(c.s();!(h=c.n()).done;){const i=Vt(r,a,t,h.value);e.push(Rt(i,o,s&&s[t],l))}}catch(t){c.e(t)}finally{c.f()}}return e}(o,u,a,d.isIndexable)),u=vn(o,u)?Rt(u,h,c&&c[o],d):u}}),getOwnPropertyDescriptor:(e,i)=>e._descriptors.allKeys?Reflect.has(t,i)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(t,i),getPrototypeOf:()=>Reflect.getPrototypeOf(t),has:(e,i)=>Reflect.has(t,i),ownKeys:()=>Reflect.ownKeys(t),set:(e,i,r)=>(t[i]=r,delete e[i],!0)})}function Nt(t,e={scriptable:!0,indexable:!0}){let i=t._scriptable,r=void 0===i?e.scriptable:i,n=t._indexable,a=void 0===n?e.indexable:n,o=t._allKeys;return{allKeys:void 0===o?e.allKeys:o,scriptable:r,indexable:a,isScriptable:_r(r)?r:()=>r,isIndexable:_r(a)?a:()=>a}}function Ft(t,e,i){return Object.prototype.hasOwnProperty.call(t,e)||"constructor"===e?t[e]:(i=i(),t[e]=i)}function Ht(t,e,i){return _r(t)?t(e,i):t}function Vt(t,e,n,a){var o=e._rootScopes,s=Ht(e._fallback,n,a),l=(t=[...t,...o],new Set),h=(l.add(a),qt(l,t,n,s||n,a));return null!==h&&(void 0===s||s===n||null!==qt(l,t,s,h,a))&&Bt(Array.from(l),[""],o,s,()=>{return o=a,(t=n)in(s=e._getTarget())||(s[t]={}),i(s=s[t])&&r(o)?o:s||{};var t,o,s})}function qt(t,e,i,r,n){for(;i;)i=function(t,e,i,r,n){var a,o=_createForOfIteratorHelper(e);try{for(o.s();!(a=o.n()).done;){var s=a.value;const e=bn(i,s);if(e){t.add(e);var l=Ht(e._fallback,i,n);if(void 0!==l&&l!==i&&l!==r)return l}else if(!1===e&&void 0!==r&&i!==r)return null}}catch(t){o.e(t)}finally{o.f()}return!1}(t,e,i,r,n);return i}function jt(t,e){var i,r=_createForOfIteratorHelper(e);try{for(r.s();!(i=r.n()).done;){var n=i.value;if(n){const e=n[t];if(void 0!==e)return e}}}catch(t){r.e(t)}finally{r.f()}}function Wt(t){return t._keys||(t._keys=function(t){var e,i=new Set,r=_createForOfIteratorHelper(t);try{for(r.s();!(e=r.n()).done;){var n,a=e.value,o=_createForOfIteratorHelper(Object.keys(a).filter(t=>!t.startsWith("_")));try{for(o.s();!(n=o.n()).done;){const t=n.value;i.add(t)}}catch(t){o.e(t)}finally{o.f()}}}catch(t){r.e(t)}finally{r.f()}return Array.from(i)}(t._scopes))}function Ut(t,e,i,r){let n,a,o,s,l=t.iScale,h=this._parsing.key,c=void 0===h?"r":h,d=new Array(r);for(n=0,a=r;n!t.skip)),"monotone"===e.cubicInterpolationMode)Yt(t,n);else{let i=r?t[t.length-1]:t[0];for(a=0,o=t.length;ao(t[i],t[e[i]]):e=>t[e]:()=>t,h=_createForOfIteratorHelper(s);try{for(h.s();!(i=h.n()).done;){const t=i.value;n[t]=Cn(l(t))}}catch(i){h.e(i)}finally{h.f()}return n}function ee(t){return te(t,{top:"y",right:"x",bottom:"y",left:"x"})}function ie(t){return te(t,["topLeft","topRight","bottomLeft","bottomRight"])}function re(t){return(t=ee(t)).width=t.left+t.right,t.height=t.top+t.bottom,t}function ne(t,e){e=e||dn.font;let i=o((t=t||{}).size,e.size),r=("string"==typeof i&&(i=parseInt(i,10)),o(t.style,e.style));return r&&!(""+r).match(Tn)&&(console.warn('Invalid font style specified: "'+r+'"'),r=void 0),(t={family:o(t.family,e.family),lineHeight:Qt(o(t.lineHeight,e.lineHeight),i),size:i,style:r,weight:o(t.weight,e.weight),string:""}).string=kt(t),t}function ae(t,e,r,n){let a,o,s,l=!0;for(a=0,o=t.length;ai&&0===t?0:t+e);return{min:n(t,-Math.abs(e)),max:n(r,e)}}function se(t,e){return Object.assign(Object.create(t),e)}function le(t,e,i){return t?(r=e,n=i,{x:t=>r+r+n-t,setWidth(t){n=t},textAlign:t=>"center"===t?t:"right"===t?"left":"right",xPlus:(t,e)=>t-e,leftForLtr:(t,e)=>t-e}):{x:t=>t,setWidth(t){},textAlign:t=>t,xPlus:(t,e)=>t+e,leftForLtr:t=>t};var r,n}function he(t,e){var i,r;"ltr"!==e&&"rtl"!==e||(r=[(i=t.canvas.style).getPropertyValue("direction"),i.getPropertyPriority("direction")],i.setProperty("direction",e,"important"),t.prevTextDirection=r)}function ce(t,e){void 0!==e&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]))}function de(t){return"angle"===t?{between:E,compare:L,normalize:P}:{between:B,compare:(t,e)=>t-e,normalize:t=>t}}function ue({start:t,end:e,count:i,loop:r,style:n}){return{start:t%i,end:e%i,loop:r&&(e-t+1)%i==0,style:n}}function pe(t,e,i){if(!i)return[t];let r,n,a,o,s=i.property,l=i.start,h=i.end,c=e.length,d=de(s),u=d.compare,p=d.between,m=d.normalize,f=function(t,e){let r,n,a=i.property,o=i.start,s=i.end,l=de(a),h=l.between,c=l.normalize,d=e.length,u=t.start,p=t.end,m=t.loop;if(m){for(u+=d,p+=d,r=0,n=d;rn&&t[a%e].skip;)a--;return{start:n,end:a%=e}}(i,n,l=!!t._loop)).start,o=o.end,s=t,l=!0===r?[{start:a,end:o,loop:l}]:function(t,e,i,r){let n,a=t.length,o=[],s=e,l=t[e];for(n=e+1;n<=i;++n){const i=t[n%a];i.skip||i.stop?l.skip||(r=!1,o.push({start:e%a,end:(n-1)%a,loop:r}),e=s=i.stop?n:null):(s=n,l.skip&&(e=n)),l=i}return null!==s&&o.push({start:e%a,end:s%a,loop:r}),o}(i,a,o!e(t[i.axis]));n.lo-=Math.max(0,o);const s=r.slice(n.hi).findIndex(t=>!e(t[i.axis]));n.hi+=Math.max(0,s)}return n}if(a._sharedOptions){const t=o[0],e="function"==typeof t.getRange&&t.getRange(i);if(e){const t=s(o,i,r-e),n=s(o,i,r+e);return{lo:t.lo,hi:n.hi}}}}return{lo:0,hi:o.length-1}}(o[t],i,s,a)).lo,u=l.hi;for(let t=d;t<=u;++t){const e=c[t];e.skip||n(e,h,t)}}}function xe(t,e,i,r,n){const a=[];return(n||t.isPointInArea(e))&&ye(t,i,e,function(i,o,s){(n||zt(i,t.chartArea,0))&&i.inRange(e.x,e.y,r)&&a.push({element:i,datasetIndex:o,index:s})},!0),a}function we(t,e,i,r,n,a){if(a||t.isPointInArea(e)){if("r"!==i||r){var o=t,s=e,l=i,h=r,c=n,d=a;let u=[];const p=function(t){const e=-1!==t.indexOf("x"),i=-1!==t.indexOf("y");return function(t,r){var n=e?Math.abs(t.x-r.x):0;t=i?Math.abs(t.y-r.y):0;return Math.sqrt(Math.pow(n,2)+Math.pow(t,2))}}(l);let m=Number.POSITIVE_INFINITY;return ye(o,l,s,function(t,e,i){var r,n=t.inRange(s.x,s.y,c);(!h||n)&&(r=t.getCenterPoint(c),d||o.isPointInArea(r)||n)&&((n=p(s,r)){t[o]&&t[o](e[i],n)&&(a.push({element:t,datasetIndex:r,index:l}),s=s||t.inRange(e.x,e.y,n))}),r&&!s?[]:a}function _e(t,e){return t.filter(t=>t.pos===e)}function Se(t,e){return t.filter(t=>-1===Ln.indexOf(t.pos)&&t.box.axis===e)}function Me(t,e){return t.sort((t,i)=>{var r=e?i:t;t=e?t:i;return r.weight===t.weight?r.index-t.index:r.weight-t.weight})}function Ae(t,e,i,r){return Math.max(t[i],e[i])+Math.max(t[r],e[r])}function Te(t,e){t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.max(t.bottom,e.bottom),t.right=Math.max(t.right,e.right)}function Ce(t,e,i,n){let a,o,s,l,h,c,d=[];for(a=0,o=t.length,h=0;a{r[t]=Math.max(e[t],i[t])}),r}}(s.horizontal,e));var u=function(t,e,i,n){var a=i.pos,o=i.box,s=t.maxPadding;if(!r(a)){i.size&&(t[a]-=i.size);const e=n[i.stack]||{size:0,count:1};e.size=Math.max(e.size,i.horizontal?o.height:o.width),i.size=e.size/e.count,t[a]+=i.size}return o.getPadding&&Te(s,o.getPadding()),n=Math.max(0,e.outerWidth-Ae(s,t,"left","right")),a=Math.max(0,e.outerHeight-Ae(s,t,"top","bottom")),o=n!==t.w,e=a!==t.h,t.w=n,t.h=a,i.horizontal?{same:o,other:e}:{same:e,other:o}}(e,i,s,n);h|=u.same&&d.length,c=c||u.other,l.fullSize||d.push(s)}return h&&Ce(d,e,i,n)||c}function ze(t,e,i,r,n){t.top=i,t.left=e,t.right=e+r,t.bottom=i+n,t.width=r,t.height=n}function Oe(t,e,i,r){let n,a=i.padding,o=e.x,s=e.y,l=_createForOfIteratorHelper(t);try{for(l.s();!(n=l.n()).done;){var h=n.value;const t=h.box,l=r[h.stack]||{count:1,placed:0,weight:1},c=h.stackWeight/l.weight||1;if(h.horizontal){const r=e.w*c,n=l.size||t.height;kr(l.start)&&(s=l.start),t.fullSize?ze(t,a.left,s,i.outerWidth-a.right-a.left,n):ze(t,e.left+l.placed,s,r,n),l.start=s,l.placed+=r,s=t.bottom}else{const r=e.h*c,n=l.size||t.width;kr(l.start)&&(o=l.start),t.fullSize?ze(t,o,a.top,n,i.outerHeight-a.bottom-a.top):ze(t,o,e.top+l.placed,n,r),l.start=o,l.placed+=r,o=t.right}}}catch(t){l.e(t)}finally{l.f()}e.x=o,e.y=s}function Le(t,e){var i,r=_createForOfIteratorHelper(t);try{for(r.s();!(i=r.n()).done;){var n=i.value;if(n===e||n.contains(e))return!0}}catch(t){r.e(t)}finally{r.f()}}function Pe(t,e,i){const r=t.canvas,n=new MutationObserver(t=>{let e,n=!1,a=_createForOfIteratorHelper(t);try{for(a.s();!(e=a.n()).done;){const t=e.value;n=(n=n||Le(t.addedNodes,r))&&!Le(t.removedNodes,r)}}catch(t){a.e(t)}finally{a.f()}n&&i()});return n.observe(document,{childList:!0,subtree:!0}),n}function Ee(t,e,i){const r=t.canvas,n=new MutationObserver(t=>{let e,n=!1,a=_createForOfIteratorHelper(t);try{for(a.s();!(e=a.n()).done;){const t=e.value;n=(n=n||Le(t.removedNodes,r))&&!Le(t.addedNodes,r)}}catch(t){a.e(t)}finally{a.f()}n&&i()});return n.observe(document,{childList:!0,subtree:!0}),n}function Ie(){const t=window.devicePixelRatio;t!==Hn&&(Hn=t,Fn.forEach((e,i)=>{i.currentDevicePixelRatio!==t&&e()}))}function De(t,e,i){const r=t.canvas,n=r&&mt(r);if(n){const e=q((t,e)=>{var r=n.clientWidth;i(t,e),r{var i=(t=t[0]).contentRect.width;t=t.contentRect.height;0===i&&0===t||e(i,t)});return r.observe(n),a=e,Fn.size||window.addEventListener("resize",Ie),Fn.set(t,a),r;var a}}function Be(t,e,i){i&&i.disconnect(),"resize"===e&&(i=t,Fn["delete"](i),Fn.size||window.removeEventListener("resize",Ie))}function Re(t,e,i){var r=t.canvas,n=q(e=>{var r,n,a;null!==t.ctx&&i((r=t,{type:Bn[(e=e).type]||e.type,chart:r,native:e,x:void 0!==(a=(n=bt(e,r)).x)?a:null,y:void 0!==(n=n.y)?n:null}))},t);return r&&r.addEventListener(e,n,Nn),n}function Ne(t){return!pt()||"undefined"!=typeof OffscreenCanvas&&t instanceof OffscreenCanvas?In:Vn}function Fe(t,e){var i=(t=t&&t.options||{}).reverse,r=void 0===t.min?e:0;t=void 0===t.max?e:0;return{start:i?t:r,end:i?r:t}}function He(t,e){let i,r,n=[],a=t._getSortedDatasetMetas(e);for(i=0,r=a.length;ii[t].axis===e).shift()}function Ge(t,e){var i=t.controller.index,r=t.vScale&&t.vScale.axis;if(r){var n,a=_createForOfIteratorHelper(e=e||t._parsed);try{for(a.s();!(n=a.n()).done;){const t=n.value._stacks;if(!t||void 0===t[r]||void 0===t[r][i])return;delete t[r][i],void 0!==t[r]._visualValues&&void 0!==t[r]._visualValues[i]&&delete t[r]._visualValues[i]}}catch(t){a.e(t)}finally{a.f()}}}function Ye(t,e,i,r,n){let a,s,l,h=o(r,0),c=Math.min(o(n,t.length),t.length),d=0;for(i=Math.ceil(i),n&&(i=(a=n-r)/Math.floor(a/i)),l=h;l<0;)d++,l=Math.round(h+d*i);for(s=Math.max(h,0);s{var s,l,h,c,d=n[e];return r(d)?d._proxy?console.warn("Ignoring resolver passed as options for scale: "+e):(s=(c=Qe(e,d,(h=e,(c=t).data&&c.data.datasets&&(c=c.data.datasets.filter(t=>t.xAxisID===h||t.yAxisID===h)).length?ti(h,"x",c[0])||ti(h,"y",c[0]):{}),dn.scales[d.type]))===a?"_index_":"_value_",l=i.scales||{},void(o[e]=m(Object.create(null),[{axis:c},d,l[c],l[s]]))):console.error("Invalid scale configuration for scale: "+e)}),t.data.datasets.forEach(i=>{const r=i.type||t.type,a=i.indexAxis||Ze(r,e),s=(hn[r]||{}).scales||{};Object.keys(s).forEach(t=>{var e=function(t){let e=t;return"_index_"===t?e=a:"_value_"===t&&(e="x"===a?"y":"x"),e}(t),r=i[e+"AxisID"]||e;o[r]=o[r]||Object.create(null),m(o[r],[{axis:e},n[r],s[t]])})}),Object.keys(o).forEach(t=>{m(t=o[t],[dn.scales[t.type],dn.scale])}),o}(t,e)}function ii(t){return(t=t||{}).datasets=t.datasets||[],t.labels=t.labels||[],t}function ri(t,e){let i=ia.get(t);return i||(i=e(),ia.set(t,i),ra.add(i)),i}function ni(t,e,i){let r=t.get(e),n=(r||(r=new Map,t.set(e,r)),t=i.join(),r.get(t));return n||(n={resolver:Bt(e,i),subPrefixes:i.filter(t=>!t.toLowerCase().includes("hover"))},r.set(t,n)),n}function ai(t,e){return"top"===t||"bottom"===t||-1===sa.indexOf(t)&&"x"===e}function oi(t,e){return function(i,r){return i[t]===r[t]?i[e]-r[e]:i[t]-r[t]}}function si(t){var e=t.chart,i=e.options.animation;e.notifyPlugins("afterRender"),s(i&&i.onComplete,[t],e)}function li(t){var e=t.chart,i=e.options.animation;s(i&&i.onProgress,[t],e)}function hi(t){return pt()&&"string"==typeof t?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas?t.canvas:t}function ci(){l(ca.instances,t=>t._plugins.invalidate())}function di(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}function ui(t,e,r,n){if(i(t)){var a=e,o=r,s=o.parse((l=t)[0],h=n),l=o.parse(l[1],h),h=Math.min(s,l),c=Math.max(s,l);let i=h,d=c;Math.abs(h)>Math.abs(c)&&(i=c,d=h),a[o.axis]=d,a._custom={barStart:i,barEnd:d,start:s,end:l,min:h,max:c}}else e[r.axis]=r.parse(t,n);return e}function pi(t,e,i,r){let n,a,o,s,l=t.iScale,h=t.vScale,c=l.getLabels(),d=l===h,u=[];for(a=(n=i)+r;n{var e=(r-Math.min(a,t))*n/2;return I(t,0,Math.min(a,e))};return{outerStart:s(t.outerStart),outerEnd:s(t.outerEnd),innerStart:I(t.innerStart,0,o),innerEnd:I(t.innerEnd,0,o)}}(0,h,d,(l=n-c-u)-p)).outerStart;var m=r.outerEnd,f=r.innerStart,g=r.innerEnd,v=d-c,b=d-m,y=p+c/v,x=l-m/b,w=h+f,k=h+g,_=p+f/w,S=l-g/k;if(t.beginPath(),a){const e=(y+x)/2;if(t.arc(o,s,d,y,e),t.arc(o,s,d,e,x),0(p+(b?m-t:t))%u,k=()=>{s!==l&&(t.lineTo(y,l),t.lineTo(y,s),t.lineTo(y,h))};for(v&&(a=c[w(0)],t.moveTo(a.x,a.y)),n=0;n<=m;++n)if(!(a=c[w(n)]).skip){const e=a.x,i=a.y,r=0|e;r===o?(il&&(l=i),y=(x*y+e)/++x):(k(),t.lineTo(e,i),o=r,x=0,s=l=i),h=i}k()}function Si(t){var e=t.options,i=e.borderDash&&e.borderDash.length;return t._decimated||t._loop||e.tension||"monotone"===e.cubicInterpolationMode||e.stepped||i?ki:_i}function Mi(t,e,i,r){var n=t.options;t=t.getProps([i],r)[i];return Math.abs(e-t)=t[p].pos&&e<=t[m].pos&&(p=(r=Dr(t,"pos",e)).lo,m=r.hi),h=(n=t[p]).pos,d=n.time,c=(a=t[m]).pos,a.time):(e>=t[p].time&&e<=t[m].time&&(p=(o=Dr(t,"time",e)).lo,m=o.hi),h=(s=t[p]).time,d=s.pos,c=(l=t[m]).time,l.pos),(i=c-h)?d+(u-d)*(e-h)/i:d}function Ui(t){return Ca[t%Ca.length]}function Gi(t){return za[t%za.length]}function Yi(t){let e;for(e in t)if(t[e].borderColor||t[e].backgroundColor)return!0;return!1}function $i(t){var e;t._decimated&&(e=t._data,delete t._decimated,delete t._data,Object.defineProperty(t,"data",{configurable:!0,enumerable:!0,writable:!0,value:e}))}function Xi(t){t.data.datasets.forEach(t=>{$i(t)})}function Ki(t,e,i,r){if(!r){let r=e[t],n=i[t];return"angle"===t&&(r=P(r),n=P(n)),{property:t,start:r,end:n}}}function Zi(t,e,i){for(;t{e=Zi(t,e,s),t=s[t],e=s[e],null!==o?(l.push({x:t.x,y:o}),l.push({x:e.x,y:o})):null!==n&&(l.push({x:n,y:t.y}),l.push({x:n,y:e.y}))}),l}(e)).length?new ga({points:r,options:{tension:0},_loop:n,_fullLoop:n}):null}function tr(t){return t&&!1!==t.fill}function er(t){var e=t.chart,i=t.fill,a=t.line;if(n(i))return(s=e.getDatasetMeta(o=i))&&e.isDatasetVisible(o)?s.dataset:null;if("stack"!==i)return"shape"===i||((e=function(t){if((t.scale||{}).getPointPositionForValue){var e=(i=d=t).scale,i=i.fill,a=e.options,o=e.getLabels().length,s=a.reverse?e.max:e.min,l=(u=e,"start"===(d=i)?s:"end"===d?u.options.reverse?u.min:u.max:r(d)?d.value:u.getBaseValue()),h=[];if(a.grid.circular){const t=e.getPointPositionForValue(0,s);return new Pa({x:t.x,y:t.y,radius:e.getDistanceFromCenterForValue(l)})}for(let t=0;tt+e.before.length+e.lines.length+e.after.length,0),x=(y+=t.beforeBody.length+t.afterBody.length,p&&(v+=p*d.lineHeight+(p-1)*e.titleSpacing+e.titleMarginBottom),y&&(v+=f*(e.displayColors?Math.max(h,c.lineHeight):c.lineHeight)+(y-f)*c.lineHeight+(y-1)*e.bodySpacing),m&&(v+=e.footerMarginTop+m*u.lineHeight+(m-1)*e.footerSpacing),0);return r.save(),r.font=d.string,l(t.title,i),r.font=c.string,l(t.beforeBody.concat(t.afterBody),i),x=e.displayColors?s+2+e.boxPadding:0,l(n,t=>{l(t.before,i),l(t.lines,i),l(t.after,i)}),x=0,r.font=u.string,l(t.footer,i),r.restore(),{width:b+=g.width,height:v}}function dr(t,e,i){var r,n,a=i.yAlign||e.yAlign||((r=i.y)<(n=i.height)/2?"top":r>t.height-n/2?"bottom":"center");return{xAlign:i.xAlign||e.xAlign||function(){let r=i.x,n=i.width,o=t.width,s=t.chartArea,l=s.left,h=s.right,c="center";return"center"===a?c=r<=(l+h)/2?"left":"right":r<=n/2?c="left":o-n/2<=r&&(c="right"),d=c,u=i.x,p=i.width,m=e.caretSize+e.caretPadding,"left"===d&&t.width{let t=0;return()=>t++})(),yr=(t,e)=>"string"==typeof t&&t.endsWith("%")?parseFloat(t)/100:+t/e,xr=(t,e)=>"string"==typeof t&&t.endsWith("%")?parseFloat(t)/100*e:+t,wr={"":t=>t,x:t=>t.x,y:t=>t.y},kr=t=>void 0!==t,_r=t=>"function"==typeof t,Sr=(t,e)=>{if(t.size!==e.size)return!1;var i,r=_createForOfIteratorHelper(t);try{for(r.s();!(i=r.n()).done;){var n=i.value;if(!e.has(n))return!1}}catch(t){r.e(t)}finally{r.f()}return!0},Mr=Math.PI,Ar=2*Mr,Tr=Ar+Mr,Cr=Number.POSITIVE_INFINITY,zr=Mr/180,Or=Mr/2,Lr=Mr/4,Pr=2*Mr/3,Er=Math.log10,Ir=Math.sign,Dr=(t,e,i,r)=>R(t,i,r?r=>{var n=t[r][e];return nt[r][e]R(t,i,r=>t[r][e]>=i),Rr=["push","pop","shift","splice","unshift"],Nr="undefined"==typeof window?function(t){return t()}:window.requestAnimationFrame,Fr=t=>"start"===t?"left":"end"===t?"right":"center",Hr=(t,e,i)=>"start"===t?e:"end"===t?i:(e+i)/2,Vr=(t,e,i,r)=>t===(r?"left":"right")?i:"center"===t?(e+i)/2:e;var qr=new class{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,e,i,r){const n=e.listeners[r],a=e.duration;n.forEach(r=>r({chart:t,initial:e.initial,numSteps:a,currentStep:Math.min(i-e.start,a)}))}_refresh(){this._request||(this._running=!0,this._request=Nr.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let e=0;this._charts.forEach((i,r)=>{if(i.running&&i.items.length){let n,a=i.items,o=a.length-1,s=!1;for(;0<=o;--o)(n=a[o])._active?(n._total>i.duration&&(i.duration=n._total),n.tick(t),s=!0):(a[o]=a[a.length-1],a.pop());s&&(r.draw(),this._notify(r,i,t,"progress")),a.length||(i.running=!1,this._notify(r,i,t,"complete"),i.initial=!1),e+=a.length}}),this._lastDate=t,0===e&&(this._running=!1)}_getAnims(t){let e=this._charts,i=e.get(t);return i||(i={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},e.set(t,i)),i}listen(t,e,i){this._getAnims(t).listeners[e].push(i)}add(t,e){e&&e.length&&this._getAnims(t).items.push(...e)}has(t){return 0Math.max(t,e._duration),0),this._refresh())}running(t){return!!this._running&&!!((t=this._charts.get(t))&&t.running&&t.items.length)}stop(t){var e=this._charts.get(t);if(e&&e.items.length){let i=e.items,r=i.length-1;for(;0<=r;--r)i[r].cancel();e.items=[],this._notify(t,e,Date.now(),"complete")}}remove(t){return this._charts["delete"](t)}};const jr=(t,e,i)=>Math.max(Math.min(t,i),e),Wr={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},Ur=[..."0123456789ABCDEF"],Gr=t=>Ur[15&t],Yr=t=>Ur[(240&t)>>4]+Ur[15&t],$r=t=>(240&t)>>4==(15&t),Xr=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/,Kr={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},Zr={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};let Jr;const Qr=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/,tn=t=>t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055,en=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);class rn{constructor(t){if(t instanceof rn)return t;var e,i,r=typeof t;let n;"object"==r?n=ot(t):"string"==r&&(i=(r=t).length,"#"===r[0]&&(4===i||5===i?e={r:255&17*Wr[r[1]],g:255&17*Wr[r[2]],b:255&17*Wr[r[3]],a:5===i?17*Wr[r[4]]:255}:7!==i&&9!==i||(e={r:Wr[r[1]]<<4|Wr[r[2]],g:Wr[r[3]]<<4|Wr[r[4]],b:Wr[r[5]]<<4|Wr[r[6]],a:9===i?Wr[r[7]]<<4|Wr[r[8]]:255})),n=e||(i=t,Jr||((Jr=function(){let t,e,i,r,n,a={},o=Object.keys(Zr),s=Object.keys(Kr);for(t=0;t>16&255,i>>8&255,255&i]}return a}()).transparent=[0,0,0,0]),(i=Jr[i.toLowerCase()])&&{r:i[0],g:i[1],b:i[2],a:4===i.length?i[3]:255})||("r"===(r=t).charAt(0)?function(t){let e,i,r,n=Qr.exec(t),a=255;if(n){if(void 0!==n[7]){const t=+n[7];a=n[8]?Y(t):jr(255*t,0,255)}return e=+n[1],i=+n[3],r=+n[5],{r:255&(n[2]?Y(e):jr(e,0,255)),g:255&(n[4]?Y(i):jr(i,0,255)),b:255&(n[6]?Y(r):jr(r,0,255)),a:a}}}:function(t){var e,i,r;let n,a=255;if(t=Xr.exec(t))return void 0!==t[5]&&(a=(t[6]?Y:$)(+t[5])),e=rt(+t[2]),i=+t[3]/100,r=+t[4]/100,{r:(n="hwb"===t[1]?et(Q,e,i,r):"hsv"===t[1]?et(J,e,i,r):it(e,i,r))[0],g:n[1],b:n[2],a:a}})(r)),this._rgb=n,this._valid=!!n}get valid(){return this._valid}get rgb(){var t=at(this._rgb);return t&&(t.a=X(t.a)),t}set rgb(t){this._rgb=ot(t)}rgbString(){return this._valid?(t=this._rgb)&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${X(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`):void 0;var t}hexString(){return this._valid&&(e=t=this._rgb,e=$r(e.r)&&$r(e.g)&&$r(e.b)&&$r(e.a)?Gr:Yr,t)?"#"+e(t.r)+e(t.g)+e(t.b)+((t=t.a)<255?e(t):""):void 0;var t,e}hslString(){if(this._valid){var t,e,i,r=this._rgb;if(r)return t=(i=tt(r))[0],e=K(i[1]),i=K(i[2]),r.a<255?`hsla(${t}, ${e}%, ${i}%, ${X(r.a)})`:`hsl(${t}, ${e}%, ${i}%)`}}mix(t,e){var i,r,n;return t&&(i=this.rgb,t=t.rgb,n=i.a-t.a,i.r=255&(r=(1+((r=2*(e=void 0===e?.5:e)-1)*n==-1?r:(r+n)/(1+r*n)))/2)*i.r+(n=1-r)*t.r+.5,i.g=255&r*i.g+n*t.g+.5,i.b=255&r*i.b+n*t.b+.5,i.a=e*i.a+(1-e)*t.a,this.rgb=i),this}interpolate(t,e){return t&&(this._rgb=(i=this._rgb,t=t._rgb,r=en(X(i.r)),n=en(X(i.g)),a=en(X(i.b)),{r:$(tn(r+e*(en(X(t.r))-r))),g:$(tn(n+e*(en(X(t.g))-n))),b:$(tn(a+e*(en(X(t.b))-a))),a:i.a+e*(t.a-i.a)})),this;var i,r,n,a}clone(){return new rn(this.rgb)}alpha(t){return this._rgb.a=$(t),this}clearer(t){return this._rgb.a*=1-t,this}greyscale(){var t=this._rgb,e=G(.3*t.r+.59*t.g+.11*t.b);return t.r=t.g=t.b=e,this}opaquer(t){return this._rgb.a*=1+t,this}negate(){var t=this._rgb;return t.r=255-t.r,t.g=255-t.g,t.b=255-t.b,this}lighten(t){return nt(this._rgb,2,t),this}darken(t){return nt(this._rgb,2,-t),this}saturate(t){return nt(this._rgb,1,t),this}desaturate(t){return nt(this._rgb,1,-t),this}rotate(t){return(i=tt(e=this._rgb))[0]=rt(i[0]+t),i=it(i),e.r=i[0],e.g=i[1],e.b=i[2],this;var e,i}}const nn=["x","y","borderWidth","radius","tension"],an=["color","borderColor","backgroundColor"],on=new Map,sn={values:t=>i(t)?t:""+t,numeric(t,e,i){if(0===t)return"0";let r,n=this.chart.options.locale,a=t;if(1.8*i.length?sn.numeric.call(this,t,e,i):"")}};var ln={formatters:sn};const hn=Object.create(null),cn=Object.create(null);var dn=new class{constructor(t,e){this.animation=void 0,this.backgroundColor="rgba(0,0,0,0.1)",this.borderColor="rgba(0,0,0,0.1)",this.color="#666",this.datasets={},this.devicePixelRatio=(t=>t.chart.platform.getDevicePixelRatio()),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=((t,e)=>ht(e.backgroundColor)),this.hoverBorderColor=((t,e)=>ht(e.borderColor)),this.hoverColor=((t,e)=>ht(e.color)),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0,includeInvisible:!1},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(t),this.apply(e)}set(t,e){return ut(this,t,e)}get(t){return dt(this,t)}describe(t,e){return ut(cn,t,e)}override(t,e){return ut(hn,t,e)}route(t,e,i,n){const a=dt(this,t),s=dt(this,i),l="_"+e;Object.defineProperties(a,{[l]:{value:a[e],writable:!0},[e]:{enumerable:!0,get(){var t=this[l],e=s[n];return r(t)?Object.assign({},e,t):o(t,e)},set(t){this[l]=t}}})}apply(t){t.forEach(t=>t(this))}}({_scriptable:t=>!t.startsWith("on"),_indexable:t=>"events"!==t,hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[function(t){t.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0}),t.describe("animation",{_fallback:!1,_indexable:!1,_scriptable:t=>"onProgress"!==t&&"onComplete"!==t&&"fn"!==t}),t.set("animations",{colors:{type:"color",properties:an},numbers:{type:"number",properties:nn}}),t.describe("animations",{_fallback:"animation"}),t.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>0|t}}}})},function(t){t.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})},function(t){t.set("scale",{display:!0,offset:!1,reverse:!1,beginAtZero:!1,bounds:"ticks",clip:!0,grace:0,grid:{display:!0,lineWidth:1,drawOnChartArea:!0,drawTicks:!0,tickLength:8,tickWidth:(t,e)=>e.lineWidth,tickColor:(t,e)=>e.color,offset:!1},border:{display:!0,dash:[],dashOffset:0,width:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:ln.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),t.route("scale.ticks","color","","color"),t.route("scale.grid","color","","borderColor"),t.route("scale.border","color","","borderColor"),t.route("scale.title","color","","color"),t.describe("scale",{_fallback:!1,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&"callback"!==t&&"parser"!==t,_indexable:t=>"borderDash"!==t&&"tickBorderDash"!==t&&"dash"!==t}),t.describe("scales",{_fallback:"scale"}),t.describe("scale.ticks",{_scriptable:t=>"backdropPadding"!==t&&"callback"!==t,_indexable:t=>"backdropPadding"!==t})}]);const un=t=>t.ownerDocument.defaultView.getComputedStyle(t,null),pn=["top","right","bottom","left"],mn=t=>Math.round(10*t)/10;var fn=function(){let t=!1;try{var e={get passive(){return!(t=!0)}};pt()&&(window.addEventListener("test",null,e),window.removeEventListener("test",null,e))}catch(t){}return t}();const gn=(t,e)=>t?t+b(e):e,vn=(t,e)=>r(e)&&"adapters"!==t&&(null===Object.getPrototypeOf(e)||e.constructor===Object),bn=(t,e)=>!0===t?e:"string"==typeof t?v(e,t):void 0,yn=Number.EPSILON||1e-14,xn=(t,e)=>e"x"===t?"y":"x",kn=t=>0===t||1===t,_n=(t,e,i)=>-Math.pow(2,10*--t)*Math.sin((t-e)*Ar/i),Sn=(t,e,i)=>Math.pow(2,-10*t)*Math.sin((t-e)*Ar/i)+1,Mn={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>--t*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-(--t*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>--t*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>1-Math.cos(t*Or),easeOutSine:t=>Math.sin(t*Or),easeInOutSine:t=>-.5*(Math.cos(Mr*t)-1),easeInExpo:t=>0===t?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>1===t?1:1-Math.pow(2,-10*t),easeInOutExpo:t=>kn(t)?t:t<.5?.5*Math.pow(2,10*(2*t-1)):.5*(2-Math.pow(2,-10*(2*t-1))),easeInCirc:t=>1<=t?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1- --t*t),easeInOutCirc:t=>(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>kn(t)?t:_n(t,.075,.3),easeOutElastic:t=>kn(t)?t:Sn(t,.075,.3),easeInOutElastic:t=>kn(t)?t:t<.5?.5*_n(2*t,.1125,.45):.5+.5*Sn(2*t-1,.1125,.45),easeInBack:t=>t*t*(2.70158*t-1.70158),easeOutBack:t=>--t*t*(2.70158*t+1.70158)+1,easeInOutBack(t){let e=1.70158;return(t/=.5)<1?t*t*((1+(e*=1.525))*t-e)*.5:.5*((t-=2)*t*((1+(e*=1.525))*t+e)+2)},easeInBounce:t=>1-Mn.easeOutBounce(1-t),easeOutBounce(t){var e=7.5625,i=2.75;return t<1/i?e*t*t:t<2/i?e*(t-=1.5/i)*t+.75:t<2.5/i?e*(t-=2.25/i)*t+.9375:e*(t-=2.625/i)*t+.984375},easeInOutBounce:t=>t<.5?.5*Mn.easeInBounce(2*t):.5*Mn.easeOutBounce(2*t-1)+.5},An=/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/,Tn=/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/,Cn=t=>+t||0;var zn=Object.freeze({__proto__:null,HALF_PI:Or,INFINITY:Cr,PI:Mr,PITAU:Tr,QUARTER_PI:Lr,RAD_PER_DEG:zr,TAU:Ar,TWO_THIRDS_PI:Pr,_addGrace:oe,_alignPixel:Mt,_alignStartEnd:Hr,_angleBetween:E,_angleDiff:L,_arrayUnique:V,_attachContext:Rt,_bezierCurveTo:Et,_bezierInterpolation:Jt,_boundSegment:pe,_boundSegments:me,_capitalize:b,_computeSegments:fe,_createResolver:Bt,_decimalPlaces:C,_deprecated:function(t,e,i,r){void 0!==e&&console.warn(t+': "'+i+'" is deprecated. Please use "'+r+'" instead')},_descriptors:Nt,_elementsEqual:h,_factorize:k,_filterBetween:N,_getParentNode:mt,_getStartAndCountOfVisiblePoints:W,_int16Range:D,_isBetween:B,_isClickEvent:y,_isDomSupported:pt,_isPointInArea:zt,_limitValue:I,_longestText:St,_lookup:R,_lookupByKey:Dr,_measureText:_t,_merger:u,_mergerIf:f,_normalizeAngle:P,_parseObjectDataRadialScale:Ut,_pointInLine:Kt,_readValueToProps:te,_rlookupByKey:Br,_scaleRangesChanged:U,_setMinAndMaxByKey:M,_splitKey:g,_steppedInterpolation:Zt,_steppedLineTo:Pt,_textX:Vr,_toLeftRightCenter:Fr,_updateBezierControlPoints:Xt,addRoundedRectPath:Dt,almostEquals:x,almostWhole:S,callback:s,clearCanvas:At,clipArea:Ot,clone:c,color:lt,createContext:se,debounce:j,defined:kr,distanceBetweenPoints:O,drawPoint:Tt,drawPointLegend:Ct,each:l,easingEffects:Mn,finiteOrDefault:a,fontString:function(t,e,i){return e+" "+t+"px "+i},formatNumber:ct,getAngleFromPoint:z,getDatasetClipArea:be,getHoverColor:ht,getMaximumSize:yt,getRelativePosition:bt,getRtlAdapter:le,getStyle:gt,isArray:i,isFinite:n,isFunction:_r,isNullOrUndef:e,isNumber:_,isObject:r,isPatternOrGradient:st,listenArrayEvents:F,log10:Er,merge:p,mergeIf:m,niceNum:w,noop:t,overrideTextDirection:he,readUsedSize:wt,renderText:It,requestAnimFrame:Nr,resolve:ae,resolveObjectKey:v,restoreTextDirection:ce,retinaScale:xt,setsEqual:Sr,sign:Ir,splineCurve:Gt,splineCurveMonotone:Yt,supportsEventListenerOptions:fn,throttled:q,toDegrees:T,toDimension:xr,toFont:ne,toFontString:kt,toLineHeight:Qt,toPadding:re,toPercentage:yr,toRadians:A,toTRBL:ee,toTRBLCorners:ie,uid:br,unclipArea:Lt,unlistenArrayEvents:H,valueOrDefault:o}),On={evaluateInteractionItems:ye,modes:{index(t,e,i,r){const n=bt(e,t),a=i.axis||"x",o=i.includeInvisible||!1,s=i.intersect?xe(t,n,a,r,o):we(t,n,a,!1,r,o),l=[];return s.length?(t.getSortedVisibleDatasetMetas().forEach(t=>{var e=s[0].index,i=t.data[e];i&&!i.skip&&l.push({element:i,datasetIndex:t.index,index:e})}),l):[]},dataset(t,e,i,r){e=bt(e,t);var n=i.axis||"xy",a=i.includeInvisible||!1;let o=i.intersect?xe(t,e,n,r,a):we(t,e,n,!1,r,a);if(0xe(t,bt(e,t),i.axis||"xy",r,i.includeInvisible||!1),nearest:(t,e,i,r)=>we(t,bt(e,t),i.axis||"xy",i.intersect,r,i.includeInvisible||!1),x:(t,e,i,r)=>ke(t,bt(e,t),"x",i.intersect,r),y:(t,e,i,r)=>ke(t,bt(e,t),"y",i.intersect,r)}};const Ln=["left","top","right","bottom"];var Pn={addBox(t,e){t.boxes||(t.boxes=[]),e.fullSize=e.fullSize||!1,e.position=e.position||"top",e.weight=e.weight||0,e._layers=e._layers||function(){return[{z:0,draw(t){e.draw(t)}}]},t.boxes.push(e)},removeBox(t,e){-1!==(e=t.boxes?t.boxes.indexOf(e):-1)&&t.boxes.splice(e,1)},configure(t,e,i){e.fullSize=i.fullSize,e.position=i.position,e.weight=i.weight},update(t,e,i,r){if(t){ var n,a,o=re(t.options.layout.padding),s=Math.max(e-o.width,0),h=Math.max(i-o.height,0),c=(c=Me((d=function(t){let e,i,r,n,a,o,s=[];for(e=0,i=(t||[]).length;et.box.fullSize),!0),u=Me(_e(d,"left"),!0),p=Me(_e(d,"right")),f=Me(_e(d,"top"),!0),n=Me(_e(d,"bottom")),a=Se(d,"x"),m=Se(d,"y"),{fullSize:c,leftAndTop:u.concat(f),rightAndBottom:p.concat(m).concat(n).concat(a),chartArea:_e(d,"chartArea"),vertical:u.concat(p).concat(m),horizontal:f.concat(n).concat(a)}),d=c.vertical,u=c.horizontal,p=(l(t.boxes,t=>{"function"==typeof t.beforeLayout&&t.beforeLayout()}),d.reduce((t,e)=>e.box.options&&!1===e.box.options.display?t:t+1,0)||1),m=Object.freeze({outerWidth:e,outerHeight:i,padding:o,availableWidth:s,availableHeight:h,vBoxMaxWidth:s/2/p,hBoxMaxHeight:h/2}),f=Object.assign({},o);Te(f,re(r));const b=Object.assign({maxPadding:f,w:s,h:h,x:o.left,y:o.top},o),y=function(t,e){let i,r,n,a=function(){var e,i,r={},n=_createForOfIteratorHelper(t);try{for(n.s();!(i=n.n()).done;){var a=i.value,o=a.stack,s=a.pos,l=a.stackWeight;o&&Ln.includes(s)&&((e=r[o]||(r[o]={count:0,placed:0,weight:0,size:0})).count++,e.weight+=l)}}catch(e){n.e(e)}finally{n.f()}return r}(),o=e.vBoxMaxWidth,s=e.hBoxMaxHeight;for(i=0,r=t.length;i{e=e.box,Object.assign(e,t.chartArea),e.update(b.w,b.h,{left:0,top:0,right:0,bottom:0})})}}};class En{acquireContext(t,e){}releaseContext(t){return!1}addEventListener(t,e,i){}removeEventListener(t,e,i){}getDevicePixelRatio(){return 1}getMaximumSize(t,e,i,r){return e=Math.max(0,e||t.width),i=i||t.height,{width:e,height:Math.max(0,r?Math.floor(e/r):i)}}isAttached(t){return!0}updateConfig(t){}}class In extends En{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const Dn="$chartjs",Bn={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},Rn=t=>null===t||""===t,Nn=!!fn&&{passive:!0},Fn=new Map;let Hn=0;class Vn extends En{acquireContext(t,e){var i=t&&t.getContext&&t.getContext("2d");if(i&&i.canvas===t){var r=e,n=(e=t.style,t.getAttribute("height")),a=t.getAttribute("width");if(t[Dn]={initial:{height:n,width:a,style:{display:e.display,height:e.height,width:e.width}}},e.display=e.display||"block",e.boxSizing=e.boxSizing||"border-box",Rn(a)){const e=wt(t,"width");void 0!==e&&(t.width=e)}if(Rn(n))if(""===t.style.height)t.height=t.width/(r||2);else{const e=wt(t,"height");void 0!==e&&(t.height=e)}return i}return null}releaseContext(t){const i=t.canvas;if(!i[Dn])return!1;const r=i[Dn].initial,n=(["height","width"].forEach(t=>{var n=r[t];e(n)?i.removeAttribute(t):i.setAttribute(t,n)}),r.style||{});return Object.keys(n).forEach(t=>{i.style[t]=n[t]}),i.width=i.width,delete i[Dn],!0}addEventListener(t,e,i){this.removeEventListener(t,e);var r=t.$proxies||(t.$proxies={}),n={attach:Pe,detach:Ee,resize:De}[e]||Re;r[e]=n(t,e,i)}removeEventListener(t,e){var i=t.$proxies||(t.$proxies={}),r=i[e];r&&(({attach:Be,detach:Be,resize:Be}[e]||function(t,e,i){t&&t.canvas&&t.canvas.removeEventListener(e,i,Nn)})(t,e,r),i[e]=void 0)}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,e,i,r){return yt(t,e,i,r)}isAttached(t){return!(!(t=t&&mt(t))||!t.isConnected)}}fn=Object.freeze({__proto__:null,BasePlatform:En,BasicPlatform:In,DomPlatform:Vn,_detectPlatform:Ne});const qn="transparent",jn={boolean:(t,e,i)=>.5t+(e-t)*i};class Wn{constructor(t,e,i,r){var n=e[i];r=ae([t.to,r,n,t.from]),n=ae([t.from,n,r]);this._active=!0,this._fn=t.fn||jn[t.type||typeof n],this._easing=Mn[t.easing]||Mn.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=e,this._prop=i,this._from=n,this._to=r,this._promises=void 0}active(){return this._active}update(t,e,i){var r,n,a;this._active&&(this._notify(!1),r=this._target[this._prop],n=i-this._start,a=this._duration-n,this._start=i,this._duration=Math.floor(Math.max(a,t.duration)),this._total+=n,this._loop=!!t.loop,this._to=ae([t.to,e,r,t.from]),this._from=ae([t.from,r,e]))}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){t-=this._start;var e=this._duration,i=this._prop,r=this._from,n=this._loop,a=this._to;this._active=r!==a&&(n||t{t.push({res:e,rej:i})})}_notify(t){var e=t?"res":"rej",i=this._promises||[];for(let t=0;t{var o=t[a];if(r(o)){const t={};for(var s=0,l=e;s{e!==a&&n.has(e)||n.set(e,t)})}})}}_animateOptions(t,e){const i=e.options,r=function(t,e){if(e){let i=t.options;if(i)return i.$shared&&(t.options=i=Object.assign({},i,{$shared:!1,$animations:{}})),i;t.options=e}}(t,i);return r?(e=this._createAnimations(r,i),i.$shared&&function(t,e){var i=[],r=Object.keys(e);for(let e=0;e{t.options=i},()=>{}),e):[]}_createAnimations(t,e){let i,r=this._properties,n=[],a=t.$animations||(t.$animations={}),o=Object.keys(e),s=Date.now();for(i=o.length-1;0<=i;--i){var l=o[i];if("$"!==l.charAt(0))if("options"===l)n.push(...this._animateOptions(t,e));else{let i=e[l],o=a[l],h=r.get(l);if(o){if(h&&o.active()){o.update(h,i,s);continue}o.cancel()}h&&h.duration?(a[l]=o=new Wn(h,t,l,i),n.push(o)):t[l]=i}}return n}update(t,e){var i;if(0!==this._properties.size)return(i=this._createAnimations(t,e)).length?(qr.add(this._chart,i),!0):void 0;Object.assign(t,e)}}const Gn=t=>"reset"===t||"none"===t,Yn=(t,e)=>e?t:Object.assign({},t);class $n{constructor(t,e){this.chart=t,this._ctx=t.ctx,this.index=e,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){var t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=qe(t.vScale,t),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(t){this.index!==t&&Ge(this._cachedMeta),this.index=t}linkScales(){var t=this.chart,e=this._cachedMeta,i=this.getDataset(),r=(t,e,i,r)=>"x"===t?e:"r"===t?r:i,n=e.xAxisID=o(i.xAxisID,Ue(t,"x")),a=e.yAxisID=o(i.yAxisID,Ue(t,"y")),s=(i=e.rAxisID=o(i.rAxisID,Ue(t,"r")),t=e.indexAxis,e.iAxisID=r(t,n,a,i));r=e.vAxisID=r(t,a,n,i);e.xScale=this.getScaleForId(n),e.yScale=this.getScaleForId(a),e.rScale=this.getScaleForId(i),e.iScale=this.getScaleForId(s),e.vScale=this.getScaleForId(r)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){var e=this._cachedMeta;return t===e.iScale?e.vScale:e.iScale}reset(){this._update("reset")}_destroy(){var t=this._cachedMeta;this._data&&H(this._data,this),t._stacked&&Ge(t)}_dataCheck(){const t=this.getDataset(),e=t.data||(t.data=[]),i=this._data;if(r(e)){const t=this._cachedMeta;this._data=function(e){let i,r,n,a=t.iScale,o=t.vScale,s="x"===a.axis?"x":"y",l="x"===o.axis?"x":"y",h=Object.keys(e),c=new Array(h.length);for(i=0,r=h.length;inull===a[d]||p&&a[d]e||pthis.getContext(i,r,e),l)).$shared&&(c.$shared=s,n[a]=Object.freeze(Yn(c,s))),c)}_resolveAnimations(t,e,i){const r=this.chart,n=this._cachedDataOpts,a="animation-"+e,o=n[a];if(o)return o;let s;if(!1!==r.options.animation){const r=this.chart.config,n=r.datasetAnimationScopeKeys(this._type,e),a=r.getOptionScopes(this.getDataset(),n);s=r.createResolver(a,this.getContext(t,i,e))}return t=new Un(r,s&&s.animations),s&&s._cacheable&&(n[a]=Object.freeze(t)),t}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,e){return!e||Gn(t)||this.chart._animationsDisabled}_getSharedOptions(t,e){t=this.resolveDataElementOptions(t,e);var i=this._sharedOptions,r=this.getSharedOptions(t);i=this.includeOptions(e,r)||r!==i;return this.updateSharedOptions(r,e,t),{sharedOptions:r,includeOptions:i}}updateElement(t,e,i,r){Gn(r)?Object.assign(t,i):this._resolveAnimations(e,r).update(t,i)}updateSharedOptions(t,e,i){t&&!Gn(e)&&this._resolveAnimations(void 0,e).update(t,i)}_setStyle(t,e,i,r){t.active=r;var n=this.getStyle(e,r);this._resolveAnimations(e,i,r).update(t,{options:!r&&this.getSharedOptions(n)||n})}removeHoverStyle(t,e,i){this._setStyle(t,i,"active",!1)}setHoverStyle(t,e,i){this._setStyle(t,i,"active",!0)}_removeDatasetHoverStyle(){var t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){var t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){var e,i=this._data,r=this._cachedMeta.data,n=_createForOfIteratorHelper(this._syncList);try{for(n.s();!(e=n.n()).done;){var a=_slicedToArray(e.value,3),o=a[0],s=a[1],l=a[2];this[o](s,l)}}catch(t){n.e(t)}finally{n.f()}this._syncList=[];r=r.length,i=i.length;var h=Math.min(i,r);h&&this.parse(0,h),r{for(t.length+=e,o=t.length-1;o>=a;o--)t[o]=t[o-e]};for(s(n),o=t;o{r[t]=i[t]&&i[t].active()?i[t]._to:this[t]}),r}}_defineProperty(Xn,"defaults",{}),_defineProperty(Xn,"defaultRoutes",void 0);const Kn=(t,e,i)=>"top"===e||"left"===e?t[e]+i:t[e]-i,Zn=(t,e)=>Math.min(e||t,t);class Jn extends Xn{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,e){return t}getUserBounds(){var t=this._userMin,e=this._userMax,i=this._suggestedMin,r=this._suggestedMax;t=a(t,Number.POSITIVE_INFINITY),e=a(e,Number.NEGATIVE_INFINITY),i=a(i,Number.POSITIVE_INFINITY),r=a(r,Number.NEGATIVE_INFINITY);return{min:a(t,i),max:a(e,r),minDefined:n(t),maxDefined:n(e)}}getMinMax(t){let e,i=this.getUserBounds(),r=i.min,n=i.max,o=i.minDefined,s=i.maxDefined;if(o&&s)return{min:r,max:n};var l=this.getMatchingVisibleMetas();for(let i=0,a=l.length;in?n:r,a(n=o&&r>n?r:n,r)),max:a(n,a(r,n))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){var t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){s(this.options.beforeUpdate,[this])}update(t,i,r){var n,a=(n=this.options).beginAtZero,o=n.grace,s=(n=n.ticks).sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=i,this._margins=r=Object.assign({left:0,right:0,top:0,bottom:0},r),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+r.left+r.right:this.height+r.top+r.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=oe(this,o,a),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks(),t=sr)return e}}return Math.max(r,1)}(o,i,a);if(0{let e,i=t.gc,r=i.length/2;if(S({width:y[t]||0,height:x[t]||0});return{first:A(0),last:A(r-1),widest:A(n),highest:A(M),widths:y,heights:x}}getLabelForValue(t){return t}getPixelForValue(t,e){return NaN}getValueForPixel(t){}getPixelForTick(t){var e=this.ticks;return t<0||t>e.length-1?null:this.getPixelForValue(e[t].value)}getPixelForDecimal(t){return this._reversePixels&&(t=1-t),t=this._startPixel+t*this._length,D(this._alignToPixels?Mt(this.chart,t,0):t)}getDecimalForPixel(t){return t=(t-this._startPixel)/this._length,this._reversePixels?1-t:t}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){var t=this.min,e=this.max;return t<0&&e<0?e:0s+1e-6)))return l}(this,n,k))&&(s=Mt(v,a,r),_?l=c=u=m=s:h=d=p=f=s,A.push({tx1:l,ty1:h,tx2:c,ty2:d,x1:u,y1:p,x2:m,y2:f,width:r,color:o,borderDash:g,borderDashOffset:b,tickWidth:x,tickColor:S,tickBorderDash:M,tickBorderDashOffset:T}))}return this._ticksLength=S,this._borderValue=i,A}_computeLabelItems(t){let e,n,a,o,s,l,h,c,d,u,p,m=this.axis,f=this.options,g=f.position,v=f.ticks,b=this.isHorizontal(),y=this.ticks,x=v.align,w=v.crossAlign,k=v.padding,_=v.mirror,S=Xe(f.grid),M=S+k,T=_?-k:M,C=-A(this.labelRotation),z=[],O="middle";if("top"===g)s=this.bottom-T,l=this._getXAxisLabelAlignment();else if("bottom"===g)s=this.top+T,l=this._getXAxisLabelAlignment();else if("left"===g){const t=this._getYAxisLabelAlignment(S);l=t.textAlign,o=t.x}else if("right"===g){const t=this._getYAxisLabelAlignment(S);l=t.textAlign,o=t.x}else if("x"===m){if("center"===g)s=(t.top+t.bottom)/2+M;else if(r(g)){const t=Object.keys(g)[0],e=g[t];s=this.chart.scales[t].getPixelForValue(e)+M}l=this._getXAxisLabelAlignment()}else if("y"===m){if("center"===g)o=(t.left+t.right)/2-M;else if(r(g)){const t=Object.keys(g)[0],e=g[t];o=this.chart.scales[t].getPixelForValue(e)}l=this._getYAxisLabelAlignment(S).textAlign}"y"===m&&("start"===x?O="top":"end"===x&&(O="bottom"));var L=this._getLabelSizes();for(e=0,n=y.length;ee.value===t))?i.setContext(this.getContext(e)).lineWidth:0}drawGrid(t){const e=this.options.grid,i=this.ctx,r=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let n,a,o=(t,e,r)=>{r.width&&r.color&&(i.save(),i.lineWidth=r.width,i.strokeStyle=r.color,i.setLineDash(r.borderDash||[]),i.lineDashOffset=r.borderDashOffset,i.beginPath(),i.moveTo(t.x,t.y),i.lineTo(e.x,e.y),i.stroke(),i.restore())};if(e.display)for(n=0,a=r.length;n{this.drawBackground(),this.drawGrid(t),this.drawTitle()}},{z:i,draw:()=>{this.drawBorder()}},{z:t,draw:t=>{this.drawLabels(t)}}]:[{z:t,draw:t=>{this.draw(t)}}]}getMatchingVisibleMetas(t){let e,i,r=this.chart.getSortedVisibleDatasetMetas(),n=this.axis+"AxisID",a=[];for(e=0,i=r.length;e{var e=(i=t.split(".")).pop(),i=[r].concat(i).join("."),a=(t=n[t].split(".")).pop();t=t.join(".");dn.route(i,e,t,a)})),a.descriptors&&dn.describe(o,a.descriptors),this.override&&dn.override(t.id,t.overrides)),s;throw new Error("class does not have id: "+t)}get(t){return this.items[t]}unregister(t){var e=this.items,i=(t=t.id,this.scope);t in e&&delete e[t],i&&t in dn[i]&&(delete dn[i][t],this.override)&&delete hn[t]}}var ta=new class{constructor(){this.controllers=new Qn($n,"datasets",!0),this.elements=new Qn(Xn,"elements"),this.plugins=new Qn(Object,"plugins"),this.scales=new Qn(Jn,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,e,i){[...e].forEach(e=>{var r=i||this._getRegistryForType(e);i||r.isForType(e)||r===this.plugins&&e.id?this._exec(t,r,e):l(e,e=>{var r=i||this._getRegistryForType(e);this._exec(t,r,e)})})}_exec(t,e,i){var r=b(t);s(i["before"+r],[],i),e[t](i),s(i["after"+r],[],i)}_getRegistryForType(t){for(let i=0;it.filter(t=>!e.some(e=>t.plugin.id===e.plugin.id));this._notify(r(e,i),t,"stop"),this._notify(r(i,e),t,"start")}}const ia=new Map,ra=new Set,na=(t,e,i)=>{void 0!==(e=v(e,i))&&t.add(e)};class aa{constructor(t){this._config=((t=t||{}).data=ii(t.data),ei(t),t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=ii(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){var t=this._config;this.clearCache(),ei(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return ri(t,()=>[["datasets."+t,""]])}datasetAnimationScopeKeys(t,e){return ri(t+".transition."+e,()=>[[`datasets.${t}.transitions.`+e,"transitions."+e],["datasets."+t,""]])}datasetElementScopeKeys(t,e){return ri(t+"-"+e,()=>[[`datasets.${t}.elements.`+e,"datasets."+t,"elements."+e,""]])}pluginScopeKeys(t){const e=t.id;return ri(this.type+"-plugin-"+e,()=>[["plugins."+e,...t.additionalOptionScopes||[]]])}_cachedScopes(t,e){let i=this._scopeCache,r=i.get(t);return r&&!e||(r=new Map,i.set(t,r)),r}getOptionScopes(t,e,i){let r=this.options,n=this.type,a=this._cachedScopes(t,i),o=a.get(e);if(o)return o;const s=new Set;return e.forEach(e=>{t&&(s.add(t),e.forEach(e=>na(s,t,e))),e.forEach(t=>na(s,r,t)),e.forEach(t=>na(s,hn[n]||{},t)),e.forEach(t=>na(s,dn,t)),e.forEach(t=>na(s,cn,t))}),0===(i=Array.from(s)).length&&i.push(Object.create(null)),ra.has(e)&&a.set(e,i),i}chartOptionScopes(){var t=this.options,e=this.type;return[t,hn[e]||{},dn.datasets[e]||{},{type:e},dn,cn]}resolveNamedOptions(t,e,r,n=[""]){var a={$shared:!0},o=(n=(o=ni(this._resolverCache,t,n)).resolver,o.subPrefixes);let s=n;!function(t,e){var r,n=Nt(t),a=n.isScriptable,o=n.isIndexable,s=_createForOfIteratorHelper(e);try{for(s.s();!(r=s.n()).done;){var l=r.value;const e=a(l),n=o(l),s=(n||e)&&t[l];if(e&&(_r(s)||oa(s))||n&&i(s))return 1}}catch(t){s.e(t)}finally{s.f()}}(n,e)||(a.$shared=!1,s=Rt(n,r=_r(r)?r():r,this.createResolver(t,r,o)));var l,h=_createForOfIteratorHelper(e);try{for(h.s();!(l=h.n()).done;){const t=l.value;a[t]=s[t]}}catch(t){h.e(t)}finally{h.f()}return a}createResolver(t,e,i=[""],n){return t=ni(this._resolverCache,t,i).resolver,r(e)?Rt(t,e,void 0,n):t}}const oa=t=>r(t)&&Object.getOwnPropertyNames(t).some(e=>_r(t[e])),sa=["top","bottom","left","right","chartArea"],la={},ha=t=>{const e=hi(t);return Object.values(la).filter(t=>t.canvas===e).pop()};class ca{static register(...t){ta.add(...t),ci()}static unregister(...t){ta.remove(...t),ci()}constructor(t,e){if(e=this.config=new aa(e),t=hi(t),i=ha(t))throw new Error("Canvas is already in use. Chart with ID '"+i.id+"' must be destroyed before the canvas with ID '"+i.canvas.id+"' can be reused.");var i=e.createResolver(e.chartOptionScopes(),this.getContext());this.platform=new(e.platform||Ne(t)),this.platform.updateConfig(e);var r=(t=(e=this.platform.acquireContext(t,i.aspectRatio))&&e.canvas)&&t.height,n=t&&t.width;this.id=br(),this.ctx=e,this.canvas=t,this.width=n,this.height=r,this._options=i,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new ea,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=j(t=>this.update(t),i.resizeDelay||0),this._dataChanges=[],la[this.id]=this,e&&t?(qr.listen(this,"complete",si),qr.listen(this,"progress",li),this._initialize(),this.attached&&this.update()):console.error("Failed to create chart: can't acquire context from the given item")}get aspectRatio(){var t=(i=this.options).aspectRatio,i=i.maintainAspectRatio,r=this.width,n=this.height,a=this._aspectRatio;return e(t)?i&&a?a:n?r/n:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return ta}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():xt(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return At(this.canvas,this.ctx),this}stop(){return qr.stop(this),this}resize(t,e){qr.running(this)?this._resizeBeforeDraw={width:t,height:e}:this._resize(t,e)}_resize(t,e){var i=this.options,r=this.canvas,n=i.maintainAspectRatio&&this.aspectRatio;r=this.platform.getMaximumSize(r,t,e,n),t=i.devicePixelRatio||this.platform.getDevicePixelRatio(),e=this.width?"resize":"attach";this.width=r.width,this.height=r.height,this._aspectRatio=this.aspectRatio,xt(this,t,!0)&&(this.notifyPlugins("resize",{size:r}),s(i.onResize,[this,r],this),this.attached)&&this._doResize(e)&&this.render()}ensureScalesHaveIDs(){l(this.options.scales||{},(t,e)=>{t.id=e})}buildOrUpdateScales(){const t=this.options,e=t.scales,i=this.scales,r=Object.keys(i).reduce((t,e)=>(t[e]=!1,t),{});let n=[];l(n=e?n.concat(Object.keys(e).map(t=>{var i=e[t],r="r"===(t=Qe(t,i));t="x"===t;return{options:i,dposition:r?"chartArea":t?"bottom":"left",dtype:r?"radialLinear":t?"category":"linear"}})):n,e=>{var n=e.options,a=n.id,s=Qe(a,n),l=o(n.type,e.dtype);void 0!==n.position&&ai(n.position,s)===ai(e.dposition)||(n.position=e.dposition),r[a]=!0;let h=null;a in i&&i[a].type===l?h=i[a]:(h=new(ta.getScale(l))({id:a,type:l,ctx:this.ctx,chart:this}),i[h.id]=h),h.init(n,t)}),l(r,(t,e)=>{t||delete i[e]}),l(i,t=>{Pn.configure(this,t,t.options),Pn.addBox(this,t)})}_updateMetasets(){var t=this._metasets,e=this.data.datasets.length,i=t.length;if(t.sort((t,e)=>t.index-e.index),ee.length&&delete this._stacks,t.forEach((t,i)=>{0===e.filter(e=>e===t._dataset).length&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){var t,e,i,r=[],n=this.data.datasets;let a,o;for(this._removeUnreferencedMetasets(),a=0,o=n.length;a{this.getDatasetMeta(e).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){var e=((e=this.config).update(),this._options=e.createResolver(e.chartOptionScopes(),this.getContext())),i=this._animationsDisabled=!e.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),!1!==this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0})){var r=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let o=0;for(let t=0,e=this.data.datasets.length;t{t.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(oi("z","_idx")),t=this._active,(e=this._lastEvent)?this._eventHandler(e,!0):t.length&&this._updateHoverStyles(t,t,!0),this.render()}}_updateScales(){l(this.scales,t=>{Pn.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){var t=this.options,e=new Set(Object.keys(this._listeners)),i=new Set(t.events);Sr(e,i)&&!!this._responsiveListeners===t.responsive||(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){var t,e=this._hiddenIndices,i=_createForOfIteratorHelper(this._getUniformDataChanges()||[]);try{for(i.s();!(t=i.n()).done;)for(var r=t.value,n=r.method,a=r.count,o=void 0,s=void 0,l=(o=e,r.start),h="_removeElements"===n?-a:a,c=Object.keys(o),d=0,u=c;dnew Set(t.filter(t=>t[0]===e).map((t,e)=>e+","+t.splice(1).join(","))),r=i(0);for(let t=1;tt.split(",")).map(t=>({method:t[1],start:+t[2],count:+t[3]}))}}_updateLayout(t){if(!1!==this.notifyPlugins("beforeLayout",{cancelable:!0})){Pn.update(this,this.width,this.height,t);const e=this.chartArea,i=e.width<=0||e.height<=0;this._layers=[],l(this.boxes,t=>{i&&"chartArea"===t.position||(t.configure&&t.configure(),this._layers.push(...t._layers()))},this),this._layers.forEach((t,e)=>{t._idx=e}),this.notifyPlugins("afterLayout")}}_updateDatasets(t){if(!1!==this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})){for(let t=0,e=this.data.datasets.length;tt&&t._dataset===e).pop();return r||(r={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:e&&e.order||0,index:t,_dataset:e,_parsed:[],_sorted:!1},i.push(r)),r}getContext(){return this.$context||(this.$context=se(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){var e=this.data.datasets[t];return!!e&&("boolean"==typeof(t=this.getDatasetMeta(t)).hidden?!t.hidden:!e.hidden)}setDatasetVisibility(t,e){this.getDatasetMeta(t).hidden=!e}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,e,i){const r=i?"show":"hide",n=this.getDatasetMeta(t),a=n.controller._resolveAnimations(void 0,r);kr(e)?(n.data[e].hidden=!i,this.update()):(this.setDatasetVisibility(t,i),a.update(n,{visible:i}),this.update(e=>e.datasetIndex===t?r:void 0))}hide(t,e){this._updateVisibility(t,e,!1)}show(t,e){this._updateVisibility(t,e,!0)}_destroyDatasetMeta(t){var e=this._metasets[t];e&&e.controller&&e.controller._destroy(),delete this._metasets[t]}_stop(){let t,e;for(this.stop(),qr.remove(this),t=0,e=this.data.datasets.length;t{e.addEventListener(this,i,r),t[i]=r},r=(t,e,i)=>{t.offsetX=e,t.offsetY=i,this._eventHandler(t)};l(this.options.events,t=>i(t,r))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,e=this.platform,i=(i,r)=>{e.addEventListener(this,i,r),t[i]=r},r=(i,r)=>{t[i]&&(e.removeEventListener(this,i,r),delete t[i])},n=(t,e)=>{this.canvas&&this.resize(t,e)};let a;const o=()=>{r("attach",o),this.attached=!0,this.resize(),i("resize",n),i("detach",a)};a=(()=>{this.attached=!1,r("resize",n),this._stop(),this._resize(0,0),i("attach",o)}),(e.isAttached(this.canvas)?o:a)()}unbindEvents(){l(this._listeners,(t,e)=>{this.platform.removeEventListener(this,e,t)}),this._listeners={},l(this._responsiveListeners,(t,e)=>{this.platform.removeEventListener(this,e,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,e,i){let r,n,a,o=i?"set":"remove";for("dataset"===e&&this.getDatasetMeta(t[0].datasetIndex).controller["_"+o+"DatasetHoverStyle"](),n=0,a=t.length;n{var i=this.getDatasetMeta(t);if(i)return{datasetIndex:t,element:i.data[e],index:e};throw new Error("No dataset found at index "+t)}),e)||(this._active=t,this._lastEvent=null,this._updateHoverStyles(t,e))}notifyPlugins(t,e,i){return this._plugins.notify(this,t,e,i)}isPluginEnabled(t){return 1===this._plugins._cache.filter(e=>e.plugin.id===t).length}_updateHoverStyles(t,e,i){var r=this.options.hover,n=(t,e)=>t.filter(t=>!e.some(e=>t.datasetIndex===e.datasetIndex&&t.index===e.index)),a=n(e,t);i=i?t:n(t,e);a.length&&this.updateHoverStyle(a,r.mode,!1),i.length&&r.mode&&this.updateHoverStyle(i,r.mode,!0)}_eventHandler(t,e){var i={event:t,replay:e,cancelable:!0,inChartArea:this.isPointInArea(t)},r=e=>(e.options.events||this.options.events).includes(t.native.type);if(!1!==this.notifyPlugins("beforeEvent",i,r))return e=this._handleEvent(t,e,i.inChartArea),i.cancelable=!1,this.notifyPlugins("afterEvent",i,r),(e||i.changed)&&this.render(),this}_handleEvent(t,e,i){var r=void 0===(r=this._active)?[]:r,n=this.options,a=this._getActiveElements(t,r,i,e),o=y(t),l=(c=this._lastEvent,i&&"mouseout"!==t.type?o?c:t:null);i&&(this._lastEvent=null,s(n.onHover,[t,a,this],this),o)&&s(n.onClick,[t,a,this],this);var c=!h(a,r);return(c||e)&&(this._active=a,this._updateHoverStyles(a,r,e)),this._lastEvent=l,c}_getActiveElements(t,e,i,r){return"mouseout"===t.type?[]:i?(i=this.options.hover,this.getElementsAtEventForMode(t,i.mode,i,r)):e}}_defineProperty(ca,"defaults",dn),_defineProperty(ca,"instances",la),_defineProperty(ca,"overrides",hn),_defineProperty(ca,"registry",ta),_defineProperty(ca,"version","4.5.1"),_defineProperty(ca,"getChart",ha);var da={_date:class t{static override(e){Object.assign(t.prototype,e)}constructor(t){_defineProperty(this,"options",void 0),this.options=t||{}}init(){}formats(){return di()}parse(){return di()}format(){return di()}add(){return di()}diff(){return di()}startOf(){return di()}endOf(){return di()}}};class ua extends $n{constructor(t,e){super(t,e),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,e){const i=this.getDataset().data,n=this._cachedMeta;if(!1===this._parsing)n._parsed=i;else{let a,o,s=t=>+i[t];if(r(i[t])){let t=this._parsing.key,e=void 0===t?"value":t;s=(t=>+v(i[t],e))}for(o=(a=t)+e;aE(t,e,s,!0)?1:Math.max(r,r*i,n,n*i),p=(t,r,n)=>E(t,e,s,!0)?-1:Math.min(r,r*i,n,n*i),m=u(0,l,c),f=u(Or,h,d),g=p(Mr,l,c),v=p(Mr+Or,h,d);r=(m-g)/2,n=(f-v)/2,a=-(m+g)/2,o=-(f+v)/2}return{ratioX:r,ratioY:n,offsetX:a,offsetY:o}}(e.rotation,0,o)).ratioX,c=e.offsetX,d=e.offsetY;h=(i.width-a)/h,i=(i.height-a)/e.ratioY,a=Math.max(Math.min(h,i)/2,0),h=((l=xr(this.options.radius,a))-Math.max(l*o,0))/this._getVisibleDatasetWeightTotal();this.offsetX=c*l,this.offsetY=d*l,r.total=this.calculateTotal(),this.outerRadius=l-h*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-h*s,0),this.updateElements(n,0,n.length,t)}_circumference(t,e){var i=this.options,r=this._cachedMeta,n=this._getCircumference();return e&&i.animation.animateRotate||!this.chart.getDataVisibility(t)||null===r._parsed[t]||r.data[t].hidden?0:this.calculateCircumference(r._parsed[t]*n/Ar)}updateElements(t,e,i,r){let n,a="reset"===r,o=this.chart,s=o.chartArea,l=o.options.animation,h=(s.left+s.right)/2,c=(s.top+s.bottom)/2,d=a&&l.animateScale,u=d?0:this.innerRadius,p=d?0:this.outerRadius,m=this._getSharedOptions(e,r),f=m.sharedOptions,g=m.includeOptions,v=this._getRotation();for(n=0;n"spacing"!==t,_indexable:t=>"spacing"!==t&&!t.startsWith("borderDash")&&!t.startsWith("hoverBorderDash")}),_defineProperty(ua,"overrides",{aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){let e=t.data,i=t.legend.options.labels,r=i.pointStyle,n=i.textAlign,a=i.color,o=i.useBorderRadius,s=i.borderRadius;return e.labels.length&&e.datasets.length?e.labels.map((e,i)=>{var l=t.getDatasetMeta(0).controller.getStyle(i);return{text:e,fillStyle:l.backgroundColor,fontColor:a,hidden:!t.getDataVisibility(i),lineDash:l.borderDash,lineDashOffset:l.borderDashOffset,lineJoin:l.borderJoinStyle,lineWidth:l.borderWidth,strokeStyle:l.borderColor,textAlign:n,pointStyle:r,borderRadius:o&&(s||l.borderRadius),index:i}}):[]}},onClick(t,e,i){i.chart.toggleDataVisibility(e.index),i.chart.update()}}}});class pa extends $n{constructor(t,e){super(t,e),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(t){var e=this._cachedMeta,i=this.chart,r=i.data.labels||[];e=ct(e._parsed[t].r,i.options.locale);return{label:r[t]||"",value:e}}parseObjectData(t,e,i,r){return Ut.bind(this)(t,e,i,r)}update(t){var e=this._cachedMeta.data;this._updateRadius(),this.updateElements(e,0,e.length,t)}getMinMax(){const t=this._cachedMeta,e={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY};return t.data.forEach((t,i)=>{var r=this.getParsed(i).r;!isNaN(r)&&this.chart.getDataVisibility(i)&&(re.max)&&(e.max=r)}),e}_updateRadius(){var t=this.chart,e=t.chartArea,i=t.options;e=Math.min(e.right-e.left,e.bottom-e.top),i=((e=Math.max(e/2,0))-Math.max(i.cutoutPercentage?e/100*i.cutoutPercentage:1,0))/t.getVisibleDatasetCount();this.outerRadius=e-i*this.index,this.innerRadius=this.outerRadius-i}updateElements(t,e,i,r){let n,a="reset"===r,o=this.chart,s=o.options.animation,l=this._cachedMeta.rScale,h=l.xCenter,c=l.yCenter,d=l.getIndexAngle(0)-.5*Mr,u=d,p=360/this.countVisibleElements();for(n=0;n{!isNaN(this.getParsed(i).r)&&this.chart.getDataVisibility(i)&&e++}),e}_computeAngle(t,e,i){return this.chart.getDataVisibility(t)?A(this.resolveDataElementOptions(t,e).angle||i):0}}_defineProperty(pa,"id","polarArea"),_defineProperty(pa,"defaults",{dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0}),_defineProperty(pa,"overrides",{aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){var e=t.data;if(e.labels.length&&e.datasets.length){let i=t.legend.options.labels,r=i.pointStyle,n=i.color;return e.labels.map((e,i)=>{var a=t.getDatasetMeta(0).controller.getStyle(i);return{text:e,fillStyle:a.backgroundColor,strokeStyle:a.borderColor,fontColor:n,lineWidth:a.borderWidth,pointStyle:r,hidden:!t.getDataVisibility(i),index:i}})}return[]}},onClick(t,e,i){i.chart.toggleDataVisibility(e.index),i.chart.update()}}},scales:{r:{type:"radialLinear",angleLines:{ display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}});var ma=Object.freeze({__proto__:null,BarController:(_defineProperty(ma=class extends $n{parsePrimitiveData(t,e,i,r){return pi(t,e,i,r)}parseArrayData(t,e,i,r){return pi(t,e,i,r)}parseObjectData(t,e,i,r){var n,a=t.iScale,o=t.vScale,s=(t=void 0===(n=(s=this._parsing).xAxisKey)?"x":n,void 0===(n=s.yAxisKey)?"y":n),l="x"===a.axis?t:s,h="x"===o.axis?t:s,c=[];let d,u,p,m;for(u=(d=i)+r;dt.controller.options.grouped),o=n.options.stacked,s=[],l=this._cachedMeta.controller.getParsed(i),h=l&&l[n.axis],c=t=>{var i=t._parsed.find(t=>t[n.axis]===h);if(e(i=i&&i[t.vScale.axis])||isNaN(i))return!0},d=_createForOfIteratorHelper(a);try{for(d.s();!(r=d.n()).done;){const e=r.value;if((void 0===i||!c(e))&&((!1===o||-1===s.indexOf(e.stack)||void 0===o&&void 0===e.stack)&&s.push(e.stack),e.index===t))break}}catch(t){d.e(t)}finally{d.f()}return s.length||s.push(void 0),s}_getStackCount(t){return this._getStacks(void 0,t).length}_getAxisCount(){return this._getAxis().length}getFirstScaleIdForIndexAxis(){const t=this.chart.scales,e=this.chart.options.indexAxis;return Object.keys(t).filter(i=>t[i].axis===e).shift()}_getAxis(){var t,e={},i=this.getFirstScaleIdForIndexAxis(),r=_createForOfIteratorHelper(this.chart.data.datasets);try{for(r.s();!(t=r.n()).done;){var n=t.value;e[o("x"===this.chart.options.indexAxis?n.xAxisID:n.yAxisID,i)]=!0}}catch(t){r.e(t)}finally{r.f()}return Object.keys(e)}_getStackIndex(t,e,i){return t=this._getStacks(t,i),-1===(i=void 0!==e?t.indexOf(e):-1)?t.length-1:i}_getRuler(){let t,e,i=this.options,r=this._cachedMeta,n=r.iScale,a=[];for(t=0,e=r.data.length;tt-e))}return e._cache.$bar}(a),s=a._length,l=()=>{32767!==r&&-32768!==r&&(kr(n)&&(s=Math.min(s,Math.abs(r-n)||s)),n=r)};for(e=0,i=o.length;e=y?1:-1))*c,f===d&&(w-=r/2);const t=a.getPixelForDecimal(0),e=a.getPixelForDecimal(1),n=Math.min(t,e),l=Math.max(t,e);i=(w=Math.max(Math.min(w,l),n))+r,o&&!m&&(u._stacks[a.axis]._visualValues[s]=a.getValueForPixel(i)-a.getValueForPixel(w))}if(w===a.getPixelForValue(d)){const t=Ir(r)*a.getLineWidthForValue(d)/2;w+=t,r-=t}return{size:r,base:w,head:i,center:i+r/2}}_calculateBarIndexPixels(t,i){const r=i.scale,n=this.options,a=n.skipNull,s=o(n.maxBarThickness,1/0);let l,h,c=this._getAxisCount();if(i.grouped){const r=a?this._getStackCount(t):i.stackCount,d=("flex"===n.barThickness?function(t,e,i,r){let n=e.pixels,a=n[t],o=0=w?d.skip=!0:(A=e((M=this.getParsed(r))[f]),T=d[m]=s.getPixelForValue(M[m],r),C=d[f]=a||A?l.getBasePixel():l.getPixelForValue(h?this.applyStack(l,M,h):M[f],r),d.skip=isNaN(T)||isNaN(C)||A,d.stop=0y,b&&(d.parsed=M,d.raw=c.data[r]),p&&(d.options=u||this.resolveDataElementOptions(r,o.active?"active":n)),x||this.updateElement(o,r,d,n),S=M)}}getMaxOverflow(){var t,e=this._cachedMeta,i=(i=e.dataset).options&&i.options.borderWidth||0;return(e=e.data||[]).length?(t=e[0].size(this.resolveDataElementOptions(0)),e=e[e.length-1].size(this.resolveDataElementOptions(e.length-1)),Math.max(i,t,e)/2):i}draw(){var t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}},"id","line"),_defineProperty(ma,"defaults",{datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1}),_defineProperty(ma,"overrides",{scales:{_index_:{type:"category"},_value_:{type:"linear"}}}),ma),PieController:(_defineProperty(ma=class extends ua{},"id","pie"),_defineProperty(ma,"defaults",{cutout:0,rotation:0,circumference:360,radius:"100%"}),ma),PolarAreaController:pa,RadarController:(_defineProperty(ma=class extends $n{getLabelAndValue(t){var e=this._cachedMeta.vScale,i=this.getParsed(t);return{label:e.getLabels()[t],value:""+e.getLabelForValue(i[e.axis])}}parseObjectData(t,e,i,r){return Ut.bind(this)(t,e,i,r)}update(t){const e=this._cachedMeta,i=e.dataset,r=e.data||[],n=e.iScale.getLabels();if(i.points=r,"resize"!==t){const e=this.resolveDatasetElementOptions(t);this.options.showLine||(e.borderWidth=0);var a={_loop:!0,_fullLoop:n.length===r.length,options:e};this.updateElement(i,void 0,a,t)}this.updateElements(r,0,r.length,t)}updateElements(t,e,i,r){var n=this._cachedMeta.rScale,a="reset"===r;for(let o=e;oy,b&&(d.parsed=r,d.raw=c.data[o]),p&&(d.options=u||this.resolveDataElementOptions(o,i.active?"active":n)),x||this.updateElement(i,o,d,n),w=r}this.updateSharedOptions(u,n,d)}getMaxOverflow(){var t,e,i=this._cachedMeta,r=i.data||[];if(this.options.showLine)return i=(i=i.dataset).options&&i.options.borderWidth||0,r.length?(t=r[0].size(this.resolveDataElementOptions(0)),e=r[r.length-1].size(this.resolveDataElementOptions(r.length-1)),Math.max(i,t,e)/2):i;{let t=0;for(let e=r.length-1;0<=e;--e)t=Math.max(t,r[e].size(this.resolveDataElementOptions(e))/2);return 0"borderDash"!==t&&"fill"!==t});var va=Object.freeze({__proto__:null,ArcElement:(_defineProperty(va=class extends Xn{constructor(t){super(),_defineProperty(this,"circumference",void 0),_defineProperty(this,"endAngle",void 0),_defineProperty(this,"fullCircles",void 0),_defineProperty(this,"innerRadius",void 0),_defineProperty(this,"outerRadius",void 0),_defineProperty(this,"pixelMargin",void 0),_defineProperty(this,"startAngle",void 0),this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,t&&Object.assign(this,t)}inRange(t,e,i){t=(l=z(this.getProps(["x","y"],i),{x:t,y:e})).angle,e=l.distance,i=(l=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],i)).startAngle;var r=l.innerRadius,n=l.outerRadius,a=(this.options.spacing+this.options.borderWidth)/2,s=o(l.circumference,(l=l.endAngle)-i),l=(t=E(t,i,l)&&i!==l,i=s>=Ar||t,B(e,r+a,n+a));return i&&l}getCenterPoint(t){t=(a=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius"],t)).x;var e=a.y,i=this.options,r=i.offset,n=(a.startAngle+a.endAngle)/2,a=(a.innerRadius+a.outerRadius+i.spacing+r)/2;return{x:t+Math.cos(n)*a,y:e+Math.sin(n)*a}}tooltipPosition(t){return this.getCenterPoint(t)}draw(t){var e=this.options,i=this.circumference,r=(e.offset||0)/4,n=(e.spacing||0)/2,a=e.circular;if(this.pixelMargin="inner"===e.borderAlign?.33:0,this.fullCircles=i>Ar?Math.floor(i/Ar):0,!(0===i||this.innerRadius<0||this.outerRadius<0)){t.save();var o=(this.startAngle+this.endAngle)/2;o=(t.translate(Math.cos(o)*r,Math.sin(o)*r),r*(1-Math.sin(Math.min(Mr,i||0))));t.fillStyle=e.backgroundColor,t.strokeStyle=e.borderColor;{var s=t,l=(i=o,e=n,a),h=(d=r=this).fullCircles,c=d.startAngle,d=d.circumference;let u=r.endAngle;if(h){bi(s,r,i,e,u,l);for(let t=0;t=Mr&&0===f&&"miter"!==a){var v=u,b=this,y=t,x=b.startAngle,w=(g=b.x,b.y);l=b.outerRadius,n=b.innerRadius,m=(c=b.options).borderWidth,o=c.borderJoinStyle,e=Math.min(m/l,P(x-y));if(v.beginPath(),v.arc(g,w,l-m/2,x+e/2,y-e/2),0"borderDash"!==t}),va),BarElement:(_defineProperty(va=class extends Xn{constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,t&&Object.assign(this,t)}draw(t){var e,i,n,a,o,s,l=this.inflateAmount,h=(c=this.options).borderColor,c=c.backgroundColor,d=(p=(n=(i=Ai(this)).right-i.left)/2,o=(a=i.bottom-i.top)/2,s=this.options.borderWidth,d=this.borderSkipped,s=ee(s),o={t:Ti(d.top,s.top,0,o),r:Ti(d.right,s.right,0,p),b:Ti(d.bottom,s.bottom,0,o),l:Ti(d.left,s.left,0,p)},d=n/2,s=a/2,e=(p=this).getProps(["enableBorderRadius"]).enableBorderRadius,m=ie(u=p.options.borderRadius),d=Math.min(d,s),s=p.borderSkipped,e={topLeft:Ti(!(p=e||r(u))||s.top||s.left,m.topLeft,0,d),topRight:Ti(!p||s.top||s.right,m.topRight,0,d),bottomLeft:Ti(!p||s.bottom||s.left,m.bottomLeft,0,d),bottomRight:Ti(!p||s.bottom||s.right,m.bottomRight,0,d)},{outer:{x:i.left,y:i.top,w:n,h:a,radius:e},inner:{x:i.left+o.l,y:i.top+o.t,w:n-o.l-o.r,h:a-o.t-o.b,radius:{topLeft:Math.max(0,e.topLeft-Math.max(o.t,o.l)),topRight:Math.max(0,e.topRight-Math.max(o.t,o.r)),bottomLeft:Math.max(0,e.bottomLeft-Math.max(o.b,o.l)),bottomRight:Math.max(0,e.bottomRight-Math.max(o.b,o.r))}}}),u=d.inner,p=d.outer,m=(s=p.radius).topLeft||s.topRight||s.bottomLeft||s.bottomRight?Dt:zi;t.save(),p.w===u.w&&p.h===u.h||(t.beginPath(),m(t,Oi(p,l,u)),t.clip(),m(t,Oi(u,-l,p)),t.fillStyle=h,t.fill("evenodd")),t.beginPath(),m(t,Oi(u,l)),t.fillStyle=c,t.fill(),t.restore()}inRange(t,e,i){return Ci(this,t,e,i)}inXRange(t,e){return Ci(this,t,null,e)}inYRange(t,e){return Ci(this,null,t,e)}getCenterPoint(t){t=(e=this.getProps(["x","y","base","horizontal"],t)).x;var e,i=e.y,r=e.base;return{x:(e=e.horizontal)?(t+r)/2:t,y:e?i:(i+r)/2}}getRange(t){return"x"===t?this.width/2:this.height/2}},"id","bar"),_defineProperty(va,"defaults",{borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0}),_defineProperty(va,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"}),va),LineElement:ga,PointElement:(_defineProperty(va=class extends Xn{constructor(t){super(),_defineProperty(this,"parsed",void 0),_defineProperty(this,"skip",void 0),_defineProperty(this,"stop",void 0),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,t&&Object.assign(this,t)}inRange(t,e,i){var r=this.options,n=(i=(n=this.getProps(["x","y"],i)).x,n.y);return Math.pow(t-i,2)+Math.pow(e-n,2)a=r?a:t,l=t=>o=n?o:t;if(e){const t=Ir(a),e=Ir(o);t<0&&e<0?l(0):0m&&(A=w(M*A/m/p)*p),e(l)||(y=Math.pow(10,l),A=Math.ceil(A*y)/y),_="ticks"===n?(k=Math.floor(i/A)*A,Math.ceil(f/A)*A):(k=i,f),g&&v&&a&&S((s-o)/a,A/1e3)?(A=(s-o)/(M=Math.round(Math.min((s-o)/A,c))),k=o,_=s):b?A=((_=v?s:_)-(k=g?o:k))/(M=h-1):M=x(M=(_-k)/A,Math.round(M),A/1e3)?Math.round(M):Math.ceil(M),m=Math.max(C(A),C(k)),y=Math.pow(10,e(l)?m:l),k=Math.round(k*y)/y,_=Math.round(_*y)/y;let T=0;for(g&&(u&&k!==o?(r.push({value:o}),ks)break;r.push({value:t})}return v&&u&&_!==s?r.length&&x(r[r.length-1].value,s,Pi(s,d,t))?r[r.length-1].value=s:r.push({value:s}):v&&_!==s||r.push({value:_}),r}({maxTicks:Math.max(2,r),bounds:t.bounds,min:t.min,max:t.max,precision:i.precision,step:i.stepSize,count:i.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:i.minRotation||0,includeBounds:!1!==i.includeBounds},this._range||this);return"ticks"===t.bounds&&M(r,this,"value"),t.reverse?(r.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),r}configure(){let t=this.ticks,e=this.min,i=this.max;super.configure(),this.options.offset&&t.length&&(e-=t=(i-e)/Math.max(t.length-1,1)/2,i+=t),this._startValue=e,this._endValue=i,this._valueRange=i-e}getLabelForValue(t){return ct(t,this.chart.options.locale,this.options.ticks.format)}}class ya extends ba{determineDataLimits(){var t=(e=this.getMinMax(!0)).min,e=e.max;this.min=n(t)?t:0,this.max=n(e)?e:1,this.handleTickRangeOptions()}computeTickLimit(){var t=(i=this.isHorizontal())?this.width:this.height,e=A(this.options.ticks.minRotation),i=(i?Math.sin(e):Math.cos(e))||.001;e=this._resolveTickFontOptions(0);return Math.ceil(t/Math.min(40,e.lineHeight/i))}getPixelForValue(t){return null===t?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}_defineProperty(ya,"id","linear"),_defineProperty(ya,"defaults",{ticks:{callback:ln.formatters.numeric}});const xa=t=>Math.floor(Er(t)),wa=(t,e)=>Math.pow(10,xa(t)+e);class ka extends Jn{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0}parse(t,e){if(0!==(t=ba.prototype.parse.apply(this,[t,e])))return n(t)&&0r=e?r:t,o=t=>n=i?n:t;r===n&&(r<=0?(a(1),o(10)):(a(wa(r,-1)),o(wa(n,1)))),r<=0&&a(wa(n,-1)),n<=0&&o(wa(r,1)),this.min=r,this.max=n}buildTicks(){var t=this.options,e=function(t,{min:e,max:i}){e=a(t.min,e);var r=[],n=xa(e);let o=function(t,e){let i=xa(e-t);for(;10o?Math.pow(10,n):0,c=(n=Math.round((e-h)*s)/s,Math.floor((e-h)/l/10)*l*10);let d=Math.floor((n-c)/Math.pow(10,o)),u=a(t.min,Math.round((h+c+d*Math.pow(10,o))*s)/s);for(;u(t=s(this.options.pointLabels.callback,[t,e],this))||0===t?t:"").filter((t,e)=>this.chart.getDataVisibility(e))}fit(){var t=this.options;t.display&&t.pointLabels.display?Ri(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(t,e,i,r){this.xCenter+=Math.floor((t-e)/2),this.yCenter+=Math.floor((i-r)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(t,e,i,r))}getIndexAngle(t){return P(t*(Ar/(this._pointLabels.length||1))+A(this.options.startAngle||0))}getDistanceFromCenterForValue(t){var i;return e(t)?NaN:(i=this.drawingArea/(this.max-this.min),this.options.reverse?(this.max-t)*i:(t-this.min)*i)}getValueForDistanceFromCenter(t){return e(t)?NaN:(t/=this.drawingArea/(this.max-this.min),this.options.reverse?this.max-t:this.min+t)}getPointLabelContext(t){var e=this._pointLabels||[];if(0<=t&&t0!==t)?(f.beginPath(),Dt(f,{x:g,y:p,w:x,h:b,radius:t}),f.fill()):f.fillRect(g,p,x,b)}v=ne(m.font),w=i.x,y=i.y,f=i.textAlign,It(d,this._pointLabels[t],w,y+v.lineHeight/2,v,{color:m.color,textAlign:f,textBaseline:"middle"})}}}if(s.display&&this.ticks.forEach((t,e)=>{var r,n,a,o,c;(0!==e||0===e&&this.min<0)&&(i=this.getDistanceFromCenterForValue(t.value),t=this.getContext(e),e=s.setContext(t),t=l.setContext(t),r=i,n=h,a=this.ctx,o=e.circular,e=(c=e).color,c=c.lineWidth,!o&&!n||!e||!c||r<0||(a.save(),a.strokeStyle=e,a.lineWidth=c,a.setLineDash(t.dash||[]),a.lineDashOffset=t.dashOffset,a.beginPath(),Ni(this,r,o,n),a.closePath(),a.stroke(),a.restore()))}),o.display){for(n.save(),t=h-1;0<=t;t--){var k=o.setContext(this.getPointLabelContext(t)),_=k.color,S=k.lineWidth;S&&_&&(n.lineWidth=S,n.strokeStyle=_,n.setLineDash(k.borderDash),n.lineDashOffset=k.borderDashOffset,i=this.getDistanceFromCenterForValue(a.reverse?this.min:this.max),r=this.getPointPosition(t,i),n.beginPath(),n.moveTo(this.xCenter,this.yCenter),n.lineTo(r.x,r.y),n.stroke())}n.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,e=this.options,i=e.ticks;if(i.display){let r,n,a=this.getIndexAngle(0);t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(a),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((a,o)=>{if(!(0===o&&0<=this.min)||e.reverse){var s=i.setContext(this.getContext(o)),l=ne(s.font);if(r=this.getDistanceFromCenterForValue(this.ticks[o].value),s.showLabelBackdrop){t.font=l.string,n=t.measureText(a.label).width,t.fillStyle=s.backdropColor;const e=re(s.backdropPadding);t.fillRect(-n/2-e.left,-r-l.size/2-e.top,n+e.width,l.size+e.height)}It(t,a.label,0,-r,l,{color:s.color,strokeColor:s.textStrokeColor,strokeWidth:s.textStrokeWidth})}}),t.restore()}}drawTitle(){}}_defineProperty(_a,"id","radialLinear"),_defineProperty(_a,"defaults",{display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:ln.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback:t=>t,padding:5,centerPointLabels:!1}}),_defineProperty(_a,"defaultRoutes",{"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"}),_defineProperty(_a,"descriptors",{angleLines:{_fallback:"grid"}});const Sa={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Ma=Object.keys(Sa);class Aa extends Jn{constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,e={}){var i=t.time||(t.time={}),r=this._adapter=new da._date(t.adapters.date);r.init(e),m(i.displayFormats,r.formats()),this._parseOpts={parser:i.parser,round:i.round,isoWeekday:i.isoWeekday},super.init(t),this._normalized=e.normalized}parse(t,e){return void 0===t?null:Hi(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){function t(t){l||isNaN(t.min)||(o=Math.min(o,t.min)),h||isNaN(t.max)||(s=Math.max(s,t.max))}let e=this.options,i=this._adapter,r=e.time.unit||"day",a=this.getUserBounds(),o=a.min,s=a.max,l=a.minDefined,h=a.maxDefined;l&&h||(t(this._getLabelBounds()),"ticks"===e.bounds&&"labels"===e.ticks.source)||t(this.getMinMax(!1)),o=n(o)&&!isNaN(o)?o:+i.startOf(Date.now(),r),s=n(s)&&!isNaN(s)?s:+i.endOf(Date.now(),r)+1,this.min=Math.min(o,s-1),this.max=Math.max(o+1,s)}_getLabelBounds(){let t=this.getLabelTimestamps(),e=Number.POSITIVE_INFINITY,i=Number.NEGATIVE_INFINITY;return t.length&&(e=t[0],i=t[t.length-1]),{min:e,max:i}}buildTicks(){var t=this.options,e=t.time,i=t.ticks,r="labels"===i.source?this.getLabelTimestamps():this._generate(),n=("ticks"===t.bounds&&r.length&&(this.min=this._userMin||r[0],this.max=this._userMax||r[r.length-1]),this.min),a=N(r,n,this.max);return this._unit=e.unit||(i.autoSkip?Vi(e.minUnit,this.min,this.max,this._getLabelCapacity(n)):function(t,e,i,r,n){for(let a=Ma.length-1;a>=Ma.indexOf(i);a--){const i=Ma[a];if(Sa[i].common&&t._adapter.diff(n,r,i)>=e-1)return i}return Ma[i?Ma.indexOf(i):0]}(this,a.length,e.minUnit,this.min,this.max)),this._majorUnit=i.major.enabled&&"year"!==this._unit?function(t){for(let e=Ma.indexOf(t)+1,i=Ma.length;e+t.value))}initOffsets(t=[]){let e,i,r=0,n=0;this.options.offset&&t.length&&(e=this.getDecimalForValue(t[0]),r=1===t.length?1-e:(this.getDecimalForValue(t[1])-e)/2,i=this.getDecimalForValue(t[t.length-1]),n=1===t.length?i:(i-this.getDecimalForValue(t[t.length-2]))/2),r=I(r,0,t=t.length<3?.5:.25),n=I(n,0,t),this._offsets={start:r,end:n,factor:1/(r+1+n)}}_generate(){var t=this._adapter,e=this.min,i=this.max,r=this.options,n=r.time,a=n.unit||Vi(n.minUnit,e,i,this._getLabelCapacity(e)),s=o(r.ticks.stepSize,1),l=_(n="week"===a&&n.isoWeekday)||!0===n,h={};let c,d,u=e;if(l&&(u=+t.startOf(u,"isoWeek",n)),u=+t.startOf(u,l?"day":a),t.diff(i,e,a)>1e5*s)throw new Error(e+" and "+i+" are too far apart with stepSize of "+s+" "+a);var p="data"===r.ticks.source&&this.getDataTimestamps();for(c=u,d=0;c+t)}getLabelForValue(t){var e=this._adapter,i=this.options.time;return i.tooltipFormat?e.format(t,i.tooltipFormat):e.format(t,i.displayFormats.datetime)}format(t,e){var i=this.options.time.displayFormats,r=this._unit;e=e||i[r];return this._adapter.format(t,e)}_tickFormatFunction(t,e,i,r){var n,a=this.options,o=a.ticks.callback;return o?s(o,[t,e,i],this):(o=a.time.displayFormats,a=this._unit,n=this._majorUnit,a=a&&o[a],o=n&&o[n],i=i[e],e=n&&o&&i&&i.major,this._adapter.format(t,r||(e?o:a)))}generateTickLabels(t){let e,i,r;for(e=0,i=t.length;ee.length-1?null:this.getPixelForValue(e[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}},"id","category"),_defineProperty(Ta,"defaults",{ticks:{callback:Li}}),Ta),LinearScale:ya,LogarithmicScale:ka,RadialLinearScale:_a,TimeScale:Aa,TimeSeriesScale:(_defineProperty(Ta=class extends Aa{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){var t=this._getTimestampsForTable(),e=this._table=this.buildLookupTable(t);this._minPos=Wi(e,this.min),this._tableRange=Wi(e,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){let e,i,r,n,a,o=this.min,s=this.max,l=[],h=[];for(e=0,i=t.length;e=o&&n<=s&&l.push(n);if(l.length<2)return[{time:o,pos:0},{time:s,pos:1}];for(e=0,i=l.length;et-e)}_getTimestampsForTable(){var t,e,i=this._cache.all||[];return i.length||(t=this.getDataTimestamps(),e=this.getLabelTimestamps(),i=t.length&&e.length?this.normalize(t.concat(e)):t.length?t:e,i=this._cache.all=i),i}getDecimalForValue(t){return(Wi(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){var e=this._offsets;t=this.getDecimalForPixel(t)/e.factor-e.end;return Wi(this._table,t*this._tableRange+this._minPos,!0)}},"id","timeseries"),_defineProperty(Ta,"defaults",Aa.defaults),Ta)});const Ca=["rgb(54, 162, 235)","rgb(255, 99, 132)","rgb(255, 159, 64)","rgb(255, 205, 86)","rgb(75, 192, 192)","rgb(153, 102, 255)","rgb(201, 203, 207)"],za=Ca.map(t=>t.replace("rgb(","rgba(").replace(")",", 0.5)"));var Oa={id:"colors",defaults:{enabled:!0,forceOverride:!1},beforeLayout(t,e,i){var r,n,a;i.enabled&&(r=(n=t.config).data.datasets,a=(n=n.options).elements,n=Yi(r)||n&&(n.borderColor||n.backgroundColor)||a&&Yi(a)||"rgba(0,0,0,0.1)"!==dn.borderColor||"rgba(0,0,0,0.1)"!==dn.backgroundColor,!i.forceOverride&&n||(a=function(t){let e=0;return(i,r)=>{var n,a,o;(r=t.getDatasetMeta(r).controller)instanceof ua?(o=e,(a=i).backgroundColor=a.data.map(()=>Ui(o++)),e=o):r instanceof pa?(n=e,(a=i).backgroundColor=a.data.map(()=>Gi(n++)),e=n):r&&(r=i,i=e,r.borderColor=Ui(i),r.backgroundColor=Gi(i),e=++i)}}(t),r.forEach(a)))}},La={id:"decimation",defaults:{algorithm:"min-max",enabled:!1},beforeElementsUpdate:(t,i,r)=>{if(r.enabled){const i=t.width;t.data.datasets.forEach((n,a)=>{var o=n._data,s=n.indexAxis,l=t.getDatasetMeta(a),h=o||n.data;if("y"!==ae([s,t.options.indexAxis])&&l.controller.supportsDecimation&&("linear"===(a=t.scales[l.xAxisID]).type||"time"===a.type)&&!t.options.parsing){var c=(s=function(t){let e,i=t.length,r=0,n=l.iScale,a=n.getUserBounds(),o=a.min,s=a.max,h=a.minDefined,c=a.maxDefined;return h&&(r=I(Dr(t,n.axis,o).lo,0,i-1)),{start:r,count:e=c?I(Dr(t,n.axis,s).hi+1,r,i)-r:i-r}}(h)).start,d=s.count;if(d<=(r.threshold||4*i))$i(n);else{let t;switch(e(o)&&(n._data=h,delete n.data,Object.defineProperty(n,"data",{configurable:!0,enumerable:!0,get:function(){return this._decimated},set:function(t){this._data=t}})),r.algorithm){case"lttb":t=function(t,e,i,n){var a=r.samples||n;if(i<=a)return t.slice(e,e+i);let o=[],s=(i-2)/(a-2),l=0;const h=e+i-1;let c,d,u,p,m,f=e;for(o[l++]=t[f],c=0;cu&&(u=p,d=t[r],m=r);o[l++]=d,f=m}return o[l++]=t[h],o}(h,c,d,i);break;case"min-max":t=function(t,i,r,n){let a,o,s,l,h,c,d,u,p,m,f=0,g=0,v=[],b=t[i].x,y=t[i+r-1].x-b;for(a=i;am&&(m=l,d=a),f=(g*f+o.x)/++g;else{const r=a-1;if(!e(c)&&!e(d)){const e=Math.min(c,d),i=Math.max(c,d);e!==u&&e!==r&&v.push(_objectSpread(_objectSpread({},t[e]),{},{x:f})),i!==u&&i!==r&&v.push(_objectSpread(_objectSpread({},t[i]),{},{x:f}))}0{let i=t.boxHeight,r=void 0===i?e:i,n=t.boxWidth,a=void 0===n?e:n;return t.usePointStyle&&(r=Math.min(r,e),a=t.pointStyleWidth||Math.min(a,e)),{boxWidth:a,boxHeight:r,itemHeight:Math.max(e,r)}};class Da extends Xn{constructor(t){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,e,i){this.maxWidth=t,this.maxHeight=e,this._margins=i,this.setDimensions(),this.buildLabels(),this.fit()}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height)}buildLabels(){const t=this.options.labels||{};let e=s(t.generateLabels,[this.chart],this)||[];t.filter&&(e=e.filter(e=>t.filter(e,this.chart.data))),t.sort&&(e=e.sort((e,i)=>t.sort(e,i,this.chart.data))),this.options.reverse&&e.reverse(),this.legendItems=e}fit(){var t=this.options,e=this.ctx;if(t.display){var i=ne((a=t.labels).font),r=i.size,n=this._computeTitleHeight(),a=(o=Ia(a,r)).boxWidth,o=o.itemHeight;let s,l;e.font=i.string,this.isHorizontal()?(s=this.maxWidth,l=this._fitRows(n,r,a,o)+10):(l=this.maxHeight,s=this._fitCols(n,i,a,o)+10),this.width=Math.min(s,t.maxWidth||this.maxWidth),this.height=Math.min(l,t.maxHeight||this.maxHeight)}else this.width=this.height=0}_fitRows(t,e,i,r){let n=this.ctx,a=this.maxWidth,o=this.options.labels.padding,s=this.legendHitBoxes=[],l=this.lineWidths=[0],h=r+o,c=t,d=(n.textAlign="left",n.textBaseline="middle",-1),u=-h;return this.legendItems.forEach((t,p)=>{t=i+e/2+n.measureText(t.text).width,(0===p||l[l.length-1]+t+2*o>a)&&(c+=h,l[l.length-(0{var f=e,g=n,v=t,b=r,y=(t=(b={itemWidth:function(t,e,i){let r=v.text;return r&&"string"!=typeof r&&(r=r.reduce((t,e)=>t.length>e.length?t:e)),t+e.size/2+i.measureText(r).width}(y=i,f,g),itemHeight:(g=f.lineHeight,f=b,"string"!=typeof v.text?sr(v,g):f)}).itemWidth,b.itemHeight);0h&&(c+=d+o,l.push({width:d,height:u}),p+=d+o,m++,d=u=0),s[a]={left:p,top:u,col:m,width:t,height:y},d=Math.max(d,t),u+=y+o}),c+=d,l.push({width:d,height:u}),c}adjustHitBoxes(){if(this.options.display){var t=this._computeTitleHeight(),e=this.legendHitBoxes,i=this.options,r=i.align,n=i.labels.padding,a=le(i.rtl,this.left,this.width);if(this.isHorizontal()){let s,l=0,h=Hr(r,this.left+n,this.right-this.lineWidths[l]),c=_createForOfIteratorHelper(e);try{for(c.s();!(s=c.n()).done;){var o=s.value;l!==o.row&&(l=o.row,h=Hr(r,this.left+n,this.right-this.lineWidths[l])),o.top+=this.top+t+n,o.left=a.leftForLtr(a.x(h),o.width),h+=o.width+n}}catch(i){c.e(i)}finally{c.f()}}else{let o,l=0,h=Hr(r,this.top+t+n,this.bottom-this.columnSizes[l].height),c=_createForOfIteratorHelper(e);try{for(c.s();!(o=c.n()).done;){var s=o.value;s.col!==l&&(l=s.col,h=Hr(r,this.top+t+n,this.bottom-this.columnSizes[l].height)),s.top=h,s.left+=this.left+n,s.left=a.leftForLtr(a.x(s.left),s.width),h+=s.height+n}}catch(i){c.e(i)}finally{c.f()}}}}isHorizontal(){return"top"===this.options.position||"bottom"===this.options.position}draw(){var t;this.options.display&&(Ot(t=this.ctx,this),this._draw(),Lt(t))}_draw(){let t,e=this.options,i=this.columnSizes,r=this.lineWidths,n=this.ctx,a=e.align,s=e.labels,l=dn.color,h=le(e.rtl,this.left,this.width),c=ne(s.font),d=s.padding,u=c.size,p=u/2,m=(this.drawTitle(),n.textAlign=h.textAlign("left"),n.textBaseline="middle",n.lineWidth=.5,n.font=c.string,Ia(s,u)),f=m.boxWidth,g=m.boxHeight,v=m.itemHeight,b=this.isHorizontal(),y=this._computeTitleHeight();t=b?{x:Hr(a,this.left+d,this.right-r[0]),y:this.top+d+y,line:0}:{x:this.left+d,y:Hr(a,this.top+y+d,this.bottom-i[0].height),line:0},he(this.ctx,e.textDirection);const x=v+d;this.legendItems.forEach((m,w)=>{n.strokeStyle=m.fontColor,n.fillStyle=m.fontColor;var k=n.measureText(m.text).width,_=h.textAlign(m.textAlign||(m.textAlign=s.textAlign));k=f+p+k;let S=t.x,M=t.y;h.setWidth(this.width),b?0this.right&&(M=t.y+=x,t.line++,S=t.x=Hr(a,this.left+d,this.right-r[t.line])):0this.bottom&&(S=t.x=S+i[t.line].width+d,t.line++,M=t.y=Hr(a,this.top+y+d,this.bottom-i[t.line].height));w=h.x(S);var A=M,T=m;if(!(isNaN(f)||f<=0||isNaN(g)||g<0)){n.save();var C=o(T.lineWidth,1);if(n.fillStyle=o(T.fillStyle,l),n.lineCap=o(T.lineCap,"butt"),n.lineDashOffset=o(T.lineDashOffset,0),n.lineJoin=o(T.lineJoin,"miter"),n.lineWidth=C,n.strokeStyle=o(T.strokeStyle,l),n.setLineDash(o(T.lineDash,[])),s.usePointStyle){const t={radius:g*Math.SQRT2/2,pointStyle:T.pointStyle,rotation:T.rotation,borderWidth:C},e=h.xPlus(w,f/2);Ct(n,t,e,A+p,s.pointStyleWidth&&f)}else{const t=A+Math.max((u-g)/2,0),e=h.leftForLtr(w,f),i=ie(T.borderRadius);n.beginPath(),Object.values(i).some(t=>0!==t)?Dt(n,{x:e,y:t,w:f,h:g,radius:i}):n.rect(e,t,f,g),n.fill(),0!==C&&n.stroke()}n.restore()}if(S=Vr(_,S+f+p,b?S+k:this.right,e.rtl),A=h.x(S),w=M,It(n,(T=m).text,A,w+v/2,c,{strikethrough:T.hidden,textAlign:h.textAlign(T.textAlign)}),b)t.x+=k+d;else if("string"!=typeof m.text){const e=c.lineHeight;t.y+=sr(m,e)+d}else t.y+=x}),ce(this.ctx,e.textDirection)}drawTitle(){const t=this.options,e=t.title,i=ne(e.font),r=re(e.padding);if(e.display){var n=le(t.rtl,this.left,this.width),a=this.ctx,o=e.position,s=i.size/2;s=r.top+s;let l,h=this.left,c=this.width;if(this.isHorizontal())c=Math.max(...this.lineWidths),l=this.top+s,h=Hr(t.align,h,this.right-c);else{const e=this.columnSizes.reduce((t,e)=>Math.max(t,e.height),0);l=s+Hr(t.align,this.top,this.bottom-e-t.labels.padding-this._computeTitleHeight())}s=Hr(o,h,h+c),a.textAlign=n.textAlign(Fr(o)),a.textBaseline="middle",a.strokeStyle=e.color,a.fillStyle=e.color,a.font=i.string,It(a,e.text,s,l,i)}}_computeTitleHeight(){var t=this.options.title,e=ne(t.font),i=re(t.padding);return t.display?e.lineHeight+i.height:0}_getLegendItemAt(t,e){let i,r,n;if(B(t,this.left,this.right)&&B(e,this.top,this.bottom))for(n=this.legendHitBoxes,i=0;it.chart.options.color,boxWidth:40,padding:10,generateLabels(t){let e=t.data.datasets,i=t.legend.options.labels,r=i.usePointStyle,n=i.pointStyle,a=i.textAlign,o=i.color,s=i.useBorderRadius,l=i.borderRadius;return t._getSortedDatasetMetas().map(t=>{var i=t.controller.getStyle(r?0:void 0),h=re(i.borderWidth);return{text:e[t.index].label,fillStyle:i.backgroundColor,fontColor:o,hidden:!t.visible,lineCap:i.borderCapStyle,lineDash:i.borderDash,lineDashOffset:i.borderDashOffset,lineJoin:i.borderJoinStyle,lineWidth:(h.width+h.height)/4,strokeStyle:i.borderColor,pointStyle:n||i.pointStyle,rotation:i.rotation,textAlign:a||i.textAlign,borderRadius:s&&(l||i.borderRadius),datasetIndex:t.index}},this)}},title:{color:t=>t.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:t=>!t.startsWith("on"),labels:{_scriptable:t=>!["generateLabels","filter","sort"].includes(t)}}};class Ra extends Xn{constructor(t){super(),this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,e){var r=this.options;this.left=0,this.top=0,r.display?(this.width=this.right=t,this.height=this.bottom=e,t=i(r.text)?r.text.length:1,this._padding=re(r.padding),e=t*ne(r.font).lineHeight+this._padding.height,this.isHorizontal()?this.height=e:this.width=e):this.width=this.height=this.right=this.bottom=0}isHorizontal(){var t=this.options.position;return"top"===t||"bottom"===t}_drawArgs(t){let e,i,r,n=this.top,a=this.left,o=this.bottom,s=this.right,l=this.options,h=l.align,c=0;return e=this.isHorizontal()?(i=Hr(h,a,s),r=n+t,s-a):(c="left"===l.position?(i=a+t,r=Hr(h,o,n),-.5*Mr):(i=s-t,r=Hr(h,n,o),.5*Mr),o-n),{titleX:i,titleY:r,maxWidth:e,rotation:c}}draw(){var t,e,i,r,n=this.ctx,a=this.options;a.display&&(i=(e=ne(a.font)).lineHeight/2+this._padding.top,i=(t=this._drawArgs(i)).titleX,r=t.titleY,It(n,a.text,0,0,e,{color:a.color,maxWidth:t.maxWidth,rotation:t.rotation,textAlign:Fr(a.align),textBaseline:"middle",translation:[i,r]}))}}var Na={id:"title",_element:Ra,start(t,e,i){var r=new Ra({ctx:t.ctx,options:i,chart:t});Pn.configure(t,r,i),Pn.addBox(t,r),t.titleBlock=r},stop(t){var e=t.titleBlock;Pn.removeBox(t,e),delete t.titleBlock},beforeUpdate(t,e,i){var r=t.titleBlock;Pn.configure(t,r,i),r.options=i},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const Fa=new WeakMap;var Ha={id:"subtitle",start(t,e,i){var r=new Ra({ctx:t.ctx,options:i,chart:t});Pn.configure(t,r,i),Pn.addBox(t,r),Fa.set(t,r)},stop(t){Pn.removeBox(t,Fa.get(t)),Fa["delete"](t)},beforeUpdate(t,e,i){var r=Fa.get(t);Pn.configure(t,r,i),r.options=i},defaults:{align:"center",display:!1,font:{weight:"normal"},fullSize:!0,padding:0,position:"top",text:"",weight:1500},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const Va={average(t){if(!t.length)return!1;let e,i,r=new Set,n=0,a=0;for(e=0,i=t.length;et+e)/r.size,y:n/a}},nearest(t,e){if(!t.length)return!1;let i,r,n,a=e.x,o=e.y,s=Number.POSITIVE_INFINITY;for(i=0,r=t.length;i({borderColor:(t=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex)).borderColor,backgroundColor:t.backgroundColor,borderWidth:t.borderWidth,borderDash:t.borderDash,borderDashOffset:t.borderDashOffset,borderRadius:0}),labelTextColor(){return this.options.bodyColor},labelPointStyle:t=>({pointStyle:(t=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex)).pointStyle,rotation:t.rotation}),afterLabel:t,afterBody:t,beforeFooter:t,footer:t,afterFooter:t};class ja extends Xn{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){var t,e;return this._cachedAnimations||(e=this.chart,e=(t=this.options.setContext(this.getContext())).enabled&&e.options.animation&&t.animations,t=new Un(this.chart,e),e._cacheable&&(this._cachedAnimations=Object.freeze(t)),t)}getContext(){return this.$context||(this.$context=se(this.chart.getContext(),{tooltip:this,tooltipItems:this._tooltipItems,type:"tooltip"}))}getTitle(t,e){var i=gr(e=e.callbacks,"beforeTitle",this,t),r=gr(e,"title",this,t);e=gr(e,"afterTitle",this,t);return lr(t=lr(t=lr([],hr(i)),hr(r)),hr(e))}getBeforeBody(t,e){return mr(gr(e.callbacks,"beforeBody",this,t))}getBody(t,e){let i=e.callbacks,r=[];return l(t,t=>{var e={before:[],lines:[],after:[]},n=fr(i,t);lr(e.before,hr(gr(n,"beforeLabel",this,t))),lr(e.lines,gr(n,"label",this,t)),lr(e.after,hr(gr(n,"afterLabel",this,t))),r.push(e)}),r}getAfterBody(t,e){return mr(gr(e.callbacks,"afterBody",this,t))}getFooter(t,e){var i=gr(e=e.callbacks,"beforeFooter",this,t),r=gr(e,"footer",this,t);e=gr(e,"afterFooter",this,t);return lr(t=lr(t=lr([],hr(i)),hr(r)),hr(e))}_createItems(t){const e=this._active,i=this.chart.data,r=[],n=[],a=[];let o,s,h=[];for(o=0,s=e.length;ot.filter(e,r,n,i))),l(h=t.itemSort?h.sort((e,r)=>t.itemSort(e,r,i)):h,e=>{var i=fr(t.callbacks,e);r.push(gr(i,"labelColor",this,e)),n.push(gr(i,"labelPointStyle",this,e)),a.push(gr(i,"labelTextColor",this,e))}),this.labelColors=r,this.labelPointStyles=n,this.labelTextColors=a,this.dataPoints=h}update(t,e){let i,r=this.options.setContext(this.getContext()),n=this._active,a=[];if(n.length){const t=Va[r.position].call(this,n,this._eventPosition),e=(a=this._createItems(r),this.title=this.getTitle(a,r),this.beforeBody=this.getBeforeBody(a,r),this.body=this.getBody(a,r),this.afterBody=this.getAfterBody(a,r),this.footer=this.getFooter(a,r),this._size=cr(this,r)),o=Object.assign({},t,e),s=dr(this.chart,r,o),l=ur(r,o,s,this.chart);this.xAlign=s.xAlign,this.yAlign=s.yAlign,i={opacity:1,x:l.x,y:l.y,width:e.width,height:e.height,caretX:t.x,caretY:t.y}}else 0!==this.opacity&&(i={opacity:0});this._tooltipItems=a,this.$context=void 0,i&&this._resolveAnimations().update(this,i),t&&r.external&&r.external.call(this,{chart:this.chart,tooltip:this,replay:e})}drawCaret(t,e,i,r){t=this.getCaretPosition(t,i,r),e.lineTo(t.x1,t.y1),e.lineTo(t.x2,t.y2),e.lineTo(t.x3,t.y3)}getCaretPosition(t,e,i){var r,n=this.xAlign,a=this.yAlign,o=(i=(r=i).caretSize,(r=ie(r.cornerRadius)).topLeft),s=r.topRight,l=r.bottomRight,h=(t=(h=t).x,h.y),c=(e=(c=e).width,c.height);let d,u,p,m,f,g;return"center"===a?(f=h+c/2,g="left"===n?(u=(d=t)-i,m=f+i,f-i):(u=(d=t+e)+i,m=f-i,f+i),p=d):(u="left"===n?t+Math.max(o,r.bottomLeft)+i:"right"===n?t+e-Math.max(s,l)-i:this.caretX,p="top"===a?(f=(m=h)-i,d=u-i,u+i):(f=(m=h+c)+i,d=u+i,u-i),g=m),{x1:d,x2:u,x3:p,y1:m,y2:f,y3:g}}drawTitle(t,e,i){let r,n,a,o=this.title,s=o.length;if(s){var l=le(i.rtl,this.x,this.width);for(t.x=pr(this,i.titleAlign,i),e.textAlign=l.textAlign(i.titleAlign),e.textBaseline="middle",r=ne(i.titleFont),n=i.titleSpacing,e.fillStyle=i.titleColor,e.font=r.string,a=0;a0!==t)?(t.beginPath(),t.fillStyle=a.multiKeyBackground,Dt(t,{x:e,y:m,w:h,h:l,radius:s}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),Dt(t,{x:i,y:m+1,w:h-2,h:l-2,radius:s}),t.fill()):(t.fillStyle=a.multiKeyBackground,t.fillRect(e,m,h,l),t.strokeRect(e,m,h,l),t.fillStyle=o.backgroundColor,t.fillRect(i,m+1,h-2,l-2))}t.fillStyle=this.labelTextColors[i]}drawBody(t,e,i){function r(i){e.fillText(i,f.x(t.x+m),t.y+p/2),t.y+=p+a}let n=this.body,a=i.bodySpacing,o=i.bodyAlign,s=i.displayColors,h=i.boxHeight,c=i.boxWidth,d=i.boxPadding,u=ne(i.bodyFont),p=u.lineHeight,m=0;const f=le(i.rtl,this.x,this.width),g=f.textAlign(o);let v,b,y,x,w,k,_;for(e.textAlign=o,e.textBaseline="middle",e.font=u.string,t.x=pr(this,g,i),e.fillStyle=i.bodyColor,l(this.beforeBody,r),m=s&&"right"!==g?"center"===o?c/2+d:c+2+d:0,x=0,k=n.length;x{var i=this.chart.getDatasetMeta(t);if(i)return{datasetIndex:t,element:i.data[e],index:e};throw new Error("Cannot find a dataset at index "+t)})),r=this._positionChanged(t,e);(i||r)&&(this._active=t,this._eventPosition=e,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,e,i=!0){if(e&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;var r=this.options,n=this._active||[],a=(i=this._getActiveElements(t,n,e,i),this._positionChanged(i,t));return(n=e||!h(i,n)||a)&&(this._active=i,r.enabled||r.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,e)),n}_getActiveElements(t,e,i,r){var n=this.options;return"mouseout"===t.type?[]:r?(r=this.chart.getElementsAtEventForMode(t,n.mode,n,i),n.reverse&&r.reverse(),r):e.filter(t=>this.chart.data.datasets[t.datasetIndex]&&void 0!==this.chart.getDatasetMeta(t.datasetIndex).controller.getParsed(t.index))}_positionChanged(t,e){var i=this.caretX,r=this.caretY,n=this.options;return!1!==(n=Va[n.position].call(this,t,e))&&(i!==n.x||r!==n.y)}}_defineProperty(ja,"positioners",Va);var Wa={id:"tooltip",_element:ja,positioners:Va,afterInit(t,e,i){i&&(t.tooltip=new ja({chart:t,options:i}))},beforeUpdate(t,e,i){t.tooltip&&t.tooltip.initialize(i)},reset(t,e,i){t.tooltip&&t.tooltip.initialize(i)},afterDraw(t){var e,i=t.tooltip;i&&i._willRender()&&!(e={tooltip:i})!==t.notifyPlugins("beforeTooltipDraw",_objectSpread(_objectSpread({},e),{},{cancelable:!0}))&&(i.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",e))},afterEvent(t,e){var i;t.tooltip&&(i=e.replay,t.tooltip.handleEvent(e.event,i,e.inChartArea))&&(e.changed=!0)},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,e)=>e.bodyFont.size,boxWidth:(t,e)=>e.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:qa},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:t=>"filter"!==t&&"itemSort"!==t&&"external"!==t,_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};return ca.register(ma,Ta,va,vr),ca.helpers=_objectSpread({},zn),ca._adapters=da,ca.Animation=Wn,ca.Animations=Un,ca.animator=qr,ca.controllers=ta.controllers.items,ca.DatasetController=$n,ca.Element=Xn,ca.elements=va,ca.Interaction=On,ca.layouts=Pn,ca.platforms=fn,ca.Scale=Jn,ca.Ticks=ln,Object.assign(ca,ma,Ta,va,vr,fn),ca.Chart=ca,"undefined"!=typeof window&&(window.Chart=ca),ca}),window.SL=function(t){t=t.split(".");for(var e=SL;t.length;){var i=t.shift();e[i]||(e[i]={}),e=e[i]}return e},[].slice.call(document.querySelectorAll('.sl-block[data-block-type="code"] pre code')).forEach(function(t){t.setAttribute("data-plaintext",t.textContent)}),function(){function t(){if(e)return;e=!0,"undefined"==typeof SLConfig&&(window.SLConfig={}),SL.fonts.init(),SL.view=new SL.views.decks.Export;const t=/print-pdf/.test(window.location.search)?SL.deck.Controller.MODE_PRINTING:SL.deck.Controller.MODE_VIEWING;SL.deck.Controller.init({mode:t})}var e=!1;"complete"===document.readyState?setTimeout(t,1):"interactive"===document.readyState?(document.onreadystatechange=function(){"complete"==document.readyState&&setTimeout(t,1)},window.addEventListener("load",t)):(document.addEventListener("DOMContentLoaded",t),window.addEventListener("load",t))}(),SL.fonts={INIT_TIMEOUT:5e3,FONTS_URL:SLConfig.fonts_url||"fonts/",FAMILIES:{montserrat:{id:"montserrat",name:"Montserrat",path:"montserrat/montserrat.css"},opensans:{id:"opensans",name:"Open Sans",path:"opensans/opensans.css"},lato:{id:"lato",name:"Lato",path:"lato/lato.css"},asul:{id:"asul",name:"Asul",path:"asul/asul.css"},josefinsans:{id:"josefinsans",name:"Josefin Sans",path:"josefinsans/josefinsans.css"},league:{id:"league",name:"League Gothic",path:"league/league_gothic.css"},merriweathersans:{id:"merriweathersans",name:"Merriweather Sans",path:"merriweathersans/merriweathersans.css"},overpass:{id:"overpass",name:"Overpass",path:"overpass/overpass.css"},overpass2:{id:"overpass2",name:"Overpass 2",path:"overpass2/overpass2.css"},quicksand:{id:"quicksand",name:"Quicksand",path:"quicksand/quicksand.css"},cabinsketch:{id:"cabinsketch",name:"Cabin Sketch",path:"cabinsketch/cabinsketch.css"},newscycle:{id:"newscycle",name:"News Cycle",path:"newscycle/newscycle.css"},oxygen:{id:"oxygen",name:"Oxygen",path:"oxygen/oxygen.css"}},PACKAGES:{asul:["asul"],helvetica:[],josefine:["josefinsans","lato"],league:["league","lato"],merriweather:["merriweathersans","oxygen"],news:["newscycle","lato"],montserrat:["montserrat","opensans"],opensans:["opensans"],overpass:["overpass"],overpass2:["overpass2"],palatino:[],quicksand:["quicksand","opensans"],sketch:["cabinsketch","oxygen"]},googlePreviewHistory:{},init:function(){if(this._isReady=!1,this.ready=new signals.Signal,this.loaded=new signals.Signal,this.fontactive=new signals.Signal,this.fontinactive=new signals.Signal,this.debugMode=!!/debug/gi.test(location.search),[].slice.call(document.querySelectorAll("link[data-application-font]")).forEach(function(t){var e=t.getAttribute("data-application-font");SL.fonts.FAMILIES[e]&&(SL.fonts.FAMILIES[e].loaded=!0)}),SLConfig&&SLConfig.deck){var t=SL.config?SL.config.DEFAULT_THEME_FONT:"montserrat";this.loadDeckFont([SLConfig.deck.theme_font||t],{active:this.onInitialFontsActive.bind(this),inactive:this.onInitialFontsInactive.bind(this)})?this.initTimeout=setTimeout(function(){this.debugMode&&console.log("SL.fonts","timed out"),this.finishLoading()}.bind(this),SL.fonts.INIT_TIMEOUT):this.finishLoading()}else this.finishLoading()},load:function(t,e){var i={classes:!1,fontactive:this.onFontActive.bind(this),fontinactive:this.onFontInactive.bind(this),custom:{families:[],urls:[]}};for(var r in e)i[r]=e[r];SLConfig&&SLConfig.deck&&(SLConfig.deck.font_typekit&&(i.typekit={id:SLConfig.deck.font_typekit}),SLConfig.deck.font_google&&(i.google=i.google||{families:[]},i.google.families=i.google.families.concat(SL.fonts.parseGoogleFontFamilies(SLConfig.deck.font_google)))),SLConfig&&SLConfig.theme&&(SLConfig.theme.font_typekit&&(i.typekit={id:SLConfig.theme.font_typekit}),SLConfig.theme.font_google&&(i.google=i.google||{families:[]},i.google.families=i.google.families.concat(SL.fonts.parseGoogleFontFamilies(SLConfig.theme.font_google))));var n=[];return i.google&&i.google.families&&(n=i.google.families.map(function(t){return t.split(":")[0]})),t.forEach(function(t){var e=SL.fonts.FAMILIES[t];e?e.loaded||-1!==n.indexOf(e.name)?"function"==typeof i.fontactive&&i.fontactive(e.name):(e.loaded=!0,i.custom.families.push(e.name),i.custom.urls.push(SL.fonts.FONTS_URL+e.path)):console.warn('Could not find font family with id "'+t+'"')}),this.debugMode&&console.log("SL.fonts.load",i.custom.families),!!(i.custom.families.length||i.typekit||i.google)&&(WebFont.load(i),!0)},loadAll:function(t){var e=[];for(var i in SL.fonts.FAMILIES)e.push(i);this.load(e,t)},loadDeckFont:function(t,e){var i=SL.fonts.PACKAGES[t];return i?SL.fonts.load(i,e):SL.fonts.load([],e)},loadGoogleFont:function(t){WebFont.load({google:{families:SL.fonts.parseGoogleFontFamilies(t)}})},loadGoogleFontPreview:function(t,e){this.googlePreviewHistory[t]=this.googlePreviewHistory[t]||[],-1===this.googlePreviewHistory[t].indexOf(e)&&(this.googlePreviewHistory[t].push(e),WebFont.load({google:{families:[t],text:e}}))},loadTypekitFont:function(t){WebFont.load({typekit:{id:t}})},parseGoogleFontFamilies:function(t){return t=(t=(t=(t||"").trim().split(", ")).map(function(t){return t.trim().replace(/(^,)|(,$)/gi,"")})).filter(function(t){return"string"==typeof t&&t.length>0})},unload:function(t){t.forEach(function(t){var e=SL.fonts.FAMILIES[t];e&&(e.loaded=!1,[].slice.call(document.querySelectorAll('link[href="'+SL.fonts.FONTS_URL+e.path+'"]')).forEach(function(t){t.parentNode.removeChild(t)}))})},finishLoading:function(){clearTimeout(this.initTimeout),document.documentElement.classList.add("fonts-are-ready"),!1===this._isReady&&(this._isReady=!0,this.ready.dispatch()),this.loaded.dispatch()},getPackageIDs:function(){return Object.keys(SL.fonts.PACKAGES)},getFamilyByName:function(t){for(var e in SL.fonts.FAMILIES){var i=SL.fonts.FAMILIES[e];if(t===i.name)return i}},isPackageLoaded:function(t){var e=SL.fonts.PACKAGES[t];return!e||(0===e.length||e.every(function(t){var e=SL.fonts.FAMILIES[t];return e.active||e.inactive}))},isReady:function(){return this._isReady},onFontActive:function(t){var e=SL.fonts.getFamilyByName(t);e&&(e.active=!0),this.fontactive.dispatch(e)},onFontInactive:function(t){var e=SL.fonts.getFamilyByName(t);e&&(e.inactive=!0),this.fontinactive.dispatch(e)},onInitialFontsActive:function(){this.finishLoading()},onInitialFontsInactive:function(){this.finishLoading()}},SL("views.decks").Export=Class.extend({init:function(){SL.deck.util.injectNotes(),SL.deck.util.renderMath(),SL.deck.util.injectCodeCopyButtons(),window.Reveal&&Reveal.isReady()&&(Reveal.sync(),Reveal.layout())}}),SL("deck").Animation={init:function(){this.animationListeners=[],this.animationsEnabled=!0,this.run=this.run.bind(this),this.reset=this.reset.bind(this),this.toggle=this.toggle.bind(this),this.onSlideChanged=this.onSlideChanged.bind(this),Reveal.addEventListener("slidechanged",this.onSlideChanged),this.revealElement=document.querySelector(".reveal"),this.interactiveAnimationChanged=new signals.Signal},sync:function(){this.animationsEnabled?this.enableAnimations():this.disableAnimations()},enableAnimations:function(){this.animationsEnabled=!0,this.revealElement.classList.remove("block-animations-disabled"),this.reset(this.revealElement);var t=Reveal.getCurrentSlide();t&&this.fastForwardAnimation(t,function(){this.run(t),this.bind(t)}.bind(this))},disableAnimations:function(){this.animationsEnabled=!1,this.revealElement.classList.add("block-animations-disabled"),this.unbind(),this.fastForwardAnimation(this.revealElement)},getAnimationTargets:function(t){return t instanceof Array?t:t.hasAttribute("data-animation-type")?[t]:[].slice.call(t.querySelectorAll("[data-animation-type]"))},getInteractiveAnimationTargets:function(t,e){var i=e?".animate":"";return[].slice.call(t.querySelectorAll(['[data-animation-trigger="click"]','[data-animation-trigger="hover"]'].join(i+",")+i))},run:function(t,e){this.getAnimationTargets(t).forEach(function(t){!e&&this.hasInteractiveAnimationTrigger(t)||t.classList.add("animate")}.bind(this))},toggle:function(t,e){this.getAnimationTargets(t).forEach(function(t){!e&&this.hasInteractiveAnimationTrigger(t)||t.classList.toggle("animate")}.bind(this))},reset:function(t){this.getAnimationTargets(t).forEach(function(t){t.classList.remove("animate")}.bind(this))},preview:function(t){!1===this.animationsEnabled&&this.revealElement.classList.remove("block-animations-disabled"),this.getAnimationTargets(t).forEach(function(t){t.classList.remove("animate"),this.fastForwardAnimation(t,function(){t.classList.add("animate"),!1===this.animationsEnabled&&this.revealElement.classList.add("block-animations-disabled")}.bind(this))}.bind(this))},bind:function(t){this.unbind(),this.getAnimationTargets(t).forEach(function(e){if(this.hasInteractiveAnimationTrigger(e)){var i=e.getAttribute("data-animation-trigger-id"),r="self"===i?e:t.querySelector('.sl-block[data-block-id="'+i+'"] .sl-block-content');if(r){var n=e.getAttribute("data-animation-trigger");"click"===n?(this.addAnimationEventListener(r,"touchstart",this.onTriggerTouchStart.bind(this,e)),this.addAnimationEventListener(r,"click",this.onTriggerClick.bind(this,e))):"hover"===n&&(this.addAnimationEventListener(r,"mouseover",this.onTriggerMouseOver.bind(this,e)),this.addAnimationEventListener(r,"mouseout",this.onTriggerMouseOut.bind(this,e)))}}}.bind(this))},addAnimationEventListener:function(t,e,i){t.addEventListener(e,i),/click|touchstart/gi.test(e)&&t.classList.add("animation-trigger"),this.animationListeners.push([t,e,i])},unbind:function(){this.animationListeners.forEach(function(t){var e=t[0],i=t[1],r=t[2];/click|touchstart/gi.test(i)&&e.classList.remove("animation-trigger"),e.removeEventListener(i,r)}),this.animationListeners.length=0},hasInteractiveAnimationTrigger:function(t){return/click|hover/gi.test(t.getAttribute("data-animation-trigger"))},fastForwardAnimation:function(t,e){t.classList.add("no-transition"),setTimeout(function(){t.classList.remove("no-transition"),"function"==typeof e&&e()},1)},getSerializedInteractiveState:function(){return this.getInteractiveAnimationTargets(Reveal.getCurrentSlide(),!0).map(function(t){var e=this.getParentBlock(t);return e?e.getAttribute("data-block-id"):null},this).filter(function(t){return"string"==typeof t}).join(",")},setSerializedInteractiveState:function(t){var e=this.getInteractiveAnimationTargets(Reveal.getCurrentSlide());if(e.length&&"string"==typeof t){t=t.split(",");var i=[],r=[];e.forEach(function(e){var n=this.getParentBlock(e),a=n?n.getAttribute("data-block-id"):null;"string"==typeof a&&-1!==t.indexOf(a)?r.push(e):i.push(e)},this),this.reset(i),this.run(r,!0)}},getParentBlock:function(t){for(var e=t.parentNode;e&&!e.hasAttribute("data-block-id");)e=e.parentNode;return e},onSlideChanged:function(t){this.animationsEnabled&&(t.previousSlide&&(this.reset(t.previousSlide),this.unbind()),t.currentSlide&&(this.run(t.currentSlide),this.bind(t.currentSlide)))},onTriggerTouchStart:function(t,e){e.preventDefault(),this.toggle(t,!0),this.interactiveAnimationChanged.dispatch()},onTriggerClick:function(t){Reveal.isAutoSliding()&&Reveal.getConfig().autoSlideStoppable&&Reveal.toggleAutoSlide(!1),this.toggle(t,!0),this.interactiveAnimationChanged.dispatch()},onTriggerMouseOver:function(t){this.run(t,!0),this.interactiveAnimationChanged.dispatch()},onTriggerMouseOut:function(t){this.reset(t),this.interactiveAnimationChanged.dispatch()}},SL("deck").AutoAnimate={ANIMATABLE_BLOCK_CONTENT_STYLES:["color","background-color","padding","font-size","line-height","letter-spacing","border-width","border-color","border-radius"],init:function(){this.onAutoAnimate=this.onAutoAnimate.bind(this),Reveal.addEventListener("autoanimate",this.onAutoAnimate)},matcher:function(t,e){var i=[];SL.deck.AutoAnimate.findMatchingElements(i,t,e,".sl-block[data-name]",function(t){return t.nodeName+":::"+t.getAttribute("data-name")});var r=i.map(t=>t.from);return SL.deck.AutoAnimate.findMatchingElements(i,t,e,'.sl-block[data-block-type="text"], .sl-block[data-block-type="snippet"], .sl-block[data-block-type="table"]',function(t){return t.getAttribute("data-block-type")+":::"+t.textContent.trim()},null,r),SL.deck.AutoAnimate.findMatchingElements(i,t,e,'.sl-block[data-block-type="image"], .sl-block[data-block-type="video"]',function(t){var e=t.querySelector("img[src], video[src]");return e?e.getAttribute("src"):null},null,r),SL.deck.AutoAnimate.findMatchingElements(i,t,e,'.sl-block[data-block-type="iframe"]',function(t){var e=t.querySelector("iframe[src], iframe[data-src]");return e?e.getAttribute("src")||e.getAttribute("data-src"):null},null,r),SL.deck.AutoAnimate.findMatchingElements(i,t,e,'.sl-block[data-block-type="code"]',function(t){return t.querySelector(":not(.editing-ui) pre code").textContent},null,r),SL.deck.AutoAnimate.findMatchingElements(i,t,e,'.sl-block[data-block-type="math"]',function(t){return t.querySelector(".math-input").textContent},null,r),SL.deck.AutoAnimate.expandBlockPairs(i)},findMatchingElements:function(t,e,i,r,n,a,o){var s={},l={};[].slice.call(e.querySelectorAll(r)).forEach(function(t){var e=n(t);"string"==typeof e&&e.length&&(s[e]=s[e]||[],s[e].push(t))}),[].slice.call(i.querySelectorAll(r)).forEach(function(e){var i,r=n(e);if(l[r]=l[r]||[],l[r].push(e),s[r]){var h=l[r].length-1,c=s[r].length-1;s[r][h]?(i=s[r][h],s[r][h]=null):s[r][c]&&(i=s[r][c],s[r][c]=null)}!i||o&&-1!==o.indexOf(i)||t.push({from:i,to:e,options:a||{styles:[]}})})},expandBlockPairs:function(t){return t.forEach(function(e){var i=e.from,r=e.to,n=i.querySelector(".sl-block-content"),a=r.querySelector(".sl-block-content");n&&a&&SL.deck.AutoAnimate.expandBlockPair(t,e,i,r,n,a)}),t},expandBlockPair:function(t,e,i,r,n,a){var o=i.querySelector(".sl-block-style"),s=r.querySelector(".sl-block-style");o&&o.closest(".sl-block")!==i&&(o=null),s&&s.closest(".sl-block")!==r&&(s=null);var l=i.getAttribute("data-block-type"),h={},c={};if(r.dataset.autoAnimateDelay&&(e.options.delay=parseFloat(r.dataset.autoAnimateDelay)),r.dataset.autoAnimateDuration&&(e.options.duration=parseFloat(r.dataset.autoAnimateDuration)),r.dataset.autoAnimateEasing&&(e.options.easing=r.dataset.autoAnimateEasing),h["z-index"]={property:"z-index",from:a.style.zIndex,to:a.style.zIndex},s){const t=s.style.mixBlendMode;t&&"normal"!==t&&(h["mix-blend-mode"]={property:"mix-blend-mode",to:t})}return/text|snippet|table|line/i.test(l)?h.width={property:"width"}:/code|math/i.test(l)&&(h.width={property:"width"},h.height={property:"height"}),o&&s?(h.opacity={property:"opacity",from:o.style.opacity||"1",to:s.style.opacity||"1"},(o.style.transform||s.style.transform)&&(h.width={property:"width"},h.height={property:"height"},t.push({from:o,to:s,options:{translate:!1,scale:!1,styles:[{property:"transform"}]}}))):o?(h.opacity={property:"opacity",from:o.style.opacity||"1",to:"1"},o.style.transform&&(h.width={property:"width"},h.height={property:"height"},c.transform={property:"transform",from:o.style.transform,to:"none"})):s&&(h.opacity={property:"opacity",from:"1",to:s.style.opacity||"1"},s.style.transform&&(h.width={property:"width"},h.height={property:"height"},t.push({from:document.createElement("div"),to:s,options:{translate:!1,scale:!1,styles:[{property:"transform",from:"none"}]}}))),t.push({from:n,to:a,options:{translate:!1,scale:!1,styles:SL.deck.AutoAnimate.ANIMATABLE_BLOCK_CONTENT_STYLES.concat(Object.keys(c).map(function(t){return c[t]}))}}),/text/i.test(l)&&this.expandTextBlock(t,e,i,r),/code/i.test(l)&&this.expandCodeBlock(t,e,i,r),/shape/i.test(l)&&this.expandShapeBlock(t,e,i,r),/line/i.test(l)&&this.expandLineBlock(t,e,i,r),e.options.styles=e.options.styles.concat(Object.keys(h).map(function(t){return h[t]})),(h.width||h.height)&&(e.options.scale=!1),t},expandTextBlock:function(t,e,i,r){SL.deck.AutoAnimate.findMatchingElements(t,i,r,"li>p",function(t){return t.innerText.trim()},{scale:!1,translate:!1,measure:SL.deck.AutoAnimate.getLocalBlockMeasurements}),SL.deck.AutoAnimate.findMatchingElements(t,i,r,"ul li, ol li",function(t){return Array.prototype.map.call(t.childNodes,function(t){return/li|ul|ol/i.test(t.nodeName)?"":t.textContent.trim()}).join("")},{scale:!1,measure:SL.deck.AutoAnimate.getLocalBlockMeasurements}),SL.deck.AutoAnimate.findMatchingElements(t,i,r,'span[style*="font-size"]',function(t){return t.textContent.trim()},{scale:!1,translate:!1,styles:[{property:"font-size"}]})},expandCodeBlock:function(t,e,i,r){var n=r.querySelector("code.current-fragment");n&&(r=n),SL.deck.AutoAnimate.findMatchingElements(t,i,r,".hljs-ln-code",function(t){return t.textContent},{scale:!1,styles:[],measure:SL.deck.AutoAnimate.getLocalBlockMeasurements}),SL.deck.AutoAnimate.findMatchingElements(t,i,r,".hljs-ln-line[data-line-number]",function(t){return t.getAttribute("data-line-number")},{scale:!1,styles:["width"],measure:SL.deck.AutoAnimate.getLocalBlockMeasurements})},expandShapeBlock:function(t,e,i,r){var n=i.querySelector(".shape-element"),a=r.querySelector(".shape-element"),o=[{property:"fill"},{property:"stroke"}];n&&a&&(/rect/i.test(a.nodeName)&&o.push({property:"rx"},{property:"ry"}),t.push({from:n,to:a,options:{translate:!1,scale:!1,styles:o}}))},expandLineBlock:function(t,e,i,r){var n=[];let a=i.querySelector(".line-element"),o=r.querySelector(".line-element");a&&o&&n.push([a,o]);let s=i.querySelector("path.line-start"),l=r.querySelector("path.line-start");s&&l&&n.push([s,l]);let h=i.querySelector("path.line-end"),c=r.querySelector("path.line-end");h&&c&&n.push([h,c]),n.forEach(function(e){t.push({from:e[0],to:e[1],options:{translate:!1,scale:!1,styles:[{property:"d"},{property:"fill"},{property:"stroke"},{property:"stroke-width"},{property:"stroke-dasharray"}]}})})},getLocalBlockMeasurements:function(t){var e=Reveal.getScale();return{x:Math.round(t.offsetLeft*e*100)/100,y:Math.round(t.offsetTop*e*100)/100,width:Math.round(t.offsetWidth*e*100)/100,height:Math.round(t.offsetHeight*e*100)/100}},onAutoAnimate:function(t){let e=[];Array.prototype.forEach.call(t.toSlide.querySelectorAll('.sl-block[data-auto-animate-target^="unmatched"]'),function(t){const i=t.querySelector(".sl-block-content");if(i){const r=i.style.zIndex,n=t.getAttribute("data-block-id"),a=t.getAttribute("data-auto-animate-target");e.push(`.reveal [data-auto-animate-target="${a}"][data-block-id="${n}"] { z-index: ${r}; }`)}}),e.length&&(t.sheet.innerHTML+=e.join(""))}},SL("deck").Charts={DEFAULT_CHART_DATA:{columns:[{value:"Quarter",type:"label"},{value:"Revenue",type:"number"},{value:"Expenses",type:"number"}],rows:[{data:["Q1",72,68]},{data:["Q2",84,71]},{data:["Q3",76,66]},{data:["Q4",94,76]}]},DEFAULT_CHART_TYPE:"column",DEFAULT_COLOR_THEME:"mono-dark",DEFAULT_BEGIN_AT_ZERO:!0,DEFAULT_SCALES:!0,DEFAULT_LEGEND:!0,DEFAULT_LEGEND_POSITION:"top",DEFAULT_TEXT_COLOR:"rgba(100, 100, 100, 0.9)",DEFAULT_GRID_COLOR:"rgba(100, 100, 100, 0)",DEFAULT_FONT_SIZE:12,COLOR_THEMES:[{id:"contrast",title:"Contrast",colors:["#4285F4","#EA4335","#FBBC05","#34A853","#A142F4","#00ACC1"]},{id:"mono-dark",title:"Mono Dark",colors:["#111111","#CCCCCC","#333333","#EEEEEE","#666666","#999999"]},{id:"mono-light",title:"Mono Light",colors:["#EEEEEE","#333333","#CCCCCC","#111111","#999999","#666666"]},{id:"warm",title:"Warm",colors:["#FF6F61","#FFD166","#CA5310","#FFD166","#E2711D","#FFA552"]},{id:"cool",title:"Cool",colors:["#13293D","#5BC0EB","#9BC53D","#4CB5F5","#2A628F","#3E92CC"]},{id:"pastel",title:"Pastel",colors:["#6BAED6","#FD8D3C","#31A354","#FDD0A2","#C6DBEF","#E592CB"]},{id:"vibrant",title:"Vibrant",colors:["#4E79A7","#F28E2B","#E15759","#76B7B2","#59A14F","#EDC948"]},{id:"earth",title:"Earth",colors:["#A6611A","#DFC27D","#80CDC1","#018571","#B2182B","#F4A582"]},{id:"neon",title:"Neon",colors:["#00E5FF","#FF4081","#69F0AE","#FFD740","#536DFE","#FFAB40"]},{id:"neutral",title:"Neutral",colors:["#6BA292","#D9BF77","#EAD2AC","#A37065","#E9AFA3","#C4C4C4"]}],options:{mode:null},init:function(t){this.options=t,this.onSlideChanged=this.onSlideChanged.bind(this),t.mode===SL.deck.Controller.MODE_VIEWING?(Reveal.addEventListener("slidechanged",this.onSlideChanged),this.renderChartsIn(Reveal.getCurrentSlide())):t.mode===SL.deck.Controller.MODE_PRINTING&&(Chart.defaults.events=[],this.renderChartsIn(Reveal.getRevealElement()))},formatChartConfig:function(t,{type:e,theme:i,scales:r,beginAtZero:n,legend:a,legendPosition:o,textColor:s,gridColor:l,fontSize:h}){const c=(SL.deck.Charts.COLOR_THEMES.find(t=>t.id===i)||SL.deck.Charts.COLOR_THEMES[0]).colors,d=this.chartTypeSupportsScales(e),u="radar"===e||"polarArea"===e;let p=null;try{p=window.getComputedStyle(Reveal.getSlidesElement()).fontFamily}catch(f){console.warn("Unable to get chart font family, using default:",f)}const m={family:p||'"Helvetica Neue", "Helvetica", sans-serif',size:h};if(t.data.datasets.forEach((t,i)=>{if(t.color=s,t.borderRadius=2,d){const e=t.backgroundColor||c[i%c.length];u?(t.borderColor=e,t.backgroundColor=SL.util.color.makeTransparent(e,.25)):t.backgroundColor=e}else t.backgroundColor=c;"line"===e&&(t.borderColor=t.backgroundColor,t.tension=.25)}),"bar"===e&&(t.options.indexAxis="y"),"column"===e&&(t.type="bar"),t.options.plugins.legend={display:a,position:o,labels:{color:s,font:m}},t.options.plugins.tooltip={yAlign:"bottom",padding:12,caretSize:h/2,boxPadding:4,animation:{duration:100},titleColor:"#ffffff",bodyColor:"#ffffff",borderWidth:1,backgroundColor:"rgba(0, 0, 0, 0.8)",borderColor:"rgba(255, 255, 255, 0.2)",titleFont:m,bodyFont:m,footerFont:m},d){const i="column"===e||"line"===e,a="bar"===e||"line"===e,o=r&&(i||a),h=r&&(i||a),c=r&&("radar"===e||"polarArea"===e);t.options.scales={y:{beginAtZero:n,ticks:{color:s,font:m,display:o},border:{display:o},grid:{color:i?l:"transparent",offset:o}},x:{ticks:{color:s,font:m,display:h},border:{display:h},grid:{color:a?l:"transparent",offset:h}},r:{beginAtZero:n,pointLabels:{color:s,font:m,display:c},ticks:{color:s,font:m,showLabelBackdrop:!1,display:c},grid:{color:l,tickColor:s,display:c},angleLines:{color:l,display:c}}}}else t.options.scales&&delete t.options.scales},renderChart:function(t,e,{type:i,theme:r,scales:n,beginAtZero:a,legend:o,legendPosition:s,textColor:l,gridColor:h,fontSize:c}){i=i||SL.deck.Charts.DEFAULT_CHART_TYPE,r=r||SL.deck.Charts.DEFAULT_COLOR_THEME,n="boolean"==typeof n?n:SL.deck.Charts.DEFAULT_SCALES,a="boolean"==typeof a?a:SL.deck.Charts.DEFAULT_BEGIN_AT_ZERO,o="boolean"==typeof o?o:SL.deck.Charts.DEFAULT_LEGEND,s=s||SL.deck.Charts.DEFAULT_LEGEND_POSITION,l=l||SL.deck.Charts.DEFAULT_TEXT_COLOR,h=h||SL.deck.Charts.DEFAULT_GRID_COLOR,c="number"!=typeof c||isNaN(c)?SL.deck.Charts.DEFAULT_FONT_SIZE:c;const d={type:i,data:{labels:e.labels,datasets:e.datasets},options:{responsive:!0,maintainAspectRatio:!1,animations:!1,transitions:!1,plugins:{}}};this.formatChartConfig(d,{type:i,theme:r,scales:n,beginAtZero:a,legend:o,legendPosition:s,textColor:l,gridColor:h,fontSize:c}),this.options.mode===SL.deck.Controller.MODE_PRINTING&&(d.options.responsive=!1,d.options.devicePixelRatio=3,t.style.width="100%",t.style.height="100%");const u=new Chart(t,d);if(this.options.mode!==SL.deck.Controller.MODE_PRINTING){const e=t.closest(".sl-block");if(e){const t=e.offsetWidth,i=e.offsetHeight;u.resize(t,i)}}return u._internalType=i,u},updateChart:function(t,e,i){if(t._internalType!==i.type){const r=t.canvas;return t.destroy(),this.renderChart(r,e,i)}return t.data.labels=e.labels,t.data.datasets=e.datasets,this.formatChartConfig(t,i),t.update(),t},renderChartsIn:function(t){t.querySelectorAll('.sl-block[data-block-type="chart"]:not(.chart-rendered)').forEach(t=>{t.classList.add("chart-rendered");const e=t.querySelector(".sl-block-content"),i=e.getAttribute("data-chart-data"),r=e.getAttribute("data-chart-type"),n=e.getAttribute("data-chart-theme"),a=e.getAttribute("data-chart-scales"),o=e.getAttribute("data-chart-begin-at-zero"),s=e.getAttribute("data-chart-legend"),l=e.getAttribute("data-chart-legend-position"),h=e.getAttribute("data-chart-text-color"),c=e.getAttribute("data-chart-grid-color"),d=parseInt(e.getAttribute("data-chart-font-size"));let u=null;try{u=JSON.parse(i),u=this.tableDataToChartJSData(u)}catch(m){return void console.warn("Error parsing chart data:",m)}if(!e)return void console.warn("Chart block has no content element");const p=document.createElement("canvas");p.className="chart-canvas editing-ui",e.appendChild(p),this.renderChart(p,u,{type:r,theme:n,scales:a,beginAtZero:o,legend:s,legendPosition:l,textColor:h,gridColor:c,fontSize:d})})},tableDataToChartJSData:function(t){const e=t.rows.map(t=>t.data[0]),i=t.columns.slice(1).map(t=>t.value),r=t.rows.filter(t=>t.data.some(t=>""!==t)).map(t=>t.data.slice(1));return{labels:e,datasets:i.map((t,e)=>({data:r.map(t=>t[e]),label:t}))}},chartTypeSupportsScales:function(t){return"column"===t||"bar"===t||"line"===t||"polarArea"===t||"radar"===t},onSlideChanged:function(t){this.renderChartsIn(t.currentSlide)}},SL("deck").Controller={MODE_VIEWING:"viewing",MODE_EDITING:"editing",MODE_PRINTING:"printing",init:function(t){if(this.options=t||{},this.options.mode="string"==typeof this.options.mode?this.options.mode:SL.deck.Controller.MODE_VIEWING,this.mode=null,SL.deck.Media.init(this.options),SL.deck.Variables.init(this.options),this.options.mode===SL.deck.Controller.MODE_VIEWING&&(SL.deck.util.formatIframes(),/safari/gi.test(navigator.userAgent)&&!/chrome/gi.test(navigator.userAgent))){document.querySelectorAll('.sl-block[data-block-type="video"] > .sl-block-style[style*="mix-blend-mode"]').forEach(t=>{const e=t.parentElement;e.style.mixBlendMode=t.style.mixBlendMode,e.style.zIndex=t.style.zIndex,t.style.mixBlendMode=null})}Reveal.isReady()?this.setup():Reveal.addEventListener("ready",this.setup.bind(this))},setup:function(){SL.deck.Charts.init(this.options),SL.deck.Animation.init(),SL.deck.AutoAnimate.init(),this.setMode(this.options.mode)},setMode:function(t){this.mode=t,this.mode===SL.deck.Controller.MODE_EDITING||this.mode===SL.deck.Controller.MODE_PRINTING?SL.deck.Animation.disableAnimations():SL.deck.Animation.enableAnimations()}},SL("deck").Media={init:function(t){this.options=t,this.supportsCDN()&&(this.switchToCDN(".reveal img[src], .reveal video[src]","src"),this.switchToCDN(".reveal img[data-src], .reveal video[data-src]","data-src"), this.switchToCDN(".reveal video[poster]","poster"),this.switchToCDN(".reveal [data-background-video]","data-background-video"),this.switchToCDN(".reveal [data-background-image]","data-background-image"))},supportsCDN:function(){return SL.config&&this.options.mode===SL.deck.Controller.MODE_VIEWING&&!document.documentElement.classList.contains("sl-editor")},switchToCDN:function(t,e){document.querySelectorAll(t).forEach(function(t){var i=t.getAttribute(e);0===i.lastIndexOf(SL.config.S3_HOST,0)&&t.setAttribute(e,i.replace(SL.config.S3_HOST,SL.config.CDN_HOST))},this)},replaceS3HostWithCDN:function(t){return t.replace(SL.config.S3_HOST,SL.config.CDN_HOST)}},SL("deck").util={extend:function(t){return Array.prototype.forEach.call(arguments,function(e){for(var i in e)t[i]=e[i]},t),t},renderMath:function(t){SL.deck.util.renderMathBlocks(t),SL.deck.util.renderInlineMath(t)},renderMathBlocks:function(t){t||(t=document.querySelector(".reveal .slides")),window.katex&&"function"==typeof window.katex.render&&[].slice.call(t.querySelectorAll('.sl-block[data-block-type="math"]')).forEach(function(t){var e=t.querySelector(".math-input"),i=t.querySelector(".math-output");if(e&&!i&&((i=document.createElement("div")).className="math-output",e.parentNode.insertBefore(i,e)),e&&i)try{katex.render(e.innerText,i,{displayMode:null!==t.querySelector("[data-math-display=true]"),throwOnError:!0})}catch(r){console.warn(r.message)}})},renderInlineMath:function(t){t||(t=document.querySelector(".reveal .slides")),"function"==typeof window.renderMathInElement&&SL.deck.util.containsInlineMath(t)&&renderMathInElement(t,{delimiters:[{left:"$$",right:"$$",display:!0},{left:"\\[",right:"\\]",display:!0},{left:"\\(",right:"\\)",display:!1}]})},containsInlineMath:function(t){return!!t&&/\$\$.+\$\$|\\\[.+\\\]|\\\(.+\\\)/g.test(t.innerHTML)},injectCodeCopyButtons:function(){var t=[].slice.call(document.querySelectorAll('.sl-block[data-block-type="code"] .sl-block-content:not(.has-copy-button)'));t.length&&(this.copyButton=document.createElement("button"),this.copyButton.className="copy-code-to-clipboard",this.copyButton.textContent="Copy",this.copyButton.addEventListener("click",function(){this.copyButton.hasAttribute("data-code-to-copy")&&(this.copyButton.textContent="Copied!",this.copyButton.classList.add("bounce"),SL.deck.util.copyToClipboard(this.copyButton.getAttribute("data-code-to-copy")),setTimeout(function(){this.copyButton.textContent="Copy",this.copyButton.classList.remove("bounce")}.bind(this),1500))}.bind(this)),t.forEach(function(t){var e,i=t.querySelector("pre code");i&&(e=i.hasAttribute("data-plaintext")?i.getAttribute("data-plaintext"):i.textContent),e&&t.addEventListener("mouseenter",function(t){this.copyButton.setAttribute("data-code-to-copy",e),t.currentTarget.classList.add("has-copy-button"),t.currentTarget.appendChild(this.copyButton)}.bind(this))},this))},hasNotes:function(){if(SLConfig.deck&&SLConfig.deck.notes)for(var t in SLConfig.deck.notes)return!0;return document.querySelectorAll(".reveal .slides section[data-notes]").length>0},injectNotes:function(){SLConfig.deck&&SLConfig.deck.notes&&[].forEach.call(document.querySelectorAll(".reveal .slides section"),function(t){var e=SLConfig.deck.notes[t.getAttribute("data-id")];e&&"string"==typeof e&&t.setAttribute("data-notes",e)})},injectTranslationRules:function(){[].slice.call(document.querySelectorAll(".sl-block .katex")).forEach(function(t){t.classList.add("notranslate")})},formatIframes:function(){[].slice.call(document.querySelectorAll(".sl-block iframe[data-src]")).forEach(this.formatIframe.bind(this))},formatIframe:function(t){t.removeAttribute("allowfullscreen"),t.removeAttribute("webkitallowfullscreen"),t.removeAttribute("mozallowfullscreen");let e=["fullscreen","autoplay","accelerometer","geolocation","gyroscope","camera","encrypted-media","microphone","midi"],i=t.getAttribute("allow");"string"==typeof i?(i=i.split(";").map(t=>t.trim()),e.forEach(t=>{-1===i.indexOf(t)&&i.push(t)})):i=e,t.setAttribute("allow",i.join("; "));var r=t.getAttribute("src")||t.getAttribute("data-src");"string"!=typeof r||/\.pdf$/i.test(r)?t.removeAttribute("sandbox"):t.setAttribute("sandbox","allow-forms allow-scripts allow-popups allow-same-origin allow-pointer-lock allow-presentation")},copyToClipboard:function(t){var e=document.createElement("textarea");e.value=t,document.body.appendChild(e),e.select();var i=document.execCommand("copy");return document.body.removeChild(e),i}},SL("deck").Variables={VARIABLE_REGEX:/\{\{.*?\}\}/g,VARIABLES:[{name:["today"],description:"Today's date",value:()=>(new Date).toLocaleDateString()},{name:["author"],description:"The author of the deck",value:()=>{if(SLConfig&&SLConfig.deck&&SLConfig.deck.user){if(SLConfig.deck.user.name)return SLConfig.deck.user.name;if(SLConfig.deck.user.username)return SLConfig.deck.user.username}return"N/A"}},{name:["title"],description:"The deck title",value:()=>SLConfig&&SLConfig.deck&&SLConfig.deck.title?SLConfig.deck.title:null},{name:["slide"],description:"Current slide number",value:t=>{const e=t.closest("section");return e?Reveal.getSlidePastCount(e)+1:null}},{name:["hslide"],description:"Horizontal slide number",value:t=>{const e=t.closest("section");if(!e)return null;const i=Reveal.getIndices(e);return i?(i.h||0)+1:null}},{name:["vslide"],description:"Vertical slide number",value:t=>{const e=t.closest("section");if(!e)return null;const i=Reveal.getIndices(e);return i?(i.v||0)+1:null}},{name:["hslideCount"],description:"Horizontal slide count",value:()=>Reveal?Reveal.getHorizontalSlides().length:null},{name:["slideCount","totalSlides"],description:"Total number of slides",value:()=>Reveal?Reveal.getTotalSlides():null}],options:{mode:null},discoveredVariableCount:0,blockSelector:['.sl-block[data-block-type="text"] .sl-block-content','.sl-block[data-block-type="table"] .sl-block-content','.sl-block[data-block-type="snippet"] .sl-block-content'].join(","),init:function(t){this.options=t,t.mode===SL.deck.Controller.MODE_EDITING?this.blockSelector=['.sl-block[data-block-type="text"] .sl-block-content-preview','.sl-block[data-block-type="table"] .sl-block-content-preview','.sl-block[data-block-type="snippet"] .sl-block-content-preview'].join(","):t.mode!==SL.deck.Controller.MODE_VIEWING&&t.mode!==SL.deck.Controller.MODE_PRINTING||("undefined"!=typeof Reveal&&"function"==typeof Reveal.removeHiddenSlides&&Reveal.removeHiddenSlides(),this.replaceAndUpdateVariablesInBlocks(document.querySelector(".reveal .slides")))},replaceAndUpdateVariablesInBlocks:function(t,e){this.replaceVariablesInBlocks(t),this.updateVariablesIn(t,e)},replaceVariablesInBlocks:function(t){if(!t)return;t.querySelectorAll(this.blockSelector).forEach(t=>this.replaceVariablesIn(t))},replaceVariablesIn:function(t){if(!t)return;const e=t.innerHTML.replace(new RegExp(this.VARIABLE_REGEX),t=>{const e=t.substring(2,t.length-2).trim();return this.hasVariable(e)?(this.discoveredVariableCount++,``):t});t.innerHTML=e},updateVariablesIn:function(t,e){t&&0!==this.discoveredVariableCount&&t.querySelectorAll(".sl-variable").forEach(t=>{const i=t.getAttribute("data-variable");if(!i)return;const r=this.getVariable(i);if(!r)return;if(e&&(!r.updateOn||!r.updateOn.includes(e)))return;const n=this.getVariableValue(i,t);null!==n&&(t.textContent=n)})},containsVariables:function(t){return!!t&&new RegExp(this.VARIABLE_REGEX).test(t.innerHTML)},getVariables:function(){return this.VARIABLES},getVariable:function(t){return this.getVariables().find(e=>e.name.includes(t))},hasVariable:function(t){return this.getVariable(t)!==undefined},getVariableValue:function(t,e){const i=this.getVariable(t);return i?"function"==typeof i.value?i.value(e):i.value:null}};