diff --git a/templates/zerver/emails/digest.source.html b/templates/zerver/emails/digest.source.html index a46465e1bf..c9e4c2222f 100644 --- a/templates/zerver/emails/digest.source.html +++ b/templates/zerver/emails/digest.source.html @@ -39,7 +39,7 @@

{% for convo in hot_conversations %} -
+
{% for recipient_block in convo.first_few_messages %}
{{ recipient_block.header.html|safe }}
diff --git a/templates/zerver/emails/email.css b/templates/zerver/emails/email.css index e36d08e5e8..61dee0eca6 100644 --- a/templates/zerver/emails/email.css +++ b/templates/zerver/emails/email.css @@ -213,11 +213,11 @@ a.button:hover { font-weight: normal; } -#messages { +.messages { width: 600px; font-size: 12px; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; - overflow-y: scroll; + overflow-y: auto; } .hot_convo_recipient_block { @@ -242,6 +242,43 @@ a.button:hover { padding-top: 1px; } +.recipient_block_with_messages { + background-color: hsl(192, 20%, 95%); + border: 1px solid black; + margin-bottom: 4px; +} + +.recipient_header_with_messages { + background-color: hsl(213, 100%, 81%); + border-bottom: 1px solid black; + font-weight: bold; + padding: 2px; +} + +.message_content_with_messages { + background-color: hsl(192, 20%, 95%); + margin-left: 1px; + margin-right: 2px; +} + +.recipient_block_without_messages { + border: 1px solid black; + margin-bottom: 4px; +} + +.recipient_header_without_messages { + color: hsl(0, 0%, 100%); + background-color: hsl(0, 0%, 27%); + border-bottom: 1px solid black; + font-weight: bold; + padding: 2px; +} + +.message_content_without_messages { + margin-left: 1px; + margin-right: 2px; +} + .hot_convo_message_content_block { padding-left: 6px; font-weight: normal; diff --git a/templates/zerver/emails/missed_message.html b/templates/zerver/emails/missed_message.source.html similarity index 62% rename from templates/zerver/emails/missed_message.html rename to templates/zerver/emails/missed_message.source.html index 5501b66559..67d12999c4 100644 --- a/templates/zerver/emails/missed_message.html +++ b/templates/zerver/emails/missed_message.source.html @@ -18,21 +18,21 @@

{% if show_message_content %} -
+
{% for recipient_block in messages %} {% if not recipient_block.header.stream_message %} -
-
{{ recipient_block.header.html|safe }}
-
+
+
{{ recipient_block.header.html|safe }}
+
{% else %} -
-
{{ recipient_block.header.html|safe }}
-
+
+
{{ recipient_block.header.html|safe }}
+
{% endif %} {% for sender_block in recipient_block.senders %} - {% if sender_block.sender %}
{{ sender_block.sender }}
{% endif %} + {% if sender_block.sender %}
{{ sender_block.sender }}
{% endif %} {% for message_block in sender_block.content %} -
+
{{ message_block.html|safe }}
{% endfor %} diff --git a/tools/check-templates b/tools/check-templates index a91ce57841..54f341d449 100755 --- a/tools/check-templates +++ b/tools/check-templates @@ -17,7 +17,7 @@ EXCLUDED_FILES = [ ## Test data Files for testing modules in tests "tools/tests/test_template_data", # Our parser doesn't handle the way its conditionals are layered - 'templates/zerver/emails/missed_message.html', + 'templates/zerver/emails/missed_message.source.html', ] def check_our_files(modified_only, all_dups, targets): diff --git a/tools/linter_lib/custom_check.py b/tools/linter_lib/custom_check.py index 4262ded376..214a74c3ad 100644 --- a/tools/linter_lib/custom_check.py +++ b/tools/linter_lib/custom_check.py @@ -801,7 +801,6 @@ def build_custom_checkers(by_lang): # Old-style email templates need to use inline style # attributes; it should be possible to clean these up # when we convert these templates to use premailer. - 'templates/zerver/emails/missed_message.html', 'templates/zerver/emails/email_base_messages.html', # Email log templates; should clean up.