@mytec: iter10.2 ready for testing

This commit is contained in:
2026-01-30 17:03:56 +02:00
parent 05d6b8f13c
commit 652b34571b
2 changed files with 25 additions and 25 deletions

View File

@@ -18,25 +18,25 @@ export function getSignalQuality(rsrp: number): SignalQuality {
return 'no-service';
}
// Warm color scheme: dark = weak, bright = strong
// Purple → Orange palette: dark purple = weak, bright orange = strong
export const SIGNAL_COLORS: Record<string, string> = {
excellent: '#ffeb3b', // Yellow (excellent)
good: '#ff9800', // Orange (strong)
fair: '#ff4444', // Bright red (fair)
poor: '#cc0000', // Red (weak)
weak: '#8b0000', // Dark red (very weak)
'no-service': '#3c1428', // Deep maroon (no coverage)
excellent: '#ffb74d', // Bright orange (excellent)
good: '#ff6f00', // Dark orange (strong)
fair: '#ff8a65', // Peach (fair)
poor: '#ab47bc', // Light purple (weak)
weak: '#7b1fa2', // Purple (very weak)
'no-service': '#4a148c', // Dark purple (no coverage)
} as const;
export function getRSRPColor(rsrp: number): string {
return SIGNAL_COLORS[getSignalQuality(rsrp)] ?? '#0d47a1';
return SIGNAL_COLORS[getSignalQuality(rsrp)] ?? '#1a0033';
}
export const RSRP_LEGEND = [
{ label: 'Excellent', range: '> -70 dBm', color: '#ffeb3b', description: 'Very strong signal', min: -70 },
{ label: 'Good', range: '-70 to -85 dBm', color: '#ff9800', description: 'Strong signal', min: -85 },
{ label: 'Fair', range: '-85 to -100 dBm', color: '#ff4444', description: 'Acceptable signal', min: -100 },
{ label: 'Poor', range: '-100 to -110 dBm', color: '#cc0000', description: 'Weak signal', min: -110 },
{ label: 'Weak', range: '-110 to -120 dBm', color: '#8b0000', description: 'Very weak signal', min: -120 },
{ label: 'No Service', range: '< -120 dBm', color: '#3c1428', description: 'No coverage', min: -140 },
{ label: 'Excellent', range: '> -70 dBm', color: '#ffb74d', description: 'Very strong signal', min: -70 },
{ label: 'Good', range: '-70 to -85 dBm', color: '#ff6f00', description: 'Strong signal', min: -85 },
{ label: 'Fair', range: '-85 to -100 dBm', color: '#ff8a65', description: 'Acceptable signal', min: -100 },
{ label: 'Poor', range: '-100 to -110 dBm', color: '#ab47bc', description: 'Weak signal', min: -110 },
{ label: 'Weak', range: '-110 to -120 dBm', color: '#7b1fa2', description: 'Very weak signal', min: -120 },
{ label: 'No Service', range: '< -120 dBm', color: '#1a0033', description: 'No coverage', min: -140 },
] as const;