Adds the widgets block editor to widgets.php and customize.php

Moves the widgets block editor from Gutenberg into WordPress Core.

- Adds @wordpress/edit-widgets, @wordpress/customize-widgets and
  @wordpress/widgets.
- Modifies wp-admin/widgets.php to branch between the old editor and new editor
  depending on wp_use_widgets_block_editor().
- Modifies WP_Customize_Widgets to branch between the old editor control and new
  editor control depending on wp_use_widgets_block_editor().

Fixes #51506.
Props isabel_brison, TimothyBlynJacobs, andraganescu, kevin940726, talldanwp.


git-svn-id: https://develop.svn.wordpress.org/trunk@50996 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Robert Anderson
2021-05-25 08:38:04 +00:00
parent bc48d7ae09
commit 00bc227eb8
16 changed files with 973 additions and 811 deletions

View File

@@ -1552,6 +1552,20 @@ function wp_default_styles( $styles ) {
'list-reusable-blocks' => array( 'wp-components' ),
'reusable-blocks' => array( 'wp-components' ),
'nux' => array( 'wp-components' ),
'edit-widgets' => array(
'wp-components',
'wp-block-editor',
'wp-edit-blocks',
'wp-block-library',
'wp-reusable-blocks',
),
'customize-widgets' => array(
'wp-components',
'wp-block-editor',
'wp-edit-blocks',
'wp-block-library',
'wp-reusable-blocks',
),
);
foreach ( $package_styles as $package => $dependencies ) {