frontPanel/src/pages/IntegrationsPage/IntegrationsModal/IntegrationStep6/IntegrationStep6.tsx

64 lines
1.6 KiB
TypeScript
Raw Normal View History

2024-04-10 09:38:30 +00:00
import { Box, useMediaQuery, useTheme } from "@mui/material";
import { FC } from "react";
2024-04-10 09:38:30 +00:00
import { StepButtonsBlock } from "../StepButtonsBlock/StepButtonsBlock";
2024-04-12 15:07:37 +00:00
import { Item } from "./Item/Item";
import { someItems } from "../../mocks/MockData";
type IntegrationStep6Props = {
handlePrevStep: () => void;
2024-04-12 15:07:37 +00:00
handleNextStep: () => void;
};
export const IntegrationStep6: FC<IntegrationStep6Props> = ({
handlePrevStep,
2024-04-12 15:07:37 +00:00
handleNextStep,
}) => {
const theme = useTheme();
2024-04-09 15:38:38 +00:00
const isMobile = useMediaQuery(theme.breakpoints.down(600));
return (
<Box
sx={{
2024-04-12 15:07:37 +00:00
marginTop: "20px",
display: "flex",
flexDirection: "column",
alignItems: "center",
height: "100%",
flexGrow: 1,
}}
>
2024-04-10 15:49:04 +00:00
<Box
sx={{
marginTop: "20px",
width: "100%",
2024-04-12 15:07:37 +00:00
height: "420px",
2024-04-10 15:49:04 +00:00
borderRadius: "10px",
padding: "10px",
boxShadow: "0 0 20px rgba(0, 0, 0, 0.15)",
2024-04-12 15:07:37 +00:00
display: "flex",
overflowY: "auto",
flexWrap: "wrap",
2024-04-10 15:49:04 +00:00
}}
2024-04-12 15:07:37 +00:00
>
{/*TODO разобраться что за сущность и какая у нее логика*/}
{someItems &&
someItems.map((item) => (
<Item title={item} onAddBtnClick={() => {}} />
))}
</Box>
2024-04-10 15:49:04 +00:00
<Box
sx={{
marginTop: "20px",
alignSelf: "end",
2024-04-12 15:07:37 +00:00
lineHeight: "1",
2024-04-10 15:49:04 +00:00
}}
>
<StepButtonsBlock
onSmallBtnClick={handlePrevStep}
2024-04-12 15:07:37 +00:00
onLargeBtnClick={handleNextStep}
2024-04-10 15:49:04 +00:00
/>
</Box>
</Box>
);
};