mirror of
https://github.com/logseq/logseq.git
synced 2026-05-01 09:26:28 +00:00
enhance: use css to handle select-none instead of component state
This commit is contained in:
@@ -891,6 +891,7 @@
|
||||
[state route-match main-content]
|
||||
(let [{:keys [open-fn]} state
|
||||
current-repo (state/sub :git/current-repo)
|
||||
selection-mode? (state/sub :selection/mode)
|
||||
granted? (state/sub [:nfs/user-granted? (state/get-current-repo)])
|
||||
theme (state/sub :ui/theme)
|
||||
accent-color (some-> (state/sub :ui/radix-color) (name))
|
||||
@@ -952,7 +953,8 @@
|
||||
(when (= "Enter" (.-key e))
|
||||
(ui/focus-element (ui/main-node))))}
|
||||
(t :accessibility/skip-to-main-content)]
|
||||
[:div.#app-container
|
||||
[:div.#app-container (cond-> {} selection-mode?
|
||||
(assoc :class "blocks-selection-mode"))
|
||||
[:div#left-container
|
||||
{:class (if (state/sub :ui/sidebar-open?) "overflow-hidden" "w-full")}
|
||||
(header/header {:open-fn open-fn
|
||||
|
||||
Reference in New Issue
Block a user