nyash
7e35a2ac41
add hx-target find selector test
2020-08-31 10:34:08 +02:00
1cg
8983448b33
Merge pull request #145 from rros/users/rros/fix-queryselector-issue
...
Fix issue with unquoted id attribute in query selector
2020-08-30 18:50:50 -07:00
1cg
3ec2b3bb3a
Merge pull request #166 from bencroker/patch-17
...
Added event tests and fixed names
2020-08-30 15:46:26 -07:00
carson
22af2347b9
enqueue requests when a trigger occurs while a request is in flight
...
fixes https://github.com/bigskysoftware/htmx/issues/152
2020-08-19 07:39:55 -06:00
Ben Croker
bfaedef497
Added event tests
...
Added `afterRequest`, `afterOnLoad` and `sendError` event tests.
2020-08-17 19:37:56 +02:00
Ben Croker
331881aed9
Fixed event names
2020-08-17 19:31:07 +02:00
Robert Ros
c6fe43adcd
Add testcase for issue with id attributes with a dot.
2020-07-20 20:57:16 +02:00
Ben Weller
381005b018
clean up extraneous newlines in test
2020-07-19 09:29:56 -05:00
Ben Weller
612d2fedf1
remove console.log() noise from new test
2020-07-19 09:15:58 -05:00
Ben Weller
8fcf27ab8c
add test for <select multiple>
2020-07-19 09:13:32 -05:00
carson
93cfc2e1f6
update to alpha4
2020-06-30 16:15:22 -07:00
carson
416ee3dde2
fix test
2020-06-30 12:17:34 -07:00
carson
b22b1d104c
Merge remote-tracking branch 'origin/dev' into dev
2020-06-30 10:45:38 -07:00
carson
4f3cf2d889
Move events from <event name>.htmx
(jQuery style) to htmx:<event name>
(zepto style)
...
fixes https://github.com/bigskysoftware/htmx/issues/109
2020-06-30 10:45:30 -07:00
chg20
2fbe230853
Merge pull request #122 from bencroker/patch-8
...
Allowed `hx-push-url` to accept a string
2020-06-28 22:17:24 -07:00
carson
70d770a1b5
Add support for the hx-vars
attribute, for including dynamically computed values in requests
...
Fixes https://github.com/bigskysoftware/htmx/issues/120
2020-06-28 17:07:39 -07:00
Ben Croker
a4a550d9ea
Added test for when string
2020-06-26 15:52:21 +02:00
carson
eb04ab5b3e
add scroll
and view
modifiers to hx-swap
2020-06-23 14:25:56 -07:00
carson
276082f2c2
exclude value and id from the settle swap to avoid flicker
2020-06-19 06:29:46 -07:00
carson
2524fcf436
rename test
2020-06-17 18:37:02 -07:00
carson
74c7395f1f
integrate improvement for extension swapping, back out extension passing through event object, run www and dist
2020-06-17 18:33:41 -07:00
chg20
6c8930028c
Merge pull request #94 from twidi/handle-events-and-content-after-handleSwap-extensions
...
Handle events and content after `handleSwap` in extensions
2020-06-17 18:05:45 -07:00
carson
99d18d347f
test fix
2020-06-17 15:35:58 -07:00
chg20
025b043918
Merge branch 'dev' into json-parse
2020-06-17 15:28:33 -07:00
carson
f9463686e0
switch to contain for safari
2020-06-17 15:15:17 -07:00
carson
76a1d5c5a4
fix remove-me extension tests
2020-06-17 15:02:32 -07:00
carson
6083a2ea74
remove bad console logs
2020-06-17 14:58:38 -07:00
carson
5c8b47deb3
update perf to reasonable numbers
2020-06-17 13:54:43 -07:00
carson
b07ed32dc4
selector implementation for processNode
2020-06-17 13:42:18 -07:00
carson
b6f1c834cf
include perf tests
2020-06-17 12:30:52 -07:00
carson
19b933449b
catch empty IDs in attribute swap, fixes https://github.com/bigskysoftware/htmx/issues/101
2020-06-16 19:20:23 -07:00
carson
efd3ab85f0
regression for https://github.com/bigskysoftware/htmx/issues/101
2020-06-16 16:46:19 -07:00
carson
504bd34ee4
fix tests, hyperscript is so awesome
2020-06-15 18:28:14 -07:00
chg20
64f263f778
Merge pull request #82 from 36864/dev
...
Add an extension to include the commonly-used X-Requested-With header
2020-06-15 18:25:07 -07:00
carson
84200f4599
update hyperscript and docs
2020-06-13 13:17:25 -07:00
carson
0ac641b63f
remove the hx-error-url attribute in favor of hyperscript
...
add basic hyperscript compatibility testing
2020-06-12 13:42:55 -07:00
Stephane Angel (Twidi)
0b9448e727
Extension.handleSwap: handle new content
...
Before this commit, the content that were swapped by an extension via
`handleSwap` was not handled by htmx: elemtents with `hx-` attributes,
scripts, no `load.htmx` event...
With this commit, if the `handleSwap` command returns an array of newly
added elements (only the first level), then they will be handled by htmx
like it's done for internal swap.
To not break existing extensions, `handleSwap` can still return `true`
to tell that the swap was handled, assuming than there is no new
elements to handle.
A new test was added with a button that, when clicked, loads a text and
a span with `hx-trigger=load`, both handled by an extension. This commit
allows this span to be loaded.
The return of the `morphdom-swap` extension was updated to return the
target element, even if unchanged, to let htmx check in the maybe new
content that there is something new to handle. This is tested in a new
test.
2020-06-12 02:08:05 +02:00
Stephane Angel (Twidi)
86febd3efc
Extension.handleSwap: trigger events for extensions defined on parents
...
If an element is replaced by an extension in `handleSwap`, the events
(`afterSwap.htmx` and `afterSettle.htmx`) were not received by the
`onLoad` method of extensions defined on parents of the target, because
theses extensions were retrieved after the replacement, and so it was
not possible to get through the parents, the target not being in the dom
anymore.
This commits loads the extensions for the target and save them in
`eventDetail` before doing the swap, so they are accessible in
`triggerEvent`, and passed to `withExtensions` that use this list if
passed (else load them).
A new test is added that fails without the updates in `htmx.js`.
2020-06-12 01:20:13 +02:00
carson
296f354fef
fix throttle and make the trigger spec test actually work
2020-06-11 09:45:42 -07:00
carson
96c9623a3d
test fix
2020-06-11 06:55:50 -07:00
carson
2ac221bdbc
try to preserve focus and selection state when active element is replaced
...
fixes https://github.com/bigskysoftware/htmx/issues/75
2020-06-11 06:53:18 -07:00
carson
1f62541094
support throttle modifier in trigger definition
...
https://github.com/bigskysoftware/htmx/issues/88
2020-06-11 06:21:49 -07:00
carson
4ef719e63a
support hx-swap="none"
...
fixes https://github.com/bigskysoftware/htmx/issues/89
2020-06-11 06:02:23 -07:00
carson
a65c37ec4f
Include full path w/ variables when pushing a GET
...
Fixes https://github.com/bigskysoftware/htmx/issues/58
2020-06-10 16:37:03 -07:00
carson
6f14cba2e6
Trigger events on new content, rather than triggering element, since triggering element may have been replaced
...
fixes https://github.com/bigskysoftware/htmx/issues/79
2020-06-10 16:09:00 -07:00
carson
2305aed18e
Move X-HTTP-Method-Override out to an extension
...
fixes https://github.com/bigskysoftware/htmx/issues/86
2020-06-10 16:01:56 -07:00
Robert Schroll
1060c9e88a
Avoid throwing errors when parsing malformed JSON
...
Instead, treat it as if no value was present.
2020-06-08 00:55:09 -07:00
36864
92561e193c
Add an extension to include the commonly-used X-Requested-With header
2020-06-05 15:44:02 +01:00
acnebs
d01025823e
Rename custom HTTP headers to no longer start with X-
...
This convention is deprecated, as per this RFC from the IETF:
https://tools.ietf.org/html/rfc6648
2020-05-28 01:29:51 +01:00
carson
3d814327af
handle exceptions in embedded script tags gracefully
2020-05-26 17:32:22 -07:00