-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Converting blocks lose anchor tags #7335
Comments
@WordPress/gutenberg-core Do we want to handle this with an abstraction similar to |
It appears #8124 is meant to address this issue. |
#8124 only allows ID attributes, what about other attributes that users may have previously added manually for plugins and such for example? We shouldn't be stripping anything when converting, if we do it should be a migration instead, and it should be clear that attribute data may be lost if it does not adhere to our pre-defined standards. |
👍 You're right. It just addresses a specific instance of this issue. Thanks for correcting. |
Describe the bug
When converting a classic page to blocks, any existing anchor tags on titles are lost. This is despite the block and the original classic content both utilize the
id
attribute to provide the anchor tag.To Reproduce
Steps to reproduce the behavior:
id
attribute on a heading.Expected behavior
Elements that are supported in Gutenberg should be retained when converting, as an aside would it be an idea to not strip non-supported attributes but rather leave in the HTML to avoid breaking content?
Additional context
Gutenberg 3.0.1 (running on WordPress.org, in case there's something special introduced there?)
The text was updated successfully, but these errors were encountered: