diff --git a/air-quality-ui/src/components/summary-view/MapViewHeader.tsx b/air-quality-ui/src/components/summary-view/MapViewHeader.tsx index f5c7dddd..aaf7a0ca 100644 --- a/air-quality-ui/src/components/summary-view/MapViewHeader.tsx +++ b/air-quality-ui/src/components/summary-view/MapViewHeader.tsx @@ -1,4 +1,5 @@ import Switch from '@mui/material/Switch' +import { ChangeEvent, useId } from 'react' import classes from './MapViewHeader.module.css' @@ -11,15 +12,21 @@ export const MapViewHeader = ({ showMap, setShowMap, }: MapViewHeaderProps): JSX.Element => { + const switchId = useId() + return (
-