mirror of
https://github.com/penpot/penpot.git
synced 2025-02-01 20:09:04 -05:00
🐛 Fix shadows order
This commit is contained in:
parent
83bd479176
commit
35b442d6a7
3 changed files with 17 additions and 3 deletions
|
@ -6,4 +6,4 @@
|
|||
|
||||
(ns app.common.files.defaults)
|
||||
|
||||
(def version 60)
|
||||
(def version 61)
|
||||
|
|
|
@ -1163,6 +1163,18 @@
|
|||
(update :pages-index update-vals update-container)
|
||||
(update :components update-vals update-container))))
|
||||
|
||||
(defn migrate-up-61
|
||||
[data]
|
||||
(letfn [(update-object [object]
|
||||
(d/update-when object :shadow #(into [] (reverse %))))
|
||||
|
||||
(update-container [container]
|
||||
(d/update-when container :objects update-vals update-object))]
|
||||
|
||||
(-> data
|
||||
(update :pages-index update-vals update-container)
|
||||
(update :components update-vals update-container))))
|
||||
|
||||
(def migrations
|
||||
"A vector of all applicable migrations"
|
||||
[{:id 2 :migrate-up migrate-up-2}
|
||||
|
@ -1213,5 +1225,6 @@
|
|||
{:id 56 :migrate-up migrate-up-56}
|
||||
{:id 57 :migrate-up migrate-up-57}
|
||||
{:id 59 :migrate-up migrate-up-59}
|
||||
{:id 60 :migrate-up migrate-up-60}])
|
||||
{:id 60 :migrate-up migrate-up-60}
|
||||
{:id 61 :migrate-up migrate-up-61}])
|
||||
|
||||
|
|
|
@ -161,7 +161,8 @@
|
|||
(mf/defc filters
|
||||
[{:keys [filter-id shape]}]
|
||||
|
||||
(let [filters (-> shape gsb/shape->filters change-filter-in)
|
||||
(let [shape' (update shape :shadow reverse)
|
||||
filters (-> shape' gsb/shape->filters change-filter-in)
|
||||
bounds (gsb/get-rect-filter-bounds (:selrect shape) filters (or (-> shape :blur :value) 0))
|
||||
padding (gsb/calculate-padding shape)
|
||||
selrect (:selrect shape)
|
||||
|
|
Loading…
Add table
Reference in a new issue