|
|
|
@ -220,17 +220,20 @@ const Diagram = { |
|
|
|
|
const c2 = data.countries[t2.cId]; |
|
|
|
|
|
|
|
|
|
const game = data.tourneys[eventKey].games.find(v => { |
|
|
|
|
return (v.t1 === t1.tId || v.t1 === t2.tId) && (v.t2 === t1.tId || v.t2 === t2.tId); |
|
|
|
|
}); |
|
|
|
|
return (v.t1 === t1.tId || v.t1 === t2.tId) && (v.t2 === t1.tId || v.t2 === t2.tId); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
const e1 = game.se1 ? `(+${game.se1} in extended time)` : ''; |
|
|
|
|
const e2 = game.se2 ? `(+${game.se2} in extended time)` : ''; |
|
|
|
|
const s1 = game.t1 === t1.tId ? game.s1 : game.s2; |
|
|
|
|
const s2 = game.t2 === t2.tId ? game.s2 : game.s1; |
|
|
|
|
|
|
|
|
|
const e1 = game.se1 ? `(+${game.se1} in extended time)` : ''; |
|
|
|
|
const e2 = game.se2 ? `(+${game.se2} in extended time)` : ''; |
|
|
|
|
|
|
|
|
|
const p1 = game.sp1 ? `(+${game.sp1} in penalties)` : ''; |
|
|
|
|
const p2 = game.sp2 ? `(+${game.sp2} in penalties)` : ''; |
|
|
|
|
const p1 = game.sp1 ? `(+${game.sp1} in penalties)` : ''; |
|
|
|
|
const p2 = game.sp2 ? `(+${game.sp2} in penalties)` : ''; |
|
|
|
|
|
|
|
|
|
return `${c1}: ${game.s1} ${e1} ${p1}\n${c2}: ${game.s2} ${e2} ${p2}\n${data.rounds[game.rId]}`; |
|
|
|
|
}); |
|
|
|
|
return `${c1}: ${s1} ${e1} ${p1}\n${c2}: ${s2} ${e2} ${p2}\n${data.rounds[game.rId]}`; |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
group.append("text") |
|
|
|
|
.each(function(d) { d.angle = (d.startAngle + d.endAngle) / 2; }) |
|
|
|
|