import React, { Component } from 'react';
import {
StyleSheet,
View,
ScrollView
} from 'react-native';
import Heading from '../components/heading'
export default class ScrollableContainer extends Component {
constructor(props) {
super()
}
render() {
const { heading, bodyStyle, headingOnPress, ...props } = this.props
let headingEl;
if (heading) {
headingEl = (
{heading.toUpperCase()}
)
}
else {
headingEl = null
}
return (
this.scrollView = ref} contentContainerStyle={[styles.body, bodyStyle]}>
{headingEl}
{this.props.children}
footer
)
}
}
const styles = StyleSheet.create({
container: {
width: '100vw',
flex: 1,
justifyContent: 'flex-start',
},
heading: {
},
body: {
alignItems: 'center',
},
})