From a9d9cbcb72933e8a2f3ec1a01e9ff7625fe86a45 Mon Sep 17 00:00:00 2001 From: Aaryan Khandelwal <65252264+aaryan610@users.noreply.github.com> Date: Fri, 31 May 2024 14:59:49 +0530 Subject: [PATCH] refactor: drag handle component (#4663) --- packages/ui/src/drag-handle.tsx | 16 +++++++++------- .../issues/issue-layouts/list/block.tsx | 14 ++++++++++---- .../labels/label-block/label-item-block.tsx | 8 +++++++- 3 files changed, 26 insertions(+), 12 deletions(-) diff --git a/packages/ui/src/drag-handle.tsx b/packages/ui/src/drag-handle.tsx index 0496f86de..89037a5ca 100644 --- a/packages/ui/src/drag-handle.tsx +++ b/packages/ui/src/drag-handle.tsx @@ -1,14 +1,15 @@ -import React from "react"; -import { forwardRef } from "react"; +import React, { forwardRef } from "react"; import { MoreVertical } from "lucide-react"; +// helpers +import { cn } from "../helpers"; interface IDragHandle { - isDragging: boolean; + className?: string; disabled?: boolean; } export const DragHandle = forwardRef((props, ref) => { - const { isDragging, disabled = false } = props; + const { className, disabled = false } = props; if (disabled) { return
; @@ -17,9 +18,10 @@ export const DragHandle = forwardRef((pro return (