Package-level declarations

JengaFab and JengaExtendedFab: floating primary actions.

Types

Link copied to clipboard
class JengaFabColors(val container: Color, val content: Color)

Resolved colors for a JengaFab. Override via JengaFabDefaults.colors.

Link copied to clipboard

Defaults and token mappings for JengaFab. The composable members follow the theme's JengaFabStyle; the constants are Jenga's built-in values, and JengaFab and JengaExtendedFab resolve the theme's values over them.

Link copied to clipboard
class JengaFabStyle(val shape: Shape? = null, val size: Dp? = null, val extendedShape: Shape? = null, val extendedHeight: Dp? = null, val extendedContentPadding: PaddingValues? = null, val elevation: Dp? = null, val shadowColor: Color? = null, val textStyle: TextStyle? = null, val colors: JengaFabColors? = null)

Theme-wide style for every JengaFab and JengaExtendedFab, set through io.github.joelkanyi.jenga.theme.JengaComponentStyles.fab. A null value keeps Jenga's default; arguments passed to a call still win.

Functions

Link copied to clipboard
fun JengaExtendedFab(label: String, onClick: () -> Unit, modifier: Modifier = Modifier, icon: @Composable () -> Unit? = null, shape: Shape = JengaTheme.components.fab?.extendedShape ?: JengaFabDefaults.extendedShape, colors: JengaFabColors = JengaFabDefaults.colors(), elevation: Dp = JengaFabDefaults.elevation, shadowColor: Color = JengaTheme.components.fab?.shadowColor ?: JengaFabDefaults.ShadowColor, height: Dp = JengaTheme.components.fab?.extendedHeight ?: JengaFabDefaults.ExtendedHeight, contentPadding: PaddingValues = JengaFabDefaults.extendedContentPadding, textStyle: TextStyle = JengaFabDefaults.textStyle)

An extended floating action button: a prominent, elevated pill carrying an optional leading icon and a text label. Use it when the primary action needs a word, not just a glyph. Same elevation language as JengaFab; the colors default to brand and can be overridden with any pair (e.g. a neutral inverse) so it reads correctly on any surface.

Link copied to clipboard
fun JengaFab(onClick: () -> Unit, modifier: Modifier = Modifier, shape: Shape = JengaFabDefaults.shape, colors: JengaFabColors = JengaFabDefaults.colors(), elevation: Dp = JengaFabDefaults.elevation, shadowColor: Color = JengaTheme.components.fab?.shadowColor ?: JengaFabDefaults.ShadowColor, size: Dp = JengaTheme.components.fab?.size ?: JengaFabDefaults.Size, content: @Composable () -> Unit)

A floating action button: a prominent, elevated action with an icon.