diff options
author | Sam Wilkins <samwilkins333@gmail.com> | 2019-08-04 03:33:00 -0400 |
---|---|---|
committer | Sam Wilkins <samwilkins333@gmail.com> | 2019-08-04 03:33:00 -0400 |
commit | 5a17fc9ff91e5a039a0ada4be498d8353ee94205 (patch) | |
tree | f35c1fa99217198523e446ca3732f5a93dbf982c /src/client/views/nodes/PDFBox.tsx | |
parent | 8d6620dd6818c82363ec0c4d49a92b0e2c0c1036 (diff) | |
parent | 02346eabdefd428ca23d6a3fbefdcd51ef62b738 (diff) |
merged with master
Diffstat (limited to 'src/client/views/nodes/PDFBox.tsx')
-rw-r--r-- | src/client/views/nodes/PDFBox.tsx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/client/views/nodes/PDFBox.tsx b/src/client/views/nodes/PDFBox.tsx index fa072aecf..a49709e83 100644 --- a/src/client/views/nodes/PDFBox.tsx +++ b/src/client/views/nodes/PDFBox.tsx @@ -152,9 +152,7 @@ export class PDFBox extends DocComponent<FieldViewProps, PdfDocument>(PdfDocumen } scrollTo(y: number) { - if (this._mainCont.current) { - this._mainCont.current.scrollTo({ top: Math.max(y - (this._mainCont.current!.offsetHeight / 2), 0), behavior: "auto" }); - } + this._mainCont.current && this._mainCont.current.scrollTo({ top: Math.max(y - (this._mainCont.current.offsetHeight / 2), 0), behavior: "auto" }); } settingsPanel() { |