arnog / mathlive

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

LaTeX in text mode is not parsed correctly when using mf.insert #2419

Open DegrangeM opened 6 days ago

DegrangeM commented 6 days ago

Description

mf.insert("La fonction $f$ est croissante", {insertionMode: "replaceAll"}) does not parse the $f$ when the mathfield defaultMode is set to Text.

Steps to Reproduce

  1. Open : https://output.jsbin.com/qazavuroha
  2. Click on Set Value

Actual Behavior

The $f$ is parsed as Tex.

Expected Behavior

The $f$ should be parsed as LaTeX math.

Environment

MathLive version 0.100.0

Operating System Windows 10

Browser Google Chrome, Firefox