-
Notifications
You must be signed in to change notification settings - Fork 324
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
aligned 环境中无法换行 #445
Comments
应该要升级一下 KaTeX 版本 |
升级了也不行,但是看到这个警告
|
@yzhang-gh 那边不是显示是 js 的错误吗,你这个是直接看的 html 结果吗? |
我对 TS 不了解 😂 ,只是说明一下 BUG 是新引入的。我猜和 #426 有关系 🤔 |
我把 #426 引入的 macros 禁用掉就好了, 应该就是这么设计的 问题变成了如果传的参数是 |
@yzhang-gh 我没理解你的意思 😕 |
我前面的意思是说 katex.render("aa\\bb\begin{aligned}aa\\bb\end{aligned}", element, {
displayMode: true
}); 正常,但是 katex.render("aa\\bb\begin{aligned}aa\\bb\end{aligned}", element, {
displayMode: true,
macros: {}
}); 就不正常,不符合一般的期待 之前我以为后者是符合 KaTeX 的设计的,但是现在看来并不是 |
这个是正常的,不知道有没有关系 😕 <!DOCTYPE html>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/katex.min.css" integrity="sha384-yFRtMMDnQtDRO8rLpMIKrtPCD5jdktao2TV19YiZYWMDkUR5GQZR/NOVTdquEx1j" crossorigin="anonymous">
<script defer src="https://cdn.jsdelivr.net/npm/[email protected]/dist/katex.min.js" integrity="sha384-9Nhn55MVVN0/4OFx7EE5kpFBPsEMZxKTCnA+4fqDmg12eCTqGi6+BB2LjY8brQxJ" crossorigin="anonymous"></script>
<script defer src="https://cdn.jsdelivr.net/npm/[email protected]/dist/contrib/auto-render.min.js" integrity="sha384-kWPLUVMOks5AQFrykwIup5lo0m3iMkkHrD0uJ4H5cjeGihAutqP0yW0J6dpFiVkI" crossorigin="anonymous"
onload="renderMathInElement(document.body, {
displayMode: true,
macros: {}
});"></script>
<body>
$$
aa\\bb\\
\begin{aligned}
a\\b
\end{aligned}
$$
</body> |
如果这样是正常的话那应该就不是 KaTeX 的问题了 剩下就只怀疑 |
I have fixed, a PR will come soon. |
Please try out the latest dev build. |
这里没问题 👍 |
多谢 @upupming,合并 PR 之后应该是真正解决了 |
在
aligned
环境中使用\\
无法换行,但环境外可以换行The text was updated successfully, but these errors were encountered: