mirror of
https://github.com/penpot/penpot.git
synced 2026-03-21 18:03:47 +00:00
🐛 Fix circle dimensions update.
This commit is contained in:
@@ -203,8 +203,12 @@
|
||||
instead of absolute positions."
|
||||
[shape opts]
|
||||
(case (:type shape)
|
||||
:cirle (resize-dim-circle shape opts)
|
||||
(resize-dim-rect shape opts)))
|
||||
:rect (resize-dim-rect shape opts)
|
||||
:canvas (resize-dim-rect shape opts)
|
||||
:icon (resize-dim-rect shape opts)
|
||||
:image (resize-dim-rect shape opts)
|
||||
:text (resize-dim-rect shape opts)
|
||||
:circle (resize-dim-circle shape opts)))
|
||||
|
||||
(defn- resize-dim-rect
|
||||
[{:keys [proportion proportion-lock x y] :as shape}
|
||||
@@ -224,7 +228,6 @@
|
||||
(defn- resize-dim-circle
|
||||
[{:keys [proportion proportion-lock] :as shape}
|
||||
{:keys [rx ry]}]
|
||||
{:pre [(not (and rx ry))]}
|
||||
(if-not proportion-lock
|
||||
(if rx
|
||||
(assoc shape :rx rx)
|
||||
|
||||
@@ -73,7 +73,7 @@
|
||||
:on-change on-size-rx-change
|
||||
:value (-> (:rx shape)
|
||||
(math/precision 2)
|
||||
(d/coalesce-str "0"))}]]
|
||||
(d/coalesce-str "0"))}]]
|
||||
[:div.lock-size {:class (when (:proportion-lock shape) "selected")
|
||||
:on-click on-proportion-lock-change}
|
||||
(if (:proportion-lock shape)
|
||||
|
||||
Reference in New Issue
Block a user