mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-07-13 03:27:39 +03:00
Release fixes
This commit is contained in:
parent
6576eee3c8
commit
44566aad4b
9 changed files with 51 additions and 71 deletions
|
|
@ -140,7 +140,10 @@
|
||||||
if (this.editor)
|
if (this.editor)
|
||||||
{
|
{
|
||||||
this.modeToggle(true);
|
this.modeToggle(true);
|
||||||
this.editor.setData(sHtml);
|
|
||||||
|
try {
|
||||||
|
this.editor.setData(sHtml);
|
||||||
|
} catch (e) {}
|
||||||
|
|
||||||
if (bFocus)
|
if (bFocus)
|
||||||
{
|
{
|
||||||
|
|
@ -160,7 +163,9 @@
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this.editor.setData(sPlain);
|
try {
|
||||||
|
this.editor.setData(sPlain);
|
||||||
|
} catch (e) {}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bFocus)
|
if (bFocus)
|
||||||
|
|
@ -273,7 +278,9 @@
|
||||||
{
|
{
|
||||||
if (this.editor)
|
if (this.editor)
|
||||||
{
|
{
|
||||||
this.editor.focus();
|
try {
|
||||||
|
this.editor.focus();
|
||||||
|
} catch (e) {}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,6 @@
|
||||||
|
|
||||||
this.displayName = AccountStore.displayName;
|
this.displayName = AccountStore.displayName;
|
||||||
this.signature = AccountStore.signature;
|
this.signature = AccountStore.signature;
|
||||||
this.signatureToAll = AccountStore.signatureToAll;
|
|
||||||
this.replyTo = AccountStore.replyTo;
|
this.replyTo = AccountStore.replyTo;
|
||||||
|
|
||||||
this.signatureDom = ko.observable(null);
|
this.signatureDom = ko.observable(null);
|
||||||
|
|
@ -219,12 +218,6 @@
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
AccountStore.signatureToAll.subscribe(function (bValue) {
|
|
||||||
Remote.saveSettings(null, {
|
|
||||||
'SignatureToAll': bValue ? '1' : '0'
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
}, 50);
|
}, 50);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,6 @@
|
||||||
|
|
||||||
this.displayName = AccountStore.displayName;
|
this.displayName = AccountStore.displayName;
|
||||||
this.signature = AccountStore.signature;
|
this.signature = AccountStore.signature;
|
||||||
this.signatureToAll = AccountStore.signatureToAll;
|
|
||||||
this.replyTo = AccountStore.replyTo;
|
this.replyTo = AccountStore.replyTo;
|
||||||
|
|
||||||
this.signatureDom = ko.observable(null);
|
this.signatureDom = ko.observable(null);
|
||||||
|
|
@ -90,12 +89,6 @@
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
AccountStore.signatureToAll.subscribe(function (bValue) {
|
|
||||||
Remote.saveSettings(null, {
|
|
||||||
'SignatureToAll': bValue ? '1' : '0'
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
}, 50);
|
}, 50);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,6 @@
|
||||||
this.displayName = ko.observable('');
|
this.displayName = ko.observable('');
|
||||||
this.replyTo = ko.observable('');
|
this.replyTo = ko.observable('');
|
||||||
this.signature = ko.observable('');
|
this.signature = ko.observable('');
|
||||||
this.signatureToAll = ko.observable(false);
|
|
||||||
|
|
||||||
this.accounts = ko.observableArray([]);
|
this.accounts = ko.observableArray([]);
|
||||||
this.accounts.loading = ko.observable(false).extend({'throttle': 100});
|
this.accounts.loading = ko.observable(false).extend({'throttle': 100});
|
||||||
|
|
@ -74,7 +73,6 @@
|
||||||
this.displayName(Settings.settingsGet('DisplayName'));
|
this.displayName(Settings.settingsGet('DisplayName'));
|
||||||
this.replyTo(Settings.settingsGet('ReplyTo'));
|
this.replyTo(Settings.settingsGet('ReplyTo'));
|
||||||
this.signature(Settings.settingsGet('Signature'));
|
this.signature(Settings.settingsGet('Signature'));
|
||||||
this.signatureToAll(!!Settings.settingsGet('SignatureToAll'));
|
|
||||||
};
|
};
|
||||||
|
|
||||||
module.exports = new AccountUserStore();
|
module.exports = new AccountUserStore();
|
||||||
|
|
|
||||||
|
|
@ -758,13 +758,13 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* @param {string} sInputText
|
||||||
* @param {string} sSignature
|
* @param {string} sSignature
|
||||||
* @param {string=} sFrom
|
* @param {string=} sFrom
|
||||||
* @param {string=} sData
|
|
||||||
* @param {string=} sComposeType
|
* @param {string=} sComposeType
|
||||||
* @return {string}
|
* @return {string}
|
||||||
*/
|
*/
|
||||||
ComposePopupView.prototype.convertSignature = function (sSignature, sFrom, sData, sComposeType)
|
ComposePopupView.prototype.convertSignature = function (sInputText, sSignature, sFrom, sComposeType)
|
||||||
{
|
{
|
||||||
var bHtml = false, bData = false;
|
var bHtml = false, bData = false;
|
||||||
if ('' !== sSignature)
|
if ('' !== sSignature)
|
||||||
|
|
@ -801,35 +801,51 @@
|
||||||
sSignature = sSignature.replace(/{{DATE}}/g, moment().format('llll'));
|
sSignature = sSignature.replace(/{{DATE}}/g, moment().format('llll'));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sData && Enums.ComposeType.Empty === sComposeType &&
|
// Enums.ComposeType.Empty === sComposeType
|
||||||
-1 < sSignature.indexOf('{{BODY}}'))
|
if (-1 < sSignature.indexOf('{{BODY}}'))
|
||||||
{
|
{
|
||||||
bData = true;
|
if (sInputText)
|
||||||
sSignature = sSignature.replace('{{BODY}}', sData);
|
{
|
||||||
|
bData = true;
|
||||||
|
|
||||||
|
sSignature = bHtml ? sSignature : Utils.plainToHtml(sSignature, true);
|
||||||
|
sSignature = sSignature.replace('{{BODY}}', sInputText);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sSignature = sSignature.replace(/[\n]?{{BODY}}[\n]?/g, '{{BODY}}');
|
||||||
|
sSignature = sSignature.replace(/{{BODY}}/g, '');
|
||||||
|
|
||||||
|
sSignature = bHtml ? sSignature : Utils.plainToHtml(sSignature, true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
else
|
||||||
sSignature = sSignature.replace(/{{BODY}}/g, '');
|
|
||||||
|
|
||||||
if (!bHtml)
|
|
||||||
{
|
{
|
||||||
sSignature = Utils.plainToHtml(sSignature, true);
|
sSignature = bHtml ? sSignature : Utils.plainToHtml(sSignature, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sData && !bData)
|
if (!bData)
|
||||||
{
|
{
|
||||||
switch (sComposeType)
|
if (sSignature)
|
||||||
{
|
{
|
||||||
case Enums.ComposeType.Empty:
|
switch (sComposeType)
|
||||||
sSignature = sData + '<br />' + sSignature;
|
{
|
||||||
break;
|
case Enums.ComposeType.Empty:
|
||||||
default:
|
sInputText = sInputText + '<br />' + sSignature;
|
||||||
sSignature = sSignature + '<br />' + sData;
|
break;
|
||||||
break;
|
default:
|
||||||
|
sInputText = sSignature + '<br />' + sInputText;
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sInputText = sSignature;
|
||||||
|
}
|
||||||
|
|
||||||
return sSignature;
|
return sInputText;
|
||||||
};
|
};
|
||||||
|
|
||||||
ComposePopupView.prototype.editor = function (fOnInit)
|
ComposePopupView.prototype.editor = function (fOnInit)
|
||||||
|
|
@ -951,7 +967,6 @@
|
||||||
oIdResult = null,
|
oIdResult = null,
|
||||||
mEmail = AccountStore.email(),
|
mEmail = AccountStore.email(),
|
||||||
sSignature = AccountStore.signature(),
|
sSignature = AccountStore.signature(),
|
||||||
bSignatureToAll = AccountStore.signatureToAll(),
|
|
||||||
aDownloads = [],
|
aDownloads = [],
|
||||||
aDraftInfo = null,
|
aDraftInfo = null,
|
||||||
oMessage = null,
|
oMessage = null,
|
||||||
|
|
@ -1134,10 +1149,10 @@
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bSignatureToAll && '' !== sSignature &&
|
if ('' !== sSignature &&
|
||||||
Enums.ComposeType.EditAsNew !== sComposeType && Enums.ComposeType.Draft !== sComposeType)
|
Enums.ComposeType.EditAsNew !== sComposeType && Enums.ComposeType.Draft !== sComposeType)
|
||||||
{
|
{
|
||||||
sText = this.convertSignature(sSignature, fEmailArrayToStringLineHelper(oMessage.from, true), sText, sComposeType);
|
sText = this.convertSignature(sText, sSignature, fEmailArrayToStringLineHelper(oMessage.from, true), sComposeType);
|
||||||
}
|
}
|
||||||
|
|
||||||
this.editor(function (oEditor) {
|
this.editor(function (oEditor) {
|
||||||
|
|
@ -1154,10 +1169,9 @@
|
||||||
this.subject(Utils.isNormal(sCustomSubject) ? '' + sCustomSubject : '');
|
this.subject(Utils.isNormal(sCustomSubject) ? '' + sCustomSubject : '');
|
||||||
|
|
||||||
sText = Utils.isNormal(sCustomPlainText) ? '' + sCustomPlainText : '';
|
sText = Utils.isNormal(sCustomPlainText) ? '' + sCustomPlainText : '';
|
||||||
if (bSignatureToAll && '' !== sSignature)
|
if ('' !== sSignature)
|
||||||
{
|
{
|
||||||
sText = this.convertSignature(sSignature, '',
|
sText = this.convertSignature(Utils.plainToHtml(sText, true), sSignature, '', sComposeType);
|
||||||
Utils.plainToHtml(sText, true), sComposeType);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
this.editor(function (oEditor) {
|
this.editor(function (oEditor) {
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
"name": "RainLoop",
|
"name": "RainLoop",
|
||||||
"title": "RainLoop Webmail",
|
"title": "RainLoop Webmail",
|
||||||
"version": "1.8.0",
|
"version": "1.8.0",
|
||||||
"release": "250",
|
"release": "251",
|
||||||
"description": "Simple, modern & fast web-based email client",
|
"description": "Simple, modern & fast web-based email client",
|
||||||
"homepage": "http://rainloop.net",
|
"homepage": "http://rainloop.net",
|
||||||
"main": "gulpfile.js",
|
"main": "gulpfile.js",
|
||||||
|
|
|
||||||
|
|
@ -1451,7 +1451,6 @@ class Actions
|
||||||
$aResult['DisplayName'] = '';
|
$aResult['DisplayName'] = '';
|
||||||
$aResult['ReplyTo'] = '';
|
$aResult['ReplyTo'] = '';
|
||||||
$aResult['Signature'] = '';
|
$aResult['Signature'] = '';
|
||||||
$aResult['SignatureToAll'] = false;
|
|
||||||
$aResult['EnableTwoFactor'] = false;
|
$aResult['EnableTwoFactor'] = false;
|
||||||
$aResult['ParentEmail'] = '';
|
$aResult['ParentEmail'] = '';
|
||||||
$aResult['InterfaceAnimation'] = true;
|
$aResult['InterfaceAnimation'] = true;
|
||||||
|
|
@ -1497,7 +1496,6 @@ class Actions
|
||||||
$aResult['DisplayName'] = $oSettings->GetConf('DisplayName', $aResult['DisplayName']);
|
$aResult['DisplayName'] = $oSettings->GetConf('DisplayName', $aResult['DisplayName']);
|
||||||
$aResult['ReplyTo'] = $oSettings->GetConf('ReplyTo', $aResult['ReplyTo']);
|
$aResult['ReplyTo'] = $oSettings->GetConf('ReplyTo', $aResult['ReplyTo']);
|
||||||
$aResult['Signature'] = $oSettings->GetConf('Signature', $aResult['Signature']);
|
$aResult['Signature'] = $oSettings->GetConf('Signature', $aResult['Signature']);
|
||||||
$aResult['SignatureToAll'] = !!$oSettings->GetConf('SignatureToAll', $aResult['SignatureToAll']);
|
|
||||||
$aResult['EnableTwoFactor'] = !!$oSettings->GetConf('EnableTwoFactor', $aResult['EnableTwoFactor']);
|
$aResult['EnableTwoFactor'] = !!$oSettings->GetConf('EnableTwoFactor', $aResult['EnableTwoFactor']);
|
||||||
|
|
||||||
$aResult['ParentEmail'] = $oAccount->ParentEmail();
|
$aResult['ParentEmail'] = $oAccount->ParentEmail();
|
||||||
|
|
@ -4363,7 +4361,6 @@ class Actions
|
||||||
$this->setSettingsFromParams($oSettings, 'DisplayName', 'string');
|
$this->setSettingsFromParams($oSettings, 'DisplayName', 'string');
|
||||||
$this->setSettingsFromParams($oSettings, 'ReplyTo', 'string');
|
$this->setSettingsFromParams($oSettings, 'ReplyTo', 'string');
|
||||||
$this->setSettingsFromParams($oSettings, 'Signature', 'string');
|
$this->setSettingsFromParams($oSettings, 'Signature', 'string');
|
||||||
$this->setSettingsFromParams($oSettings, 'SignatureToAll', 'bool');
|
|
||||||
$this->setSettingsFromParams($oSettings, 'EnableTwoFactor', 'bool');
|
$this->setSettingsFromParams($oSettings, 'EnableTwoFactor', 'bool');
|
||||||
|
|
||||||
return $this->DefaultResponse(__FUNCTION__,
|
return $this->DefaultResponse(__FUNCTION__,
|
||||||
|
|
|
||||||
|
|
@ -62,17 +62,6 @@
|
||||||
}"></div>
|
}"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="control-group g-ui-user-select-none">
|
|
||||||
<div class="controls">
|
|
||||||
<div data-bind="component: {
|
|
||||||
name: 'Checkbox',
|
|
||||||
params: {
|
|
||||||
label: 'SETTINGS_IDENTITIES/LABEL_ADD_SIGNATURE_TO_ALL',
|
|
||||||
value: signatureToAll
|
|
||||||
}
|
|
||||||
}"></div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
<br />
|
<br />
|
||||||
<div class="form-horizontal g-ui-user-select-none">
|
<div class="form-horizontal g-ui-user-select-none">
|
||||||
|
|
|
||||||
|
|
@ -45,16 +45,5 @@
|
||||||
}"></div>
|
}"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="control-group g-ui-user-select-none">
|
|
||||||
<div class="controls">
|
|
||||||
<div data-bind="component: {
|
|
||||||
name: 'Checkbox',
|
|
||||||
params: {
|
|
||||||
label: 'SETTINGS_IDENTITIES/LABEL_ADD_SIGNATURE_TO_ALL',
|
|
||||||
value: signatureToAll
|
|
||||||
}
|
|
||||||
}"></div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue