-
Notifications
You must be signed in to change notification settings - Fork 13.5k
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
bug: remove global hidden attribute styles #17583
Comments
I would say, more than only remove the On my code I do have an Even having the value of the property set to This, or, at least for that specific use case, the render logic should remove the |
@ElNinjaGaiden Yes, I think that it should be removed entirely since it interferes with the functionality of the native attribute. My only concern is that it may be a breaking change to some apps if we remove this, so I would need to do some more thorough testing on it. |
resolves #17583 BREAKING CHANGE: The `[hidden]` attribute has been removed from Ionic's global stylesheet. The `[hidden]` attribute can continue to be used, but developers will get the [native `hidden` implementation](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/hidden) instead. The main difference is that the native implementation is easier to override using `display` than Ionic's implementation. Developers can add the following CSS to their global stylesheet if they need the old behavior: ```css [hidden] { display: none !important; } ```
This was fixed in #25829. Please note that since this is a breaking change, the fix will be available in Ionic 7, the next major release. |
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out. |
Bug Report
Ionic version:
[x] 4.x
Current behavior:
We have the following CSS in the global
core
stylesheet:This causes conflicts with the native
hidden
attribute, see the MDN docs here: https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/hiddenExpected behavior:
This style should not be there or it should not use
!important
. It may be seen as a breaking change to remove it but I'd argue it is a fix to a problem because it interferes with the native functionality of the attribute. Up for discussion.Steps to reproduce:
!important
does not override either)Other information:
I stumbled on this while reviewing the following PR: #17359
The text was updated successfully, but these errors were encountered: