[$$]...[/$$] sometimes introduces blank lines breaking eg tikzcd

I’ve just upgraded to Anki version 23.12.1 on a Mac (from version 2.1.65). I’m trying to add a card using LaTeX with tikzcd, but when Anki generates the tmp.tex, it seemingly randomly introduces blank lines. With this input in the “Add” window card content (with preceding text):

[$$]\begin{tikzcd}
x & y
\end{tikzcd}[/$$]

the generated tmp.tex file contained

\begin{displaymath}\begin{tikzcd}
x & y

\end{tikzcd}\end{displaymath}

(which breaks because of the blank line inside the tikzcd environment), but on editing the card content and re-editing back to the way it was, the tmp.tex file then contained the correct

\begin{displaymath}\begin{tikzcd}
x & y
\end{tikzcd}\end{displaymath}

This is a new problem that I have never experienced before.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.