SigmaKit.Components.Flash (sigma_kit v0.0.33)

Summary

Functions

Shows the flash group with standard titles and content.

Functions

flash(assigns)

Examples

<.flash kind={:info} flash={@flash} />
<.flash kind={:info} phx-mounted={show("#flash")}>Welcome Back!</.flash>

Attributes

  • id (:string) - the optional id of flash container.
  • flash (:map) - the map of flash messages to display. Defaults to %{}.
  • kind (:atom) - used for styling and flash lookup. Must be one of :info, or :error.
  • details (:list) - Defaults to nil.
  • Global attributes are accepted. the arbitrary HTML attributes to add to the flash container.

flash_group(assigns)

Shows the flash group with standard titles and content.

Examples

<.flash_group flash={@flash} />

Attributes

  • flash (:map) (required) - the map of flash messages.
  • id (:string) - the optional id of flash container. Defaults to "flash-group".

flash_icon(assigns)

Attributes

  • kind (:atom)