mirror of
https://github.com/kremalicious/umami.git
synced 2024-11-15 09:45:04 +01:00
26 lines
642 B
JavaScript
26 lines
642 B
JavaScript
import { Container } from 'react-basics';
|
|
import Head from 'next/head';
|
|
import NavBar from 'components/layout/NavBar';
|
|
import useRequireLogin from 'hooks/useRequireLogin';
|
|
import styles from './AppLayout.module.css';
|
|
|
|
export default function AppLayout({ title, children }) {
|
|
useRequireLogin();
|
|
|
|
return (
|
|
<div className={styles.layout}>
|
|
<Head>
|
|
<title>{title ? `${title} | umami` : 'umami'}</title>
|
|
</Head>
|
|
<div className={styles.nav}>
|
|
<NavBar />
|
|
</div>
|
|
<div className={styles.body}>
|
|
<Container>
|
|
<main>{children}</main>
|
|
</Container>
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|