Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

typo from my last commit #12

Merged
merged 1 commit into from
Feb 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions htmx.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,8 @@ func Disable(v string) g.Node {

// Disable element until htmx request completes.
// See https://htmx.org/attributes/hx-disabled-elt/
func DisableElt(v string) g.Node {
return attr("disable-elt", v)
func DisabledElt(v string) g.Node {
return attr("disabled-elt", v)
}

// Disinherit controls and disables automatic attribute inheritance for child nodes.
Expand Down
64 changes: 32 additions & 32 deletions htmx_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,38 +14,38 @@ import (

func TestAttributes(t *testing.T) {
cases := map[string]func(string) g.Node{
"boost": hx.Boost,
"get": hx.Get,
"post": hx.Post,
"push-url": hx.PushURL,
"select": hx.Select,
"select-oob": hx.SelectOOB,
"swap": hx.Swap,
"swap-oob": hx.SwapOOB,
"target": hx.Target,
"trigger": hx.Trigger,
"vals": hx.Vals,
"confirm": hx.Confirm,
"delete": hx.Delete,
"disable": hx.Disable,
"disable-elt": hx.DisableElt,
"disinherit": hx.Disinherit,
"encoding": hx.Encoding,
"ext": hx.Ext,
"headers": hx.Headers,
"history": hx.History,
"history-elt": hx.HistoryElt,
"include": hx.Include,
"indicator": hx.Indicator,
"params": hx.Params,
"patch": hx.Patch,
"preserve": hx.Preserve,
"prompt": hx.Prompt,
"put": hx.Put,
"replace-url": hx.ReplaceURL,
"request": hx.Request,
"sync": hx.Sync,
"validate": hx.Validate,
"boost": hx.Boost,
"get": hx.Get,
"post": hx.Post,
"push-url": hx.PushURL,
"select": hx.Select,
"select-oob": hx.SelectOOB,
"swap": hx.Swap,
"swap-oob": hx.SwapOOB,
"target": hx.Target,
"trigger": hx.Trigger,
"vals": hx.Vals,
"confirm": hx.Confirm,
"delete": hx.Delete,
"disable": hx.Disable,
"disabled-elt": hx.DisabledElt,
"disinherit": hx.Disinherit,
"encoding": hx.Encoding,
"ext": hx.Ext,
"headers": hx.Headers,
"history": hx.History,
"history-elt": hx.HistoryElt,
"include": hx.Include,
"indicator": hx.Indicator,
"params": hx.Params,
"patch": hx.Patch,
"preserve": hx.Preserve,
"prompt": hx.Prompt,
"put": hx.Put,
"replace-url": hx.ReplaceURL,
"request": hx.Request,
"sync": hx.Sync,
"validate": hx.Validate,
}

for name, fn := range cases {
Expand Down
Loading