mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-05 07:27:04 +03:00
Add Simplified Chinese language.
Update language popup. + Merge conflict origin/master
This commit is contained in:
commit
101f956fa8
25 changed files with 1055 additions and 458 deletions
|
|
@ -2266,38 +2266,40 @@ img.mfp-img {
|
|||
0% { transform: none; transform: none; }
|
||||
100% { transform: translate(-32px, 0); transform: translate(-32px, 0); }
|
||||
}
|
||||
.flag-wrapper {
|
||||
width: 24px;
|
||||
height: 16px;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.flag {
|
||||
width: 16px;
|
||||
height: 11px;
|
||||
display: inline-block;
|
||||
background: url(flags.png) no-repeat;
|
||||
}
|
||||
|
||||
.flag.flag-en {background-position: -144px -154px}
|
||||
.flag.flag-en-us {background-position: -144px -154px}
|
||||
.flag.flag-en-gb {background-position: -240px -33px}
|
||||
.flag.flag-en-ca {background-position: -48px -22px}
|
||||
|
||||
.flag.flag-nl, .flag.flag-nl-nl {background-position: -80px -110px}
|
||||
.flag.flag-ru, .flag.flag-ru-ru {background-position: -224px -121px}
|
||||
.flag.flag-de, .flag.flag-de-de {background-position: -80px -33px}
|
||||
.flag.flag-it, .flag.flag-it-it {background-position: -208px -66px}
|
||||
.flag.flag-is, .flag.flag-is-is {background-position: -192px -66px}
|
||||
.flag.flag-lv, .flag.flag-lv-lv {background-position: -112px -88px}
|
||||
|
||||
.flag.flag-fr, .flag.flag-fr-fr, .flag.flag-fr-ca {background-position: -144px -44px}
|
||||
.flag.flag-es, .flag.flag-es-es, .flag.flag-es-la {background-position: -16px -44px}
|
||||
|
||||
.flag.flag-ja, .flag.flag-jp, .flag.flag-ja-jp {background-position: -16px -77px}
|
||||
|
||||
.flag.flag-pt, .flag.flag-pt-pt {background-position: -112px -121px}
|
||||
.flag.flag-pt-br {background-position: -192px -11px}
|
||||
.flag-wrapper {
|
||||
width: 24px;
|
||||
height: 16px;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.flag {
|
||||
width: 16px;
|
||||
height: 11px;
|
||||
display: inline-block;
|
||||
background: url(flags.png) no-repeat;
|
||||
}
|
||||
|
||||
.flag.flag-en {background-position: -144px -154px}
|
||||
.flag.flag-en-us {background-position: -144px -154px}
|
||||
.flag.flag-en-gb {background-position: -240px -33px}
|
||||
.flag.flag-en-ca {background-position: -48px -22px}
|
||||
|
||||
.flag.flag-nl, .flag.flag-nl-nl {background-position: -80px -110px}
|
||||
.flag.flag-ru, .flag.flag-ru-ru {background-position: -224px -121px}
|
||||
.flag.flag-de, .flag.flag-de-de {background-position: -80px -33px}
|
||||
.flag.flag-it, .flag.flag-it-it {background-position: -208px -66px}
|
||||
.flag.flag-is, .flag.flag-is-is {background-position: -192px -66px}
|
||||
.flag.flag-lv, .flag.flag-lv-lv {background-position: -112px -88px}
|
||||
|
||||
.flag.flag-fr, .flag.flag-fr-fr, .flag.flag-fr-ca {background-position: -144px -44px}
|
||||
.flag.flag-es, .flag.flag-es-es, .flag.flag-es-la {background-position: -16px -44px}
|
||||
|
||||
.flag.flag-ja, .flag.flag-jp, .flag.flag-ja-jp {background-position: -16px -77px}
|
||||
|
||||
.flag.flag-pt, .flag.flag-pt-pt {background-position: -112px -121px}
|
||||
.flag.flag-pt-br {background-position: -192px -11px}
|
||||
|
||||
.flag.flag-cn, .flag.flag-zh-tw, .flag.flag-zh-cn, .flag.flag-zh-hk {background-position: -208px -22px}
|
||||
|
||||
/* RainLoop Webmail (c) RainLoop Team | Licensed under CC BY-NC-SA 3.0 */
|
||||
.clearfix {
|
||||
|
|
@ -6384,10 +6386,10 @@ html.rl-no-preview-pane #rl-right .ui-resizable-handle {
|
|||
}
|
||||
.popups .b-languages-content.modal {
|
||||
z-index: 1103;
|
||||
width: 520px;
|
||||
width: 500px;
|
||||
}
|
||||
.popups .b-languages-content.exp {
|
||||
width: 521px;
|
||||
width: 501px;
|
||||
}
|
||||
.popups .b-languages-content .modal-header {
|
||||
background-color: #fff;
|
||||
|
|
@ -6396,7 +6398,7 @@ html.rl-no-preview-pane #rl-right .ui-resizable-handle {
|
|||
display: inline-block;
|
||||
padding: 5px 15px;
|
||||
margin: 2px 5px;
|
||||
width: 200px;
|
||||
width: 180px;
|
||||
background-color: #fff;
|
||||
text-align: left;
|
||||
}
|
||||
|
|
@ -7678,6 +7680,12 @@ html.rl-message-fullscreen .messageView .b-content .buttonFull {
|
|||
.b-admin-right .b-settings-content {
|
||||
padding: 20px;
|
||||
}
|
||||
.b-admin-general .flag-selector {
|
||||
padding-top: 5px;
|
||||
}
|
||||
.b-admin-general .flag-name {
|
||||
border-bottom: 1px dashed #555;
|
||||
}
|
||||
.b-admin-domains .process-place {
|
||||
width: 600px;
|
||||
padding: 14px 0;
|
||||
|
|
|
|||
2
rainloop/v/0.0.0/static/css/app.min.css
vendored
2
rainloop/v/0.0.0/static/css/app.min.css
vendored
File diff suppressed because one or more lines are too long
|
|
@ -1716,11 +1716,13 @@ Utils.microtime = function ()
|
|||
/**
|
||||
*
|
||||
* @param {string} sLanguage
|
||||
* @param {boolean=} bEng = false
|
||||
* @return {string}
|
||||
*/
|
||||
Utils.convertLangName = function (sLanguage)
|
||||
Utils.convertLangName = function (sLanguage, bEng)
|
||||
{
|
||||
return Utils.i18n('LANGS_NAMES/LANG_' + sLanguage.toUpperCase().replace(/[^a-zA-Z0-9]+/, '_'), null, sLanguage);
|
||||
return Utils.i18n('LANGS_NAMES' + (true === bEng ? '_EN' : '') + '/LANG_' +
|
||||
sLanguage.toUpperCase().replace(/[^a-zA-Z0-9]+/, '_'), null, sLanguage);
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -4578,26 +4580,40 @@ function PopupsLanguagesViewModel()
|
|||
this.exp = ko.observable(false);
|
||||
|
||||
this.languages = ko.computed(function () {
|
||||
var sCurrent = RL.data().mainLanguage();
|
||||
return _.map(RL.data().languages(), function (sLanguage) {
|
||||
return {
|
||||
'key': sLanguage,
|
||||
'selected': sLanguage === sCurrent,
|
||||
'selected': ko.observable(false),
|
||||
'fullName': Utils.convertLangName(sLanguage)
|
||||
};
|
||||
});
|
||||
});
|
||||
|
||||
RL.data().mainLanguage.subscribe(function () {
|
||||
this.resetMainLanguage();
|
||||
}, this);
|
||||
}
|
||||
|
||||
Utils.extendAsViewModel('PopupsLanguagesViewModel', PopupsLanguagesViewModel);
|
||||
|
||||
PopupsLanguagesViewModel.prototype.languageEnName = function (sLanguage)
|
||||
{
|
||||
return Utils.convertLangName(sLanguage, true);
|
||||
};
|
||||
|
||||
PopupsLanguagesViewModel.prototype.resetMainLanguage = function ()
|
||||
{
|
||||
var sCurrent = RL.data().mainLanguage();
|
||||
_.each(this.languages(), function (oItem) {
|
||||
oItem['selected'](oItem['key'] === sCurrent);
|
||||
});
|
||||
};
|
||||
|
||||
PopupsLanguagesViewModel.prototype.onShow = function ()
|
||||
{
|
||||
// var self = this;
|
||||
// _.defer(function () {
|
||||
// self.exp(true);
|
||||
// });
|
||||
this.exp(true);
|
||||
|
||||
this.resetMainLanguage();
|
||||
};
|
||||
|
||||
PopupsLanguagesViewModel.prototype.onHide = function ()
|
||||
|
|
@ -4766,12 +4782,21 @@ function AdminGeneral()
|
|||
};
|
||||
});
|
||||
});
|
||||
|
||||
this.mainLanguageFullName = ko.computed(function () {
|
||||
return Utils.convertLangName(this.mainLanguage());
|
||||
}, this);
|
||||
|
||||
this.languagesOptions = ko.computed(function () {
|
||||
return _.map(oData.languages(), function (sLanguage) {
|
||||
var
|
||||
sName = Utils.convertLangName(sLanguage),
|
||||
sEn = Utils.convertLangName(sLanguage, true)
|
||||
;
|
||||
|
||||
return {
|
||||
'optValue': sLanguage,
|
||||
'optText': Utils.convertLangName(sLanguage)
|
||||
'optText': sName + (sEn !== sName ? ' (' + sEn + ')' : '')
|
||||
};
|
||||
});
|
||||
});
|
||||
|
|
@ -4856,6 +4881,11 @@ AdminGeneral.prototype.onBuild = function ()
|
|||
|
||||
}, 50);
|
||||
};
|
||||
|
||||
AdminGeneral.prototype.selectLanguage = function ()
|
||||
{
|
||||
kn.showScreenPopup(PopupsLanguagesViewModel);
|
||||
};
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
|
|
|
|||
|
|
@ -1716,11 +1716,13 @@ Utils.microtime = function ()
|
|||
/**
|
||||
*
|
||||
* @param {string} sLanguage
|
||||
* @param {boolean=} bEng = false
|
||||
* @return {string}
|
||||
*/
|
||||
Utils.convertLangName = function (sLanguage)
|
||||
Utils.convertLangName = function (sLanguage, bEng)
|
||||
{
|
||||
return Utils.i18n('LANGS_NAMES/LANG_' + sLanguage.toUpperCase().replace(/[^a-zA-Z0-9]+/, '_'), null, sLanguage);
|
||||
return Utils.i18n('LANGS_NAMES' + (true === bEng ? '_EN' : '') + '/LANG_' +
|
||||
sLanguage.toUpperCase().replace(/[^a-zA-Z0-9]+/, '_'), null, sLanguage);
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -9613,26 +9615,40 @@ function PopupsLanguagesViewModel()
|
|||
this.exp = ko.observable(false);
|
||||
|
||||
this.languages = ko.computed(function () {
|
||||
var sCurrent = RL.data().mainLanguage();
|
||||
return _.map(RL.data().languages(), function (sLanguage) {
|
||||
return {
|
||||
'key': sLanguage,
|
||||
'selected': sLanguage === sCurrent,
|
||||
'selected': ko.observable(false),
|
||||
'fullName': Utils.convertLangName(sLanguage)
|
||||
};
|
||||
});
|
||||
});
|
||||
|
||||
RL.data().mainLanguage.subscribe(function () {
|
||||
this.resetMainLanguage();
|
||||
}, this);
|
||||
}
|
||||
|
||||
Utils.extendAsViewModel('PopupsLanguagesViewModel', PopupsLanguagesViewModel);
|
||||
|
||||
PopupsLanguagesViewModel.prototype.languageEnName = function (sLanguage)
|
||||
{
|
||||
return Utils.convertLangName(sLanguage, true);
|
||||
};
|
||||
|
||||
PopupsLanguagesViewModel.prototype.resetMainLanguage = function ()
|
||||
{
|
||||
var sCurrent = RL.data().mainLanguage();
|
||||
_.each(this.languages(), function (oItem) {
|
||||
oItem['selected'](oItem['key'] === sCurrent);
|
||||
});
|
||||
};
|
||||
|
||||
PopupsLanguagesViewModel.prototype.onShow = function ()
|
||||
{
|
||||
// var self = this;
|
||||
// _.defer(function () {
|
||||
// self.exp(true);
|
||||
// });
|
||||
this.exp(true);
|
||||
|
||||
this.resetMainLanguage();
|
||||
};
|
||||
|
||||
PopupsLanguagesViewModel.prototype.onHide = function ()
|
||||
|
|
@ -12449,14 +12465,14 @@ function WebMailDataStorage()
|
|||
this.devPassword = '';
|
||||
|
||||
this.accountEmail = ko.observable('');
|
||||
this.accountLogin = ko.observable('');
|
||||
this.accountIncLogin = ko.observable('');
|
||||
this.accountOutLogin = ko.observable('');
|
||||
this.projectHash = ko.observable('');
|
||||
|
||||
this.threading = ko.observable(false);
|
||||
this.lastFoldersHash = '';
|
||||
|
||||
this.remoteSuggestions = false;
|
||||
this.remoteChangePassword = false;
|
||||
|
||||
// system folders
|
||||
this.sentFolder = ko.observable('');
|
||||
|
|
@ -12804,7 +12820,8 @@ WebMailDataStorage.prototype.populateDataOnStart = function()
|
|||
AbstractData.prototype.populateDataOnStart.call(this);
|
||||
|
||||
this.accountEmail(RL.settingsGet('Email'));
|
||||
this.accountLogin(RL.settingsGet('Login'));
|
||||
this.accountIncLogin(RL.settingsGet('IncLogin'));
|
||||
this.accountOutLogin(RL.settingsGet('OutLogin'));
|
||||
this.projectHash(RL.settingsGet('ProjectHash'));
|
||||
|
||||
this.displayName(RL.settingsGet('DisplayName'));
|
||||
|
|
@ -12814,7 +12831,6 @@ WebMailDataStorage.prototype.populateDataOnStart = function()
|
|||
this.lastFoldersHash = RL.local().get(Enums.ClientSideKeyName.FoldersLashHash) || '';
|
||||
|
||||
this.remoteSuggestions = !!RL.settingsGet('RemoteSuggestions');
|
||||
this.remoteChangePassword = !!RL.settingsGet('RemoteChangePassword');
|
||||
|
||||
this.devEmail = RL.settingsGet('DevEmail');
|
||||
this.devLogin = RL.settingsGet('DevLogin');
|
||||
|
|
@ -15795,7 +15811,7 @@ RainLoopApp.prototype.bootstart = function ()
|
|||
bTwitter = this.settingsGet('AllowTwitterSocial')
|
||||
;
|
||||
|
||||
if (!this.settingsGet('RemoteChangePassword'))
|
||||
if (!this.settingsGet('AllowChangePassword'))
|
||||
{
|
||||
Utils.removeSettingsViewModel(SettingsChangePasswordScreen);
|
||||
}
|
||||
|
|
|
|||
14
rainloop/v/0.0.0/static/js/app.min.js
vendored
14
rainloop/v/0.0.0/static/js/app.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue