Experiment: Add delete action to taxonomy management#77524
Conversation
|
Size Change: 0 B Total Size: 7.76 MB ℹ️ View Unchanged
|
|
Flaky tests detected in 60b293c. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/24823193902
|
| label: __( 'Delete' ), | ||
| icon: trash, | ||
| supportsBulk: true, | ||
| modalHeader: ( items ) => |
There was a problem hiding this comment.
This action is very similar to trashPost action, so I guess we can have similar config. Remove the modalHeader and add
hideModalHeader: true,
modalFocusOnMount: 'firstContentElement',
Although modalSize:small seems more fitting, I'm curious why we have the medium for trashPost. We should probably see to update the core one to also be small.
There was a problem hiding this comment.
Done in 2e235e7.
Should we figure out the modal size separately?
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
I haven't investigated in depth but it seems like we should do that. Maybe the way forward could be a checkbox (checked by default) to also delete existing terms. Since we're so early with the experiment it's okay by me to handle in a follow up and investigate properly. |
Yep, that makes sense, and a follow-up PR sounds good 👍 This one is ready for a review in the meantime. |
ae776e1 to
60b293c
Compare
ntsekouras
left a comment
There was a problem hiding this comment.
I made some small tweaks to translators' comments and rebased.
LGTM, thank you!
What?
Adds a Delete action to the Taxonomies experiment (Settings > Taxonomies), alongside the existing Edit and Activate/Deactivate actions.
Follow-up to #77497.
What we're not doing
Why?
The Taxonomies experiment lets users create custom taxonomies, but has no way to remove them. Users could only deactivate.
How?
Mirrors the pattern of the existing
editTaxonomyAction:RenderModalconfirmationsupportsBulk: trueso multi-select works from the DataViews bulk actions bar.Modal+isDestructiveprimary button.taxonomyActionsarrayTesting Instructions
Testing Instructions for Keyboard
Same
Screenshots or screencast
Use of AI Tools
Opus 4.7