Last active
March 24, 2018 14:09
-
-
Save alexkuttig/e505c914e8649bffb38337aa28ce1607 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { | |
statusBarHeight, | |
headerHeight, | |
SafeAreaWithHeader, | |
} from './DimensionsHelper'; | |
const vw: number = SafeAreaWithHeader.vw; | |
const vh: number = SafeAreaWithHeader.vh; | |
class ViewWithTitle extends Component { | |
render() { | |
return ( | |
<View style={styles.outerContainer}> | |
/* | |
title stuff here | |
*/ | |
{ | |
this.renderIOSBigTitle() | |
} | |
<View style={[styles.titleContainer, {height: this.headerHeight}]}> | |
{ | |
this.renderTitleArea() | |
} | |
</View> | |
<View style={[styles.innerContainer, {height: 100 * vh}]}> | |
/* | |
content stuff here | |
*/ | |
{ | |
this.renderContentArea() | |
} | |
{ | |
this.renderContentAreaList() | |
} | |
</View> | |
</View> | |
); | |
} | |
} | |
const styles: StyleSheet = StyleSheet.create({ | |
outerContainer: { | |
width: 100 * vw, | |
backgroundColor: '#ffffff', | |
}, | |
innerContainer: { | |
position: 'relative', | |
width: 100 * vw, | |
} | |
}); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment