0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-21 06:02:32 -05:00

Fix instant value change applies shape attributes

This commit is contained in:
Florian Schroedl 2024-05-24 10:00:26 +02:00
parent bc620ba2cd
commit b6061cc4a0

View file

@ -135,6 +135,12 @@
value (or (d/parse-double value) value)]
(set-value value)))
handle-token-change-input
(fn [event]
(let [value (-> event dom/get-target dom/get-value)
value (or (d/parse-double value) value)]
(set-token-value! value)))
handle-key-down
(mf/use-fn
(mf/deps set-value is-open? token)
@ -214,7 +220,7 @@
(cond
token [:input {:value (or (:token-value state) "")
:class input-class
:on-change handle-change-input
:on-change handle-token-change-input
:on-key-down handle-key-down
:on-focus handle-focus
:on-blur handle-blur