Posts, Post Types: Introduce `item_trashed` post type label.

This allows the block editor to announce the correct message when an entity is moved to the Trash.

Original issue from Gutenberg repository:
* [https://github.com/WordPress/gutenberg/issues/19144 #19144 Wrong notification message shown when an entity is moved to trash]

Props james-roberts, ntsekouras, nrqsnchz, afercia, swissspidy, joedolson, talldanwp, SergeyBiryukov.
Fixes #51387.
Built from https://develop.svn.wordpress.org/trunk@55923


git-svn-id: http://core.svn.wordpress.org/trunk@55435 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2023-06-15 01:39:20 +00:00
parent bf7d51c86d
commit c965fefd6e
3 changed files with 4 additions and 1 deletions

View File

@ -857,6 +857,7 @@ final class WP_Post_Type {
'item_published' => array( __( 'Post published.' ), __( 'Page published.' ) ),
'item_published_privately' => array( __( 'Post published privately.' ), __( 'Page published privately.' ) ),
'item_reverted_to_draft' => array( __( 'Post reverted to draft.' ), __( 'Page reverted to draft.' ) ),
'item_trashed' => array( __( 'Post trashed.' ), __( 'Page trashed.' ) ),
'item_scheduled' => array( __( 'Post scheduled.' ), __( 'Page scheduled.' ) ),
'item_updated' => array( __( 'Post updated.' ), __( 'Page updated.' ) ),
'item_link' => array(

View File

@ -1957,6 +1957,7 @@ function _post_type_meta_capabilities( $capabilities = null ) {
* Default is 'Post published privately.' / 'Page published privately.'
* - `item_reverted_to_draft` - Label used when an item is switched to a draft.
* Default is 'Post reverted to draft.' / 'Page reverted to draft.'
* - `item_trashed` - Label used when an item is moved to Trash. Default is 'Post trashed.' / 'Page trashed.'
* - `item_scheduled` - Label used when an item is scheduled for publishing. Default is 'Post scheduled.' /
* 'Page scheduled.'
* - `item_updated` - Label used when an item is updated. Default is 'Post updated.' / 'Page updated.'
@ -1980,6 +1981,7 @@ function _post_type_meta_capabilities( $capabilities = null ) {
* `item_scheduled`, and `item_updated` labels.
* @since 5.7.0 Added the `filter_by_date` label.
* @since 5.8.0 Added the `item_link` and `item_link_description` labels.
* @since 6.3.0 Added the `item_trashed` label.
*
* @access private
*

View File

@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.3-alpha-55922';
$wp_version = '6.3-alpha-55923';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.