V2.0.0 : VOICI LES MODIFICATIONS MAJEURS APPRTÉES DANS CETTE VERSION :

-> REFONTE DU DESIGN DES AFFICHEURS CLASSIQUES (GÉNÉRAL + QUAIS)
-> IMPLÉMENTATION DU DESIGN AFL : GÉNÉRAL ET QUAIS

-> CHOIX DE LA SÉLECTION DES TYPES D'AFFICHEURS (GÉNÉRAL / QUAIS) UNE FOIS LE TYPE D'AFFICHEUR SÉLECTIONNÉS

EN COURS DE DÉVELOPPEMENT :

-> IMPLÉMENTATION DES PERTURBATION DU LANDEMAIN POUR LES HORAIRES DU LANDEMAIN AFFICHÉS AVANT MINUIT.
-> IMPLÉMENTATION DES AFFICHEURS D'INFORMATIONS / INFOS TRAVAUX, etc... (AFFICHEURS AFL)
This commit is contained in:
Ferrovia committed 2026-06-14 22:02:08 +02:00
1 parent f0d9ed9ee7
commit f06ebbaf48
43 files changed
+10519 -3813

No files matched your search

+1 -6
View File
@@ -60,14 +60,9 @@ export default function Displays({ onBack, navigate }) {
<div style={{ display: 'flex', gap: 16, flexWrap: 'wrap', marginTop: 16 }}>
{types.map((t) => (
<div key={t.id} role="button" tabIndex={0} style={{ width: 220, padding: 16, borderRadius: 8, boxShadow: '0 2px 8px rgba(0,0,0,0.08)', background: '#fff', cursor: 'pointer' }} onClick={() => {
// Si un navigate est fourni par le routeur simple, on l'utilise
if (typeof navigate === 'function') {
// construire l'URL finale au format strict demandé :
// /afficheurs/{mode}/{type}?gare=<Nom-de-la-gare>
const kebab = gare ? String(gare).trim().replace(/\s+/g, '-').replace(/\//g, '/') : '';
const gareQuery = kebab ? `?gare=${encodeURIComponent(kebab)}` : '';
// Construire l'URL au format demandé : /afficheurs/{mode}/{type}?gare=...
navigate(`/afficheurs/${mode}/${t.id}${gareQuery}`);
navigate(`/select-afficheur?gare=${encodeURIComponent(kebab)}&mode=${mode}&type=${t.id}`);
return;
}
alert(`${t.label} pour ${gare || '—'}`);