summaryrefslogtreecommitdiff
path: root/client/src/lib/components/footer.js
diff options
context:
space:
mode:
authorJules Laplace <julescarbon@gmail.com>2017-06-01 19:47:08 -0400
committerJules Laplace <julescarbon@gmail.com>2017-06-01 19:47:08 -0400
commit3e72bfa56c860826429a842f6c128d78d4a930db (patch)
tree3cecd31c92d53fae32e9761b80802c82f3dcb7fa /client/src/lib/components/footer.js
parentb694bd511ceccd00d4a4c98f36f910d5fc5f79c4 (diff)
react-native-web port of fmf app
Diffstat (limited to 'client/src/lib/components/footer.js')
-rw-r--r--client/src/lib/components/footer.js77
1 files changed, 77 insertions, 0 deletions
diff --git a/client/src/lib/components/footer.js b/client/src/lib/components/footer.js
new file mode 100644
index 0000000..b389245
--- /dev/null
+++ b/client/src/lib/components/footer.js
@@ -0,0 +1,77 @@
+import React, { Component } from 'react'
+import {
+ Image,
+ StyleSheet,
+ TouchableOpacity,
+ Text,
+ View,
+} from 'react-native'
+import { Link } from 'react-router-dom'
+
+export default class ClearText extends Component {
+ render() {
+ return (
+ <View style={styles.footer}>
+ <Link to='/page/privacy'>
+ <View style={styles.footerItem}>
+ <Text style={styles.footerText}>Privacy</Text>
+ </View>
+ </Link>
+ <View style={styles.footerItem}>
+ <TouchableOpacity onPress={() => this.props.onLinkPress('http://armoryonpark.org/')}>
+ <Image source={require('../../img/armory.png')} resizeMode='contain' style={styles.footerLogo} />
+ </TouchableOpacity>
+ </View>
+ <Link to='/page/credits'>
+ <View style={styles.footerItem}>
+ <Text style={styles.footerText}>Credits</Text>
+ </View>
+ </Link>
+ </View>
+ )
+ }
+}
+
+const isIphone = (navigator.userAgent.match(/iPhone/i)) || (navigator.userAgent.match(/iPod/i))
+const isIpad = (navigator.userAgent.match(/iPad/i))
+const isAndroid = (navigator.userAgent.match(/Android/i))
+const isMobile = isIphone || isIpad || isAndroid
+const isDesktop = ! isMobile
+
+const styles = StyleSheet.create({
+ footer: {
+ position: 'fixed',
+ bottom: 0,
+ left: 0,
+ width: '100%',
+ height: isMobile ? 40 : 70,
+ backgroundColor: 'black',
+ paddingTop: isMobile ? 5 : 20,
+ paddingBottom: isMobile ? 5 : 20,
+ flexDirection: 'row',
+ justifyContent: 'space-around',
+ alignItems: 'center',
+ },
+ footerLogo: {
+ flexDirection: 'row',
+ justifyContent: 'center',
+ alignItems: 'center',
+ maxWidth: 140,
+ maxHeight: 40,
+ width: 260,
+ height: 39,
+ },
+ footerItem: {
+ height: 35,
+ flex: 1,
+ alignItems: 'center',
+ },
+ footerText: {
+ fontFamily: 'Futura-Medium',
+ color: 'white',
+ fontSize: 10,
+ flex: 1,
+ padding: 10,
+ marginTop: 4,
+ }
+})