Skip to content

Commit 46b2140

Browse files
committed
Added letters instead of hyphens
1 parent b79e0df commit 46b2140

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

src/main.ts

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,9 @@ class BracketsViewer {
193193
const team1 = this.renderTeam(results.opponent1);
194194
const team2 = this.renderTeam(results.opponent2);
195195

196-
const teams = $('<div class="teams">').append(team1).append(team2);
196+
const teams = $('<div class="teams">');
197197
if (label) teams.append($('<span>').text(label));
198+
teams.append(team1).append(team2);
198199

199200
const match = $('<div class="match">').append(teams);
200201
if (!connection) return match;
@@ -233,11 +234,19 @@ class BracketsViewer {
233234
if (team.result && team.result === 'win') {
234235
nameDOM.addClass('win');
235236
scoreDOM.addClass('win');
237+
238+
if (team.score === undefined)
239+
scoreDOM.text('W'); // Win.
236240
}
237241

238-
if (team.result && team.result === 'loss') {
242+
if (team.result && team.result === 'loss' || team.forfeit) {
239243
nameDOM.addClass('loss');
240244
scoreDOM.addClass('loss');
245+
246+
if (team.forfeit)
247+
scoreDOM.text('F'); // Forfeit.
248+
else if (team.score === undefined)
249+
scoreDOM.text('L'); // Loss.
241250
}
242251
}
243252

src/style.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ h3 {
171171
background: white;
172172
padding: 0 5px;
173173
color: #a7a7a7;
174+
border-radius: 3px;
174175
}
175176

176177
&.connect-previous {

0 commit comments

Comments
 (0)