aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/formattedText/FormattedTextBox.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2023-02-28 20:57:01 -0500
committerbobzel <zzzman@gmail.com>2023-02-28 20:57:01 -0500
commit5e7989da274606638c96f649e97e9d1a979956f5 (patch)
tree80a10b9a47e9874c3ec8dacdc26210836bbe3fe8 /src/client/views/nodes/formattedText/FormattedTextBox.tsx
parentf1dea8f31886c1e5e3d8bb772434009803b8fb8a (diff)
cleaning up of following inPlace links to overlay current inplaceContainer contents instead of deleting them.
Diffstat (limited to 'src/client/views/nodes/formattedText/FormattedTextBox.tsx')
-rw-r--r--src/client/views/nodes/formattedText/FormattedTextBox.tsx8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/client/views/nodes/formattedText/FormattedTextBox.tsx b/src/client/views/nodes/formattedText/FormattedTextBox.tsx
index 123499647..dc7a11e6e 100644
--- a/src/client/views/nodes/formattedText/FormattedTextBox.tsx
+++ b/src/client/views/nodes/formattedText/FormattedTextBox.tsx
@@ -230,6 +230,14 @@ export class FormattedTextBox extends ViewBoxAnnotatableComponent<FieldViewProps
}
}
+ sidebarAddDocTab = (doc: Doc, where: OpenWhere) => {
+ if (DocListCast(this.props.Document[this.props.fieldKey + '-sidebar']).includes(doc) && !this.SidebarShown) {
+ this.toggleSidebar(false);
+ return true;
+ }
+ return this.props.addDocTab(doc, where);
+ };
+
getAnchor = (addAsAnnotation: boolean, pinProps?: PinProps) => {
if (!pinProps) return this.rootDoc;
const anchor = Docs.Create.TextanchorDocument({ annotationOn: this.rootDoc, unrendered: true });