Subsequentily that option should be renamed accordingly as well as added some descriptions on exactly what it disables.
Take the check from the buttons.php:
public function load(): void {
$post_types = wd_asp()->o['asp_compatibility']['meta_box_post_types']; // Allow only for selected post types
$post_types = explode('|', $post_types);
$current_screen = get_current_screen();
if ( is_null($current_screen) || is_wp_error($current_screen) ) {
return;
}
if ( in_array( $current_screen->post_type, $post_types, true ) ) {
add_action( 'admin_head', array( $this, 'addMceVariables' ), 999 );
add_filter( 'mce_external_plugins', array( $this, 'addMceScript' ) );
add_filter( 'mce_buttons', array( $this, 'addMceButton' ) );
}
}
Possibly make a shouldLoad() function on SearchBlocks.php - but be careful about get_current_screen(), it may not exist, as well as if the site editor is active.
Similarly to the classic editor (tinyMCE) the block editor blocks should respect the meta box on post editor screen options.
Subsequentily that option should be renamed accordingly as well as added some descriptions on exactly what it disables.
Take the check from the buttons.php:
Possibly make a
shouldLoad()
function onSearchBlocks.php
- but be careful about get_current_screen(), it may not exist, as well as if the site editor is active.