import React from "react"; import { View, Text, StyleSheet, TouchableOpacity, Image, Alert, Share, } from "react-native"; import { Ionicons } from "@expo/vector-icons"; import { useNavigation } from "@react-navigation/native"; import BottomNav from "../../Navigation/BottomNav"; const ProfilScreen = () => { const navigation = useNavigation(); const handleLogout = () => { Alert.alert("Konfirmasi", "Anda yakin ingin keluar?", [ { text: "Batal" }, { text: "Keluar", onPress: () => navigation.replace("AksesAkun") }, ]); }; const handleShare = async () => { try { await Share.share({ message: "Lihat aplikasi lingkungan ini!", }); } catch (error) { console.error("Error sharing: ", error); } }; return ( {/* Header dengan Foto Profil */} Hi Dina 👋 Terus jaga lingkungan sekitar agar tetap hijau dan asri! 🌱 {/* Info dan Motivasi */} PAHLAWAN LINGKUNGAN {/* Tombol dan Informasi */} { navigation.navigate("InformasiPribadiStackScreen", { screen: "InformasiPribadi", }); }} > Informasi Pribadi { navigation.navigate("StatusPenukaranKoinStackScreen", { screen: "StatusPengirimanScreen", }); }} > Status Penukaran Koin { navigation.navigate("StatusPengaduanStack", { screen: "StatusPengaduanStack", }); }} > Status Pengaduan { navigation.replace("DonasiStackScreen"); }} > Donasi Bagikan ke Media Sosial Keluar Akun {/* Bottom Navigation */} ); }; const styles = StyleSheet.create({ container: { flex: 1, backgroundColor: "#fff", padding: 20, }, profileImage: { width: 150, height: 150, borderRadius: 100, borderWidth: 5, borderColor: "#388e3c", marginBottom: 10, marginTop: 50, }, profileInfo: { flexDirection: "column", alignItems: "center", justifyContent: "center", }, profileName: { fontSize: 24, fontWeight: "bold", color: "#000", }, environmentStatus: { fontSize: 16, color: "#2e7d32", marginTop: 5, fontStyle: "italic", }, motivationSection: { marginTop: 10, backgroundColor: "#f0f0f0", padding: 10, borderRadius: 12, marginBottom: 10, marginRight: 100, marginLeft: 100, borderWidth: 0.5, }, motivationText: { fontSize: 15, color: "#000", textAlign: "center", fontWeight: "600", }, buttonContainer: { marginTop: 20, marginLeft: 10, }, button: { flexDirection: "row", alignItems: "center", paddingVertical: 12, borderBottomWidth: 1, borderBottomColor: "#ddd", }, buttonText: { marginLeft: 10, fontSize: 16, color: "#333", }, bottomNavContainer: { position: "absolute", bottom: 0, left: 0, right: 0, height: 60, flexDirection: "row", justifyContent: "space-around", backgroundColor: "#fff", paddingVertical: 8, borderTopLeftRadius: 20, borderTopRightRadius: 20, shadowColor: "#000", shadowOffset: { width: 0, height: -2 }, shadowOpacity: 0.1, shadowRadius: 6, elevation: 5, }, }); export default ProfilScreen;