mirror of
https://github.com/ecency/ecency-mobile.git
synced 2024-12-20 20:01:56 +03:00
Merge pull request #1241 from esteemapp/bugfix/android-splash
Bugfix/android splash
This commit is contained in:
commit
66af429b2d
@ -165,6 +165,8 @@ class NotificationView extends PureComponent {
|
|||||||
rightIconType="MaterialIcons"
|
rightIconType="MaterialIcons"
|
||||||
onRightIconPress={readAllNotification}
|
onRightIconPress={readAllNotification}
|
||||||
/>
|
/>
|
||||||
|
<ThemeContainer>
|
||||||
|
{({ isDarkTheme }) => (
|
||||||
<FlatList
|
<FlatList
|
||||||
data={_notifications}
|
data={_notifications}
|
||||||
refreshing={isNotificationRefreshing}
|
refreshing={isNotificationRefreshing}
|
||||||
@ -174,8 +176,6 @@ class NotificationView extends PureComponent {
|
|||||||
ListFooterComponent={this._renderFooterLoading}
|
ListFooterComponent={this._renderFooterLoading}
|
||||||
ListEmptyComponent={<ListPlaceHolder />}
|
ListEmptyComponent={<ListPlaceHolder />}
|
||||||
refreshControl={
|
refreshControl={
|
||||||
<ThemeContainer>
|
|
||||||
{({ isDarkTheme }) => (
|
|
||||||
<RefreshControl
|
<RefreshControl
|
||||||
refreshing={isNotificationRefreshing}
|
refreshing={isNotificationRefreshing}
|
||||||
progressBackgroundColor="#357CE6"
|
progressBackgroundColor="#357CE6"
|
||||||
@ -183,8 +183,6 @@ class NotificationView extends PureComponent {
|
|||||||
titleColor="#fff"
|
titleColor="#fff"
|
||||||
colors={['#fff']}
|
colors={['#fff']}
|
||||||
/>
|
/>
|
||||||
)}
|
|
||||||
</ThemeContainer>
|
|
||||||
}
|
}
|
||||||
renderItem={({ item, index }) => (
|
renderItem={({ item, index }) => (
|
||||||
<Fragment>
|
<Fragment>
|
||||||
@ -198,6 +196,8 @@ class NotificationView extends PureComponent {
|
|||||||
</Fragment>
|
</Fragment>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
)}
|
||||||
|
</ThemeContainer>
|
||||||
</View>
|
</View>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -40,12 +40,10 @@ class PointsView extends Component {
|
|||||||
|
|
||||||
// Component Functions
|
// Component Functions
|
||||||
|
|
||||||
refreshControl = () => {
|
refreshControl = ({ isDarkTheme }) => {
|
||||||
const { fetchUserActivity, refreshing } = this.props;
|
const { fetchUserActivity, refreshing } = this.props;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<ThemeContainer>
|
|
||||||
{isDarkTheme => (
|
|
||||||
<RefreshControl
|
<RefreshControl
|
||||||
refreshing={refreshing}
|
refreshing={refreshing}
|
||||||
onRefresh={fetchUserActivity}
|
onRefresh={fetchUserActivity}
|
||||||
@ -54,8 +52,6 @@ class PointsView extends Component {
|
|||||||
titleColor="#fff"
|
titleColor="#fff"
|
||||||
colors={['#fff']}
|
colors={['#fff']}
|
||||||
/>
|
/>
|
||||||
)}
|
|
||||||
</ThemeContainer>
|
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -100,7 +96,12 @@ class PointsView extends Component {
|
|||||||
return (
|
return (
|
||||||
<Fragment>
|
<Fragment>
|
||||||
<LineBreak height={12} />
|
<LineBreak height={12} />
|
||||||
<ScrollView style={styles.scrollContainer} refreshControl={this.refreshControl()}>
|
<ThemeContainer>
|
||||||
|
{isDarkTheme => (
|
||||||
|
<ScrollView
|
||||||
|
style={styles.scrollContainer}
|
||||||
|
refreshControl={this.refreshControl({ isDarkTheme })}
|
||||||
|
>
|
||||||
<View style={styles.pointsWrapper}>
|
<View style={styles.pointsWrapper}>
|
||||||
<Text onPress={this._showDropdown} style={styles.pointText}>
|
<Text onPress={this._showDropdown} style={styles.pointText}>
|
||||||
{get(userPoints, 'points')}
|
{get(userPoints, 'points')}
|
||||||
@ -122,7 +123,9 @@ class PointsView extends Component {
|
|||||||
dropdownStyle={styles.dropdownStyle}
|
dropdownStyle={styles.dropdownStyle}
|
||||||
/>
|
/>
|
||||||
</View>
|
</View>
|
||||||
<Text style={styles.subText}>{intl.formatMessage({ id: 'points.esteemPoints' })}</Text>
|
<Text style={styles.subText}>
|
||||||
|
{intl.formatMessage({ id: 'points.esteemPoints' })}
|
||||||
|
</Text>
|
||||||
|
|
||||||
<MainButton
|
<MainButton
|
||||||
isLoading={isClaiming}
|
isLoading={isClaiming}
|
||||||
@ -135,7 +138,9 @@ class PointsView extends Component {
|
|||||||
>
|
>
|
||||||
<View style={styles.mainButtonWrapper}>
|
<View style={styles.mainButtonWrapper}>
|
||||||
<Text style={styles.unclaimedText}>
|
<Text style={styles.unclaimedText}>
|
||||||
{unclaimedPoints > 0 ? unclaimedPoints : intl.formatMessage({ id: 'boost.buy' })}
|
{unclaimedPoints > 0
|
||||||
|
? unclaimedPoints
|
||||||
|
: intl.formatMessage({ id: 'boost.buy' })}
|
||||||
</Text>
|
</Text>
|
||||||
<View style={styles.mainIconWrapper}>
|
<View style={styles.mainIconWrapper}>
|
||||||
<Icon name="add" iconType="MaterialIcons" color="#357ce6" size={23} />
|
<Icon name="add" iconType="MaterialIcons" color="#357ce6" size={23} />
|
||||||
@ -188,7 +193,9 @@ class PointsView extends Component {
|
|||||||
>
|
>
|
||||||
<View style={styles.popoverWrapper}>
|
<View style={styles.popoverWrapper}>
|
||||||
<Text style={styles.popoverText}>
|
<Text style={styles.popoverText}>
|
||||||
{this._getTranslation(get(POINTS[get(item, 'type')], 'descriptionKey'))}
|
{this._getTranslation(
|
||||||
|
get(POINTS[get(item, 'type')], 'descriptionKey'),
|
||||||
|
)}
|
||||||
</Text>
|
</Text>
|
||||||
</View>
|
</View>
|
||||||
</Popover>
|
</Popover>
|
||||||
@ -229,9 +236,15 @@ class PointsView extends Component {
|
|||||||
isThin
|
isThin
|
||||||
text={
|
text={
|
||||||
get(item, 'sender')
|
get(item, 'sender')
|
||||||
? `${intl.formatMessage({ id: 'points.from' })} @${get(item, 'sender')}`
|
? `${intl.formatMessage({ id: 'points.from' })} @${get(
|
||||||
|
item,
|
||||||
|
'sender',
|
||||||
|
)}`
|
||||||
: get(item, 'receiver') &&
|
: get(item, 'receiver') &&
|
||||||
`${intl.formatMessage({ id: 'points.to' })} @${get(item, 'receiver')}`
|
`${intl.formatMessage({ id: 'points.to' })} @${get(
|
||||||
|
item,
|
||||||
|
'receiver',
|
||||||
|
)}`
|
||||||
}
|
}
|
||||||
description={get(item, 'memo')}
|
description={get(item, 'memo')}
|
||||||
/>
|
/>
|
||||||
@ -241,6 +254,8 @@ class PointsView extends Component {
|
|||||||
/>
|
/>
|
||||||
</View>
|
</View>
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
|
)}
|
||||||
|
</ThemeContainer>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -376,6 +376,8 @@ class PostsView extends Component {
|
|||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
<ThemeContainer>
|
||||||
|
{({ isDarkTheme }) => (
|
||||||
<FlatList
|
<FlatList
|
||||||
data={posts}
|
data={posts}
|
||||||
showsVerticalScrollIndicator={false}
|
showsVerticalScrollIndicator={false}
|
||||||
@ -395,8 +397,6 @@ class PostsView extends Component {
|
|||||||
onScrollEndDrag={this._handleOnScroll}
|
onScrollEndDrag={this._handleOnScroll}
|
||||||
ListEmptyComponent={this._renderEmptyContent}
|
ListEmptyComponent={this._renderEmptyContent}
|
||||||
refreshControl={
|
refreshControl={
|
||||||
<ThemeContainer>
|
|
||||||
{({ isDarkTheme }) => (
|
|
||||||
<RefreshControl
|
<RefreshControl
|
||||||
refreshing={refreshing}
|
refreshing={refreshing}
|
||||||
onRefresh={this._handleOnRefreshPosts}
|
onRefresh={this._handleOnRefreshPosts}
|
||||||
@ -405,13 +405,13 @@ class PostsView extends Component {
|
|||||||
titleColor="#fff"
|
titleColor="#fff"
|
||||||
colors={['#fff']}
|
colors={['#fff']}
|
||||||
/>
|
/>
|
||||||
)}
|
|
||||||
</ThemeContainer>
|
|
||||||
}
|
}
|
||||||
ref={ref => {
|
ref={ref => {
|
||||||
this.flatList = ref;
|
this.flatList = ref;
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
|
)}
|
||||||
|
</ThemeContainer>
|
||||||
</View>
|
</View>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -58,12 +58,12 @@ class WalletView extends PureComponent {
|
|||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
<ThemeContainer>
|
||||||
|
{isDarkTheme => (
|
||||||
<ScrollView
|
<ScrollView
|
||||||
onScroll={handleOnScroll && handleOnScroll}
|
onScroll={handleOnScroll && handleOnScroll}
|
||||||
style={styles.scrollView}
|
style={styles.scrollView}
|
||||||
refreshControl={
|
refreshControl={
|
||||||
<ThemeContainer>
|
|
||||||
{isDarkTheme => (
|
|
||||||
<RefreshControl
|
<RefreshControl
|
||||||
refreshing={isRefreshing}
|
refreshing={isRefreshing}
|
||||||
onRefresh={handleOnWalletRefresh}
|
onRefresh={handleOnWalletRefresh}
|
||||||
@ -72,8 +72,6 @@ class WalletView extends PureComponent {
|
|||||||
titleColor="#fff"
|
titleColor="#fff"
|
||||||
colors={['#fff']}
|
colors={['#fff']}
|
||||||
/>
|
/>
|
||||||
)}
|
|
||||||
</ThemeContainer>
|
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
{!walletData ? (
|
{!walletData ? (
|
||||||
@ -128,6 +126,8 @@ class WalletView extends PureComponent {
|
|||||||
</Fragment>
|
</Fragment>
|
||||||
)}
|
)}
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
|
)}
|
||||||
|
</ThemeContainer>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -5,5 +5,6 @@ export default EStyleSheet.create({
|
|||||||
flex: 1,
|
flex: 1,
|
||||||
justifyContent: 'center',
|
justifyContent: 'center',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
|
backgroundColor: '$pureWhite',
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user