kiwix / kiwix-js-pwa

Kiwix JS Offline Browser implemented as a Progressive Web App (PWA), and packaged as Electron, NWJS and UWP apps for Windows and Linux.
https://pwa.kiwix.org
GNU General Public License v3.0
177 stars 29 forks source link

Fix zimit2 external links and PDFs #538

Closed Jaifroid closed 7 months ago

Jaifroid commented 7 months ago

Fixes second bullet point of #536.

Jaifroid commented 7 months ago

Tested (and working*) on the following zimit2 archives in ServiceWorker mode:

* There is a small issue with the currently loaded page in the iframe being blanked out if the user opens a link in a new tab. The link in the new tab works fine and is navigable, but the iframe is put out of commission by this (and it is hard to open the landing page in the iframe, it keeps redirecting to the tab). This needs investigating.

JQuery mode has odd effects on mes-quartiers-chinois: images are all detected as hidden by default, even though the UI option to hide images is not turned on. Also needs investigating. The same behaviour can be observed in 100rabbits_en_2024-01.zim and it will be easier to debug it in that ZIM. However, fixing JQuery mode should be a separate PR.

Jaifroid commented 7 months ago

I need to check the PDF code on a zimit2 with PDF files that can be opened in the ZIM.

Jaifroid commented 7 months ago

PDFs are working with zimit2 archives, but now this code breaks PDFs in classic zimit archives! 😡

Jaifroid commented 7 months ago

OK, fixed now... phew. That took a lot of hunting...