frontPanel/src/pages/Questions/QuestionSwitchWindowTool.tsx
2023-12-09 16:27:31 +03:00

23 lines
751 B
TypeScript

import {
Box,
} from "@mui/material";
import { DraggableList } from "./DraggableList";
import { SwitchBranchingPanel } from "./SwitchBranchingPanel";
import { BranchingMap } from "./BranchingMap";
import {useQuestionsStore} from "@root/questions/store";
export const QuestionSwitchWindowTool = () => {
const {openBranchingPanel, questions} = useQuestionsStore.getState()
console.log("questions ", questions)
return (
<Box sx={{ display: "flex", gap: "20px", flexWrap: "wrap" }}>
<Box sx={{ flexBasis: "796px" }}>
{openBranchingPanel? <BranchingMap /> : <DraggableList />}
</Box>
<SwitchBranchingPanel
/>
</Box>
)
}