Skip to content

Commit

Permalink
Cover Block: Restore overflow: clip rule to allow border radius again (
Browse files Browse the repository at this point in the history
…#59388)

* Cover Block: Restore overflow: clip rule to allow border radius again

* Fully restore to prior to aspect ratio PR

Co-authored-by: andrewserong <andrewserong@git.wordpress.org>
Co-authored-by: ramonjd <ramonopoly@git.wordpress.org>
Co-authored-by: tellthemachines <isabel_brison@git.wordpress.org>
Co-authored-by: luminuu <luminuu@git.wordpress.org>
  • Loading branch information
5 people authored Feb 27, 2024
1 parent 2b2a2be commit c349d27
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/block-library/src/cover/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@
align-items: center;
padding: 1em;
// Prevent the `wp-block-cover__background` span from overflowing the container when border-radius is applied.
// `overflow: hidden` is provided as a fallback for browsers that don't support `overflow: clip`.
overflow: hidden;
// Use clip instead of overflow: hidden so that sticky position works on child elements.
// Use overflow-x instead of overflow so that aspect-ratio allows content to expand the area of the cover block.
overflow-x: clip;
overflow: clip;
// This block has customizable padding, border-box makes that more predictable.
box-sizing: border-box;
// Keep the flex layout direction to the physical direction (LTR) in RTL languages.
Expand Down

0 comments on commit c349d27

Please sign in to comment.