diff --git a/src/pages/Questions/QuestionsPage.tsx b/src/pages/Questions/QuestionsPage.tsx
index 40a30fb7..7586087e 100755
--- a/src/pages/Questions/QuestionsPage.tsx
+++ b/src/pages/Questions/QuestionsPage.tsx
@@ -1,19 +1,19 @@
import {
- Box,
- Button,
- IconButton,
- Typography,
- useMediaQuery,
- useTheme,
+ Box,
+ Button,
+ IconButton,
+ Typography,
+ useMediaQuery,
+ useTheme,
} from "@mui/material";
import AddPlus from "../../assets/icons/questionsPage/addPlus";
import ArrowLeft from "../../assets/icons/questionsPage/arrowLeft";
import { quizStore } from "@root/quizes";
import { useParams } from "react-router-dom";
import {
- questionStore,
- createQuestion,
- updateQuestionsList,
+ questionStore,
+ createQuestion,
+ updateQuestionsList,
} from "@root/questions";
import { DraggableList } from "./DraggableList";
@@ -22,17 +22,17 @@ import QuizPreview from "@ui_kit/QuizPreview/QuizPreview";
import { createPortal } from "react-dom";
export default function QuestionsPage() {
- const { listQuizes, updateQuizesList } = quizStore();
- const quizId = Number(useParams().quizId);
- const { listQuestions } = questionStore();
- const handleNext = () => {
- updateQuizesList(quizId, { step: listQuizes[quizId].step + 1 });
- };
+ const { listQuizes, updateQuizesList } = quizStore();
+ const quizId = Number(useParams().quizId);
+ const { listQuestions } = questionStore();
+ const handleNext = () => {
+ updateQuizesList(quizId, { step: listQuizes[quizId].step + 1 });
+ };
- const handleBack = () => {
- let result = listQuizes[quizId].step - 1;
- updateQuizesList(quizId, { step: result ? result : 1 });
- };
+ const handleBack = () => {
+ let result = listQuizes[quizId].step - 1;
+ updateQuizesList(quizId, { step: result ? result : 1 });
+ };
const collapseEverything = () => {
listQuestions[quizId].forEach((item, index) => {
@@ -43,12 +43,11 @@ export default function QuestionsPage() {
});
};
- const theme = useTheme();
- const isTablet = useMediaQuery(theme.breakpoints.up(1000));
+ const theme = useTheme();
+ const isMobile = useMediaQuery(theme.breakpoints.down(660));
return (
<>
- {/* */}
{
createQuestion(quizId);
}}
+ sx={{
+ position: "fixed",
+ left: isMobile ? "20px" : "250px",
+ bottom: "20px",
+ }}
>
-
+