A clickable button component with ASCII styling that maintains the retro aesthetic.
npx shadcn@latest add accordion
import { AsciiButton } from 'react-ascii-ui'; export default function Example() { return ( <AsciiButton onClick={() => console.log('Clicked!')}> Click me </AsciiButton> ); }
<AsciiButton>Default Button</AsciiButton>
<AsciiButton disabled>Disabled Button</AsciiButton>
<AsciiButton onClick={() => alert('Button clicked!')}> Click Me </AsciiButton>
Prop | Type | Default | Description |
---|---|---|---|
children | React.ReactNode | - | The content of the button |
onClick | () => void | - | Function to call when button is clicked |
disabled | boolean | false | Whether the button is disabled |
className | string | - | Additional CSS classes |
AsciiButton extends all HTML button attributes and React.ButtonHTMLAttributes.