Dock
The Magic UI Dock provides magnification controls and child icon surfaces.
Practical React example
Group a small set of destinations in a pointer-magnifying navigation dock.
Before you copy and paste
Match the imported component’s client or server rendering boundary before using the example. Copy components/magicui/dock.tsx and its returned support files from the Code tab; preserve the project-relative paths. Example-only packages: lucide-react. Replace fixture-generation helpers with application data if they are not needed.
Listed package dependencies: motion.
Use the Code tab for the component files and installation instructions, then adapt the imports in this example to your project.
Group a small set of destinations in a pointer-magnifying navigation dock
// Usage adapted from Magic UI's pinned MIT source.
// Copyright (c) Magic UI. See ./LICENSES.md.
'use client';
import { Home, Search, Settings } from "lucide-react"
import { Dock, DockIcon } from "@/components/magicui/dock"
export function ComponentExample() {
return (
<Dock>
<DockIcon>
<Home />
</DockIcon>
<DockIcon>
<Settings />
</DockIcon>
<DockIcon>
<Search />
</DockIcon>
</Dock>
);
}
Usage example adapted from Magic UI's pinned MIT source. Retain the source licence notices when copying.
Place real links or buttons inside the dock icons, and give each a clear accessible name. Use disableMagnification when motion or precision makes magnification unsuitable.
Customization
- DockProps.className
- Optional; string.
- DockProps.iconSize
- Optional; number.
- DockProps.iconMagnification
- Optional; number.
- DockProps.disableMagnification
- Optional; boolean.
- DockProps.iconDistance
- Optional; number.
- DockProps.direction
- Optional; "top" | "middle" | "bottom".
- DockProps.children
- Required; React.ReactNode.
- DockIconProps.size
- Optional; number.
- DockIconProps.magnification
- Optional; number.
- DockIconProps.disableMagnification
- Optional; boolean.
- DockIconProps.distance
- Optional; number.
- DockIconProps.mouseX
- Optional; MotionValue<number>.
- DockIconProps.className
- Optional; string.
- DockIconProps.children
- Optional; React.ReactNode.
Integration notes
- Magnification is decoration; all destinations must remain reachable without hovering.
- Check touch target size, focus styling and layout when labels or icons differ in width.
Component source: Magic UI documentation . These examples describe the version imported into Rendyn. Upstream APIs may have changed; retain the source licence notices when adapting the code.
Give your agent taste.
The best way to use Rendyn is through MCP. Let your agent find the right component, compare previews and bring the source into your project.
All components are free. Sign up only to connect MCP.