Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal for Enhancing the Navigation Block to Support Mega Menu Creation #61021

Open
nirav7707 opened this issue Apr 24, 2024 · 0 comments
Open
Labels
[Block] Navigation Affects the Navigation Block [Type] Enhancement A suggestion for improvement.

Comments

@nirav7707
Copy link
Contributor

nirav7707 commented Apr 24, 2024

Why we need ?

enhancing the core/navigation-submenu block to allow for the creation of mega menus within the Navigation Block.

Many websites feature extensive navigation menus with numerous links, often requiring linear menus that limit the number of items per row. This restricts the flexibility of design and organization. By expanding the capabilities of the core/navigation-submenu block to accommodate more inner blocks, users will have the ability to construct mega menus. This enhancement will enable users to categorize links more effectively and provide greater freedom in customizing the visual layout of the menu.

What need to update ?

  • Can create variation of the core/navigation-submenu but core/navigation-submenu uses the useInnerBlocksProps so can't able to manage the allowedBlock attribute value by filter so variation didn't work.
  • Update wp-content/plugins/gutenberg/packages/block-library/src/navigation-submenu/edit.js Edit function and add filter for core/navigation-submenu block. also can remove default block or move default block from edit function to block.json ( ref: Allow setting defaultBlock in navigation block #52610 )
  • Screenshot 2024-04-24 at 9 44 07 AM

Enhancement outcome:

Megamenu.mp4
@nirav7707 nirav7707 added the [Type] Enhancement A suggestion for improvement. label Apr 24, 2024
@jordesign jordesign added the [Block] Navigation Affects the Navigation Block label Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Navigation Affects the Navigation Block [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

No branches or pull requests

2 participants