Fix user menu CSS classes

refs #5543
This commit is contained in:
Eric Lippmann 2015-09-28 16:40:16 +02:00
parent ed6da19876
commit 98f1e9028e
3 changed files with 6 additions and 4 deletions

View File

@ -309,6 +309,7 @@ class Web extends EmbeddedWeb
'priority' => 920
)
),
'cssClass' => 'user-nav-item',
'label' => $this->user->getUsername(),
'url' => 'account',
'priority' => 900,
@ -317,13 +318,14 @@ class Web extends EmbeddedWeb
),
),
'logout' => array(
'cssClass' => 'user-nav-item',
'label' => t('Logout'),
'url' => 'authentication/logout',
'priority' => 990,
'renderer' => array(
'LogoutNavigationItemRenderer',
'target' => '_self'
)
),
'url' => 'authentication/logout'
)
);

View File

@ -9,6 +9,6 @@ class LogoutNavigationItemRenderer extends NavigationItemRenderer
{
public function render(NavigationItem $item = null)
{
return '<div class="user-nav-item">' . parent::render($item) . '</div>';
return parent::render($item);
}
}

View File

@ -17,6 +17,6 @@ class UserNavigationItemRenderer extends NavigationItemRenderer
public function render(NavigationItem $item = null)
{
return '<div class="user-nav-item clearfix">' . $this->getAvatar() . parent::render($item) . '</div>';
return '<div class="clearfix">' . $this->getAvatar() . parent::render($item) . '</div>';
}
}