lenards/elm-ui-patternfly/4.0.1

NOTE: the latest version is 4.0.2

PF6.Badge

PF6 Badge component

Displays counts or status indicators as pill-shaped elements.

See: https://www.patternfly.org/components/badge

Definition

type Badge

Opaque Badge type

type Status

Read or Unread status

Constructor functions

badge : Int -> Badge

Construct a Badge with a read status

Construct a Badge with unread status

Configuration functions

Set status to Read (gray background)

Set status to Unread (blue background)

Set the overflow threshold. Counts above this show as "N+"

Predicates

isRead : Badge -> Bool

True if badge status is Read

isUnread : Badge -> Bool

True if badge status is Unread

Rendering

toMarkup : Theme -> Badge -> Element msg

Render the Badge as an Element msg