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

[HTML formatter] Use span for .line, put code inside <code> #572

Merged
merged 1 commit into from
Nov 10, 2021

Conversation

CIAvash
Copy link
Contributor

@CIAvash CIAvash commented Nov 10, 2021

Apparently only "phrasing content" are permitted inside pre and code, and div is not one of them, so replaced it with span, div wasn't necessary anyway.

Also it makes sense to put code inside code tag(except for line numbers).

Removed overflow:auto and width: auto from table as they didn't seem to be necessary and actually prevented horizontal scroll bar to appear when content didn't fit in the viewport.

Apparently only "phrasing content" are permitted inside `pre` and
`code`, and `div` is not one of them, so replace it with `span`, `div`
wasn't necessary anyway.

Also it makes sense to put code inside `code` tag(except for line
numbers).

Removed `overflow:auto` and `width: auto` as they didn't seem to be
necessary and actually prevented horizontal scroll bar to appear when content
didn't fit in the viewport.
@alecthomas alecthomas merged commit d6e61d3 into alecthomas:master Nov 10, 2021
@CIAvash CIAvash deleted the phrasing_content branch November 10, 2021 09:38
QuLogic added a commit to QuLogic/go-org that referenced this pull request Feb 28, 2022
- 0.9.2 added `tabindex="0"` to `pre`:
  alecthomas/chroma#515
- 0.10.0 changed around divs and spans, pre and code
  alecthomas/chroma#571
  alecthomas/chroma#572
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

Successfully merging this pull request may close these issues.

2 participants