app_rail-steps 0.2.6 → 0.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a141fb3b658dd53261624e501490700e20e8659856c107022597092a2fe29469
4
- data.tar.gz: 17a66d80b87ecb6305d88b56decf82ef5445e7d44b5062d49adef43132a3a0f0
3
+ metadata.gz: c2d5bad1ddf33cb2a28dd8fb15796f908b637f596e65ba339990abd6e023a37d
4
+ data.tar.gz: 1d8608a1a47a3dfae2ab1f2adb641fe91a1958adf1482097daa6519fd093f050
5
5
  SHA512:
6
- metadata.gz: fea4a473618b0e1129c641f9195c2cd84f8718ce1a3f6a6713aaf9eb064cc07eed26d29ef20b84e512ea6206052ac163cde9c32defe9dbcda38ccd0cc511664f
7
- data.tar.gz: c7c443db93e21aa566c7a23b73ba5cd8905f8ca25e6c1d555b5a7ae2a9bf74ec90fc8bf8f09f79a54f22742c586a5778c8dea3c2ed607a7e5a89c3e1053d73bd
6
+ metadata.gz: 8a5bc64794f64cbce9f8804d184562f8f05fccd54e68b4091521ca43955fb294c4fbb7f36e38ee47e92834df7ce204edfec01cd5aa3ab1c7ad1ca124450ba603
7
+ data.tar.gz: 4b5f215882c55f047d3fc6053846e70ab8414b86061a51e66afcbaf83015e72cb3680e8ec1a75d0e4b958e9a5f036f45ff50a6d29d642dafd8ee55e0dd58460d
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- app_rail-steps (0.2.6)
4
+ app_rail-steps (0.2.7)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -0,0 +1,49 @@
1
+ # frozen_string_literal: true
2
+
3
+ module AppRail
4
+ module Steps
5
+ module Charts
6
+ module Dashboard
7
+ def ar_charts_dashboard_statistic(id:, title:, text:)
8
+ {
9
+ id: id,
10
+ chartType: :none,
11
+ title: title,
12
+ text: text
13
+ }.compact
14
+ end
15
+
16
+ def ar_charts_dashboard_line_chart(id:, title:, values:, text: nil, footer: nil)
17
+ {
18
+ id: id,
19
+ chartType: :line,
20
+ title: title,
21
+ text: text,
22
+ footer: footer,
23
+ chartValues: values
24
+ }.compact
25
+ end
26
+
27
+ def ar_charts_dashboard_bar_chart(id:, title:, values:)
28
+ {
29
+ id: id,
30
+ chartType: :bar,
31
+ title: title,
32
+ chartValues: values
33
+ }.compact
34
+ end
35
+
36
+ def ar_charts_dashboard_bar_pie(id:, title:, values:, light_colors: nil, dark_colors: nil)
37
+ {
38
+ id: id,
39
+ chartType: :pie,
40
+ title: title,
41
+ chartValues: values,
42
+ chartColors: light_colors,
43
+ chartColorsDark: dark_colors
44
+ }.compact
45
+ end
46
+ end
47
+ end
48
+ end
49
+ end
@@ -6,6 +6,7 @@ require_relative "core_forms/form"
6
6
  require_relative "maps/map"
7
7
  require_relative "styled_content/grid"
8
8
  require_relative "styled_content/stack"
9
+ require_relative "charts/dashboard"
9
10
 
10
11
  module AppRail
11
12
  module Steps
@@ -16,6 +17,7 @@ module AppRail
16
17
  include Steps::Maps::Map
17
18
  include Steps::StyledContent::Grid
18
19
  include Steps::StyledContent::Stack
20
+ include Steps::Charts::Dashboard
19
21
 
20
22
  BUTTON_STYLES = %i[primary outline danger textOnly].freeze
21
23
  ON_SUCCESS_OPTIONS = %i[none reload backward forward].freeze
@@ -2,6 +2,6 @@
2
2
 
3
3
  module AppRail
4
4
  module Steps
5
- VERSION = "0.2.6"
5
+ VERSION = "0.2.7"
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: app_rail-steps
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.6
4
+ version: 0.2.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Brooke-Smith
@@ -27,6 +27,7 @@ files:
27
27
  - Rakefile
28
28
  - app_rail-steps.gemspec
29
29
  - lib/app_rail/steps.rb
30
+ - lib/app_rail/steps/charts/dashboard.rb
30
31
  - lib/app_rail/steps/core/list.rb
31
32
  - lib/app_rail/steps/core/stack.rb
32
33
  - lib/app_rail/steps/core_forms/form.rb