flarebyte/bubblegum-entity

Access to settings and states for widgets of the Bubblegum UI toolkit.


Keywords
experimental
License
BSD-3-Clause
Install
elm-package install flarebyte/bubblegum-entity 1.1.1

Documentation

Bubblegum-entity

Status of direct dependencies License of the package Latest version of the package

Access to settings and states for widgets of the Bubblegum UI toolkit

Model

Attribute

An attribute represents a small piece of information such as a Semantic triple.

attrLabel =
{ id = Just "id:1234"
, key = "ui:label"
, facets = ["blue"]
, values = ["Some label"]
}

Outcome

An outcome is a type which borrows concepts from both Elm Maybe and Result.

type Outcome value
= Valid value
| None
| Warning String

Settings

A settings entity represents some configuration that is applied to a widget.

{
attributes = [
attr "ui:label" "some label"
, attr "ui:font" "Arial"
]
}

State

A state entity is similar to settings but represents the live state that is applied to a widget.

{
attributes = [
attr "ui:selection" "first item"
]
}

Validation

List of validations that can be applied to an outcome.

For most validations:

  • None will propagate as None.
  • Warning will propagate as Warning.
  • A failure to validate the outcome will produce a Warning.

Documentation and links

Installation

elm install flarebyte/bubblegum-entity