Create interactive controls for complex data structures.
A Control that allows a Date (include date and time) input
with a date picker UI.
A Control that chooses between a list of values with a dropdown UI.
The first value will be the initial value.
A Control that wraps another control in a Maybe, which a checkbox UI.
The Bool parameter is the initial value, where False is Nothing,
and True is Just with the value of the nested control.
A Control that chooses between a list of nested controls.
This will crash if you provide an empty list.
The first entry will be the initial value.
Create a Control representing a record with multiple fields.
This uses an API similar to elm-decode-pipeline.
You will use this with field.
import Debug.Control exposing (field, record, string)
type alias Point =
{ x : String
, y : String
}
pointControl : Control Point
pointControl =
record Point
|> field "x" (string "initial x value")
|> field "y" (string "initial y value")Used with record to create a Control representing a record.
See record.
Gets the current value of a Control.
An interactive control that produces a value
a.