glib-web 3.15.0 → 3.16.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (91) hide show
  1. checksums.yaml +4 -4
  2. data/app/controllers/concerns/glib/auth/policy.rb +4 -0
  3. data/app/controllers/concerns/glib/auth/response.rb +44 -0
  4. data/app/controllers/concerns/glib/json/libs.rb +27 -38
  5. data/app/controllers/concerns/glib/json/new_dynamic_text.rb +0 -0
  6. data/app/helpers/glib/app_feature_support_helper.rb +0 -0
  7. data/app/helpers/glib/dynamic_texts_helper.rb +0 -0
  8. data/app/helpers/glib/enum_helper.rb +1 -7
  9. data/app/helpers/glib/json_ui/action_builder/sheets.rb +0 -0
  10. data/app/helpers/glib/json_ui/analytics_helper.rb +0 -0
  11. data/app/helpers/glib/json_ui/generic_builders.rb +0 -0
  12. data/app/helpers/glib/json_ui/table_builders.rb +0 -0
  13. data/app/helpers/glib/json_ui/view_builder/fields.rb +49 -5
  14. data/app/helpers/glib/json_ui/view_builder/panels.rb +1 -1
  15. data/app/models/concerns/glib/enum_humanization.rb +14 -5
  16. data/app/models/glib/active_storage/attachment.rb +0 -0
  17. data/app/models/glib/active_storage/blob.rb +0 -0
  18. data/app/models/glib/dynamic_text_record.rb +0 -0
  19. data/app/models/glib/text.rb +0 -0
  20. data/app/validators/email_typo_validator.rb +0 -0
  21. data/app/validators/email_validator.rb +0 -0
  22. data/app/validators/url_validator.rb +0 -0
  23. data/app/views/json_ui/garage/actions/_sheets.json.jbuilder +0 -0
  24. data/app/views/json_ui/garage/actions/dialogs_oauth_post.json.jbuilder +0 -0
  25. data/app/views/json_ui/garage/forms/dynamic_select_data.json.jbuilder +0 -0
  26. data/app/views/json_ui/garage/forms/file_upload.json.jbuilder +2 -4
  27. data/app/views/json_ui/garage/forms/generic_post.json.jbuilder +0 -0
  28. data/app/views/json_ui/garage/forms/otp_field.json.jbuilder +0 -4
  29. data/app/views/json_ui/garage/forms/submission_flow.json.jbuilder +0 -0
  30. data/app/views/json_ui/garage/forms/submission_flow_post.json.jbuilder +0 -0
  31. data/app/views/json_ui/garage/forms/submission_indicator.json.jbuilder +0 -0
  32. data/app/views/json_ui/garage/forms/submission_indicator_post.json.jbuilder +0 -0
  33. data/app/views/json_ui/garage/home/blank.json.jbuilder +0 -0
  34. data/app/views/json_ui/garage/home/slow.json.jbuilder +0 -0
  35. data/app/views/json_ui/garage/lists/autoload_all.json.jbuilder +0 -0
  36. data/app/views/json_ui/garage/lists/autoload_as_needed.json.jbuilder +0 -0
  37. data/app/views/json_ui/garage/lists/chat_ui.json.jbuilder +0 -0
  38. data/app/views/json_ui/garage/lists/fab.json.jbuilder +0 -0
  39. data/app/views/json_ui/garage/notifications/web_socket.json.jbuilder +0 -0
  40. data/app/views/json_ui/garage/pages/custom_style_class.json.jbuilder +0 -0
  41. data/app/views/json_ui/garage/pages/full_width.json.jbuilder +0 -0
  42. data/app/views/json_ui/garage/pages/full_width_height.json.jbuilder +0 -0
  43. data/app/views/json_ui/garage/pages/index.json.jbuilder +0 -0
  44. data/app/views/json_ui/garage/pages/layout.json.jbuilder +0 -0
  45. data/app/views/json_ui/garage/pages/lifecycle_hooks.json.jbuilder +0 -0
  46. data/app/views/json_ui/garage/pages/loading_indicator.json.jbuilder +0 -0
  47. data/app/views/json_ui/garage/pages/nested_scroll.json.jbuilder +0 -0
  48. data/app/views/json_ui/garage/pages/redirect_onload.json.jbuilder +0 -0
  49. data/app/views/json_ui/garage/panels/_styled.json.jbuilder +0 -0
  50. data/app/views/json_ui/garage/panels/card.json.jbuilder +0 -0
  51. data/app/views/json_ui/garage/panels/custom.json.jbuilder +0 -0
  52. data/app/views/json_ui/garage/panels/outlined.json.jbuilder +0 -0
  53. data/app/views/json_ui/garage/services/dynamic_text.json.jbuilder +0 -0
  54. data/app/views/json_ui/garage/services/image.json.jbuilder +0 -0
  55. data/app/views/json_ui/garage/services/index.json.jbuilder +0 -0
  56. data/app/views/json_ui/garage/tables/_autoload_section.json.jbuilder +0 -0
  57. data/app/views/json_ui/garage/tables/autoload_all.json.jbuilder +0 -0
  58. data/app/views/json_ui/garage/tables/autoload_as_needed.json.jbuilder +0 -0
  59. data/app/views/json_ui/garage/tables/export_import.json.jbuilder +0 -0
  60. data/app/views/json_ui/garage/tables/index.json.jbuilder +0 -0
  61. data/app/views/json_ui/garage/views/calendar_data.json.jbuilder +0 -0
  62. data/app/views/json_ui/garage/views/charts.json.jbuilder +14 -0
  63. data/app/views/json_ui/garage/views/links.json.jbuilder +0 -0
  64. data/app/views/json_ui/garage/views/map_data.json.jbuilder +0 -0
  65. data/app/views/json_ui/garage/views/multimedia.json.jbuilder +0 -0
  66. data/app/views/layouts/json_ui/no_custom.html.erb +0 -0
  67. data/lib/generators/glib/install_generator.rb +0 -0
  68. data/lib/generators/templates/20191017062519_create_texts.rb +0 -0
  69. data/lib/generators/templates/20191024063257_add_scope_to_texts.rb +0 -0
  70. data/lib/generators/templates/20191112095018_add_lang_to_texts.rb +0 -0
  71. data/lib/generators/templates/20191126071051_create_active_storage_tables.active_storage.rb +0 -0
  72. data/lib/generators/templates/database.yml +0 -0
  73. data/lib/generators/templates/dynamic_text.rb +0 -0
  74. data/lib/glib/crypt/utils.rb +0 -0
  75. data/lib/glib/crypt.rb +0 -0
  76. data/lib/glib/dynamic_text/config.rb +0 -0
  77. data/lib/glib/dynamic_text.rb +0 -0
  78. data/lib/glib/engine.rb +0 -0
  79. data/lib/glib/json_crawler/action_crawler.rb +0 -0
  80. data/lib/glib/json_crawler/action_crawlers/action_http.rb +0 -0
  81. data/lib/glib/json_crawler/action_crawlers/dialogs_alert.rb +0 -0
  82. data/lib/glib/json_crawler/action_crawlers/menu.rb +0 -0
  83. data/lib/glib/json_crawler/action_crawlers/run_multiple.rb +0 -0
  84. data/lib/glib/json_crawler/action_crawlers/windows_open.rb +0 -0
  85. data/lib/glib/json_crawler/coverage.rb +0 -0
  86. data/lib/glib/json_crawler.rb +0 -0
  87. data/lib/glib/mailer_tester.rb +0 -0
  88. data/lib/glib/value.rb +0 -0
  89. data/lib/glib/version.rb +0 -0
  90. data/lib/glib-web.rb +0 -0
  91. metadata +4 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3d4698a3bbea4d4960e782ad29170fbb049247d745085663b37d8c2e72f05be6
4
- data.tar.gz: 34958e58ee0067170f948af7fba0aebbd9406e35ac7e34f590f8ac6649b43478
3
+ metadata.gz: 3b8f74c09536b2840e41346cfef87cfe84896e61b4985ee60d45f576ddaf772d
4
+ data.tar.gz: f6f245a390e234a5910803043074638d9e55d72a4fc2c29eb07b570bee810bcb
5
5
  SHA512:
6
- metadata.gz: 74d23493798bec86ec387059376a1cc3e4696938f0eb9c3e9de88c9947c9685bcda9aa6f497a04088ce18d276e57ab62b4733151801f8959501aef8c5a52cc57
7
- data.tar.gz: c0ece3eebef55739e9f5a8baa756594704851eebea6e91232370e9471cfa260f8c04b83fc6ac512957c7c5f4b12c3dbb79cdd3a24601b7e2cde7fdfd7b78205f
6
+ metadata.gz: 07e4d74b157ba6ca4ffd1021806ab589c54750ee308901edb249ecf5af6a2c97ea50c2a779c516ef905751a4bb255a2101e054dfda3de2431749bc4057f0a768
7
+ data.tar.gz: d09d737aff6ddd5938e01d9ef4960ce0106a77cac80d5ca418d4ae8edddac79b9cd69da3d138f751e66f7aea4afa8b2a32a1b4c5d0ece72622739deb0902937b
@@ -17,6 +17,10 @@ module Glib::Auth
17
17
  helper_method :policy, :can?, :cannot?
18
18
  end
19
19
 
20
+ def assert_current_user_present
21
+ raise UnauthorizedError unless current_user
22
+ end
23
+
20
24
  module Overrides
21
25
 
22
26
  public # Override
@@ -0,0 +1,44 @@
1
+ module Glib::Auth
2
+ # Keep this module small because it needs to be compatible with Devise::FailureApp, which
3
+ # is not a Rails controller.
4
+ module Response
5
+ extend ActiveSupport::Concern
6
+
7
+ included do
8
+ end
9
+
10
+ def glib_json_dialog_mode?
11
+ params[:_dialog].present? # E.g. _dialog=v1
12
+ end
13
+
14
+ def __glib_error_dialog(title, message)
15
+ {
16
+ action: 'dialogs/show',
17
+ # Don't show another dialog, just use the current one since it's a new dialog anyway, which means
18
+ # that it wouldn't contain existing user data.
19
+ updateExisting: glib_json_dialog_mode?,
20
+ title: title,
21
+ body: {
22
+ childViews: [
23
+ {
24
+ "view": "label",
25
+ "text": message
26
+ },
27
+ ],
28
+ "padding": {
29
+ "x": 20,
30
+ "y": 22,
31
+ },
32
+ }
33
+ }
34
+ end
35
+
36
+ def json_ui_401_response
37
+ {
38
+ # Handle dialogs_open and windows_open
39
+ glib_json_dialog_mode? ? :onLoad : :onResponse => __glib_error_dialog(
40
+ 'Your session has ended', 'Please refresh the page and re-login.')
41
+ }
42
+ end
43
+ end
44
+ end
@@ -8,6 +8,8 @@ module Glib::Json::Libs
8
8
  helper_method :json_ui_app_is_android?, :json_ui_app_is_ios?, :json_ui_app_is_web?
9
9
  helper_method :json_ui_redirect_back_or_to
10
10
 
11
+ include Glib::Auth::Response
12
+ helper_method :glib_json_dialog_mode?
11
13
  end
12
14
 
13
15
  def json_ui_app_bundle_id
@@ -77,29 +79,6 @@ module Glib::Json::Libs
77
79
  end
78
80
  end
79
81
 
80
- # The behaviour provided by this convenience method assumes that user is logged in.
81
- # When accessing a forbidden page, redirects to `user_default_url` because we don't
82
- # want the user to get confused in the scenario where after logging in,
83
- # glib_redirect_back_or_to tries to open a page that the user doesn't have access of.
84
- def glib_handle_403(user_default_url)
85
- respond_to do |format|
86
- format.html do
87
- redirect_to user_default_url
88
- end
89
- format.json do
90
- render json: if glib_json_dialog_mode?
91
- { onLoad: __glib_error_dialog('Access denied', "Make sure you're logged in with the correct account.") }
92
- else
93
- {
94
- onResponse: {
95
- action: 'windows/open', url: user_default_url
96
- }
97
- }
98
- end, status: Rails.env.test? ? :forbidden : :ok
99
- end
100
- end
101
- end
102
-
103
82
  def glib_handle_404
104
83
  raise ActionController::RoutingError.new('Not Found')
105
84
 
@@ -122,11 +101,30 @@ module Glib::Json::Libs
122
101
  redirect_to sign_in_url
123
102
  end
124
103
  format.json do
125
- render json: {
126
- # Handle dialogs_open and windows_open
127
- glib_json_dialog_mode? ? :onLoad : :onResponse => __glib_error_dialog(
128
- 'Your session has ended', 'Please refresh the page and re-login.')
129
- }, status: Rails.env.test? ? :unauthorized : :ok
104
+ render json: json_ui_401_response, status: Rails.env.test? ? :unauthorized : :ok
105
+ end
106
+ end
107
+ end
108
+
109
+ # The behaviour provided by this convenience method assumes that user is logged in.
110
+ # When accessing a forbidden page, redirects to `user_default_url` because we don't
111
+ # want the user to get confused in the scenario where after logging in,
112
+ # glib_redirect_back_or_to tries to open a page that the user doesn't have access of.
113
+ def glib_handle_403(user_default_url)
114
+ respond_to do |format|
115
+ format.html do
116
+ redirect_to user_default_url
117
+ end
118
+ format.json do
119
+ render json: if glib_json_dialog_mode?
120
+ { onLoad: __glib_error_dialog('Access denied', "Make sure you're logged in with the correct account.") }
121
+ else
122
+ {
123
+ onResponse: {
124
+ action: 'windows/open', url: user_default_url
125
+ }
126
+ }
127
+ end, status: Rails.env.test? ? :forbidden : :ok
130
128
  end
131
129
  end
132
130
  end
@@ -135,11 +133,6 @@ module Glib::Json::Libs
135
133
  session.delete(REDIRECT_BACK_KEY) || url
136
134
  end
137
135
 
138
- # def glib_redirect_back_or_to(default_url)
139
- # redirect_url = __delete_redirect_back_url(default_url)
140
- # glib_redirect_to redirect_url
141
- # end
142
-
143
136
  def html_ui_redirect_back_or_to(default_url)
144
137
  redirect_url = __delete_redirect_back_url(default_url)
145
138
  redirect_to redirect_url
@@ -152,10 +145,6 @@ module Glib::Json::Libs
152
145
  end
153
146
  end
154
147
 
155
- def glib_json_dialog_mode?
156
- params[:_dialog].present? # E.g. _dialog=v1
157
- end
158
-
159
148
  def __glib_error_dialog(title, message)
160
149
  {
161
150
  action: 'dialogs/show',
@@ -239,7 +228,7 @@ module Glib::Json::Libs
239
228
 
240
229
  def json_libs_rescue_csrf
241
230
  rescue_from ActionController::InvalidAuthenticityToken do |exception|
242
- sign_out(:user)
231
+ # sign_out(:user)
243
232
 
244
233
  # respond_to do |format|
245
234
  # format.json do
File without changes
File without changes
@@ -4,13 +4,7 @@ module Glib
4
4
  enum_name = enum_field.to_s
5
5
  keys ||= clazz.defined_enums[enum_name].keys
6
6
  keys.map do |i|
7
- text = clazz.glib_enum_humanize(enum_field, i)
8
- if include_hints
9
- i18n_key = clazz.model_name.i18n_key
10
- if (hint = I18n.t("dt_models.#{i18n_key}.#{enum_name.pluralize}.#{i}.hint")).present?
11
- text += " #{hint}"
12
- end
13
- end
7
+ text = clazz.glib_enum_humanize(enum_field, i, include_hints: include_hints)
14
8
  { text: text, value: i }
15
9
  end
16
10
  end
File without changes
File without changes
File without changes
File without changes
@@ -258,21 +258,65 @@ class Glib::JsonUi::ViewBuilder
258
258
  string :fileUrl
259
259
  string :fileTitle
260
260
  string :uploadText
261
- string :uploadIcon
261
+ string :uploadIcon # deprecated
262
262
  hash :placeholderView
263
263
  hash :infoSpec
264
+
265
+ def buttonLabels(obj)
266
+ @buttonLabels = ActiveSupport::HashWithIndifferentAccess.new(obj)
267
+ end
268
+
269
+ def created
270
+ @buttonLabels ||= ActiveSupport::HashWithIndifferentAccess.new
271
+ @buttonLabels['change'] ||= I18n.t('common.change') if I18n.exists?('common.change')
272
+ @buttonLabels['upload'] ||= I18n.t('common.upload') if I18n.exists?('common.upload')
273
+ @buttonLabels['delete'] ||= I18n.t('common.delete') if I18n.exists?('common.delete')
274
+
275
+ json.set! :buttonLabels, @buttonLabels
276
+
277
+ super
278
+ end
264
279
  end
265
280
 
266
- class MultipleUpload < AbstractField
281
+ class MultiUpload < AbstractField
267
282
  hash :accepts
268
283
  array :files
269
284
  string :directUploadUrl
270
- string :title
271
- string :subtitle
272
285
  string :uploadTitle
273
286
  string :uploadFailedText
274
287
 
275
288
  required :accepts, :directUploadUrl
289
+
290
+ # deprecated
291
+ def title(value)
292
+ @placeholder = value
293
+ end
294
+
295
+ # deprecated
296
+ def subtitle(value)
297
+ @hint = value
298
+ end
299
+
300
+ def files(values)
301
+ @files = values
302
+ end
303
+
304
+ def created
305
+ super
306
+
307
+ @placeholder ||= I18n.t('common.multi_upload.placeholder', default: nil)
308
+ @hint ||= I18n.t('common.multi_upload.hint', default: nil)
309
+
310
+ json.placeholder @placeholder if @placeholder
311
+ json.hint @hint if @hint
312
+
313
+ if @prop && (form = page.current_form)
314
+ model = form.instance_variable_get(:@model)
315
+ @files ||= model.send(@prop).to_a.map { |file| { name: file.blob&.filename, signed_id: file.signed_id } }
316
+
317
+ json.files @files if @files.present?
318
+ end
319
+ end
276
320
  end
277
321
 
278
322
  # TODO
@@ -337,7 +381,7 @@ class Glib::JsonUi::ViewBuilder
337
381
  class Otp < AbstractField
338
382
  int :length
339
383
  string :type
340
- string :align
384
+ string :align # deprecated
341
385
  end
342
386
 
343
387
  class Rating < AbstractField
@@ -24,7 +24,7 @@ class Glib::JsonUi::ViewBuilder
24
24
  # false
25
25
 
26
26
  # Not all model is ActiveRecord
27
- model.class.try(:reflect_on_association, prop)&.macro == :has_many
27
+ model.class.try(:reflect_on_association, prop)&.macro == :has_many || model.class.try(:reflect_on_attachment, prop)&.macro == :has_many_attached
28
28
  end
29
29
 
30
30
  def self.is_single_association?(model, prop)
@@ -11,21 +11,30 @@ module Glib
11
11
  extend ClassMethods
12
12
  end
13
13
 
14
- def glib_enum_humanize(enum_name, default_enum_value = nil)
15
- self.class.glib_enum_humanize(enum_name, send(enum_name) || default_enum_value)
14
+ def glib_enum_humanize(enum_name, default_enum_value = nil, include_hints: false)
15
+ self.class.glib_enum_humanize(enum_name, send(enum_name) || default_enum_value, include_hints: include_hints)
16
16
  end
17
17
  end
18
18
 
19
19
  module ClassMethods
20
- def glib_enum_humanize(enum_name, enum_value, default_translation = nil)
20
+ def glib_enum_humanize(enum_name, enum_value, default_translation = nil, include_hints: false)
21
21
  if enum_value
22
22
  translation_key = "activerecord.attributes.#{model_name.i18n_key}.#{enum_name.to_s.pluralize}.#{enum_value}"
23
23
 
24
24
  if default_translation.nil? && Rails.env.development?
25
- I18n.t(translation_key, raise: I18n::MissingTranslationData)
25
+ text = I18n.t(translation_key, raise: I18n::MissingTranslationData)
26
26
  else
27
- I18n.t(translation_key, default: default_translation)
27
+ text = I18n.t(translation_key, default: default_translation)
28
28
  end
29
+
30
+ if include_hints
31
+ i18n_key = self.model_name.i18n_key
32
+ if (hint = I18n.t("dt_models.#{i18n_key}.#{enum_name.to_s.pluralize}.#{enum_value}.hint")).present?
33
+ text += " #{hint}"
34
+ end
35
+ end
36
+
37
+ text
29
38
  end
30
39
  end
31
40
  end
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -37,12 +37,10 @@ page.form options.merge(childViews: ->(form) do
37
37
  # placeholderView: { type: 'avatar', width: 100, height: 100, url: 'data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAkGBxMREBUREhAWFhUWGBcVFRgXFxUVFxcWGRUWFxYVFRUYHSggGB0lHRgVITEhJSkrLi4uGB8zODMtNygtLisBCgoKBQUFDgUFDisZExkrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrK//AABEIAOMA3gMBIgACEQEDEQH/xAAbAAEAAgMBAQAAAAAAAAAAAAAABgcBAwQFAv/EAEAQAAECAwMKAwYEBAYDAAAAAAEAAgMRIQQSMQUGIjJBUWFxgZEHE6FCUnKxwdEUI2LwM4KSskNzg6LC4WOz8f/EABQBAQAAAAAAAAAAAAAAAAAAAAD/xAAUEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwC6XuvCQRj7okcUe27UYoxt4TOKDDG3Knkjm3jeGCMdeoeaOcWmQwQZe6/Qc0a+6Lpx+6PbcqOSNbeF44oMMbcqeSOZeN4YIx1+h5oXEG6MEGXuv0HNGuui6cfuvMytl6zWTXi6XuN039hh1koflPxDe4nyILW/qfpO/pFB6oLDhMLTX0XLbLbChmcSNDZ8T2tPqVUNuy/aY38S0PI3A3W/0tkF5qC4bVnZYsPx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BoZDJwC2CEAZEzO4LbEde1T9FgESkdb67KoPqJo1HKWxfIZe0lhgIq7DujgSZtw7eiA11+hptQvu6P7qsvIOrj2ojSAJOx7+qAW3KiuxAy9pfuiwwEa2HeqOBJmMO3OiAHX6Gm1C65QV2rLzPVx7IwgUdj3QfVp1eqWfVREGqy49PskfW7IiDZasOv3WYGr3REGuy49FiPrdkRBstWHX7rMHV7rKINVlx6LEXX7IiDZasBzWYOp3+qyiDVZcTyWIuv2+iIg2WrAc1mHqdD9URB8WXEr5fr9R9ERBttOr1Sz6vdZRBpsuPT7JH1uyIg2WrDqswdTuiINdlxPJYtOt0REH//2Q==' }
38
38
 
39
39
  form.spacer height: 16
40
- form.fields_multipleUpload \
40
+ form.fields_multiUpload \
41
41
  name: 'user[multi][]',
42
- accepts: rules,
42
+ accepts: { fileType: 'image', maxFileSize: 5000 },
43
43
  directUploadUrl: rails_direct_uploads_url,
44
- title: 'Select file or drag and drop here',
45
- subtitle: 'JPG, PNG or PDF, file size no more than 10MB',
46
44
  uploadTitle: 'File added:',
47
45
  uploadFailedText: '(UPLOAD FAILED)',
48
46
  files: [
@@ -45,10 +45,6 @@ page.form \
45
45
  ]
46
46
  }
47
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
-
52
48
  form.spacer height: 20
53
49
  form.fields_submit text: 'Submit'
54
50
  end
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -124,6 +124,20 @@ else
124
124
  end
125
125
  ], legend: 'bottom'
126
126
 
127
+ scroll.h2 text: 'Donut chart'
128
+ scroll.charts_pie \
129
+ styleClasses: ['donut'],
130
+ dataSeries: [
131
+ -> do
132
+ json.title 'Straberry'
133
+ json.value 25
134
+ end,
135
+ -> do
136
+ json.title 'Banana'
137
+ json.value 25
138
+ end
139
+ ], legend: 'bottom'
140
+
127
141
  scroll.h2 text: 'Area chart'
128
142
  scroll.charts_area dataSeries: [
129
143
  -> do
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
data/lib/glib/crypt.rb CHANGED
File without changes
File without changes
File without changes
data/lib/glib/engine.rb CHANGED
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
data/lib/glib/value.rb CHANGED
File without changes
data/lib/glib/version.rb CHANGED
File without changes
data/lib/glib-web.rb CHANGED
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: 3.15.0
4
+ version: 3.16.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ''
@@ -78,6 +78,7 @@ files:
78
78
  - app/channels/glib/channel/online_channel.rb
79
79
  - app/controllers/concerns/glib/analytics/funnel.rb
80
80
  - app/controllers/concerns/glib/auth/policy.rb
81
+ - app/controllers/concerns/glib/auth/response.rb
81
82
  - app/controllers/concerns/glib/json/dynamic_text.rb
82
83
  - app/controllers/concerns/glib/json/libs.rb
83
84
  - app/controllers/concerns/glib/json/new_dynamic_text.rb
@@ -326,7 +327,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
326
327
  - !ruby/object:Gem::Version
327
328
  version: '0'
328
329
  requirements: []
329
- rubygems_version: 3.4.6
330
+ rubyforge_project:
331
+ rubygems_version: 2.7.6
330
332
  signing_key:
331
333
  specification_version: 4
332
334
  summary: ''