arnog / mathlive

A web component for easy math input
https://cortexjs.io/mathlive
MIT License
1.26k stars 260 forks source link

Uneven vertical spacing on top and bottom of fractions #2411

Open andrew-murdza opened 1 week ago

andrew-murdza commented 1 week ago

Code:

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Change FontShape of MathField</title>
  <script defer src="https://unpkg.com/mathlive"></script>
  <script src="mathjax-config.js" defer></script>
  <script type="text/javascript" id="MathJax-script" defer
          src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-svg.js">
  </script>
</head>
<body>
<math-field id='mf' readonly>\frac{1}{3}</math-field>
\(\displaystyle\frac{1}{3}\)
</body>
</html>

Screenshot image

Steps to Reproduce

Run the html code

Actual Behavior

The MathLive fraction (on the left) has more vertical spacing on the bottom than the top

Expected Behavior

For the fraction to be like the one on the right.