chartjs-ror 3.6.3 → 3.6.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 907f47139b9a0d3c4cfffc12bce3c68018a00c1d87868cccfa1f263e38466691
4
- data.tar.gz: f45d427f8f291a72a47d2dd578874805b7ab4a554e5d77706ff9a703d4dcd8a9
3
+ metadata.gz: 729e3dae1f744ad547dadaf6a02c6bdb61074e1032d53f1c65c3a69bc159a664
4
+ data.tar.gz: b1f8ce563ce6c3be24852b5b346d7ae3bcbe448ace6ded3e85c7c36d00d15890
5
5
  SHA512:
6
- metadata.gz: fd064b8f231b6a77349c95d15251ee559011ba78a6032d30e1e80c5ab34b6cc122a39c8c16a452a106b9ffd18ea3b72c2af37b8164873e3c46eb905d278884fa
7
- data.tar.gz: 060c52c372bf633b33231005b60323f85e247dc3db3a8a7298264f8d2a82d6037a3b77020e9c10a3e5b2abe0de5bdb9ca4aff956be4d3dc134bdc122209547b3
6
+ metadata.gz: 509d95ce759c852cad539c8fe41cd2961e3e7434c7caa13d4126bb0b37ef75d7dc81539ca4328b1d6083a93920379146376e00c90ad75a3ed71fbf8a09cf4d52
7
+ data.tar.gz: 4c05d01c2cf142d0ab1d1aecd0d9dff17c96ab75a055952cd3b070836b741cc884a9fdeae7353838032af2e6cbfb95ff8b6b519714a851c7fd2369cd27220a26
@@ -1,6 +1,11 @@
1
1
  # CHANGELOG
2
2
 
3
3
 
4
+ ## 3.6.4 - 2019-02-27
5
+
6
+ - Add argument for plugins.
7
+
8
+
4
9
  ## 3.6.3 - 2019-02-14
5
10
 
6
11
  - Use Chart.js v2.7.3.
@@ -8,25 +8,25 @@ module Chartjs
8
8
 
9
9
  module Explicit
10
10
  CHART_TYPES.each do |type|
11
- define_method "chartjs_#{type}_chart" do |data, options = {}| # def chartjs_polar_area_chart(data, options = {})
12
- chart type, data, options # chart 'polar_area', data, options
13
- end # end
11
+ define_method "chartjs_#{type}_chart" do |data, options = {}, plugins = {}| # def chartjs_polar_area_chart(data, options = {}, plugins = {})
12
+ chart type, data, options, plugins # chart 'polar_area', data, options, plugins
13
+ end # end
14
14
  end
15
15
  include Chartjs::ChartHelpers
16
16
  end
17
17
 
18
18
  module Implicit
19
19
  CHART_TYPES.each do |type|
20
- define_method "#{type}_chart" do |data, options = {}| # def polar_area_chart(data, options = {})
21
- chart type, data, options # chart 'polar_area', data, options
22
- end # end
20
+ define_method "#{type}_chart" do |data, options = {}, plugins = {}| # def polar_area_chart(data, options = {}, plugins = {})
21
+ chart type, data, options, plugins # chart 'polar_area', data, options, plugins
22
+ end # end
23
23
  end
24
24
  include Chartjs::ChartHelpers
25
25
  end
26
26
 
27
27
  private
28
28
 
29
- def chart(type, data, options)
29
+ def chart(type, data, options, plugins)
30
30
  opts = options.dup
31
31
 
32
32
  @chart_id ||= -1
@@ -45,7 +45,8 @@ module Chartjs
45
45
  var chart = new Chart(ctx, {
46
46
  type: "#{camel_case type}",
47
47
  data: #{to_javascript_string data},
48
- options: #{to_javascript_string opts}
48
+ options: #{to_javascript_string opts},
49
+ plugins: #{to_javascript_string plugins},
49
50
  });
50
51
  };
51
52
 
@@ -1,3 +1,3 @@
1
1
  module Chartjs
2
- VERSION = "3.6.3"
2
+ VERSION = "3.6.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chartjs-ror
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.6.3
4
+ version: 3.6.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andy Stewart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-02-14 00:00:00.000000000 Z
11
+ date: 2019-02-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -79,8 +79,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
79
79
  - !ruby/object:Gem::Version
80
80
  version: '0'
81
81
  requirements: []
82
- rubyforge_project:
83
- rubygems_version: 2.7.3
82
+ rubygems_version: 3.0.1
84
83
  signing_key:
85
84
  specification_version: 4
86
85
  summary: Simplifies using Chart.js in Rails