Browse Source

Adding app logo title in LoginScreen and splash screen

master
GabrielTrettel 3 years ago
parent
commit
7a03a58e3c
  1. BIN
      src/app/assets/icons/splash.png
  2. 2
      src/app/config/assets.js
  3. 13
      src/app/screens/LoginScreen.js

BIN
src/app/assets/icons/splash.png

Before

Width: 1284  |  Height: 2778  |  Size: 124 KiB

After

Width: 1284  |  Height: 2778  |  Size: 115 KiB

2
src/app/config/assets.js

@ -6,7 +6,7 @@ import SusceptibilityAreas from "../assets/dataMenu/suceptibilitiesAreas.svg";
import RainIcon from "../assets/rain/rain-icon.svg"; import RainIcon from "../assets/rain/rain-icon.svg";
import RiverIcon from "../assets/river/river-logo.svg"; import RiverIcon from "../assets/river/river-logo.svg";
import FloodZones from "../assets/floodZonesAssets/floodZones-logo.svg"; import FloodZones from "../assets/floodZonesAssets/floodZones-logo.svg";
import AppLogoTitle from "../assets/icons/logo_title.svg";
import AppLogoTitle from "../assets/icons/LogoDados1.svg";
import RiverFlood from "../assets/river/river_extravasado.svg"; import RiverFlood from "../assets/river/river_extravasado.svg";
import RiverLow from "../assets/river/river_low.svg"; import RiverLow from "../assets/river/river_low.svg";

13
src/app/screens/LoginScreen.js

@ -16,7 +16,7 @@ import authStorage from "../auth/storage";
import assets from "../config/assets"; import assets from "../config/assets";
import Button from "../components/Button"; import Button from "../components/Button";
import { TouchableNativeFeedback } from "react-native-gesture-handler"; import { TouchableNativeFeedback } from "react-native-gesture-handler";
import {login, userPersonalData} from "../api/auth";
import { login, userPersonalData } from "../api/auth";
const phoneRegex = RegExp( const phoneRegex = RegExp(
/^\(?[\(]?([0-9]{2})?\)?[)\b]?([0-9]{4,5})[-. ]?([0-9]{4})$/ /^\(?[\(]?([0-9]{2})?\)?[)\b]?([0-9]{4,5})[-. ]?([0-9]{4})$/
@ -85,7 +85,6 @@ export default function LoginScreen(props) {
setLoginFailed(false); setLoginFailed(false);
const user = await userPersonalData(); const user = await userPersonalData();
user.ok && authContext.setUser(user.data); user.ok && authContext.setUser(user.data);
}; };
const [loginFailed, setLoginFailed] = useState(false); const [loginFailed, setLoginFailed] = useState(false);
@ -102,14 +101,20 @@ export default function LoginScreen(props) {
} }
> >
<View paddingHorizontal={14}> <View paddingHorizontal={14}>
<Text style={styles.txtHeader}>Dados à Prova d'água</Text>
<assets.AppLogoTitle
preserveAspectRatio="xMidYMid meet"
width={263}
height={200}
alignSelf="center"
marginBottom={dimensions.spacing.big_padding}
/>
<ErrorMessage <ErrorMessage
error="Email ou senha inválidos" error="Email ou senha inválidos"
visible={loginFailed} visible={loginFailed}
/> />
<View style={{ paddingVertical: 24 }}>
<View style={{ paddingBottom: 24 }}>
<FormField <FormField
maxLength={12} maxLength={12}
name="name" name="name"

Loading…
Cancel
Save