Correction PDF
This commit is contained in:
@@ -33,13 +33,6 @@
|
||||
const normalize = (s) => (s ?? "").toString().trim().toLowerCase();
|
||||
const proxify = (url) => url ? `/HelloFresh/ProxyPdf?url=${encodeURIComponent(url)}` : "";
|
||||
|
||||
// Détection iOS (iPhone/iPad et iPadOS mode desktop)
|
||||
const IS_IOS = /iPad|iPhone|iPod/.test(navigator.userAgent) || (navigator.userAgent.includes("Mac") && "ontouchend" in document);
|
||||
els.btnOpen?.addEventListener("click", () => {
|
||||
const r = RECIPES[CUR]; if (!r?.pdf) return;
|
||||
const u = `/HelloFresh/ProxyPdf?url=${encodeURIComponent(r.pdf)}`;
|
||||
if (IS_IOS) window.open(u, "_blank", "noopener"); else openViewer();
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user