diff --git a/src/app/screens/AccountScreen.js b/src/app/screens/AccountScreen.js
index 694c6d2..d98b64e 100644
--- a/src/app/screens/AccountScreen.js
+++ b/src/app/screens/AccountScreen.js
@@ -1,61 +1,122 @@
import React, { useContext } from "react";
-import { Text, Button, Image, View } from "react-native";
+import { Text, Button, Image, View, StyleSheet } from "react-native";
import Screen from "../components/Screen";
-import InDevelopment from "../components/InDevelopment";
import { AuthContext } from "../auth/context";
import authStorage from "../auth/storage";
import { TouchableOpacity } from "react-native-gesture-handler";
import assets from "../config/assets";
+import { MaterialCommunityIcons } from "@expo/vector-icons";
import { scaleDimsFromWidth, dimensions } from "../config/dimensions";
import colors from "../config/colors";
-
-
function handleLogOut(setUser) {
-
-
setUser(null);
authStorage.removeToken();
}
-function AccountScreen(props) {
- const { user, setUser } = useContext(AuthContext);
+function UserHeader({ name, fone }) {
+ return (
+
+
+
+ {name}
+ {fone}
+
+
+ );
+}
- const dims = scaleDimsFromWidth(93, 106, 35);
+function ProfileItensList({ icon, title, onPress }) {
+ return (
+
+
+
+
+
+ {title}
+
+
+
+ );
+}
+
+function AccountScreen(props) {
+ const { user, setUser } = useContext(AuthContext);
+ const profileItems = [
+ {
+ icon: "account",
+ title: "Editar Perfil",
+ onPress: () => {
+ console.log("1");
+ },
+ },
+ {
+ icon: "lock",
+ title: "Alterar senha",
+ onPress: () => {
+ console.log("2");
+ },
+ },
+ {
+ icon: "account",
+ title: "Cadastrar pluviômetro",
+ onPress: () => {
+ console.log("3");
+ },
+ },
+ {
+ icon: "account",
+ title: "ATIVAR INSTITUIÇÃO",
+ onPress: () => {
+ console.log("4");
+ },
+ },
+ {
+ icon: "information-outline",
+ title: "SOBRE O PROJETO",
+ onPress: () => {
+ console.log("5");
+ },
+ },
+ {
+ icon: "logout",
+ title: "sair",
+ onPress: () => {
+ handleLogOut(setUser);
+ },
+ },
+ {
+ icon: "trash-can",
+ title: "Desativar conta",
+ onPress: () => {
+ console.log("7");
+ },
+ },
+ ];
+ console.log("a");
return (
- {user.name}
- {user.email}
+
- {/* props.navigation.navigate("PluviometerRegister")}>
-
-
-
-
- Cadastrar Pluviômetro
-
-
-
- */}
+
+ {profileItems.map(({ icon, title, onPress }) => (
+
+ ))}
+
-
- {/* */}
);
}
+const styles = StyleSheet.create({
+ text: {
+ fontSize: 16,
+ },
+});
+
export default AccountScreen;