신승민

add UI

import React from "react";
import { AsyncStorage } from "react-native";
import Loading from "./Loading";
import axios from "axios";
import React, { Component } from 'react';
import { StyleSheet, Text, View } from 'react-native';
import { createAppContainer } from 'react-navigation';
import { createStackNavigator } from 'react-navigation-stack';
import MainScreen from './Components/MainScreen';
const AppStackNavigator = createStackNavigator({
Main:{
screen: MainScreen // MainScreen 컴포넌트를 네비게이터에 등록
}
});
export default createAppContainer(AppStackNavigator);
const API_KEY = "2bf00f660b1a6a3ffeb6e06ac270cce3";
const NAVER_CLIENT_ID = "KqPsntd1hcPJ8FUPBGqN";
......@@ -26,6 +36,7 @@ const NAVER_CLIENT_SECRET = "0GRb3uya1U";
// }
// );
/*
export default class extends React.Component {
state = {
isLoading: true
......@@ -71,3 +82,4 @@ export default class extends React.Component {
);
}
}
*/
\ No newline at end of file
......
import React, { Component } from 'react';
import { View, Text, StyleSheet } from 'react-native';
export default class AddMediaTab extends Component {
render() {
return (
<View style={style.container}>
<Text>AddMediaTab</Text>
</View>
);
}
}
const style = StyleSheet.create({
container: {
flex: 1,
alignItems: 'center',
justifyContent: 'center',
}
});
\ No newline at end of file
import React, { Component } from 'react';
import { View, Text, StyleSheet } from 'react-native';
export default class HomeTab extends Component {
render() {
return (
<View style={style.container}>
<Text>HomeTab</Text>
</View>
);
}
}
const style = StyleSheet.create({
container: {
flex: 1,
alignItems: 'center',
justifyContent: 'center',
}
});
\ No newline at end of file
import React, { Component } from 'react';
import { View, Text, StyleSheet } from 'react-native';
export default class LikesTab extends Component {
render() {
return (
<View style={style.container}>
<Text>LikesTab</Text>
</View>
);
}
}
const style = StyleSheet.create({
container: {
flex: 1,
alignItems: 'center',
justifyContent: 'center',
}
});
\ No newline at end of file
import React, { Component } from 'react';
import { View, Text, StyleSheet } from 'react-native';
export default class ProfileTab extends Component {
render() {
return (
<View style={style.container}>
<Text>ProfileTab</Text>
</View>
);
}
}
const style = StyleSheet.create({
container: {
flex: 1,
alignItems: 'center',
justifyContent: 'center',
}
});
\ No newline at end of file
import React, { Component } from 'react';
import { View, Text, StyleSheet } from 'react-native';
export default class SearchTab extends Component {
render() {
return (
<View style={style.container}>
<Text>SearchTab</Text>
</View>
);
}
}
const style = StyleSheet.create({
container: {
flex: 1,
alignItems: 'center',
justifyContent: 'center',
}
});
\ No newline at end of file
import React, { Component } from 'react';
import { StyleSheet, Text, View } from 'react-native';
import { Icon } from 'native-base'; // 추가된 코드
import { createAppContainer } from 'react-navigation';
import { createMaterialTopTabNavigator } from 'react-navigation-tabs';
import HomeTab from './AppTabNavigator/HomeTab';
import SearchTab from './AppTabNavigator/SearchTab';
import AddMediaTab from './AppTabNavigator/AddMediaTab';
import LikesTab from './AppTabNavigator/LikesTab';
import ProfileTab from './AppTabNavigator/ProfileTab';
import { Platform } from 'react-native'
const AppTabNavigator = createMaterialTopTabNavigator({
HomeTab:{ screen: HomeTab },
Search:{ screen: SearchTab },
AddMedia:{ screen: AddMediaTab },
Likes:{ screen: LikesTab },
Profile:{ screen: ProfileTab }
}, {
animationEnabled: true,
swipeEnabled: true,
tabBarPosition: "bottom",
tabBarOptions: {
style: {
...Platform.select({
android:{
backgroundColor:'white',
}
})
},
iconStyle: { height: 8 },
activeTintColor: '#000',
inactiveTintColor: '#d1cece',
upperCaseLabel: false,
showLabel: true,
showIcon: true,
}
});
const AppTabContainet = createAppContainer(AppTabNavigator);
export default class MainScreen extends Component {
// navigationOptions 코드 추가
static navigationOptions = {
headerLeft: <Icon name='ios-camera' style={{ paddingLeft:10 }}/>,
title: 'poketMovie',
headerRight: <Icon name='ios-send' style={{ paddingRight:10 }}/>,
}
render() {
return <AppTabContainet/>; // AppTabContainet 컴포넌트를 리턴한다.
}
}
const styles = StyleSheet.create({
container: {
flex: 1,
alignItems: 'center',
justifyContent: 'center',
},
});
\ No newline at end of file
......@@ -10,10 +10,18 @@
"dependencies": {
"axios": "^0.19.0",
"expo": "^35.0.0",
"native-base": "^2.13.8",
"react": "16.8.3",
"react-dom": "16.8.3",
"react-native": "https://github.com/expo/react-native/archive/sdk-35.0.0.tar.gz",
"react-native-axios": "^0.17.1",
"react-native-gesture-handler": "~1.3.0",
"react-native-reanimated": "~1.2.0",
"react-native-screens": "~1.0.0-alpha.23",
"react-native-stack": "^1.0.0-alpha11",
"react-native-web": "^0.11.7",
"react-navigation": "^4.0.10",
"react-navigation-stack": "^1.10.3",
"request": "^2.88.0"
},
"devDependencies": {
......
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.