diff options
Diffstat (limited to 'html')
-rw-r--r-- | html/attributes.go | 4 | ||||
-rw-r--r-- | html/attributes_test.go | 1 |
2 files changed, 5 insertions, 0 deletions
diff --git a/html/attributes.go b/html/attributes.go index 7748e0e..2e9a05a 100644 --- a/html/attributes.go +++ b/html/attributes.go @@ -145,6 +145,10 @@ func Height(v string) g.Node { return g.Attr("height", v) } +func Hidden(v string) g.Node { + return g.Attr("hidden", v) +} + func Href(v string) g.Node { return g.Attr("href", v) } diff --git a/html/attributes_test.go b/html/attributes_test.go index 8f72e41..e5ea3f4 100644 --- a/html/attributes_test.go +++ b/html/attributes_test.go @@ -62,6 +62,7 @@ func TestSimpleAttributes(t *testing.T) { {Name: "for", Func: For}, {Name: "form", Func: FormAttr}, {Name: "height", Func: Height}, + {Name: "hidden", Func: Hidden}, {Name: "href", Func: Href}, {Name: "id", Func: ID}, {Name: "integrity", Func: Integrity}, |