fix: flicker on dashboard

v1.18.x
Barış Soner Uşaklı 4 years ago
parent d14ba1f4e1
commit 2041b8084f

@ -517,7 +517,6 @@ define('admin/dashboard', ['Chart', 'translator', 'benchpress'], function (Chart
}); });
function buildTopicsLegend() { function buildTopicsLegend() {
var legend = $('#topics-legend').html('');
var html = ''; var html = '';
topics.forEach(function (t, i) { topics.forEach(function (t, i) {
var link = t.tid ? '<a title="' + t.title + '"href="' + config.relative_path + '/topic/' + t.tid + '" target="_blank"> ' + t.title + '</a>' : t.title; var link = t.tid ? '<a title="' + t.title + '"href="' + config.relative_path + '/topic/' + t.tid + '" target="_blank"> ' + t.title + '</a>' : t.title;
@ -528,7 +527,7 @@ define('admin/dashboard', ['Chart', 'translator', 'benchpress'], function (Chart
'<span> (' + t.count + ') ' + label + '</span>' + '<span> (' + t.count + ') ' + label + '</span>' +
'</li>'; '</li>';
}); });
legend.translateHtml(html); $('#topics-legend').translateHtml(html);
} }
buildTopicsLegend(); buildTopicsLegend();

Loading…
Cancel
Save