View Source Tremorx.Components.Button (tremorx v0.1.1)

Button

Summary

Functions

Renders a button

Renders a button icon or spinner

Functions

Renders a button

Attributes

  • icon_position (:string) - Defaults to "left".
  • size (:string) - Defaults to "sm".
  • color (:string) - Defaults to nil.
  • class (:string) - Defaults to nil.
  • variant (:string) - Defaults to "primary".
  • type (:string) - Defaults to "button".
  • disabled (:boolean) - Defaults to false.
  • loading (:boolean) - Defaults to false.
  • loading_text (:string) - Defaults to nil.
  • tooltip (:string) - Defaults to nil.
  • Global attributes are accepted.

Slots

  • inner_block
  • icon
Link to this function

button_icon_spinner(assigns)

View Source

Renders a button icon or spinner

Attributes

  • icon_position (:string) - Defaults to "left".
  • icon_size (:string) - Defaults to "sm".
  • class (:string) - Defaults to nil.
  • need_icon_margin (:boolean) - Defaults to nil.
  • loading (:boolean) - Defaults to false.
  • state (:string) - Defaults to "default".

Slots

  • inner_block