apexcharts 0.1.9 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (34) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +149 -56
  3. data/lib/apex_charts/charts/base_chart.rb +1 -1
  4. data/lib/apex_charts/charts/box_plot_chart.rb +9 -0
  5. data/lib/apex_charts/charts.rb +1 -0
  6. data/lib/apex_charts/helper.rb +9 -8
  7. data/lib/apex_charts/options_builder.rb +146 -123
  8. data/lib/apex_charts/renderer.rb +69 -25
  9. data/lib/apex_charts/series/bubble_series.rb +2 -3
  10. data/lib/apex_charts/series/cartesian_series.rb +8 -2
  11. data/lib/apex_charts/theme.rb +0 -16
  12. data/lib/apex_charts/version.rb +2 -1
  13. data/vendor/assets/javascripts/apexcharts.js +5 -5
  14. metadata +4 -51
  15. data/lib/apex_charts/options/annotations_options.rb +0 -12
  16. data/lib/apex_charts/options/axis_options.rb +0 -19
  17. data/lib/apex_charts/options/chart_options.rb +0 -28
  18. data/lib/apex_charts/options/data_labels_options.rb +0 -16
  19. data/lib/apex_charts/options/div_attributes.rb +0 -11
  20. data/lib/apex_charts/options/fill_options.rb +0 -14
  21. data/lib/apex_charts/options/grid_options.rb +0 -17
  22. data/lib/apex_charts/options/legend_options.rb +0 -29
  23. data/lib/apex_charts/options/markers_options.rb +0 -20
  24. data/lib/apex_charts/options/no_data_options.rb +0 -14
  25. data/lib/apex_charts/options/plot_options.rb +0 -14
  26. data/lib/apex_charts/options/root_options.rb +0 -46
  27. data/lib/apex_charts/options/states_options.rb +0 -11
  28. data/lib/apex_charts/options/stroke_options.rb +0 -14
  29. data/lib/apex_charts/options/theme_options.rb +0 -10
  30. data/lib/apex_charts/options/title_subtitle_options.rb +0 -15
  31. data/lib/apex_charts/options/tooltip_options.rb +0 -24
  32. data/lib/apex_charts/options/x_axis_options.rb +0 -14
  33. data/lib/apex_charts/options/y_axis_options.rb +0 -18
  34. data/lib/apexcharts/prefix_with_apex.rb +0 -20
metadata CHANGED
@@ -1,29 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: apexcharts
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.9
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Adrian Setyadi
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-04-05 00:00:00.000000000 Z
11
+ date: 2022-02-28 00:00:00.000000000 Z
12
12
  dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: smart_kv
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - "~>"
18
- - !ruby/object:Gem::Version
19
- version: 0.2.8
20
- type: :runtime
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - "~>"
25
- - !ruby/object:Gem::Version
26
- version: 0.2.8
27
13
  - !ruby/object:Gem::Dependency
28
14
  name: bundler
29
15
  requirement: !ruby/object:Gem::Requirement
@@ -38,20 +24,6 @@ dependencies:
38
24
  - - ">="
39
25
  - !ruby/object:Gem::Version
40
26
  version: '0'
41
- - !ruby/object:Gem::Dependency
42
- name: coveralls
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - ">="
46
- - !ruby/object:Gem::Version
47
- version: '0'
48
- type: :development
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - ">="
53
- - !ruby/object:Gem::Version
54
- version: '0'
55
27
  - !ruby/object:Gem::Dependency
56
28
  name: nokogiri
57
29
  requirement: !ruby/object:Gem::Requirement
@@ -150,6 +122,7 @@ files:
150
122
  - lib/apex_charts/charts/area_chart.rb
151
123
  - lib/apex_charts/charts/bar_chart.rb
152
124
  - lib/apex_charts/charts/base_chart.rb
125
+ - lib/apex_charts/charts/box_plot_chart.rb
153
126
  - lib/apex_charts/charts/bubble_chart.rb
154
127
  - lib/apex_charts/charts/candlestick_chart.rb
155
128
  - lib/apex_charts/charts/cartesian_chart.rb
@@ -171,25 +144,6 @@ files:
171
144
  - lib/apex_charts/config/default_options.rb
172
145
  - lib/apex_charts/configuration.rb
173
146
  - lib/apex_charts/helper.rb
174
- - lib/apex_charts/options/annotations_options.rb
175
- - lib/apex_charts/options/axis_options.rb
176
- - lib/apex_charts/options/chart_options.rb
177
- - lib/apex_charts/options/data_labels_options.rb
178
- - lib/apex_charts/options/div_attributes.rb
179
- - lib/apex_charts/options/fill_options.rb
180
- - lib/apex_charts/options/grid_options.rb
181
- - lib/apex_charts/options/legend_options.rb
182
- - lib/apex_charts/options/markers_options.rb
183
- - lib/apex_charts/options/no_data_options.rb
184
- - lib/apex_charts/options/plot_options.rb
185
- - lib/apex_charts/options/root_options.rb
186
- - lib/apex_charts/options/states_options.rb
187
- - lib/apex_charts/options/stroke_options.rb
188
- - lib/apex_charts/options/theme_options.rb
189
- - lib/apex_charts/options/title_subtitle_options.rb
190
- - lib/apex_charts/options/tooltip_options.rb
191
- - lib/apex_charts/options/x_axis_options.rb
192
- - lib/apex_charts/options/y_axis_options.rb
193
147
  - lib/apex_charts/options_builder.rb
194
148
  - lib/apex_charts/prefix_with_apex.rb
195
149
  - lib/apex_charts/prefixer.rb
@@ -207,7 +161,6 @@ files:
207
161
  - lib/apex_charts/utils/hash.rb
208
162
  - lib/apex_charts/version.rb
209
163
  - lib/apexcharts.rb
210
- - lib/apexcharts/prefix_with_apex.rb
211
164
  - vendor/assets/javascripts/apexcharts.js
212
165
  homepage: https://github.com/styd/apexcharts.rb
213
166
  licenses:
@@ -228,7 +181,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
228
181
  - !ruby/object:Gem::Version
229
182
  version: '0'
230
183
  requirements: []
231
- rubygems_version: 3.1.2
184
+ rubygems_version: 3.3.8
232
185
  signing_key:
233
186
  specification_version: 4
234
187
  summary: Awesome charts for your ruby app
@@ -1,12 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class AnnotationsOptions < ::SmartKv
5
- optional *%i[
6
- points
7
- position
8
- xaxis
9
- yaxis
10
- ]
11
- end
12
- end
@@ -1,19 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class AxisOptions < ::SmartKv
5
- optional *%i[
6
- axisBorder
7
- axisTicks
8
- crosshairs
9
- floating
10
- labels
11
- max
12
- min
13
- tickAmount
14
- title
15
- tooltip
16
- type
17
- ]
18
- end
19
- end
@@ -1,28 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class ChartOptions < ::SmartKv
5
- optional *%i[
6
- animations
7
- background
8
- brush
9
- defaultLocale
10
- dropShadow
11
- events
12
- fontFamily
13
- foreColor
14
- height
15
- id
16
- locales
17
- parentHeightOffset
18
- selection
19
- sparkline
20
- stackType
21
- stacked
22
- toolbar
23
- type
24
- width
25
- zoom
26
- ]
27
- end
28
- end
@@ -1,16 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class DataLabelsOptions < ::SmartKv
5
- optional *%i[
6
- dropShadow
7
- enabled
8
- enabledOnSeries
9
- formatter
10
- offsetX
11
- offsetY
12
- style
13
- textAnchor
14
- ]
15
- end
16
- end
@@ -1,11 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class DivAttributes < ::SmartKv
5
- optional *%i[
6
- class
7
- id
8
- style
9
- ]
10
- end
11
- end
@@ -1,14 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class FillOptions < ::SmartKv
5
- optional *%i[
6
- colors
7
- gradient
8
- image
9
- opacity
10
- pattern
11
- type
12
- ]
13
- end
14
- end
@@ -1,17 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class GridOptions < ::SmartKv
5
- optional *%i[
6
- borderColor
7
- column
8
- padding
9
- position
10
- row
11
- show
12
- strokeDashArray
13
- xaxis
14
- yaxis
15
- ]
16
- end
17
- end
@@ -1,29 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class LegendOptions < ::SmartKv
5
- optional *%i[
6
- containerMargin
7
- floating
8
- fontFamily
9
- fontSize
10
- formatter
11
- height
12
- horizontalAlign
13
- itemMargin
14
- labels
15
- markers
16
- offsetX
17
- offsetY
18
- onItemClick
19
- onItemHover
20
- position
21
- show
22
- showForNullSeries
23
- showForSingleSeries
24
- showForZeroSeries
25
- textAnchor
26
- width
27
- ]
28
- end
29
- end
@@ -1,20 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class MarkersOptions < ::SmartKv
5
- optional *%i[
6
- colors
7
- discrete
8
- fillOpacity
9
- hover
10
- offsetX
11
- offsetY
12
- radius
13
- shape
14
- size
15
- strokeColor
16
- strokeOpacity
17
- strokeWidth
18
- ]
19
- end
20
- end
@@ -1,14 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class NoDataOptions < ::SmartKv
5
- optional *%i[
6
- align
7
- offsetX
8
- offsetY
9
- style
10
- text
11
- verticalAlign
12
- ]
13
- end
14
- end
@@ -1,14 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class PlotOptions < ::SmartKv
5
- optional *%i[
6
- bar
7
- candlestick
8
- heatmap
9
- pie
10
- radar
11
- radialBar
12
- ]
13
- end
14
- end
@@ -1,46 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require_relative 'div_attributes'
4
- require_relative 'chart_options'
5
- require_relative 'stroke_options'
6
- require_relative 'states_options'
7
-
8
- module ApexCharts::Options
9
- class RootOptions < ::SmartKv
10
- optional *%i[
11
- annotations
12
- brushTarget
13
- chart
14
- chartId
15
- colors
16
- dataLabels
17
- fill
18
- grid
19
- group
20
- labels
21
- legend
22
- markers
23
- noData
24
- plotOptions
25
- responsive
26
- series
27
- states
28
- stroke
29
- subtitle
30
- theme
31
- title
32
- tooltip
33
- var
34
- xaxis
35
- xtitle
36
- xtype
37
- yaxis
38
- ytitle
39
- ytype
40
- ],
41
- *DivAttributes.optional_keys,
42
- *ChartOptions.optional_keys,
43
- *StrokeOptions.optional_keys,
44
- *StatesOptions.optional_keys
45
- end
46
- end
@@ -1,11 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class StatesOptions < ::SmartKv
5
- optional *%i[
6
- active
7
- hover
8
- normal
9
- ]
10
- end
11
- end
@@ -1,14 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class StrokeOptions < ::SmartKv
5
- optional *%i[
6
- colors
7
- curve
8
- dashArray
9
- lineCap
10
- show
11
- width
12
- ]
13
- end
14
- end
@@ -1,10 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class ThemeOptions < ::SmartKv
5
- optional *%i[
6
- monochrome
7
- palette
8
- ]
9
- end
10
- end
@@ -1,15 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class TitleSubtitleOptions < ::SmartKv
5
- optional *%i[
6
- align
7
- floating
8
- margin
9
- offsetX
10
- offsetY
11
- style
12
- text
13
- ]
14
- end
15
- end
@@ -1,24 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module ApexCharts::Options
4
- class TooltipOptions < ::SmartKv
5
- optional *%i[
6
- custom
7
- enabled
8
- fillSeriesColor
9
- fixed
10
- followCursor
11
- intersect
12
- inverseOrder
13
- items
14
- marker
15
- onDatasetHover
16
- shared
17
- style
18
- theme
19
- x
20
- y
21
- z
22
- ]
23
- end
24
- end
@@ -1,14 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require_relative 'axis_options'
4
-
5
- module ApexCharts::Options
6
- class XAxisOptions < AxisOptions
7
- optional *%i[
8
- categories
9
- position
10
- range
11
- tickPlacement
12
- ]
13
- end
14
- end
@@ -1,18 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require_relative 'axis_options'
4
-
5
- module ApexCharts::Options
6
- class YAxisOptions < AxisOptions
7
- optional *%i[
8
- decimalsInFloat
9
- forceNiceScale
10
- logarithmic
11
- opposite
12
- reversed
13
- seriesName
14
- show
15
- showAlways
16
- ]
17
- end
18
- end
@@ -1,20 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- warn <<~DEPRECATED
4
- Deprecation warning from ApexCharts.RB:
5
-
6
- Using
7
-
8
- gem 'apexcharts', require: 'apexcharts/prefix_with_apex'
9
-
10
- is DEPRECATED.
11
-
12
- Please use
13
-
14
- gem 'apexcharts', require: 'apex_charts/prefix_with_apex'
15
-
16
- instead.
17
-
18
- DEPRECATED
19
-
20
- require_relative '../apex_charts/prefix_with_apex'