mirror of
https://github.com/ecency/ecency-mobile.git
synced 2024-12-16 00:52:04 +03:00
updated a bit
This commit is contained in:
parent
9a29783fa1
commit
04c36000db
@ -1,5 +1,6 @@
|
|||||||
import React, { PureComponent } from 'react';
|
import React, { PureComponent } from 'react';
|
||||||
import { View, FlatList, Text } from 'react-native';
|
import { View, FlatList, Text } from 'react-native';
|
||||||
|
import { injectIntl } from 'react-intl';
|
||||||
|
|
||||||
// Constants
|
// Constants
|
||||||
|
|
||||||
@ -35,11 +36,15 @@ class LeaderboardView extends PureComponent {
|
|||||||
};
|
};
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const { users } = this.props;
|
const { users, intl } = this.props;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<View style={styles.container}>
|
<View style={styles.container}>
|
||||||
<Text style={styles.text}>Daily Top User</Text>
|
<Text style={styles.text}>
|
||||||
|
{intl.formatMessage({
|
||||||
|
id: 'notification.leaderboard_title',
|
||||||
|
})}
|
||||||
|
</Text>
|
||||||
<FlatList
|
<FlatList
|
||||||
data={users}
|
data={users}
|
||||||
keyExtractor={item => item.voter}
|
keyExtractor={item => item.voter}
|
||||||
@ -51,4 +56,4 @@ class LeaderboardView extends PureComponent {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export default LeaderboardView;
|
export default injectIntl(LeaderboardView);
|
||||||
|
@ -134,6 +134,8 @@ class UpvoteView extends Component {
|
|||||||
|
|
||||||
const _percent = `${(sliderValue * 100).toFixed(0)}%`;
|
const _percent = `${(sliderValue * 100).toFixed(0)}%`;
|
||||||
const _amount = `$${amount}`;
|
const _amount = `$${amount}`;
|
||||||
|
const _totalPayout = totalPayout ? totalPayout : '0.000';
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<PopoverController>
|
<PopoverController>
|
||||||
{({
|
{({
|
||||||
@ -167,8 +169,8 @@ class UpvoteView extends Component {
|
|||||||
name={iconName}
|
name={iconName}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
{isShowPayoutValue && totalPayout && (
|
{isShowPayoutValue && (
|
||||||
<Text style={[styles.payoutValue, isDecinedPayout && styles.declinedPayout]}>{`$${totalPayout}`}</Text>
|
<Text style={[styles.payoutValue, isDecinedPayout && styles.declinedPayout]}>{`$${_totalPayout}`}</Text>
|
||||||
)}
|
)}
|
||||||
</Fragment>
|
</Fragment>
|
||||||
</TouchableOpacity>
|
</TouchableOpacity>
|
||||||
|
Loading…
Reference in New Issue
Block a user