From c10933c5fbad2813cf4390f652a3421f074b5b8c Mon Sep 17 00:00:00 2001 From: Tammie Lister Date: Thu, 26 Nov 2020 11:29:37 +0000 Subject: [PATCH 1/4] Brings back title and icon for gallery block --- packages/block-library/src/gallery/editor.scss | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/block-library/src/gallery/editor.scss b/packages/block-library/src/gallery/editor.scss index 95e1f8819a9952..a446a0db3f4b88 100644 --- a/packages/block-library/src/gallery/editor.scss +++ b/packages/block-library/src/gallery/editor.scss @@ -8,7 +8,6 @@ // @todo: this deserves a refactor, by being moved to the toolbar. .block-editor-media-placeholder { - padding: $grid-unit-15; // This element is empty here anyway. .components-placeholder__label { From e584f52aa3641ea0081ce1fd1c4dedb8b6341c15 Mon Sep 17 00:00:00 2001 From: Tammie Lister Date: Thu, 26 Nov 2020 11:31:48 +0000 Subject: [PATCH 2/4] Brings back title and icon for gallery block --- packages/block-library/src/gallery/editor.scss | 5 ----- 1 file changed, 5 deletions(-) diff --git a/packages/block-library/src/gallery/editor.scss b/packages/block-library/src/gallery/editor.scss index a446a0db3f4b88..45ce37b57e2960 100644 --- a/packages/block-library/src/gallery/editor.scss +++ b/packages/block-library/src/gallery/editor.scss @@ -9,11 +9,6 @@ // @todo: this deserves a refactor, by being moved to the toolbar. .block-editor-media-placeholder { - // This element is empty here anyway. - .components-placeholder__label { - display: none; - } - .components-button { margin-bottom: 0; } From 9ad90dba2c4767744fa6d2693896440b9555720e Mon Sep 17 00:00:00 2001 From: Tammie Lister Date: Thu, 26 Nov 2020 11:41:36 +0000 Subject: [PATCH 3/4] Removes entire block of CSS that's potentially not required --- packages/block-library/src/gallery/editor.scss | 8 -------- 1 file changed, 8 deletions(-) diff --git a/packages/block-library/src/gallery/editor.scss b/packages/block-library/src/gallery/editor.scss index 45ce37b57e2960..bb216990696618 100644 --- a/packages/block-library/src/gallery/editor.scss +++ b/packages/block-library/src/gallery/editor.scss @@ -5,14 +5,6 @@ li { list-style-type: none; } - - // @todo: this deserves a refactor, by being moved to the toolbar. - .block-editor-media-placeholder { - - .components-button { - margin-bottom: 0; - } - } } figure.wp-block-gallery { From b4a9888e1d20445c4444a31a7e4b47c0cf47f434 Mon Sep 17 00:00:00 2001 From: Tammie Lister Date: Thu, 26 Nov 2020 12:10:32 +0000 Subject: [PATCH 4/4] Better refactor - props @jasmussen --- packages/block-library/src/gallery/editor.scss | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/packages/block-library/src/gallery/editor.scss b/packages/block-library/src/gallery/editor.scss index bb216990696618..091b71e5881b0a 100644 --- a/packages/block-library/src/gallery/editor.scss +++ b/packages/block-library/src/gallery/editor.scss @@ -5,6 +5,24 @@ li { list-style-type: none; } + + .wp-block-gallery { + // Override the default list style type _only in the editor_ + // to avoid :not() selector specificity issues. + // See https://github.com/WordPress/gutenberg/pull/10358 + li { + list-style-type: none; + } + // @todo: this deserves a refactor, by being moved to the toolbar. + .block-editor-media-placeholder.is-appender { + .components-placeholder__label { + display: none; + } + .block-editor-media-placeholder__button { + margin-bottom: 0; + } + } + } } figure.wp-block-gallery {