-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Gutenberg Bug - Nested WP Element Styles Broken #52646
Comments
Trac ticket for the bugfix merge when it's ready: https://core.trac.wordpress.org/ticket/58811 |
I have done some testing, it seems that disabling this solves it |
Also, optimize does not default to false, it defaults to true? wp-includes/style-engine/class-wp-style-engine-processor.php @type bool $optimize Whether to optimize the CSS output, e.g., combine rules. Default is
|
until this gets resolved, this is a temporary work around, put this in your theme. Enforce the option to be passed into the function, remove the action hook first and re-add add_action( 'wp_enqueue_scripts', 'fix_enqueue_stored_styles' ); function fix_enqueue_stored_styles() { |
Thanks for filing this issue and noticing the discrepancy. I've flipped the default to false here: |
Description
I'm noticing some very weird behavior in the latest version of Gutenberg. It appears that the logic for inline styles is broken. Here's a video showing, 6.2.2, and an unmodified twenty twenty three theme:
https://www.youtube.com/watch?v=YRpz5xJfHZw
It seems to me that WordPress is unable to output the styles in the correct order, causing the wrong styles to override. WordPress is combining multiple styles when the color is the same, which causes specific styles on descendant elements to be hoisted to a higher level.
Step-by-step reproduction instructions
Multiple related bugs and steps to reproduce demonstrated in the video.
Screenshots, screen recording, code snippet
https://www.youtube.com/watch?v=YRpz5xJfHZw
Environment info
WordPress 6.2.2, unmodified Twenty twenty three theme, Chrome
Please confirm that you have searched existing issues in the repo.
Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Yes
The text was updated successfully, but these errors were encountered: