`` cannot be displayed by `mathjax-pagella` font
Author: alex-mashinCreated Sep 27, 2026Updated Sep 28, 2026
Issue Summary
The \mhchemxRightleftharpoons macro, unlike other macros from mhchem package, after conversion to MathML (converted code below) cannot be processed by browser-side MathJax, if the font mathjax-pagella is used.
<math xmlns="http://www.w3.org/1998/Math/MathML">
<semantics>
<mrow>
<mrow data-mjx-texclass="REL">
<mrow data-mjx-texclass="NONE"></mrow>
<mover>
<mo data-mjx-texclass="ORD" stretchy="true"></mo>
<mpadded width="+0.778em" lspace="0.278em" voffset="-.2em" height="-.2em">
<mi>x</mi>
<mspace depth=".2em"></mspace>
</mpadded>
</mover>
</mrow>
</mrow>
<annotation encoding="application/x-tex"> \mhchemxRightleftharpoons x </annotation>
</semantics>
</math>The red on yellow error message says: "Math output error" and the floating tip is: "invalid array length".
Steps to Reproduce:
- Create HTML page with MathML above and MathJax configuration script below.
- Load the page into a browser.
Technical details:
- MathJax Version: 4.1.3
- Client OS: Ubuntu 26.04
- Browser: Firefox 155.0.1
I am using the following MathJax configuration:
window.MathJax = {
"loader": {
"load": [
"input\/tex",
"[tex]\/amscd",
"[tex]\/bbox",
"[tex]\/braket",
"[tex]\/cancel",
"[tex]\/cases",
"[tex]\/centernot",
"[tex]\/colortbl",
"[tex]\/empheq",
"[tex]\/gensymb",
"[tex]\/mathtools",
"[tex]\/mhchem",
"[tex]\/physics",
"[tex]\/tagformat",
"[tex]\/textcomp",
"[tex]\/upgreek",
"[tex]\/verb",
"ui\/safe"
]
},
"options": {
"skipHtmlTags": [
"script",
"noscript",
"style",
"textarea",
"pre",
"code",
"annotation",
"annotation-xml",
"tt",
"nowiki",
"kbd",
"syntaxhighlight",
"plantuml"
],
"ignoreHtmlClass": [
"tex2jax_ignore",
"diff"
],
"menuOptions": {
"settings": {
"zoom": "DoubleClick",
"semantics": true
},
"annotationTypes": {
"TeX": [
"application\/x-tex"
],
"OpenMath": [
"OpenMath"
]
}
}
},
"tex": {
"packages": [
"ams",
"amscd",
"base",
"bbox",
"braket",
"cancel",
"cases",
"centernot",
"colortbl",
"empheq",
"gensymb",
"mathtools",
"mhchem",
"newcommand",
"physics",
"require",
"tagformat",
"textcomp",
"textmacros",
"upgreek",
"verb"
],
"inlineMath": [
[
"\\(",
"\\)"
]
],
"displayMath": [
[
"$$",
"$$"
],
[
"\\[",
"\\]"
]
],
"tags": "ams",
"maxBuffer": 10240,
"macros": []
},
"chtml": {
"scale": 1.25
},
"output": {
"font": "mathjax-pagella"
}
};and loading MathJax via
<script defer src="https://cdn.jsdelivr.net/npm/mathjax@4/tex-mml-chtml.js"></script>Source: mathjax/MathJax