aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/PDFBox.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2024-05-07 14:58:55 -0400
committerbobzel <zzzman@gmail.com>2024-05-07 14:58:55 -0400
commita61d794b7018f0ac9723ce2d3b93547ba11f444b (patch)
treebf34073d4d40aaa6d7c0b4d01eff73d966e68fe2 /src/client/views/nodes/PDFBox.tsx
parent2e27b90ded41146b249649b0b0c3267b46c68363 (diff)
parentb8907e69160d97d919fcd83eb86d60e3634205ca (diff)
Merge branch 'restoringEslint' into nathan-starter
Diffstat (limited to 'src/client/views/nodes/PDFBox.tsx')
-rw-r--r--src/client/views/nodes/PDFBox.tsx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/client/views/nodes/PDFBox.tsx b/src/client/views/nodes/PDFBox.tsx
index 1dc194c42..7a89b143b 100644
--- a/src/client/views/nodes/PDFBox.tsx
+++ b/src/client/views/nodes/PDFBox.tsx
@@ -328,8 +328,7 @@ export class PDFBox extends ViewBoxAnnotatableComponent<FieldViewProps>() {
setPdfViewer = (pdfViewer: PDFViewer) => {
this._pdfViewer = pdfViewer;
- const docView = this.DocumentView?.();
- if (this._initialScrollTarget && docView) {
+ if (this._initialScrollTarget) {
this.focus(this._initialScrollTarget, { instant: true });
this._initialScrollTarget = undefined;
}
@@ -559,7 +558,7 @@ export class PDFBox extends ViewBoxAnnotatableComponent<FieldViewProps>() {
removeDocument={this.removeDocument}
/>
) : (
- <div onPointerDown={e => setupMoveUpEvents(this, e, returnFalse, emptyFunction, () => DocumentView.SelectView(this.DocumentView?.()!, false), true)}>
+ <div onPointerDown={e => setupMoveUpEvents(this, e, returnFalse, emptyFunction, () => this._props.select(false), true)}>
<ComponentTag
// eslint-disable-next-line react/jsx-props-no-spreading
{...this._props}