-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Further preserve original CSS cascade when hoisting late-printed styles #10601
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
base: trunk
Are you sure you want to change the base?
Further preserve original CSS cascade when hoisting late-printed styles #10601
Conversation
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Core Committers: Use this line as a base for the props when committing in SVN: To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
|
Cascade when
And when
When the block styles are grouped under the related
The cascade is the same, with the difference being that |
Test using WordPress PlaygroundThe changes in this pull request can previewed and tested using a WordPress Playground instance. WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser. Some things to be aware of
For more details about these limitations and more, check out the Limitations page in the WordPress Playground documentation. |
fc14aa9 to
523be88
Compare
…into trac-64354-fix-hoisted-css-cascade
|
@westonruter When it comes to writing tests, are you able to include some for non-core block variations too. |
|
@peterwilsoncc you mean like in 2fb1c42? |
Trac ticket: https://core.trac.wordpress.org/ticket/64354
TODO
classic-theme-stylesis not enqueued.global-stylesis not enqueued.enqueue_block_assetswill get printed afterclassic-theme-stylesviaenqueue_block_styles_assets().Note that we do not need to consider what
wp_enqueue_registered_block_scripts_and_styles()outputs because it short-circuits ifwp_should_load_block_assets_on_demand()is enabled, andwp_hoist_late_printed_styles()will not run when on-demand loading is disabled.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.