From c1b9b3f6a2d1475109b5899b7c3e1f16e5eaf52a Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Wed, 12 May 2021 20:41:21 +0200 Subject: [PATCH 01/11] Web: Add countries list to Git repo In order to remove "Province of China" from entry for Taiwan. --- .../web/registration/countries.csv | 250 ++++++++++++++++++ 1 file changed, 250 insertions(+) create mode 100644 src/ctf_gameserver/web/registration/countries.csv diff --git a/src/ctf_gameserver/web/registration/countries.csv b/src/ctf_gameserver/web/registration/countries.csv new file mode 100644 index 00000000..88dc2207 --- /dev/null +++ b/src/ctf_gameserver/web/registration/countries.csv @@ -0,0 +1,250 @@ +Name,Code +Afghanistan,AF +Åland Islands,AX +Albania,AL +Algeria,DZ +American Samoa,AS +Andorra,AD +Angola,AO +Anguilla,AI +Antarctica,AQ +Antigua and Barbuda,AG +Argentina,AR +Armenia,AM +Aruba,AW +Australia,AU +Austria,AT +Azerbaijan,AZ +Bahamas,BS +Bahrain,BH +Bangladesh,BD +Barbados,BB +Belarus,BY +Belgium,BE +Belize,BZ +Benin,BJ +Bermuda,BM +Bhutan,BT +"Bolivia, Plurinational State of",BO +"Bonaire, Sint Eustatius and Saba",BQ +Bosnia and Herzegovina,BA +Botswana,BW +Bouvet Island,BV +Brazil,BR +British Indian Ocean Territory,IO +Brunei Darussalam,BN +Bulgaria,BG +Burkina Faso,BF +Burundi,BI +Cambodia,KH +Cameroon,CM +Canada,CA +Cape Verde,CV +Cayman Islands,KY +Central African Republic,CF +Chad,TD +Chile,CL +China,CN +Christmas Island,CX +Cocos (Keeling) Islands,CC +Colombia,CO +Comoros,KM +Congo,CG +"Congo, the Democratic Republic of the",CD +Cook Islands,CK +Costa Rica,CR +Côte d'Ivoire,CI +Croatia,HR +Cuba,CU +Curaçao,CW +Cyprus,CY +Czech Republic,CZ +Denmark,DK +Djibouti,DJ +Dominica,DM +Dominican Republic,DO +Ecuador,EC +Egypt,EG +El Salvador,SV +Equatorial Guinea,GQ +Eritrea,ER +Estonia,EE +Ethiopia,ET +Falkland Islands (Malvinas),FK +Faroe Islands,FO +Fiji,FJ +Finland,FI +France,FR +French Guiana,GF +French Polynesia,PF +French Southern Territories,TF +Gabon,GA +Gambia,GM +Georgia,GE +Germany,DE +Ghana,GH +Gibraltar,GI +Greece,GR +Greenland,GL +Grenada,GD +Guadeloupe,GP +Guam,GU +Guatemala,GT +Guernsey,GG +Guinea,GN +Guinea-Bissau,GW +Guyana,GY +Haiti,HT +Heard Island and McDonald Islands,HM +Holy See (Vatican City State),VA +Honduras,HN +Hong Kong,HK +Hungary,HU +Iceland,IS +India,IN +Indonesia,ID +"Iran, Islamic Republic of",IR +Iraq,IQ +Ireland,IE +Isle of Man,IM +Israel,IL +Italy,IT +Jamaica,JM +Japan,JP +Jersey,JE +Jordan,JO +Kazakhstan,KZ +Kenya,KE +Kiribati,KI +"Korea, Democratic People's Republic of",KP +"Korea, Republic of",KR +Kuwait,KW +Kyrgyzstan,KG +Lao People's Democratic Republic,LA +Latvia,LV +Lebanon,LB +Lesotho,LS +Liberia,LR +Libya,LY +Liechtenstein,LI +Lithuania,LT +Luxembourg,LU +Macao,MO +"Macedonia, the Former Yugoslav Republic of",MK +Madagascar,MG +Malawi,MW +Malaysia,MY +Maldives,MV +Mali,ML +Malta,MT +Marshall Islands,MH +Martinique,MQ +Mauritania,MR +Mauritius,MU +Mayotte,YT +Mexico,MX +"Micronesia, Federated States of",FM +"Moldova, Republic of",MD +Monaco,MC +Mongolia,MN +Montenegro,ME +Montserrat,MS +Morocco,MA +Mozambique,MZ +Myanmar,MM +Namibia,NA +Nauru,NR +Nepal,NP +Netherlands,NL +New Caledonia,NC +New Zealand,NZ +Nicaragua,NI +Niger,NE +Nigeria,NG +Niue,NU +Norfolk Island,NF +Northern Mariana Islands,MP +Norway,NO +Oman,OM +Pakistan,PK +Palau,PW +"Palestine, State of",PS +Panama,PA +Papua New Guinea,PG +Paraguay,PY +Peru,PE +Philippines,PH +Pitcairn,PN +Poland,PL +Portugal,PT +Puerto Rico,PR +Qatar,QA +Réunion,RE +Romania,RO +Russian Federation,RU +Rwanda,RW +Saint Barthélemy,BL +"Saint Helena, Ascension and Tristan da Cunha",SH +Saint Kitts and Nevis,KN +Saint Lucia,LC +Saint Martin (French part),MF +Saint Pierre and Miquelon,PM +Saint Vincent and the Grenadines,VC +Samoa,WS +San Marino,SM +Sao Tome and Principe,ST +Saudi Arabia,SA +Senegal,SN +Serbia,RS +Seychelles,SC +Sierra Leone,SL +Singapore,SG +Sint Maarten (Dutch part),SX +Slovakia,SK +Slovenia,SI +Solomon Islands,SB +Somalia,SO +South Africa,ZA +South Georgia and the South Sandwich Islands,GS +South Sudan,SS +Spain,ES +Sri Lanka,LK +Sudan,SD +Suriname,SR +Svalbard and Jan Mayen,SJ +Swaziland,SZ +Sweden,SE +Switzerland,CH +Syrian Arab Republic,SY +Taiwan,TW +Tajikistan,TJ +"Tanzania, United Republic of",TZ +Thailand,TH +Timor-Leste,TL +Togo,TG +Tokelau,TK +Tonga,TO +Trinidad and Tobago,TT +Tunisia,TN +Turkey,TR +Turkmenistan,TM +Turks and Caicos Islands,TC +Tuvalu,TV +Uganda,UG +Ukraine,UA +United Arab Emirates,AE +United Kingdom,GB +United States,US +United States Minor Outlying Islands,UM +Uruguay,UY +Uzbekistan,UZ +Vanuatu,VU +"Venezuela, Bolivarian Republic of",VE +Viet Nam,VN +"Virgin Islands, British",VG +"Virgin Islands, U.S.",VI +Wallis and Futuna,WF +Western Sahara,EH +Yemen,YE +Zambia,ZM +Zimbabwe,ZW From 428af6fc7154dfaf6da8721dedd6013349752197 Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Thu, 2 Jul 2020 11:19:03 +0200 Subject: [PATCH 02/11] Makefile: don't build/clean countries.csv It's now tracked in Git --- Makefile | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 1ed580fd..5009de82 100644 --- a/Makefile +++ b/Makefile @@ -31,10 +31,6 @@ $(EXT_DIR)/bootstrap: bootstrap.zip unzip -n $< -d $(EXT_DIR) mv -v $(EXT_DIR)/bootstrap-3.3.5-dist $(EXT_DIR)/bootstrap -$(WEB_DIR)/registration/countries.csv: - # Official download link from http://data.okfn.org/data/core/country-list, under Public Domain - curl https://raw.githubusercontent.com/datasets/country-list/master/data.csv -o $@ - run_web: $(DEV_MANAGE) runserver @@ -55,7 +51,7 @@ docs_site: mkdocs.yml $(wildcard docs/* docs/*/*) clean: rm -rf src/ctf_gameserver/web/*/migrations - rm -f src/ctf_gameserver/web/dev-db.sqlite3 src/ctf_gameserver/web/registration/countries.csv + rm -f src/ctf_gameserver/web/dev-db.sqlite3 rm -rf src/ctf_gameserver/web/static/ext rm -rf build dist src/ctf_gameserver.egg-info rm -rf docs_site From 4539246d2dbeff2b7962d4e4571bd427a6e2207a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felix=20Drei=C3=9Fig?= Date: Fri, 3 Jul 2020 13:40:18 +0200 Subject: [PATCH 03/11] Add CSS for responsive YouTube embeds --- src/ctf_gameserver/web/static/style.css | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/ctf_gameserver/web/static/style.css b/src/ctf_gameserver/web/static/style.css index e37e1529..8c9400a4 100644 --- a/src/ctf_gameserver/web/static/style.css +++ b/src/ctf_gameserver/web/static/style.css @@ -40,6 +40,22 @@ th.border-right, td.border-right { border-right: 2px solid #DDDDDD; } +/* See https://martinahonecker.com/youtube-videos-responsive-einbinden/ */ +.video-container { + position: relative; + margin-bottom: 20px; + height: 0; + padding-bottom: 56.25%; +} + +.video-container iframe, .video-container object, .video-container embed { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; +} + .image-column { width: 80px; } From 1fb947d7b2c03db807734754f6ff397ae25bee96 Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Tue, 5 Sep 2023 17:27:03 +0200 Subject: [PATCH 04/11] Add template and CSS customizations for FAUST CTF 2023 Same procedure as every year. --- src/ctf_gameserver/web/static/style.css | 11 +++++++++++ src/ctf_gameserver/web/templates/base-common.html | 10 ++++++++++ 2 files changed, 21 insertions(+) diff --git a/src/ctf_gameserver/web/static/style.css b/src/ctf_gameserver/web/static/style.css index 8c9400a4..e552aad4 100644 --- a/src/ctf_gameserver/web/static/style.css +++ b/src/ctf_gameserver/web/static/style.css @@ -100,3 +100,14 @@ img#load-spinner, button#refresh { margin-top: 20px; padding-left: 20px; } + +.jumbotron img.big-logo { + margin-right: 30px; + width: 30%; +} + +#supporter-column img { + margin-top: 10px; + margin-bottom: 35px; + width: 100%; +} diff --git a/src/ctf_gameserver/web/templates/base-common.html b/src/ctf_gameserver/web/templates/base-common.html index 5e227e3f..cbb69a53 100644 --- a/src/ctf_gameserver/web/templates/base-common.html +++ b/src/ctf_gameserver/web/templates/base-common.html @@ -21,8 +21,18 @@ {% block title %}{% endblock %} | {{ competition_name }} + + + + From cc58d1e0285b0ea644ab489e238ea073dc826c6b Mon Sep 17 00:00:00 2001 From: Benjamin Haag Date: Fri, 8 Sep 2023 09:04:58 +0200 Subject: [PATCH 05/11] Add 2023 navbar logo --- setup.py | 1 + src/ctf_gameserver/web/static/faustctf.svg | 648 ++++++++++++++++++ src/ctf_gameserver/web/static/style.css | 12 +- .../web/templates/base-common.html | 5 +- 4 files changed, 664 insertions(+), 2 deletions(-) create mode 100644 src/ctf_gameserver/web/static/faustctf.svg diff --git a/setup.py b/setup.py index 61196d8b..022282f6 100755 --- a/setup.py +++ b/setup.py @@ -59,6 +59,7 @@ 'static/*.css', 'static/*.gif', 'static/*.js', + 'static/faustctf.svg', 'static/ext/jquery.min.js', 'static/ext/bootstrap/css/*', 'static/ext/bootstrap/fonts/*', diff --git a/src/ctf_gameserver/web/static/faustctf.svg b/src/ctf_gameserver/web/static/faustctf.svg new file mode 100644 index 00000000..9a6a4b2f --- /dev/null +++ b/src/ctf_gameserver/web/static/faustctf.svg @@ -0,0 +1,648 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/ctf_gameserver/web/static/style.css b/src/ctf_gameserver/web/static/style.css index e552aad4..740d00c2 100644 --- a/src/ctf_gameserver/web/static/style.css +++ b/src/ctf_gameserver/web/static/style.css @@ -103,7 +103,17 @@ img#load-spinner, button#refresh { .jumbotron img.big-logo { margin-right: 30px; - width: 30%; + width: 40%; +} + +.navbar-brand { + padding: 5px 15px; +} + +.navbar-brand img { + display: inline; + margin-right: 15px; + height: 35px; } #supporter-column img { diff --git a/src/ctf_gameserver/web/templates/base-common.html b/src/ctf_gameserver/web/templates/base-common.html index cbb69a53..51fe454b 100644 --- a/src/ctf_gameserver/web/templates/base-common.html +++ b/src/ctf_gameserver/web/templates/base-common.html @@ -47,7 +47,10 @@ - {{ competition_name }} + + FAUST CTF 2023 logo + {{ competition_name }} +