instructure / pdf-annotate.js

Annotation layer for pdf.js (no longer maintained)
http://instructure.github.io/pdf-annotate.js/
MIT License
545 stars 277 forks source link

PDF Annotate not work more in iOS 12 #83

Closed rogercorrea closed 5 years ago

rogercorrea commented 6 years ago

Please,

My PDF Annotation not work in iOS 12. Anyone help me about it? I did see that exist a problem in new WebKit version that cause canvas memory overflow. The highlighting resource is OK but text annotation not.

https://stackoverflow.com/questions/52532614/total-canvas-memory-use-exceeds-the-maximum-limit-safari-12

But I couldn't implement here. Has anyone got it about the problem?

rogercorrea commented 5 years ago

To fix it, I changed the closeInput function in index.js:

function closeInput() { //if (input) { try{ input.removeEventListener('blur', handleInputBlur); input.removeEventListener('keyup', handleInputKeyup); document.body.removeChild(input); input = null; } catch{} //} }/**

But I couldn't work with a coordinates that are wrong. In iPhone, annotations are go to another position. The "clientX" coordinate is not work.

rogercorrea commented 5 years ago

I fixed problems and create a new fork with pull request #85 .