lenards/elm-ui-patternfly/1.5.1

NOTE: the latest version is 4.0.2

PF4.Label

A label component for closable (or dismissable) text

Definition

type Label msg

Opaque Label element that can produce msg messages

type Variant

An opaque Variant custom type with 2 variants

Outline, Fill

Constructor function

label : String -> Label msg

Constructs a label from the text

Configuration functions

withFill : Label msg -> Label msg

Configures appearance to have a Fill

withOutline : Label msg -> Label msg

Configures appearance to have an Outline

withIcon : Element msg -> Label msg -> Label msg

Configures the label to include an icon defined by the Element msg passed

withCloseMsg : msg -> Label msg -> Label msg

Configures what msg is produced "on close"

The event "on close" is produce when the "close" x is clicked.

Rendering element

toMarkup : Label msg -> Element msg

Given the custom type representation, renders as an Element msg.