Open jonathanhu237 opened 4 hours ago
Using the browser's developer tools, I observed that block equations outside lists do not inherit certain CSS properties that are applied to those inside lists.
The figure below shows the CSS properties applied to a block equation within a list.
The figure below displays the properties for a block equation outside a list.
To temporarily address this issue, I added the following CSS:
span.katex-display {
@apply text-skin-base;
}
This fix forces the correct color on the block equation. However, I am not certain if this is the optimal solution or if it may introduce other styling issues. And advice on a more robust fix would be appreciated.
Describe the bug When using the AstroPaper theme with KaTeX for math formula rendering, block equations outside of lists display a color rendering issue. Specifically, the color of these block equations does not adapt to the theme's color scheme (e.g., dark/light mode) and remains fixed at #374151. In contrast, block equations placed inside lists render correctly and respond to the theme's color changes.
To Reproduce Steps to reproduce the behavior:
Expected Behavior Both block equations (inside and outside of lists) should have consistent color rendering and should automatically adapt to the theme's color scheme (dark/light mode).
Actual Behavior
Screenshots