diff --git a/package.json b/package.json index 7eea991..f14220a 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "g1flux", "private": true, - "version": "1.3.2", + "version": "1.4.0", "type": "module", "scripts": { "dev": "vite", diff --git a/src/App.tsx b/src/App.tsx index 0f9d2a8..b92e8a2 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -131,6 +131,15 @@ export default function App() { )} + {/* Bouton info — sous ☰ sur mobile, top-left sur desktop */} + + {/* Period selector — floating over map */}
0 ? Math.round((visibleStats.geoCount / visibleStats.transactionCount) * 100) : null} - onInfo={() => setInfoOpen(true)} />
@@ -184,7 +192,6 @@ export default function App() { onPlay={animation.play} onPause={animation.pause} onSpeedChange={animation.setSpeed} - onClose={animation.deactivate} /> )} diff --git a/src/components/AnimationPlayer.tsx b/src/components/AnimationPlayer.tsx index cf993f0..e8ef05b 100644 --- a/src/components/AnimationPlayer.tsx +++ b/src/components/AnimationPlayer.tsx @@ -9,7 +9,6 @@ interface AnimationPlayerProps { onPlay: () => void; onPause: () => void; onSpeedChange: (s: 1 | 2 | 4) => void; - onClose: () => void; } export function AnimationPlayer({ @@ -21,7 +20,6 @@ export function AnimationPlayer({ onPlay, onPause, onSpeedChange, - onClose, }: AnimationPlayerProps) { const frame = frames[currentIndex]; @@ -78,8 +76,7 @@ export function AnimationPlayer({ {/* Speed selector */}
- Vitesse - {([1, 2, 4] as const).map((s) => ( +{([1, 2, 4] as const).map((s) => (
- {/* Close */} - diff --git a/src/components/FlowMap.tsx b/src/components/FlowMap.tsx index e78ae65..29e5289 100644 --- a/src/components/FlowMap.tsx +++ b/src/components/FlowMap.tsx @@ -17,7 +17,7 @@ function lerpColor(hex1: string, hex2: string, t: number): string { } const COLOR_NEUTRAL = '#d4a843'; // or Ğ1 -const COLOR_NEG = '#ff6d00'; // orange vif +const COLOR_NEG = '#e53935'; // rouge vif const COLOR_POS = '#00c853'; // vert vif const NEUTRAL_THRESHOLD = 0.05; // ±5 % → couleur neutre const CLUSTER_RADIUS = 38; // pixels — distance max pour regrouper deux villes diff --git a/src/components/InfoPanel.tsx b/src/components/InfoPanel.tsx index b0a4724..82563c5 100644 --- a/src/components/InfoPanel.tsx +++ b/src/components/InfoPanel.tsx @@ -54,8 +54,8 @@ export function InfoPanel({ onClose }: InfoPanelProps) { Vert = receveur net (reçoit plus que ce qu'il émet) ·{' '} - Or = équilibré ·{' '} - Orange = émetteur net. + Or = équilibré (dégradé or → vert selon l'excédent reçu) ·{' '} + Rouge = émetteur net (dégradé or → rouge selon l'excédent émis). Affiche la liste des villes du cluster avec leur balance individuelle, diff --git a/src/components/PeriodSelector.tsx b/src/components/PeriodSelector.tsx index 2ccb8ad..3fb7953 100644 --- a/src/components/PeriodSelector.tsx +++ b/src/components/PeriodSelector.tsx @@ -8,7 +8,6 @@ interface PeriodSelectorProps { viewMode: 'heatmap' | 'flow'; onViewModeChange: (mode: 'heatmap' | 'flow') => void; geoPercent?: number | null; - onInfo: () => void; } const PERIODS = [ @@ -19,7 +18,7 @@ const PERIODS = [ const PRESET_DAYS = new Set([1, 7, 30]); -export function PeriodSelector({ value, onChange, animationActive, onAnimate, viewMode, onViewModeChange, geoPercent, onInfo }: PeriodSelectorProps) { +export function PeriodSelector({ value, onChange, animationActive, onAnimate, viewMode, onViewModeChange, geoPercent }: PeriodSelectorProps) { const [customOpen, setCustomOpen] = useState(false); const [inputVal, setInputVal] = useState(''); const inputRef = useRef(null); @@ -132,15 +131,6 @@ export function PeriodSelector({ value, onChange, animationActive, onAnimate, vi )} -
- -
); }