glib-web 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (32) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/home_controller.rb +11 -0
  3. data/app/views/_nav_menu.json.jbuilder +84 -0
  4. data/app/views/actions/index.json.jbuilder +25 -0
  5. data/app/views/app/views/json_ui/vue/renderer.html.slim +24 -0
  6. data/app/views/forms/basic.json.jbuilder +53 -0
  7. data/app/views/forms/basic_post.json.jbuilder +10 -0
  8. data/app/views/forms/floating_submit.json.jbuilder +48 -0
  9. data/app/views/forms/generic_post.json.jbuilder +6 -0
  10. data/app/views/forms/index.json.jbuilder +34 -0
  11. data/app/views/forms/submit_indicator.json.jbuilder +32 -0
  12. data/app/views/forms/submit_indicator_post.json.jbuilder +12 -0
  13. data/app/views/home/index.json.jbuilder +92 -0
  14. data/app/views/lists/_infinite_scroll_section.json.jbuilder +10 -0
  15. data/app/views/lists/index.json.jbuilder +25 -0
  16. data/app/views/lists/infinite_scroll.json.jbuilder +27 -0
  17. data/app/views/lists/templating.json.jbuilder +45 -0
  18. data/app/views/pages/full_width_height.json.jbuilder +39 -0
  19. data/app/views/pages/index.json.jbuilder +35 -0
  20. data/app/views/pages/layout.json.jbuilder +35 -0
  21. data/app/views/pages/nav_buttons.json.jbuilder +32 -0
  22. data/app/views/panels/horizontal.json.jbuilder +213 -0
  23. data/app/views/panels/index.json.jbuilder +34 -0
  24. data/app/views/panels/split.json.jbuilder +360 -0
  25. data/app/views/panels/vertical.json.jbuilder +94 -0
  26. data/app/views/views/basic.json.jbuilder +21 -0
  27. data/app/views/views/carousels.json.jbuilder +100 -0
  28. data/app/views/views/images.json.jbuilder +48 -0
  29. data/app/views/views/index.json.jbuilder +34 -0
  30. data/config/routes.rb +4 -0
  31. data/lib/glib/engine.rb +1 -1
  32. metadata +30 -1
@@ -0,0 +1,21 @@
1
+ json.title 'Components'
2
+
3
+ render './nav_menu', json: json
4
+
5
+ json_body_with_scroll json do
6
+ json.child! do
7
+ json.view 'label-v1'
8
+ json.text "\n"
9
+ end
10
+ json.child! do
11
+ json.view 'h1-v1'
12
+ json.text 'Map'
13
+ end
14
+ json.child! do
15
+ json.view 'map-v1'
16
+ json.latitude 13.4837
17
+ json.longitude 144.7917
18
+ json.zoom 11
19
+ json.height '250px'
20
+ end
21
+ end
@@ -0,0 +1,100 @@
1
+ json.title 'Components'
2
+
3
+ render './nav_menu', json: json
4
+
5
+ image_url1 = 'http://ichef.bbci.co.uk/news/976/cpsprodpb/18106/production/_97266589_gettyimages-474547165.jpg'
6
+ image_url2 = 'https://s.abcnews.com/images/International/Guam03-gty-jrl-170809_16x9_992.jpg'
7
+
8
+ json_body_with_scroll json do
9
+ json.child! do
10
+ json.view 'label-v1'
11
+ json.text "\n"
12
+ end
13
+ json.child! do
14
+ json.view 'h1-v1'
15
+ json.text 'Carousel with labels'
16
+ end
17
+ json.child! do
18
+ json.view 'panels/carousel-v1'
19
+ json.subviews do
20
+ json.child! do
21
+ json.view 'label-v1'
22
+ json.text "Item 1"
23
+ end
24
+
25
+ json.child! do
26
+ json.view 'label-v1'
27
+ json.text "Item 2"
28
+ end
29
+ end
30
+ end
31
+
32
+ json.child! do
33
+ json.view 'label-v1'
34
+ json.text "\n"
35
+ end
36
+ json.child! do
37
+ json.view 'h1-v1'
38
+ json.text 'Carousel with images'
39
+ end
40
+ json.child! do
41
+ json.view 'panels/carousel-v1'
42
+ json.subviews do
43
+ json.child! do
44
+ json.view 'image-v1'
45
+ json.url image_url1
46
+ end
47
+
48
+ json.child! do
49
+ json.view 'image-v1'
50
+ json.url image_url2
51
+ end
52
+ end
53
+ end
54
+
55
+ json.child! do
56
+ json.view 'label-v1'
57
+ json.text "\n"
58
+ end
59
+ json.child! do
60
+ json.view 'h1-v1'
61
+ json.text 'Carousel with complex layout'
62
+ end
63
+ json.child! do
64
+ json.view 'panels/carousel-v1'
65
+ json.width 'matchParent'
66
+ json.subviews do
67
+ json.child! do
68
+ json.view 'panels/vertical-v1'
69
+ json.subviews do
70
+ json.child! do
71
+ json.view 'h3-v1'
72
+ json.text "Item 1"
73
+ end
74
+ json.child! do
75
+ json.view 'image-v1'
76
+ json.width 'matchParent'
77
+ json.url image_url1
78
+ end
79
+ end
80
+ end
81
+
82
+ json.child! do
83
+ json.view 'panels/vertical-v1'
84
+ json.subviews do
85
+ json.child! do
86
+ json.view 'h3-v1'
87
+ json.text "Item 2"
88
+ end
89
+ json.child! do
90
+ json.view 'image-v1'
91
+ json.width 'matchParent'
92
+ json.url image_url2
93
+ end
94
+ end
95
+ end
96
+
97
+ end
98
+ end
99
+
100
+ end
@@ -0,0 +1,48 @@
1
+ json.title 'Components'
2
+
3
+ render './nav_menu', json: json
4
+
5
+ json_body_with_scroll json do
6
+ json.child! do
7
+ json.view 'label-v1'
8
+ json.text "\n"
9
+ end
10
+ json.child! do
11
+ json.view 'h1-v1'
12
+ json.text 'Image with URL'
13
+ end
14
+ json.child! do
15
+ json.view 'image-v1'
16
+ json.width 100
17
+ json.url @sample_image_url
18
+ end
19
+
20
+ json.child! do
21
+ json.view 'label-v1'
22
+ json.text "\n"
23
+ end
24
+ json.child! do
25
+ json.view 'h1-v1'
26
+ json.text 'Image with base64 data'
27
+ end
28
+ json.child! do
29
+ json.view 'image-v1'
30
+ json.height 100
31
+ json.base64Data 'data:image/gif;base64,R0lGODlhPQBEAPeoAJosM//AwO/AwHVYZ/z595kzAP/s7P+goOXMv8+fhw/v739/f+8PD98fH/8mJl+fn/9ZWb8/PzWlwv///6wWGbImAPgTEMImIN9gUFCEm/gDALULDN8PAD6atYdCTX9gUNKlj8wZAKUsAOzZz+UMAOsJAP/Z2ccMDA8PD/95eX5NWvsJCOVNQPtfX/8zM8+QePLl38MGBr8JCP+zs9myn/8GBqwpAP/GxgwJCPny78lzYLgjAJ8vAP9fX/+MjMUcAN8zM/9wcM8ZGcATEL+QePdZWf/29uc/P9cmJu9MTDImIN+/r7+/vz8/P8VNQGNugV8AAF9fX8swMNgTAFlDOICAgPNSUnNWSMQ5M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6gu10bE/JG2VnCZGfo4R4d0sdQoBAHhPjhIB94v/wRoRKQWGRHgrhGSQJxCS+0pCZbEhAAOw=='
32
+ end
33
+
34
+ json.child! do
35
+ json.view 'label-v1'
36
+ json.text "\n"
37
+ end
38
+ json.child! do
39
+ json.view 'h1-v1'
40
+ json.text 'QR Code as base64 image'
41
+ end
42
+ json.child! do
43
+ json.view 'image-v1'
44
+ qr_content = { version: 1, message: 'This is a test' }
45
+ qr = RQRCode::QRCode.new(qr_content.to_json)
46
+ json.base64Data qr.as_png(size: 300).to_data_url
47
+ end
48
+ end
@@ -0,0 +1,34 @@
1
+ json.title 'Components'
2
+
3
+ render './nav_menu', json: json
4
+
5
+ json_body_with_list json do
6
+ json.rows do
7
+ json.child! do
8
+ json.template 'thumbnail-v1'
9
+ json.title 'Basic'
10
+ json.onClick do
11
+ json.action 'windows/open-v1'
12
+ json.url Glib::Web::Engine.routes.url_helpers.json_ui_garage_path(_render: 'v1', path: 'views/basic')
13
+ end
14
+ end
15
+
16
+ json.child! do
17
+ json.template 'thumbnail-v1'
18
+ json.title 'Images'
19
+ json.onClick do
20
+ json.action 'windows/open-v1'
21
+ json.url Glib::Web::Engine.routes.url_helpers.json_ui_garage_path(_render: 'v1', path: 'views/images')
22
+ end
23
+ end
24
+
25
+ json.child! do
26
+ json.template 'thumbnail-v1'
27
+ json.title 'Carousels'
28
+ json.onClick do
29
+ json.action 'windows/open-v1'
30
+ json.url Glib::Web::Engine.routes.url_helpers.json_ui_garage_path(_render: 'v1', path: 'views/carousels')
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,4 @@
1
+ Glib::Web::Engine.routes.draw do
2
+ get 'json_ui_garage', to: 'home#json_ui_garage'
3
+ post 'json_ui_garage', to: 'home#json_ui_garage'
4
+ end
@@ -1,7 +1,7 @@
1
1
  module Glib
2
2
  module Web
3
3
  class Engine < ::Rails::Engine
4
-
4
+ # isolate_namespace Glib::Web
5
5
  end
6
6
  end
7
7
  end
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.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - ''
@@ -21,7 +21,36 @@ files:
21
21
  - app/controllers/concerns/application/json/transformation.rb
22
22
  - app/controllers/concerns/application/json/ui.rb
23
23
  - app/controllers/concerns/application/json/validation.rb
24
+ - app/controllers/home_controller.rb
24
25
  - app/helpers/glib/web/json_ui_helper.rb
26
+ - app/views/_nav_menu.json.jbuilder
27
+ - app/views/actions/index.json.jbuilder
28
+ - app/views/app/views/json_ui/vue/renderer.html.slim
29
+ - app/views/forms/basic.json.jbuilder
30
+ - app/views/forms/basic_post.json.jbuilder
31
+ - app/views/forms/floating_submit.json.jbuilder
32
+ - app/views/forms/generic_post.json.jbuilder
33
+ - app/views/forms/index.json.jbuilder
34
+ - app/views/forms/submit_indicator.json.jbuilder
35
+ - app/views/forms/submit_indicator_post.json.jbuilder
36
+ - app/views/home/index.json.jbuilder
37
+ - app/views/lists/_infinite_scroll_section.json.jbuilder
38
+ - app/views/lists/index.json.jbuilder
39
+ - app/views/lists/infinite_scroll.json.jbuilder
40
+ - app/views/lists/templating.json.jbuilder
41
+ - app/views/pages/full_width_height.json.jbuilder
42
+ - app/views/pages/index.json.jbuilder
43
+ - app/views/pages/layout.json.jbuilder
44
+ - app/views/pages/nav_buttons.json.jbuilder
45
+ - app/views/panels/horizontal.json.jbuilder
46
+ - app/views/panels/index.json.jbuilder
47
+ - app/views/panels/split.json.jbuilder
48
+ - app/views/panels/vertical.json.jbuilder
49
+ - app/views/views/basic.json.jbuilder
50
+ - app/views/views/carousels.json.jbuilder
51
+ - app/views/views/images.json.jbuilder
52
+ - app/views/views/index.json.jbuilder
53
+ - config/routes.rb
25
54
  - lib/glib-web.rb
26
55
  - lib/glib/engine.rb
27
56
  - lib/glib/version.rb