From 526b91e0a6658740eae8f95a2a66b605099d5821 Mon Sep 17 00:00:00 2001 From: dabit3 Date: Tue, 13 Sep 2016 09:48:50 -0500 Subject: [PATCH] updated to new version of RNElements --- package.json | 2 +- src/about/About.js | 22 +++++++++++++++++++++- src/more/More.js | 36 ++++++++++++++++++++++++++++++++++-- 3 files changed, 56 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 2926fb9a..53ceb0d5 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,7 @@ "lodash": "^4.15.0", "react": "15.3.1", "react-native": "0.32.0", - "react-native-elements": "0.3.2", + "react-native-elements": "0.4.2", "react-native-tab-navigator": "^0.3.3", "react-native-vector-icons": "^2.1.0", "react-redux": "^4.4.5", diff --git a/src/about/About.js b/src/about/About.js index ac76f296..5fe9d3ec 100644 --- a/src/about/About.js +++ b/src/about/About.js @@ -6,7 +6,8 @@ import Icon from 'react-native-vector-icons/MaterialIcons' import { Text, Card, - SocialIcon + SocialIcon, + ButtonGroup } from 'react-native-elements' let styles = {} @@ -39,13 +40,32 @@ const users = [ ] class About extends Component { + constructor () { + super() + this.state = { + selectedIndex: 0 + } + this.updateIndex = this.updateIndex.bind(this) + } + updateIndex (selectedIndex) { + this.setState({selectedIndex}) + } render () { + const buttons = ['Button1', 'Button2'] + const { selectedIndex } = this.state return ( Components + + + diff --git a/src/more/More.js b/src/more/More.js index acebc465..f12cba64 100644 --- a/src/more/More.js +++ b/src/more/More.js @@ -6,7 +6,8 @@ let styles import { List, ListItem, - Text + Text, + SearchBar } from 'react-native-elements' const log = () => console.log('this is an example method') @@ -86,7 +87,38 @@ class More extends Component { - List + Searchbar & List + + + + + + + + + + + + + + + + + +