Style schedule-start checkboxes to match Angular

The two filter toggles ('Только прямые рейсы' / 'Показать обратные рейсы')
were rendering as the browser default 16px native checkboxes, which look
inconsistent across browsers and thin against the rest of the page.
Add an appearance:none + custom box with a blue tick mark when checked,
matching Angular's filter card.
This commit is contained in:
2026-04-18 13:00:07 +03:00
parent 96adf785aa
commit 77821c3893
@@ -131,6 +131,57 @@
margin-bottom: vars.$label-margin-bottom;
}
// Give the checkbox a proper box + sliding-knob style, matching
// Angular's schedule filter. Native `input[type="checkbox"]` is too
// thin at 16px and its accented colour differs between browsers.
label:has(input[type="checkbox"]) {
display: flex;
flex-direction: row;
align-items: center;
gap: 10px;
font-weight: normal;
margin-bottom: 0;
cursor: pointer;
font-size: 14px;
color: #222;
}
input[type="checkbox"] {
appearance: none;
-webkit-appearance: none;
width: 18px;
height: 18px;
border: 1.5px solid #d0d5dd;
border-radius: 3px;
background: #fff;
position: relative;
cursor: pointer;
flex-shrink: 0;
transition: background-color 120ms ease, border-color 120ms ease;
&:checked {
background-color: colors.$blue;
border-color: colors.$blue;
&::after {
content: "";
position: absolute;
top: 1px;
left: 5px;
width: 5px;
height: 10px;
border: solid #fff;
border-width: 0 2px 2px 0;
transform: rotate(45deg);
}
}
&:focus-visible {
outline: 2px solid colors.$blue;
outline-offset: 2px;
}
}
input[type="text"],
input[type="date"] {
@include shadows.control-border-shadow();