Merge branch 'home' into dev
This commit is contained in:
@@ -140,6 +140,7 @@ dependencies {
|
||||
compile fileTree(dir: "libs", include: ["*.jar"])
|
||||
compile "com.android.support:appcompat-v7:23.0.1"
|
||||
compile "com.facebook.react:react-native:+" // From node_modules
|
||||
compile 'com.facebook.fresco:animated-gif:1.0.1' // for gif support
|
||||
}
|
||||
|
||||
// Run this once to be able to run the application with BUCK
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
|
||||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
|
||||
|
||||
<application
|
||||
android:name=".MainApplication"
|
||||
|
||||
+13
-42
@@ -1,9 +1,6 @@
|
||||
/**
|
||||
* Sample React Native App
|
||||
* https://github.com/facebook/react-native
|
||||
* @flow
|
||||
/*
|
||||
* Main file that overlooks entire app routing
|
||||
*/
|
||||
|
||||
import React, { Component } from 'react';
|
||||
import {
|
||||
Platform,
|
||||
@@ -17,47 +14,21 @@ import {
|
||||
Stack
|
||||
} from 'react-native-router-flux';
|
||||
|
||||
const instructions = Platform.select({
|
||||
ios: 'Press Cmd+R to reload,\n' +
|
||||
'Cmd+D or shake for dev menu',
|
||||
android: 'Double tap R on your keyboard to reload,\n' +
|
||||
'Shake or press menu button for dev menu',
|
||||
});
|
||||
|
||||
// Imported screens to route through
|
||||
import Home from './screens/home.js';
|
||||
import Loading from './screens/loading.js';
|
||||
import Main from './screens/main.js'
|
||||
type Props = {};
|
||||
export default class App extends Component<Props> {
|
||||
render() {
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
<Text style={styles.welcome}>
|
||||
Welcome to React !
|
||||
</Text>
|
||||
<Text style={styles.instructions}>
|
||||
To get started, edit App.js
|
||||
</Text>
|
||||
<Text style={styles.instructions}>
|
||||
{instructions}
|
||||
</Text>
|
||||
</View>
|
||||
<Router>
|
||||
<Stack key='root' style={{paddingTop: 54}}>
|
||||
<Scene key='home' component={Home} title="Home" hideNavBar={true} />
|
||||
<Scene key='loading' component={Loading} title='Loading' />
|
||||
<Scene key='main' component={Main} title='Main' hideNavBar={true} />
|
||||
</Stack>
|
||||
</Router>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
const styles = StyleSheet.create({
|
||||
container: {
|
||||
flex: 1,
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center',
|
||||
backgroundColor: '#F5FCFF',
|
||||
},
|
||||
welcome: {
|
||||
fontSize: 20,
|
||||
textAlign: 'center',
|
||||
margin: 10,
|
||||
},
|
||||
instructions: {
|
||||
textAlign: 'center',
|
||||
color: '#333333',
|
||||
marginBottom: 5,
|
||||
},
|
||||
});
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 2.7 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 10 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 17 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 73 KiB |
@@ -0,0 +1,2 @@
|
||||
Main Theme
|
||||
Nexto color: #0e8f9e
|
||||
@@ -0,0 +1,33 @@
|
||||
/*
|
||||
* AdSpace component within Main
|
||||
*/
|
||||
import React, { Component } from 'react';
|
||||
import {
|
||||
Dimensions,
|
||||
View,
|
||||
Text,
|
||||
} from 'react-native';
|
||||
import {
|
||||
Actions
|
||||
} from 'react-native-router-flux';
|
||||
|
||||
const windowWidth = Dimensions.get('window').width;
|
||||
const windowHeight = Dimensions.get('window').height;
|
||||
|
||||
type Props = {};
|
||||
export default class AdSpace extends Component<Props> {
|
||||
render() {
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
<Text>adspace</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
const styles = {
|
||||
container: {
|
||||
flex: 1,
|
||||
backgroundColor: 'black'
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
/*
|
||||
* Chat component within Main
|
||||
*/
|
||||
import React, { Component } from 'react';
|
||||
import {
|
||||
Dimensions,
|
||||
View,
|
||||
Text,
|
||||
TextInput,
|
||||
Image
|
||||
} from 'react-native';
|
||||
import {
|
||||
Actions
|
||||
} from 'react-native-router-flux';
|
||||
|
||||
const windowWidth = Dimensions.get('window').width;
|
||||
const windowHeight = Dimensions.get('window').height;
|
||||
|
||||
type Props = {};
|
||||
export default class Chat extends Component<Props> {
|
||||
render() {
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
<View style={styles.chatField}>
|
||||
|
||||
</View>
|
||||
<View style={styles.inputMsgField}>
|
||||
<View style={styles.iconCont}>
|
||||
<Text>cra</Text>
|
||||
</View>
|
||||
<View style={styles.inputCont}>
|
||||
<TextInput
|
||||
placeholder="Type message..."
|
||||
/>
|
||||
</View>
|
||||
<View style={styles.iconCont}>
|
||||
<Image
|
||||
style={styles.sendIcon}
|
||||
source={require('../../assets/images/sendIcon.png')}
|
||||
/>
|
||||
</View>
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
const styles = {
|
||||
container: {
|
||||
flex: 1,
|
||||
flexDirection: 'column',
|
||||
justifyContent: 'flex-end',
|
||||
backgroundColor: '#e8ebef'
|
||||
},
|
||||
chatField: {
|
||||
flex: 8
|
||||
},
|
||||
inputMsgField: {
|
||||
flex: 1,
|
||||
flexDirection: 'row',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'space-between',
|
||||
height: 50,
|
||||
backgroundColor: 'white'
|
||||
},
|
||||
iconCont: {
|
||||
flex: 1,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center'
|
||||
},
|
||||
inputCont: {
|
||||
flex: 6,
|
||||
alignSelf: 'flex-end'
|
||||
},
|
||||
sendIcon: {
|
||||
height: 30,
|
||||
width: 30
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,77 @@
|
||||
/*
|
||||
* Navbar component within Main
|
||||
*/
|
||||
import React, { Component } from 'react';
|
||||
import {
|
||||
Dimensions,
|
||||
View,
|
||||
Text,
|
||||
Image
|
||||
} from 'react-native';
|
||||
import {
|
||||
Actions
|
||||
} from 'react-native-router-flux';
|
||||
|
||||
const windowWidth = Dimensions.get('window').width;
|
||||
const windowHeight = Dimensions.get('window').height;
|
||||
|
||||
type Props = {};
|
||||
export default class Navbar extends Component<Props> {
|
||||
render() {
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
<View style={styles.iconCont}>
|
||||
<Image
|
||||
style={styles.menuIcon}
|
||||
source={require('../../assets/images/menuIcon.png')}
|
||||
/>
|
||||
</View>
|
||||
<View style={styles.headerTxt}>
|
||||
<Text style={styles.head}>Main Chat</Text>
|
||||
<Text style={styles.status}>online</Text>
|
||||
</View>
|
||||
<View style={styles.iconCont}>
|
||||
<Image
|
||||
style={styles.inboxIcon}
|
||||
source={require('../../assets/images/inboxIcon.jpg')}
|
||||
/>
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
const styles = {
|
||||
container: {
|
||||
flex: 1,
|
||||
flexDirection: 'row',
|
||||
justifyContent: 'space-between',
|
||||
backgroundColor: '#0e8f9e'
|
||||
},
|
||||
iconCont: {
|
||||
flex: 1,
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center'
|
||||
},
|
||||
menuIcon: {
|
||||
height: 50,
|
||||
width: 50
|
||||
},
|
||||
headerTxt: {
|
||||
flex: 7,
|
||||
justifyContent: 'center',
|
||||
alignItems: 'center'
|
||||
},
|
||||
head: {
|
||||
fontSize: 20,
|
||||
color: 'white'
|
||||
},
|
||||
status: {
|
||||
fontSize: 13,
|
||||
color: 'white'
|
||||
},
|
||||
inboxIcon: {
|
||||
height: 40,
|
||||
width: 40
|
||||
}
|
||||
}
|
||||
Generated
+1096
-328
File diff suppressed because it is too large
Load Diff
+2
-1
@@ -8,7 +8,8 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"react": "16.3.1",
|
||||
"react-native": "0.55.3"
|
||||
"react-native": "^0.55.3",
|
||||
"react-native-router-flux": "^4.0.0-beta.28"
|
||||
},
|
||||
"devDependencies": {
|
||||
"babel-jest": "22.4.3",
|
||||
|
||||
Reference in New Issue
Block a user