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 the gutenberg-block-directory experimental flag #23389

Merged
Show file tree
Hide file tree
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
1 change: 0 additions & 1 deletion lib/block-directory.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
*/

if (
gutenberg_is_experiment_enabled( 'gutenberg-block-directory' ) &&
! has_action( 'admin_enqueue_scripts', 'enqueue_block_editor_assets_block_directory' )
) {
/**
Expand Down
12 changes: 0 additions & 12 deletions lib/experiments-page.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,17 +62,6 @@ function gutenberg_initialize_experiments_settings() {
'id' => 'gutenberg-navigation',
)
);
add_settings_field(
'gutenberg-block-directory',
__( 'Block Directory', 'gutenberg' ),
'gutenberg_display_experiment_field',
'gutenberg-experiments',
'gutenberg_experiments_section',
array(
'label' => __( 'Enable block directory search', 'gutenberg' ),
'id' => 'gutenberg-block-directory',
)
);
add_settings_field(
'gutenberg-full-site-editing',
__( 'Full Site Editing', 'gutenberg' ),
Expand Down Expand Up @@ -143,7 +132,6 @@ function gutenberg_display_experiment_section() {
function gutenberg_experiments_editor_settings( $settings ) {
$experiments_settings = array(
'__experimentalEnableLegacyWidgetBlock' => gutenberg_is_experiment_enabled( 'gutenberg-widget-experiments' ),
'__experimentalBlockDirectory' => gutenberg_is_experiment_enabled( 'gutenberg-block-directory' ),
'__experimentalEnableFullSiteEditing' => gutenberg_is_experiment_enabled( 'gutenberg-full-site-editing' ),
'__experimentalEnableFullSiteEditingDemo' => gutenberg_is_experiment_enabled( 'gutenberg-full-site-editing-demo' ),
);
Expand Down
8 changes: 0 additions & 8 deletions lib/rest-api.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,10 +119,6 @@ function gutenberg_register_rest_widget_areas() {
* @since 6.5.0
*/
function gutenberg_register_rest_block_directory() {
if ( ! gutenberg_is_experiment_enabled( 'gutenberg-block-directory' ) ) {
return;
}

$block_directory_controller = new WP_REST_Block_Directory_Controller();
$block_directory_controller->register_routes();
}
Expand Down Expand Up @@ -159,10 +155,6 @@ function gutenberg_register_rest_customizer_nonces() {
* Registers the Plugins REST API routes.
*/
function gutenberg_register_plugins_endpoint() {
if ( ! gutenberg_is_experiment_enabled( 'gutenberg-block-directory' ) ) {
return;
}

$plugins = new WP_REST_Plugins_Controller();
$plugins->register_routes();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@ import {
getEditedPostContent,
createJSONResponse,
} from '@wordpress/e2e-test-utils';
/**
* Internal dependencies
*/
import { useExperimentalFeatures } from '../../experimental-features';

// Urls to mock
const SEARCH_URLS = [
Expand Down Expand Up @@ -173,8 +169,6 @@ const matchUrl = ( reqUrl, urls ) => {
};

describe( 'adding blocks from block directory', () => {
useExperimentalFeatures( [ '#gutenberg-block-directory' ] );

beforeEach( async () => {
await createNewPost();
} );
Expand Down
6 changes: 0 additions & 6 deletions phpunit/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,6 @@ function fail_if_died( $message ) {
}
tests_add_filter( 'wp_die_handler', 'fail_if_died' );

$GLOBALS['wp_tests_options'] = array(
'gutenberg-experiments' => array(
'gutenberg-block-directory' => '1',
),
);

// Start up the WP testing environment.
require $_tests_dir . '/includes/bootstrap.php';

Expand Down