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

Remove <hr> declarations #75

Merged
merged 1 commit into from
Aug 9, 2024
Merged

Remove <hr> declarations #75

merged 1 commit into from
Aug 9, 2024

Conversation

atjn
Copy link
Contributor

@atjn atjn commented Aug 8, 2024

I believe the <hr> declarations do more harm than good. I have made a test document to show what I mean.
Source: https://codepen.io/atjn/pen/qBzXydJ

In these pictures, you see a comparison between Firefox (left), WebKit (middle), and Chromium (right).

In the first picture, the modern-normalize declarations are not enabled:

Skærmbillede fra 2024-08-09 01-03-43

As you can see, all browsers display the <hr> in the same way, so there is no need for normalization. (There is one exception when applying a color, but that can't be fixed with CSS, it requires changes to Chromium)

In the second picture, the modern-normalize declarations are enabled:

Skærmbillede fra 2024-08-09 01-04-57

First, you can observe that the height: 0px declaration is no longer needed, since modern Firefox already uses that.
Second, you will notice that the color: inherit declaration did not normalize anything, instead it created a new compat issue when colors are inherited.

It might make sense to add color: inherit in #13 (modern-base) because it provides a better default, but it does not belong in the normalization sheet.

@sindresorhus sindresorhus merged commit 42c631d into sindresorhus:main Aug 9, 2024
2 checks passed
@atjn atjn deleted the hr branch August 9, 2024 23:07
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