X-Git-Url: https://plomlompom.com/repos/?p=berlin-corona-table;a=blobdiff_plain;f=enhance_table.py;h=6dbee7c1ceff06c04bb683852b751c26b7d616dd;hp=46e0b41b85b9fe5eddc1935204c435b7838ca1ce;hb=26542fd87e874aa487752ae92395c68053b8e8b7;hpb=ac2a6b52cc241f80322745693ca6e2e12de2503a diff --git a/enhance_table.py b/enhance_table.py index 46e0b41..6dbee7c 100755 --- a/enhance_table.py +++ b/enhance_table.py @@ -140,12 +140,15 @@ table, tr, th, td { border: 1px solid black; text-align: center; } .district_name { writing-mode: vertical-rl; transform: rotate(180deg); } .bonus_data th { font-weight: normal; } .new_infections { font-weight: bold; } +thead th { position: sticky; top: 0; background-color: white; } Berlin's Corona infection numbers, development by districts +home · contact · privacy

Berlin's Corona infection numbers, development by districts

-

Updated daily at 9pm. Source code. Text view optimized for terminal curl.

+

Updated daily at 9pm based on data from the "Senatsverwaltung für Gesundheit, Pflege und Gleichstellung". Source code. Text view optimized for terminal curl.

+""") sorted_dates.reverse() @@ -155,8 +158,11 @@ table, tr, th, td { border: 1px solid black; text-align: center; } if sum_district == district: print('' % long_form) else: - print('' % long_form) + # Wrap in div because the vertical orientation otherwise fails + # in Chromium. + print('' % long_form) print('') + print('') for date in sorted_dates: print('') print('' % date) @@ -195,7 +201,7 @@ elif output_type == 'txt': # Explain what this is. intro = \ """Table of Berlin's Corona infection number development by districts. -Updated daily at 9pm. +Updated daily at 9pm based on data from the "Senatsverwaltung für Gesundheit, Pflege und Gleichstellung". Abbrevations/explanations: """
date%s%s
%s
%s