mirror of
https://github.com/penpot/penpot.git
synced 2025-05-17 23:16:11 +02:00
🐛 Fix escape key to exit comments mode
This commit is contained in:
parent
5d95d755ad
commit
284d5ecb77
1 changed files with 6 additions and 1 deletions
|
@ -15,6 +15,7 @@
|
||||||
[app.main.data.changes :as dch]
|
[app.main.data.changes :as dch]
|
||||||
[app.main.data.comments :as dcm]
|
[app.main.data.comments :as dcm]
|
||||||
[app.main.data.events :as ev]
|
[app.main.data.events :as ev]
|
||||||
|
[app.main.data.workspace :as dw]
|
||||||
[app.main.data.workspace.common :as dwco]
|
[app.main.data.workspace.common :as dwco]
|
||||||
[app.main.data.workspace.drawing :as dwd]
|
[app.main.data.workspace.drawing :as dwd]
|
||||||
[app.main.data.workspace.state-helpers :as wsh]
|
[app.main.data.workspace.state-helpers :as wsh]
|
||||||
|
@ -60,7 +61,11 @@
|
||||||
(let [local (:comments-local state)]
|
(let [local (:comments-local state)]
|
||||||
(cond
|
(cond
|
||||||
(:draft local) (rx/of (dcm/close-thread))
|
(:draft local) (rx/of (dcm/close-thread))
|
||||||
(:open local) (rx/of (dcm/close-thread)))))))
|
(:open local) (rx/of (dcm/close-thread))
|
||||||
|
|
||||||
|
:else
|
||||||
|
(rx/of (dw/clear-edition-mode)
|
||||||
|
(dw/deselect-all true)))))))
|
||||||
|
|
||||||
;; Event responsible of the what should be executed when user clicked
|
;; Event responsible of the what should be executed when user clicked
|
||||||
;; on the comments layer. An option can be create a new draft thread,
|
;; on the comments layer. An option can be create a new draft thread,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue