-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Update conditional logic for editor_styles #3916
Conversation
Tests for failing for
for the last assertion in this test: public function test_block_styles_for_editing_without_theme_support() {
// Confirm we are without theme support by default.
$this->assertFalse( current_theme_supports( 'wp-block-styles' ) );
wp_default_styles( $GLOBALS['wp_styles'] );
$this->assertFalse( wp_style_is( 'wp-block-library-theme' ) );
wp_enqueue_style( 'wp-edit-blocks' );
$this->assertTrue( wp_style_is( 'wp-block-library-theme' ) );
} Looking at the code in this PR, the In reading the intent of the original Gutenberg PR:
this does appear to be the intent, i.e. if the theme doesn't support I'll update the unit test accordingly. |
Thank you for updating that test, @hellofromtonya 🙇♂️
This is correct 👍 |
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.
Tested for both TT2 and TT3 https://core.trac.wordpress.org/ticket/57561#comment:13
- Fixes the issue for TT3, a theme that does not add
'wp-block-styles'
theme support ✅ - Does not impact TT2, a theme that does add
'wp-block-styles'
theme support ✅
This PR is ready for commit 👍
Committed via https://core.trac.wordpress.org/changeset/55368. |
Trac ticket: https://core.trac.wordpress.org/ticket/57561
This Pull Request is for code review only. Please keep all other discussion in the Trac ticket. Do not merge this Pull Request. See GitHub Pull Requests for Code Review in the Core Handbook for more details.