Skip to content
Snippets Groups Projects
Commit b05f18b2 authored by xaralis's avatar xaralis
Browse files

feat: add 404 page

parent db901971
No related branches found
No related tags found
No related merge requests found
Pipeline #1916 passed
......@@ -6,6 +6,7 @@ import * as Sentry from "@sentry/react";
import { loadConfig } from "actions/global-info";
import { loadMe } from "actions/users";
import { initializeWSChannel } from "actions/ws";
import Button from "components/Button";
import Footer from "components/Footer";
import Navbar from "components/Navbar";
import Home from "pages/Home";
......@@ -78,6 +79,22 @@ const LoadingComponent = (
</div>
);
const NotFound = () => (
<article className="container container--default py-8 lg:py-24">
<h1 className="head-alt-base lg:head-alt-lg mb-8">
404ka: Tahle stránka tu není
</h1>
<p className="text-base lg:text-xl mb-8">
Dostali jste se na takzvanou „<strong>čtyřystačtyřku</strong>“, což
znamená, že stránka, kterou jste se pokusili navštívit, na tomhle webu
není.
</p>
<Button routerTo="/" className="text-base lg:text-xl" hoverActive fullwidth>
Přejít na hlavní stránku
</Button>
</article>
);
const BaseApp = () => {
initializeWSChannel.read();
......@@ -87,6 +104,7 @@ const BaseApp = () => {
<Switch>
<Route exact path="/" children={<Home />} />
<Route exact path="/program" children={<Program />} />
<Route component={NotFound} />
</Switch>
<Footer />
</Router>
......
......@@ -22,7 +22,7 @@ const GlobalStats = () => {
<strong>{onlineMembers}</strong>{" "}
<span>
{onlineMembers === 1 && "člen online"}
{onlineMembers > 1 && onlineMembers < 4 && "členové online"}
{onlineMembers > 1 && onlineMembers <= 4 && "členové online"}
{(onlineMembers === 0 || onlineMembers > 4) && "členů online"}
</span>
</div>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment