mirror of
https://github.com/penpot/penpot.git
synced 2026-02-26 22:34:11 +00:00
🐛 Fix image paste in production build
This commit is contained in:
@@ -86,10 +86,10 @@
|
||||
[]
|
||||
(let [cboard (unchecked-get js/navigator "clipboard")
|
||||
read-item (fn [item]
|
||||
(let [img-type (->> (.-types item)
|
||||
(let [img-type (->> (.-types ^js item)
|
||||
(d/seek #(str/starts-with? % "image/")))]
|
||||
(if img-type
|
||||
(rx/from (.getType item img-type))
|
||||
(rx/from (.getType ^js item img-type))
|
||||
(rx/empty))))]
|
||||
(->> (rx/from (.read ^js cboard)) ;; Get a stream of item lists
|
||||
(rx/mapcat identity) ;; Convert each item into an emission
|
||||
|
||||
Reference in New Issue
Block a user