Inline KaTeX musí zůstat inline i v HTML jinak přidává mezery, kam nemá.

This commit is contained in:
Jan Černohorský 2023-11-15 16:03:51 +01:00
parent 0f7ed0ae32
commit 05ffd321d8

View file

@ -243,7 +243,11 @@ class HTMLGenerator(OutputGenerator):
"DisplayMath": True,
"InlineMath": False
}
self.writeraw(self.katexClient.render(e.text, {"displayMode": formats[e.format]}))
rawhtml = self.katexClient.render(e.text, {"displayMode": formats[e.format]})
if (e.format == "InlineMath"):
self.write(rawhtml)
else:
self.writeraw()
def generate_RawInline(self, e: RawInline):
if e.format == "html":