mirror of
https://github.com/makeplane/plane
synced 2024-06-14 14:31:34 +00:00
25 lines
742 B
TypeScript
25 lines
742 B
TypeScript
import { DraggableProvidedDragHandleProps } from "@hello-pangea/dnd";
|
|
import { MoreVertical } from "lucide-react";
|
|
|
|
interface IDragHandle {
|
|
isDragging: boolean;
|
|
dragHandleProps: DraggableProvidedDragHandleProps;
|
|
}
|
|
|
|
export const DragHandle = (props: IDragHandle) => {
|
|
const { isDragging, dragHandleProps } = props;
|
|
|
|
return (
|
|
<button
|
|
type="button"
|
|
className={`mr-1 flex flex-shrink-0 rounded text-sidebar-neutral-text-medium group-hover:opacity-100 ${
|
|
isDragging ? "opacity-100" : "opacity-0"
|
|
}`}
|
|
{...dragHandleProps}
|
|
>
|
|
<MoreVertical className="h-3.5 w-3.5 stroke-neutral-text-subtle" />
|
|
<MoreVertical className="-ml-5 h-3.5 w-3.5 stroke-neutral-text-subtle" />
|
|
</button>
|
|
);
|
|
};
|