OPEN-UI

Draggable Grid

A draggable 2D grid with parallax icon cells. Inspired by Apple WatchOS.

Loading...

Install

Use Open-UI CLI or Shadcn CLI to install the component.

Open-UI CLI

Shadcn CLI

Usage

ItemPropDefaultDescriptionType
RootchildrenRoot/Grid: child nodes. Item: custom content; when provided, item (link+image+tooltip) is ignored.ReactNode
RootclassNameOptional CSS class for the container.string
RooticonSize120Size (px) of each grid cell/icon. Used for layout and parallax.number
RooticonMargin40Gap (px) between grid cells.number
Rootrows10Number of grid rows (Root).number
Rootcols10Number of grid columns (Root).number
RootlinkComponentCustom component for links (e.g. Next.js Link). Receives href and children.ComponentType<{ href; children }>
RootfallbackReactNode shown before mount (e.g. loading). If set, Root renders it instead of default loading UI.ReactNode
GridchildrenRoot/Grid: child nodes. Item: custom content; when provided, item (link+image+tooltip) is ignored.ReactNode
GridclassNameOptional CSS class for the container.string
GriddragConstraintsBounds for dragging: { left, right, top, bottom } in px. Limits how far the grid plane can be dragged.{ left, right, top, bottom }
ItemrowItem's row index in the grid (0-based).number
ItemcolItem's column index in the grid (0-based).number
ItemindexItem order for stagger animation delay.number
ItemitemData for default cell: { id, href?, image?, label? }. When set, renders link + image/tooltip; omit and use children for custom content.DraggableGridItemBase
ItemlinkComponentCustom component for links (e.g. Next.js Link). Receives href and children.ComponentType<{ href; children }>
ItemclassNameOptional CSS class for the container.string
ItemchildrenRoot/Grid: child nodes. Item: custom content; when provided, item (link+image+tooltip) is ignored.ReactNode

Related Components