From 2404b6bd7453cb6d6eca2e1b105feb0ff0c3455f Mon Sep 17 00:00:00 2001 From: Kelly Dwan Date: Tue, 11 Apr 2023 17:21:21 -0400 Subject: [PATCH 1/3] Remove unnecessary width from label This was creating an overflow to the right on Chrome --- .../wp-content/themes/wporg-parent-2021/sass/blocks/_search.scss | 1 - 1 file changed, 1 deletion(-) diff --git a/source/wp-content/themes/wporg-parent-2021/sass/blocks/_search.scss b/source/wp-content/themes/wporg-parent-2021/sass/blocks/_search.scss index 911f802d..92c760a7 100644 --- a/source/wp-content/themes/wporg-parent-2021/sass/blocks/_search.scss +++ b/source/wp-content/themes/wporg-parent-2021/sass/blocks/_search.scss @@ -16,7 +16,6 @@ margin-top: var(--wp--custom--margin--baseline); > label { - width: 100%; margin-bottom: calc(var(--wp--custom--form--padding) / 2); font-size: var(--wp--custom--form--typography--font-size); color: var(--wp--custom--form--color--label); From da6a29d205196a8533e99811eaf3838ad71586b5 Mon Sep 17 00:00:00 2001 From: Kelly Dwan Date: Tue, 11 Apr 2023 17:22:24 -0400 Subject: [PATCH 2/3] Wrap text when it breaks out of the blocks container --- .../wp-content/themes/wporg-parent-2021/sass/base/_layout.scss | 1 + 1 file changed, 1 insertion(+) diff --git a/source/wp-content/themes/wporg-parent-2021/sass/base/_layout.scss b/source/wp-content/themes/wporg-parent-2021/sass/base/_layout.scss index a24bbf64..dde2c4f7 100644 --- a/source/wp-content/themes/wporg-parent-2021/sass/base/_layout.scss +++ b/source/wp-content/themes/wporg-parent-2021/sass/base/_layout.scss @@ -3,6 +3,7 @@ display: flex; flex-direction: column; min-height: calc(100vh - var(--wp-global-header-offset, 0px) - var(--local-header-height, 0px)); + overflow-wrap: break-word; > main, > article { From 48e7eb6328bf4bfadc3eb5d575b29a28e6f4f4cb Mon Sep 17 00:00:00 2001 From: Kelly Dwan Date: Tue, 11 Apr 2023 17:22:57 -0400 Subject: [PATCH 3/3] Force `pre` blocks to scroll to retain code formatting --- .../themes/wporg-parent-2021/sass/blocks/_index.scss | 1 + .../themes/wporg-parent-2021/sass/blocks/_preformatted.scss | 5 +++++ 2 files changed, 6 insertions(+) create mode 100644 source/wp-content/themes/wporg-parent-2021/sass/blocks/_preformatted.scss diff --git a/source/wp-content/themes/wporg-parent-2021/sass/blocks/_index.scss b/source/wp-content/themes/wporg-parent-2021/sass/blocks/_index.scss index 5b50a268..805f03d5 100644 --- a/source/wp-content/themes/wporg-parent-2021/sass/blocks/_index.scss +++ b/source/wp-content/themes/wporg-parent-2021/sass/blocks/_index.scss @@ -8,6 +8,7 @@ @import "post-excerpt"; @import "post-navigation-link"; @import "post-title"; +@import "preformatted"; @import "pullquote"; @import "query-pagination"; @import "quote"; diff --git a/source/wp-content/themes/wporg-parent-2021/sass/blocks/_preformatted.scss b/source/wp-content/themes/wporg-parent-2021/sass/blocks/_preformatted.scss new file mode 100644 index 00000000..bf9e6d63 --- /dev/null +++ b/source/wp-content/themes/wporg-parent-2021/sass/blocks/_preformatted.scss @@ -0,0 +1,5 @@ +.wp-block-preformatted { + white-space: pre; + overflow-x: scroll; + overflow-wrap: normal; +}