From f1c0e5856e71f1431e1cd1ef9d6775bb8495b532 Mon Sep 17 00:00:00 2001 From: Tammie Lister Date: Mon, 27 May 2024 12:41:32 +0000 Subject: [PATCH] Twenty Seventeen: Resolves image block caption text alignment inconsitency. The caption for image block was misaligned. The issue appeared in 5.8 due to the block class name change making the selector meaningless. This is resolved by a change in the selectors. Props nkeller15, sabernhardt, thakordarshil, anilvaza, shailu25, pavanpatil1, darshitrajyaguru97. Fixes #58539. git-svn-id: https://develop.svn.wordpress.org/trunk@58207 602fd350-edb4-49c9-b593-d223f7449a82 --- .../twentyseventeen/assets/css/editor-blocks.css | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/wp-content/themes/twentyseventeen/assets/css/editor-blocks.css b/src/wp-content/themes/twentyseventeen/assets/css/editor-blocks.css index c17df295a3351..60907122cda81 100644 --- a/src/wp-content/themes/twentyseventeen/assets/css/editor-blocks.css +++ b/src/wp-content/themes/twentyseventeen/assets/css/editor-blocks.css @@ -458,15 +458,19 @@ html[lang="th"] .edit-post-visual-editor * { margin-top: 0.5em; } -/* Caption styles*/ +/* Caption styles */ -[class^="wp-block-"]:not(.wp-block-gallery) figcaption { +[class^="wp-block-"]:not(.wp-block-gallery) > figcaption, +[class*=" wp-block-"]:not(.wp-block-gallery) > figcaption { font-style: italic; margin-bottom: 1.5em; text-align: left; } -.rtl [class^="wp-block-"]:not(.wp-block-gallery) figcaption { +.rtl [class^="wp-block-"]:not(.wp-block-gallery) > figcaption, +.rtl [class*=" wp-block-"]:not(.wp-block-gallery) > figcaption, +[dir="rtl"] [class^="wp-block-"]:not(.wp-block-gallery) > figcaption, +[dir="rtl"] [class*=" wp-block-"]:not(.wp-block-gallery) > figcaption { text-align: right; }