CLI setup for DnD code on this page
If you copy code from the Snippet or Component tabs, run the command below first. It scaffolds AfnoUI, installs the pointer-event DnD primitives at components/dnd/*, and pulls the runtime deps the snippets import (lucide-react, clsx, tailwind-merge).
Alternatively, install a ready-made demo with afnoui add dnd/<variant>. That command pulls the DnD primitives and the variant's example file (under dnd/<variant>/, a sibling of components/) in one go — you don't need to run the init step separately.
Install with:
npx afnoui init --dnd Custom Pointer DnD
File → folder drop
Drop loose files into folders. Folders open visually on hover and tally a count.
drop to file
hover open
counts
Install with:
npx afnoui add dnd/filesFile → folder drop
Loose files
report.pdf
notes.md
logo.svg
data.csv
Documents0 files
Designs0 files
Archive0 files