diff options
-rw-r--r-- | org-roam-ui.el | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/org-roam-ui.el b/org-roam-ui.el index 97e1da2..775b3ea 100644 --- a/org-roam-ui.el +++ b/org-roam-ui.el @@ -57,7 +57,7 @@ :group 'org-roam-ui :type 'number) -(defcustom org-roam-ui-sync-theme t +(defcustom org-roam-ui-sync-theme nil "If true, sync your current Emacs theme with `org-roam-ui'. Works best with doom-themes. Ignored if a custom theme is provied for variable 'org-roam-ui-custom-theme'." @@ -612,7 +612,7 @@ from all other links." (defun org-roam-ui--update-current-node () "Send the current node data to the web-socket." (when (and (websocket-openp org-roam-ui-ws-socket) - (org-roam-buffer-p) + (bound-and-true-p org-gnosis-mode) (buffer-file-name (buffer-base-buffer))) (let* ((node (org-gnosis-get-id))) (setq org-roam-ui--ws-current-node node) @@ -814,9 +814,9 @@ Optionally with ID (string), SPEED (number, ms) and PADDING (number, px)." :init-value nil (if org-roam-ui-follow-mode (progn - (add-hook 'org-gnosis-mode-hook #'org-roam-ui-node-zoom) + (add-hook 'post-command-hook #'org-roam-ui--update-current-node) (message "org-roam-ui will now follow you around.")) - (remove-hook 'org-gnosis-mode-hook #'org-roam-ui-node-zoom) + (remove-hook 'post-command-hook #'org-roam-ui--update-current-node) (message "org-roam-ui will now leave you alone."))) (provide 'org-roam-ui) |