parent
4c798d4e04
commit
30ed3ad760
|
@ -42,7 +42,7 @@ abstract class BadgeMenuItemRenderer extends MenuItemRenderer
|
||||||
*/
|
*/
|
||||||
public function render(Menu $menu)
|
public function render(Menu $menu)
|
||||||
{
|
{
|
||||||
return $this->renderBadge() . $this->createLink($menu);
|
return '<div class="clearfix">' . $this->renderBadge() . $this->createLink($menu) . '</div>';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -53,10 +53,11 @@ abstract class BadgeMenuItemRenderer extends MenuItemRenderer
|
||||||
protected function renderBadge()
|
protected function renderBadge()
|
||||||
{
|
{
|
||||||
if ($count = $this->getCount()) {
|
if ($count = $this->getCount()) {
|
||||||
|
$view = $this->getView();
|
||||||
return sprintf(
|
return sprintf(
|
||||||
'<div title="%s" class="badge-container"><span class="badge badge-%s">%s</span></div>',
|
'<span title="%s" class="badge pull-right state-%s">%s</span>',
|
||||||
$this->getView()->escape($this->getTitle()),
|
$view->escape($this->getTitle()),
|
||||||
$this->getView()->escape($this->getState()),
|
$view->escape($this->getState()),
|
||||||
$count
|
$count
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue