fix tests and formatting
This commit is contained in:
1 parent
d352bf3e05
commit
20cc4d6b1c
3 files changed
+11
-5
No files matched your search
+2
-1
@@ -26,8 +26,9 @@
|
||||
},
|
||||
"jest": {
|
||||
"preset": "react-native",
|
||||
"setupFiles": ["<rootDir>/jest/setup.js"],
|
||||
"transformIgnorePatterns": [
|
||||
"node_modules/(?!react-native|react-navigation)"
|
||||
"node_modules/(?!(jest-)?react-native|react-clone-referenced-element|react-navigation|native-base|@shoutem)"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
import {StyleSheet, Linking, ActivityIndicator, View, SectionList} from "react-native";
|
||||
import {StyleSheet, ActivityIndicator, View, SectionList} from "react-native";
|
||||
import {Card, ListItem, CardItem, Body, Text as Text, Left, Right, Icon, Button, Content} from 'native-base';
|
||||
import React, { Component } from 'react';
|
||||
import moment from "moment";
|
||||
@@ -8,8 +8,8 @@ export default class EventList extends Component {
|
||||
_renderItem = ({item}) => (
|
||||
<ListItem button onPress={() => { this._onPressItem(item); }} style={styles.listItem}>
|
||||
<Body style={{flex: 5}}>
|
||||
<Text style={styles.listItemTitle} numberOfLines={1}>{item.title.decoded}</Text>
|
||||
<Text style={styles.listItemTime}>{this._formatTime(item.start_time)}</Text>
|
||||
<Text style={styles.listItemTitle} numberOfLines={1}>{item.title.decoded}</Text>
|
||||
<Text style={styles.listItemTime}>{this._formatTime(item.start_time)}</Text>
|
||||
</Body>
|
||||
<Right style={{flex: 1}}>
|
||||
<Icon name="arrow-forward" />
|
||||
|
||||
@@ -104,7 +104,12 @@ class EventListContainer extends React.Component {
|
||||
};
|
||||
|
||||
render() {
|
||||
return (<EventList showEvent={this.showEvent} {...{...this.state, handleRefresh: this.handleRefresh, handleLoadMore: this.handleLoadMore}} />)
|
||||
return (<EventList
|
||||
showEvent={this.showEvent}
|
||||
handleRefresh={this.handleRefresh}
|
||||
handleLoadMore={this.handleLoadMore}
|
||||
{...this.state}
|
||||
/>)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user