Package-level declarations

Types

Link copied to clipboard
actual enum ButtonSize : Enum<ButtonSize>

Enum class representing different sizes for a button. Each size has an associated height in dp.

expect enum ButtonSize : Enum<ButtonSize>

Enum class representing different sizes for a button. Each size has an associated height in dp.

actual enum ButtonSize : Enum<ButtonSize>

Enum class representing different sizes for a button. Each size has an associated height in dp.

actual enum ButtonSize : Enum<ButtonSize>

Enum class representing different sizes for a button. Each size has an associated height in dp.

actual enum ButtonSize : Enum<ButtonSize>

Enum class representing different sizes for a button. Each size has an associated height in dp.

Link copied to clipboard

Variants of the Carbon Button.

Functions

Link copied to clipboard
fun Button(label: String, onClick: () -> Unit, modifier: Modifier = Modifier, iconPainter: Painter? = null, isEnabled: Boolean = true, buttonType: ButtonType = ButtonType.Primary, buttonSize: ButtonSize = ButtonSize.LargeProductive, interactionSource: MutableInteractionSource = remember { MutableInteractionSource() })
fun Button(label: String, tooltipParameters: TooltipParameters, onClick: () -> Unit, modifier: Modifier = Modifier, tooltipModifier: Modifier = Modifier, iconPainter: Painter? = null, isEnabled: Boolean = true, buttonType: ButtonType = ButtonType.Primary, buttonSize: ButtonSize = ButtonSize.LargeProductive, interactionSource: MutableInteractionSource = remember { MutableInteractionSource() })

Buttons are used to initialize an action. Button labels express what action will occur when the user interacts with it.

Link copied to clipboard
fun IconButton(iconPainter: Painter, onClick: () -> Unit, modifier: Modifier = Modifier, buttonType: ButtonType = ButtonType.Primary, buttonSize: ButtonSize = ButtonSize.LargeProductive, isEnabled: Boolean = true, interactionSource: MutableInteractionSource = remember { MutableInteractionSource() })
fun IconButton(iconPainter: Painter, tooltipParameters: TooltipParameters, onClick: () -> Unit, modifier: Modifier = Modifier, tooltipModifier: Modifier = Modifier, buttonType: ButtonType = ButtonType.Primary, buttonSize: ButtonSize = ButtonSize.LargeProductive, isEnabled: Boolean = true, interactionSource: MutableInteractionSource = remember { MutableInteractionSource() })

Buttons are used to initialize an action. Button labels express what action will occur when the user interacts with it.

Link copied to clipboard
fun IconButtonWithPopover(iconPainter: Painter, isPopoverVisible: Boolean, popoverAlignment: PopoverAlignment, onClick: () -> Unit, modifier: Modifier = Modifier, popoverMinWidth: Dp = Dp.Unspecified, popoverMaxWidth: Dp = Dp.Unspecified, popoverPopupProperties: PopupProperties = popoverDefaultProperties, buttonType: ButtonType = ButtonType.Primary, buttonSize: ButtonSize = ButtonSize.LargeProductive, isEnabled: Boolean = true, interactionSource: MutableInteractionSource = remember { MutableInteractionSource() }, onDismissRequest: () -> Unit? = null, popoverContent: @Composable BoxScope.() -> Unit)

Buttons are used to initialize an action. Button labels express what action will occur when the user interacts with it.