mirror of
https://github.com/penpot/penpot.git
synced 2025-07-30 04:58:35 +02:00
💄 Add some cosmetic adjustements
This commit is contained in:
parent
b20d2badfe
commit
5192b36669
2 changed files with 8 additions and 8 deletions
|
@ -36,11 +36,10 @@
|
||||||
;; will be empty on first rendering before drawing the thumbnail and we don't want to store that
|
;; will be empty on first rendering before drawing the thumbnail and we don't want to store that
|
||||||
(let [node (dom/query (dm/fmt "canvas.thumbnail-canvas[data-object-id='%'][data-empty='false']" object-id))]
|
(let [node (dom/query (dm/fmt "canvas.thumbnail-canvas[data-object-id='%'][data-empty='false']" object-id))]
|
||||||
(if (some? node)
|
(if (some? node)
|
||||||
(-> node
|
(.toBlob node (fn [blob]
|
||||||
(.toBlob (fn [blob]
|
(rx/push! subs blob)
|
||||||
(rx/push! subs blob)
|
(rx/end! subs))
|
||||||
(rx/end! subs))
|
"image/png")
|
||||||
"image/png"))
|
|
||||||
|
|
||||||
;; If we cannot find the node we send `nil` and the upsert will delete the thumbnail
|
;; If we cannot find the node we send `nil` and the upsert will delete the thumbnail
|
||||||
(do (rx/push! subs nil)
|
(do (rx/push! subs nil)
|
||||||
|
|
|
@ -45,9 +45,10 @@
|
||||||
|
|
||||||
(defn check-props
|
(defn check-props
|
||||||
[new-props old-props]
|
[new-props old-props]
|
||||||
(and
|
(and (= (unchecked-get new-props "thumbnail?")
|
||||||
(= (unchecked-get new-props "thumbnail?") (unchecked-get old-props "thumbnail?"))
|
(unchecked-get old-props "thumbnail?"))
|
||||||
(= (unchecked-get new-props "shape") (unchecked-get old-props "shape"))))
|
(= (unchecked-get new-props "shape")
|
||||||
|
(unchecked-get old-props "shape"))))
|
||||||
|
|
||||||
(defn nested-frame-wrapper-factory
|
(defn nested-frame-wrapper-factory
|
||||||
[shape-wrapper]
|
[shape-wrapper]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue