refactor: simplify renderer drain handling and expand LaTeX arrow replacements

This commit is contained in:
mitchell 2026-05-14 02:52:49 -04:00
parent 7367cfdfe3
commit 0ed6a23334
2 changed files with 10 additions and 16 deletions

View file

@ -152,8 +152,12 @@ export async function renderMarkdown(
image: () => chalk.red("Images are unsupported (for now)\n"),
text: (children) =>
children
.replaceAll("$\\rightarrow$", "->")
.replaceAll("$\\leftarrow$", "<-")
.replaceAll("$\\rightarrow$", "-->")
.replaceAll("$\\leftarrow$", "<--")
.replaceAll("$\\leftrightarrow$", "<->")
.replaceAll("$\\Rightarrow$", "==>")
.replaceAll("$\\Leftarrow$", "<==")
.replaceAll("$\\Leftrightarrow$", "<=>")
.replaceAll("$\\to$", "->"),
html: () => chalk.red("HTML is unsupported\n"),
});