diff options
author | Markus Wüstenberg | 2020-12-10 14:20:33 +0100 |
---|---|---|
committer | GitHub | 2020-12-10 14:20:33 +0100 |
commit | febffb600db7fbfd81827ded1b8fa3774bf42107 (patch) | |
tree | 853ef8b506ec986f3e4bfe11dc93486af4131006 /html/attributes_test.go | |
parent | 100ae9e8308f380eeb3c6a5ea7a7e3277483aa43 (diff) | |
download | gomponents-febffb600db7fbfd81827ded1b8fa3774bf42107.tar.lz gomponents-febffb600db7fbfd81827ded1b8fa3774bf42107.tar.zst gomponents-febffb600db7fbfd81827ded1b8fa3774bf42107.zip |
Simplify available elements (#55)
`a`, `form`, `img`, `input`, `label`, `option`, `progress`, `select`, and `textarea` are now just regular elements (without helper parameters), because: - Sometimes the use case doesn't fit (`a` as anchor without href, for example) - There's no reason these are special among the others, so streamlining them makes sense Also added new attributes `action`, `alt`, `for`, `method` that I had somehow missed.
Diffstat (limited to 'html/attributes_test.go')
-rw-r--r-- | html/attributes_test.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/html/attributes_test.go b/html/attributes_test.go index 7bf45bb..ba8cbb4 100644 --- a/html/attributes_test.go +++ b/html/attributes_test.go @@ -34,11 +34,14 @@ func TestBooleanAttributes(t *testing.T) { func TestSimpleAttributes(t *testing.T) { cases := map[string]func(string) g.Node{ "accept": Accept, + "action": Action, + "alt": Alt, "autocomplete": AutoComplete, "charset": Charset, "class": Class, "cols": Cols, "content": Content, + "for": For, "form": FormAttr, "height": Height, "href": Href, @@ -46,6 +49,7 @@ func TestSimpleAttributes(t *testing.T) { "lang": Lang, "max": Max, "maxlength": MaxLength, + "method": Method, "min": Min, "minlength": MinLength, "name": Name, |