From 3dae915b23b55a74e7efc9f2fafcaf43aa065bfb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torkel=20=C3=96degaard?= Date: Fri, 15 Feb 2019 21:33:36 +0100 Subject: [PATCH] Bar gauge icon updated --- pkg/api/frontendsettings.go | 12 +- .../panel/bargauge/img/icon_bar_gauge.svg | 148 +++++++++--------- public/app/plugins/panel/bargauge/types.ts | 6 +- public/app/plugins/panel/gauge/types.ts | 2 +- 4 files changed, 80 insertions(+), 88 deletions(-) diff --git a/pkg/api/frontendsettings.go b/pkg/api/frontendsettings.go index d13f0a26ab0..f0821f75324 100644 --- a/pkg/api/frontendsettings.go +++ b/pkg/api/frontendsettings.go @@ -191,16 +191,18 @@ func getPanelSort(id string) int { sort = 2 case "gauge": sort = 3 - case "table": + case "bargauge": sort = 4 - case "text": + case "table": sort = 5 - case "heatmap": + case "text": sort = 6 - case "alertlist": + case "heatmap": sort = 7 - case "dashlist": + case "alertlist": sort = 8 + case "dashlist": + sort = 9 } return sort } diff --git a/public/app/plugins/panel/bargauge/img/icon_bar_gauge.svg b/public/app/plugins/panel/bargauge/img/icon_bar_gauge.svg index a305d2d912e..2da2cc78196 100644 --- a/public/app/plugins/panel/bargauge/img/icon_bar_gauge.svg +++ b/public/app/plugins/panel/bargauge/img/icon_bar_gauge.svg @@ -14,89 +14,83 @@ .st7{fill:url(#SVGID_8_);} .st8{fill:url(#SVGID_9_);} + + + + + - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - + + + + + + diff --git a/public/app/plugins/panel/bargauge/types.ts b/public/app/plugins/panel/bargauge/types.ts index dcef36716a4..fd267e79d76 100644 --- a/public/app/plugins/panel/bargauge/types.ts +++ b/public/app/plugins/panel/bargauge/types.ts @@ -18,10 +18,6 @@ export const PanelDefaults: BarGaugeOptions = { suffix: '', stat: 'avg', unit: 'none', - thresholds: [ - { index: 2, value: 80, color: 'red' }, - { index: 1, value: 50, color: 'orange' }, - { index: 0, value: -Infinity, color: 'green' }, - ], + thresholds: [{ index: 2, value: 80, color: 'red' }, { index: 0, value: -Infinity, color: 'green' }], valueMappings: [], }; diff --git a/public/app/plugins/panel/gauge/types.ts b/public/app/plugins/panel/gauge/types.ts index 4cdb4fcdd7b..053a4a15d04 100644 --- a/public/app/plugins/panel/gauge/types.ts +++ b/public/app/plugins/panel/gauge/types.ts @@ -25,5 +25,5 @@ export const PanelDefaults: GaugeOptions = { stat: 'avg', unit: 'none', valueMappings: [], - thresholds: [], + thresholds: [{ index: 1, value: 80, color: 'red' }, { index: 0, value: -Infinity, color: 'green' }], };