ZoonkWeb.Components.Button (Zoonk v0.1.0-dev)

View Source

Provides the UI for rendering buttons.

Summary

Functions

Renders a button.

Functions

button(assigns)

Renders a button.

Examples

<.button>Send!</.button>
<.button variant={:outline}>Send!</.button>

Attributes

  • type (:string) - Defaults to "button".
  • kind (:atom) - Defaults to :button. Must be one of :button, or :icon.
  • icon (:string) - Defaults to nil.
  • icon_align (:atom) - Defaults to :auto. Must be one of :left, :right, or :auto.
  • variant (:atom) - Defaults to :primary. Must be one of :primary, :destructive, :secondary, :outline, or :active.
  • size (:atom) - Defaults to :sm. Must be one of :adaptive, :sm, :md, or :lg.
  • class (:string) - Defaults to nil.
  • Global attributes are accepted. Supports all globals plus: ["disabled", "form", "name", "value"].

Slots

  • inner_block (required)