Skip to content

Commit

Permalink
fix(styles): HCM Light: Select arrow icon is not visible (#2696)
Browse files Browse the repository at this point in the history
  • Loading branch information
imagoiq authored Feb 20, 2024
1 parent b6ec72f commit 401ed2d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/smart-avocados-wonder.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@swisspost/design-system-styles': patch
---

Fixed visibility of select arrow in icon in high-contrast mode with light theme.
7 changes: 6 additions & 1 deletion packages/styles/src/components/form-select.scss
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,12 @@
}

@include utilities.high-contrast-mode() {
background-image: b.escape-svg(form-select.$form-select-indicator-hcm);
background-image: b.escape-svg(form-select.$form-select-indicator-hcm-dark);

@media (prefers-color-scheme: light) {
background-image: b.escape-svg(form-select.$form-select-indicator-hcm-light);
}

background-color: Field;
border-color: FieldText;
color: FieldText;
Expand Down
3 changes: 2 additions & 1 deletion packages/styles/src/variables/components/_form-select.scss
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,5 @@ $form-select-indicator-success: url(icons.get-colored-svg-url(
color.$success-green
)) !default;
$form-select-indicator-error: url(icons.get-colored-svg-url('2104', color.$error-red)) !default;
$form-select-indicator-hcm: url(icons.get-colored-svg-url('2113', color.$white)) !default;
$form-select-indicator-hcm-dark: url(icons.get-colored-svg-url('2113', color.$white)) !default;
$form-select-indicator-hcm-light: url(icons.get-colored-svg-url('2113', color.$black)) !default;

0 comments on commit 401ed2d

Please sign in to comment.