forked from github/plane
63b6150b9c
* fix: Labels reordering inconsistency * fix: Delete child labels * feat: multi-select while grouping labels * refactor: label sorting in mobx computed function * feat: drag & drop label grouping, un-grouping * chore: removed label select modal * fix: moving labels from project store to project label store * fix: typo changes and build tree function added * labels feature * disable dropping group into a group * fix build errors * fix more issues * chore: added combining state UI, fixed scroll issue for label groups * chore: group icon for label groups * fix: group cannot be dropped in another group --------- Co-authored-by: sriram veeraghanta <veeraghanta.sriram@gmail.com> Co-authored-by: rahulramesha <rahulramesham@gmail.com> Co-authored-by: Aaryan Khandelwal <aaryankhandu123@gmail.com>
25 lines
730 B
TypeScript
25 lines
730 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={`rounded text-custom-sidebar-text-200 flex flex-shrink-0 mr-1 group-hover:opacity-100 ${
|
|
isDragging ? "opacity-100" : "opacity-0"
|
|
}`}
|
|
{...dragHandleProps}
|
|
>
|
|
<MoreVertical className="h-3.5 w-3.5 stroke-custom-text-400" />
|
|
<MoreVertical className="h-3.5 w-3.5 stroke-custom-text-400 -ml-5" />
|
|
</button>
|
|
);
|
|
};
|