glib-web 0.5.53 → 0.5.54

Sign up to get free protection for your applications and to get access to all the features.
Files changed (35) hide show
  1. checksums.yaml +4 -4
  2. data/app/channels/glib/channel/is_typing_channel.rb +0 -0
  3. data/app/controllers/concerns/glib/json/traversal.rb +0 -0
  4. data/app/controllers/glib/home_controller.rb +0 -0
  5. data/app/helpers/glib/json_ui/abstract_builder.rb +0 -0
  6. data/app/helpers/glib/json_ui/action_builder.rb +0 -0
  7. data/app/helpers/glib/json_ui/action_builder/windows.rb +5 -0
  8. data/app/helpers/glib/json_ui/list_builders.rb +0 -0
  9. data/app/helpers/glib/json_ui/page_helper.rb +0 -0
  10. data/app/helpers/glib/json_ui/response_helper.rb +0 -0
  11. data/app/helpers/glib/json_ui/view_builder.rb +0 -0
  12. data/app/helpers/glib/json_ui/view_builder/banners.rb +0 -0
  13. data/app/helpers/glib/json_ui/view_builder/fields.rb +6 -0
  14. data/app/helpers/glib/json_ui/view_builder/panels.rb +0 -0
  15. data/app/views/json_ui/garage/actions/index.json.jbuilder +0 -0
  16. data/app/views/json_ui/garage/forms/_alert_post_data.json.jbuilder +0 -0
  17. data/app/views/json_ui/garage/forms/conditional_value.json.jbuilder +0 -0
  18. data/app/views/json_ui/garage/forms/index.json.jbuilder +1 -2
  19. data/app/views/json_ui/garage/forms/pickers.json.jbuilder +64 -8
  20. data/app/views/json_ui/garage/forms/selects.json.jbuilder +0 -0
  21. data/app/views/json_ui/garage/forms/show_hide.json.jbuilder +0 -0
  22. data/app/views/json_ui/garage/forms/styled_boxes.json.jbuilder +0 -0
  23. data/app/views/json_ui/garage/forms/submission_flow.json.jbuilder +4 -4
  24. data/app/views/json_ui/garage/forms/submission_flow_post.json.jbuilder +6 -4
  25. data/app/views/json_ui/garage/home/index.json.jbuilder +14 -10
  26. data/app/views/json_ui/garage/lists/_autoload_section.json.jbuilder +0 -0
  27. data/app/views/json_ui/garage/lists/edit_actions.json.jbuilder +0 -0
  28. data/app/views/json_ui/garage/lists/index.json.jbuilder +0 -0
  29. data/app/views/json_ui/garage/lists/reordering.json.jbuilder +0 -0
  30. data/app/views/json_ui/garage/notifications/action_cable.json.jbuilder +2 -2
  31. data/app/views/json_ui/garage/notifications/android_post.json.jbuilder +0 -0
  32. data/app/views/json_ui/garage/views/maps.json.jbuilder +0 -0
  33. data/lib/glib/json_crawler/router.rb +0 -0
  34. data/lib/glib/test_helpers.rb +0 -0
  35. metadata +2 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 65a2bc305ef53f9a39b851abfa09c8e760b174c74c2a8fcf41a7d04c527ef0ee
4
- data.tar.gz: 5a75ed552c05fcf47468e8d91e630dd4567d5f5028656324ef36d5d0818bd8e3
3
+ metadata.gz: b12f4b3c8c68a3186c98a87a2b5a50bdc6720d04926b042c48c21116eae6062f
4
+ data.tar.gz: 2e2423b34dc9ad34a0c8e38cbf7c5178eb71e861062dbe7dd4286f39e1a002d0
5
5
  SHA512:
6
- metadata.gz: 9ac891b106a5e45b949d523464c82152f24166bc61e274a0377108cee8a3784e97cda6b2627340d1c1fa7cb0187870a3526fd60e6e5d3da01443e24e50b60313
7
- data.tar.gz: 4e15c49028568df461f16c3de40b7c22bbfdc5e6ff2cfdd938f55e1e6263041a52f95620eef38126d7531c3ba3b10e31a1d7d2c7cb46a75d94be589d724fe9b2
6
+ metadata.gz: 1e54bfdd8bf13af51abbc7b81067acfdf2efda44cbc6c277b361e6de797898e8f597f34de810da521cfe589e7832970a23f1a7f5adcd8e5946609245f43914bc
7
+ data.tar.gz: 1fc0990f8ac4287cb011b7e818b3c470a4974aed979d8211277cb61557cece79c860e7c2ac98258cd42855ce1699cd82dc981021f3ae1362f12cb446a163aed3
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -22,5 +22,10 @@ class Glib::JsonUi::ActionBuilder
22
22
  string :url, cache: true
23
23
  action :onReload
24
24
  end
25
+
26
+ class CloseWithReload < Action
27
+ string :fallbackUrl
28
+ action :onReload
29
+ end
25
30
  end
26
31
  end
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -236,5 +236,11 @@ class Glib::JsonUi::ViewBuilder
236
236
  class CreditCard < AbstractField
237
237
  string :publicKey
238
238
  end
239
+
240
+ class Rating < AbstractField
241
+ bool :halfIncrements
242
+ string :color
243
+ int :size
244
+ end
239
245
  end
240
246
  end
File without changes
File without changes
@@ -16,7 +16,7 @@ page.list sections: [
16
16
  template.thumbnail title: "Submission Flow (timestamp: #{DateTime.current.to_i})", onClick: ->(action) do
17
17
  action.windows_open url: json_ui_garage_url(path: 'forms/submission_flow')
18
18
  end
19
- template.thumbnail title: "Submission Indicator", onClick: ->(action) do
19
+ template.thumbnail title: 'Submission Indicator', onClick: ->(action) do
20
20
  action.windows_open url: json_ui_garage_url(path: 'forms/submission_indicator')
21
21
  end
22
22
  template.thumbnail title: 'GET Request', onClick: ->(action) do
@@ -59,7 +59,6 @@ page.list sections: [
59
59
  template.thumbnail title: 'Floating Submit', onClick: ->(action) do
60
60
  action.windows_open url: json_ui_garage_url(path: 'forms/floating_submit')
61
61
  end
62
-
63
62
  end
64
63
  end, ->(section) do
65
64
  section.header padding: glib_json_padding_list, childViews: ->(header) do
@@ -3,7 +3,12 @@ json.title 'Forms'
3
3
  page = json_ui_page json
4
4
  render "#{@path_prefix}/nav_menu", json: json, page: page
5
5
 
6
- page.form url: json_ui_garage_url(path: 'forms/generic_post'), method: 'post', padding: glib_json_padding_body, childViews: ->(form) do
6
+ page.form \
7
+ url: json_ui_garage_url(path: 'forms/generic_post'),
8
+ method: 'post',
9
+ padding: glib_json_padding_body,
10
+ childViews: ->(form) do
11
+
7
12
  form.h2 text: 'Radio Group'
8
13
  form.spacer height: 6
9
14
  form.h4 text: 'Gender'
@@ -15,15 +20,40 @@ page.form url: json_ui_garage_url(path: 'forms/generic_post'), method: 'post', p
15
20
 
16
21
  form.spacer height: 20
17
22
  form.h2 text: 'Single Checkbox'
18
- form.fields_check name: 'user[age_range]', value: '16+', checkValue: '16+', uncheckValue: '0-16', label: 'I am over 16 (has default value)'
19
- form.fields_check name: 'user[employer]', checkValue: 1, label: 'I am an employer (no default value)'
20
- form.fields_check name: 'user[enabled]', checkValue: true, label: 'Enable', styleClass: 'switch', value: 'true'
23
+ form.fields_check \
24
+ name: 'user[age_range]',
25
+ value: '16+',
26
+ checkValue: '16+',
27
+ uncheckValue: '0-16',
28
+ label: 'I am over 16 (has default value)'
29
+ form.fields_check \
30
+ name: 'user[employer]',
31
+ checkValue: 1,
32
+ label: 'I am an employer (no default value)'
33
+ form.fields_check \
34
+ name: 'user[enabled]',
35
+ checkValue: true,
36
+ label: 'Enable',
37
+ styleClass: 'switch',
38
+ value: 'true'
21
39
 
22
40
  form.spacer height: 20
23
41
  form.h2 text: 'Date/Time'
24
42
  form.spacer height: 6
25
- form.fields_date name: 'user[date]', width: 'matchParent', label: 'Date', min: '2010-01-01', max: '2012-01-01', value: '2010-02-01'
26
- form.fields_datetime name: 'user[date_time]', width: 'matchParent', label: 'Date Time', min: '2018-06-09T00:00', max: '2018-06-17T00:00', value: '2018-06-15T19:30'
43
+ form.fields_date \
44
+ name: 'user[date]',
45
+ width: 'matchParent',
46
+ label: 'Date',
47
+ min: '2010-01-01',
48
+ max: '2012-01-01',
49
+ value: '2010-02-01'
50
+ form.fields_datetime \
51
+ name: 'user[date_time]',
52
+ width: 'matchParent',
53
+ label: 'Date Time',
54
+ min: '2018-06-09T00:00',
55
+ max: '2018-06-17T00:00',
56
+ value: '2018-06-15T19:30'
27
57
 
28
58
  form.spacer height: 20
29
59
  form.h2 text: 'Country'
@@ -34,13 +64,39 @@ page.form url: json_ui_garage_url(path: 'forms/generic_post'), method: 'post', p
34
64
  form.spacer height: 20
35
65
  form.h2 text: 'Map'
36
66
  form.spacer height: 6
37
- form.fields_location name: 'user[address]', width: 'matchParent', label: 'Type an address', value: 'Sydney Harbour Bridge',
67
+ form.fields_location \
68
+ name: 'user[address]',
69
+ width: 'matchParent',
70
+ label: 'Type an address',
71
+ value: 'Sydney Harbour Bridge',
38
72
  autocompleteOptions: { componentRestrictions: { country: 'au' }, types: ['(cities)'] },
39
73
  latitudeField: { view: 'fields/text', name: 'user[latitude]', label: 'Lat', value: -33.8523063, readOnly: true },
40
74
  longitudeField: { view: 'fields/text', name: 'user[longitude]', label: 'Long', value: 151.21078710000006, readOnly: true },
41
75
  zoomField: { view: 'fields/text', name: 'user[zoom]', label: 'Zoom' }
42
76
 
43
77
  form.spacer height: 20
44
- form.fields_submit text: 'Submit'
78
+ form.h2 text: 'Rating'
79
+ form.spacer height: 6
80
+ form.fields_rating \
81
+ name: 'user[rating_summary1]',
82
+ value: 1,
83
+ color: 'primary'
84
+ form.fields_rating \
85
+ name: 'user[rating_summary2]',
86
+ value: 1.5,
87
+ halfIncrements: true,
88
+ color: 'secondary'
89
+ form.fields_rating \
90
+ name: 'user[rating_summary3]',
91
+ value: 2,
92
+ color: 'ternary',
93
+ size: 35
94
+ form.fields_rating \
95
+ name: 'user[rating_summary4]',
96
+ value: 3,
97
+ readOnly: true,
98
+ size: 40
45
99
 
100
+ form.spacer height: 20
101
+ form.fields_submit text: 'Submit'
46
102
  end
File without changes
@@ -7,10 +7,10 @@ json_ui_page json do |page|
7
7
  form.fields_radioGroup name: 'user[flow]', childViews: ->(group) do
8
8
  group.h3 text: 'Flow'
9
9
  group.spacer height: 6
10
- group.fields_radio value: 'close_reload', label: 'close+reload - useful for form submission in mobile apps'
11
- group.fields_radio value: 'open', label: 'open - useful for form submission in web app'
12
- group.fields_radio value: 'close_alert', label: 'close+alert - useful for non-model form (e.g. contact us) in both mobile/web'
13
- group.fields_radio value: 'alert_close', label: 'alert+close - useful for non-model form (e.g. contact us) in both mobile/web'
10
+ group.fields_radio value: 'open', label: 'open - useful for form create'
11
+ group.fields_radio value: 'close_with_reload', label: 'closeWithReload - useful for form update'
12
+ group.fields_radio value: 'close_alert', label: 'close+alert - useful for non-model form (e.g. contact us)'
13
+ group.fields_radio value: 'alert_close', label: 'alert+close - useful for non-model form (e.g. contact us)'
14
14
  end
15
15
  form.button text: 'Submit', onClick: ->(action) { action.forms_submit }
16
16
  end
@@ -5,10 +5,12 @@ json_ui_response json do |action|
5
5
  action.dialogs_alert message: 'Please enter all required information'
6
6
  else
7
7
  case flow
8
- when 'close_reload'
9
- action.windows_close onClose: ->(action) do
10
- action.windows_reload
11
- end
8
+ when 'close_with_reload'
9
+ # action.windows_close onClose: ->(action) do
10
+ # action.windows_reload
11
+ # end
12
+
13
+ action.windows_closeWithReload fallbackUrl: json_ui_garage_url(path: 'forms/index')
12
14
  when 'close_alert'
13
15
  action.windows_close onClose: ->(action) do
14
16
  action.dialogs_alert message: 'Thanks for the submission!'
@@ -2,30 +2,34 @@ json.title 'Menu'
2
2
 
3
3
  json_ui_page json do |page|
4
4
  render "#{@path_prefix}/nav_menu", json: json, page: page, top_nav: true
5
-
5
+
6
6
  page.list firstSection: ->(section) do
7
7
  section.rows builder: ->(template) do
8
- template.thumbnail title: 'Pages', onClick: ->(action) do
8
+ template.thumbnail title: 'Pages', onClick: ->(action) do
9
9
  action.windows_open url: json_ui_garage_url(path: 'pages/index')
10
10
  end
11
- template.thumbnail title: 'Lists', onClick: ->(action) do
11
+ template.thumbnail title: 'Panels', onClick: ->(action) do
12
+ action.windows_open url: json_ui_garage_url(path: 'panels/index')
13
+ end
14
+ template.thumbnail title: 'Lists', onClick: ->(action) do
12
15
  action.windows_open url: json_ui_garage_url(path: 'lists/index')
13
16
  end
14
- template.thumbnail title: 'Forms', onClick: ->(action) do
17
+ template.thumbnail title: 'Forms', onClick: ->(action) do
15
18
  action.windows_open url: json_ui_garage_url(path: 'forms/index')
16
19
  end
17
- template.thumbnail title: 'Panels', onClick: ->(action) do
18
- action.windows_open url: json_ui_garage_url(path: 'panels/index')
19
- end
20
- template.thumbnail title: 'Views', onClick: ->(action) do
20
+ template.thumbnail title: 'Views', onClick: ->(action) do
21
21
  action.windows_open url: json_ui_garage_url(path: 'views/index')
22
22
  end
23
- template.thumbnail title: 'Actions', onClick: ->(action) do
23
+ template.thumbnail title: 'Actions', onClick: ->(action) do
24
24
  action.windows_open url: json_ui_garage_url(path: 'actions/index')
25
25
  end
26
- template.thumbnail title: 'Tables (Web Only)', onClick: ->(action) do
26
+ template.thumbnail title: 'Tables (Web Only)', onClick: ->(action) do
27
27
  action.windows_open url: json_ui_garage_url(path: 'tables/index')
28
28
  end
29
+ # Disabled to prevent errors in crawler tests due to external dependencies
30
+ # template.thumbnail title: 'Services', onClick: ->(action) do
31
+ # action.windows_open url: json_ui_garage_url(path: 'services/index')
32
+ # end
29
33
  end
30
34
 
31
35
  end
File without changes
@@ -43,7 +43,7 @@ page.scroll padding: glib_json_padding_body, childViews: ->(scroll) do
43
43
  scroll.panels_split width: 'matchParent', content: ->(content) do
44
44
  content.left childViews: ->(left) do
45
45
  left.fields_textarea \
46
- width: 'matchParent',
46
+ width: 440,
47
47
  label: "Messages from #{first_user.full_name}",
48
48
  onTypeStart: lambda { |action|
49
49
  action.cables_push \
@@ -69,7 +69,7 @@ page.scroll padding: glib_json_padding_body, childViews: ->(scroll) do
69
69
  end
70
70
  content.right childViews: ->(right) do
71
71
  right.fields_textarea \
72
- width: 'matchParent',
72
+ width: 440,
73
73
  label: "Messages from #{second_user.full_name}",
74
74
  onTypeStart: lambda { |action|
75
75
  action.cables_push \
File without changes
File without changes
File without changes
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: 0.5.53
4
+ version: 0.5.54
5
5
  platform: ruby
6
6
  authors:
7
7
  - ''
@@ -263,8 +263,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
263
263
  - !ruby/object:Gem::Version
264
264
  version: '0'
265
265
  requirements: []
266
- rubyforge_project:
267
- rubygems_version: 2.7.6
266
+ rubygems_version: 3.1.4
268
267
  signing_key:
269
268
  specification_version: 4
270
269
  summary: ''