Skip to content

Commit

Permalink
Center text and icons vertically in the option select component
Browse files Browse the repository at this point in the history
The font size of this element increased with the typography changes
deployed in a recent update to `govuk-frontend`. This means that the
up/down icons no longer align vertically. This PR makes a minor tweak
to the position of the icons for better vertical balance.

This also supports the same change made in `finder-frontend` where
search filter titles had the same tweak to icon positions. See the PR
at alphagov/finder-frontend#3334.

Note that a refactor of this element could use a better solution
such as flexbox, rather than using absolutely positioned icons
and magic numbers.
  • Loading branch information
matthillco committed Sep 24, 2024
1 parent f8d8c29 commit 09177bf
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
.gem-c-option-select__icon {
display: none;
position: absolute;
top: 0;
top: 3px;
left: 9px;
width: 30px;
height: 40px;
Expand Down

0 comments on commit 09177bf

Please sign in to comment.