From 3940b2991f20ebdc2e6d464f605e42e1b222add5 Mon Sep 17 00:00:00 2001
From: KnugiHK <24708955+KnugiHK@users.noreply.github.com>
Date: Tue, 13 Jun 2023 21:23:44 +0800
Subject: [PATCH] Try to reduce the size of the template
---
Whatsapp_Chat_Exporter/whatsapp.html | 58 ++++++++++++++++++----------
1 file changed, 38 insertions(+), 20 deletions(-)
diff --git a/Whatsapp_Chat_Exporter/whatsapp.html b/Whatsapp_Chat_Exporter/whatsapp.html
index bef7d8c..fc960c6 100644
--- a/Whatsapp_Chat_Exporter/whatsapp.html
+++ b/Whatsapp_Chat_Exporter/whatsapp.html
@@ -50,6 +50,9 @@
animation: border-blink 0.5s steps(1) 5;
border-color: rgba(0,0,0,0)
}
+ table {
+ width: 100%;
+ }
@keyframes border-blink {
0% {
border-color: #2196F3;
@@ -64,23 +67,38 @@
max-width: 64px;
max-height: 64px;
}
+ .name {
+ color: #3892da;
+ }
+ .pad-left-10 {
+ padding-left: 10px;
+ }
+ .pad-right-10 {
+ padding-right: 10px;
+ }
+ .reply_link {
+ color: #168acc;
+ }
+ .blue {
+ color: #70777a;
+ }
Chat history with {{ name }}
-
+
{% set last = {'last': 946688461.001} %}
{% for msg in msgs -%}
-
+
{% if determine_day(last.last, msg.timestamp) is not none %}
-
{{ determine_day(last.last, msg.timestamp) }}
+
{{ determine_day(last.last, msg.timestamp) }}
{% if last.update({'last': msg.timestamp}) %}{% endif %}
{% endif %}
{% if msg.from_me == true %}
-
{{ msg.time }}
-
You
+
{{ msg.time }}
+
You
{% if not no_avatar and my_avatar is not none %}
@@ -88,11 +106,11 @@
{% else %}
{% endif %}
-
+
{% if msg.reply is not none %}
{% endif %}
{% if msg.meta == true or msg.media == false and msg.data is none %}
-
-
{{ msg.data or 'Not supported WhatsApp internal message' }}
-
+
+
{{ msg.data or 'Not supported WhatsApp internal message' }}
+
{% else %}
{% if msg.media == false %}
{{ msg.data | sanitize_except() }}
@@ -120,7 +138,7 @@
{% elif "/" in msg.mime %}
-
+
The file cannot be displayed here, however it should be located at here
{% else %}
@@ -135,7 +153,7 @@
{% if not no_avatar and my_avatar is not none %}
-
+
@@ -144,14 +162,14 @@
{% else %}
-
+
{% if msg.sender is not none %}
{{ msg.sender }}
{% else %}
{{ name }}
{% endif %}
-
{{ msg.time }}
+
{{ msg.time }}
{% if not no_avatar %}
@@ -166,11 +184,11 @@
{% else %}
{% endif %}
-
+
{% if msg.reply is not none %}
{% endif %}
{% if msg.meta == true or msg.media == false and msg.data is none %}
-
+
{{ msg.data or 'Not supported WhatsApp internal message' }}
{% else %}
@@ -198,7 +216,7 @@
{% elif "/" in msg.mime %}
-
+
The file cannot be displayed here, however it should be located at here
{% else %}