mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-07-13 03:27:39 +03:00
Some small cleanups
This commit is contained in:
parent
04f4538700
commit
c0f494c758
5 changed files with 13 additions and 22 deletions
|
|
@ -42,10 +42,7 @@ const
|
||||||
|
|
||||||
getNotificationMessage = code => {
|
getNotificationMessage = code => {
|
||||||
let key = getKeyByValue(Notification, code);
|
let key = getKeyByValue(Notification, code);
|
||||||
if (key) {
|
return key ? I18N_DATA.NOTIFICATIONS[i18nKey(key).replace('_NOTIFICATION', '_ERROR')] : '';
|
||||||
key = i18nKey(key).replace('_NOTIFICATION', '_ERROR');
|
|
||||||
return I18N_DATA.NOTIFICATIONS[key];
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
export const
|
export const
|
||||||
|
|
|
||||||
|
|
@ -43,10 +43,8 @@ export const
|
||||||
clearTimer = () => {
|
clearTimer = () => {
|
||||||
__themeTimer = setTimeout(() => themeTrigger(SaveSettingsStep.Idle), 1000);
|
__themeTimer = setTimeout(() => themeTrigger(SaveSettingsStep.Idle), 1000);
|
||||||
__themeJson = null;
|
__themeJson = null;
|
||||||
};
|
},
|
||||||
|
url = themeStyle.dataset.href.replace(/(Admin|User)\/-\/[^/]+\//, '$1/-/' + value + '/') + 'Json/';
|
||||||
let url = themeStyle.dataset.href.replace(/(Admin|User)\/-\/[^/]+\//, '$1/-/' + value + '/')
|
|
||||||
+ 'Json/';
|
|
||||||
|
|
||||||
clearTimeout(__themeTimer);
|
clearTimeout(__themeTimer);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -9,17 +9,17 @@ export const ThemeStore = {
|
||||||
userBackgroundHash: ko.observable(''),
|
userBackgroundHash: ko.observable(''),
|
||||||
isMobile: ko.observable($htmlCL.contains('rl-mobile')),
|
isMobile: ko.observable($htmlCL.contains('rl-mobile')),
|
||||||
|
|
||||||
populate: function(){
|
populate: () => {
|
||||||
const themes = Settings.app('themes');
|
const themes = Settings.app('themes');
|
||||||
|
|
||||||
this.themes(isArray(themes) ? themes : []);
|
ThemeStore.themes(isArray(themes) ? themes : []);
|
||||||
this.theme(SettingsGet('Theme'));
|
ThemeStore.theme(SettingsGet('Theme'));
|
||||||
if (!this.isMobile()) {
|
if (!ThemeStore.isMobile()) {
|
||||||
this.userBackgroundName(SettingsGet('UserBackgroundName'));
|
ThemeStore.userBackgroundName(SettingsGet('UserBackgroundName'));
|
||||||
this.userBackgroundHash(SettingsGet('UserBackgroundHash'));
|
ThemeStore.userBackgroundHash(SettingsGet('UserBackgroundHash'));
|
||||||
}
|
}
|
||||||
|
|
||||||
leftPanelDisabled(this.isMobile());
|
leftPanelDisabled(ThemeStore.isMobile());
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -67,12 +67,9 @@ abstract class AbstractConfig implements \JsonSerializable
|
||||||
*/
|
*/
|
||||||
public function Get(string $sSection, string $sName, $mDefault = null)
|
public function Get(string $sSection, string $sName, $mDefault = null)
|
||||||
{
|
{
|
||||||
$mResult = $mDefault;
|
return isset($this->aData[$sSection][$sName][0])
|
||||||
if (isset($this->aData[$sSection][$sName][0]))
|
? $this->aData[$sSection][$sName][0]
|
||||||
{
|
: $mDefault;
|
||||||
$mResult = $this->aData[$sSection][$sName][0];
|
|
||||||
}
|
|
||||||
return $mResult;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
1
vendors/fontastic/styles.css
vendored
1
vendors/fontastic/styles.css
vendored
|
|
@ -17,7 +17,6 @@
|
||||||
font-weight: normal !important;
|
font-weight: normal !important;
|
||||||
font-variant: normal !important;
|
font-variant: normal !important;
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
text-transform: none !important;
|
|
||||||
speak: never;
|
speak: never;
|
||||||
-webkit-font-smoothing: antialiased;
|
-webkit-font-smoothing: antialiased;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue