From 68e1dbc7c2a434c7be8cd5cc78b2c34726d0992c Mon Sep 17 00:00:00 2001 From: Brian Gwaltney Date: Tue, 20 Feb 2024 16:06:41 +0300 Subject: [PATCH] typo from my last commit --- htmx.go | 4 ++-- htmx_test.go | 64 ++++++++++++++++++++++++++-------------------------- 2 files changed, 34 insertions(+), 34 deletions(-) diff --git a/htmx.go b/htmx.go index 9809b51..b8f74f1 100644 --- a/htmx.go +++ b/htmx.go @@ -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. diff --git a/htmx_test.go b/htmx_test.go index 8147328..6798220 100644 --- a/htmx_test.go +++ b/htmx_test.go @@ -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 {