Admin backoffice : rubriques General/Evenement + videos situation + surprise + rembobinage ruban
- Reorganisation menu admin en 2 rubriques (General / Evenement) - Destinations deplace dans Evenement - Nouveau panneau Videos : upload par situation (montage, depannage, bourrage, rechargement) - Nouveau panneau Surprise : photo/video affichee ~1s avant capture pour provoquer sourire - Toggle rembobinage ruban Mitsubishi (StpiDecklist) pour economiser le ruban sur petits formats - Historique email cloisonne par evenement - Memoire projet consolidee dans memoire.md Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -9,6 +9,27 @@ let captureEnCours = false; // true pendant tout le flux lancerCapture()
|
||||
|
||||
const EMOJI_CAR = { 3: '🤪', 2: '😱', 1: '🔥' };
|
||||
|
||||
// --- Surprise avant capture ---
|
||||
|
||||
async function afficherSurprise() {
|
||||
const surprise = (config || {}).surprise;
|
||||
if (!surprise || !surprise.actif || !surprise.fichier) return;
|
||||
const delai = surprise.delai_ms || 1000;
|
||||
|
||||
const overlay = document.getElementById('surprise-overlay');
|
||||
if (!overlay) return;
|
||||
|
||||
if (surprise.type === 'video') {
|
||||
overlay.innerHTML = '<video src="/api/surprise/media" autoplay muted playsinline style="max-width:100%;max-height:100%;object-fit:contain"></video>';
|
||||
} else {
|
||||
overlay.innerHTML = '<img src="/api/surprise/media" style="max-width:100%;max-height:100%;object-fit:contain">';
|
||||
}
|
||||
overlay.classList.remove('cache');
|
||||
|
||||
await new Promise(r => setTimeout(r, delai));
|
||||
overlay.classList.add('cache');
|
||||
}
|
||||
|
||||
// --- Preview live ---
|
||||
|
||||
function afficherErreurCapture(titre, detail = '') {
|
||||
@@ -253,6 +274,9 @@ async function lancerCapture() {
|
||||
lancerPreview(); // Miroir live pendant le compte à rebours
|
||||
await compteARebours();
|
||||
|
||||
// Surprise : afficher media juste avant capture
|
||||
await afficherSurprise();
|
||||
|
||||
// Flash blanc immédiat + lancer capture en parallèle
|
||||
const flash = document.getElementById('flash-blanc');
|
||||
flash.classList.remove('cache');
|
||||
|
||||
Reference in New Issue
Block a user