Interface

SnackbarData

Interface to represent one particular Snackbar as a piece of the SnackbarHostState

Source set: Common
public interface SnackbarData

Interface to represent one particular Snackbar as a piece of the SnackbarHostState

Properties

message

Source set: Common
public val message: String

actionLabel

Source set: Common
public val actionLabel: String?

duration

Source set: Common
public val duration: SnackbarDuration

Functions

performAction

Source set: Common
public fun performAction()

Function to be called when Snackbar action has been performed to notify the listeners

dismiss

Source set: Common
public fun dismiss()

Function to be called when Snackbar is dismissed either by timeout or by the user

Jetpack Compose beyond MaterialFree components, screens and templates for apps that don’t look like Google’s. Copy them into your app, or let your coding agent add them.Browse for free

Content updated: