Add toolbar block appender to the navigation block#74263
Draft
Add toolbar block appender to the navigation block#74263
Conversation
5909ebd to
9f93522
Compare
|
Size Change: +162 B (+0.01%) Total Size: 2.59 MB
ℹ️ View Unchanged
|
5022b07 to
10a55a5
Compare
f7b6614 to
d593f48
Compare
|
Warning: Type of PR label mismatch To merge this PR, it requires exactly 1 label indicating the type of PR. Other labels are optional and not being checked here.
Read more about Type labels in Gutenberg. Don't worry if you don't have the required permissions to add labels; the PR reviewer should be able to help with the task. |
simison
commented
Dec 30, 2025
|
|
||
| _Note:_ | ||
|
|
||
| ## Props |
simison
commented
Dec 30, 2025
| import Inserter from '../inserter'; | ||
|
|
||
| function ToolbarBlockAppender( { | ||
| defaultBlock = { name: 'core/paragraph', attributes: {} }, |
Member
Author
There was a problem hiding this comment.
Instead of hardcoding paragraph here, should pull dynamically current default block for the current block.
3 tasks
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Resolves #73647
Alternative to #73648
Introduce a toolbar-based [+] inserter for the Navigation block, replacing the in-canvas inserter.
Why
The inline inserter inside the Navigation block often leads to:
A toolbar-based inserter provides:
How
ToolbarBlockAppendercomponent, similar toButtonBlockAppender:[ + ]iconInsertercomponent withtogglePropsfor consistencyBlockToolbarLastItemdefaultBlockpropQuestions/thoughts
Should open the dropdown to select a block by default, or always directly insert a block?

Should check if block allows inner blocks before adding itself to the toolbar?
Should pull the default inner block from the block where this is used, thus not requiring passing the default block to the component?
Testing Instructions
Testing Instructions for Keyboard
Screenshots or screencast
Screen.Recording.2025-12-30.at.15.52.21.mov
Screen.Recording.2025-12-30.at.15.52.41.mov