RemoteIconButtonDefaults

object RemoteIconButtonDefaults


Contains the default values used by RemoteIconButton.

Summary

Public functions

RemoteIconButtonColors

Returns a iconButtonColors for a text button - by default, a transparent background with contrasting content color.

RemoteIconButtonColors
@Composable
iconButtonColors(
    containerColor: RemoteColor,
    contentColor: RemoteColor?,
    disabledContainerColor: RemoteColor,
    disabledContentColor: RemoteColor?
)

Returns a RemoteIconButtonColors for a text button - by default, a transparent background with contrasting content color.

RemoteDp
iconSizeFor(buttonSize: RemoteDp)

Recommended icon size for a given icon button size.

Public properties

RemoteDp

The default size applied for buttons.

RemoteDp

The default size of an icon when used inside an icon button of size DefaultButtonSize.

RemoteFloat

Recommended alpha to apply to an IconButton with Image content with disabled

RemoteDp

The recommended background size of an extra small, compact button.

RemoteDp

The recommended size for a large button.

RemoteDp

The size of an icon when used inside an icon button with size LargeButtonSize.

RemoteDp

The recommended size for a small button.

RemoteDp

The recommended size of an icon when used inside an icon button with size SmallButtonSize or ExtraSmallButtonSize.

RemoteRoundedCornerShape

Recommended RemoteShape for RemoteIconButton.

Public functions

iconButtonColors

Added in 1.0.0-alpha01
@Composable
fun iconButtonColors(): RemoteIconButtonColors

Returns a iconButtonColors for a text button - by default, a transparent background with contrasting content color. If the button is disabled then the colors default to RemoteColorScheme.onSurface with suitable alpha values applied.

iconButtonColors

Added in 1.0.0-alpha01
@Composable
fun iconButtonColors(
    containerColor: RemoteColor = RemoteColor(Color.Transparent),
    contentColor: RemoteColor? = null,
    disabledContainerColor: RemoteColor = RemoteColor(Color.Transparent),
    disabledContentColor: RemoteColor? = null
): RemoteIconButtonColors

Returns a RemoteIconButtonColors for a text button - by default, a transparent background with contrasting content color. If the button is disabled then the colors default to RemoteColorScheme.onSurface with suitable alpha values applied.

Parameters
containerColor: RemoteColor = RemoteColor(Color.Transparent)

the background color of this text button when enabled

contentColor: RemoteColor? = null

the content color of this text button when enabled

disabledContainerColor: RemoteColor = RemoteColor(Color.Transparent)

the background color of this text button when not enabled

disabledContentColor: RemoteColor? = null

the content color of this text button when not enabled

iconSizeFor

Added in 1.0.0-alpha01
fun iconSizeFor(buttonSize: RemoteDp): RemoteDp

Recommended icon size for a given icon button size.

Ensures that the minimum recommended icon size is applied.

Examples: for size LargeButtonSize, returns LargeIconSize, for size ExtraSmallButtonSize returns SmallIconSize.

Parameters
buttonSize: RemoteDp

The size of the icon button

Public properties

DefaultButtonSize

Added in 1.0.0-alpha01
val DefaultButtonSizeRemoteDp

The default size applied for buttons.

DefaultIconSize

Added in 1.0.0-alpha01
val DefaultIconSizeRemoteDp

The default size of an icon when used inside an icon button of size DefaultButtonSize. Use iconSizeFor to easily determine the icon size.

DisabledImageOpacity

Added in 1.0.0-alpha01
val DisabledImageOpacityRemoteFloat

Recommended alpha to apply to an IconButton with Image content with disabled

ExtraSmallButtonSize

Added in 1.0.0-alpha01
val ExtraSmallButtonSizeRemoteDp

The recommended background size of an extra small, compact button.

LargeButtonSize

Added in 1.0.0-alpha01
val LargeButtonSizeRemoteDp

The recommended size for a large button.

LargeIconSize

Added in 1.0.0-alpha01
val LargeIconSizeRemoteDp

The size of an icon when used inside an icon button with size LargeButtonSize. Use iconSizeFor to easily determine the icon size.

SmallButtonSize

Added in 1.0.0-alpha01
val SmallButtonSizeRemoteDp

The recommended size for a small button.

SmallIconSize

Added in 1.0.0-alpha01
val SmallIconSizeRemoteDp

The recommended size of an icon when used inside an icon button with size SmallButtonSize or ExtraSmallButtonSize. Use iconSizeFor to easily determine the icon size.