aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/pdf/PDFViewer.tsx
diff options
context:
space:
mode:
authorSophie Zhang <sophie_zhang@brown.edu>2023-10-05 01:44:50 -0400
committerSophie Zhang <sophie_zhang@brown.edu>2023-10-05 01:44:50 -0400
commit981a38934236e1302d617422c01daa93eb449493 (patch)
tree304303d0c4267fed72e3311dad0d87b4a44fcccb /src/client/views/pdf/PDFViewer.tsx
parentf2958fd4d7dab5369c9e68c5d8f3b50332391aac (diff)
parentc9d83841221620137e89920198ffaeab2677b439 (diff)
Merge branch 'master' into sophie-ai-images
Diffstat (limited to 'src/client/views/pdf/PDFViewer.tsx')
-rw-r--r--src/client/views/pdf/PDFViewer.tsx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/client/views/pdf/PDFViewer.tsx b/src/client/views/pdf/PDFViewer.tsx
index 2a191477b..23dc084ad 100644
--- a/src/client/views/pdf/PDFViewer.tsx
+++ b/src/client/views/pdf/PDFViewer.tsx
@@ -82,9 +82,7 @@ export class PDFViewer extends React.Component<IViewerProps> {
private _ignoreScroll = false;
private _initialScroll: { loc: Opt<number>; easeFunc: 'linear' | 'ease' | undefined } | undefined;
private _forcedScroll = true;
- get _getAnchor() {
- return AnchorMenu.Instance?.GetAnchor;
- }
+ _getAnchor: (savedAnnotations: Opt<ObservableMap<number, HTMLDivElement[]>>, addAsAnnotation: boolean) => Opt<Doc> = () => undefined;
selectionText = () => this._selectionText;
selectionContent = () => this._selectionContent;
@@ -400,6 +398,7 @@ export class PDFViewer extends React.Component<IViewerProps> {
@action
finishMarquee = (x?: number, y?: number) => {
+ this._getAnchor = AnchorMenu.Instance?.GetAnchor;
this.isAnnotating = false;
this._marqueeing = undefined;
this._textSelecting = true;