JengaSnackbarDuration

How long a snackbar stays before it auto-dismisses.

Unlike Material, which forces an indefinite duration the moment an action label is present, so an "Undo" can sit on screen forever, Jenga defaults an action snackbar to Short as well. Opt into Indefinite explicitly when a message must persist until acted upon (and pair it with a dismiss affordance).

Entries

Link copied to clipboard

Brief, for a simple confirmation.

Link copied to clipboard

Longer, the sensible default for a snackbar carrying an action (e.g. Undo).

Link copied to clipboard

Stays until acted upon or explicitly dismissed. Use sparingly.

Properties

Link copied to clipboard

Returns a representation of an immutable list of all enum entries, in the order they're declared.

Link copied to clipboard
expect val name: String
Link copied to clipboard
expect val ordinal: Int

Functions

Link copied to clipboard

Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Link copied to clipboard

Returns an array containing the constants of this enum type, in the order they're declared.