Auto expand html blocks

  • Instead of showing a scroll bar for each html block (and having them showing only a few lines of code per time) it would be much more convenient to have it auto expand to fit the entire code within.

  • Hi there:

    Can you give us a link to an example where this is showing? And are you talking about the HTML block (where you can compose posts using HTML) or the Code block? Once we have that information, we’ll be better able to advise.

    Thanks!

  • When you are using the Gutenberg editor and you have an HTML block, it only shows a few lines of code and has a scroll bar on the right side.

    It would be better if the block auto expanded itself.

    There’s no link to it, it’s not visible to the public, it’s a feature request for the editor. Sorry if I didn’t make it clear.

  • And yes, the HTML block, not the “code” one.

  • Hi there,

    To confirm, you are requesting that the HTML block doesn’t use a scroll bar after a few lines of code like this:

    But, have the block fully expand to see the entire code in one view like this:

    Whenever I need to see more of the code written in the block, I convert the page to the code editor:

    However, this may complicate things if you have more than just the HTML block on the page.

    I’d be happy to submit this idea internally to our dev team. Let me know if you have any other questions.

    Thanks!

  • Hi! Thanks for your post.

    I have multiple blocks on a single page/post/reusable block.

    A few of them may be html “type” blocks.

    Each of those blocks (on Gutenberg editor) will be small and only show about five lines of code.

    Each of those “html blocks” should expand automatically to fit the entire code. It would also fix scrolling if the mouse rests over one of those “html blocks” while editing, since by default we’d need to scroll the entire html block to scroll the page, forcing us to move the mouse pointer to the “page scroll bar” while doing that.

    It would also allow us to see many more lines of code instead of a few per time.

    If I only had one block it would be easy, I’d just use “code view”. The suggestion for improvement would be so “html blocks” always expand to fit the entire code, the same way other blocks do.

    If I write a long paragraph, it will automatically resize itself to fit all the content, so I can just click what I want to edit and change it.

    If I paste multiple lines of code, I’d love to have the same behavior.

    Thanks a lot for getting back so quickly. I hope you find my idea useful 😇

  • Thanks for the details! We’ll pass that along!

  • Hm, actually, I don’t see any WordPress.com sites under your account here.

    What is the URL of the site with the problem?

  • Ah, ok then. :)

    Because WordPress.com and WordPress.org are two entirely separate entities, we cannot access files or data for sites that are hosted elsewhere, so WordPress.com staff can only assist with sites that are hosted on our servers. You can find more information here about the differences between WordPress.org software and WordPress.com: https://wordpress.com/support/com-vs-org/

    https://wordpress.org/support/ is a great resource for sites using the open source WordPress.org software, and you can find support for that at: https://wordpress.org/support/forums/

    And, in this case, I recommend filing the feature request under the editor’s development platform at https://github.com/WordPress/gutenberg/issues

  • Oh, I get it. I don’t give you profit, you’re not expect to support me (I am totally ok with that, by the way, I didn’t notice I was “posting in the wrong forum”, please accept my apologies). But… You are still a single platform, right?

    Isn’t the editor shared between both (org and com)?

    If so, I guess that my suggestion would be useful no matter what.

    😉

  • We’re not a singular platform, there are some built-in differences here, and WordPress.com and WordPress.org are two different entities: https://wordpress.com/support/com-vs-org/

    For example, if we were to implement this feature here, it may only be implemented here.

    So, if you are using WordPress.org, it would be best to request the feature at https://github.com/WordPress/gutenberg/issues

  • Thank you so much! I am so sorry I can’t afford for your premium version. I’ll look forward sharing my idea there then.

    I wish you have a great weekend and thanks again for your time! 🤗

  • The topic ‘Auto expand html blocks’ is closed to new replies.