Skip to content

Instantly share code, notes, and snippets.

@khatv911
Last active April 27, 2017 09:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save khatv911/131c0b4c895b0285e015ff4ece54ab44 to your computer and use it in GitHub Desktop.
Save khatv911/131c0b4c895b0285e015ff4ece54ab44 to your computer and use it in GitHub Desktop.
Section Header
import React, {Component} from 'react';
import {View, StyleSheet} from 'react-native';
import {Icon, Text} from 'react-native-elements';
const SectionHeader = (section, index, isActive) => <View style={styles.container}>
<Text h4>{section.title}</Text>
<View style={styles.right}>
<Text style={{
marginRight: 5,
fontSize: 18
}}>10</Text>
<Icon
name={isActive
? 'arrow-down'
: 'arrow-right'}
type='simple-line-icon'
size={25}/>
</View>
</View>
const styles = StyleSheet.create({
container: {
flexDirection: 'row',
justifyContent: 'space-between',
alignItems: 'center',
borderBottomWidth: 0.75,
padding: 10
},
left: {},
right: {
justifyContent: 'space-between',
flexDirection: 'row',
alignItems: 'center'
}
});
export default SectionHeader;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment