mirror of
https://github.com/cotes2020/jekyll-theme-chirpy.git
synced 2026-08-05 21:37:37 +00:00
99614aede3
Since the MathJax 4 upgrade (97a537e), the `mjx-container` overflow
rules were dropped, so long display equations extend past the viewport
and cause page-level horizontal scrolling on mobile (the fix from #545
for #543 was lost). MathJax 4 defaults to `displayOverflow: 'overflow'`;
set it to 'scroll' so long equations scroll within their own container.
30 lines
785 B
JavaScript
30 lines
785 B
JavaScript
---
|
|
layout: compress
|
|
# WARNING: Don't use '//' to comment out code, use '{% comment %}' and '{% endcomment %}' instead.
|
|
---
|
|
|
|
{%- comment -%}
|
|
See: <https://docs.mathjax.org/en/latest/options/input/tex.html#tex-options>
|
|
{%- endcomment -%}
|
|
|
|
MathJax = {
|
|
tex: {
|
|
{%- comment -%} start/end delimiter pairs for in-line math {%- endcomment -%}
|
|
inlineMath: [
|
|
['$', '$'],
|
|
['\\(', '\\)']
|
|
],
|
|
{%- comment -%} start/end delimiter pairs for display math {%- endcomment -%}
|
|
displayMath: [
|
|
['$$', '$$'],
|
|
['\\[', '\\]']
|
|
],
|
|
{%- comment -%} equation numbering {%- endcomment -%}
|
|
tags: 'ams'
|
|
},
|
|
output: {
|
|
{%- comment -%} scroll long display equations instead of overflowing the page {%- endcomment -%}
|
|
displayOverflow: 'scroll'
|
|
}
|
|
};
|