GB Editor Widths

In GeneratePress, the Post and Block Element editor width can be set.

The Post Editor width can be set with the Layout Metabox (Default, Full Width, or Contained).

The Block Element editor width defaults to the Element Type selected, or can be overridden with a manually entered Editor Width (% or px).

Both of these work well and closely represent the expected front-end. They also work well if the site is using the generate_block_editor_content_width filter, which only applies if not full width and not in the Element Block editor. This filter is great for closely matching the front end of sites where a max-width is set with CSS for the .grid-container when not using a sidebar, for example.

Local Template and Global Styles Editor Width

In GB, however, the Local Template and Global Style editors seem fixed to the default contained width.

It seems to me that these editors should either default to full width, or provide an Editor Width setting similar to the Block Element editor in GPP.

If you insert a container into the Local Template editor and set it as full width, it’s still confined by the contained width set by the editor. Of course, it renders properly on the front end, but this makes it harder to visualize in the editor.

If generate_block_editor_content_width is being used, things get weird. The full width of the container in the editor will be the width of the filter’s value, while the contained width remains default. So, a container with full width set will actually render narrower than the contained width.

I’m not sure the best way to change this, but for consistency I think the GB Local Template and Global Styles editor widths should be full width by default, or behave more like the Block Element editor. In either case, the generate_block_editor_content_width filter probably shouldn’t apply in these editors.