Package-level declarations
Types
Link copied to clipboard
data class QuantityButtonAppearance( val modifier: Modifier = Modifier, val shape: Shape = CircleShape, val size: Dp = 30.dp, val background: Color, val icon: ImageVector)
The QuantityButtonAppearance
allows to customize the appearance of the QuantityButton
Link copied to clipboard
class QuantityPickerState
The QuantityPickerState
class is useful to handle the QuantityPicker component lifecycle
Functions
Link copied to clipboard
Custom QuantityButton used to decrement the quantity value picked by the QuantityPicker
Link copied to clipboard
Custom QuantityButton used to increment the quantity value picked by the QuantityPicker
Link copied to clipboard
private fun QuantityButton(appearance: QuantityButtonAppearance, quantityAction: () -> Unit, longPressQuantityAction: () -> Unit? = null)
Custom Box used to handle the quantity value picked by the QuantityPicker
Link copied to clipboard
fun quantityButtonAppearance( modifier: Modifier = Modifier, shape: Shape = CircleShape, size: Dp = 30.dp, background: Color = MaterialTheme.colorScheme.primary, icon: ImageVector): QuantityButtonAppearance
Method used to create a customization style for a QuantityButton
Link copied to clipboard
fun QuantityPicker( modifier: Modifier = Modifier, state: QuantityPickerState, informativeText: String? = null, informativeTextStyle: TextStyle = TextStyle.Default, decrementButtonAppearance: QuantityButtonAppearance = quantityButtonAppearance(
icon = Icons.Default.Remove
), quantityIndicatorStyle: TextStyle = TextStyle.Default, incrementButtonAppearance: QuantityButtonAppearance = quantityButtonAppearance(
icon = Icons.Default.Add
))
Component used to pick a numerical quantity value
Link copied to clipboard
fun rememberQuantityPickerState( initialQuantity: Int = 0, minQuantity: Int = Int.MIN_VALUE, maxQuantity: Int = Int.MAX_VALUE, longPressQuantity: Int? = null): QuantityPickerState
Method used to create and remember during the recompositions the state for the QuantityPicker component