Genie minimize
A window that minimises like a genie into its target: the edge nearest the target narrows first, the rest pours after it in a curved funnel, and restoring runs the same path back out. It is drawn with horizontal slices of a copy of the window, so any content works.
When to use
- Desktop-style workspaces with floating windows and a dock or tray.
- Sending a panel to a tray icon so people see where it went.
When not to use
- Ordinary dialogs and drawers; they have their own motion.
- Phones, where windows are full screen.
Installation
pnpm dlx shadcn@latest add @caliper/genie-minimize
Adds its 2 files to components/ui/, each with its own stylesheet, and installs their packages. Pro installs with your access token, set up once per project. See Pro access. The first part also adds Caliper UI’s tokens; import them once as in Installation.
API reference
GenieMinimize
3 props
Also accepts the native props of its root element and a ref.
Keyboard
- No custom key handling; Tab and the native activation keys do the work.
Accessibility
It is built on native elements, so roles and focus come from the browser.
Motion
- State changes animate with the library's shared durations and curves, so its timing matches every other part.
- Under reduced motion each change lands on its end state without movement; nothing is hidden or skipped.
Notes for AI
Give your coding assistant this page as Markdown instead of screenshots: the props, keyboard and examples in one file.
/docs/components/genie-minimize.mdThe index of every part is at /llms.txt.