summaryrefslogtreecommitdiff
path: root/org-roam-ui.el
diff options
context:
space:
mode:
authorThomas F. K. Jorna <[email protected]>2021-10-07 02:05:58 +0200
committerThomas F. K. Jorna <[email protected]>2021-10-07 02:05:58 +0200
commitf495a9499c549d92d64ee3a2e50a239ea769c609 (patch)
tree2f560b4dc24bc31ac3d9af05d6918c87d63377d6 /org-roam-ui.el
parentbae6487afd5e6eec9f04b38b235bbac24042ca62 (diff)
fix: make daily toggle useful
Diffstat (limited to 'org-roam-ui.el')
-rw-r--r--org-roam-ui.el6
1 files changed, 4 insertions, 2 deletions
diff --git a/org-roam-ui.el b/org-roam-ui.el
index f363331..ad0cad6 100644
--- a/org-roam-ui.el
+++ b/org-roam-ui.el
@@ -36,6 +36,7 @@
(require 'json)
(require 'simple-httpd)
(require 'org-roam)
+(require 'org-roam-dailies)
(require 'websocket)
(defgroup org-roam-ui nil
@@ -168,6 +169,7 @@ This serves the web-build and API over HTTP."
:host 'local
:on-open (lambda (ws) (progn
(setq oru-ws ws)
+ (org-roam-ui--send-variables ws)
(org-roam-ui--send-graphdata)
(when org-roam-ui-update-on-save
(add-hook 'after-save-hook #'org-roam-ui--on-save))
@@ -385,8 +387,8 @@ unchanged."
(when (boundp 'org-roam-dailies-directory)
(websocket-send-text ws (json-encode `((type . "variables")
(data .
- (("daily-directory" . ,(concat org-roam-directory org-roam-dailies-directory))
- ("org-roam-directory" . ,org-roam-directory))))))))
+ (("dailyDir" . ,(concat org-roam-directory org-roam-dailies-directory))
+ ("roamDir" . ,org-roam-directory))))))))
(defun org-roam-ui-sql-to-alist (column-names rows)
"Convert sql result to alist for json encoding.