mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-05 05:25:49 +01:00
disabling graph animation on mobile devices
This commit is contained in:
@@ -158,6 +158,7 @@ define('admin/general/dashboard', ['semver'], function(semver) {
|
||||
|
||||
if (isMobile) {
|
||||
Chart.defaults.global.showTooltips = false;
|
||||
Chart.defaults.global.animation = false;
|
||||
}
|
||||
|
||||
var data = {
|
||||
@@ -186,7 +187,7 @@ define('admin/general/dashboard', ['semver'], function(semver) {
|
||||
]
|
||||
};
|
||||
|
||||
trafficCanvas.width = $(trafficCanvas).parent().width(); // is this necessary
|
||||
trafficCanvas.width = $(trafficCanvas).parent().width();
|
||||
graphs.traffic = new Chart(trafficCtx).Line(data, {
|
||||
responsive: true
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user