Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove wp_area custom post type #25497

Merged
merged 1 commit into from
Sep 21, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 0 additions & 55 deletions lib/widgets.php
Original file line number Diff line number Diff line change
Expand Up @@ -217,61 +217,6 @@ function gutenberg_legacy_widget_settings( $settings ) {
}
add_filter( 'block_editor_settings', 'gutenberg_legacy_widget_settings' );

/**
* Registers a wp_area post type.
*/
function gutenberg_create_wp_area_post_type() {
register_post_type(
'wp_area',
array(
'description' => __( 'Experimental custom post type that will store block areas referenced by themes.', 'gutenberg' ),
'labels' => array(
'name' => _x( 'Block Area (Experimental)', 'post type general name', 'gutenberg' ),
'singular_name' => _x( 'Block Area (Experimental)', 'post type singular name', 'gutenberg' ),
'menu_name' => _x( 'Block Areas', 'admin menu', 'gutenberg' ),
'name_admin_bar' => _x( 'Block Area', 'add new on admin bar', 'gutenberg' ),
'add_new' => _x( 'Add New', 'Block', 'gutenberg' ),
'add_new_item' => __( 'Add New Block Area', 'gutenberg' ),
'new_item' => __( 'New Block Area', 'gutenberg' ),
'edit_item' => __( 'Edit Block Area', 'gutenberg' ),
'view_item' => __( 'View Block Area', 'gutenberg' ),
'all_items' => __( 'All Block Areas', 'gutenberg' ),
'search_items' => __( 'Search Block Areas', 'gutenberg' ),
'not_found' => __( 'No block area found.', 'gutenberg' ),
'not_found_in_trash' => __( 'No block areas found in Trash.', 'gutenberg' ),
'filter_items_list' => __( 'Filter block areas list', 'gutenberg' ),
'items_list_navigation' => __( 'Block areas list navigation', 'gutenberg' ),
'items_list' => __( 'Block areas list', 'gutenberg' ),
'item_published' => __( 'Block area published.', 'gutenberg' ),
'item_published_privately' => __( 'Block area published privately.', 'gutenberg' ),
'item_reverted_to_draft' => __( 'Block area reverted to draft.', 'gutenberg' ),
'item_scheduled' => __( 'Block area scheduled.', 'gutenberg' ),
'item_updated' => __( 'Block area updated.', 'gutenberg' ),
),
'public' => false,
'show_ui' => false,
'show_in_menu' => false,
'show_in_rest' => true,
'rest_base' => '__experimental/block-areas',
'capabilities' => array(
'read' => 'edit_posts',
'create_posts' => 'edit_theme_options',
'edit_posts' => 'edit_theme_options',
'edit_published_posts' => 'edit_theme_options',
'delete_published_posts' => 'edit_theme_options',
'edit_others_posts' => 'edit_theme_options',
'delete_others_posts' => 'edit_theme_options',
),
'map_meta_cap' => true,
'supports' => array(
'title',
'editor',
),
)
);
}
add_action( 'init', 'gutenberg_create_wp_area_post_type' );

/**
* Function to enqueue admin-widgets as part of the block editor assets.
*/
Expand Down