From 1a1f584b8160292223e79dc910538045fff60aa3 Mon Sep 17 00:00:00 2001 From: AlexSserb Date: Thu, 6 Nov 2025 12:23:54 +0400 Subject: [PATCH] feat: header in module editor page for mobiles --- .../mobile/MobileHeader/MobileHeader.tsx | 21 +++++++++++++++++++ .../components/shared/PageBody/PageBody.tsx | 5 ++++- 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 src/app/module-editor/[moduleId]/components/mobile/MobileHeader/MobileHeader.tsx diff --git a/src/app/module-editor/[moduleId]/components/mobile/MobileHeader/MobileHeader.tsx b/src/app/module-editor/[moduleId]/components/mobile/MobileHeader/MobileHeader.tsx new file mode 100644 index 0000000..53807de --- /dev/null +++ b/src/app/module-editor/[moduleId]/components/mobile/MobileHeader/MobileHeader.tsx @@ -0,0 +1,21 @@ +import { redirect } from "next/navigation"; +import { IconArrowLeft } from "@tabler/icons-react"; +import { Box, Button, Group, Title } from "@mantine/core"; + +const MobileHeader = () => { + return ( + + + Редактирование модуля + + + ); +}; + +export default MobileHeader; diff --git a/src/app/module-editor/[moduleId]/components/shared/PageBody/PageBody.tsx b/src/app/module-editor/[moduleId]/components/shared/PageBody/PageBody.tsx index 2066868..0b596fb 100644 --- a/src/app/module-editor/[moduleId]/components/shared/PageBody/PageBody.tsx +++ b/src/app/module-editor/[moduleId]/components/shared/PageBody/PageBody.tsx @@ -1,6 +1,6 @@ "use client"; -import { Box, Fieldset, Flex, Stack } from "@mantine/core"; +import { Box, Divider, Fieldset, Flex, Stack } from "@mantine/core"; import AttributesTable from "@/app/module-editor/[moduleId]/components/shared/AttributesTable/AttributesTable"; import CreateAttributeButton from "@/app/module-editor/[moduleId]/components/shared/CreateAttributeButton/CreateAttributeButton"; import ModuleAttributesEditor from "@/app/module-editor/[moduleId]/components/shared/ModuleAttributesEditor/ModuleAttributesEditor"; @@ -8,6 +8,7 @@ import ModuleCommonInfoEditor from "@/app/module-editor/[moduleId]/components/sh import { useModuleEditorContext } from "@/app/module-editor/[moduleId]/contexts/ModuleEditorContext"; import PageBlock from "@/components/layout/PageBlock/PageBlock"; import useIsMobile from "@/hooks/utils/useIsMobile"; +import MobileHeader from "@/app/module-editor/[moduleId]/components/mobile/MobileHeader/MobileHeader"; const PageBody = () => { const { module } = useModuleEditorContext(); @@ -21,6 +22,8 @@ const PageBody = () => { gap={"xs"} flex={2} direction={"column"}> + +