Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
560750b15d | ||
|
af6e4908f4 |
BIN
public/nestling.png
Normal file
BIN
public/nestling.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 24 KiB |
54
src/App.tsx
54
src/App.tsx
@ -1,62 +1,12 @@
|
|||||||
import { ThemeProvider } from "theme-ui";
|
import { ThemeProvider } from "theme-ui";
|
||||||
import { BrowserRouter as Router, Switch, Route } from "react-router-dom";
|
|
||||||
|
|
||||||
import theme from "./theme";
|
import theme from "./theme";
|
||||||
import Home from "./routes/Home";
|
import MigrationModal from "./modals/MigrationModal";
|
||||||
import Game from "./routes/Game";
|
|
||||||
import About from "./routes/About";
|
|
||||||
import FAQ from "./routes/FAQ";
|
|
||||||
import ReleaseNotes from "./routes/ReleaseNotes";
|
|
||||||
import HowTo from "./routes/HowTo";
|
|
||||||
|
|
||||||
import { AuthProvider } from "./contexts/AuthContext";
|
|
||||||
import { SettingsProvider } from "./contexts/SettingsContext";
|
|
||||||
import { KeyboardProvider } from "./contexts/KeyboardContext";
|
|
||||||
import { DatabaseProvider } from "./contexts/DatabaseContext";
|
|
||||||
import { UserIdProvider } from "./contexts/UserIdContext";
|
|
||||||
|
|
||||||
import { ToastProvider } from "./components/Toast";
|
|
||||||
import { MigrationNotification } from "./MigrationNotification";
|
|
||||||
|
|
||||||
function App() {
|
function App() {
|
||||||
return (
|
return (
|
||||||
<ThemeProvider theme={theme}>
|
<ThemeProvider theme={theme}>
|
||||||
<SettingsProvider>
|
<MigrationModal />
|
||||||
<AuthProvider>
|
|
||||||
<KeyboardProvider>
|
|
||||||
<ToastProvider>
|
|
||||||
<MigrationNotification />
|
|
||||||
<Router>
|
|
||||||
<Switch>
|
|
||||||
{/* Legacy support camel case routes */}
|
|
||||||
<Route path={["/howTo", "/how-to"]}>
|
|
||||||
<HowTo />
|
|
||||||
</Route>
|
|
||||||
<Route path={["/releaseNotes", "/release-notes"]}>
|
|
||||||
<ReleaseNotes />
|
|
||||||
</Route>
|
|
||||||
<Route path="/about">
|
|
||||||
<About />
|
|
||||||
</Route>
|
|
||||||
<Route path="/faq">
|
|
||||||
<FAQ />
|
|
||||||
</Route>
|
|
||||||
<Route path="/game/:id">
|
|
||||||
<DatabaseProvider>
|
|
||||||
<UserIdProvider>
|
|
||||||
<Game />
|
|
||||||
</UserIdProvider>
|
|
||||||
</DatabaseProvider>
|
|
||||||
</Route>
|
|
||||||
<Route path="/">
|
|
||||||
<Home />
|
|
||||||
</Route>
|
|
||||||
</Switch>
|
|
||||||
</Router>
|
|
||||||
</ToastProvider>
|
|
||||||
</KeyboardProvider>
|
|
||||||
</AuthProvider>
|
|
||||||
</SettingsProvider>
|
|
||||||
</ThemeProvider>
|
</ThemeProvider>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
47
src/modals/MigrationModal.tsx
Normal file
47
src/modals/MigrationModal.tsx
Normal file
@ -0,0 +1,47 @@
|
|||||||
|
import { Box, Button, Container, Text } from "theme-ui";
|
||||||
|
|
||||||
|
function MigrationModal() {
|
||||||
|
return (
|
||||||
|
<Container>
|
||||||
|
<Box>
|
||||||
|
<Text py={2} sx={{ textAlign: "center", mc: "auto" }}>
|
||||||
|
<h1>Owlbear Rodeo 2.0 is coming!</h1>
|
||||||
|
</Text>
|
||||||
|
<img
|
||||||
|
src="/nestling.png"
|
||||||
|
alt="nestling"
|
||||||
|
style={{ width: 200, margin: "0 auto", display: "block" }}
|
||||||
|
/>
|
||||||
|
<Text
|
||||||
|
as="p"
|
||||||
|
variant="body"
|
||||||
|
sx={{ flexGrow: 1, textAlign: "center", mt: 3 }}
|
||||||
|
>
|
||||||
|
Migration is now taking place
|
||||||
|
</Text>
|
||||||
|
<Button
|
||||||
|
//@ts-ignore
|
||||||
|
href="https://blog.owlbear.rodeo/owlbear-rodeo-2-0-release-date-announcement/"
|
||||||
|
target="_blank"
|
||||||
|
rel="noopener noreferrer"
|
||||||
|
as="a"
|
||||||
|
variant="primary"
|
||||||
|
sx={{
|
||||||
|
backgroundColor: "hsl(260, 100%, 80%)",
|
||||||
|
color: "black",
|
||||||
|
border: "none",
|
||||||
|
alignContent: "center",
|
||||||
|
width: "50%",
|
||||||
|
mx: "auto",
|
||||||
|
display: "block",
|
||||||
|
mt: 4,
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Read more
|
||||||
|
</Button>
|
||||||
|
</Box>
|
||||||
|
</Container>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
export default MigrationModal;
|
Loading…
Reference in New Issue
Block a user