Custom classes and IDs are removed from admin notices #12320
Labels
Backwards Compatibility
Issues or PRs that impact backwards compatability
[Package] Notices
/packages/notices
[Type] Bug
An existing feature does not function as intended
Companion ticket for Trac-45418.
Custom classes and IDs are stripped from admin notices, making it impossible for plugin and theme developers to specifically target their notices.
Describe the bug
A clear and concise description of what the bug is.
To Reproduce
Add an admin notice using the
admin_notices
action hook that has custom classes and an ID attribute.Open the editor screen and inspect the notice. It has the Gutenberg notice class (
components-notice is-error
), and nothing else.Expected behavior
The custom classes and ID should be preserved.
The text was updated successfully, but these errors were encountered: