Fixed popup message styles (#278)

This commit is contained in:
RainLoop Team 2014-09-04 20:00:11 +04:00
parent 9bde3fe5dd
commit 542c46b654
6 changed files with 99 additions and 36 deletions

View file

@ -1301,13 +1301,13 @@
oWin.document.open(); oWin.document.open();
oWin.document.write('<html><head>' + oWin.document.write('<html><head>' +
'<meta charset="utf-8" />' + '<meta charset="utf-8" />' +
'<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />' + '<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />' +
'<meta name="viewport" content="user-scalable=no" />' + '<meta name="viewport" content="user-scalable=no" />' +
'<meta name="apple-mobile-web-app-capable" content="yes" />' + '<meta name="apple-mobile-web-app-capable" content="yes" />' +
'<meta name="robots" content="noindex, nofollow, noodp" />' + '<meta name="robots" content="noindex, nofollow, noodp" />' +
'<title>' + Utils.encodeHtml(sTitle) + '</title>' + '<title>' + Utils.encodeHtml(sTitle) + '</title>' +
'</head><body><div id="rl-content"></div></body></html>'); '</head><body><div id="rl-content"></div></body></html>');
oWin.document.close(); oWin.document.close();
oScript = oWin.document.createElement('script'); oScript = oWin.document.createElement('script');

View file

@ -825,6 +825,7 @@
'popupCc': this.ccToLine(false), 'popupCc': this.ccToLine(false),
'popupBcc': this.bccToLine(false), 'popupBcc': this.bccToLine(false),
'popupSubject': this.subject(), 'popupSubject': this.subject(),
'popupIsHtml': this.isHtml(),
'popupDate': this.fullFormatDateValue(), 'popupDate': this.fullFormatDateValue(),
'popupAttachments': this.attachmentsToStringLine(), 'popupAttachments': this.attachmentsToStringLine(),
'popupBody': this.textBodyToString() 'popupBody': this.textBodyToString()

View file

@ -1,20 +1,81 @@
<style> <style>
html, body { html, body {
margin: 0; margin: 0;
padding: 0; padding: 0;
background-color: #fff; background-color: #fff;
font-size: 13px;
font-family: arial, sans-serif; font-family: arial, sans-serif;
} }
.tbl {width:100%;font-family:normal 11px Tahoma, Arial, Helvetica, "sans-serif"} .tbl {width: 100%; font-size: 12px; font-family: arial, sans-serif;}
.tt {padding:5px;border:solid #ddd;border-width:0px 0px 1px 0px} .tt {padding: 5px; border:solid #ddd; border-width:0px 0px 1px 0px}
.tv {padding:5px;border:solid #ddd;border-width:0px 0px 1px 1px} .tv {padding: 5px; border:solid #ddd; border-width:0px 0px 1px 1px}
.tb {padding:15px} .tb {padding: 15px}
a {color: blue; text-decoration: underline} a {color: blue; text-decoration: underline}
a:visited {color: #609} a:visited {color: #609}
a:active {color: red} a:active {color: red}
blockquote {border-left: 2px solid black; margin: 0; padding: 0px 10px} blockquote {border-left: 2px solid black; margin: 0; padding: 0px 10px}
pre {margin: 0px; padding: 0px; font-family: arial, sans-serif; background: #fff; border: none; white-space: normal}
pre {
margin: 0px;
padding: 0px;
font-family: Monaco, Menlo, Consolas, 'Courier New', monospace;
background: #fff;
border: none;
white-space: pre-wrap;
word-wrap: break-word;
word-break: break-all;
}
.text-body {
font-size: 13px;
}
.text-body.html div[data-x-div-type=body] {
margin: 15px;
}
.text-body.html pre {
font-family: Monaco, Menlo, Consolas, 'Courier New', monospace;
white-space: pre-wrap;
word-wrap: break-word;
word-break: break-all;
}
.text-body.plain {
padding: 15px;
white-space: pre-wrap;
font-family: Monaco, Menlo, Consolas, 'Courier New', monospace;
}
.text-body.plain pre {
margin: 0px;
padding: 0px;
background: #fff;
border: none;
font-family: Monaco, Menlo, Consolas, 'Courier New', monospace;
white-space: pre-wrap;
word-wrap: break-word;
word-break: break-all;
}
.text-body.plain blockquote {
border-left: 2px solid blue;
color: blue;
}
.text-body.plain blockquote blockquote {
border-left: 2px solid green;
color: green;
}
.text-body.plain blockquote blockquote blockquote {
border-left: 2px solid red;
color: red;
}
</style> </style>
<table cellpadding="0" cellspacing="0" class="tbl"> <table cellpadding="0" cellspacing="0" class="tbl">
@ -49,7 +110,7 @@ pre {margin: 0px; padding: 0px; font-family: arial, sans-serif; background: #fff
</tr> </tr>
<tr> <tr>
<td colspan="2" class="tb"> <td colspan="2" class="tb">
<div data-bind="html: popupBody"></div> <div class="text-body" data-bind="html: popupBody, css: {'plain': !popupIsHtml, 'html': popupIsHtml}"></div>
</td> </td>
</tr> </tr>
</tbody> </tbody>

View file

@ -3342,13 +3342,13 @@
oWin.document.open(); oWin.document.open();
oWin.document.write('<html><head>' + oWin.document.write('<html><head>' +
'<meta charset="utf-8" />' + '<meta charset="utf-8" />' +
'<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />' + '<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />' +
'<meta name="viewport" content="user-scalable=no" />' + '<meta name="viewport" content="user-scalable=no" />' +
'<meta name="apple-mobile-web-app-capable" content="yes" />' + '<meta name="apple-mobile-web-app-capable" content="yes" />' +
'<meta name="robots" content="noindex, nofollow, noodp" />' + '<meta name="robots" content="noindex, nofollow, noodp" />' +
'<title>' + Utils.encodeHtml(sTitle) + '</title>' + '<title>' + Utils.encodeHtml(sTitle) + '</title>' +
'</head><body><div id="rl-content"></div></body></html>'); '</head><body><div id="rl-content"></div></body></html>');
oWin.document.close(); oWin.document.close();
oScript = oWin.document.createElement('script'); oScript = oWin.document.createElement('script');

View file

@ -5736,13 +5736,13 @@
oWin.document.open(); oWin.document.open();
oWin.document.write('<html><head>' + oWin.document.write('<html><head>' +
'<meta charset="utf-8" />' + '<meta charset="utf-8" />' +
'<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />' + '<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />' +
'<meta name="viewport" content="user-scalable=no" />' + '<meta name="viewport" content="user-scalable=no" />' +
'<meta name="apple-mobile-web-app-capable" content="yes" />' + '<meta name="apple-mobile-web-app-capable" content="yes" />' +
'<meta name="robots" content="noindex, nofollow, noodp" />' + '<meta name="robots" content="noindex, nofollow, noodp" />' +
'<title>' + Utils.encodeHtml(sTitle) + '</title>' + '<title>' + Utils.encodeHtml(sTitle) + '</title>' +
'</head><body><div id="rl-content"></div></body></html>'); '</head><body><div id="rl-content"></div></body></html>');
oWin.document.close(); oWin.document.close();
oScript = oWin.document.createElement('script'); oScript = oWin.document.createElement('script');
@ -10357,6 +10357,7 @@ module.exports = window;
'popupCc': this.ccToLine(false), 'popupCc': this.ccToLine(false),
'popupBcc': this.bccToLine(false), 'popupBcc': this.bccToLine(false),
'popupSubject': this.subject(), 'popupSubject': this.subject(),
'popupIsHtml': this.isHtml(),
'popupDate': this.fullFormatDateValue(), 'popupDate': this.fullFormatDateValue(),
'popupAttachments': this.attachmentsToStringLine(), 'popupAttachments': this.attachmentsToStringLine(),
'popupBody': this.textBodyToString() 'popupBody': this.textBodyToString()

File diff suppressed because one or more lines are too long