From 231f48153722629aafb39234d52288fd485fd737 Mon Sep 17 00:00:00 2001 From: Igor Scheller Date: Mon, 9 Aug 2021 23:32:24 +0200 Subject: [PATCH] Styling optimizations (esp. alerts) and other fixes --- includes/sys_template.php | 2 +- resources/assets/themes/dark.scss | 3 +++ resources/assets/themes/theme10.scss | 4 ++-- resources/assets/themes/theme4.scss | 2 ++ resources/assets/themes/theme6.scss | 2 ++ resources/assets/themes/theme7.scss | 2 +- resources/assets/themes/theme8.scss | 4 ++-- resources/assets/themes/theme9.scss | 4 ++-- resources/views/pages/design.twig | 3 ++- 9 files changed, 17 insertions(+), 9 deletions(-) diff --git a/includes/sys_template.php b/includes/sys_template.php index 9102a544..c5eb3835 100644 --- a/includes/sys_template.php +++ b/includes/sys_template.php @@ -393,7 +393,7 @@ function render_table($columns, $rows, $data = true) */ function button($href, $label, $class = '') { - if (!Str::contains(Str::remove(['btn-sm', 'btn-xl'], $class), 'btn-')) { + if (!Str::contains(str_replace(['btn-sm', 'btn-xl'], '', $class), 'btn-')) { $class = 'btn-secondary' . ($class ? ' ' . $class : ''); } diff --git a/resources/assets/themes/dark.scss b/resources/assets/themes/dark.scss index 7faeffb8..408d6165 100644 --- a/resources/assets/themes/dark.scss +++ b/resources/assets/themes/dark.scss @@ -1,3 +1,6 @@ // All dark themes $input-group-addon-color: #222; $input-disabled-bg: #111; +$nav-tabs-link-active-color: #ADAFAE; +$alert-bg-scale: 70%; + diff --git a/resources/assets/themes/theme10.scss b/resources/assets/themes/theme10.scss index cbc4f615..5bb46590 100644 --- a/resources/assets/themes/theme10.scss +++ b/resources/assets/themes/theme10.scss @@ -27,7 +27,7 @@ $text-muted: $primary; } strong { - font-weight: lighter; + font-weight: normal; color: $brand-primary; text-shadow: 0 0 10px $brand-primary, @@ -40,7 +40,7 @@ $text-muted: $primary; } h1 { - font-weight: lighter; + font-weight: normal; color: $brand-primary; text-shadow: 0 0 10px $brand-primary; diff --git a/resources/assets/themes/theme4.scss b/resources/assets/themes/theme4.scss index a976e3f6..6ec8b599 100644 --- a/resources/assets/themes/theme4.scss +++ b/resources/assets/themes/theme4.scss @@ -12,6 +12,7 @@ $gray-lighter: #ADAFAE; $brand-primary: rgb(0, 156, 139); $primary: rgb(0, 156, 139); +$secondary: #424242; $brand-success: rgb(141, 193, 35); $success: rgb(141, 193, 35); $brand-info: rgb(70, 71, 73); @@ -26,6 +27,7 @@ $text-muted: lighten($gray-light, 25%); //== changed Scaffolding $body-bg: #1d1d1b; +$alert-bg-scale: 0%; //== changed Buttons diff --git a/resources/assets/themes/theme6.scss b/resources/assets/themes/theme6.scss index e1084bf9..3de34996 100644 --- a/resources/assets/themes/theme6.scss +++ b/resources/assets/themes/theme6.scss @@ -23,6 +23,8 @@ $danger: rgb(255, 102, 0); $secondary: #424242; +$alert-bg-scale: 0%; + .badge.bg-warning, .progress-bar.progress-bar-warning { color: #000; } diff --git a/resources/assets/themes/theme7.scss b/resources/assets/themes/theme7.scss index 2876c077..12c4918d 100644 --- a/resources/assets/themes/theme7.scss +++ b/resources/assets/themes/theme7.scss @@ -147,7 +147,7 @@ $label-link-hover-color: $brand-primary; $headings-small-color: $gray-light; -$alert-bg-scale: 0; +$alert-bg-scale: 0%; $alert-border-scale: 0; $alert-color-scale: 0; diff --git a/resources/assets/themes/theme8.scss b/resources/assets/themes/theme8.scss index ed536cc2..5f49b1bd 100644 --- a/resources/assets/themes/theme8.scss +++ b/resources/assets/themes/theme8.scss @@ -26,7 +26,7 @@ $text-muted: $primary; } strong { - font-weight: lighter; + font-weight: normal; color: $brand-primary; text-shadow: 0 0 10px $brand-primary, @@ -39,7 +39,7 @@ $text-muted: $primary; } h1 { - font-weight: lighter; + font-weight: normal; color: $brand-primary; text-shadow: 0 0 10px $brand-primary; diff --git a/resources/assets/themes/theme9.scss b/resources/assets/themes/theme9.scss index 254f3b25..b140793a 100644 --- a/resources/assets/themes/theme9.scss +++ b/resources/assets/themes/theme9.scss @@ -27,7 +27,7 @@ $text-muted: $primary; } strong { - font-weight: lighter; + font-weight: normal; color: $brand-primary; text-shadow: 0 0 10px $brand-primary, @@ -40,7 +40,7 @@ $text-muted: $primary; } h1 { - font-weight: lighter; + font-weight: normal; color: $brand-primary; text-shadow: 0 0 10px $brand-primary; diff --git a/resources/views/pages/design.twig b/resources/views/pages/design.twig index 204ab886..69b94df4 100644 --- a/resources/views/pages/design.twig +++ b/resources/views/pages/design.twig @@ -69,7 +69,8 @@