From 1763ff090ea734ca275c3c28edc6c303c935b801 Mon Sep 17 00:00:00 2001
From: bobzel <zzzman@gmail.com>
Date: Wed, 25 Jan 2023 12:59:50 -0500
Subject: added a linkFollow o[ption to choose between opening target, or
 highest level collection containing target. fixed adding marker annotations
 to pdf/web/etc.  fixed following link to wikipedia pages to not create a new
 document each time.  made searchBox's search function static so that it can
 be called programmatically. Fixed LinkDocPreview to not flicker when doing a
 nopreview link follow.  changed PlayTrail to restore state of all freeform
 collections containing source anchor.

---
 src/client/views/MainView.tsx | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

(limited to 'src/client/views/MainView.tsx')

diff --git a/src/client/views/MainView.tsx b/src/client/views/MainView.tsx
index 839db5795..895ed9bda 100644
--- a/src/client/views/MainView.tsx
+++ b/src/client/views/MainView.tsx
@@ -948,6 +948,10 @@ export class MainView extends React.Component {
         );
     }
 
+    @computed get linkDocPreview() {
+        return LinkDocPreview.LinkInfo ? <LinkDocPreview {...LinkDocPreview.LinkInfo} /> : null;
+    }
+
     render() {
         return (
             <div
@@ -975,7 +979,7 @@ export class MainView extends React.Component {
                 {this._hideUI ? null : <TopBar />}
                 {LinkDescriptionPopup.descriptionPopup ? <LinkDescriptionPopup /> : null}
                 {DocumentLinksButton.LinkEditorDocView ? <LinkMenu clearLinkEditor={action(() => (DocumentLinksButton.LinkEditorDocView = undefined))} docView={DocumentLinksButton.LinkEditorDocView} /> : null}
-                {LinkDocPreview.LinkInfo ? <LinkDocPreview {...LinkDocPreview.LinkInfo} /> : null}
+                {this.linkDocPreview}
 
                 {((page: string) => {
                     // prettier-ignore
-- 
cgit v1.2.3-70-g09d2

