We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 044c2be commit d3a699fCopy full SHA for d3a699f
1 file changed
docs/javascripts/rank-table.js
@@ -103,7 +103,8 @@ document$.subscribe(() => {
103
const colorClasses = ['winner-gold', 'winner-silver', 'winner-bronze'];
104
let currentId = 0;
105
let topId = 0;
106
- while (topId < 3) {
+ top_rows_length = prepRows.length < 3 ? prepRows.length : 3
107
+ while (topId < top_rows_length) {
108
$(dt.row(prepRows[currentId]).node()).addClass(colorClasses[topId]);
109
if (getRank(prepRows[currentId]) != getRank(prepRows[currentId+1])) {
110
topId += 1;
0 commit comments