OudsFloatingActionButton
The FAB represents the most important action on a screen. It puts key actions within reach.
FAB typically contains an icon, for a FAB with text and an icon, see OudsExtendedFloatingActionButton.
Design
| Name | FAB |
| Version | Draft |
Parameters
Icon for this FAB.
Called when this FAB is clicked.
The Modifier to be applied to this FAB.
Defines the shape of this FAB's container and shadow.
Appearance of the FAB among OudsFloatingActionButtonAppearance values.
An optional hoisted MutableInteractionSource for observing and emitting Interactions for this FAB. You can use this to change the FAB's appearance or preview the FAB in different states. Note that if null is provided, interactions will still happen internally.
Samples
OudsFloatingActionButton(
icon = OudsIcon(
imageVector = Icons.Filled.FavoriteBorder,
contentDescription = "Content description"
),
onClick = { /* Do something! */ }
)OudsFloatingActionButton(
icon = OudsIcon(
painter = rememberRainbowHeartPainter(),
contentDescription = "Content description",
tinted = false
),
onClick = { /* Do something! */ },
appearance = OudsFloatingActionButtonAppearance.Strong
)Deprecated
The FAB represents the most important action on a screen. It puts key actions within reach.
FAB typically contains an icon, for a FAB with text and an icon, see OudsExtendedFloatingActionButton.
Design
| Name | FAB |
| Version | Draft |
Parameters
Icon for this FAB.
Called when this FAB is clicked.
The Modifier to be applied to this FAB.
Defines the shape of this FAB's container and shadow.
Appearance of the FAB among OudsFloatingActionButtonAppearance values.
An optional hoisted MutableInteractionSource for observing and emitting Interactions for this FAB. You can use this to change the FAB's appearance or preview the FAB in different states. Note that if null is provided, interactions will still happen internally.
Samples
OudsFloatingActionButton(
icon = OudsIcon(
imageVector = Icons.Filled.FavoriteBorder,
contentDescription = "Content description"
),
onClick = { /* Do something! */ }
)OudsFloatingActionButton(
icon = OudsIcon(
painter = rememberRainbowHeartPainter(),
contentDescription = "Content description",
tinted = false
),
onClick = { /* Do something! */ },
appearance = OudsFloatingActionButtonAppearance.Strong
)