uibrik

Folder Peek

New

Preview

Customize

Color
Rise44px
Fan7°
Tilt22°
Max rows5

Usage

import { FolderPeek } from "@/components/uibrik/folder-peek/folder-peek";

<FolderPeek />

Installation

npx shadcn@latest add https://uibrik.com/r/folder-peek.json
Adds the files to components/uibrik/folder-peek and installs @tabler/icons-react and motion. With the @uibrik namespace set up: npx shadcn@latest add @uibrik/folder-peek.

Props

FolderPeek
name
Type string
"Launch assets"
Folder name, under the folder and atop the list.
color
Type string
"#a1a1aa"
Folder colour. The back is drawn a shade darker, the flap a shade lighter.
rise
Type number
44
How far the sheets rise on hover.
fan
Type number
7
How far the outer sheets turn as they fan.
tilt
Type number
22
How far the front flap tips forward on hover.
parallax
Type boolean
true
Lean the fanned sheets toward the cursor.
droppable
Type boolean
true
Accept files dropped on the folder or the open list.
maxRows
Type number
5
Rows the open list shows before it scrolls.
files
Type { name: string; meta?: string; kind?: "doc" | "slides" | "image" | "text"; preview?: string }[]
4 sample files
Files on mount, newest first. The first three are drawn as sheets, previewed by kind (inferred from the extension); `preview` swaps the drawn preview for your own image.
onSelect
Type (file, index) => void
–
Called when a row in the open list is picked.
onAdd
Type (files) => void
–
Called with files dropped in from the desktop, or dragged with the application/x-folder-file type.
className
Type string
–
Classes for the wrapper.