Posts, Post Types: Add default `menu_icon` values for built-in post types.

This allows the icons to be retrieved via `get_post_type_object()`.

Props m.usama.masood, michael.ecklund, SergeyBiryukov.
Fixes #38844.
Built from https://develop.svn.wordpress.org/trunk@47196


git-svn-id: http://core.svn.wordpress.org/trunk@46996 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2020-02-05 22:40:05 +00:00
parent 9bb7789f07
commit 39e133bce8
2 changed files with 4 additions and 1 deletions

View File

@ -30,6 +30,7 @@ function create_initial_post_types() {
'capability_type' => 'post',
'map_meta_cap' => true,
'menu_position' => 5,
'menu_icon' => 'dashicons-admin-post',
'hierarchical' => false,
'rewrite' => false,
'query_var' => false,
@ -54,6 +55,7 @@ function create_initial_post_types() {
'capability_type' => 'page',
'map_meta_cap' => true,
'menu_position' => 20,
'menu_icon' => 'dashicons-admin-page',
'hierarchical' => true,
'rewrite' => false,
'query_var' => false,
@ -85,6 +87,7 @@ function create_initial_post_types() {
'create_posts' => 'upload_files',
),
'map_meta_cap' => true,
'menu_icon' => 'dashicons-admin-media',
'hierarchical' => false,
'rewrite' => false,
'query_var' => false,

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.4-alpha-47195';
$wp_version = '5.4-alpha-47196';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.