Skip to content
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

在数学公式块中Latex语法双反斜杠\\被转义为单反斜杠\ #303

Closed
AutoLoop255 opened this issue Apr 20, 2023 · 2 comments
Closed
Labels

Comments

@AutoLoop255
Copy link

首先对这个项目的贡献者和表示由衷的感谢!
谢谢你们让我用到如此好用的插件!
虽然我下面的问题其实脱离了Markdown的范畴,但是作为一个热爱写数学博客的人真的蛮痛苦的,希望大佬能帮助我解决。
(其实我也有一个垃圾的解决方法,就是用四个反斜杠来代替两个反斜杠,但是这样粘贴的时候真的很痛苦!)
問題或臭蟲

在githuber-md中贴入的数学公式块中双反斜杠\\被转义
在$$中无法使用\\,都会被转义为\

如何重現

請告知重現此問題的步驟回何:

  1. 使用mathjax3.2.2解析
  2. 使用$$代码块且里面包含\\
    这里提供一个例子
$$
    \begin{aligned}
    & p_1=v_2 \cdot w_3-v_3 \cdot w_2 \\
    & p_2=v_3 \cdot w_1-v_1 \cdot w_3 \\
    & p_3=v_1 \cdot w_2-v_2 \cdot w_1
    \end{aligned}
$$

預期的行為或結果
这样的结果才是正常的,这是用html使用mathjax3.2.2解析的结果,我将html代码粘贴如下,可以进行复现
image

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<script src="https://cdn.bootcdn.net/ajax/libs/mathjax/3.2.2/es5/tex-chtml-full.js"></script>
<body>
   <p>
    \begin{aligned}
    & p_1=v_2 \cdot w_3-v_3 \cdot w_2 \\
    & p_2=v_3 \cdot w_1-v_1 \cdot w_3 \\
    & p_3=v_1 \cdot w_2-v_2 \cdot w_1
    \end{aligned}
   </p>
</body>
</html>

畫面截圖
如图所示会被转义
image
在网页中会变成这样
image

伺服器環境

  • WordPress 版本 5.7.1
  • WP Githuber MD 版本 1.16.1
  • PHP 版本 8.0

用戶端環境

  • 作業系統 Windows11
  • 瀏覽器 edge浏览器

其它說明
如果有其它解决方案的话可以告诉我,不胜感谢!

@github-actions
Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 2 days.

@github-actions github-actions bot added the stale label Jun 20, 2023
@github-actions
Copy link

This issue was closed because it has been inactive for 14 days since being marked as stale.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Jun 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant