[icinga-checkins] icinga.org: icingaweb2/feature/redesign-state-badges: Monitoring: Redesign state badges

git at icinga.org git at icinga.org
Tue Nov 15 16:14:48 CET 2016


Module: icingaweb2
Branch: feature/redesign-state-badges
Commit: de2db52f5a360e643e8b4072c876727f46325668
URL:    https://git.icinga.org/?p=icingaweb2.git;a=commit;h=de2db52f5a360e643e8b4072c876727f46325668

Author: Florian Strohmaier <florian.strohmaier at netways.de>
Date:   Tue Nov 15 16:14:41 2016 +0100

Monitoring: Redesign state badges

---

 .../views/scripts/list/components/hostssummary.phtml    |    4 ++--
 .../views/scripts/list/components/servicesummary.phtml  |    4 ++--
 modules/monitoring/public/css/module.less               |   15 ++++++++++++---
 3 files changed, 16 insertions(+), 7 deletions(-)

diff --git a/modules/monitoring/application/views/scripts/list/components/hostssummary.phtml b/modules/monitoring/application/views/scripts/list/components/hostssummary.phtml
index 4b9f1cd..f41a2fd 100644
--- a/modules/monitoring/application/views/scripts/list/components/hostssummary.phtml
+++ b/modules/monitoring/application/views/scripts/list/components/hostssummary.phtml
@@ -9,7 +9,7 @@ if (! $stats instanceof stdClass) {
 ?>
 <div class="hosts-summary dont-print">
     <span class="hosts-link"><?= $this->qlink(
-        sprintf($this->translatePlural('%u Host', '%u Hosts', $stats->hosts_total), $stats->hosts_total),
+        sprintf($this->translatePlural('%u', '%u', $stats->hosts_total), $stats->hosts_total),
         // @TODO(el): Fix that
         Url::fromPath('monitoring/list/hosts')->setParams(isset($baseFilter) ? $baseFilter->getUrlParams() : array()),
         null,
@@ -17,7 +17,7 @@ if (! $stats instanceof stdClass) {
             $this->translatePlural('List %u host', 'List all %u hosts', $stats->hosts_total),
             $stats->hosts_total
         ))
-    ) ?>:</span>
+    ) ?></span>
 <?php
 $stateBadges = new StateBadges();
 $stateBadges
diff --git a/modules/monitoring/application/views/scripts/list/components/servicesummary.phtml b/modules/monitoring/application/views/scripts/list/components/servicesummary.phtml
index 5b0bfc5..d73fead 100644
--- a/modules/monitoring/application/views/scripts/list/components/servicesummary.phtml
+++ b/modules/monitoring/application/views/scripts/list/components/servicesummary.phtml
@@ -10,7 +10,7 @@ if (! $stats instanceof stdClass) {
 <div class="services-summary dont-print">
     <span class="services-link"><?= $this->qlink(
         sprintf($this->translatePlural(
-            '%u Service', '%u Services', $stats->services_total),
+            '%u', '%u', $stats->services_total),
             $stats->services_total
         ),
         // @TODO(el): Fix that
@@ -20,7 +20,7 @@ if (! $stats instanceof stdClass) {
             $this->translatePlural('List %u service', 'List all %u services', $stats->services_total),
             $stats->services_total
         ))
-    ) ?>:</span>
+    ) ?></span>
 <?php
 $stateBadges = new StateBadges();
 $stateBadges
diff --git a/modules/monitoring/public/css/module.less b/modules/monitoring/public/css/module.less
index fa04397..0df0422 100644
--- a/modules/monitoring/public/css/module.less
+++ b/modules/monitoring/public/css/module.less
@@ -82,11 +82,20 @@
 .hosts-summary,
 .services-summary {
   margin-bottom: 0.5em;
+  background: @gray-lighter;
+  .rounded-corners(@border-radius: 0.4em);
+  line-height: 1.4;
 
   > .hosts-link,
-  > .services-link,
-  > .state-badges {
-    vertical-align: middle;
+  > .services-link {
+    font-weight: bold;
+    display: inline-block;
+    vertical-align: top;
+
+    > a {
+      padding: .095em .25em .095em @vertical-padding;
+      display: inline-block;
+    }
   }
 }
 



More information about the icinga-checkins mailing list