Installation
Usage
showLineNumbers
showLineNumbers
Props
| Prop | Type | Default | Description |
|---|---|---|---|
children | React.ReactNode | - | Must be exactly two <span> elements. |
subscribeStatus | boolean | - | Controlled state for subscription status. |
className | string | - | Additional class names for the button. |
onClick | (event: MouseEvent<HTMLButtonElement>) => void | - | Click event handler. |
| …rest | HTMLMotionProps<"button"> | - | All motion button props are supported. |
Important Notes
- The component requires exactly two children, both must be
<span>elements - First
<span>is shown in the unsubscribed state - Second
<span>is shown in the subscribed state - Can be used as controlled or uncontrolled component
Examples
Uncontrolled (Default)
showLineNumbers
Controlled State
showLineNumbers
With Icons
showLineNumbers
Custom Styling
showLineNumbers