Skip to content

Commit

Permalink
Simpler approach
Browse files Browse the repository at this point in the history
  • Loading branch information
t-hamano committed Jun 24, 2023
1 parent a3af2c7 commit 3101339
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 13 deletions.
1 change: 1 addition & 0 deletions packages/components/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
- `Button`: Remove unnecessary margin from dashicon ([#51395](https://github.com/WordPress/gutenberg/pull/51395)).
- `Autocomplete`: Announce how many results are available to screen readers when suggestions list first renders ([#51018](https://github.com/WordPress/gutenberg/pull/51018)).
- `ConfirmDialog`: Ensure onConfirm isn't called an extra time when submitting one of the buttons using the keyboard ([#51730](https://github.com/WordPress/gutenberg/pull/51730)).
- `DropdownMenu`: fix icon style when dashicon is used ([#43574](https://github.com/WordPress/gutenberg/pull/43574)).

### Internal

Expand Down
22 changes: 9 additions & 13 deletions packages/components/src/dropdown-menu/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -30,19 +30,15 @@
height: 1px;
}

&.is-active svg {
// Block UI appearance.
color: $white;
background: $gray-900;
box-shadow: 0 0 0 $border-width $gray-900;
border-radius: $border-width;
}

// Formatting buttons
> svg {
border-radius: $radius-block-ui;
width: $button-size-small;
height: $button-size-small;
&.is-active {
svg,
.dashicon {
// Block UI appearance.
color: $white;
background: $gray-900;
box-shadow: 0 0 0 $border-width $gray-900;
border-radius: $border-width;
}
}

// If menu items are icon-only, make them stretch only to the icon size.
Expand Down

0 comments on commit 3101339

Please sign in to comment.