4
$\begingroup$

This answer seems to overflow into the HNQ. The bold text is written in latex. Why would anyone do that, I have no idea. But is this a known bug?

OS: Windows 10

Browser: MS Edge 136.0.3240.64

enter image description here

$\endgroup$
6
  • $\begingroup$ Also on Mac Sequoia 15.3.2 with Vivaldi 7.3.3635.12. If MauvaiseFoi had bothered to use the native Markdown syntax (i.e., **something**), it wouldn't overflow. $\endgroup$ Commented May 10 at 18:48
  • 3
    $\begingroup$ Though my 2 pennies is that this is insignificant enough a change that you should just do it yourself, though why reporting that MathJax is overflowing is a good thing to follow up on. $\endgroup$ Commented May 10 at 18:50
  • 3
    $\begingroup$ I tried it on a couple platforms, and they both showed it. Then I fixed it. $\endgroup$ Commented May 10 at 19:16
  • 4
    $\begingroup$ I believe it is intended behavior that inline expressions ($...$) are never automatically wrapped. This just happened to be a really long one. $\endgroup$ Commented May 10 at 19:54
  • 1
    $\begingroup$ Even if it is strictly speaking a bug the up side is that it discourages users from formatting text via MathJax, something which 1. MathJax is not intended for 2. Adds to the rendering time and 3. Is pointless given the capabilities of Markdown $\endgroup$ Commented May 12 at 21:01
  • $\begingroup$ I have just verified that this behavior also occurs on comments as well (latest version of Chrome on Windows 11, with this comment). $\endgroup$ Commented May 15 at 0:46

1 Answer 1

3
$\begingroup$

MathJax's text-mode support is quite limited, so it's unsurprising that linebreaks within a long \text block are broken. This seems to be a specific MathJax limitation:

Automatic line breaking has not yet been implemented in MathJax version 3, but is high on our list for inclusion in a future release.

Based on my recalled experiences (but not on doing any searches today) of looking at the same questions on desktop versus on mobile, display-mode mathematics do some amount of line-breaking. Within an environment like \begin{align}, the line-breaking is turned off, and a wide display equation appears inside of a scrollable frame. For inline mathematics, however, I think there is never any line-breaking: a long inline equation just wraps to the next line, as would averylongwordlikethisoneunlesshyphenationwereenabledinwhichcasetherewouldbesomemoreintelligentwraparound.

Compare the display-mode $$ e^x = \frac1{0!} + \frac{x}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} + \frac{x^4}{4!} + \frac{x^5}{5!} + \frac{x^6}{6!} + \frac{x^7}{7!} + \frac{x^8}{8!} + \frac{x^9}{9!} + \frac{x^{10}}{10!} + \frac{x^{11}}{11!} + \frac{x^{12}}{12!} + \frac{x^{13}}{13!} + \frac{x^{14}}{14!} + \frac{x^{15}}{15!} + \cdots, $$ which wraps on the desktop display I'm using at the moment, versus the inline-mode $ e^x = \frac1{0!} + \frac{x}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} + \frac{x^4}{4!} + \frac{x^5}{5!} + \frac{x^6}{6!} + \frac{x^7}{7!} + \frac{x^8}{8!} + \frac{x^9}{9!} + \frac{x^{10}}{10!} + \frac{x^{11}}{11!} + \frac{x^{12}}{12!} + \frac{x^{13}}{13!} + \frac{x^{14}}{14!} + \frac{x^{15}}{15!} + \cdots $. The second of these begins on a new line, and the MathJax block wraps to a second new line, but the period following the final $ shows up in the wrong place and the first word of the next sentence does as well.

Here's a screenshot of how it looks on my machine:

enter image description here

$\endgroup$

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.