link-stack/apps/leafcutter/app/(main)/about/_components/AboutBox.tsx

36 lines
652 B
TypeScript
Raw Normal View History

2023-07-18 12:26:57 +00:00
"use client";
2023-05-24 20:27:57 +00:00
import { FC, PropsWithChildren } from "react";
2023-02-13 13:46:56 +00:00
import { Box } from "@mui/material";
2023-07-18 12:26:57 +00:00
import { useAppContext } from "../../../_components/AppProvider";
2023-02-13 13:46:56 +00:00
2023-05-24 20:27:57 +00:00
type AboutBoxProps = PropsWithChildren<{
2023-02-13 13:46:56 +00:00
backgroundColor: string;
2023-05-24 20:27:57 +00:00
}>;
2023-02-13 13:46:56 +00:00
2023-05-24 20:27:57 +00:00
export const AboutBox: FC<AboutBoxProps> = ({
backgroundColor,
children,
}: any) => {
2023-02-13 13:46:56 +00:00
const {
colors: { white },
} = useAppContext();
return (
<Box
sx={{
width: "100%",
backgroundColor,
color: white,
p: 4,
borderRadius: "10px",
mt: "66px",
mb: "22px",
textAlign: "center",
}}
>
{children}
</Box>
);
};