-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Sort order for categories. #643
Comments
Also important to this topic is whether we want categories to be a one to one relationship or a one to many relationship for blocks. |
What's the use case for one-to-one ? |
registerBlock( {
namespace: core,
name: embed,
categories: [ 'common', 'media' ]
} ); If we want blocks to belong to many categories it will make displaying them a lot more complex. Maybe there is a user experience benefit that outweighs keeping things simple. So in total the relation would become a many to many, which are usually ugly to deal with unless the benefits of it are superior. I personally don't find an urgent need to have multiple categories for each blockType, but this would probably be a good decision for @jasmussen to chime in on. |
We don't want a block to belong to multiple categories, at least for now. There's a PR to allow creating new categories. It's likely we could assign a plugin-block that hasn't specified a category to be under a "Plugins" category. Same for themes. |
This is tied in with the inserter menu. What do we want the default sort order to be for the categories and blocks in those categories? This mainly becomes a concern when other plugins will be able to register blocks and categories.
The text was updated successfully, but these errors were encountered: