-
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
Cover Block: Fix default background dim #36312
Conversation
Size Change: +8 B (0%) Total Size: 1.08 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.
Just to clarify - the issue only happens with the default black dim that's added just after you add the Cover
block, which was lost before this fix. That being said, this tests well!
Hi @noisysocks, It seems that this PR wasn't backported in WP 5.9 RC2. |
@dianeco Thanks for reporting this. I wasn't able to replicate it: Are you able to share the block markup of both versions, ie. copy and paste ` chunk from editor code view from 5.8.3 and then after reloading the editor in 5.9? It might be a combination of the attributes you have set for the cover that is causing this to happen in your instance. @noisysocks I have checked and it looks like this patch is included in 5.9 as the default dimRatio of 50 is applied when adding a new cover with media. |
@glendaviesnz I discovered an issue and maybe wrongly assumed that this PR was fixing it. My issue is that the overlay opacity on covers previously created with WP 5.8 isn't applied in WP 5.9 RC 2 (and Gutenberg). To reproduce:
Let me know if I should open a new issue. |
WP 5.9 includes all versions ≤ Gutenberg 11.9, so this PR will have automatically been included. @dianeco: Yes, please create an issue 😀 |
Description
After #35065, the default background dim for the Cover block disappeared. This PR fixes it.
What caused the bug?
In #35065 we changed the Cover block's markup which caused the
has-background-dim
class to not take effect anymore as it's no longer paired with the top-levelwp-block-cover
class. This PR fixes thehas-background-dim
class dependency.Default Cover block's markup before #35065:
Default Cover block's markup after #35065:
Fixes #36310
How has this been tested?
trunk
npx wp-env start && npm run dev
)Screenshots
Types of changes
Bug fix
Checklist:
*.native.js
files for terms that need renaming or removal).