mirror of
https://github.com/penpot/penpot.git
synced 2025-02-23 07:16:07 -05:00
🐛 Fixes issue with multiple selection and shadows
This commit is contained in:
parent
04670bb5f2
commit
32b0fd7b36
2 changed files with 12 additions and 2 deletions
|
@ -47,7 +47,12 @@
|
|||
|
||||
handle-change
|
||||
(fn [value]
|
||||
(change! #(assoc-in % [:blur :value] value)))
|
||||
(change! #(cond-> %
|
||||
(not (contains? % :blur))
|
||||
(assoc :blur (create-blur))
|
||||
|
||||
:always
|
||||
(assoc-in [:blur :value] value))))
|
||||
|
||||
handle-toggle-visibility
|
||||
(fn []
|
||||
|
|
|
@ -123,6 +123,9 @@
|
|||
[v]
|
||||
(when v (select-keys v blur-keys)))
|
||||
|
||||
(defn empty-map [keys]
|
||||
(into {} (map #(hash-map % nil)) keys))
|
||||
|
||||
(defn get-attrs
|
||||
"Given a `type` of options that we want to extract and the shapes to extract them from
|
||||
returns a list of tuples [id, values] with the extracted properties for the shapes that
|
||||
|
@ -142,7 +145,9 @@
|
|||
result (case props
|
||||
:ignore [ids values]
|
||||
:shape [(conj ids id)
|
||||
(merge-attrs values (select-keys shape attrs))]
|
||||
(merge-attrs values (merge
|
||||
(empty-map attrs)
|
||||
(select-keys shape attrs)))]
|
||||
:text [(conj ids id)
|
||||
(-> values
|
||||
(merge-attrs (select-keys shape attrs))
|
||||
|
|
Loading…
Add table
Reference in a new issue