My math-field freeze(can't type inside it) with Mathquill Matheditor when I try to translate Mathquill equation into LaTeX language.
<span id="math-field" class="mathquill-textbox" />
<textarea id="latex" name="content" />
This is the current mathquill script that I use: https://github.com/jipsen/matheditor/blob/master/mathquill.js
Here is the original script from Mathquill.com's front page that does nothing:
<p>Type math here: <span id="math-field"></span></p>
<p>LaTeX of what you typed: <span id="latex"></span></p>
<script>
var mathFieldSpan = document.getElementById('math-field');
var latexSpan = document.getElementById('latex');
var MQ = MathQuill.getInterface(2); // for backcompat
var mathField = MQ.MathField(mathFieldSpan, {
spaceBehavesLikeTab: true, // configurable
handlers: {
edit: function() { // useful event handlers
latexSpan.textContent = mathField.latex(); // simple API
}
}
});
</script>