-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Closed as not planned
Labels
[Feature] Block APIAPI that allows to express the block paradigm.API that allows to express the block paradigm.[Feature] Block Validation/DeprecationHandling block validation to determine accuracy and deprecationHandling block validation to determine accuracy and deprecation[Status] Needs More InfoFollow-up required in order to be actionable.Follow-up required in order to be actionable.[Status] StaleGives the original author opportunity to update before closing. Can be reopened as needed.Gives the original author opportunity to update before closing. Can be reopened as needed.[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended
Description
Description
It seems that data-*
attributes are not parsed by hpq
library and consequently not as a block attribute. Given their special nature I can understand that. This is perhaps a known issue, but I want to confirm that.
To clarify more, see below:
Step-by-step reproduction instructions
in blocks.json
, block attribute definition
{
...
"openSelector": {
"type": "string",
"source": "attribute",
"attribute": "data-open-selector"
},
...
}
result: openSelector attribute is undefined each time and causes This block contains unexpected or invalid content.
error, since it is not parsed from the block. I use instead openSelector without "source" and "attribute" instead, so it is written in a block comments, but it would be nice to know if this is known and accepted issue, or bug.
Screenshots, screen recording, code snippet
No response
Environment info
No response
Please confirm that you have searched existing issues in the repo.
Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Yes
Metadata
Metadata
Assignees
Labels
[Feature] Block APIAPI that allows to express the block paradigm.API that allows to express the block paradigm.[Feature] Block Validation/DeprecationHandling block validation to determine accuracy and deprecationHandling block validation to determine accuracy and deprecation[Status] Needs More InfoFollow-up required in order to be actionable.Follow-up required in order to be actionable.[Status] StaleGives the original author opportunity to update before closing. Can be reopened as needed.Gives the original author opportunity to update before closing. Can be reopened as needed.[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended