loginScreen enhanced created esstylesheet removed other styles

This commit is contained in:
ue 2018-09-25 23:05:39 +03:00
parent 3f38121f23
commit 1031c59020
6 changed files with 105 additions and 66 deletions

View File

@ -0,0 +1,40 @@
import React, { Component } from "react";
import { connect } from "react-redux";
// Services and Actions
// Middleware
// Constants
// Utilities
// Component
import { LoginScreen } from "../";
/*
* Props Name Description Value
*@props --> props name here description here Value Type Here
*
*/
class LoginContainer extends Component {
constructor(props) {
super(props);
this.state = {};
}
// Component Life Cycle Functions
// Component Functions
render() {
return <LoginScreen {...this.props} />;
}
}
const mapStateToProps = state => ({
account: state.accounts,
});
export default connect(mapStateToProps)(LoginContainer);

View File

@ -0,0 +1,5 @@
import LoginScreen from "./screen/loginScreen";
import Login from "./container/loginContainer";
export { LoginScreen, Login };
export default Login;

View File

@ -3,9 +3,7 @@ import {
View,
ActivityIndicator,
Text,
StyleSheet,
Image,
Dimensions,
TouchableOpacity,
TextInput,
BackHandler,
@ -13,21 +11,22 @@ import {
} from "react-native";
import { Navigation } from "react-native-navigation";
import { connect } from "react-redux";
import Ionicons from "react-native-vector-icons/Ionicons";
import FastImage from "react-native-fast-image";
import Tabs from "../home/customTab";
import Tabs from "../../home/customTab";
import ScrollableTabView from "@esteemapp/react-native-scrollable-tab-view";
import { Login } from "../../providers/steem/auth";
import { Login } from "../../../providers/steem/auth";
import { addNewAccount } from "../../redux/actions/accountAction";
import { addNewAccount } from "../../../redux/actions/accountAction";
import { default as INITIAL } from "../../constants/initial";
import { lookupAccounts } from "../../providers/steem/dsteem";
import { goToAuthScreens } from "../../navigation";
import { lookupAccounts } from "../../../providers/steem/dsteem";
import { goToAuthScreens } from "../../../navigation";
class LoginPage extends Component {
// Styles
import styles from "./loginStyles";
class LoginScreen extends Component {
static get options() {
return {
_statusBar: {
@ -466,7 +465,7 @@ class LoginPage extends Component {
left: 55,
top: 10,
}}
source={require("../../assets/love_mascot.png")}
source={require("../../../assets/love_mascot.png")}
/>
</View>
</View>
@ -551,52 +550,5 @@ class LoginPage extends Component {
);
}
}
const styles = StyleSheet.create({
container: {
margin: 0,
padding: 0,
backgroundColor: "#f1f1f1",
flexDirection: "column",
},
header: {
flexDirection: "row",
padding: 0,
backgroundColor: "white",
marginBottom: 10,
height: 200,
flex: 0.4,
},
footer: {
flex: 0.2,
bottom: 0,
marginTop: 10,
height: 80,
backgroundColor: "white",
flexDirection: "row",
},
tabView: {
alignSelf: "center",
backgroundColor: "transparent",
},
tabbar: {
alignSelf: "center",
height: 40,
backgroundColor: "white",
},
tabbarItem: {
flex: 1,
backgroundColor: "#ffffff",
minWidth: Dimensions.get("window").width / 1,
},
steemConnectTab: {
flex: 1,
backgroundColor: "#e9e9e9",
minWidth: Dimensions.get("window").width / 1,
},
});
const mapStateToProps = state => ({
account: state.accounts,
});
export default connect(mapStateToProps)(LoginPage);
export default LoginScreen;

View File

@ -0,0 +1,45 @@
import EStyleSheet from "react-native-extended-stylesheet";
export default EStyleSheet.create({
container: {
margin: 0,
padding: 0,
backgroundColor: "#f1f1f1",
flexDirection: "column",
},
header: {
flexDirection: "row",
padding: 0,
backgroundColor: "white",
marginBottom: 10,
height: 200,
flex: 0.4,
},
footer: {
flex: 0.2,
bottom: 0,
marginTop: 10,
height: 80,
backgroundColor: "white",
flexDirection: "row",
},
tabView: {
alignSelf: "center",
backgroundColor: "transparent",
},
tabbar: {
alignSelf: "center",
height: 40,
backgroundColor: "white",
},
tabbarItem: {
flex: 1,
backgroundColor: "#ffffff",
minWidth: "$deviceWidth",
},
steemConnectTab: {
flex: 1,
backgroundColor: "#e9e9e9",
minWidth: "$deviceWidth",
},
});

View File

@ -12,7 +12,7 @@ import Feed from "./home/feed";
import { SinglePost } from "./singlePost";
import { Profile } from "./profile";
import { Author } from "./authorProfile";
import Login from "./login/login";
import { Login } from "./login";
import Wallet from "./wallet/wallet";
import Editor from "./editor/editor";
import Discover from "./discover/discover";

View File

@ -1,7 +1,6 @@
import { createStyle } from "react-native-theming";
import { Dimensions } from "react-native";
import EStyleSheet from "react-native-extended-stylesheet";
const styles = createStyle({
export default EStyleSheet.create({
container: {
backgroundColor: "#F9F9F9",
flex: 1,
@ -20,7 +19,7 @@ const styles = createStyle({
},
tabs: {
position: "absolute",
top: Dimensions.get("window").width / 30,
top: "$deviceWidth / 30",
alignItems: "center",
},
flatlistFooter: {
@ -31,5 +30,3 @@ const styles = createStyle({
borderColor: "#CED0CE",
},
});
export default styles;