diff --git a/src/features/flights-map/components/FlightsMapFilter.tsx b/src/features/flights-map/components/FlightsMapFilter.tsx index cf960fd8..f818a0b0 100644 --- a/src/features/flights-map/components/FlightsMapFilter.tsx +++ b/src/features/flights-map/components/FlightsMapFilter.tsx @@ -146,6 +146,8 @@ export const FlightsMapFilter: FC = ({ return (
+

{t("FLIGHTS-MAP.ROUTE")}

+ = ({ testIdPrefix="fm-arrival" /> +
+

{t("FLIGHTS-MAP.FILTER_INFO")}

+
+ +
+ + + + + +
+
= ({ maxDate={maxDate} disabledDates={disabledDates} dateFormat="dd.mm.yy" + placeholder={t("SHARED.DATE_FORMAT")} showIcon className="input--filter" inputId="fm-date" data-testid="fm-date-input" />
- -
-

{t("FLIGHTS-MAP.FILTER_INFO")}

-
- -
- - - - - -
); }; diff --git a/src/features/flights-map/components/FlightsMapStartPage.scss b/src/features/flights-map/components/FlightsMapStartPage.scss index 482fcfb7..a43da352 100644 --- a/src/features/flights-map/components/FlightsMapStartPage.scss +++ b/src/features/flights-map/components/FlightsMapStartPage.scss @@ -180,17 +180,65 @@ } } + &__title { + font-size: 18px; + font-weight: 600; + color: #222; + margin: 0 0 vars.$space-s; + } + &__toggles { display: flex; flex-direction: column; - gap: vars.$space-s; + gap: vars.$space-m; + padding: vars.$space-s 0; + } - label { - display: flex; - align-items: center; - gap: vars.$space-s; - cursor: pointer; - @include fonts.font-small(colors.$gray); + // Visual toggle switch matching Angular's p-inputswitch. Hides the + // native checkbox and renders a pill + sliding knob via . + &__toggle { + display: flex; + align-items: center; + gap: vars.$space-m; + cursor: pointer; + @include fonts.font-small(colors.$gray); + + input[type="checkbox"] { + position: absolute; + opacity: 0; + pointer-events: none; + } + } + + &__switch { + display: inline-block; + width: 36px; + height: 20px; + background: #d0d5dd; + border-radius: 10px; + position: relative; + transition: background-color 150ms ease; + flex-shrink: 0; + + &::before { + content: ""; + position: absolute; + top: 2px; + left: 2px; + width: 16px; + height: 16px; + background: #fff; + border-radius: 50%; + transition: transform 150ms ease; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15); + } + } + + input[type="checkbox"]:checked + &__switch { + background: colors.$blue; + + &::before { + transform: translateX(16px); } }