diff --git a/application/controllers/NodeController.php b/application/controllers/NodeController.php index d04a80c..fa20e8d 100644 --- a/application/controllers/NodeController.php +++ b/application/controllers/NodeController.php @@ -87,7 +87,9 @@ class NodeController extends Controller ->setPath(array_shift($parentAndPath)); $bc = Breadcrumb::create($renderer); - $bc->getAttributes()->set('data-base-target', '_next'); + $bc->getAttributes() + ->set('data-base-target', '_next') + ->add('class', 'with-states'); $content->add($bc); } } diff --git a/public/css/module.less b/public/css/module.less index ff2bf09..f40dec2 100644 --- a/public/css/module.less +++ b/public/css/module.less @@ -537,26 +537,6 @@ td > a > .badges { padding: 0; } -/*.breadcrumb { - > .critical a { background: @colorCritical; } - > .critical.handled a { background: @colorCriticalHandled; } - > .unknown a { background: @colorUnknown; } - > .unknown.handled a { background: @colorUnknownHandled; } - > .warning a { background: @colorWarning; } - > .warning.handled a { background: @colorWarningHandled; } - > .ok a { background: @colorOk; } -} - -.breadcrumb { - > .critical a:after { border-left-color: @colorCritical; } - > .critical.handled a:after { border-left-color: @colorCriticalHandled; } - > .unknown a:after { border-left-color: @colorUnknown; } - > .unknown.handled a:after { border-left-color: @colorUnknownHandled; } - > .warning a:after { border-left-color: @colorWarning; } - > .warning.handled a:after { border-left-color: @colorWarningHandled; } - > .ok a:after { border-left-color: @colorOk; } -}*/ - .breadcrumb:after { content:''; display:block; @@ -603,6 +583,35 @@ td > a > .badges { } } } +.breadcrumb.with-states li { + &.critical { background: @colorCritical; } + &.critical.handled { background: @colorCriticalHandled; } + &.unknown { background: @colorUnknown; } + &.unknown.handled { background: @colorUnknownHandled; } + &.warning { background: @colorWarning; } + &.warning.handled { background: @colorWarningHandled; } + &.ok { background: @colorOk; } + + &.process-node a { color: white; } +} +.breadcrumb.with-states li:not(:last-of-type) { + &.critical a:after { border-left-color: @colorCritical; } + &.critical.handled a:after { border-left-color: @colorCriticalHandled; } + &.unknown a:after { border-left-color: @colorUnknown; } + &.unknown.handled a:after { border-left-color: @colorUnknownHandled; } + &.warning a:after { border-left-color: @colorWarning; } + &.warning.handled a:after { border-left-color: @colorWarningHandled; } + &.ok a:after { border-left-color: @colorOk; } +} +.breadcrumb.with-states li:last-of-type { + &.critical { border-color: @colorCritical; } + &.critical.handled { border-color: @colorCriticalHandled; } + &.unknown { border-color: @colorUnknown; } + &.unknown.handled { border-color: @colorUnknownHandled; } + &.warning { border-color: @colorWarning; } + &.warning.handled { border-color: @colorWarningHandled; } + &.ok { border-color: @colorOk; } +} .breadcrumb li:not(:last-of-type) a:before, .breadcrumb li:not(:last-of-type) a:after { content: " "; @@ -632,15 +641,10 @@ td > a > .badges { padding-left: 1em; padding-right: 0.5em; } -.breadcrumb li:last-child a { - cursor: default; -} -.breadcrumb li:last-child a:hover { - -} .breadcrumb li:not(:last-child) a:hover { background: @icinga-blue; color: white; } -.breadcrumb li:not(:last-child) a:hover:after { border-left-color: @icinga-blue; } +.breadcrumb li:not(:last-child) a:hover:after { border-left-color: @icinga-blue !important; } +.breadcrumb li:last-child:hover, .breadcrumb li:last-child a:hover { background: @icinga-blue; border-color: @icinga-blue !important; } .breadcrumb li a:focus { text-decoration: underline;