mirror of
https://github.com/penpot/penpot.git
synced 2026-08-07 13:29:07 +00:00
✨ Add missing srepl helper for disable objects-map feat
This commit is contained in:
parent
62563d28d0
commit
9f2dc06c95
@ -49,6 +49,20 @@
|
|||||||
(update :data update-data)
|
(update :data update-data)
|
||||||
(update :features conj "fdata/objects-map"))))
|
(update :features conj "fdata/objects-map"))))
|
||||||
|
|
||||||
|
(defn disable-objects-map
|
||||||
|
[file & _opts]
|
||||||
|
(let [update-page
|
||||||
|
(fn [page]
|
||||||
|
(update page :objects #(into {} %)))
|
||||||
|
|
||||||
|
update-data
|
||||||
|
(fn [fdata]
|
||||||
|
(update fdata :pages-index d/update-vals update-page))]
|
||||||
|
|
||||||
|
(-> file
|
||||||
|
(update :data update-data)
|
||||||
|
(update :features disj "fdata/objects-map"))))
|
||||||
|
|
||||||
(defn process-objects
|
(defn process-objects
|
||||||
"Apply a function to all objects-map on the file. Usualy used for convert
|
"Apply a function to all objects-map on the file. Usualy used for convert
|
||||||
the objects-map instances to plain maps"
|
the objects-map instances to plain maps"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user