PressButton
A button that compresses slightly on press and settles with a tiny natural overshoot for a tactile, physical feel.
Installation
Add the component directly to your repository using shadcn CLI:
npx shadcn@latest add Surajmaurya1/easyui/press-button
API Reference
| Prop | Type | Default | Description |
|---|---|---|---|
| variant | 'primary' | 'secondary' | 'outline' | 'ghost' | 'primary' | Visual presentation style |
| size | 'sm' | 'md' | 'lg' | 'icon' | 'md' | Dimensions and typography scale |
| pressStrength | number | 0.04 | Compression amount on press (0-1, clamped 0.01-0.06) |
| fullWidth | boolean | false | Stretches button to 100% width of parent container |
| disabled | boolean | false | Prevents interaction and applies 30% disabled opacity |