feat: boards and statuses editing and creating for mobiles
This commit is contained in:
@ -44,6 +44,7 @@ const Board: FC<Props> = ({ board }) => {
|
||||
/>
|
||||
</>
|
||||
)}
|
||||
modalTitle={"Редактирование доски"}
|
||||
/>
|
||||
</Group>
|
||||
);
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
import React, { FC } from "react";
|
||||
import { IconDotsVertical, IconEdit, IconTrash } from "@tabler/icons-react";
|
||||
import { isMobile } from "react-device-detect";
|
||||
import { Box, Group, Menu, Text } from "@mantine/core";
|
||||
import { useBoardsContext } from "@/app/deals/contexts/BoardsContext";
|
||||
import { BoardSchema } from "@/lib/client";
|
||||
@ -19,7 +20,11 @@ const BoardMenu: FC<Props> = ({ isHovered, board, startEditing }) => {
|
||||
<Box
|
||||
style={{
|
||||
opacity:
|
||||
isHovered || selectedBoard?.id === board.id ? 1 : 0,
|
||||
isMobile ||
|
||||
isHovered ||
|
||||
selectedBoard?.id === board.id
|
||||
? 1
|
||||
: 0,
|
||||
cursor: "pointer",
|
||||
}}
|
||||
onClick={e => {
|
||||
|
||||
@ -16,6 +16,7 @@ const CreateBoardButton = () => {
|
||||
<IconPlus />
|
||||
</Box>
|
||||
)}
|
||||
modalTitle={"Создание доски"}
|
||||
/>
|
||||
</Box>
|
||||
);
|
||||
|
||||
@ -26,6 +26,7 @@ const CreateStatusButton = () => {
|
||||
<Text>Создать колонку</Text>
|
||||
</Box>
|
||||
)}
|
||||
modalTitle={"Создание колонки"}
|
||||
/>
|
||||
</Box>
|
||||
);
|
||||
|
||||
@ -28,7 +28,10 @@ const Funnel: FC = () => {
|
||||
<ScrollArea
|
||||
offsetScrollbars={"x"}
|
||||
scrollbarSize={"0.5rem"}>
|
||||
<Group align={"start"}>
|
||||
<Group
|
||||
align={"start"}
|
||||
wrap={"nowrap"}
|
||||
gap={"sm"}>
|
||||
<FunnelDnd
|
||||
containers={sortedStatuses}
|
||||
items={deals}
|
||||
|
||||
@ -64,6 +64,7 @@ const StatusColumnWrapper = ({
|
||||
/>
|
||||
</>
|
||||
)}
|
||||
modalTitle={"Редактирование статуса"}
|
||||
/>
|
||||
</Group>
|
||||
{children}
|
||||
|
||||
Reference in New Issue
Block a user