mm-1302 - Adding profile pick in LHS Header

This commit is contained in:
Asaad Mahmood
2015-07-14 03:26:04 +05:00
parent 0a166572c1
commit d1cb7d35fb
2 changed files with 28 additions and 9 deletions

View File

@@ -77,7 +77,7 @@ var NavbarDropdown = React.createClass({
for (var i = 0; i < this.state.teams.length; i++) {
var domain = this.state.teams[i];
if (domain == utils.getSubDomain())
if (domain == utils.getSubDomain())
continue;
if (teams.length == 0)
@@ -125,9 +125,11 @@ module.exports = React.createClass({
return (
<div className="team__header theme">
<img className="profile-picture" src={"/api/v1/users/" + me.id + "/image?time=" + me.update_at} />
<span className="user_name">{me.username}</span>
<a className="team__name" href="/channels/town-square">{ teamName }</a>
<img className="user__picture" src={"/api/v1/users/" + me.id + "/image?time=" + me.update_at} />
<div className="header__info">
<div className="user__name">@{me.username}</div>
<a className="team__name" href="/channels/town-square">{ teamName }</a>
</div>
<NavbarDropdown teamType={this.props.teamType} />
</div>
);

View File

@@ -75,14 +75,16 @@
// Team Header in Sidebar
.sidebar--left, .sidebar--menu {
.team__header {
padding: 0 15px 0 15px;
padding: 15px;
@include legacy-pie-clearfix;
a {
color: #fff;
}
.navbar-right {
font-size: 0.85em;
margin: 16px -5px 0;
position: absolute;
top: 24px;
right: 25px;
.dropdown-toggle {
padding: 0 10px;
}
@@ -100,17 +102,32 @@
display: inline-block;
}
}
.team__name {
.user__picture {
width: 36px;
height: 36px;
float: left;
line-height: 50px;
@include border-radius(36px);
}
.header__info {
padding-left: 42px;
color: #fff;
}
.team__name, .user__name {
display: block;
line-height: 18px;
font-weight: 600;
font-size: 1.2em;
font-size: 16px;
max-width: 80%;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
text-decoration: none;
}
.user__name {
font-size: 14px;
font-weight: 400;
color: #eee;
}
> .nav {
> li {
> a {