mirror of
https://github.com/penpot/penpot.git
synced 2025-02-10 00:58:26 -05:00
🐛 Fix error on collaboratibe editing
This commit is contained in:
parent
d965736751
commit
a3ead3aa6d
3 changed files with 7 additions and 11 deletions
|
@ -28,12 +28,6 @@
|
|||
(s/def ::shape-attrs ::cp/shape-attrs)
|
||||
(s/def ::set-of-string (s/every string? :kind set?))
|
||||
(s/def ::ordered-set-of-uuid (s/every uuid? :kind d/ordered-set?))
|
||||
;; --- Protocols
|
||||
|
||||
(declare setup-selection-index)
|
||||
(declare update-indices)
|
||||
(declare reset-undo)
|
||||
(declare append-undo)
|
||||
|
||||
|
||||
;; --- Helpers
|
||||
|
|
|
@ -7,12 +7,12 @@
|
|||
(ns app.main.data.workspace.notifications
|
||||
(:require
|
||||
[app.common.data :as d]
|
||||
[app.common.uri :as u]
|
||||
[app.common.geom.point :as gpt]
|
||||
[app.common.pages :as cp]
|
||||
[app.common.spec :as us]
|
||||
[app.common.uri :as u]
|
||||
[app.config :as cf]
|
||||
[app.main.data.workspace.common :as dwc]
|
||||
[app.main.data.workspace.changes :as dch]
|
||||
[app.main.data.workspace.libraries :as dwl]
|
||||
[app.main.data.workspace.persistence :as dwp]
|
||||
[app.main.repo :as rp]
|
||||
|
@ -217,7 +217,7 @@
|
|||
(let [changes-by-pages (group-by :page-id changes)
|
||||
process-page-changes
|
||||
(fn [[page-id changes]]
|
||||
(dwc/update-indices page-id changes))]
|
||||
(dch/update-indices page-id changes))]
|
||||
|
||||
(rx/merge
|
||||
(rx/of (dwp/shapes-changes-persisted file-id msg))
|
||||
|
|
|
@ -42,7 +42,8 @@
|
|||
|
||||
(mf/defc interaction
|
||||
[{:keys [shape interactions show-interactions?]}]
|
||||
(let [{:keys [x y width height]} shape]
|
||||
(let [{:keys [x y width height]} (:selrect shape)
|
||||
frame? (= :frame (:type shape))]
|
||||
(when-not (empty? interactions)
|
||||
[:rect {:x (- x 1)
|
||||
:y (- y 1)
|
||||
|
@ -52,7 +53,8 @@
|
|||
:stroke "#31EFB8"
|
||||
:stroke-width (if show-interactions? 1 0)
|
||||
:fill-opacity (if show-interactions? 0.2 0)
|
||||
:style {:pointer-events "none"}}])))
|
||||
:style {:pointer-events (when frame? "none")}
|
||||
:transform (geom/transform-matrix shape)}])))
|
||||
|
||||
(defn generic-wrapper-factory
|
||||
"Wrap some svg shape and add interaction controls"
|
||||
|
|
Loading…
Add table
Reference in a new issue