From a6f8d571cf60dfe96a0f69942dc8c6db66ad8530 Mon Sep 17 00:00:00 2001 From: Rashid Khan Date: Wed, 17 Apr 2013 10:19:16 -0700 Subject: [PATCH] reorganized pie panel editor, added option to change legend position --- common/css/main.css | 4 ++++ panels/pie/editor.html | 43 +++++++++++++++++++++++------------------- panels/pie/module.html | 6 +++++- panels/pie/module.js | 4 ++-- 4 files changed, 35 insertions(+), 22 deletions(-) diff --git a/common/css/main.css b/common/css/main.css index c38f566e8cf..1d72620a14d 100644 --- a/common/css/main.css +++ b/common/css/main.css @@ -106,6 +106,10 @@ font-size: 85%; } +.input-append label { + font-size: inherit !important; +} + .large { font-size: 120%; } diff --git a/panels/pie/editor.html b/panels/pie/editor.html index a3059a243a2..4a9b1d1f4b9 100644 --- a/panels/pie/editor.html +++ b/panels/pie/editor.html @@ -1,28 +1,32 @@
-
-
+
+
+ + +
+
-
Field
+
-
+
-
Query
+
-
-
Length
+
+
-
+
-
Exclude Terms(s) (comma seperated)
+
@@ -30,16 +34,20 @@
-
+
+
+ + +
-
Goal
+
-
+
-
Query
+
@@ -54,15 +62,12 @@
-
- -
-
- - +
+ +
Panel Spy
diff --git a/panels/pie/module.html b/panels/pie/module.html index 3a78b2b9dfd..a8ca59bf55b 100644 --- a/panels/pie/module.html +++ b/panels/pie/module.html @@ -3,10 +3,14 @@ -
+
{{query.label}} ({{query.data[0][1]}})

+ +
+
{{query.label}} ({{query.data[0][1]}}) +
\ No newline at end of file diff --git a/panels/pie/module.js b/panels/pie/module.js index 709363ca192..0c3e8d5502f 100644 --- a/panels/pie/module.js +++ b/panels/pie/module.js @@ -12,7 +12,7 @@ angular.module('kibana.pie', []) labels : true, mode : "terms", group : "default", - default_field : '_all', + default_field : 'DEFAULT', spyable : true, } _.defaults($scope.panel,_d) @@ -122,7 +122,7 @@ angular.module('kibana.pie', []) var complete = results.hits.total; var remaining = $scope.panel.query.goal - complete; $scope.data = [ - { label : 'Complete', data : complete, color: '#51A351' }, + { label : 'Complete', data : complete, color: '#86B22D' }, { data : remaining, color: '#EEE'}] $scope.$emit('render'); });