From a1175f69c28716e213aff211d133ea5e2ce95ffe Mon Sep 17 00:00:00 2001 From: Andrew Serong <14988353+andrewserong@users.noreply.github.com> Date: Tue, 27 Feb 2024 12:20:04 +1100 Subject: [PATCH 1/2] Cover Block: Restore overflow: clip rule to allow border radius again --- packages/block-library/src/cover/style.scss | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/block-library/src/cover/style.scss b/packages/block-library/src/cover/style.scss index 3b4eac41a0d3b4..3cc674f93787d7 100644 --- a/packages/block-library/src/cover/style.scss +++ b/packages/block-library/src/cover/style.scss @@ -9,8 +9,7 @@ padding: 1em; // Prevent the `wp-block-cover__background` span from overflowing the container when border-radius is applied. // 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. From 944280306ed597735fbaa3b2c927bf68882ca83d Mon Sep 17 00:00:00 2001 From: Andrew Serong <14988353+andrewserong@users.noreply.github.com> Date: Tue, 27 Feb 2024 12:45:24 +1100 Subject: [PATCH 2/2] Fully restore to prior to aspect ratio PR --- packages/block-library/src/cover/style.scss | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/block-library/src/cover/style.scss b/packages/block-library/src/cover/style.scss index 3cc674f93787d7..837e3834e2e1ba 100644 --- a/packages/block-library/src/cover/style.scss +++ b/packages/block-library/src/cover/style.scss @@ -8,6 +8,8 @@ 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. overflow: clip; // This block has customizable padding, border-box makes that more predictable.