diff --git a/src/components/map/MapFilters.tsx b/src/components/map/MapFilters.tsx index 2c28a72..fb06744 100644 --- a/src/components/map/MapFilters.tsx +++ b/src/components/map/MapFilters.tsx @@ -11,6 +11,8 @@ interface MapFiltersProps { onToggleHotspots?: () => void; showHotspots?: boolean; isLoadingHotspots?: boolean; + onToggleEvents?: () => void; + showEvents?: boolean; } export function MapFilters({ @@ -23,6 +25,8 @@ export function MapFilters({ onToggleHotspots, showHotspots = false, isLoadingHotspots = false, + onToggleEvents, + showEvents = true, }: MapFiltersProps) { const [isExpanded, setIsExpanded] = useState(true); @@ -159,6 +163,30 @@ export function MapFilters({ + {/* Events Toggle */} + {onToggleEvents && ( +
${event.locationName}
-Participants: ${event.participantCount}
-Status: ${event.status}
++ 📍 + ${event.locationName} +
++ 📅 + ${scheduledDate} +
++ ⏱️ + ${event.duration} minutes +
++ 👥 + ${event.participantCount} participant${event.participantCount !== 1 ? 's' : ''} +
+ ${event.status === 'completed' && event.litterCollected ? ` ++ ♻️ + ${event.litterCollected} kg collected +
+ ` : ''} ++ + ${event.status.charAt(0).toUpperCase() + event.status.slice(1)} + +
+${event.description}
+ ` : ''}Loading reports...
++ Loading {isLoadingReports && isLoadingEvents ? 'map data' : isLoadingReports ? 'reports' : 'events'}... +