Component packs › Pressworks › Hole Punch
The pin drives through the ticket, the chad tumbles into the clear tray where they pile up, and the ticket slides out with a hole you can see through.
Hole Punch is a confirm from Pressworks, a component pack with 8 buttons: Eight buttons, each a different real mechanism you can feel. Price: $2 for the whole pack.
Built with: lever on a hinge, falling chads that pile up, see-through hole.
Code: React and Next.js (TypeScript), Vue 3, plain HTML/CSS/JS, Tailwind CSS v4 and Motion (motion.dev). No npm packages needed. Keyboard accessible, with a reduced-motion version, in dark and light.
| Prop | Type | Default | Description |
|---|---|---|---|
ticket | string | Printed on the ticket. | |
ariaLabel | string | Accessible name. | |
doneText | string | Status after a punch. | |
disabled | boolean | ||
onConfirm | () => void | Called when the pin has gone through. | |
theme | 'light' | 'dark' | ||
size | number | Scale factor. 1 = 290 × 186 px. | |
autoplay | number | false | Showcase mode: punches a fresh ticket every N ms while visible. |
readonly punched: booleanpunch(): voidreset(): void: Feeds a fresh ticket in.setDisabled(disabled: boolean): voiddestroy(): voidimport HolePunch from './HolePunch';
<HolePunch />The Vue, HTML, Next.js, Tailwind and Motion versions take the same options.
Good for: Buttons.