|
|
|
|
@ -177,8 +177,11 @@ class DefaultTheme implements ITheme { |
|
|
|
|
// to be used for legacy reasons only. Use inline |
|
|
|
|
// svg with proper css variable instead or material |
|
|
|
|
// design icons. |
|
|
|
|
'--primary-invert-if-bright' => $this->util->invertTextColor($this->primaryColor) ? 'invert(100%)' : 'unset', |
|
|
|
|
'--background-invert-if-dark' => 'unset', |
|
|
|
|
// ⚠️ Using 'no' as a value to make sure we specify an |
|
|
|
|
// invalid one with no fallback. 'unset' could here fallback to some |
|
|
|
|
// other theme with media queries |
|
|
|
|
'--primary-invert-if-bright' => $this->util->invertTextColor($this->primaryColor) ? 'invert(100%)' : 'no', |
|
|
|
|
'--background-invert-if-dark' => 'no', |
|
|
|
|
]; |
|
|
|
|
|
|
|
|
|
// Register image variables only if custom-defined |
|
|
|
|
@ -187,7 +190,7 @@ class DefaultTheme implements ITheme { |
|
|
|
|
if ($this->imageManager->hasImage($image)) { |
|
|
|
|
// If primary as background has been request, let's not define the background image |
|
|
|
|
if ($image === 'background' && $backgroundDeleted) { |
|
|
|
|
$variables["--image-background-plain"] = true; |
|
|
|
|
$variables["--image-background-plain"] = 'true'; |
|
|
|
|
continue; |
|
|
|
|
} else if ($image === 'background') { |
|
|
|
|
$variables['--image-background-size'] = 'cover'; |
|
|
|
|
@ -197,7 +200,7 @@ class DefaultTheme implements ITheme { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if ($hasCustomLogoHeader) { |
|
|
|
|
$variables["--image-logoheader-custom"] = true; |
|
|
|
|
$variables["--image-logoheader-custom"] = 'true'; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
return $variables; |
|
|
|
|
|