This commit is contained in:
2024-05-24 10:09:50 +02:00
parent cfe3d3f329
commit c390a3eb9a
8 changed files with 68 additions and 23 deletions

View File

@ -7,19 +7,25 @@
<img src="{{ url }}" >
<div class="right">
<div class="stats">
<div class="rounds">
Round {{ i }} of {{ game_length }}
</div>
{% if game_length > 0 %}
<div class="rounds">
Round {{ i }} of {{ game_length }}
</div>
{% endif %}
<div class="points">
{{ points }}/{{ round_n }} points.
</div>
</div>
<form method="post" action="/fontgame?id={{ id }}">
<select name="font">
{% for font in fonts %}
<option>{{ font }}</option>
{% endfor %}
</select>
<form method="post" action="/fontgame?id={{ id }}" autocomplete="off">
{% if not hard_mode %}
<select name="font" autofocus>
{% for font in fonts %}
<option>{{ font }}</option>
{% endfor %}
</select>
{% else %}
<input type="text" name="font" autofocus>
{% endif %}
<input type="hidden" name="id" value="{{ id }}">
<input type="submit" value="Submit">
</form>

View File

@ -1,13 +1,20 @@
<!DOCTYPE html>
<html>
<head>
<head>
<link rel="stylesheet" href="/static/css/stylesheet.css">
</head>
<body class="menupage">
<h1>Font Game</h1>
<form method="post" action="/startgame">
<label for="game_length">Game rounds:</label>
<input type="number" name="game_length" min=1 class="number" value=10>
<div>
<label for="game_length">Game rounds:</label>
<input type="number" name="game_length" min=0 class="number" value=10>
</div>
<p>(0 for endless mode)</p>
<div>
<label for="hard_mode">Hard mode:</label>
<input type="checkbox" name="hard_mode" class="checkbox">
</div>
<input type="submit" value="Start">
</form>
</body>