diff --git a/components/observatory/observatory-map.tsx b/components/observatory/observatory-map.tsx index 487ee70f..19ef4339 100644 --- a/components/observatory/observatory-map.tsx +++ b/components/observatory/observatory-map.tsx @@ -47,15 +47,15 @@ export function ObservatoryMap({ ctx.clearRect(0, 0, canvas.width, canvas.height); // Draw world map background (simplified) - ctx.fillStyle = '#e0e0e0'; + ctx.fillStyle = '#f5f5f5'; ctx.fillRect(0, 0, canvas.width, canvas.height); // Draw grid lines for better visualization - ctx.strokeStyle = '#ffffff'; - ctx.lineWidth = 0.5; + ctx.strokeStyle = '#e5e5e5'; + ctx.lineWidth = 1; // Horizontal grid lines - for (let y = 0; y < canvas.height; y += 30) { + for (let y = 0; y < canvas.height; y += 40) { ctx.beginPath(); ctx.moveTo(0, y); ctx.lineTo(canvas.width, y); @@ -63,7 +63,7 @@ export function ObservatoryMap({ } // Vertical grid lines - for (let x = 0; x < canvas.width; x += 30) { + for (let x = 0; x < canvas.width; x += 40) { ctx.beginPath(); ctx.moveTo(x, 0); ctx.lineTo(x, canvas.height); @@ -73,26 +73,30 @@ export function ObservatoryMap({ // Draw country markers (in random positions) countries.forEach((country, index) => { // Generate random positions (in a real app, we would use actual coordinates) - const x = (index * 50 + 100) % (canvas.width - 50); - const y = 50 + Math.floor(index / 5) * 50; + const x = (index * 60 + 100) % (canvas.width - 80); + const y = 60 + Math.floor(index / 4) * 70; // Draw marker ctx.beginPath(); - ctx.arc(x, y, country.count > 5 ? 10 : (country.count > 2 ? 7 : 5), 0, Math.PI * 2); + ctx.arc(x, y, country.count > 5 ? 8 : (country.count > 2 ? 6 : 4), 0, Math.PI * 2); // Highlight selected country if (selectedCountry === country.name) { ctx.fillStyle = '#3b82f6'; + ctx.strokeStyle = '#2563eb'; } else { - ctx.fillStyle = '#ef4444'; + ctx.fillStyle = '#f87171'; + ctx.strokeStyle = '#ef4444'; } ctx.fill(); + ctx.lineWidth = 1; + ctx.stroke(); // Draw country name - ctx.fillStyle = '#000000'; - ctx.font = '12px Arial'; - ctx.fillText(country.name, x + 12, y + 4); + ctx.fillStyle = '#374151'; + ctx.font = '12px Inter, system-ui, sans-serif'; + ctx.fillText(country.name, x + 14, y + 4); // Store coordinates for click detection country.x = x; @@ -130,14 +134,14 @@ export function ObservatoryMap({ }, [countries, selectedCountry, onCountrySelect]); return ( -
No countries detected in the news
+No countries detected in the news
No news available
- ) : ( - filteredNews.map(item => ( + {/* Main Content */} +No news available
+ ) : ( +- {item.description} -
++ {item.description} +
No countries detected
- ) : ( -No countries detected
+ ) : ( +