Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Molakvoæ <skjnldsv@protonmail.com>2022-05-20 10:06:29 +0300
committerJohn Molakvoæ (Rebase PR Action) <skjnldsv@users.noreply.github.com>2022-05-31 20:27:12 +0300
commit20efadff5fa0b156c65f9dddc7e72b65d6f6a918 (patch)
tree287013060545e0f7044bd9a2153352fcb912d1c6 /apps/theming
parent3638e65027afad9f51676ba7bb6feea2ea4a5c88 (diff)
Properly calculate primary element based on background luminancefix/theming-colours-primary-24
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Diffstat (limited to 'apps/theming')
-rw-r--r--apps/theming/lib/ThemingDefaults.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/theming/lib/ThemingDefaults.php b/apps/theming/lib/ThemingDefaults.php
index 3d7aaee2064..1001cb78c18 100644
--- a/apps/theming/lib/ThemingDefaults.php
+++ b/apps/theming/lib/ThemingDefaults.php
@@ -315,7 +315,7 @@ class ThemingDefaults extends \OC_Defaults {
/**
* @return array scss variables to overwrite
*/
- public function getScssVariables() {
+ public function getScssVariables(bool $brightBackground = true) {
$cacheBuster = $this->config->getAppValue('theming', 'cachebuster', '0');
$cache = $this->cacheFactory->createDistributed('theming-' . $cacheBuster . '-' . $this->urlGenerator->getBaseUrl());
if ($value = $cache->get('getScssVariables')) {
@@ -339,7 +339,7 @@ class ThemingDefaults extends \OC_Defaults {
if ($this->config->getAppValue('theming', 'color', '') !== '') {
$variables['color-primary'] = $this->getColorPrimary();
$variables['color-primary-text'] = $this->getTextColorPrimary();
- $variables['color-primary-element'] = $this->util->elementColor($this->getColorPrimary());
+ $variables['color-primary-element'] = $this->util->elementColor($this->getColorPrimary(), $brightBackground);
}
if ($this->config->getAppValue('theming', 'backgroundMime', '') === 'backgroundColor') {