Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
mmelchio committed Jul 15, 2016
2 parents 77aa772 + 8351ade commit 9d85c43
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion js/components/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ const scenes = Actions.create(
</Scene>
<Scene key="solveTask" panHandlers={null} component={SolveTaskModal} direction="vertical" />
<Scene key="taskReward" panHandlers={null} component={TaskRewardModal} direction="vertical" />
<Scene key="profileModal" hideNavBar={false} panHandlers={null} component={ProfileModal} direction="horizontal" />
<Scene key="profileModal" hideNavBar panHandlers={null} component={ProfileModal} direction="horizontal" />
</Scene>
</Scene>
);
Expand Down
8 changes: 5 additions & 3 deletions js/components/shared/Profile.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ const styles = StyleSheet.create({
justifyContent: 'flex-start',
alignItems: 'flex-start',
padding: 10,
marginTop: -20,
},
containerKoins: {
flexDirection: 'column',
Expand Down Expand Up @@ -117,7 +118,7 @@ const Profile = React.createClass({
},

render() {
let name, userName, oauthProvider, solveCount, collectedKoins, ranking; // eslint-disable-line one-var, max-len
let name, userName, picUrl, oauthProvider, solveCount, collectedKoins, ranking; // eslint-disable-line one-var, max-len
if (this.state.user === null) {
name = '';
userName = '';
Expand All @@ -128,6 +129,7 @@ const Profile = React.createClass({
} else {
name = (this.state.user.name === null) ? '' : this.state.user.name;
userName = this.state.user.userName;
picUrl = this.state.user.picUrl;
oauthProvider = (this.state.user.oauthProvider === null) ? '' : this.state.user.oauthProvider;
solveCount = this.state.user.solveCount;
collectedKoins = `${this.state.user.koinCount} ${I18n.t('profile_content_koins_title')}`;
Expand Down Expand Up @@ -169,17 +171,17 @@ const Profile = React.createClass({
<View style={styles.containerProfile}>
<Image
style={{ width: 64, height: 64, padding: 64 }}
source={{ uri: this.state.picUrl }}
source={{ uri: picUrl }}
/>
<View style={styles.containerProfileDescription}>
<Text style={styles.textSubTitle}>{I18n.t('profile_content_username')}</Text>
<Text style={styles.textSubTitle}>{userName}</Text>
{oauthProviderInfo}
{logoutButton}
<Text style={styles.textSubTitle}>{I18n.t('profile_content_fixes')}</Text>
<Text style={styles.textSubTitle}>{solveCount}</Text>
</View>
</View>
{logoutButton}
<Text style={styles.textSubTitle}>{I18n.t('profile_content_koins_header')}</Text>
<View style={styles.containerKoins}>
<View style={styles.containerKoinsDescription}>
Expand Down

0 comments on commit 9d85c43

Please sign in to comment.