import React, { useState } from 'react'; import { View, Text, ScrollView, Pressable, StyleSheet, SafeAreaView } from 'react-native'; const ROUTINES = { AM: [ { step: 'Cleanser', note: 'Gentle gel', icon: '๐Ÿงด' }, { step: 'Vitamin C', note: '10% serum', icon: '๐ŸŠ' }, { step: 'Moisturizer', note: 'Lightweight', icon: '๐Ÿ’ง' }, { step: 'SPF 50', note: 'Always', icon: 'โ˜€๏ธ' }, ], PM: [ { step: 'Cleanser', note: 'Oil + gel', icon: '๐Ÿงผ' }, { step: 'Retinol', note: '0.3%', icon: '๐ŸŒ™' }, { step: 'Night cream', note: 'Rich', icon: '๐ŸŒฟ' }, ], }; export default function App() { const [tab, setTab] = useState('AM'); const [done, setDone] = useState>({}); const list = ROUTINES[tab]; return ( YOUR ROUTINE {['AM', 'PM'].map((t) => ( setTab(t)} style={[s.tab, tab === t && s.tabOn]}> {t === 'AM' ? 'โ˜€๏ธ Morning' : '๐ŸŒ™ Evening'} ))} {list.map((r, i) => { const key = tab + i; const on = done[key]; return ( setDone((d) => ({ ...d, [key]: !d[key] }))} style={s.row}> {i + 1} {r.icon} {r.step} {r.note} {on ? โœ“ : null} ); })} ); } const s = StyleSheet.create({ safe: { flex: 1, backgroundColor: '#140E11' }, scroll: { padding: 22, paddingTop: 60 }, kicker: { color: '#F5A3B8', fontSize: 12, fontWeight: '700', letterSpacing: 2, marginBottom: 16 }, tabs: { flexDirection: 'row', backgroundColor: '#1E141A', borderRadius: 16, padding: 5, marginBottom: 22 }, tab: { flex: 1, paddingVertical: 12, borderRadius: 12, alignItems: 'center' }, tabOn: { backgroundColor: '#F5A3B8' }, tabText: { color: '#B98DA0', fontSize: 15, fontWeight: '700' }, tabTextOn: { color: '#2A1620' }, row: { flexDirection: 'row', alignItems: 'center', backgroundColor: '#1A1117', borderRadius: 16, padding: 16, marginBottom: 12 }, num: { width: 26, height: 26, borderRadius: 13, backgroundColor: '#2A1B24', alignItems: 'center', justifyContent: 'center', marginRight: 12 }, numT: { color: '#F5A3B8', fontSize: 13, fontWeight: '800' }, rowIcon: { fontSize: 24, marginRight: 14 }, step: { color: '#F3E2E8', fontSize: 17, fontWeight: '600' }, stepDone: { color: '#7A6670', textDecorationLine: 'line-through' }, note: { color: '#A6889A', fontSize: 13, marginTop: 2 }, check: { width: 28, height: 28, borderRadius: 14, borderWidth: 2, borderColor: '#3A2A34', alignItems: 'center', justifyContent: 'center' }, checkOn: { backgroundColor: '#F5A3B8', borderColor: '#F5A3B8' }, checkM: { color: '#2A1620', fontWeight: '900' }, });