glaze/basecoat/label
Basecoat documentation: https://basecoatui.com/components/label/
Label helpers for form controls.
Pair a label with an input by using attribute.for(...) and a matching
input id.
Recipe
import glaze/basecoat/label
import lustre/attribute
import lustre/element/html
fn email_field() {
label.label([attribute.for("email")], [html.text("Email")])
}
Values
pub fn label(
attrs: List(attribute.Attribute(msg)),
children: List(element.Element(msg)),
) -> element.Element(msg)
pub fn with_input(
id: String,
label_text: String,
input_attrs: List(attribute.Attribute(msg)),
) -> element.Element(msg)