highcharts-rails 3.0.9 → 3.0.10

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Highcharts JS v3.0.9 (2014-01-15)
2
+ * @license Highcharts JS v3.0.10 (2014-03-10)
3
3
  * Exporting module
4
4
  *
5
5
  * (c) 2010-2014 Torstein Honsi
@@ -27,7 +27,7 @@ defaultPlotOptions.funnel = merge(defaultPlotOptions.pie, {
27
27
  neckWidth: '30%',
28
28
  height: '100%',
29
29
  neckHeight: '25%',
30
-
30
+ reversed: false,
31
31
  dataLabels: {
32
32
  //position: 'right',
33
33
  connectorWidth: 1,
@@ -48,6 +48,7 @@ seriesTypes.funnel = Highcharts.extendClass(seriesTypes.pie, {
48
48
 
49
49
  type: 'funnel',
50
50
  animate: noop,
51
+ singularTooltips: true,
51
52
 
52
53
  /**
53
54
  * Overrides the pie translate method
@@ -65,10 +66,11 @@ seriesTypes.funnel = Highcharts.extendClass(seriesTypes.pie, {
65
66
  sum = 0,
66
67
  series = this,
67
68
  chart = series.chart,
69
+ options = series.options,
70
+ reversed = options.reversed,
68
71
  plotWidth = chart.plotWidth,
69
72
  plotHeight = chart.plotHeight,
70
73
  cumulative = 0, // start at top
71
- options = series.options,
72
74
  center = options.center,
73
75
  centerX = getLength(center[0], plotWidth),
74
76
  centerY = getLength(center[0], plotHeight),
@@ -99,7 +101,7 @@ seriesTypes.funnel = Highcharts.extendClass(seriesTypes.pie, {
99
101
  neckWidth + (width - neckWidth) * ((height - neckHeight - y) / (height - neckHeight));
100
102
  };
101
103
  series.getX = function (y, half) {
102
- return centerX + (half ? -1 : 1) * ((getWidthAt(y) / 2) + options.dataLabels.distance);
104
+ return centerX + (half ? -1 : 1) * ((getWidthAt(reversed ? plotHeight - y : y) / 2) + options.dataLabels.distance);
103
105
  };
104
106
 
105
107
  // Expose
@@ -163,6 +165,11 @@ seriesTypes.funnel = Highcharts.extendClass(seriesTypes.pie, {
163
165
  y3 = neckY;
164
166
  }
165
167
 
168
+ if (reversed) {
169
+ y1 = height - y1;
170
+ y3 = height - y3;
171
+ y5 = (y5 ? height - y5 : null);
172
+ }
166
173
  // save the path
167
174
  path = [
168
175
  'M',
@@ -199,10 +206,7 @@ seriesTypes.funnel = Highcharts.extendClass(seriesTypes.pie, {
199
206
  point.half = half;
200
207
 
201
208
  cumulative += fraction;
202
- });
203
-
204
-
205
- series.setTooltipPoints();
209
+ });
206
210
  },
207
211
  /**
208
212
  * Draw a single point (wedge)
@@ -239,7 +243,11 @@ seriesTypes.funnel = Highcharts.extendClass(seriesTypes.pie, {
239
243
  /**
240
244
  * Funnel items don't have angles (#2289)
241
245
  */
242
- sortByAngle: noop,
246
+ sortByAngle: function (points) {
247
+ points.sort(function (a, b) {
248
+ return a.plotY - b.plotY;
249
+ });
250
+ },
243
251
 
244
252
  /**
245
253
  * Extend the pie data label method
@@ -285,5 +293,17 @@ seriesTypes.funnel = Highcharts.extendClass(seriesTypes.pie, {
285
293
 
286
294
  });
287
295
 
296
+ /**
297
+ * Pyramid series type.
298
+ * A pyramid series is a special type of funnel, without neck and reversed by default.
299
+ */
300
+ defaultOptions.plotOptions.pyramid = Highcharts.merge(defaultOptions.plotOptions.funnel, {
301
+ neckWidth: '0%',
302
+ neckHeight: '0%',
303
+ reversed: true
304
+ });
305
+ Highcharts.seriesTypes.pyramid = Highcharts.extendClass(Highcharts.seriesTypes.funnel, {
306
+ type: 'pyramid'
307
+ });
288
308
 
289
309
  }(Highcharts));
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Highcharts JS v3.0.9 (2014-01-15)
2
+ * @license Highcharts JS v3.0.10 (2014-03-10)
3
3
  * Plugin for displaying a message when there is no data visible in chart.
4
4
  *
5
5
  * (c) 2010-2014 Highsoft AS
@@ -44,7 +44,9 @@
44
44
  return !!this.points.length; /* != 0 */
45
45
  }
46
46
 
47
- seriesTypes.pie.prototype.hasData = hasDataPie;
47
+ if (seriesTypes.pie) {
48
+ seriesTypes.pie.prototype.hasData = hasDataPie;
49
+ }
48
50
 
49
51
  if (seriesTypes.gauge) {
50
52
  seriesTypes.gauge.prototype.hasData = hasDataPie;
@@ -15,7 +15,7 @@ Highcharts.theme = {
15
15
  ]
16
16
  },
17
17
  borderWidth: 0,
18
- borderRadius: 15,
18
+ borderRadius: 0,
19
19
  plotBackgroundColor: null,
20
20
  plotShadow: false,
21
21
  plotBorderWidth: 0
@@ -102,7 +102,7 @@ Highcharts.theme = {
102
102
 
103
103
  plotOptions: {
104
104
  series: {
105
- shadow: true
105
+ nullColor: '#444444'
106
106
  },
107
107
  line: {
108
108
  dataLabels: {
@@ -1,3 +1,3 @@
1
1
  module Highcharts
2
- VERSION = "3.0.9"
2
+ VERSION = "3.0.10"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: highcharts-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.9
4
+ version: 3.0.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Per Christian B. Viken
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-01-15 00:00:00.000000000 Z
11
+ date: 2014-03-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties
metadata.gz.asc CHANGED
@@ -2,17 +2,17 @@
2
2
  Version: GnuPG/MacGPG2 v2.0.22 (Darwin)
3
3
  Comment: GPGTools - http://gpgtools.org
4
4
 
5
- iQIcBAABAgAGBQJS1mNAAAoJEH1ncb0Txu7XfV4P/05oGakw9qagcBIc6WuZdZnu
6
- iIuVVp2bHuMWgwaogJtEAINLR/6egMzAvsHKte/tdVJccEQ2xDaCI6o8bvl7DXhu
7
- Rssn1xaNW2ov3IVPMXlB6gpo4RVKrLWaJp2ZXvO/owqUG/mvmIWnkZdbRvoc4NTg
8
- /GZz/ftwsaKmB7QmOXfbhafpIiCh6b3pYAbby603u+upqcmO4vwQaDhdpaPVjLCI
9
- qyf8M6JQkJOCu3H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