Home / Function/ DragHandle() — ui Function Reference

DragHandle() — ui Function Reference

Architecture documentation for the DragHandle() function in data-table.tsx from the ui codebase.

Entity Profile

Dependency Diagram

graph TD
  f34ecc00_b183_928f_7160_0be74d2ff566["DragHandle()"]
  35e180e2_eb50_375e_4a19_e8096d02a705["data-table.tsx"]
  f34ecc00_b183_928f_7160_0be74d2ff566 -->|defined in| 35e180e2_eb50_375e_4a19_e8096d02a705
  style f34ecc00_b183_928f_7160_0be74d2ff566 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

apps/v4/registry/bases/base/blocks/dashboard-01/components/data-table.tsx lines 108–131

function DragHandle({ id }: { id: number }) {
  const { attributes, listeners } = useSortable({
    id,
  })
  return (
    <Button
      {...attributes}
      {...listeners}
      variant="ghost"
      size="icon"
      className="text-muted-foreground size-7 hover:bg-transparent"
    >
      <IconPlaceholder
        lucide="GripVerticalIcon"
        tabler="IconGripVertical"
        hugeicons="DragDropVerticalIcon"
        phosphor="DotsSixVerticalIcon"
        remixicon="RiDraggable"
        className="text-muted-foreground size-3"
      />
      <span className="sr-only">Drag to reorder</span>
    </Button>
  )
}

Subdomains

Frequently Asked Questions

What does DragHandle() do?
DragHandle() is a function in the ui codebase, defined in apps/v4/registry/bases/base/blocks/dashboard-01/components/data-table.tsx.
Where is DragHandle() defined?
DragHandle() is defined in apps/v4/registry/bases/base/blocks/dashboard-01/components/data-table.tsx at line 108.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free