installTrigger déprécié

This commit is contained in:
2026-03-27 07:46:34 +01:00
parent 98b3ac7dd4
commit 2076034b37
3 changed files with 7 additions and 7 deletions

View File

@@ -16,7 +16,7 @@
<header> <header>
<div style="display: flex; gap: 10px; align-items: center;"> <div style="display: flex; gap: 10px; align-items: center;">
<button class="stop-all" onclick="stopAll()">🛑 STOP ALL</button> <button class="stop-all" onclick="stopAll()">🛑 STOP ALL</button>
<span id="app-version" style="color: #555; font-size: 0.8rem; margin-left: 10px;">v1.204</span> <span id="app-version" style="color: #555; font-size: 0.8rem; margin-left: 10px;">v1.205</span>
<button id="installBtn" style="display:none; ...">📥 INSTALLER</button> <button id="installBtn" style="display:none; ...">📥 INSTALLER</button>
</div> </div>

View File

@@ -4,7 +4,7 @@
let deferredPrompt; let deferredPrompt;
const installBtn = document.getElementById('installBtn'); const installBtn = document.getElementById('installBtn');
const isFirefox = typeof InstallTrigger !== 'undefined'; const isFirefox = navigator.userAgent.toLowerCase().includes('firefox');
window.addEventListener('beforeinstallprompt', (e) => { window.addEventListener('beforeinstallprompt', (e) => {
// Empêche Chrome d'afficher sa propre mini-barre // Empêche Chrome d'afficher sa propre mini-barre
@@ -29,11 +29,11 @@
}); });
if (isFirefox && !window.matchMedia('(display-mode: standalone)').matches) { if (isFirefox && !window.matchMedia('(display-mode: standalone)').matches) {
// On peut par exemple afficher un petit texte dans le header const infoZone = document.getElementById('app-version');
const infoZone = document.getElementById('app-version'); // On utilise la zone de version
if (infoZone) { if (infoZone) {
infoZone.innerHTML += " <br><small>(Install. non dispo sur Firefox PC)</small>"; // Message plus pro-actif pour l'utilisateur
infoZone.style.color = "#ff8800"; // Orange pour attirer l'oeil gentiment infoZone.innerHTML += " <br><small>(Utilisez 'Installer' dans le menu Firefox)</small>";
infoZone.style.color = "#ff8800";
} }
} }

View File

@@ -1,4 +1,4 @@
const CACHE_NAME = 'sb-v1.204'; // Change ce numéro pour forcer une mise à jour globale const CACHE_NAME = 'sb-v1.205'; // Change ce numéro pour forcer une mise à jour globale
const ASSETS = [ const ASSETS = [
'./', // Racine './', // Racine
'./index.html', './index.html',