[Dovecot] Quota template - better compatibility (#3783)

MS Outlook, Thunderbird, EMClient, SOGo, Roundcube
master
Lukáš Matula 2020-09-29 06:33:13 +02:00 committed by GitHub
parent 43fef9973f
commit 37e4ad7c1b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 71 additions and 51 deletions

View File

@ -1,53 +1,73 @@
<html> <html>
<head> <head>
<style> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
body { <style>
font-family: sans-serif; body {
} font-family: Calibri, Arial, Verdana;
div { }
/* width based on text fill*/ table {
display: inline-block; border: 0;
} border-collapse: collapse;
#progressbar { <!--[if mso]>
color: #000; border-spacing: 0px;
background-color: #f1f1f1; table-layout: fixed;
width: 100%; <![endif]-->
} }
{% if (percent >= 95) %} tr {
#progressbar > div { display: flex;
color: #fff; }
background-color: #FF0000; #progressbar {
text-align: center; color: #000;
padding: 0.01em; background-color: #f1f1f1;
width: {{percent}}%; width: 100%;
} }
{% elif (percent < 95) and (percent >= 80) %} {% if (percent >= 95) %}
#progressbar > div { #progressbar {
color: #fff; color: #fff;
background-color: #FF8C00; background-color: #FF0000;
text-align: center; text-align: center;
padding: 0.01em; width: {{percent}}%;
width: {{percent}}%; }
} {% elif (percent < 95) and (percent >= 80) %}
{% else %} #progressbar {
#progressbar > div { color: #fff;
color: #fff; background-color: #FF8C00;
background-color: #00B000; text-align: center;
text-align: center; width: {{percent}}%;
padding: 0.01em; }
width: {{percent}}%; {% else %}
} #progressbar {
{% endif %} color: #fff;
</style> background-color: #00B000;
</head> text-align: center;
<body> width: {{percent}}%;
<div> }
<p>Hi {{username}}!<br><br> {% endif %}
Your mailbox is now {{percent}}% full, please consider deleting old messages to still be able to receive new mails in the future.<br> #graybar {
<div id="progressbar"> background-color: #D8D8D8;
<div>{{percent}}%</div> width: {{100 - percent}}%;
</div> }
</p> a:link, a:visited {
</div> color: #858585;
</body> text-decoration: none;
}
a:hover, a:active {
color: #4a81bf;
}
</style>
</head>
<body>
<table>
<tr>
<td colspan="2">
Hi {{username}}!<br /><br />
Your mailbox is now {{percent}}% full, please consider deleting old messages to still be able to receive new mails in the future.<br /><br />
</td>
</tr>
<tr>
<td id="progressbar">{{percent}}%</td>
<td id="graybar"></td>
</tr>
</table>
</body>
</html> </html>