37 lines
995 B
TypeScript
37 lines
995 B
TypeScript
import { CSSProperties, FC, ReactNode } from "react";
|
|
import classNames from "classnames";
|
|
import styles from "./PageItem.module.css";
|
|
|
|
type Props = {
|
|
children: ReactNode;
|
|
style?: CSSProperties;
|
|
fullHeight?: boolean;
|
|
fullHeightFixed?: boolean;
|
|
noBorderRadius?: boolean;
|
|
fullScreenMobile?: boolean;
|
|
};
|
|
|
|
const PageItem: FC<Props> = ({
|
|
children,
|
|
style,
|
|
fullHeight = false,
|
|
fullHeightFixed = false,
|
|
noBorderRadius = false,
|
|
fullScreenMobile = false,
|
|
}) => {
|
|
return (
|
|
<div
|
|
style={style}
|
|
className={classNames(
|
|
styles.container,
|
|
fullHeight && styles["container-full-height"],
|
|
fullHeightFixed && styles["container-full-height-fixed"],
|
|
noBorderRadius && styles["container-no-border-radius"],
|
|
fullScreenMobile && styles["container-full-screen-mobile"]
|
|
)}>
|
|
{children}
|
|
</div>
|
|
);
|
|
};
|
|
export default PageItem;
|