improve browser compatability
in some browsers ariaPressed is only supported since 2023. We use a data attribute as a fallback
This commit is contained in:
parent
14a514e3e4
commit
caa96f565f
5 changed files with 42 additions and 17 deletions
18
style.scss
18
style.scss
|
@ -713,7 +713,7 @@ span.lineChip, span.typeChip, button.typeChip {
|
|||
}
|
||||
|
||||
|
||||
div#typeFilter{
|
||||
div#typeFilter {
|
||||
display: flex;
|
||||
flex-grow: 1;
|
||||
flex-wrap: nowrap;
|
||||
|
@ -727,9 +727,13 @@ div#typeFilter{
|
|||
aspect-ratio: 1/1;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
|
||||
&[data-type="U"], &[data-type="S"], &[data-type="A"], &[data-type="R"] {
|
||||
border: solid 2px var(--station-border);
|
||||
&[aria-pressed="false"] {
|
||||
|
||||
&[data-pressed="false"] {
|
||||
background-color: var(--color-gray-500);
|
||||
color: var(--color-type-disabled);
|
||||
|
||||
|
@ -748,6 +752,16 @@ div#typeFilter{
|
|||
&[data-type="R"] {
|
||||
background-color: var(--bg-type-r-disabled);
|
||||
}
|
||||
|
||||
&::after {
|
||||
position: absolute;
|
||||
content: '';
|
||||
width: 144%;
|
||||
height: 0.4rem;
|
||||
background-color: var(--color-gray-500);
|
||||
opacity: 80%;
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue