diff options
author | bobzel <zzzman@gmail.com> | 2020-10-10 17:56:34 -0400 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2020-10-10 17:56:34 -0400 |
commit | c03949832eaff9c29fe48f8ec702362810c7f3b6 (patch) | |
tree | 15a58250989dc7125314255ace2722dacb751df8 | |
parent | d123cac247bcc37aa00fe44a4933df86b71e93af (diff) |
fixed scrolling down to annotations that have no height (but really do -- eg pdf selections) to at least show 50 pixels.
-rw-r--r-- | src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx index 796765a8d..d48961849 100644 --- a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx +++ b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx @@ -896,7 +896,7 @@ export class CollectionFreeFormView extends CollectionSubView<PanZoomDocument, P const curScroll = NumCast(this.props.Document._scrollTop); let scrollTo = curScroll; if (curScroll + contextHgt < NumCast(doc.y)) { - scrollTo = NumCast(doc.y) + NumCast(doc._height) - contextHgt; + scrollTo = NumCast(doc.y) + Math.max(NumCast(doc._height), 50) - contextHgt; } else if (curScroll > NumCast(doc.y)) { scrollTo = NumCast(doc.y); } |