Twenty Seventeen and Twenty Ten: Fixes gallery captions being at the bottom of images.

The margin specified in this theme caused issues when the gallery was placed in another block. This fix covers both themes as the selector is used within both.

Props pevogam, sabernhardt.
Fixes #58362.

Built from https://develop.svn.wordpress.org/trunk@58634


git-svn-id: http://core.svn.wordpress.org/trunk@58063 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Tammie Lister 2024-07-03 10:47:16 +00:00
parent f54e344ed8
commit 4d6f01b32d
5 changed files with 9 additions and 9 deletions

View File

@ -30,7 +30,7 @@ figure[class^="wp-block-"] {
font-size: 12px; font-size: 12px;
} }
[class^="wp-block-"]:not(.wp-block-gallery) figcaption { [class^="wp-block-"]:not(.wp-block-gallery) > figcaption {
color: #666; color: #666;
margin-bottom: 1.625em; margin-bottom: 1.625em;
max-width: 96%; max-width: 96%;
@ -40,7 +40,7 @@ figure[class^="wp-block-"] {
text-align: left; text-align: left;
} }
[class^="wp-block-"]:not(.wp-block-gallery) figcaption:before { [class^="wp-block-"]:not(.wp-block-gallery) > figcaption:before {
color: #666; color: #666;
content: '\2014'; content: '\2014';
font-size: 14px; font-size: 14px;
@ -52,13 +52,13 @@ figure[class^="wp-block-"] {
top: 0; top: 0;
} }
.rtl [class^="wp-block-"]:not(.wp-block-gallery) figcaption { .rtl [class^="wp-block-"]:not(.wp-block-gallery) > figcaption {
padding-left: 0; padding-left: 0;
padding-right: 40px; padding-right: 40px;
text-align: right; text-align: right;
} }
.rtl [class^="wp-block-"]:not(.wp-block-gallery) figcaption:before { .rtl [class^="wp-block-"]:not(.wp-block-gallery) > figcaption:before {
left: 0; left: 0;
margin-left: 5px; margin-left: 5px;
margin-right: 0; margin-right: 0;

View File

@ -20,13 +20,13 @@ Description: Used to style blocks.
/* Captions */ /* Captions */
[class^="wp-block-"]:not(.wp-block-gallery) figcaption { [class^="wp-block-"]:not(.wp-block-gallery) > figcaption {
font-style: italic; font-style: italic;
margin-bottom: 1.5em; margin-bottom: 1.5em;
text-align: left; text-align: left;
} }
.rtl [class^="wp-block-"]:not(.wp-block-gallery) figcaption { .rtl [class^="wp-block-"]:not(.wp-block-gallery) > figcaption {
text-align: right; text-align: right;
} }

View File

@ -20,7 +20,7 @@ Description: Used to style blocks.
/* Captions */ /* Captions */
[class^="wp-block-"]:not(.wp-block-gallery) figcaption { [class^="wp-block-"]:not(.wp-block-gallery) > figcaption {
color: #777; color: #777;
font-family: "Helvetica Neue", Arial, Helvetica, "Nimbus Sans L", sans-serif; font-family: "Helvetica Neue", Arial, Helvetica, "Nimbus Sans L", sans-serif;
} }

View File

@ -149,7 +149,7 @@ Description: Used to style blocks in the editor.
/* Caption styles */ /* Caption styles */
[class^="wp-block-"] figcaption { [class^="wp-block-"]:not(.wp-block-gallery) > figcaption {
color: #777; color: #777;
font-family: "Helvetica Neue", Arial, Helvetica, "Nimbus Sans L", sans-serif; font-family: "Helvetica Neue", Arial, Helvetica, "Nimbus Sans L", sans-serif;
} }

View File

@ -16,7 +16,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '6.7-alpha-58633'; $wp_version = '6.7-alpha-58634';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.