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

Reduce the spacing around the display math element. #272

Closed
akhmerov opened this issue Jan 3, 2021 · 3 comments
Closed

Reduce the spacing around the display math element. #272

akhmerov opened this issue Jan 3, 2021 · 3 comments
Labels
enhancement New feature or request 🏷️ design Related to look and feel of the theme

Comments

@akhmerov
Copy link
Contributor

akhmerov commented Jan 3, 2021

Is your feature request related to a problem? Please describe.

Check out the spacing below and above a display math element embedded in text:

  • Example from the theme docs:

image


  • Example with more text:

image


I think the spacing between the equation and the text around does not look good—the top margin is way larger than the bottom one.

Describe the solution you'd like

Not the best CSS expert here, but I imagine adjusting bottom margin on a <p> followed by a mathjax div would do.

Describe alternatives you've considered

...some other CSS adjustments.

@akhmerov akhmerov added the enhancement New feature or request label Jan 3, 2021
@choldgraf
Copy link
Member

+1 from me, I agree it should be symmetric around both. If anybody wants to try a PR I'm happy to review!

@akhmerov
Copy link
Contributor Author

akhmerov commented Jan 4, 2021

One tricky thing here is that we're dealing with a semantically incorrect DOM here regardless since display math is a part of the paragraph to which it belongs (see also sphinx-doc/sphinx#8166).

@choldgraf choldgraf added the 🏷️ design Related to look and feel of the theme label Jan 20, 2021
@choldgraf
Copy link
Member

closed via #369

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request 🏷️ design Related to look and feel of the theme
Projects
None yet
Development

No branches or pull requests

2 participants