Add support for latex blocks / environments

current support for latex fragments was inline only, i.e. lines containing block
elements (e.g. a line starting with `* `, i.e. a headline) will not be parsed
as part of the latex fragment but the respective block element. Parsing latex
blocks at the block level should fix that. Note that in any case we don't do
any processing and just emit the raw latex (leaving the rendering to e.g. js).
This commit is contained in:
Niklas Fasching 2022-11-02 14:16:57 +01:00
parent 05a2dedbf8
commit 1849701ba7
8 changed files with 77 additions and 5 deletions

View file

@ -6,8 +6,18 @@ we support <code class="verbatim">\(...\)</code>, <code class="verbatim">\[...\]
<li>\[\sum_{i=1}^n a_n\]</li>
<li>$$\sum_{i=1}^n a_n$$</li>
<li>\begin{xyz}\sum_{i=1}^n a_n\end{xyz}</li>
<li>\begin{xyz}
<li>
\begin{xyz}
\sum_{i=1}^n a_n
\end{xyz}</li>
\end{xyz}
</li>
<li>$2 + 2$, $3 - 3$</li>
<li>
\begin{xyz}
latex block ignores block lvl elements (e.g. list - line starting with -)
a = b
- c
- d
\end{xyz}
</li>
</ul>

View file

@ -10,3 +10,9 @@ we support =\(...\)=, =\[...\]=, =$$...$$= and =\begin{$env}...\end{$env}= as la
\sum_{i=1}^n a_n
\end{xyz}
- $2 + 2$, $3 - 3$
- \begin{xyz}
latex block ignores block lvl elements (e.g. list - line starting with -)
a = b
- c
- d
\end{xyz}

View file

@ -10,3 +10,9 @@ we support =\(...\)=, =\[...\]=, =$$...$$= and =\begin{$env}...\end{$env}= as la
\sum_{i=1}^n a_n
\end{xyz}
- $2 + 2$, $3 - 3$
- \begin{xyz}
latex block ignores block lvl elements (e.g. list - line starting with -)
a = b
- c
- d
\end{xyz}