From 039fdfc8af93271008c199d0cbfa2cead6133d6f Mon Sep 17 00:00:00 2001 From: Johannes Meyer Date: Wed, 23 Jun 2021 11:27:23 +0200 Subject: [PATCH] Integrate light theme's `@text-color` using a media query --- modules/doc/public/css/module.less | 3 ++- modules/monitoring/public/css/module.less | 7 ++++--- modules/monitoring/public/css/service-grid.less | 4 ++-- public/css/icinga/about.less | 4 ++-- public/css/icinga/base.less | 6 ++++++ public/css/icinga/health.less | 2 +- public/css/icinga/layout.less | 4 ++-- public/css/icinga/main.less | 2 +- public/css/icinga/setup.less | 2 +- public/css/icinga/tabs.less | 4 ++-- public/css/icinga/widgets.less | 8 ++++---- public/css/themes/icinga-light-theme.less | 2 -- 12 files changed, 27 insertions(+), 21 deletions(-) diff --git a/modules/doc/public/css/module.less b/modules/doc/public/css/module.less index fb0916db2..a027e1e86 100644 --- a/modules/doc/public/css/module.less +++ b/modules/doc/public/css/module.less @@ -28,7 +28,8 @@ pre > code { font-weight: @font-weight-bold; &:hover { - border-bottom: 1px @text-color solid; + border-bottom: 1px solid; + .var(border-bottom-color, text-color); text-decoration: none; } } diff --git a/modules/monitoring/public/css/module.less b/modules/monitoring/public/css/module.less index 56809fb77..40f735d8d 100644 --- a/modules/monitoring/public/css/module.less +++ b/modules/monitoring/public/css/module.less @@ -158,7 +158,7 @@ color: @text-color-light; > a { - color: @text-color; + .var(color, text-color); letter-spacing: normal; font-weight: bold; } @@ -401,7 +401,7 @@ div.box.stats { max-width: 50em; border: 1px solid @gray-lighter; border-left: 15px solid @gray; - color: @text-color; + .var(color, text-color); } .stats > .boxview > div.box { @@ -699,7 +699,8 @@ form.instance-features span.description, form.object-features span.description { border-bottom: 1px @gray-light dotted; &:hover { - border-bottom: 1px @text-color solid; + border-bottom: 1px solid; + .var(border-bottom-color, text-color); text-decoration: none; } } diff --git a/modules/monitoring/public/css/service-grid.less b/modules/monitoring/public/css/service-grid.less index 2501afb1f..3ab212843 100644 --- a/modules/monitoring/public/css/service-grid.less +++ b/modules/monitoring/public/css/service-grid.less @@ -33,7 +33,7 @@ font-size: 130%; a { - color: @text-color; + .var(color, text-color); outline: none; &:hover { @@ -72,4 +72,4 @@ form.filter-toggle { input[type="checkbox"]:checked ~ label { color: inherit; } -} \ No newline at end of file +} diff --git a/public/css/icinga/about.less b/public/css/icinga/about.less index de151fe97..caf24032b 100644 --- a/public/css/icinga/about.less +++ b/public/css/icinga/about.less @@ -7,7 +7,7 @@ .about-social i { font-size: 1.7em; - color: @text-color; + .var(color, text-color); } .about-social i:hover { @@ -23,7 +23,7 @@ margin: 0.5em; padding: 0; font-size: 5em; - color: @text-color; + .var(color, text-color); } .about-links i:hover { diff --git a/public/css/icinga/base.less b/public/css/icinga/base.less index 14eeaead3..81c9a1d99 100644 --- a/public/css/icinga/base.less +++ b/public/css/icinga/base.less @@ -110,6 +110,12 @@ --menu-bg-color: #DEECF1; --menu-hover-bg-color: fade(#DEECF1, 50%); --menu-search-hover-bg-color: darken(#DEECF1, 20%); + + --text-color: #535353; + --text-color-light: fade(#535353, 75%); + --link-color: #535353; + --menu-active-color: #535353; + --menu-flyout-color: #535353; } } diff --git a/public/css/icinga/health.less b/public/css/icinga/health.less index 402e63a41..b2efed065 100644 --- a/public/css/icinga/health.less +++ b/public/css/icinga/health.less @@ -5,7 +5,7 @@ color: @text-color-light; span { - color: @text-color; + .var(color, text-color); } } diff --git a/public/css/icinga/layout.less b/public/css/icinga/layout.less index d94fa9fe2..b5ffad512 100644 --- a/public/css/icinga/layout.less +++ b/public/css/icinga/layout.less @@ -82,7 +82,7 @@ #layout { .var(background-color, body-bg-color); - color: @text-color; + .var(color, text-color); font-family: @font-family; } @@ -204,7 +204,7 @@ } #notifications > li { - color: @text-color; + .var(color, text-color); display: block; line-height: 2.5em; border-left: .5em solid @gray-light; diff --git a/public/css/icinga/main.less b/public/css/icinga/main.less index 208effc85..90a0b091d 100644 --- a/public/css/icinga/main.less +++ b/public/css/icinga/main.less @@ -387,7 +387,7 @@ a:hover > .icon-cancel { > tbody > tr > th { font-weight: bold; - color: @text-color; + .var(color, text-color); } .missing { diff --git a/public/css/icinga/setup.less b/public/css/icinga/setup.less index ae985bd0c..9395c9614 100644 --- a/public/css/icinga/setup.less +++ b/public/css/icinga/setup.less @@ -376,7 +376,7 @@ form#setup_requirements { padding: 0.2em; margin: -1em -1em 1em; text-align: center; - color: @text-color; + .var(color, text-color); background-color: #f6fafa; border: 1px solid lightgrey; } diff --git a/public/css/icinga/tabs.less b/public/css/icinga/tabs.less index 666915376..0cdc1eda1 100644 --- a/public/css/icinga/tabs.less +++ b/public/css/icinga/tabs.less @@ -38,7 +38,7 @@ &.active > a, > a:focus { .var(background-color, body-bg-color); - color: @text-color; + .var(color, text-color); } } @@ -56,7 +56,7 @@ .tabs > li > .refresh-container-control:focus, .tabs > li > .refresh-container-control:hover { .var(background-color, body-bg-color); - color: @text-color; + .var(color, text-color); text-decoration: none; } diff --git a/public/css/icinga/widgets.less b/public/css/icinga/widgets.less index b1ce79cb7..88132bc30 100644 --- a/public/css/icinga/widgets.less +++ b/public/css/icinga/widgets.less @@ -202,7 +202,7 @@ table.multiselect tr[href] td { padding: .5em; border: none; background: none; - color: @text-color; + .var(color, text-color); &:hover, &:focus { color: @icinga-blue; @@ -414,7 +414,7 @@ ul.tree li a.error { } ul.tree li a:hover { - color: @text-color; + .var(color, text-color); text-decoration: underline; } @@ -561,7 +561,7 @@ ul.tree li a.error:hover { .donut-label { font-weight: bold; - fill: @text-color; + .var(fill, text-color); } .donut-label { @@ -584,7 +584,7 @@ ul.tree li a.error:hover { } .donut-label-small { - fill: @text-color; + .var(fill, text-color); font-size: 1.2em; text-anchor: middle; -moz-transform: translateY(0.35em); diff --git a/public/css/themes/icinga-light-theme.less b/public/css/themes/icinga-light-theme.less index 4e60dc7da..4f2ce5537 100644 --- a/public/css/themes/icinga-light-theme.less +++ b/public/css/themes/icinga-light-theme.less @@ -5,8 +5,6 @@ @gray-lighter: #EEEEEE; @gray-lightest: #F7F7F7; -@text-color: #535353; - @menu-color: #676767; @menu-active-bg-color: #EDF7FC;