Button: rename and deprecate describedBy prop #63483
Labels
[Package] Components
/packages/components
[Status] In Progress
Tracking issues with work in progress
[Type] Code Quality
Issues or PRs that relate to code quality
Description
The button
describedBy
prop name is misleading.It is inspired by the ARIA property
aria-describedby
which suggests it would accept an ID reference. Instead, it accepts astring
, which is the actual description text.It actually renders a visually hidden description, correctly associated to the button via
aria-describedby
. As such, a more appropriate, less confusing, prop name would bedescription
.To my understanding, other props have already been deprecated and `aliased' to new names so this wouldn't be unprecedented.
Cc @WordPress/gutenberg-components
Step-by-step reproduction instructions
describedBy
is astring
.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
The text was updated successfully, but these errors were encountered: