-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
70 lines (63 loc) · 1.97 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
---
layout: default
title: Scoreboard
permalink: /
nav: boxscores
---
{% assign data = site.data.boxscores %}
{% assign current_week = "" %}
{% for game in data.boxscores %}
{% if forloop.first == true %}
{% assign current_week = game.week %}
<div class="week">
{{ game.week }} – {{ game.time | date: "%B %d, %Y" }}
</div>
<div class="week-section">
{% endif %}
{% if current_week != game.week %}
<!-- close the section -->
</div>
{% assign current_week = game.week %}
<div class="week">
{{ game.week }} – {{ game.time | date: "%B %d, %Y" }}
</div>
<div class="week-section">
{% endif %}
<div class="card scoreboard p-6">
<div class="flex items-center justify-between pb-2">
<img src="{{ site.data.logos[game.away_abbr] }}" class="mini-logo" />
<h2>{{ game.away_team }}</h2>
{% if game.away_score > game.home_score %}
<h3 class="winner">{{ game.away_score }}</h3>
{% else %}
<h3>{{ game.away_score }}</h3>
{% endif %}
</div>
<div class="flex items-center justify-between">
<img src="{{ site.data.logos[game.home_abbr] }}" class="mini-logo" />
<h2>{{ game.home_team }}</h2>
{% if game.home_score > game.away_score %}
<h3 class="winner">{{ game.home_score }}</h3>
{% else %}
<h3>{{ game.home_score }}</h3>
{% endif %}
</div>
<div class="flex mt-6">
{% if game.status == "COMPLETE" or game.status == "PLAYING" or game.status == "HALFTIME" %}
<a href="/boxscores/{{game.slug}}" class="btn btn-small">
Boxscore
</a>
{% else %}
<div class="text-grey">
{{ game.kickoff }}
<span class="px">·</span>
{{ game.watch_on }}
</div>
{% endif %}
</div>
</div>
{% if forloop.last == true %}
<!-- close the section -->
</div>
{% endif %}
{% endfor %}