Support » Plugin: Gutenberg » Why doesn’t default block editor width = content width

  • Resolved patbell101

    (@patbell101)


    A year passed and I head back to gutenberg but the editor width is STILL too narrow and still no dice for me, and I would have thought it a no-brainer. I have seen much discussion but no real solutions, usually passing the buck to the theme. Sorry folks but if you want the block editor to be adopted you have to listen. Making it “distraction free” by default doesn’t hack it, it just hides stuff. Why not just make the default editor width the same as the current content width.

    I did find a plugin that looks abandoned but which only gave a choice between full-width or vertical letterbox default.

    Or have I missed something?

Viewing 10 replies - 1 through 10 (of 10 total)
  • Anonymous User 14934761

    (@anonymized-14934761)

    Are you saying WYSIWYG style or current window width?

    I actually believe the future of Gutenberg should be seamless front end WYSIWYG editing just like the third party page builders but more clutter-less and less developer oriented and more consumer oriented.

    If the backend width doesn’t match the front end width, I think that is a huge mistake!

    I think we agree. Essentially the backend editor width should reflect the content width as displayed on the front end. There are plugins that give full width editing but it makes layout difficult when it doesn’t match the end result.

    Anonymous User 14934761

    (@anonymized-14934761)

    I am not a dev, but as an internet marketer and entrepreneur my gut was that Gutenberg should basically become a WYSIWYG editor in order to compete with Wix, Squarespace and others that are heavily taking larger slice of the content management systems usage percentage. If you are a developer, could you register into GitHub and describe the issue as if I do it, it would be more like a laic person trying to explain it with no coding information as an addition?

    If anyone from the Gutenberg team is here and reading, could you point to the ticket or drive attention to this.

    To me, it is far more important than anything I see you do like changing colors and fixing pixels etc which I see. Let’s fix the big stuff and do the polishing later I guess.

    I say “we” as I feel like this is a community, despite me not being a developer.

    Plugin Author Joen A.

    (@joen)

    Hi @patbell101, I responded to something similar in https://wordpress.org/support/topic/suggestion-text-width-in-gutenberg-based-on-theme/.

    You’ve clearly heard the message before: that the editor is as wide as the theme designs it to be. So I won’t repeat that.

    > Why not just make the default editor width the same as the current content width.

    Efforts to make the editor WYSIWYG have been underway for a while, and it’s quite the technical challenge. As things improve here, it’s very likely that fewer and fewer WordPress themes don’t style the editor at all, and it might even be possible to load the stylesheet of older themes directly into the editor.

    May I ask: which WordPress theme are you running?

    Am on wp 5.4 I would think that just matching the editor width to existing content width wouldn’t be full wysiwyg but a much welcomed approximation.

    The new default to full screen that obliterates the admin menu is annoying too. I would like to mix and match between elementor and gutenberg (if the editor was a sensible width) and exiting from an elementor page to a full screen editor and having to switch it off each time is a pain.

    I chose Elementor shortly after gutenberg was launched because gutenberg lacked the sophistication I needed to develop sites and train others to do so. I do wonder who gutenberg is being designed for, the editor width is a good case in point who would want the vertical letter box default? The classic editor was limited true and gutenberg is making strides in the right direction. Its getting there but certain no-brainer design flaws stop me from adopting it. I will keep coming back but for now, nice try but no cigar.

    • This reply was modified 1 month, 2 weeks ago by patbell101.
    Plugin Author Joen A.

    (@joen)

    Your thoughts are much appreciated, and I’m happy there are other options than the block editor that meets your needs.

    The reason I ask about which WordPress theme you’re running is that in order for WYSIWYG to land, despite that answer not being the most satisfying, it really is the job of the WordPress theme itself, not the editor.

    What you see in the editor in absence of the theme providing the width of the editor, is a line-width that is optimized for readibility, which is about 70 characters per line at the default font size. But this is still recognizing that this width is not a good fit for everyone, which is why the theme can change this.

    OK thats clearer. I am using the Hello Elementor theme that is intentionally minimal. What can I insert to specify the editor width?

    Plugin Author Joen A.

    (@joen)

    Ah yes, that helps! It appears that the “Hello” theme has zero support for the block editor, so you see the fallback styles. So there are a couple of things to try:

    – Contact the theme author and ask them to support the block editor.
    – Switch to a theme that does support the block editor.
    – Use the classic editor.
    – Try to add support for the block editor yourself.

    The 4th item is a bit roundabout, but if you’re feeling adventurous, here’s how it’s done:

    1. First, open the wp-content/themes/hello-elementor/functions.php file.

    2. Search for add_editor_style, and replace the text so it says this:

    
    			/*
    			 * Editor Style.
    			 */
    			add_theme_support('editor-styles');
    			add_editor_style( 'editor-style.css' );
    

    3. Open the wp-content/themes/hello-elementor/style-editor.css, and add the following at the end:

    
    /* Main column width */
    .wp-block {
        max-width: 960px;
    }
     
    /* Width of "wide" blocks */
    .wp-block[data-align="wide"] {
        max-width: 1080px;
    }
     
    /* Width of "full-wide" blocks */
    .wp-block[data-align="full"] {
        max-width: none;
    }
    

    That should get you the same width of blocks in the editor as they are on the frontend.

    Note that if you do edit these files yourself, there is a chance if you update the theme later on, that those changes will have to be reapplied. But given the theme doesn’t have block editor support, I would wager to guess it’s not receiving updates much anymore.

    Hope that helps!

    Anonymous User 14934761

    (@anonymized-14934761)

    “What you see in the editor in absence of the theme providing the width of the editor, is a line-width that is optimized for readability, which is about 70 characters per line at the default font size. But this is still recognizing that this width is not a good fit for everyone, which is why the theme can change this.”

    When you have a long form content and you want to divide the paragraphs, you need to be able to see the content as the user would see it when read it. If the number of lines is different than what the paragraph looks in the end result that creates confusion of the writer, which should go back and re-edit the text many times.

    That is why matching what is displayed in Gutenberg and the end result in terms of everything – width, style, font, etc should be 1:1.

    I do use a lot of themes and I am not ready to code-edit them one by one. I don’t think every developer would be able to update their theme. Also, these days a lot of themes are rented, you pay a subscription, when you stop – they stop updating. A lot of businesses and non-profit organizations and personal blogs run outdated themes.

    On these, you could still get full front page editing with third party page builders. I don’t believe in third party page builders, their locking and future development of the ecosystem, I also don’t like their slownless.

    The thing is, I think Gutenberg and WordPress in general should start finding a way to implement and take these styles from the themes and apply them in Gutenberg rather than waiting for theme developers and theme owners to have the latest version that supports it. Let’s be real – many themes won’t be updated unfortunately, will we leave them with no WYSIWYG support?

    Not sure if that is possible but it will be better if Gutenberg finds a way to do that from the themes rather than waiting for theme developers and theme owners to implement it.

    I think having the same width is critical for an editor to write something. How long the paragraphs should be, how he could present it’s logic so that the end user UX should match what he represented in the editor. If your logic is spread in a paragraph with 5-6 sentences and it looks long, but when you cut it in half it doesn’t make logical sense for the next paragraphs, you still have to rephrase the sentences. The length of the paragraphs and their width should match what the end user sees.

    Also I believe there should be a toggle option for other kind of content where people need to long-form scan the article for other things. In that case, people with 27″ inch iMacs, wide screens of 32″, 34″ and 38″ inch monitors, should be able to see, when they choose a toggle, their content in a width of their window so that they could see a very long form content stretched on their screen, similar to what you would achieve with the classic editor.

    Plugin Author Joen A.

    (@joen)

    > The thing is, I think Gutenberg and WordPress in general should start finding a way to implement and take these styles from the themes and apply them in Gutenberg rather than waiting for theme developers and theme owners to have the latest version that supports it. Let’s be real – many themes won’t be updated unfortunately, will we leave them with no WYSIWYG support?

    I hear you.

    While efforts are underway to make the editor markup behave and appear as closely as possible to the frontend, I’m afraid the opt-in is unlikely to ever go away, as it is impossible to guarantee the theme style will work perfectly in the editor. I believe it should be possible to write a plugin that forces an old theme to opt-in, without having to edit the code.

Viewing 10 replies - 1 through 10 (of 10 total)
  • You must be logged in to reply to this topic.