PetalComponents.Badge (petal_components v3.0.0)

View Source

Summary

Functions

Attributes

  • size (:string) - Defaults to "md".
  • variant (:string) - Defaults to "light".
  • color (:string) - Defaults to "primary".
  • role (:string) - Defaults to "note".
  • with_icon (:boolean) - adds some icon base classes. Defaults to false.
  • class (:any) - CSS class for parent div. Defaults to nil.
  • label (:string) - label your badge. Defaults to nil.
  • Global attributes are accepted.

Slots

  • inner_block

Functions

badge(assigns)

Attributes

  • size (:string) - Defaults to "md".
  • variant (:string) - Defaults to "light".
  • color (:string) - Defaults to "primary".
  • role (:string) - Defaults to "note".
  • with_icon (:boolean) - adds some icon base classes. Defaults to false.
  • class (:any) - CSS class for parent div. Defaults to nil.
  • label (:string) - label your badge. Defaults to nil.
  • Global attributes are accepted.

Slots

  • inner_block