From 548058650a42d864f001855c040dc794a761f916 Mon Sep 17 00:00:00 2001 From: Bernd Erk Date: Thu, 6 Nov 2014 15:49:26 +0100 Subject: [PATCH] Fixed Plugin output and box-border --- .../views/helpers/PluginOutput.php | 6 ++---- modules/monitoring/public/css/module.less | 19 +++++++++++++++++++ public/css/icinga/layout-structure.less | 4 +++- public/css/icinga/main-content.less | 11 ++++++----- public/css/icinga/monitoring-colors.less | 9 ++++++--- public/css/icinga/tabs.less | 4 ++-- public/css/icinga/widgets.less | 1 - 7 files changed, 38 insertions(+), 16 deletions(-) diff --git a/modules/monitoring/application/views/helpers/PluginOutput.php b/modules/monitoring/application/views/helpers/PluginOutput.php index 3cd36c46f..b4a6138ba 100644 --- a/modules/monitoring/application/views/helpers/PluginOutput.php +++ b/modules/monitoring/application/views/helpers/PluginOutput.php @@ -19,8 +19,7 @@ class Zend_View_Helper_PluginOutput extends Zend_View_Helper_Abstract ); } elseif (preg_match('~\\\n~', $output)) { // Plaintext - $output = '
'
+            $output = '
'
                . preg_replace(
               '~\\\n~', "\n", preg_replace(
                 '~\\\n\\\n~', "\n",
@@ -33,8 +32,7 @@ class Zend_View_Helper_PluginOutput extends Zend_View_Helper_Abstract
               )
             ) . '
'; } else { - $output = '
'
+            $output = '
'
                . preg_replace('~\@{6,}~', '@@@@@@',
                 $this->view->escape($output)
             ) . '
'; diff --git a/modules/monitoring/public/css/module.less b/modules/monitoring/public/css/module.less index 7c3d1403f..a62a76eee 100644 --- a/modules/monitoring/public/css/module.less +++ b/modules/monitoring/public/css/module.less @@ -14,6 +14,24 @@ table.action.comments td a, table.action.downtimes td a { width: 16em; } +p.pluginoutput { + font-size: 0.9em; + overflow: auto; + width: 100%; + white-space: pre-wrap; +} + +pre.pluginoutput { + font-family: Courier; + background: #eee; + font-size: 0.7em; + overflow: auto; + white-space: pre-wrap; + margin: 0em; + padding: 1em; + margin-bottom: 0.5em; +} + table.objecthistory td { font-size: 0.8em; } @@ -58,6 +76,7 @@ h3.tinystatesummary { line-height: 2em; font-size: 0.95em; padding-left: 1em; + margin-right: 1em; background-color: #eee; color: #666; border: 1px solid #d9d9d9; diff --git a/public/css/icinga/layout-structure.less b/public/css/icinga/layout-structure.less index cdbe9e417..43c030154 100644 --- a/public/css/icinga/layout-structure.less +++ b/public/css/icinga/layout-structure.less @@ -101,7 +101,7 @@ html { } #layout.twocols #main > .container { - width: 50%; + width: 49%; } @@ -310,10 +310,12 @@ html { } #layout.twocols #col2 { + border-left: 1px solid #d9d9d9; display: block; } #layout.threecols #col3 { + border-left: 1px solid #d9d9d9; display: block; } diff --git a/public/css/icinga/main-content.less b/public/css/icinga/main-content.less index e626aad22..d280d56e8 100644 --- a/public/css/icinga/main-content.less +++ b/public/css/icinga/main-content.less @@ -67,6 +67,7 @@ img.icon { } table.avp { + color: #555; table-layout: auto; width: 100%; font-size: 0.9em; @@ -78,11 +79,11 @@ table.avp a { } table.avp > tbody > tr > th { - text-align: right; + text-align: left; margin: 0; - width: 13em; + width: 10em; vertical-align: top; - line-height: 2em; + line-height: 1.8em; } table.avp > tbody > tr > td { @@ -91,11 +92,11 @@ table.avp > tbody > tr > td { word-break: break-all; vertical-align: top; - padding: 0em 0em 0em 0.5em; + padding: 0em 0em 0em 0em; } table.avp.newsection, table.avp tr.newsection { - border-top: 1px solid #555; + border-top: 1px solid #d9d9d9; } .content table.avp dd, .content table.avp dd { diff --git a/public/css/icinga/monitoring-colors.less b/public/css/icinga/monitoring-colors.less index c7a1c7054..5c658f1d5 100644 --- a/public/css/icinga/monitoring-colors.less +++ b/public/css/icinga/monitoring-colors.less @@ -20,11 +20,13 @@ table.colors td { /* Action table */ table.action { + font-size: 0.9em; border-collapse: separate; border-spacing: 1px; width: 100%; table-layout: fixed; margin: 0; + color: #666; } table.action th { @@ -57,6 +59,7 @@ table.action td .pluginoutput { table.action td a { color: inherit; text-decoration: none; + color: #555; } table.action td a:hover { @@ -131,7 +134,7 @@ tr.state.handled td.state, tr.state.ok td.state, tr.state.up td.state, tr.state. } tr[href].active { - background-color: #ddd; + background-color: #eee; color: black; } @@ -196,7 +199,7 @@ tr.state.handled td.state { tr[href]:hover, tr.state[href]:hover td.state { color: white; - background-color: #555; + background-color: #eee; } tr.state.ok[href]:hover, tr.state.up[href]:hover { @@ -279,7 +282,7 @@ a.critical { padding: 0.4em; margin: 0.4em; - background: #555; + background: #eee; border-radius: 0.4em; -moz-border-radius: 0.4em; } diff --git a/public/css/icinga/tabs.less b/public/css/icinga/tabs.less index 4fa3d38dc..c3e25e544 100644 --- a/public/css/icinga/tabs.less +++ b/public/css/icinga/tabs.less @@ -2,12 +2,12 @@ // {{{ICINGA_LICENSE_HEADER}}} ul.tabs { - margin-left: 0em; padding: 1em 0 0 0; list-style-type: inside; } .controls ul.tabs { + margin-left: 0em; margin-top: -3.6em; height: 2.6em; overflow: hidden; @@ -108,7 +108,7 @@ ul.tabs ul.dropdown-menu { ul.tabs ul.dropdown-menu li a { color: #555; - margin: 1em; + margin: 0em; } ul.tabs ul.dropdown-menu li a:focus { diff --git a/public/css/icinga/widgets.less b/public/css/icinga/widgets.less index be9705640..4adceec45 100644 --- a/public/css/icinga/widgets.less +++ b/public/css/icinga/widgets.less @@ -196,7 +196,6 @@ ul.tree li a.error:hover { margin-right: 0.6em; } - li li .badge-container { /* fix margin for smaller font-size of list elements