diff --git a/backend/src/Controller/SpotScoreController.php b/backend/src/Controller/SpotScoreController.php index 334de45..d756fb2 100644 --- a/backend/src/Controller/SpotScoreController.php +++ b/backend/src/Controller/SpotScoreController.php @@ -312,8 +312,8 @@ class SpotScoreController extends AbstractController private function scoreToLevel(int $score): string { return match (true) { - $score <= 30 => 'low', - $score <= 70 => 'medium', + $score <= 15 => 'low', + $score <= 55 => 'medium', default => 'high', }; } diff --git a/backend/src/Service/Forecast/ImpactScoreService.php b/backend/src/Service/Forecast/ImpactScoreService.php index d26645b..a0c7b0b 100644 --- a/backend/src/Service/Forecast/ImpactScoreService.php +++ b/backend/src/Service/Forecast/ImpactScoreService.php @@ -29,8 +29,8 @@ class ImpactScoreService { private const MAX_DISTANCE_M = 50_000; // 50 km : au-delà score distance = 0 private const MAX_RELEVANT_M = 300_000; // 300 km : au-delà, on ne touche pas au score existant - private const MAX_DENSITY_KM2 = 100; // 100 km² = densité maximale - private const MAX_APPROACH_KMH = 5; // 5 km/h = vitesse d'approche max + private const MAX_DENSITY_KM2 = 20; // 20 km² = densité maximale pour l'échelle Guadeloupe + private const MAX_APPROACH_KMH = 1; // 1 km/h = vitesse réaliste max des sargasses private const CACHE_TTL = 10_800; // 3h private const ETA_BUFFER_M = 5_000; // 5 km : seuil "impact imminent" sur le spot @@ -38,7 +38,7 @@ class ImpactScoreService private const FEEDBACK_RADIUS_M = 20_000; private const FEEDBACK_WINDOW_H = 6; private const FEEDBACK_BONUS = 8; - private const HIGH_SCORE_THRESHOLD = 70; + private const HIGH_SCORE_THRESHOLD = 55; public function __construct( private Connection $connection, @@ -335,8 +335,8 @@ class ImpactScoreService private function scoreToLevel(int $score): string { return match (true) { - $score <= 30 => 'low', - $score <= 70 => 'medium', + $score <= 15 => 'low', + $score <= 55 => 'medium', default => 'high', }; } diff --git a/frontend/index.html b/frontend/index.html index ece42f3..dcece1f 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -2,9 +2,15 @@ - + + + - Radar Sargasses Caraïbes + + + + + Radar Sargasses 971 diff --git a/frontend/public/icon.svg b/frontend/public/icon.svg new file mode 100644 index 0000000..99aad2e --- /dev/null +++ b/frontend/public/icon.svg @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 971 + diff --git a/frontend/public/manifest.json b/frontend/public/manifest.json new file mode 100644 index 0000000..2c45676 --- /dev/null +++ b/frontend/public/manifest.json @@ -0,0 +1,29 @@ +{ + "name": "Radar Sargasses 971", + "short_name": "RS 971", + "description": "Surveillance satellite des sargasses en Guadeloupe", + "start_url": "/", + "scope": "/", + "display": "standalone", + "background_color": "#1a1a2e", + "theme_color": "#3ab5e6", + "orientation": "portrait", + "lang": "fr", + "icons": [ + { + "src": "/icon.svg", + "sizes": "any", + "type": "image/svg+xml", + "purpose": "any maskable" + } + ], + "screenshots": [ + { + "src": "/assets/logo-radarsargasses971.png", + "sizes": "512x512", + "type": "image/png", + "form_factor": "narrow", + "label": "Carte radar sargasses Guadeloupe" + } + ] +}