import {createBrowserRouter, RouterProvider} from "react-router-dom" import Station from "./Station" import {createTheme, CssBaseline, ThemeProvider, useMediaQuery} from "@mui/material" import React, {useMemo} from "react" import {frFR, LocalizationProvider} from "@mui/x-date-pickers" import {AdapterDayjs} from "@mui/x-date-pickers/AdapterDayjs" import 'dayjs/locale/fr' import './App.css' function App() { const router = createBrowserRouter([ { path: "/", element:
Hello World!
}, { path: "/station/:stopId", element: } ]) const prefersDarkMode = useMediaQuery('(prefers-color-scheme: dark)'); const theme = useMemo( () => createTheme({ palette: { mode: prefersDarkMode ? 'dark' : 'light', sncf: { departures: { dark: "#003A79", light: "#0064AB", }, arrivals: { dark: "#1F5628", light: "#187936", }, } }, }), [prefersDarkMode], ); return <> } export default App;