link-stack/packages/leafcutter-common/components/AboutBox.tsx

36 lines
672 B
TypeScript
Raw Normal View History

2023-06-26 10:07:12 +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-08-25 07:11:33 +00:00
import { useAppContext } from "../../../apps/leafcutter/app/_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>
);
};