aboutsummaryrefslogtreecommitdiffstats
path: root/apps/theming
diff options
context:
space:
mode:
authorChristopher Ng <chrng8@gmail.com>2023-06-05 17:28:19 -0700
committerChristopher Ng <chrng8@gmail.com>2023-06-06 08:47:56 -0700
commitfe098ff6fb1d1fbbfbc5bb2774237b529f49b08d (patch)
tree9fcd545c77264e9695f1cbe3b8d55252e84a1346 /apps/theming
parent27ebaea10c3b7868379150d0e44e17baefb3eb00 (diff)
downloadnextcloud-server-fe098ff6fb1d1fbbfbc5bb2774237b529f49b08d.tar.gz
nextcloud-server-fe098ff6fb1d1fbbfbc5bb2774237b529f49b08d.zip
enh(theming): Warning contrast
Signed-off-by: Christopher Ng <chrng8@gmail.com>
Diffstat (limited to 'apps/theming')
-rw-r--r--apps/theming/css/default.css7
-rw-r--r--apps/theming/lib/Themes/DarkTheme.php5
-rw-r--r--apps/theming/lib/Themes/DefaultTheme.php8
3 files changed, 14 insertions, 6 deletions
diff --git a/apps/theming/css/default.css b/apps/theming/css/default.css
index a305faba543..cb4a12fce10 100644
--- a/apps/theming/css/default.css
+++ b/apps/theming/css/default.css
@@ -21,9 +21,10 @@
--color-error-rgb: 233,50,45;
--color-error-hover: #ed5a56;
--color-error-text: #e7201b;
- --color-warning: #eca700;
- --color-warning-rgb: 236,167,0;
- --color-warning-hover: #efb832;
+ --color-warning: #c28900;
+ --color-warning-rgb: 194,137,0;
+ --color-warning-hover: #cea032;
+ --color-warning-text: #996c00;
--color-success: #46ba61;
--color-success-rgb: 70,186,97;
--color-success-hover: #6ac780;
diff --git a/apps/theming/lib/Themes/DarkTheme.php b/apps/theming/lib/Themes/DarkTheme.php
index 6c90c8e5aa5..85e4d4708cc 100644
--- a/apps/theming/lib/Themes/DarkTheme.php
+++ b/apps/theming/lib/Themes/DarkTheme.php
@@ -60,6 +60,7 @@ class DarkTheme extends DefaultTheme implements ITheme {
$colorBoxShadowRGB = join(',', $this->util->hexToRGB($colorBoxShadow));
$colorError = '#e9322d';
+ $colorWarning = '#c28900';
return array_merge(
$defaultVariables,
@@ -88,6 +89,10 @@ class DarkTheme extends DefaultTheme implements ITheme {
'--color-error-rgb' => join(',', $this->util->hexToRGB($colorError)),
'--color-error-hover' => $this->util->mix($colorError, $colorMainBackground, 60),
'--color-error-text' => $this->util->lighten($colorError, 3),
+ '--color-warning' => $colorWarning,
+ '--color-warning-rgb' => join(',', $this->util->hexToRGB($colorWarning)),
+ '--color-warning-hover' => $this->util->mix($colorWarning, $colorMainBackground, 60),
+ '--color-warning-text' => $colorWarning,
// used for the icon loading animation
'--color-loading-light' => '#777',
diff --git a/apps/theming/lib/Themes/DefaultTheme.php b/apps/theming/lib/Themes/DefaultTheme.php
index 3df6ce081f1..3238ed00564 100644
--- a/apps/theming/lib/Themes/DefaultTheme.php
+++ b/apps/theming/lib/Themes/DefaultTheme.php
@@ -110,6 +110,7 @@ class DefaultTheme implements ITheme {
$colorBoxShadowRGB = join(',', $this->util->hexToRGB($colorBoxShadow));
$colorError = '#e9322d';
+ $colorWarning = '#c28900';
$variables = [
'--color-main-background' => $colorMainBackground,
@@ -144,9 +145,10 @@ class DefaultTheme implements ITheme {
'--color-error-rgb' => join(',', $this->util->hexToRGB($colorError)),
'--color-error-hover' => $this->util->mix($colorError, $colorMainBackground, 60),
'--color-error-text' => $this->util->darken($colorError, 4),
- '--color-warning' => '#eca700',
- '--color-warning-rgb' => join(',', $this->util->hexToRGB('#eca700')),
- '--color-warning-hover' => $this->util->mix('#eca700', $colorMainBackground, 60),
+ '--color-warning' => $colorWarning,
+ '--color-warning-rgb' => join(',', $this->util->hexToRGB($colorWarning)),
+ '--color-warning-hover' => $this->util->mix($colorWarning, $colorMainBackground, 60),
+ '--color-warning-text' => $this->util->darken($colorWarning, 8),
'--color-success' => '#46ba61',
'--color-success-rgb' => join(',', $this->util->hexToRGB('#46ba61')),
'--color-success-hover' => $this->util->mix('#46ba61', $colorMainBackground, 60),