Annotations are not interactive on subsequent WebViewer initializations

WebViewer Version: 11.8, 11.9.0-20251116

Do you have an issue with a specific file(s)?

  • No
    Can you reproduce using one of our samples or online demos?
  • No
    Are you using the WebViewer server?
  • No
    Does the issue only happen on certain browsers?
  • No
    Is your issue related to a front-end framework?
  • Possibly; using Angular v20
    Is your issue related to annotations?
  • Yes

Please give a brief summary of your issue:
I have a component that contains my WebViewer instance. When that component is initialized the first time, everything works as expected. When I destroy that component and re-initialize it, the annotations that are created are not interactive. For example, I can create a highlight annotation and then when I click on it, the toolbar does not appear and I cannot resize or move it.

Refreshing the page allows it to work once, again.

Hello, I’m AiRon, an automated tech support bot :robot:
While you wait for one of our customer support representatives, I can help you with your question.


It seems like your issue may be related to the way the WebViewer instance is being re-initialized within your Angular component. When the component is destroyed and re-initialized, certain event listeners or states related to annotations might not be set up properly again.

Some things you can try:

  • Ensure that when you destroy the component, you are properly cleaning up the WebViewer instance by calling relevant cleanup methods.

  • When re-initializing, confirm that all necessary event listeners and configurations for annotations are being set up again.

  • Check if the annotation manager is properly re-initialized and if it retains its functions like enabling the annotation toolbar.

  • Investigate if the Angular lifecycle hooks are properly handling the WebViewer instance initialization and destruction.



Here are some resources that might help you:


Hopefully, this helps you solve your problem while you wait for a human to get back to you.

Hello @rsmith_elari,

Thank you for posting on our forum.

It looks like this question is a duplicate of the one you have posted to our Support Portal.

We have recently provided on the ticket, let us know if you have not received it.

In summary, the issue was raised to our backlog for further investigation. You can use the current workaround:

      instance.Core.documentViewer.addEventListener('click', (e) => {
        console.log('page clicked', e);
        const annots = instance.Core.annotationManager.getAnnotationsByMouseEvent(e, true);
        console.log('annots under mouse:', annots);
        instance.Core.annotationManager.selectAnnotations(annots);
      });

See the ticket on our Support Portal for more details. We will update this forum post as well once we have an update regarding the issue on the backlog. If you have any further questions, feel free to reach out on our Support Portal.

Best Regards,
Jacob Romano Carlsen
Web Development Support Engineer
Apryse Software Inc.

2 Likes