Add better label when all builds displayed

This commit is contained in:
Jake Howard 2016-03-17 22:19:20 +00:00
parent d86fa02272
commit c31e186f94
2 changed files with 36 additions and 1 deletions

View file

@ -0,0 +1,34 @@
import React from 'react-native';
import GlobalStyles from '../../settings/styles';
const {
View,
Text,
StyleSheet
} = React;
const styles = StyleSheet.create({
container: {
flex: 1,
height: 45,
alignItems: 'center',
justifyContent: 'center',
backgroundColor: GlobalStyles.get('CIRCLE_ITEM_BG'),
borderBottomColor: GlobalStyles.get('CIRCLE_ITEM_BORDER'),
borderBottomWidth: 2,
flexDirection: 'row',
},
text: {
fontSize: 18,
}
});
export default class BuildItem extends React.Component {
render() {
return (
<View style={styles.container}>
<Text style={styles.text}>That's all!</Text>
</View>
);
}
};

View file

@ -3,6 +3,7 @@ import GiftedListView from 'react-native-gifted-listview';
import GlobalStyles from '../../settings/styles'; import GlobalStyles from '../../settings/styles';
import loaderHandler from 'react-native-busy-indicator/LoaderHandler'; import loaderHandler from 'react-native-busy-indicator/LoaderHandler';
import BuildItem from './BuildItem'; import BuildItem from './BuildItem';
import BuildItemEnd from './BuildItemEnd';
import { getProjectRecentBuilds } from '../../api/CircleCI'; import { getProjectRecentBuilds } from '../../api/CircleCI';
import _ from 'underscore'; import _ from 'underscore';
@ -59,7 +60,7 @@ export default class BuildList extends React.Component {
rowView={this.renderRow} rowView={this.renderRow}
refreshable={true} refreshable={true}
onFetch={this._fetch} onFetch={this._fetch}
paginationAllLoadedView={() => null}/> paginationAllLoadedView={() => <BuildItemEnd />}/>
</View> </View>
); );
} }