Skip to content

Commit

Permalink
fix(styles): added hover color to ´post-accordion´ in HCM (#4316)
Browse files Browse the repository at this point in the history
Co-authored-by: Alizé Debray <[email protected]>
  • Loading branch information
schaertim and alizedebray authored Dec 18, 2024
1 parent 53bcc26 commit 912198c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
5 changes: 5 additions & 0 deletions .changeset/violet-geckos-shave.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@swisspost/design-system-components': patch
---

Added hover color to `post-accordion` in high contrast mode.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ tokens.$default-map: components.$post-accordion;
}
&:has(.accordion-button:hover)::after {
border-color: tokens.get('accordion-hover-border');
@include utility-mx.high-contrast-mode() {
border-color: Highlight;
}
}
}

Expand All @@ -47,7 +50,6 @@ tokens.$default-map: components.$post-accordion;
calc(
tokens.get('accordion-header-padding-inline') + tokens.get('accordion-border-bottom-width')
);
transition: accordion.$accordion-button-transition;
cursor: pointer;

&::before {
Expand Down Expand Up @@ -100,13 +102,7 @@ tokens.$default-map: components.$post-accordion;
@include utility-mx.high-contrast-mode() {
&:hover,
&:focus-visible {
&:not(:disabled) {
outline: tokens.get('accordion-border-bottom-width') solid Highlight;
}
}

&:disabled {
opacity: 1 !important;
color: Highlight;
}
}
}
Expand Down

0 comments on commit 912198c

Please sign in to comment.