Button
A button.
Preview
CLI
To generate and customize this style:
dart run forui style create button
Usage
FButton(...)
FButton(
style: FButtonStyle(...),
mainAxisSize: MainAxisSize.min,
onPress: () {},
onSecondaryPress: () {},
onSecondaryLongPress: () {},
shortcuts: { SingleActivator(LogicalKeyboardKey.enter): ActivateIntent() },
actions: { ActivateIntent: CallbackAction<ActivateIntent>(onInvoke: (_) {}) },
child: const Text('Button'),
);
FButton.raw(...)
FButton.raw(
style: FButtonStyle(...),
onPress: () {},
onSecondaryPress: () {},
onSecondaryLongPress: () {},
shortcuts: { SingleActivator(LogicalKeyboardKey.enter): ActivateIntent() },
actions: { ActivateIntent: CallbackAction<ActivateIntent>(onInvoke: (_) {}) },
child: const Text('Button'),
);
Examples
Appearance
Primary
Preview
Secondary
Preview
Destructive
Preview
Outline
Preview
Ghost
Preview
Content
With Text and Icon
Preview
With Only Icon
Preview
With Circular Progress
Preview
Last updated on