Fix gitea env + proposer modal + favicon/nginx — 2026-01-31
All checks were successful
CI / build-and-anchors (push) Successful in 1m31s
SMOKE / smoke (push) Successful in 24s

This commit is contained in:
archicratia
2026-01-31 16:33:13 +00:00
parent 60d88939b0
commit 7f871ca46f
14 changed files with 37 additions and 31 deletions

View File

@@ -160,15 +160,8 @@
}
};
// ✅ Ouvre EN NOUVEL ONGLET sans jamais remplacer longlet courant
// ✅ Ouvre EN NOUVEL ONGLET : stratégie unique (anchor click) => jamais 2 onglets
const openInNewTab = (url) => {
// 1) tente window.open
try {
const w = window.open(url, "_blank", "noopener,noreferrer");
if (w) return true;
} catch {}
// 2) fallback "anchor click" (souvent mieux toléré)
try {
const a = document.createElement("a");
a.href = url;
@@ -181,7 +174,7 @@
return true;
} catch {}
// 3) dernier recours: on ne quitte PAS la page
// dernier recours
window.prompt("Popup bloquée. Copiez ce lien pour ouvrir le ticket :", url);
return false;
};
@@ -200,7 +193,7 @@
if (!a) return;
e.preventDefault();
e.stopPropagation();
e.stopImmediatePropagation();
const rawUrl = a.dataset.url || a.getAttribute("href") || "";
if (!rawUrl || rawUrl === "#") return;
@@ -210,10 +203,8 @@
try {
const u = new URL(rawUrl);
// Option B.1 : copie presse-papier du texte complet (si dispo)
if (full) {
try { await navigator.clipboard.writeText(full); } catch {}
// Option B.2 : upgrade du body (si l'URL reste raisonnable)
tryUpgradeBodyWithFull(u, full);
}
@@ -221,7 +212,7 @@
} catch {
openInNewTab(rawUrl);
}
});
}, { capture: true });
// Step 1: type
dlg.addEventListener("click", (e) => {