From: Mischa POSLAWSKY Date: Wed, 21 Aug 2019 23:31:55 +0000 (+0200) Subject: list last three match results X-Git-Tag: v0.5~3 X-Git-Url: http://git.shiar.nl/sc2-widget/commitdiff_plain/34a0c009755b52cc6d83b80302c4cf911d412a04 list last three match results Preliminary styling to mostly show play times. --- diff --git a/battle.css b/battle.css index cf7c4d0..bcb8c62 100644 --- a/battle.css +++ b/battle.css @@ -134,6 +134,15 @@ li, li img { background-position: -100px -150px; } +.loss:before { + color: #C11; + content: '✘'; +} +.win:before { + color: #297ACC; + content: '✔'; +} + .old { text-decoration: line-through; } @@ -153,6 +162,9 @@ body { .ladders { grid-row: 3; } +.matches { + grid-column: 1; +} @media (min-width: 576px) { .members { diff --git a/widget.html b/widget.html index 1184ab1..c2a351d 100644 --- a/widget.html +++ b/widget.html @@ -25,6 +25,8 @@ }) .then(clan => { let tiernum = (rank) => rank <= 8 ? 1 : rank <= 25 ? 2 : rank <= 50 ? 3 : 4; + let matchtime = (d) => d.getDate() + '/' + (d.getMonth() + 1) + + ' ' + d.getHours() + ":" + ('0' + d.getMinutes()).slice(-2); outcont.outerHTML = `

${clan.tag || clan.members[0].name}

+ ` document.querySelectorAll('[data-members]').forEach(li => {