diff --git a/packages/block-editor/src/components/colors-gradients/style.scss b/packages/block-editor/src/components/colors-gradients/style.scss index 8b36f04b83552..6cade124b7fe4 100644 --- a/packages/block-editor/src/components/colors-gradients/style.scss +++ b/packages/block-editor/src/components/colors-gradients/style.scss @@ -77,14 +77,16 @@ $swatch-gap: 12px; border-right: 1px solid $gray-300; border-bottom: 1px solid $gray-300; - &.first { + // Identify the first visible instance as placeholder items will not have this class. + &:nth-child(1 of &) { margin-top: $grid-unit-30; border-top-left-radius: $radius-block-ui; border-top-right-radius: $radius-block-ui; border-top: 1px solid $gray-300; } - &.last { + // Identify the last visible instance as placeholder items will not have this class. + &:nth-last-child(1 of &) { border-bottom-left-radius: $radius-block-ui; border-bottom-right-radius: $radius-block-ui; } diff --git a/packages/components/CHANGELOG.md b/packages/components/CHANGELOG.md index 0605bda1a47e5..b3c01c4db2c70 100644 --- a/packages/components/CHANGELOG.md +++ b/packages/components/CHANGELOG.md @@ -5,6 +5,7 @@ ### Enhancements - `Notice`: Remove margins from `Notice` component ([#54800](https://github.com/WordPress/gutenberg/pull/54800)). +- `ToolsPanel`: do not apply the `className` to prop to `ToolsPanelItem` components when rendered as placeholders ([#55207](https://github.com/WordPress/gutenberg/pull/55207)). - `ColorPalette`/`ToggleGroupControl/ToggleGroupControlOptionBase`: add `type="button"` attribute to native `