import React, { ComponentProps, MutableRefObject, ReactNode } from 'react'; import { Box, Header, Line, Scroll, Text, as } from 'folds'; import classNames from 'classnames'; import { ContainerColor } from '../../styles/ContainerColor.css'; import * as css from './style.css'; import { ScreenSize, useScreenSizeContext } from '../../hooks/useScreenSize'; type PageRootProps = { nav: ReactNode; children: ReactNode; }; export function PageRoot({ nav, children }: PageRootProps) { const screenSize = useScreenSizeContext(); return ( {nav} {screenSize !== ScreenSize.Mobile && ( )} {children} ); } type ClientDrawerLayoutProps = { children: ReactNode; }; export function PageNav({ size, children }: ClientDrawerLayoutProps & css.PageNavVariants) { const screenSize = useScreenSizeContext(); const isMobile = screenSize === ScreenSize.Mobile; return ( {children} ); } export const PageNavHeader = as<'header', css.PageNavHeaderVariants>( ({ className, outlined, ...props }, ref) => (
) ); export function PageNavContent({ scrollRef, children, }: { children: ReactNode; scrollRef?: MutableRefObject; }) { return (
{children}
); } export const Page = as<'div'>(({ className, ...props }, ref) => ( )); export const PageHeader = as<'div', css.PageHeaderVariants>( ({ className, outlined, balance, ...props }, ref) => (
) ); export const PageContent = as<'div'>(({ className, ...props }, ref) => (
)); export function PageHeroEmpty({ children }: { children: ReactNode }) { return ( {children} ); } export const PageHeroSection = as<'div', ComponentProps>( ({ className, ...props }, ref) => ( ) ); export function PageHero({ icon, title, subTitle, children, }: { icon: ReactNode; title: ReactNode; subTitle: ReactNode; children?: ReactNode; }) { return ( {icon} {title} {subTitle} {children} ); } export const PageContentCenter = as<'div'>(({ className, ...props }, ref) => (
));