-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Load block editor assets in the navigation and widget editors #30076
Load block editor assets in the navigation and widget editors #30076
Conversation
Size Change: 0 B Total Size: 1.41 MB ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice. Before:
After:
I don't think it's related, but just out of an abundance of caution, is there any overlap or conflict between this PR and #30034?
Thanks for flagging it. I don't think there will be a conflict. I do wonder whether 'wp-reset-editor-styles' will be something the nav or widget editors will need. I'll try testing the two together. |
Description
Fixes #21648
Fixes #28874
The
do_action( 'enqueue_block_editor_assets' );
was not being called in the widget and navigation editors.This caused a side effect where
style.scss
styles for blocks were not displayed on those screens when the TT1-blocks theme was active.Additionally, the navigation editor now also uses the
should_load_block_editor_scripts_and_styles
filter appropriately. This triggers some logic in core that enqueueswp-block-library
styles and callsdo_action( 'enqueue_block_assets' )
, a slightly different action.How has this been tested?
Test TT1 blocks
Test enqueueing
Types of changes
Bug fix (non-breaking change which fixes an issue)
Checklist: