Replies: 4 comments 3 replies
-
Great catch, definitely looks like we can ditch this: https://github.com/necolas/normalize.css/blob/master/normalize.css#L343-L349 If you want to open a PR for it I'm happy to merge it 👍 |
Beta Was this translation helpful? Give feedback.
-
Appreciative for sharing such mind blowing information. |
Beta Was this translation helpful? Give feedback.
-
Unfortunately this is not quite as simple as “all browsers support this default behavior” if you look deeper you’ll see:
So in those cases |
Beta Was this translation helpful? Give feedback.
-
Not sure if this is worth a proper bug report but thought I’d mention this is causing style regressions in Tailwind 3.1.1. The preflight styles force replaced elements to Here is a simple example where this happens (see Tailwind Play demo). In Tailwind 3.1, this image is visible. In previous releases, it’s hidden, just like in vanilla HTML when no styles are applied: <img src="404.png" width="64" height="64" alt="" hidden> In my case this was happening with a Considering this is changing existing styles I would expect this kind of change to only be done in a major release, ideally with note of the breakage and instructions on what to do about it. For now, it would be nice to revert this in 3.1 so people can confidently upgrade and benefit from the new features without having to worry about this type of breakage. Alternatively, go for a change like this PR to normalize.css, which preserves the previous behavior (I think?) while making it possible to use |
Beta Was this translation helpful? Give feedback.
-
Is there any reason why this style is still kept in preflight?
All supported browsers should be capable of handling the default behavior: https://caniuse.com/hidden
Restoring the actual default behavior with this style is non-trivial and destroys upcoming functionality: https://developer.chrome.com/blog/hidden-until-found/
Beta Was this translation helpful? Give feedback.
All reactions