omnivore/packages/web/components/templates/ProfileLayout.tsx

56 lines
1.2 KiB
TypeScript
Raw Permalink Normal View History

2022-02-11 17:24:33 +00:00
import { Box, VStack, HStack } from '../elements/LayoutPrimitives'
2022-12-28 09:49:33 +00:00
import { OmnivoreNameLogo } from '../elements/images/OmnivoreNameLogo'
2022-02-11 17:24:33 +00:00
import { theme } from '../tokens/stitches.config'
type ProfileLayoutProps = {
logoDestination?: string
2022-02-11 17:24:33 +00:00
children: React.ReactNode
}
export function ProfileLayout(props: ProfileLayoutProps): JSX.Element {
2022-02-11 17:24:33 +00:00
return (
<>
<VStack
alignment="center"
distribution="center"
css={{
height: '100vh',
2024-05-07 09:22:02 +00:00
color: '#898989',
background: '#2A2A2A',
}}
2022-02-11 17:24:33 +00:00
>
{props.children}
</VStack>
<Box
css={{
position: 'absolute',
top: 0,
left: 0,
m: '0',
width: '100%',
}}
>
<HStack
alignment="center"
distribution="between"
css={{
mt: '18px',
2022-02-11 17:24:33 +00:00
ml: '18px',
mr: '0',
'@smDown': {
ml: '8px',
mt: '10px',
},
}}
>
2022-12-28 09:49:33 +00:00
<OmnivoreNameLogo
2024-05-07 02:33:51 +00:00
color="#898989"
href={props.logoDestination ?? '/login'}
/>
2022-02-11 17:24:33 +00:00
</HStack>
</Box>
</>
)
}