// Screens 1-4: Home, Search/Browse, Product Detail, Prescription Upload // ═════════════════════════════════════════════════════════════ // 1) HOME // ═════════════════════════════════════════════════════════════ function ScreenHome() { const categories = [ { label: 'Medicines', hue: 'blue', Icon: IconPill }, { label: 'Wellness', hue: 'mint', Icon: IconHeart }, { label: 'Devices', hue: 'navy', Icon: IconShield }, { label: 'Lab tests', hue: 'amber', Icon: IconScan }, { label: 'Babycare', hue: 'rose', Icon: IconUser }, { label: 'Ayurveda', hue: 'mint', Icon: IconStar }, ]; const featured = [ { name: 'Dolo 650', sub: 'Paracetamol · Strip of 15', price: '32', mrp: '40', hue: 'blue', off: '20%' }, { name: 'Vitamin D3', sub: 'Cholecalciferol · 60K IU', price: '149', mrp: '189', hue: 'amber', off: '21%' }, { name: 'Pan-D', sub: 'Pantoprazole · 10 caps', price: '108', mrp: '128', hue: 'mint', off: '16%' }, ]; return (
{/* Hero banner */}
FIRST ORDER · USE JAN20
Flat 20% off,
plus free delivery
T&C apply
{categories.map((c) => (
{c.label}
))}
{featured.map((p, i) => (
-{p.off}
{p.name}
{p.sub}
₹{p.price} ₹{p.mrp}
))}
{[ { name: 'Cetirizine 10mg', sub: 'Last ordered 12 days ago · ×2', price: '24' }, { name: 'Vicks VapoRub 50g', sub: 'Last ordered 28 days ago · ×1', price: '145' }, ].map((p, i) => (
{p.name}
{p.sub}
))}
); } // ═════════════════════════════════════════════════════════════ // 2) SEARCH / BROWSE // ═════════════════════════════════════════════════════════════ function ScreenSearch() { const filters = ['All', 'Tablets', 'Syrups', 'Diabetes', 'Heart', 'Generics']; const products = [ { name: 'Crocin Advance', sub: 'Paracetamol 500mg · 15 tabs', price: '38', mrp: '45', hue: 'blue', stock: 'In stock', rx: false, rating: '4.7' }, { name: 'Metformin SR', sub: 'Glycomet · 500mg · 30 tabs', price: '78', mrp: '95', hue: 'mint', stock: 'In stock', rx: true, rating: '4.5' }, { name: 'Azithromycin', sub: 'Azithral 500 · 5 tabs', price: '92', mrp: '118', hue: 'amber', stock: 'Low stock', rx: true, rating: '4.6' }, { name: 'Calpol 250mg', sub: 'Susp · 60ml bottle', price: '52', mrp: '62', hue: 'rose', stock: 'In stock', rx: false, rating: '4.8' }, ]; return (
{/* Sticky search */}
paracetamol
{/* Filter chips */}
Filters
2
{filters.map((f, i) => (
{f}
))}
284 results · Sort: Relevance
{/* Product list */}
{products.map((p, i) => (
{p.name}
{p.sub}
{p.rx && ( Rx )} ● {p.stock} {p.rating}
₹{p.price} ₹{p.mrp}
))}
); } // ═════════════════════════════════════════════════════════════ // 3) PRODUCT DETAIL // ═════════════════════════════════════════════════════════════ function ScreenProduct() { return (
{/* Image area with overlay header */}
{/* Big pill graphic */}
{/* dot indicators */}
{[0,1,2,3].map(i => (
))}
{/* Title block */}
Prescription ● In stock
Metformin SR 500mg
Glycomet-SR · USV Ltd · Strip of 30 tablets
4.7 (2,341)
View alternates
{/* Price */}
₹78 ₹95 18% OFF
Inclusive of all taxes
{/* Stepper */}
2
{/* Delivery promise */}
Express delivery in 28 min
Free for orders above ₹199 · 560038
Change
{/* Composition table */}
Composition
METFORMIN HCL 500 mg
FORM Tablet (SR)
{/* Tabs */}
{['Uses', 'How to take', 'Side effects', 'FAQs'].map((t, i) => (
{t}
))}
Used to control high blood sugar in adults with type 2 diabetes. Works by reducing glucose production in the liver and improving insulin sensitivity. Often used alongside diet and exercise.
{/* Sticky CTA */}
); } // ═════════════════════════════════════════════════════════════ // 4) PRESCRIPTION UPLOAD // ═════════════════════════════════════════════════════════════ function ScreenRx() { return (
Upload prescription
Our pharmacist verifies in under 5 min
{/* Step indicator */}
{['Upload', 'Verify', 'Order'].map((s, i) => (
{i + 1}
{s}
{i < 2 &&
} ))}
{/* Drop zone */}
Drop your prescription here
JPG, PNG or PDF, up to 10MB.
Make sure all 4 corners are visible.
{/* Attached Rx */}
Dr_Mehta_Rx.jpg
1.8 MB · Uploaded just now
{/* Patient block */}
{[ { name: 'Aarav Kumar', sub: 'Self · 32 yrs · M', active: true }, { name: 'Meera Kumar', sub: 'Mother · 58 yrs · F', active: false }, { name: '+ Add family member', sub: '', active: false, add: true }, ].map((p, i) => (
{p.add ? : p.name.split(' ').map(s => s[0]).join('')}
{p.name}
{p.sub &&
{p.sub}
}
{p.active && (
)}
))}
{/* Note */}
Your prescription is end-to-end encrypted and shared only with our licensed pharmacist.
{/* CTA */}
); } Object.assign(window, { ScreenHome, ScreenSearch, ScreenProduct, ScreenRx });