How to Handle Overlapped Annotations in JavaScript (ES5) PDF Viewer

17 Aug 20261 minute to read

Use the annotationCollection property of the annotationSelect event to get overlapped annotations when the user clicks an annotation.

The following example shows how to access overlapped annotations on click:

// Get overlapped annotation collections.
viewer.annotationSelect =(args) =>{
  console.log(args.annotationCollection);
}

Find the sample: Get overlapped annotations on click