1
0
mirror of https://github.com/mailcow/mailcow-dockerized.git synced 2024-12-12 10:45:14 +02:00

[SOGo] Override more theme options to prevent occasional theme switching on login

This commit is contained in:
André 2018-07-15 16:34:25 +02:00
parent 9017f3f83c
commit b45b9bc5cf
2 changed files with 47 additions and 5 deletions

View File

@ -13,6 +13,27 @@
function configure($mdThemingProvider) { function configure($mdThemingProvider) {
// Overwrite values to prevent flipping colors on login screen // Overwrite values to prevent flipping colors on login screen
$mdThemingProvider.definePalette('mailcow-blue', {
'50': 'E3F2FD',
'100': 'BBDEFB',
'200': '90CAF9',
'300': '64B5F6',
'400': '42A5F5',
'500': '2196F3',
'600': '1E88E5',
'700': '1976D2',
'800': '1565C0',
'900': '0D47A1',
'1000': '0D47A1',
'A100': '82B1FF',
'A200': '448AFF',
'A400': '2979ff',
'A700': '2962ff',
'contrastDefaultColor': 'dark',
'contrastLightColors': ['700', '800', '900'],
'contrastDarkColors': undefined
});
$mdThemingProvider.definePalette('sogo-green', { $mdThemingProvider.definePalette('sogo-green', {
'50': 'E3F2FD', '50': 'E3F2FD',
'100': 'BBDEFB', '100': 'BBDEFB',
@ -34,17 +55,38 @@
'contrastDarkColors': undefined 'contrastDarkColors': undefined
}); });
$mdThemingProvider.definePalette('default', {
'50': 'E3F2FD',
'100': 'BBDEFB',
'200': '90CAF9',
'300': '64B5F6',
'400': '42A5F5',
'500': '2196F3',
'600': '1E88E5',
'700': '1976D2',
'800': '1565C0',
'900': '0D47A1',
'1000': '0D47A1',
'A100': '82B1FF',
'A200': '448AFF',
'A400': '2979ff',
'A700': '2962ff',
'contrastDefaultColor': 'dark',
'contrastLightColors': ['700', '800', '900'],
'contrastDarkColors': undefined
});
/** /**
* Define the Alternative theme * Define the Alternative theme
*/ */
$mdThemingProvider.theme('mailcow') $mdThemingProvider.theme('mailcow')
.primaryPalette('sogo-green', { .primaryPalette('mailcow-blue', {
'default': '700', // top toolbar 'default': '700', // top toolbar
'hue-1': '500', 'hue-1': '500',
'hue-2': '700', // sidebar toolbar 'hue-2': '700', // sidebar toolbar
'hue-3': 'A700' 'hue-3': 'A700'
}) })
.accentPalette('sogo-green', { .accentPalette('mailcow-blue', {
'default': '800', // fab buttons 'default': '800', // fab buttons
'hue-1': '50', // center list toolbar 'hue-1': '50', // center list toolbar
'hue-2': '500', 'hue-2': '500',
@ -57,13 +99,13 @@
'hue-3': '300' 'hue-3': '300'
}); });
$mdThemingProvider.theme('default') $mdThemingProvider.theme('default')
.primaryPalette('sogo-green', { .primaryPalette('mailcow-blue', {
'default': '700', // top toolbar 'default': '700', // top toolbar
'hue-1': '500', 'hue-1': '500',
'hue-2': '700', // sidebar toolbar 'hue-2': '700', // sidebar toolbar
'hue-3': 'A200' 'hue-3': 'A200'
}) })
.accentPalette('sogo-green', { .accentPalette('mailcow-blue', {
'default': '800', // fab buttons 'default': '800', // fab buttons
'hue-1': '50', // center list toolbar 'hue-1': '50', // center list toolbar
'hue-2': '500', 'hue-2': '500',

View File

@ -146,7 +146,7 @@ services:
- phpfpm - phpfpm
sogo-mailcow: sogo-mailcow:
image: mailcow/sogo:1.28 image: mailcow/sogo:1.29
build: ./data/Dockerfiles/sogo build: ./data/Dockerfiles/sogo
environment: environment:
- DBNAME=${DBNAME} - DBNAME=${DBNAME}