Skip to content
This repository was archived by the owner on Mar 4, 2025. It is now read-only.

Commit 7fd8138

Browse files
committed
Merge pull request #200 from appirio-tech/dev
Release dev to qa
2 parents 8f8bb9f + 87f4c67 commit 7fd8138

File tree

3 files changed

+34
-2
lines changed

3 files changed

+34
-2
lines changed

src/footer.html

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,23 @@ <h2>Comment Examples</h2>
175175
} else {
176176
photoLink = tcconfig.communityURL + '/i/m/nophoto_login.gif';
177177
}
178+
179+
var color = '';
180+
var ratings = data['ratingSummary'];
181+
if (ratings) {
182+
var maxRating = 0;
183+
for (var i = 0; i < ratings.length; i++) {
184+
if (maxRating < ratings[i]['rating']) {
185+
maxRating = ratings[i]['rating'];
186+
color = ratings[i]['colorStyle'].split(": ")[1];
187+
}
188+
}
189+
} else if (data['isPM'] == true) {
190+
color = '#FF9900';
191+
}
192+
178193
$timeout(function() {
194+
vm.handleStyle = { color: color };
179195
vm.photoURL = photoLink;
180196
});
181197
});

src/js/app/header/partials/header-nav.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<div class="menu-item-header">
2121
<a ng-href={{vm.profileLink}} class="profile-link-dropdown">
2222
<img ng-src="{{vm.photoURL}}" class="user-avatar"/>
23-
<span class="username">{{vm.userHandle}}</span>
23+
<span ng-style="vm.handleStyle" class="username">{{vm.userHandle}}</span>
2424
</a>
2525
</div>
2626
<a href="/settings/profile" class="btn-link btn-edit-profile show-small">EDIT</a>

wp/wp-content/themes/tcs-responsive/footer.php

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,23 @@ function _kms(u){
256256
} else {
257257
photoLink = tcconfig.communityURL + '/i/m/nophoto_login.gif';
258258
}
259+
260+
var color = '';
261+
var ratings = data['ratingSummary'];
262+
if (ratings) {
263+
var maxRating = 0;
264+
for (var i = 0; i < ratings.length; i++) {
265+
if (maxRating < ratings[i]['rating']) {
266+
maxRating = ratings[i]['rating'];
267+
color = ratings[i]['colorStyle'].split(": ")[1];
268+
}
269+
}
270+
} else if (data['isPM'] == true) {
271+
color = '#FF9900';
272+
}
273+
259274
$timeout(function() {
275+
vm.handleStyle = { color: color };
260276
vm.photoURL = photoLink;
261277
});
262278
});
@@ -290,7 +306,7 @@ function _kms(u){
290306
{ 'href': '/community/competitive%20programming/', 'text': 'COMPETITIVE PROGRAMMING', 'icon': '/mf/i/nav/book-cp.svg' },
291307
],
292308
'community': [
293-
{ 'href': '/community/members/', 'text': 'MEMBERS', 'icon': '/mf/i/nav/members.svg' },
309+
{ 'href': '/community/members/', 'text': 'OVERVIEW', 'icon': '/mf/i/nav/members.svg' },
294310
{ 'href': '/community/member-programs/', 'text': 'PROGRAMS', 'icon': '/mf/i/nav/programs.svg' },
295311
{ 'href': 'https://' + tcconfig.forumsAppURL, 'text': 'FORUMS', 'icon': '/mf/i/nav/forums.svg' },
296312
{ 'href': '/community/statistics/', 'text': 'STATISTICS', 'icon': '/mf/i/nav/statistics.svg' },

0 commit comments

Comments
 (0)