feat: add featured image to posts

This commit is contained in:
Felix Schröter 2022-11-15 20:14:27 +01:00
parent df2fd8a520
commit 840621c672
Signed by: felschr
GPG key ID: 671E39E6744C807D
5 changed files with 48 additions and 5 deletions

View file

@ -10,11 +10,12 @@ const pages = [
]
type LayoutProps = {
pageTitle: string | ReactNode
pageTitle: string
preTitle?: ReactNode
children: ReactNode
}
const Layout = ({ pageTitle, children }: LayoutProps) => {
const Layout = ({ pageTitle, preTitle, children }: LayoutProps) => {
const theme = useTheme()
return (
@ -58,6 +59,7 @@ const Layout = ({ pageTitle, children }: LayoutProps) => {
</AppBar>
<Container style={{ marginTop: 68.5, marginBottom: 80, minHeight: "100%" }}>
{preTitle}
<Typography variant="h1">{pageTitle}</Typography>
{children}
</Container>