mirror of
https://github.com/logseq/logseq.git
synced 2026-04-27 23:54:55 +00:00
tempory fix for wrong positions of custom context menu
which is caused by the bump of rum too.
This commit is contained in:
@@ -228,10 +228,15 @@
|
||||
client-y (gobj/get e "clientY")
|
||||
scroll-y (util/cur-doc-top)]
|
||||
(state/show-custom-context-menu! context-menu-content)
|
||||
(when-let [context-menu (d/by-id "custom-context-menu")]
|
||||
(d/set-style! context-menu
|
||||
:left (str client-x "px")
|
||||
:top (str (+ scroll-y client-y) "px")))))
|
||||
|
||||
;; FIXME: use setTimeout here because rum renders lazily.
|
||||
(js/setTimeout
|
||||
(fn []
|
||||
(when-let [context-menu (d/by-id "custom-context-menu")]
|
||||
(d/set-style! context-menu
|
||||
:left (str client-x "px")
|
||||
:top (str (+ scroll-y client-y) "px"))))
|
||||
10)))
|
||||
|
||||
(defn parse-config
|
||||
"Parse configuration from file `content` such as from config.edn."
|
||||
|
||||
Reference in New Issue
Block a user