pytron-web/views/index.pug

59 lines
2.7 KiB
Plaintext
Raw Normal View History

2019-03-20 16:52:01 +01:00
extends base
block content
section.section
.container
2019-03-26 15:07:36 +01:00
if running
.columns.is-centered
.column.is-narrow.is-desktop
h5.title.is-5 Some battles are running...
2019-03-20 16:52:01 +01:00
.columns.is-centered
.column.is-narrow.is-desktop
table.table.is-bordered.is-striped.is-hoverable
tr
th.has-text-centered AI
2019-03-26 12:24:36 +01:00
th.has-text-centered Victories
th.has-text-centered Nulls
th.has-text-centered Defeats
2019-03-20 16:52:01 +01:00
th.has-text-centered Score
2019-03-26 15:07:36 +01:00
for ai in data.sortedAis
2019-03-20 16:52:01 +01:00
tr
td.has-text-centered
2019-03-20 17:13:06 +01:00
strong= ai.name
2019-03-26 15:08:42 +01:00
td.has-text-centered= ai.victories
td.has-text-centered= ai.nulls
td.has-text-centered= ai.defeats
2019-03-26 12:24:36 +01:00
td.has-text-centered
strong= ai.score
2019-03-27 09:12:49 +01:00
.columns.is-centered
.column.is-narrow
caption
strong Leaderboard
2019-03-20 16:52:01 +01:00
2019-03-27 09:12:49 +01:00
.columns.is-centered
.column.is-narrow.is-desktop
table.table.is-bordered.is-striped.is-narrow.is-hoverable
tr
th
for ai in data.ais
th.has-text-centered= ai.name
for ai1 in data.ais
tr
th.has-text-centered= ai1.name
for ai2 in data.ais
if ai1.name == ai2.name
td
else if data.battles[ai1.name + "/" + ai2.name] > data.battles[ai2.name + "/" + ai1.name]
td.has-text-centered.has-text-success= data.battles[ai1.name + "/" + ai2.name]
else if data.battles[ai1.name + "/" + ai2.name] < data.battles[ai2.name + "/" + ai1.name]
td.has-text-centered.has-text-danger= data.battles[ai1.name + "/" + ai2.name]
else
td.has-text-centered= data.battles[ai1.name + "/" + ai2.name]
.columns.is-centered
.column.is-narrow
caption
strong All battles
2019-03-20 16:52:01 +01:00