package brr

  1. Overview
  2. Docs
On This Page
  1. Labels
  2. Styling
Legend:
Library
Module
Module type
Parameter
Class
Class type

Labels.

Labels are for displaying short units of textual content. See the styling information.

Labels

type t

The type for labels.

val v : ?class':Jstr.t -> ?enabled:bool Note.signal -> ?tip:Jstr.t Note.signal -> Brr.El.t list Note.signal -> t

v ~class' ~enabled ~tip label is a label with:

  • label the label's contents.
  • enabled indicates if the label should look as such. Defaults to Note.S.Bool.true'
  • tip is a tooltip for the label.
  • class' is added to the element's classes.
val enabled : t -> bool Note.signal

enabled l is a signal that is true iff the label is enabled.

val el : t -> Brr.El.t

el l is l's DOM element.

Styling

The element returned by el makes use of the following CSS classes:

  • ui-label always.
  • ui-disabled whenever enabled is false.