This commit is contained in:
Alejandro Alonso 2026-03-19 18:42:04 +01:00
parent e870497ae1
commit 7ebdbcd04f
2 changed files with 6 additions and 4 deletions

View File

@ -978,7 +978,8 @@
(select-keys shape [:selrect :points :width :height]))
content-has-text? (v2-content-has-text? content)
prev-content-has-text? (v2-content-has-text? prev-content)
new-size (when (and (not= :fixed (:grow-type shape))
grow-type (:grow-type shape)
new-size (when (and (not= :fixed grow-type)
content-has-text?)
(dwwt/get-wasm-text-new-size shape content))
;; New shapes: single undo on finalize only (no per-keystroke undo)

View File

@ -332,9 +332,10 @@
(defn process-shape-changes!
[objects shape-changes]
(->> (rx/from shape-changes)
(rx/mapcat (fn [[shape-id props]] (process-shape! (get objects shape-id) props)))
(rx/subs! #(api/request-render "set-wasm-attrs"))))
(when (seq shape-changes)
(->> (rx/from shape-changes)
(rx/mapcat (fn [[shape-id props]] (process-shape! (get objects shape-id) props)))
(rx/subs! #(api/request-render "set-wasm-attrs")))))
;; `conj` empty set initialization
(def conj* (fnil conj (d/ordered-set)))