From bb7036f4cfd279de388e9850b452b252fefb8e5b Mon Sep 17 00:00:00 2001
From: Erik Hetzner <egh@e6h.org>
Date: Mon, 17 Jan 2022 07:38:57 -0800
Subject: Do not assume that a node is the entire file

A roam node is no longer necessarily an entire file. It can be a file,
or any heading with an id.

Fixes #106
---
 components/Sidebar/Link.tsx | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'components/Sidebar/Link.tsx')

diff --git a/components/Sidebar/Link.tsx b/components/Sidebar/Link.tsx
index e5b1102..6130eb5 100644
--- a/components/Sidebar/Link.tsx
+++ b/components/Sidebar/Link.tsx
@@ -152,7 +152,7 @@ export const PreviewLink = (props: LinkProps) => {
   const extraNoteStyle = outline ? outlineNoteStyle : viewerNoteStyle
   console.log(previewNode)
   const getText = () => {
-    fetch(`http://localhost:35901/file/${file}`)
+    fetch(`http://localhost:35901/node/${id}`)
       .then((res) => {
         return res.text()
       })
-- 
cgit v1.2.3

