Gutenberg Modify core taxonomy panel element via wp.hooks.addFilter

Because your plugin handles both hierarchical and non-hierarchical taxonomies, then I think it might be a better option to copy the HierarchicalTermSelector component, and return the copy from the CustomizeTaxonomySelector function. And you can see how I did it here — Updated to use the JavaScript Build Setup which makes things like transpilation super easy. … Read more

Changing Gutenberg / WP block editor width only on pages, not posts or other taxonomies

Because the WordPress hook add_theme_support( ‘editor-styles’ ); adds the css in the style-editor.css and appends the class .editor-styles-wrapper before my .wp-block, the usage of the body classes for page vs. post styles fails. Instead I use the answer from here, from David Walsh, to add the styles independently to the wp admin area: // Update … Read more

Is it possible to create column width presets in Gutenberg?

Just in case anyone else comes looking here’s what I did. First I enqueued a javascript file into the block editor. add_action( ‘enqueue_block_editor_assets’, function () { wp_enqueue_style( ‘block-editor-styles’, get_template_directory_uri(‘styles/gutenberg.css’), false, ‘1.0’, ‘all’ ); wp_enqueue_script( ‘block-editor-scripts’, get_template_directory_uri(‘scripts/gutenberg.js’), array( ‘wp-blocks’, ‘wp-dom’ ), time(), true ); }); Then I just used this bit of code for adding a … Read more