glib-web 3.2.0 → 3.3.0
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 +4 -4
- data/app/helpers/glib/json_ui/view_builder/charts.rb +4 -1
- data/app/helpers/glib/json_ui/view_builder/fields.rb +1 -0
- data/app/helpers/glib/json_ui/view_builder/panels.rb +3 -3
- data/app/views/json_ui/garage/forms/otp_field.json.jbuilder +16 -0
- data/app/views/json_ui/garage/views/charts.json.jbuilder +6 -3
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 59e6e70dde41beec5d9c0bf837e0f28d64cebe37ddaa3fa25f27b27e82c6dd6a
|
4
|
+
data.tar.gz: b2ef47c7d8777e4bf1eb47362300f6e607ba65df40a62df308f54afa6dca7fb2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 654fb0f66f3d3bb996a66c093d09d19d81c33230a413caa2d79d696bd16cf55c0c4f6fb0364b40da3785ab9012b34e97ea82b5108c26b7ad9feb70d80ae02c62
|
7
|
+
data.tar.gz: d14d4c9851cdbad8dd123020204210fa08c189f56215d25f24bc75229a6b953be6c210dfc086a6982e05b9e8af5077b161e39c796cb92480737f89e141e46d2a
|
@@ -36,7 +36,7 @@ class Glib::JsonUi::ViewBuilder
|
|
36
36
|
|
37
37
|
class Line < View
|
38
38
|
include Series
|
39
|
-
|
39
|
+
array :colors
|
40
40
|
# idea for the future
|
41
41
|
# hash :nextPage
|
42
42
|
end
|
@@ -45,15 +45,18 @@ class Glib::JsonUi::ViewBuilder
|
|
45
45
|
include Series
|
46
46
|
|
47
47
|
bool :stacked
|
48
|
+
array :colors
|
48
49
|
end
|
49
50
|
|
50
51
|
class Pie < View
|
51
52
|
include Series
|
53
|
+
array :colors
|
52
54
|
|
53
55
|
end
|
54
56
|
|
55
57
|
class Area < View
|
56
58
|
include Series
|
59
|
+
array :colors
|
57
60
|
end
|
58
61
|
|
59
62
|
end
|
@@ -39,15 +39,15 @@ class Glib::JsonUi::ViewBuilder
|
|
39
39
|
end
|
40
40
|
|
41
41
|
def field_label(prop, args)
|
42
|
-
I18n.t("dt_models.#{@model_name}.#{prop}.label", args.merge(default: nil)) || I18n.t("activerecord.attributes.#{@model_name}.#{prop}", args)
|
42
|
+
I18n.t("dt_models.#{@model_name}.#{prop}.label", **args.merge(default: nil)) || I18n.t("activerecord.attributes.#{@model_name}.#{prop}", **args)
|
43
43
|
end
|
44
44
|
|
45
45
|
def hint_label(prop, args)
|
46
|
-
I18n.t("dt_models.#{@model_name}.#{prop}.hint", args.merge(default: nil))
|
46
|
+
I18n.t("dt_models.#{@model_name}.#{prop}.hint", **args.merge(default: nil))
|
47
47
|
end
|
48
48
|
|
49
49
|
def placeholder_label(prop, args)
|
50
|
-
I18n.t("dt_models.#{@model_name}.#{prop}.placeholder", args.merge(default: nil))
|
50
|
+
I18n.t("dt_models.#{@model_name}.#{prop}.placeholder", **args.merge(default: nil))
|
51
51
|
end
|
52
52
|
|
53
53
|
def field_validation(prop)
|
@@ -33,6 +33,22 @@ page.form \
|
|
33
33
|
length: 20,
|
34
34
|
type: 'text'
|
35
35
|
|
36
|
+
form.spacer height: 20
|
37
|
+
form.h2 text: 'OTP with Value If'
|
38
|
+
form.fields_otp name: 'user[otp_summary4]', width: 'matchParent', value: 60000, length: 5
|
39
|
+
form.fields_otp name: 'user[otp_summary5]', width: 'matchParent', length: 5, valueIf: {
|
40
|
+
"*": [
|
41
|
+
{
|
42
|
+
"var": 'user[otp_summary4]'
|
43
|
+
},
|
44
|
+
(20/100.to_f)
|
45
|
+
]
|
46
|
+
}
|
47
|
+
|
48
|
+
form.spacer height: 20
|
49
|
+
form.h2 text: 'OTP with Alignment right'
|
50
|
+
form.fields_otp name: 'user[otp_summary6]', width: 'matchParent', type: 'text', value: '1234', align: 'right', length: 5
|
51
|
+
|
36
52
|
form.spacer height: 20
|
37
53
|
form.fields_submit text: 'Submit'
|
38
54
|
end
|
@@ -42,7 +42,8 @@ else
|
|
42
42
|
}
|
43
43
|
json.points points.map { |k, v| { x: k, y: v } }
|
44
44
|
end
|
45
|
-
]
|
45
|
+
],
|
46
|
+
colors: ['#79AC78', '#3085C3']
|
46
47
|
|
47
48
|
# scroll.spacer height: 20
|
48
49
|
# scroll.h1 text: 'Line chart using remote data'
|
@@ -77,7 +78,8 @@ else
|
|
77
78
|
}
|
78
79
|
json.points points
|
79
80
|
end
|
80
|
-
]
|
81
|
+
],
|
82
|
+
colors: ['#b00', '#666', '#E55604']
|
81
83
|
|
82
84
|
scroll.h2 text: 'Column chart (Stacked)'
|
83
85
|
scroll.charts_column stacked: true, dataGroups: [
|
@@ -140,7 +142,8 @@ else
|
|
140
142
|
json.title 'June'
|
141
143
|
json.value 20
|
142
144
|
end
|
143
|
-
]
|
145
|
+
],
|
146
|
+
colors: ['#5B0888']
|
144
147
|
end
|
145
148
|
end
|
146
149
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: glib-web
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.
|
4
|
+
version: 3.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ''
|
@@ -318,7 +318,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
318
318
|
- !ruby/object:Gem::Version
|
319
319
|
version: '0'
|
320
320
|
requirements: []
|
321
|
-
rubygems_version: 3.1.
|
321
|
+
rubygems_version: 3.1.6
|
322
322
|
signing_key:
|
323
323
|
specification_version: 4
|
324
324
|
summary: ''
|