How piyush0108maurya/ecosense works
EcoSense is an environmental-awareness and community-action web app. Users enter through the landing page, authenticate, then navigate air-quality monitoring, waste guidance, community waste reporting, and a dashboard; activity can earn points and streaks. The graph includes documented AI chat and gamification capabilities. Source excerpts are partial, so unsampled module details and relationships are omitted unless supported by the SOURCE INDEX.
Main entry points: App.jsx App shell · firebase.js Firebase services · gamification.js Rewards engine · Landing.jsx Landing page
Components 20
App experience
- App shell
src/App.jsx - Landing page
src/components/Landing/Landing.jsx - Side navigation
src/components/common/SideNav.jsx - Impact dashboard
src/components/Tabs/DashboardTab.jsx - Brand mark
src/components/common/Logo.jsx
Environmental tools
- Air quality monitor
src/components/Tabs/AQI.jsx - Waste guide
src/components/Tabs/WasteGuide.jsx - Collector registry
src/services/collectors.js
Community action
- Community waste map
src/components/Tabs/NeighbourWaste.jsx
Identity and state
- Sign-in screen
src/components/UI/AuthScreen.jsx - Firebase services
src/services/firebase.js - Local user cache
src/services/db.js
AI and rewards
- AQI and Gemini API
src/services/api.js - Lumi chat
src/components/Tabs/LumiChat.jsx - Lumi spirit
src/components/common/LumiSpirit.jsx - Rewards engine
src/services/gamification.js - Achievement display
src/components/UI/Achievement.jsx - Points progress
src/components/common/PointsProgress.jsx
Other components
- Visitor
- Firestore
Connections 24
- Visitor → Landing page: opens
src/components/Landing/Landing.jsx - Landing page → App shell: starts
src/components/Landing/Landing.jsx - App shell → Sign-in screen: renders
src/App.jsx - Sign-in screen → Firebase services: authenticates
src/components/UI/AuthScreen.jsx - App shell → Firebase services: loads account
src/App.jsx - Firebase services → Firestore: reads and writes
src/services/firebase.js - App shell → Local user cache: caches user
src/App.jsx - App shell → Side navigation: renders
src/App.jsx - App shell → Air quality monitor: routes to
src/App.jsx - Air quality monitor → AQI and Gemini API: fetches AQI
src/components/Tabs/AQI.jsx - App shell → Waste guide: routes to
src/App.jsx - Waste guide → Collector registry: finds collectors
src/components/Tabs/WasteGuide.jsx - Waste guide → Local user cache: uses cache
src/components/Tabs/WasteGuide.jsx - App shell → Community waste map: routes to
src/App.jsx - Community waste map → Firebase services: loads and adds pins
src/components/Tabs/NeighbourWaste.jsx - App shell → Impact dashboard: routes to
src/App.jsx - Impact dashboard → Rewards engine: reads reward logic
src/components/Tabs/DashboardTab.jsx - Lumi chat → AQI and Gemini API: requests responses
src/components/Tabs/LumiChat.jsx - Lumi spirit → AQI and Gemini API: requests responses
src/components/common/LumiSpirit.jsx - Local user cache → Rewards engine: calculates activity
src/services/db.js - Firebase services → Rewards engine: calculates rewards
src/services/firebase.js - Points progress → Rewards engine: shows progress
src/components/common/PointsProgress.jsx - Landing page → Brand mark: renders
src/components/Landing/Landing.jsx - Side navigation → Brand mark: renders
src/components/common/SideNav.jsx