🐛 Fix plugin API crash when setting text fills (#10051)

The `update-text-range` event's `watch` method was returning a bare
potok event object (`dwwt/resize-wasm-text-debounce id`) directly
inside `rx/concat`, instead of wrapping it in `rx/of`. This caused
RxJS to throw "You provided an invalid object where a stream was
expected" when a plugin set text fills via the Plugin API.

The fix wraps the event in `rx/of` so it becomes a valid Observable,
matching the pattern used elsewhere in the codebase (e.g.,
`clipboard.cljs` lines 1050/1082 and `texts.cljs` line 1232).

Signed-off-by: Andrey Antukh <niwi@niwi.nz>
This commit is contained in:
Andrey Antukh 2026-06-08 11:33:36 +02:00 committed by GitHub
parent 4f852e33bf
commit 4d0a3efc5c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -411,7 +411,7 @@
(rx/concat
(rx/of (dwsh/update-shapes shape-ids update-fn))
(if (features/active-feature? state "render-wasm/v1")
(dwwt/resize-wasm-text-debounce id)
(rx/of (dwwt/resize-wasm-text-debounce id))
(rx/empty)))))))
(defn update-root-attrs