Fix dom-listen: rename dom-on to dom-listen in dom.sx
adapter-dom.sx defines dom-on as a wrapper around dom-listen (adds post-render hooks). But dom-listen was never defined — my earlier dom-on in dom.sx was overwritten by the adapter's version. Rename to dom-listen so the adapter's dom-on can call it. This fixes click handlers not firing on island buttons (stepper, stopwatch, counter, etc.). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -97,7 +97,7 @@
|
||||
(fn (child parent)
|
||||
(and child parent (host-call parent "contains" child))))
|
||||
|
||||
(define dom-on
|
||||
(define dom-listen
|
||||
(fn (el event-name handler)
|
||||
(host-call el "addEventListener" event-name (host-callback handler))))
|
||||
|
||||
|
||||
@@ -97,7 +97,7 @@
|
||||
(fn (child parent)
|
||||
(and child parent (host-call parent "contains" child))))
|
||||
|
||||
(define dom-on
|
||||
(define dom-listen
|
||||
(fn (el event-name handler)
|
||||
(host-call el "addEventListener" event-name (host-callback handler))))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user