From f111f0c215d0fcc4c3f43bd1e2bebe6e341d621d Mon Sep 17 00:00:00 2001 From: jasmussen Date: Tue, 1 Feb 2022 10:43:41 +0100 Subject: [PATCH 1/2] Images: Try moving responsive rule to common.scss. --- packages/block-library/src/common.scss | 10 ++++++++++ packages/block-library/src/image/style.scss | 2 -- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/packages/block-library/src/common.scss b/packages/block-library/src/common.scss index 7d2892f57cead9..df5bcf279a0371 100644 --- a/packages/block-library/src/common.scss +++ b/packages/block-library/src/common.scss @@ -120,3 +120,13 @@ html :where(.has-border-color) { html :where([style*="border-width"]) { border-style: solid; } + + +/** + * Provide baseline responsiveness for images. + */ + +html :where(img) { + height: auto; + max-width: 100%; +} diff --git a/packages/block-library/src/image/style.scss b/packages/block-library/src/image/style.scss index fe61a93e629566..4a5742f0ff6754 100644 --- a/packages/block-library/src/image/style.scss +++ b/packages/block-library/src/image/style.scss @@ -2,8 +2,6 @@ margin: 0 0 1em 0; img { - height: auto; - max-width: 100%; vertical-align: bottom; } From 092177706cf55ed7986a5792bb7466861f8a52ca Mon Sep 17 00:00:00 2001 From: Joen A <1204802+jasmussen@users.noreply.github.com> Date: Tue, 1 Feb 2022 15:39:48 +0100 Subject: [PATCH 2/2] Update packages/block-library/src/common.scss Co-authored-by: Kjell Reigstad --- packages/block-library/src/common.scss | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/block-library/src/common.scss b/packages/block-library/src/common.scss index df5bcf279a0371..a40014302b2409 100644 --- a/packages/block-library/src/common.scss +++ b/packages/block-library/src/common.scss @@ -125,7 +125,6 @@ html :where([style*="border-width"]) { /** * Provide baseline responsiveness for images. */ - html :where(img) { height: auto; max-width: 100%;