Hi,
I fixed all of the issues, which were caused by subtle shortcomings in
the "dollars" delimiters of the
https://github.com/goessner/markdown-it-texmath plugin. E.g., the
issue with missing text was caused by how that plugin defined equation
labels, so I disabled that functionality. Also, their regexp didn't
work for multiline inline math formulas, e.g.,
$x
+y$
which seems pretty annoying, so I fixed the regexp.
I did not fix "$f(x) [space]".
I'm building an updated docker image and
cocalc.com, which will be
live in about 2 hours assuming nothing goes wrong.
I want to STRONGLY thank you for this excellent and very helpful bug
report! It's painful moving to a proper markdown math parser from the
horrible hacks that we used before (copied from Jupyter classic /
MathJax v2), but it will be much better in the longrun.