diff options
author | bobzel <zzzman@gmail.com> | 2021-02-09 12:16:25 -0500 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2021-02-09 12:16:25 -0500 |
commit | 81bd2378ffa753e851390c2616e66a71d23c9989 (patch) | |
tree | e6b7c6cf1f1917144c813f0bbcccfab9f0757e6c /src/client/views/nodes/formattedText/FormattedTextBoxComment.tsx | |
parent | 0f03183b9a2374ed3198d2b9ec8348fa819b11b4 (diff) |
started to cleanup LinkDocPreview, LinkMenu.
Diffstat (limited to 'src/client/views/nodes/formattedText/FormattedTextBoxComment.tsx')
-rw-r--r-- | src/client/views/nodes/formattedText/FormattedTextBoxComment.tsx | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/client/views/nodes/formattedText/FormattedTextBoxComment.tsx b/src/client/views/nodes/formattedText/FormattedTextBoxComment.tsx index 05f0fefd8..d1bb2ad84 100644 --- a/src/client/views/nodes/formattedText/FormattedTextBoxComment.tsx +++ b/src/client/views/nodes/formattedText/FormattedTextBoxComment.tsx @@ -136,8 +136,6 @@ export class FormattedTextBoxComment { @undoBatch deleteLink = action(() => { FormattedTextBoxComment.linkDoc ? LinkManager.Instance.deleteLink(FormattedTextBoxComment.linkDoc) : null; - LinkDocPreview.LinkInfo = undefined; - DocumentLinksButton.EditLink = undefined; FormattedTextBoxComment.Hide(); }); @@ -158,6 +156,7 @@ export class FormattedTextBoxComment { FormattedTextBoxComment.tooltip && (FormattedTextBoxComment.tooltip.style.display = ""); } + @action static showCommentbox(set: string, view: EditorView, nbef: number) { const state = view.state; if (set !== "none") { @@ -171,6 +170,13 @@ export class FormattedTextBoxComment { const left = Math.max((start.left + end.left) / 2, start.left + 3); FormattedTextBoxComment.tooltip.style.left = (left - box.left) + "px"; FormattedTextBoxComment.tooltip.style.bottom = (box.bottom - start.top) + "px"; + // const props = FormattedTextBoxComment.textBox?.props.docViewPath.lastElement().props; + // props && (LinkDocPreview.SetLinkInfo({ + // docprops: props, + // linkSrc: props.Document, + // linkDoc: FormattedTextBoxComment.linkDoc, + // Location: [start.left, start.top + 25] + // }); } FormattedTextBoxComment.tooltip && (FormattedTextBoxComment.tooltip.style.display = set); } |