Drift Canvas
image-galleryProAn endless, draggable image canvas: one tile of varied-height cards wraps seamlessly in both directions, with momentum, wheel and arrow-key panning.
Introductory price until 31 December 2026. €79 after that.
Preview
Live demo. The theme switches the demo itself.
Code
The code is locked
Drift Canvas is part of Manniche UI Pro. A key unlocks the source of all 66 effects.
Buy · €49€49 · Introductory price until 31 December 2026. €79 after that.
- One-off payment
- One developer
- Sign in and create your key straight away
- No VAT (§ 19 UStG)
Have a key? Get the code with the CLI or MCP.
The key lives in MANNICHE_PRO_KEY, never in your code or a URL. How to set it up
npx shadcn@latest add @manniche-pro/drift-canvasclaude mcp add --transport http manniche-ui https://mikkelmanniche.dk/api/mcp --header "Authorization: Bearer $MANNICHE_PRO_KEY"Props
DriftCanvasProps
| Prop | Type | Default | What it does |
|---|---|---|---|
items required | DriftCanvasItem[] | – | Pictures to lay out. They repeat to fill the tile, and the tile repeats forever in every direction. |
columns | number | 5 | Columns in one repeat of the tile. More columns means a wider tile before the pattern repeats. |
size | number | 220 | Width of a column (a card) in CSS pixels. It shrinks on narrow containers so a phone still sees several cards. |
gap | number | 16 | Space between cards in CSS pixels. |
radius | number | 16 | Corner radius of every card in CSS pixels. |
onItemClick | (item: DriftCanvasItem, index: number) => void | – | Called when a card is clicked or activated by keyboard. Giving it turns every card into a focusable button. It never fires for the click that ends a drag. |
wheel | 'auto' | 'always' | 'off' | 'auto' | How the mouse wheel and trackpad pan the canvas.
|
inertia | number | 0.85 | How long a flick keeps gliding, from 0 (stops at once) to 1 (long glide). Ignored with reduced motion, where there is no glide. |
touchDrag | boolean | true | Touch behaviour. By default the surface sets touch-action: none so a finger can pan in any direction, which also means a finger on the canvas will not scroll the page. Pass false to use touch-action: pan-y instead: swiping sideways pans the canvas and swiping up or down scrolls the page. Mouse and pen always drag freely. |
aria-label | string | 'Image canvas' | Accessible name of the canvas. |
children | ReactNode | – | Content drawn above the cards. It ignores the pointer; switch pointer-events-auto back on for anything clickable. |
className | string | – | – |
A11y
Keyboard
The canvas takes focus with Tab. Arrow keys pan, Shift pans further, and Escape stops wheel capture. With onItemClick each card is a button and focusing one scrolls it into view; cards with a label show their caption on focus and on tap. Only the first copy of the tile is in tab order.
Screen reader
The canvas is a group named by aria-label and described by a hidden hint. Only the first copy of the tile is exposed; the repeats are aria-hidden and out of tab order but still answer the pointer. Cards use alt as their name, joined with label when set, and are buttons when onItemClick is given.
Reduced motion
Under reduced motion there is no glide and the arrows move the canvas directly. The loop pauses while off screen.