Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
75 changes: 32 additions & 43 deletions index.android.js
Original file line number Diff line number Diff line change
@@ -1,52 +1,41 @@
/**
* Sample React Native App
* Flume
* https://github.com/facebook/react-native
*/
'use strict';

var React = require('react-native');
var {
AppRegistry,
StyleSheet,
Text,
View,
} = React;
// global static data for ease-of-use (dsl'y)
global.React = require('react')
global.Native = require('react-native')
const {
Animated,
AppRegistry,
StyleSheet,
Text,
ListView,
Navigator,
NavigatorIOS,
View,
TouchableHighlight,
StatusBarIOS
} = Native
global.Component = React.Component
global.StyleSheet = StyleSheet
global.Animated = Animated

var flume = React.createClass({
// "stylesheet" theme variables
global.grid = 10,
global.textColor = '#fff'
global.themeColor = 'rgba(122,87,153,.7)'
global.darkThemeColor = '#484093'
global.fontFamily = 'Swiss721BT-Light'

const IntroScene = require('./src/IntroScene')

const app = React.createClass({
render: function() {
return (
<View style={styles.container}>
<Text style={styles.welcome}>
Welcome to React Native!
</Text>
<Text style={styles.instructions}>
To get started, edit index.android.js
</Text>
<Text style={styles.instructions}>
Shake or press menu button for dev menu
</Text>
</View>
);
return <IntroScene />
}
});

var styles = StyleSheet.create({
container: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
backgroundColor: '#F5FCFF',
},
welcome: {
fontSize: 20,
textAlign: 'center',
margin: 10,
},
instructions: {
textAlign: 'center',
color: '#333333',
marginBottom: 5,
},
});
})

AppRegistry.registerComponent('flume', () => flume);
AppRegistry.registerComponent('flume', () => app)
15 changes: 8 additions & 7 deletions src/TourDates.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,16 +57,17 @@ class TourDates extends Component {
<Text style={styles.header}>TOUR</Text>
{this.state.tourEvents.map((tour, i) => {
return (i < 10) // latest N shows
? <View key={i} style={styles.tour}>
<Text style={styles.date}>{tour.start.date}</Text>
<Text style={styles.name}>{tour.displayName}</Text>
<Text style={styles.city}>{tour.location.city}</Text>
<TouchableHighlight underlayColor='transparent' onPress={() => {
? <TouchableHighlight key={i} style={styles.tour} underlayColor='transparent' onPress={() => {
console.log('http://www.songkick.com/artists/3645486');
Linking.openURL('http://www.songkick.com/artists/3645486')
}}>
<Text style={styles.tickets}>TICKETS</Text>
</TouchableHighlight>
<View>
<Text style={styles.date}>{tour.start.date}</Text>
<Text style={styles.name}>{tour.displayName}</Text>
<Text style={styles.city}>{tour.location.city}</Text>
<Text style={styles.tickets}>TICKETS</Text>
</View>
</TouchableHighlight>
: <View key={i}></View>
})}
</LinearGradient>
Expand Down