Skip to content
This repository was archived by the owner on Mar 4, 2025. It is now read-only.
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 2572e91

Browse files
author
Nick Litwin
committedOct 13, 2015
Merge branch 'dev' into feature/tc-ui-kit-integration
2 parents 1f1beda + 9bf2ff6 commit 2572e91

File tree

13 files changed

+52
-19
lines changed

13 files changed

+52
-19
lines changed
 

‎.version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v1.0.3
1+
v1.0.5

‎app/directives/ios-card/ios-card.directive.jade

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,14 @@
99
.challenge-details
1010

1111
p.currentPhase {{challenge.userCurrentPhase}}
12+
1213
.challenge-calendar(ng-show="challenge.userCurrentPhaseEndTime")
1314
p.ends-in Ends In
1415
p.time-remaining {{challenge.userCurrentPhaseEndTime[0]}}
1516
p.unit-of-time {{challenge.userCurrentPhaseEndTime[1]}}
1617

18+
.stalled-challenge(ng-hide="challenge.userCurrentPhaseEndTime") This challenge is currently paused.
19+
1720
p.prize-money(ng-show="challenge.reviewType === 'PEER'") Peer Review Challenge
1821

1922
p.prize-money(ng-hide="challenge.reviewType === 'PEER'") {{challenge.totalCheckpointPrize || 0 | currency:undefined:0}}

‎app/directives/profile-widget/profile-widget.directive.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
scope: {
1111
profile: '=profile',
1212
editProfileLink: '=editProfileLink',
13-
numChallenges: '=numChallenges',
13+
numWins: '=numWins',
1414
profileVm: '=profileVm'
1515
},
1616
link: function(scope, elem, attrs) {

‎app/directives/profile-widget/profile-widget.jade

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
| Member Since {{profile.startMonth}}
1111

1212
h3.location-challenges {{profile.homeCountryCode | isoCountry}}
13-
span.bar(ng-show="profile.homeCountryCode && numChallenges")  | 
14-
span(ng-show="numChallenges") {{numChallenges}} Challenges
13+
span.bar(ng-show="profile.homeCountryCode && numWins")  | 
14+
span(ng-show="numWins") {{numWins}} Wins
1515

1616
p.description {{profile.description}}
1717

‎app/index.jade

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ html
8181
8282
body(ng-app="topcoder", ng-controller="TopcoderController as main", ng-class="{'menu-visible': main.menuVisible}", ng-strict-di)
8383

84-
#header(ui-view="header")
84+
#header(ui-view="header", autoscroll="true")
8585

8686
.intro-js-container(ng-intro-options="main.introOptions", ng-intro-method="main.startIntro")
8787

‎app/my-dashboard/my-dashboard.controller.js

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,35 @@
33

44
angular.module('tc.myDashboard').controller('MyDashboardController', MyDashboardController);
55

6-
MyDashboardController.$inject = ['userIdentity'];
6+
MyDashboardController.$inject = ['userIdentity', 'ProfileService', '$log'];
77

8-
function MyDashboardController(userIdentity) {
8+
function MyDashboardController(userIdentity, ProfileService, $log) {
99
var vm = this;
1010

1111
activate();
1212

1313
function activate() {
14+
vm.showSRMs = false;
1415
vm.isCopilot = _.includes(userIdentity.roles, 'copilot');
16+
17+
displaySRMsBasedOnTrack();
18+
}
19+
20+
function displaySRMsBasedOnTrack() {
21+
ProfileService.getUserProfile(userIdentity.handle)
22+
.then(function(userProfile) {
23+
var isDesigner = _.includes(userProfile.tracks, 'DESIGN');
24+
25+
if (isDesigner && userProfile.tracks.length === 1) {
26+
vm.showSRMs = false;
27+
} else {
28+
vm.showSRMs = true;
29+
}
30+
})
31+
.catch(function(err) {
32+
vm.showSRMs = false;
33+
$log.error(err);
34+
})
1535
}
1636
}
1737
})();

‎app/my-dashboard/my-dashboard.jade

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
.my-challenges(id="challenges", ui-view="my-challenges")
77

8-
.srms(id="srms", ui-view="srms")
8+
.srms(id="srms", ui-view="srms", ng-show="dashboard.showSRMs")
99

1010
.programs(id="community", ui-view="programs")
1111

‎app/profile/about/about.jade

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.profile-header-container(ng-cloak)
2-
profile-widget(profile="profileVm.profile", edit-profile-link="profileVm.showEditProfileLink", num-challenges="profileVm.numProjects", profile-vm="profileVm")
2+
profile-widget(profile="profileVm.profile", edit-profile-link="profileVm.showEditProfileLink", num-wins="profileVm.numWins", profile-vm="profileVm")
33

44
.profile-about-container
55

‎app/profile/profile.jade

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
.profile-container
2-
ui-view(ng-cloak, autoscroll="true")
2+
ui-view(ng-cloak)

‎app/profile/subtrack/develop/develop.jade

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@
66
span.square(ng-if="vm.typeStats.rank.rating", style="background-color: {{vm.typeStats.rank.rating | ratingColor}}")
77
.name RATING
88

9-
li.stat(ng-if="!vm.typeStats.rank.rating")
9+
li.stat(ng-if="!vm.typeStats.rank.rating && !vm.nonRated")
1010
.value -
1111
.name RATING
1212

13-
li.stat
13+
li.stat(ng-hide="vm.nonRated")
1414
.value {{vm.typeStats.rank.overallRank | empty}}
1515
.name RANK
1616

17-
li.stat
17+
li.stat(ng-hide="vm.nonRated")
1818
.value {{vm.typeStats.rank.overallPercentile / 100 | percentage | empty}}
1919
.name PERCENTILE
2020

@@ -26,7 +26,7 @@
2626
.value {{vm.typeStats.wins | empty}}
2727
.name WINS
2828

29-
li.stat
29+
li.stat(ng-hide="vm.nonRated")
3030
.value {{vm.typeStats.rank.reliability | percentage | empty}}
3131
.name RELIABILITY
3232

‎app/profile/subtrack/subtrack.controller.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,8 @@
7676
vm.subTrack.toLowerCase().replace(/ /g, '')
7777
);
7878

79+
vm.nonRated = !vm.typeStats.rank.rating && !vm.typeStats.rank.overallRank && !vm.typeStats.rank.reliability;
80+
7981
if (vm.subTrack) {
8082
vm.dropdown = ProfileService.getSubTracks(profileVm.stats, vm.track.toLowerCase())
8183
.map(function(subtrack) {

‎app/settings/edit-profile/edit-profile.jade

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
.bio
3939
.form-label short bio
4040
span(style="float:right;") {{vm.userData.description.length || 0}}/144
41-
textarea.form-field(name="description", ng-model="vm.userData.description", maxlength="144")
41+
textarea.form-field(name="description", ng-model="vm.userData.description", data-ng-trim="false", maxlength="144")
4242

4343
.settings-section.tracks
4444
.section-info

‎assets/css/directives/ios-card.scss

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,10 @@ ios-card .challenge.tile-view {
5050
align-items: center;
5151

5252
.currentPhase {
53-
margin-top: 42px;
53+
margin-top: 40px;
54+
@include sofia-pro-light;
55+
font-size: 20px;
56+
line-height: 24px;
5457
}
5558
}
5659

@@ -63,7 +66,8 @@ ios-card .challenge.tile-view {
6366
}
6467

6568
.technologies {
66-
margin-bottom: 40px;
69+
height: 36px;
70+
margin-bottom: 33px;
6771
padding: 0 20px;
6872
@include source-sans-regular;
6973
font-size: 13px;
@@ -76,8 +80,7 @@ ios-card .challenge.tile-view {
7680
align-items: center;
7781
width: 75px;
7882
height: 63px;
79-
margin-bottom: 20px;
80-
margin-top: 44px;
83+
margin-top: 16px;
8184
background-image: url(/images/ico-calendar.svg);
8285

8386
> p {
@@ -106,6 +109,11 @@ ios-card .challenge.tile-view {
106109
}
107110
}
108111

112+
.stalled-challenge {
113+
margin-top: 31px;
114+
margin-bottom: 32px;
115+
}
116+
109117
.phase-action {
110118
margin-bottom: 25px;
111119
@include button-m-wide;

0 commit comments

Comments
 (0)
This repository has been archived.