From 0aad5554089f9fbebf3263ed3e23b75822047a57 Mon Sep 17 00:00:00 2001 From: n9k Date: Mon, 14 Mar 2022 08:21:38 +0000 Subject: [PATCH] Info iframe: properly show uptime text-only fallback --- anonstream/templates/nojs_info.html | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/anonstream/templates/nojs_info.html b/anonstream/templates/nojs_info.html index 37c0620..14c4fb2 100644 --- a/anonstream/templates/nojs_info.html +++ b/anonstream/templates/nojs_info.html @@ -83,11 +83,14 @@ #h1 { animation-duration: {{ 36000 - uptime }}s; } + #uptime-dynamic { + animation: disappear step-end {{ 360000 - uptime }}s forwards; + } #uptime-dynamic-overflow { animation: appear step-end {{ 360000 - uptime }}s backwards; } - #uptime-dynamic { - animation: disappear step-end {{ 360000 - uptime }}s forwards; + #uptime-dynamic-overflow::after { + content: "100+ hours"; } @keyframes appear { from { @@ -146,11 +149,11 @@ Uptime: {%- if uptime >= 3600 -%} - {{- (uptime // 3600) | int -}} + {{- uptime | int // 3600 -}} {{- ':' -}} {{- '%02.0f' | format(uptime % 3600 // 60) -}} {%- else -%} - {{- uptime % 3600 // 60 | int -}} + {{- uptime | int % 3600 // 60 -}} {%- endif -%} {{- ':' -}} {{- '%02.0f' | format(uptime % 60) -}} @@ -170,7 +173,7 @@ {{- '' -}} -
100+ hours
+
{% endif %}