diff --git a/wp-content/plugins/core/src/Blocks/Blocks_Subscriber.php b/wp-content/plugins/core/src/Blocks/Blocks_Subscriber.php index 7354860c..702f06c7 100644 --- a/wp-content/plugins/core/src/Blocks/Blocks_Subscriber.php +++ b/wp-content/plugins/core/src/Blocks/Blocks_Subscriber.php @@ -102,10 +102,16 @@ public function register(): void { add_filter( 'should_load_remote_block_patterns', '__return_false' ); /** - * Disable openverse media category. + * Handle Block Editor Settings */ add_filter( 'block_editor_settings_all', function ( array $settings ): array { - return $this->container->get( Theme_Support::class )->disable_openverse_media_category( $settings ); + // Disable openverse media category. + $settings = $this->container->get( Theme_Support::class )->disable_openverse_media_category( $settings ); + + // Disable the WP block editor font library. + $settings = $this->container->get( Theme_Support::class )->disable_font_library_ui( $settings ); + + return $settings; } ); } diff --git a/wp-content/plugins/core/src/Theme_Config/Theme_Support.php b/wp-content/plugins/core/src/Theme_Config/Theme_Support.php index 93ee09f8..b56ce5c9 100644 --- a/wp-content/plugins/core/src/Theme_Config/Theme_Support.php +++ b/wp-content/plugins/core/src/Theme_Config/Theme_Support.php @@ -29,6 +29,15 @@ public function disable_openverse_media_category( array $settings ): array { return $settings; } + /** + * Dsiable the WP block editor font library + */ + public function disable_font_library_ui( array $settings ): array { + $settings['fontLibraryEnabled'] = false; + + return $settings; + } + /** * Disable Block Editor Widget Support */