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:
2026-03-25 14:56:34 +00:00
parent 0c8c0b6426
commit fb8dbeba9f
2 changed files with 2 additions and 2 deletions

View File

@@ -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))))