From 7e6cd72166b1b1ade86ed5018470ce957f67f33e Mon Sep 17 00:00:00 2001 From: Jb Audras Date: Mon, 26 Jun 2023 15:04:22 +0000 Subject: [PATCH] Twenty Twenty: Fix left margin in Latest Posts & Latest Comments blocks. This fixes a bug where the `margin-left: auto` property was being overwritten to `margin-left: 0` causing an inconsistency in the alignment of these blocks. Props nkeller15, nadimcse, sabernhardt, tb1909, poena. Fixes #58396. git-svn-id: https://develop.svn.wordpress.org/trunk@56034 602fd350-edb4-49c9-b593-d223f7449a82 --- .../twentytwenty/assets/css/editor-style-block-rtl.css | 7 ++++++- .../themes/twentytwenty/assets/css/editor-style-block.css | 7 ++++++- src/wp-content/themes/twentytwenty/style-rtl.css | 5 +++++ src/wp-content/themes/twentytwenty/style.css | 5 +++++ 4 files changed, 22 insertions(+), 2 deletions(-) diff --git a/src/wp-content/themes/twentytwenty/assets/css/editor-style-block-rtl.css b/src/wp-content/themes/twentytwenty/assets/css/editor-style-block-rtl.css index 4cc3333779..fcc5246aff 100644 --- a/src/wp-content/themes/twentytwenty/assets/css/editor-style-block-rtl.css +++ b/src/wp-content/themes/twentytwenty/assets/css/editor-style-block-rtl.css @@ -458,6 +458,11 @@ Inter variable font. Usage: padding-right: 0; } +.editor-styles-wrapper ul.wp-block-latest-posts { + margin-right: auto; + margin-left: auto; +} + .editor-styles-wrapper ul.wp-block-categories__list ul { margin: 0; } @@ -982,7 +987,7 @@ hr.wp-block-separator.is-style-dots::before { .editor-styles-wrapper .wp-block-latest-comments { font-family: inherit; - margin-right: 0; + margin-right: auto; } .editor-styles-wrapper .wp-block-latest-comments li.wp-block-latest-comments__comment { diff --git a/src/wp-content/themes/twentytwenty/assets/css/editor-style-block.css b/src/wp-content/themes/twentytwenty/assets/css/editor-style-block.css index c8d1610ae4..bff6710680 100644 --- a/src/wp-content/themes/twentytwenty/assets/css/editor-style-block.css +++ b/src/wp-content/themes/twentytwenty/assets/css/editor-style-block.css @@ -462,6 +462,11 @@ Inter variable font. Usage: padding-left: 0; } +.editor-styles-wrapper ul.wp-block-latest-posts { + margin-left: auto; + margin-right: auto; +} + .editor-styles-wrapper ul.wp-block-categories__list ul { margin: 0; } @@ -986,7 +991,7 @@ hr.wp-block-separator.is-style-dots::before { .editor-styles-wrapper .wp-block-latest-comments { font-family: inherit; - margin-left: 0; + margin-left: auto; } .editor-styles-wrapper .wp-block-latest-comments li.wp-block-latest-comments__comment { diff --git a/src/wp-content/themes/twentytwenty/style-rtl.css b/src/wp-content/themes/twentytwenty/style-rtl.css index cb02433f6e..158119328a 100644 --- a/src/wp-content/themes/twentytwenty/style-rtl.css +++ b/src/wp-content/themes/twentytwenty/style-rtl.css @@ -2925,6 +2925,11 @@ h2.entry-title { list-style: none; } +ol.wp-block-latest-comments { + margin-left: auto; + margin-right: auto; +} + .entry-content .wp-block-archives > li, .entry-content .wp-block-categories > li, .entry-content .wp-block-latest-posts > li, diff --git a/src/wp-content/themes/twentytwenty/style.css b/src/wp-content/themes/twentytwenty/style.css index 393da269b4..8287d9263c 100644 --- a/src/wp-content/themes/twentytwenty/style.css +++ b/src/wp-content/themes/twentytwenty/style.css @@ -2945,6 +2945,11 @@ h2.entry-title { list-style: none; } +ol.wp-block-latest-comments { + margin-left: auto; + margin-right: auto; +} + .entry-content .wp-block-archives > li, .entry-content .wp-block-categories > li, .entry-content .wp-block-latest-posts > li,