aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/Main.tsx
diff options
context:
space:
mode:
authorTyler Schicke <tyler_schicke@brown.edu>2019-03-16 20:38:24 -0400
committerTyler Schicke <tyler_schicke@brown.edu>2019-03-16 20:38:24 -0400
commit0a1b68e534aebf6f5fa6af31fd6a1e3d63f299d1 (patch)
treeebc5c1a5a5836f5dedf0ef01d690a8a98f3f726b /src/client/views/Main.tsx
parent914114aaffbbd492f68c5e580acf6a28f43dc2c7 (diff)
Added context menu option to copy document id
Added route to handle going to any doc id
Diffstat (limited to 'src/client/views/Main.tsx')
-rw-r--r--src/client/views/Main.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/Main.tsx b/src/client/views/Main.tsx
index 3a68b98ce..f938e83b9 100644
--- a/src/client/views/Main.tsx
+++ b/src/client/views/Main.tsx
@@ -41,8 +41,8 @@ document.addEventListener("pointerdown", action(function (e: PointerEvent) {
ContextMenu.Instance.clearItems()
}
}), true)
-
-const mainDocId = "mainDoc";
+const pathname = window.location.pathname.split("/");
+const mainDocId = pathname[pathname.length - 1];
let mainContainer: Document;
let mainfreeform: Document;