Closed pkra closed 8 years ago
I have created a more minimal example that exhibits the same behavior. There are no
The issue is that Firefox and Chrome treat the empty MathJax_Preview span that precedes the typeset math differently in this situation. In Firefox, the empty span is treated as in-line material and so the block level expression needs to start a new line following that material. In Chrome, the fact that the span is empty seems to be taken into account and Chrome puts the block-level material at the top of the list item.
If the MathJax_Preview span is removed, Firefox's output is the same as Chrome's. So adding he following
<script type="text/x-mathjax-config">
if (MathJax.Hub.Borwser.isFirefox) {
Mathjax.Hub.Queue(function () {
var previews = document.querySelectAll(".MathJax_Preview");
for (var i = 0, m = previews.length; i < m; i++) {
previews[i].parentNode.removeChild(previews[i]);
}
});
}
</script>
to the page somewhere before the script that loads MathJax.js should clear up the issue.
@pkra, do we want to think about removing the previews ourselves? There are reasons these weren't removed which we can discuss if you want to consider it.
@pkra, do we want to think about removing the previews ourselves?
Yes, let's discuss this at the next F2F.
Actually, it turns out that setting display:none
also has the desired effect, so that might be the better approach.
:+1:
@pkra, do we want to add this to 2.7, since the change is minimal?
@dpvc sounds good to me.
==> In testsuite
MathMLToDisplay/issue1555.html
==> Merged
From a user report elsewhere.
Firefox:
Chrome
I haven't had a chance to take a closer look, so labeling it
investigate
.