From e11191876344b191c28a8cd6606df84e94f32104 Mon Sep 17 00:00:00 2001 From: anika-ahluwalia Date: Mon, 29 Jun 2020 18:09:26 -0500 Subject: preview fix --- src/client/views/linking/LinkMenuItem.tsx | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src') diff --git a/src/client/views/linking/LinkMenuItem.tsx b/src/client/views/linking/LinkMenuItem.tsx index e8db5aff8..d5d31d1ba 100644 --- a/src/client/views/linking/LinkMenuItem.tsx +++ b/src/client/views/linking/LinkMenuItem.tsx @@ -129,6 +129,7 @@ export class LinkMenuItem extends React.Component { @action onContextMenu = (e: React.MouseEvent) => { DocumentLinksButton.EditLink = undefined; + LinkDocPreview.LinkInfo = undefined; e.preventDefault(); ContextMenu.Instance.addItem({ description: "Follow Default Link", event: () => this.followDefault(), icon: "arrow-right" }); ContextMenu.Instance.displayMenu(e.clientX, e.clientY); @@ -137,6 +138,7 @@ export class LinkMenuItem extends React.Component { @action.bound async followDefault() { DocumentLinksButton.EditLink = undefined; + LinkDocPreview.LinkInfo = undefined; DocumentManager.Instance.FollowLink(this.props.linkDoc, this.props.sourceDoc, doc => this.props.addDocTab(doc, "onRight"), false); } @@ -144,6 +146,7 @@ export class LinkMenuItem extends React.Component { deleteLink = (): void => { LinkManager.Instance.deleteLink(this.props.linkDoc); //this.props.showLinks(); + LinkDocPreview.LinkInfo = undefined; DocumentLinksButton.EditLink = undefined; } -- cgit v1.2.3-70-g09d2