Button
The Button component triggers a defined action. Button labels should clearly indicate the action that will be performed upon interaction.
Preview
variant
size
API Reference
prop | type | default | description |
---|---|---|---|
package | typing.Literal['flect'] | flect | None |
class_name | typing.Optional[str] | None | Specifies the Tailwind CSS classes for the component. |
children | flect.components.AnyComponents | [] | The children of the component. |
variant | typing.Literal['default', 'destructive', 'outline', 'secondary', 'ghost', 'link'] | default | Determines the button's style variant. |
size | typing.Literal['default', 'sm', 'lg', 'icon'] | default | Determines the button's size. |
on_click_action | typing.Optional[typing.Annotated[typing.Union[flect.actions.DispatchEvent, flect.actions.Notify, flect.actions.Redirect], FieldInfo(annotation=NoneType, required=True, discriminator='type')]] | None | Defines the action to be performed when the button is clicked. |