fix uppercase error for avatars

This commit is contained in:
Lisa P 2016-03-03 16:41:14 +01:00
parent a3ce77831d
commit adb8753b60
2 changed files with 3 additions and 2 deletions

View File

@ -8,14 +8,14 @@ export default Ember.Component.extend({
userInitials: function() {
var name = this.get('name');
var arr = name.split(' ');
var initials;
var initials = '';
if (arr.length >= 2) {
initials = arr[0].split('')[0] + arr[1].split('')[0];
} else {
initials = arr[0].split('')[0];
}
return initials.toUpperCase();
return initials;
}.property('userInitials')
});

View File

@ -30,6 +30,7 @@
text-align: center
font-size: 1.4em
line-height: 1.6
text-transform: uppercase
.real-avatar
+absoluteCenter