-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Try always generating navigation post title (#36760)
* Try always generating navigation title * Show placeholder preview * Add useCreateNavigationMenu * Update packages/block-library/src/navigation/edit/use-default-navigation-title.js * Fix placeholder and remove unecessary logic. * Pass clientId to placeholder. * Reset inner blocks when creating new menu * Only consider published Navigations as valid * Correct bug with checking status of Nav post * UX to allow creating new menu if associated Nav post not found Previously you could get into an error state if the Nav block referenced a Nav Post which had been deleted. You could not recover from this as the UI provided no way to "start over". This addition affords that ability. * Switch to useGenerateDefaultNavigationTitle * Wrap createNewMenu in useCallback * Rename createNewMenu to startWithEmptyMenu Co-authored-by: Adam Zieliński <[email protected]> Co-authored-by: Dave Smith <[email protected]>
- Loading branch information
1 parent
5cf67a8
commit a07e386
Showing
8 changed files
with
184 additions
and
264 deletions.
There are no files selected for viewing
This file contains 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
69 changes: 0 additions & 69 deletions
69
packages/block-library/src/navigation/edit/navigation-menu-name-modal.js
This file was deleted.
Oops, something went wrong.
57 changes: 0 additions & 57 deletions
57
packages/block-library/src/navigation/edit/navigation-menu-publish-button.js
This file was deleted.
Oops, something went wrong.
This file contains 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
Oops, something went wrong.