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 renderer doesn't fully take into account block type #279

Open
QuietRocket opened this issue Apr 29, 2022 · 4 comments
Open

LaTeX renderer doesn't fully take into account block type #279

QuietRocket opened this issue Apr 29, 2022 · 4 comments

Comments

@QuietRocket
Copy link

Description

In Notion, there are both inline equations and block equations. They should be rendered differently, however it appears that react-notion-x doesn't take this into account. For instance, in Notion, integrals appear small in inline equations and large in block equations. In react-notion-x, however, they appear the same way (small). I believe passing the displayMode option in KaTeX rectifies this problem, as mentioned in the KaTeX documentation. The exact way to do this though might be a little different since a react wrapper package is used.

Notion:
Screen Shot 2022-04-29 at 12 25 32 AM

React-Notion-X:
Screen Shot 2022-04-29 at 12 26 04 AM

Notion Test Page ID

df2adb88d5b34105bc397074001b9b69

@transitive-bullshit
Copy link
Member

Hmmm, we definitely handle block vs inline usage differently, though I agree that it looks like Notion's rendering of equation blocks has changed since it was initially implemented. See https://react-notion-x-demo.transitivebullsh.it/7820b2d5300747b38e31344eb06fbd57 for a live example.

This shouldn't be too hard to fix. PRs welcome 🙂

@Thooooor
Copy link

I also had this problem when using \tag in formulas. The \tag only works when 'displayMode' is true. And I fixed this problem and PR.

@yangkang2318
Copy link

I also had this problem when using \tag in formulas. The \tag only works when 'displayMode' is true. And I fixed this problem and PR.

Could you please tell me how to fix this? Thanks!

@Thooooor
Copy link

Thooooor commented May 9, 2022

I also had this problem when using \tag in formulas. The \tag only works when 'displayMode' is true. And I fixed this problem and PR.

Could you please tell me how to fix this? Thanks!

#281 see this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants