web-library
web-library copied to clipboard
Add a warning in older browsers when trying to open attachment in a reader
While web library supports browsers as old as FF60 and Safari 11, Reader can really only support browsers that both, pdf.js and epub.js, support. Even in legacy
build pdf.js seems to depend on some relatively modern browser features and currently their target is Safari 16, though I believe Safari 15 will also work.
I've made an attempt to extend this compatibility but maintaining this is not feasible. I believe that instead we should just test for features that pdf.js requires (e.g. structuredClone
API seems to be a good candidate) and display an error message in browsers that lack this feature (currently we attempt to load pdf.js, which results in an error in the console and "forever" spinner in the UI).