How sriram-731/pedal-pulse works
Pedal Pulse is a mobile cycling app for account-based ride planning and tracking, rider groups, community events, messaging, and safety alerts. The main workflow initializes a Supabase-backed session, routes authenticated riders into the app, and lets them join groups, share ride locations, and use map and ride features; community, chat, activity, profile, and notification features are parallel branches. The graph reflects documented imports and sampled calls; unsampled screens are represented by their exact tree paths, with uncertain connections omitted.
Main entry points: AppNavigator.tsx Navigation · supabase.ts Supabase client · App.tsx App bootstrap · MapScreen.tsx Ride map
Components 22
App and identity
- App bootstrap
pedal-pulse-master/App.tsx - Navigation
pedal-pulse-master/src/navigation/AppNavigator.tsx - Session and profile
pedal-pulse-master/src/store/useAuthStore.ts - Supabase client
pedal-pulse-master/src/config/supabase.ts - Rider dashboard
pedal-pulse-master/src/screens/dashboard/DashboardScreen.tsx
Rides and safety
- Ride groups
pedal-pulse-master/src/store/useGroupStore.ts - Group screens
pedal-pulse-master/src/screens/ride/RideGroupsScreen.tsx - Ride details
pedal-pulse-master/src/screens/ride/RideDetailScreen.tsx - Ride map
pedal-pulse-master/src/screens/map/MapScreen.tsx - Live group locations
pedal-pulse-master/src/hooks/useGroupLocationSync.ts - Accident detection
pedal-pulse-master/src/hooks/useAccidentDetection.ts - Emergency overlay
pedal-pulse-master/src/components/safety/EmergencyOverlay.tsx
Community and chat
- Community screens
pedal-pulse-master/src/screens/community/CommunityListScreen.tsx - Community state
pedal-pulse-master/src/store/useCommunityStore.ts - Community events
pedal-pulse-master/src/screens/community/EventListScreen.tsx - Chat screens
pedal-pulse-master/src/screens/chat/ChatRoomScreen.tsx - Message handling
pedal-pulse-master/src/hooks/useMessages.ts
Activities and alerts
- Daily activities
pedal-pulse-master/src/screens/activity/DailyActivitiesScreen.tsx - Notification state
pedal-pulse-master/src/store/useNotificationStore.ts - Notification display
pedal-pulse-master/src/screens/notifications/NotificationsScreen.tsx
Other components
- Rider
- Emergency SMS service
pedal-pulse-master/supabase/functions/send-emergency-sms/index.ts
Connections 33
- Rider → App bootstrap: opens
- App bootstrap → Supabase client: initializes
pedal-pulse-master/App.tsx - App bootstrap → Session and profile: sets session
pedal-pulse-master/App.tsx - App bootstrap → Navigation: renders
pedal-pulse-master/App.tsx - Navigation → Session and profile: reads session
pedal-pulse-master/src/navigation/AppNavigator.tsx - Navigation → Rider dashboard: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Session and profile → Supabase client: fetches profile
pedal-pulse-master/src/store/useAuthStore.ts - Navigation → Notification state: starts listener
pedal-pulse-master/src/navigation/AppNavigator.tsx - Rider dashboard → Supabase client: reads data
pedal-pulse-master/src/screens/dashboard/DashboardScreen.tsx - Navigation → Group screens: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Group screens → Ride groups: uses group state
pedal-pulse-master/src/screens/ride/RideGroupsScreen.tsx - Ride groups → Supabase client: manages groups
pedal-pulse-master/src/store/useGroupStore.ts - Navigation → Ride details: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Ride details → Supabase client: loads ride data
pedal-pulse-master/src/screens/ride/RideDetailScreen.tsx - Navigation → Ride map: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Ride map → Live group locations: tracks group
pedal-pulse-master/src/screens/map/MapScreen.tsx - Live group locations → Supabase client: syncs locations
pedal-pulse-master/src/hooks/useGroupLocationSync.ts - Ride map → Accident detection: checks accidents
pedal-pulse-master/src/screens/map/MapScreen.tsx - Ride map → Emergency overlay: shows overlay
pedal-pulse-master/src/screens/map/MapScreen.tsx - Navigation → Community screens: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Community screens → Community state: uses community state
- Community state → Supabase client: loads membership
pedal-pulse-master/src/store/useCommunityStore.ts - Navigation → Community events: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Community events → Supabase client: loads events
pedal-pulse-master/src/screens/community/EventListScreen.tsx - Navigation → Chat screens: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Chat screens → Message handling: uses message hook
- Message handling → Supabase client: reads and writes
pedal-pulse-master/src/hooks/useMessages.ts - Navigation → Daily activities: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Daily activities → Supabase client: loads activities
pedal-pulse-master/src/screens/activity/DailyActivitiesScreen.tsx - Notification state → Supabase client: syncs alerts
pedal-pulse-master/src/store/useNotificationStore.ts - Navigation → Notification display: routes to
pedal-pulse-master/src/navigation/AppNavigator.tsx - Notification display → Notification state: uses alert state
pedal-pulse-master/src/screens/notifications/NotificationsScreen.tsx - Emergency overlay → Emergency SMS service: may dispatch