aretherecookies-mobile/js/components/IconButton.js
2017-04-14 12:28:48 -05:00

17 lines
563 B
JavaScript

// @flow
import React from 'react';
import { Text, View } from 'react-native';
import { pure } from 'recompose';
import { Link } from 'react-router-native';
import { Icon } from 'react-native-material-ui';
export default pure(({ glyph, text, route }: { glyph: string, text: string, route: string }) => (
<View style={{ flex: 3 }}>
<Link to={route}>
<View style={{ alignItems: 'center' }}>
<Icon name={glyph} size={50} color="grey" />
<Text>{text}</Text>
</View>
</Link>
</View>
));