From a06bbdf589cf211b878cf8671a166480b3b8bf32 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20K=C3=B6nig?= Date: Mon, 6 Nov 2023 21:04:31 +0100 Subject: [PATCH] Fix styling MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Christian König --- scripts/pi-hole/js/index.js | 18 ++++++++---------- scripts/pi-hole/js/settings-system.js | 11 +++++------ 2 files changed, 13 insertions(+), 16 deletions(-) diff --git a/scripts/pi-hole/js/index.js b/scripts/pi-hole/js/index.js index 564aa6ef..cc013a34 100644 --- a/scripts/pi-hole/js/index.js +++ b/scripts/pi-hole/js/index.js @@ -13,10 +13,10 @@ var queryTypePieChart, forwardDestinationPieChart; // Register the ChartDeferred plugin to all charts: Chart.register(ChartDeferred); -Chart.defaults.set('plugins.deferred', { - yOffset: '50%', - delay: 500 -}) +Chart.defaults.set("plugins.deferred", { + yOffset: "50%", + delay: 500, +}); // Functions to update data in page @@ -120,8 +120,7 @@ function updateQueryTypesPie() { $("#query-types-pie .overlay").hide(); // Passing 'none' will prevent rotation animation for further updates //https://www.chartjs.org/docs/latest/developers/updates.html#preventing-animations - queryTypePieChart.update('none'); - + queryTypePieChart.update("none"); }) .done(function () { // Reload graph after minute @@ -243,9 +242,8 @@ function updateForwardDestinationsPie() { // Passing 'none' will prevent rotation animation for further updates //https://www.chartjs.org/docs/latest/developers/updates.html#preventing-animations - queryTypePieChart.update('none'); - forwardDestinationPieChart.update('none'); - + queryTypePieChart.update("none"); + forwardDestinationPieChart.update("none"); }) .done(function () { // Reload graph after one minute @@ -522,7 +520,7 @@ $(function () { }, border: { display: false, - } + }, }, }, elements: { diff --git a/scripts/pi-hole/js/settings-system.js b/scripts/pi-hole/js/settings-system.js index 9befc225..417c137a 100644 --- a/scripts/pi-hole/js/settings-system.js +++ b/scripts/pi-hole/js/settings-system.js @@ -14,10 +14,10 @@ var cacheSize = 0, // Register the ChartDeferred plugin to all charts: Chart.register(ChartDeferred); -Chart.defaults.set('plugins.deferred', { - yOffset: '50%', - delay: 500 -}) +Chart.defaults.set("plugins.deferred", { + yOffset: "50%", + delay: 500, +}); function updateCachePie(data) { var v = [], @@ -78,8 +78,7 @@ function updateCachePie(data) { $("#cache-pie-chart .overlay").hide(); // Passing 'none' will prevent rotation animation for further updates //https://www.chartjs.org/docs/latest/developers/updates.html#preventing-animations - cachePieChart.update('none'); - + cachePieChart.update("none"); } function updateHostInfo() {