WPTavern: Gutenberg 1.4 Adds HTML Mode for Blocks
Gutenberg 1.4 was released today with a new feature that allows users to edit HTML on a per-block basis. HTML mode can be triggered by toggling the ellipsis menu and selecting the HTML icon. This will switch the block between visual and text mode, without having to switch the entire document into text mode.
Contributors debated on whether or not to place the HTML button in the quick toolbar or to add the button to the side of the block. Eventually, they landed on putting the trash icon, the cog settings, and this new HTML mode under an ellipsis.
Gutenberg testers will also notice that version 1.4 redesigns the editor’s header, grouping content actions to the left and post actions to the right.
This release adds the initial REST API infrastructure for reusable global blocks, an idea Matias Ventura proposed several months ago. The pull request was created by new Gutenberg contributor Robert Anderson, a web and mobile developer at Tumblr. It is based on the technical details that Weston Ruter outlined for creating dynamic reusable blocks. Anderson highlighted a few examples of what this infrastructure will eventually enable for users:
- Convert a block into a reusable block, and give it a name
- Convert a reusable block back into a regular block
- Edit a reusable block within a post and have the changes appear across all posts
- Insert an existing reusable block into a post
- Delete an existing reusable block
Anderson said the next step is adding a core/reusable-block block to the editor that can be rendered and edited, followed by a UI for adding, deleting, attaching, and detaching reusable blocks.
Gutenberg 1.4 will now show a users’ most frequently used blocks when hovering over the inserter. If the editor doesn’t have enough usage data, it will display the paragraph and image blocks by default.
Version 1.3 of the plugin introduced a new feedback option for testers with a link in the Gutenberg sidebar menu. Ventura reported that the team has received 12 responses so far, which included four bugs and two proposed enhancements. Check out the full changelog for 1.4 for more details on what’s new in the latest beta release.