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

Doesn't add hljs class to inline code #25

Closed
Maxim-Mazurok opened this issue Apr 5, 2022 · 1 comment
Closed

Doesn't add hljs class to inline code #25

Maxim-Mazurok opened this issue Apr 5, 2022 · 1 comment

Comments

@Maxim-Mazurok
Copy link

I see this in most themes:

code.hljs {
  padding: 3px 5px;
}

And I see similar thing for inline code on github:

.markdown-body code{
    padding: 0.2em 0.4em;
}

and on SO:

.s-prose *:not(.s-code-block)>code {
    padding: 2px 4px;

So I'm guessing that idea in highlights is that this padding is supposed to be added to inline code. But this class hljs is not being added :( Would be great to add it. Thanks!

@valeriangalliat
Copy link
Owner

Good catch! I think it's potentially breaking if people expected the hljs class to not be present, so I bumped a major, v4.0.0 (actually needs to be v4.0.1 because of a publish mistake) that now sets hljs on inline code class. Cheers :)

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

2 participants