matteo-the-prestige/templates/game_box.html

53 lines
2.4 KiB
HTML
Raw Normal View History

2021-01-02 11:21:53 +00:00
{% macro base(number) -%}
src={% if state.bases[number] %}"/static/img/base_filled.png" alt="{{state.bases[number]}}"{% else %}"/static/img/base_empty.png"{% endif %}
{%- endmacro %}
{% macro out(number) -%}
{% if number <= state.outs %}/static/img/out_out.png{% else %}/static/img/out_in.png{% endif %}
{%- endmacro %}
<div class="header">
2021-01-06 19:14:19 +00:00
<div class="inning">Inning: {% if state.display_top_of_inning == true %}🔼{% else %}🔽{% endif %} {{ state.display_inning | escape }}/{{ state.max_innings | escape }}</div>
<div class="title">{{ state.title | escape }}</div>
<div class="weather">{{ state.weather_emoji | escape }} {{ state.weather_text | escape }}</div>
2021-01-02 11:21:53 +00:00
</div>
<div class="body">
<div class="teams">
<div class="team">
2021-01-06 19:14:19 +00:00
<div class="team_name">{{ state.away_name | escape }}</div>
2021-01-02 11:21:53 +00:00
<div class="score">{{ state.away_score }}</div>
</div>
<div class="team">
2021-01-06 19:14:19 +00:00
<div class="team_name">{{ state.home_name | escape }}</div>
2021-01-02 11:21:53 +00:00
<div class="score">{{ state.home_score }}</div>
</div>
</div>
<div class="info">
<div class="field">
<img class="base base_2" {{ base(2) }}/>
<div style="display: flex;">
<img class="base base_3" {{ base(3) }}/>
<img class="base base_1" {{ base(1) }}/>
</div>
</div>
<div class="outs">
<div class="outs_title">OUTS</div>
<div class="outs_count">
<img class="out" src="{{ out(1) }}"/>
<img class="out" src="{{ out(2) }}"/>
</div>
</div>
</div>
<div class="players">
2021-01-03 20:09:31 +00:00
<div class="player_type">PITCHER</div>
2021-01-06 19:14:19 +00:00
<div class="player_name pitcher_name">{{ state.pitcher | escape }}</div>
2021-01-03 20:09:31 +00:00
<div class="player_type">BATTER</div>
2021-01-06 19:14:19 +00:00
<div class="player_name batter_name">{{ state.batter | escape }}</div>
2021-01-02 11:21:53 +00:00
</div>
<div class="update">
2021-01-06 19:14:19 +00:00
<div class="update_emoji">{{ state.update_emoji | escape }}</div>
<div class="update_text">{{ state.update_text | escape }}</div>
2021-01-02 11:21:53 +00:00
</div>
</div>
<div class="footer">
2021-01-06 19:14:19 +00:00
<div class="batting">{% if state.display_top_of_inning == true %}{{ state.away_name | escape }}{% else %}{{ state.home_name | escape }}{% endif %} batting.</div>
<div class="leagueoruser">{{ state.leagueoruser | escape }} (<a href="/game?timestamp={{ timestamp }}">share</a>)</div>
2021-01-02 11:21:53 +00:00
</div>