mirror of
https://github.com/penpot/penpot.git
synced 2025-05-20 10:56:11 +02:00
Merge remote-tracking branch 'origin/staging' into develop
This commit is contained in:
commit
5fc303a05d
6 changed files with 38 additions and 16 deletions
|
@ -1377,17 +1377,18 @@
|
|||
(not (contains? #{:group :bool} (:type head))))
|
||||
|
||||
no-bool-shapes? (->> all-selected (some (comp #{:frame :text} :type)))]
|
||||
|
||||
(rx/concat
|
||||
(when (and (some? shape) (not (contains? selected (:id shape))))
|
||||
(rx/of (dws/select-shape (:id shape))))
|
||||
(rx/of (show-context-menu
|
||||
(-> params
|
||||
(assoc
|
||||
:kind :shape
|
||||
:disable-booleans? (or no-bool-shapes? not-group-like?)
|
||||
:disable-flatten? no-bool-shapes?
|
||||
:selected (conj selected (:id shape)))))))))))
|
||||
|
||||
(if (and (some? shape) (not (contains? selected (:id shape))))
|
||||
(rx/concat
|
||||
(rx/of (dws/select-shape (:id shape)))
|
||||
(rx/of (show-shape-context-menu params)))
|
||||
(rx/of (show-context-menu
|
||||
(-> params
|
||||
(assoc
|
||||
:kind :shape
|
||||
:disable-booleans? (or no-bool-shapes? not-group-like?)
|
||||
:disable-flatten? no-bool-shapes?
|
||||
:selected (conj selected (:id shape)))))))))))
|
||||
|
||||
(defn show-page-item-context-menu
|
||||
[{:keys [position page] :as params}]
|
||||
|
|
|
@ -77,6 +77,7 @@
|
|||
|
||||
on-thread-click
|
||||
(mf/use-callback
|
||||
(mf/deps page-id)
|
||||
(fn [thread]
|
||||
(when (not= page-id (:page-id thread))
|
||||
(st/emit! (dw/go-to-page (:page-id thread))))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue