Add LabelAttr and List attributes (#175) Fixes #168 and fixes #169.
Markus Wüstenberg markus@maragu.dk
Thu, 06 Jun 2024 12:49:01 +0200
2 files changed, 10 insertions(+), 0 deletions(-)
M html/attributes.go → html/attributes.go
@@ -145,8 +145,16 @@ func Integrity(v string) g.Node { return g.Attr("integrity", v) } +func LabelAttr(v string) g.Node { + return g.Attr("label", v) +} + func Lang(v string) g.Node { return g.Attr("lang", v) +} + +func List(v string) g.Node { + return g.Attr("list", v) } func Loading(v string) g.Node {
M html/attributes_test.go → html/attributes_test.go
@@ -61,7 +61,9 @@ {Name: "height", Func: Height}, {Name: "href", Func: Href}, {Name: "id", Func: ID}, {Name: "integrity", Func: Integrity}, + {Name: "label", Func: LabelAttr}, {Name: "lang", Func: Lang}, + {Name: "list", Func: List}, {Name: "loading", Func: Loading}, {Name: "max", Func: Max}, {Name: "maxlength", Func: MaxLength},