How aditya-raj52/medvani works
MedVani is an offline-first emergency-response web app for first responders. Users select a capability from the navigation: hear Hindi first-aid instructions, create and save a medical ID with a QR code, scan medicine packaging or prescriptions and review saved results, or find hospitals and dial helplines. A separate SOS flow launches calling or messaging actions. The source excerpts establish component dispatch and the main data/service calls; unsampled navigation and modal internals are represented only where App.jsx shows their role.
Main entry points: App.jsx Application shell · MedicalIDForm.jsx Medical ID form · MedicineScanner.jsx Prescription scanner · EmergencyVoicePlayer.jsx First-aid voice player
Components 18
App shell
- Application shell
src/App.jsx - Navigation
src/components/Navbar.jsx - Overview modal
src/components/SupervisorPitchModal.jsx - Quick SOS dialing
src/App.jsx
Emergency guidance
- First-aid voice player
src/components/EmergencyVoicePlayer.jsx - Emergency procedures
src/config/emergencyConfig.js - Speech synthesis
src/services/speechService.js - Emergency helplines
src/config/emergencyConfig.js
Medical profile
- Medical ID form
src/components/MedicalIDForm.jsx - Local profile store
src/db/schema.js - QR SVG generator
src/utils/qrCode.js
Medicine scanning
- Prescription scanner
src/components/MedicineScanner.jsx - OCR and text parser
src/services/ocrService.js - Saved scan store
src/db/schema.js
Emergency directory
- Hospital directory
src/components/HospitalDirectory.jsx - Hospital listings
src/config/emergencyConfig.js
Other components
- First responder
- Phone, SMS, WhatsApp, Maps
Connections 25
- First responder → Application shell: opens
- Application shell → Navigation: renders
src/App.jsx - Application shell → First-aid voice player: selects tab
src/App.jsx - Application shell → Medical ID form: selects tab
src/App.jsx - Application shell → Prescription scanner: selects tab
src/App.jsx - Application shell → Hospital directory: selects tab
src/App.jsx - Navigation → Application shell: opens SOS or overview
src/App.jsx - Application shell → Overview modal: renders
src/App.jsx - Application shell → Quick SOS dialing: renders
src/App.jsx - Quick SOS dialing → Phone, SMS, WhatsApp, Maps: dials numbers
src/App.jsx - First-aid voice player → Emergency procedures: reads guidance
src/components/EmergencyVoicePlayer.jsx - First-aid voice player → Speech synthesis: requests speech
src/components/EmergencyVoicePlayer.jsx - Speech synthesis → Emergency procedures: reads defaults
src/services/speechService.js - First-aid voice player → Emergency helplines: reads numbers
src/components/EmergencyVoicePlayer.jsx - Medical ID form → Local profile store: loads and saves
src/components/MedicalIDForm.jsx - Medical ID form → QR SVG generator: generates code
src/components/MedicalIDForm.jsx - Medical ID form → Emergency procedures: reads profile options
src/components/MedicalIDForm.jsx - Medical ID form → Phone, SMS, WhatsApp, Maps: shares SOS
src/components/MedicalIDForm.jsx - Prescription scanner → OCR and text parser: processes prescription
src/components/MedicineScanner.jsx - Prescription scanner → Saved scan store: loads and saves scans
src/components/MedicineScanner.jsx - Prescription scanner → Speech synthesis: requests readout
src/components/MedicineScanner.jsx - Prescription scanner → OCR and text parser: uses sample presets
src/components/MedicineScanner.jsx - Hospital directory → Hospital listings: reads listings
src/components/HospitalDirectory.jsx - Hospital directory → Emergency helplines: reads numbers
src/components/HospitalDirectory.jsx - Hospital directory → Phone, SMS, WhatsApp, Maps: dials or maps
src/components/HospitalDirectory.jsx