Added collapsable text for text that's too long

This commit is contained in:
Kostia
2023-01-03 03:11:50 +02:00
parent a83eb7ffe1
commit 1fdb3c4876
3 changed files with 41 additions and 1 deletions
+2 -1
View File
@@ -17,6 +17,7 @@ import {
verticalListSortingStrategy,
} from "@dnd-kit/sortable";
import { ReactNode, useEffect, useState } from "react";
import { CollapsableText } from "../CollapsableText";
import { SortableItem } from "./SortableItem";
@@ -61,7 +62,7 @@ export const Sortable = ({ items, onChange }: SortableProps) => {
<Flex direction="column" gap={2}>
{itemsWithIds.map(({ id, item }) => (
<SortableItem key={id} id={id}>
{item}
<CollapsableText text={item} />
</SortableItem>
))}
</Flex>