Skip to content

Commit

Permalink
Fix cover placeholder text color.
Browse files Browse the repository at this point in the history
  • Loading branch information
afercia committed Feb 28, 2025
1 parent 0a6f557 commit 24550fb
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions packages/block-library/src/cover/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,15 @@
background-color: $black;
}

// Make sure the placeholder text is white when has-background-dim default background is black.
// the first selector is required for old Cover markup
&.has-background-dim:not([class*="-background-color"]):not(.is-light),
&:not(.is-light) .has-background-dim:not([class*="-background-color"]) {
& ~ .wp-block-cover__inner-container [data-rich-text-placeholder]::after {
color: $white;
}
}

.has-background-dim.has-background-gradient {
background-color: transparent;
}
Expand Down

0 comments on commit 24550fb

Please sign in to comment.