glib-web 4.36.2 → 4.36.5
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/controllers/concerns/glib/auth/response.rb +6 -8
- data/app/controllers/concerns/glib/json/libs.rb +25 -15
- data/app/helpers/glib/json_ui/action_builder/popovers.rb +23 -8
- data/app/views/json_ui/garage/actions/_windows.json.jbuilder +8 -0
- data/app/views/json_ui/garage/home/print.json.jbuilder +14 -0
- data/app/views/json_ui/garage/panels/flow.json.jbuilder +30 -0
- data/app/views/json_ui/garage/panels/horizontal.json.jbuilder +58 -0
- data/app/views/json_ui/garage/panels/responsive.json.jbuilder +61 -1
- data/app/views/json_ui/garage/panels/vertical.json.jbuilder +40 -0
- data/app/views/json_ui/garage/views/controls.json.jbuilder +33 -0
- data/app/views/json_ui/garage/views/popovers_open.json.jbuilder +10 -0
- metadata +3 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e657850bcd9c7e8e881d35180ee54e239302bdf680511cb49f4cdde2b87c9379
|
4
|
+
data.tar.gz: 106a0f38b451f40536fb00f76ad24a62105ae53dcd2f5047239b1ec7dd2b7d72
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4d9fbae4fcc33c99c7081f0aaf458e41e26228df11f6709d537f2ec584140af02dd8c2b4252c4e0356cd9dffee152dd273457e12b96b6ce0898680f96998353e
|
7
|
+
data.tar.gz: 84dfef2ffce458eacfe1d9e279d09b2c0fd818cd4ba0f26eb4db16ea6f1c87d6f8bdd5f7c6fa71c0cb3244d54cb3fc41acfb4f0c2a4a6420682149c49ed9dd66
|
@@ -11,23 +11,21 @@ module Glib::Auth
|
|
11
11
|
params[:_dialog].present? # E.g. _dialog=v1
|
12
12
|
end
|
13
13
|
|
14
|
-
def json_ui_401_response(sign_in_url)
|
14
|
+
def json_ui_401_response(sign_in_url, **redirect_options)
|
15
|
+
allow_other_host = redirect_options[:allow_other_host]
|
15
16
|
{
|
16
17
|
# Handle dialogs_open and windows_open
|
17
18
|
glib_json_dialog_mode? ? :onLoad : :onResponse => __glib_error_dialog(
|
18
|
-
'Your session has ended', 'Please re-login.', [
|
19
|
-
{
|
20
|
-
view: 'spacer',
|
21
|
-
height: 20
|
22
|
-
},
|
19
|
+
'Your session has ended', 'Please re-login.', ['dialog-401-error'], [
|
23
20
|
{
|
24
21
|
view: 'button',
|
25
22
|
text: 'Re-login',
|
26
23
|
onClick: {
|
27
24
|
action: 'dialogs/close',
|
28
25
|
onClose: {
|
29
|
-
action: 'windows/open',
|
30
|
-
url: sign_in_url
|
26
|
+
action: allow_other_host ? 'windows/openWeb' : 'windows/open',
|
27
|
+
url: sign_in_url,
|
28
|
+
targetWindow: allow_other_host ? '_self' : nil
|
31
29
|
}
|
32
30
|
}
|
33
31
|
},
|
@@ -68,10 +68,10 @@ module Glib::Json::Libs
|
|
68
68
|
|
69
69
|
# As much as possible, try retaining the front fragment by matching the back, because
|
70
70
|
# the front could be either a `?` or `&`
|
71
|
-
url = url.sub(/format=json\&/, '')
|
71
|
+
url = url.sub(/format=json\&/, '')
|
72
72
|
|
73
73
|
# If no match, then we replace the front fragment
|
74
|
-
url.sub(/[\&\?]format=json/, '')
|
74
|
+
url.sub(/[\&\?]format=json/, '')
|
75
75
|
end
|
76
76
|
|
77
77
|
def glib_redirect_to(url, return_to_previous: false, status: :ok)
|
@@ -131,7 +131,9 @@ module Glib::Json::Libs
|
|
131
131
|
redirect_to sign_in_url, **redirect_options
|
132
132
|
end
|
133
133
|
format.json do
|
134
|
-
render
|
134
|
+
render \
|
135
|
+
json: json_ui_401_response(sign_in_url, **redirect_options),
|
136
|
+
status: Rails.env.test? ? :unauthorized : :ok
|
135
137
|
end
|
136
138
|
format.csv do
|
137
139
|
if Rails.env.test?
|
@@ -158,15 +160,23 @@ module Glib::Json::Libs
|
|
158
160
|
return
|
159
161
|
end
|
160
162
|
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
163
|
+
json_response = \
|
164
|
+
if glib_json_dialog_mode?
|
165
|
+
{
|
166
|
+
onLoad: __glib_error_dialog(
|
167
|
+
'Access denied',
|
168
|
+
"Make sure you're logged in with the correct account.",
|
169
|
+
['dialog-403-error']
|
170
|
+
)
|
167
171
|
}
|
168
|
-
|
169
|
-
|
172
|
+
else
|
173
|
+
{
|
174
|
+
onResponse: {
|
175
|
+
action: 'windows/open', url: user_default_url
|
176
|
+
}
|
177
|
+
}
|
178
|
+
end
|
179
|
+
render json: json_response, status: Rails.env.test? ? :forbidden : :ok
|
170
180
|
end
|
171
181
|
format.csv do
|
172
182
|
if Rails.env.test?
|
@@ -203,7 +213,7 @@ module Glib::Json::Libs
|
|
203
213
|
# end
|
204
214
|
# end
|
205
215
|
|
206
|
-
def __glib_error_dialog(title, message, bottom_views = [])
|
216
|
+
def __glib_error_dialog(title, message, style_classes, bottom_views = [])
|
207
217
|
{
|
208
218
|
action: 'dialogs/show',
|
209
219
|
# Don't show another dialog, just use the current one since it's a new dialog anyway, which means
|
@@ -214,7 +224,7 @@ module Glib::Json::Libs
|
|
214
224
|
childViews: [
|
215
225
|
{
|
216
226
|
view: 'panels/vertical',
|
217
|
-
styleClasses: ['glib-error-dialog'],
|
227
|
+
styleClasses: ['glib-error-dialog'].concat(style_classes),
|
218
228
|
childViews: [
|
219
229
|
{
|
220
230
|
view: 'label',
|
@@ -236,7 +246,7 @@ module Glib::Json::Libs
|
|
236
246
|
if json_ui_activated?
|
237
247
|
if Rails.env.production? || preview_mode
|
238
248
|
if defined?(Rollbar) && !preview_mode
|
239
|
-
Rollbar.error(exception, :
|
249
|
+
Rollbar.error(exception, use_exception_level_filters: true)
|
240
250
|
end
|
241
251
|
|
242
252
|
render file: Rails.root.join('public', '500.html'), status: :internal_server_error
|
@@ -342,7 +352,7 @@ module Glib::Json::Libs
|
|
342
352
|
format.json do
|
343
353
|
render json: {
|
344
354
|
glib_json_dialog_mode? ? :onLoad : :onResponse => __glib_error_dialog(
|
345
|
-
'Your session has expired', 'Please refresh the page and retry.', [
|
355
|
+
'Your session has expired', 'Please refresh the page and retry.', ['dialog-csrf-error'], [
|
346
356
|
{
|
347
357
|
view: 'button',
|
348
358
|
text: 'Refresh',
|
@@ -1,17 +1,32 @@
|
|
1
1
|
class Glib::JsonUi::ActionBuilder
|
2
2
|
module Popovers
|
3
3
|
|
4
|
+
module PopoverAttributes
|
5
|
+
extend ActiveSupport::Concern
|
6
|
+
|
7
|
+
included do
|
8
|
+
string :key
|
9
|
+
# views :childViews
|
10
|
+
string :placement
|
11
|
+
int :offset
|
12
|
+
int :width
|
13
|
+
bool :persistent
|
14
|
+
hash :overlay, required: [:closeOnFocus]
|
15
|
+
singleton_array :styleClass, :styleClasses
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
4
19
|
class Show < Action
|
20
|
+
include PopoverAttributes
|
21
|
+
|
5
22
|
panels_builder :content, :body
|
23
|
+
end
|
6
24
|
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
bool :persistent
|
13
|
-
hash :overlay, required: [:closeOnFocus]
|
14
|
-
singleton_array :styleClass, :styleClasses
|
25
|
+
class Open < Action
|
26
|
+
include PopoverAttributes
|
27
|
+
|
28
|
+
string :url
|
29
|
+
bool :updateExisting
|
15
30
|
end
|
16
31
|
|
17
32
|
class Close < Action
|
@@ -27,6 +27,14 @@ section.rows builder: ->(template) do
|
|
27
27
|
end
|
28
28
|
end
|
29
29
|
|
30
|
+
template.thumbnail title: 'windows/closeWithOpen1', onClick: ->(action) do
|
31
|
+
action.windows_closeWithOpen url: json_ui_garage_url(path: 'home/print', encoded_key: 'Hello+World')
|
32
|
+
end
|
33
|
+
|
34
|
+
template.thumbnail title: 'windows/closeWithOpen2', onClick: ->(action) do
|
35
|
+
action.windows_closeWithOpen url: json_ui_garage_url(path: 'home/print', encoded_key: 'Hello%2BWorld')
|
36
|
+
end
|
37
|
+
|
30
38
|
template.thumbnail title: 'windows/closeAllWithOpen', onClick: ->(action) do
|
31
39
|
action.windows_closeAllWithOpen url: json_ui_garage_url(path: 'home/index', sleep: true), loaderViews: ->(view) do
|
32
40
|
view.panels_responsive padding: { all: 16 }, childViews: ->(res) do
|
@@ -0,0 +1,14 @@
|
|
1
|
+
if params[:sleep].present?
|
2
|
+
sleep 1
|
3
|
+
end
|
4
|
+
|
5
|
+
json.title 'Menu'
|
6
|
+
|
7
|
+
page = json_ui_page json
|
8
|
+
render "#{@path_prefix}/nav_menu", json: json, page: page, top_nav: false
|
9
|
+
|
10
|
+
page.scroll padding: glib_json_padding_body, childViews: ->(scroll) do
|
11
|
+
params.each do |key, value|
|
12
|
+
scroll.label text: "#{key}: #{value}"
|
13
|
+
end
|
14
|
+
end
|
@@ -77,4 +77,34 @@ page.scroll padding: glib_json_padding_body, childViews: ->(scroll) do
|
|
77
77
|
panel.spacer width: 10
|
78
78
|
panel.label text: 'bottom'
|
79
79
|
end
|
80
|
+
|
81
|
+
scroll.label text: "\n"
|
82
|
+
scroll.h1 text: 'Changed when Hover'
|
83
|
+
scroll.panels_flow \
|
84
|
+
id: 'default1',
|
85
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
86
|
+
backgroundColor: '#b3bac2',
|
87
|
+
onMouseEnter: ->(action) {
|
88
|
+
action.runMultiple childActions: ->(saction) do
|
89
|
+
saction.components_set targetId: 'default1', data: { displayed: false }
|
90
|
+
saction.components_set targetId: 'hovered1', data: { displayed: true }
|
91
|
+
end
|
92
|
+
}, childViews: ->(panel) do
|
93
|
+
panel.label text: 'Hover me'
|
94
|
+
end
|
95
|
+
scroll.panels_flow \
|
96
|
+
id: 'hovered1',
|
97
|
+
displayed: false,
|
98
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
99
|
+
backgroundColor: '#b3bac2',
|
100
|
+
onMouseLeave: ->(action) {
|
101
|
+
action.runMultiple childActions: ->(saction) do
|
102
|
+
saction.components_set targetId: 'default1', data: { displayed: true }
|
103
|
+
saction.components_set targetId: 'hovered1', data: { displayed: false }
|
104
|
+
end
|
105
|
+
}, childViews: ->(panel) do
|
106
|
+
panel.label text: 'Hover active'
|
107
|
+
end
|
108
|
+
|
109
|
+
scroll.label text: "\n"
|
80
110
|
end
|
@@ -163,5 +163,63 @@ json_ui_page json do |page|
|
|
163
163
|
}
|
164
164
|
|
165
165
|
scroll.label text: "\n"
|
166
|
+
scroll.h1 text: 'Changed when Hover'
|
167
|
+
scroll.panels_horizontal \
|
168
|
+
id: 'default1',
|
169
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
170
|
+
backgroundColor: '#b3bac2',
|
171
|
+
onMouseEnter: ->(action) {
|
172
|
+
action.runMultiple childActions: ->(saction) do
|
173
|
+
saction.components_set targetId: 'default1', data: { displayed: false }
|
174
|
+
saction.components_set targetId: 'hovered1', data: { displayed: true }
|
175
|
+
end
|
176
|
+
}, childViews: ->(panel) do
|
177
|
+
panel.label text: 'Hover me'
|
178
|
+
end
|
179
|
+
scroll.panels_horizontal \
|
180
|
+
id: 'hovered1',
|
181
|
+
displayed: false,
|
182
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
183
|
+
backgroundColor: '#b3bac2',
|
184
|
+
onMouseLeave: ->(action) {
|
185
|
+
action.runMultiple childActions: ->(saction) do
|
186
|
+
saction.components_set targetId: 'default1', data: { displayed: true }
|
187
|
+
saction.components_set targetId: 'hovered1', data: { displayed: false }
|
188
|
+
end
|
189
|
+
}, childViews: ->(panel) do
|
190
|
+
panel.label text: 'Hover active'
|
191
|
+
end
|
192
|
+
|
193
|
+
scroll.label text: "\n"
|
194
|
+
scroll.h1 text: 'Changed when Hover (with onClick)'
|
195
|
+
scroll.panels_horizontal \
|
196
|
+
id: 'default2',
|
197
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
198
|
+
backgroundColor: '#b3bac2',
|
199
|
+
onMouseEnter: ->(action) {
|
200
|
+
action.runMultiple childActions: ->(saction) do
|
201
|
+
saction.components_set targetId: 'default2', data: { displayed: false }
|
202
|
+
saction.components_set targetId: 'hovered2', data: { displayed: true }
|
203
|
+
end
|
204
|
+
}, childViews: ->(panel) do
|
205
|
+
panel.label text: 'Hover me'
|
206
|
+
end
|
207
|
+
scroll.panels_horizontal \
|
208
|
+
id: 'hovered2',
|
209
|
+
displayed: false,
|
210
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
211
|
+
backgroundColor: '#b3bac2',
|
212
|
+
onMouseLeave: ->(action) {
|
213
|
+
action.runMultiple childActions: ->(saction) do
|
214
|
+
saction.components_set targetId: 'default2', data: { displayed: true }
|
215
|
+
saction.components_set targetId: 'hovered2', data: { displayed: false }
|
216
|
+
end
|
217
|
+
}, childViews: ->(panel) do
|
218
|
+
panel.label text: 'Click me'
|
219
|
+
end, onClick: ->(action) do
|
220
|
+
action.windows_open url: json_ui_garage_url(path: 'home/blank')
|
221
|
+
end
|
222
|
+
|
223
|
+
scroll.label text: "\n"
|
166
224
|
end
|
167
225
|
end
|
@@ -158,7 +158,67 @@ page.scroll padding: glib_json_padding_body, childViews: ->(scroll) do
|
|
158
158
|
action.windows_open url: json_ui_garage_url(path: 'home/blank')
|
159
159
|
end
|
160
160
|
|
161
|
-
scroll.spacer height:
|
161
|
+
scroll.spacer height: 32
|
162
|
+
scroll.h1 text: 'Changed when Hover'
|
163
|
+
scroll.spacer height: 8
|
164
|
+
scroll.panels_responsive \
|
165
|
+
id: 'default1',
|
166
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
167
|
+
backgroundColor: '#c3cad2',
|
168
|
+
onMouseEnter: ->(action) {
|
169
|
+
action.runMultiple childActions: ->(saction) do
|
170
|
+
saction.components_set targetId: 'default1', data: { displayed: false }
|
171
|
+
saction.components_set targetId: 'hovered1', data: { displayed: true }
|
172
|
+
end
|
173
|
+
}, childViews: ->(panel) do
|
174
|
+
panel.label text: 'Hover me'
|
175
|
+
end
|
176
|
+
scroll.panels_responsive \
|
177
|
+
id: 'hovered1',
|
178
|
+
displayed: false,
|
179
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
180
|
+
backgroundColor: '#c3cad2',
|
181
|
+
onMouseLeave: ->(action) {
|
182
|
+
action.runMultiple childActions: ->(saction) do
|
183
|
+
saction.components_set targetId: 'default1', data: { displayed: true }
|
184
|
+
saction.components_set targetId: 'hovered1', data: { displayed: false }
|
185
|
+
end
|
186
|
+
}, childViews: ->(panel) do
|
187
|
+
panel.label text: 'Hover active'
|
188
|
+
end
|
189
|
+
|
190
|
+
scroll.spacer height: 32
|
191
|
+
scroll.h1 text: 'Changed when Hover (with onClick)'
|
192
|
+
scroll.spacer height: 8
|
193
|
+
scroll.panels_responsive \
|
194
|
+
id: 'default2',
|
195
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
196
|
+
backgroundColor: '#c3cad2',
|
197
|
+
onMouseEnter: ->(action) {
|
198
|
+
action.runMultiple childActions: ->(saction) do
|
199
|
+
saction.components_set targetId: 'default2', data: { displayed: false }
|
200
|
+
saction.components_set targetId: 'hovered2', data: { displayed: true }
|
201
|
+
end
|
202
|
+
}, childViews: ->(panel) do
|
203
|
+
panel.label text: 'Hover me'
|
204
|
+
end
|
205
|
+
scroll.panels_responsive \
|
206
|
+
id: 'hovered2',
|
207
|
+
displayed: false,
|
208
|
+
padding: { left: 20, right: 20, top: 10, bottom: 10 },
|
209
|
+
backgroundColor: '#c3cad2',
|
210
|
+
onMouseLeave: ->(action) {
|
211
|
+
action.runMultiple childActions: ->(saction) do
|
212
|
+
saction.components_set targetId: 'default2', data: { displayed: true }
|
213
|
+
saction.components_set targetId: 'hovered2', data: { displayed: false }
|
214
|
+
end
|
215
|
+
}, childViews: ->(panel) do
|
216
|
+
panel.label text: 'Click me'
|
217
|
+
end, onClick: ->(action) do
|
218
|
+
action.windows_open url: json_ui_garage_url(path: 'home/blank')
|
219
|
+
end
|
220
|
+
|
221
|
+
scroll.spacer height: 32
|
162
222
|
scroll.h4 text: 'With grid-like functionality'
|
163
223
|
scroll.spacer height: 8
|
164
224
|
scroll.panels_responsive \
|
@@ -66,5 +66,45 @@ json_ui_page json do |page|
|
|
66
66
|
end, childViews: ->(panel) do
|
67
67
|
panel.label text: 'Click me'
|
68
68
|
end
|
69
|
+
|
70
|
+
scroll.label text: "\n"
|
71
|
+
scroll.h1 text: 'Changed when Hover'
|
72
|
+
scroll.panels_vertical id: 'default1', width: 100, height: 100, backgroundColor: '#b3bac2', align: 'center', onMouseEnter: ->(action) {
|
73
|
+
action.runMultiple childActions: ->(saction) do
|
74
|
+
saction.components_set targetId: 'default1', data: { displayed: false }
|
75
|
+
saction.components_set targetId: 'hovered1', data: { displayed: true }
|
76
|
+
end
|
77
|
+
}, childViews: ->(panel) do
|
78
|
+
panel.label text: 'Hover me'
|
79
|
+
end
|
80
|
+
scroll.panels_vertical id: 'hovered1', displayed: false, width: 100, height: 100, backgroundColor: '#b3bac2', align: 'center', onMouseLeave: ->(action) {
|
81
|
+
action.runMultiple childActions: ->(saction) do
|
82
|
+
saction.components_set targetId: 'default1', data: { displayed: true }
|
83
|
+
saction.components_set targetId: 'hovered1', data: { displayed: false }
|
84
|
+
end
|
85
|
+
}, childViews: ->(panel) do
|
86
|
+
panel.label text: 'Hover active'
|
87
|
+
end
|
88
|
+
|
89
|
+
scroll.label text: "\n"
|
90
|
+
scroll.h1 text: 'Changed when Hover (with onClick)'
|
91
|
+
scroll.panels_vertical id: 'default2', width: 100, height: 100, backgroundColor: '#b3bac2', align: 'center', onMouseEnter: ->(action) {
|
92
|
+
action.runMultiple childActions: ->(saction) do
|
93
|
+
saction.components_set targetId: 'default2', data: { displayed: false }
|
94
|
+
saction.components_set targetId: 'hovered2', data: { displayed: true }
|
95
|
+
end
|
96
|
+
}, childViews: ->(panel) do
|
97
|
+
panel.label text: 'Hover me'
|
98
|
+
end
|
99
|
+
scroll.panels_vertical id: 'hovered2', displayed: false, width: 100, height: 100, backgroundColor: '#b3bac2', align: 'center', onMouseLeave: ->(action) {
|
100
|
+
action.runMultiple childActions: ->(saction) do
|
101
|
+
saction.components_set targetId: 'default2', data: { displayed: true }
|
102
|
+
saction.components_set targetId: 'hovered2', data: { displayed: false }
|
103
|
+
end
|
104
|
+
}, childViews: ->(panel) do
|
105
|
+
panel.label text: 'Click me'
|
106
|
+
end, onClick: ->(action) do
|
107
|
+
action.windows_open url: json_ui_garage_url(path: 'home/blank')
|
108
|
+
end
|
69
109
|
end
|
70
110
|
end
|
@@ -87,6 +87,16 @@ page.scroll padding: glib_json_padding_body, childViews: ->(scroll) do
|
|
87
87
|
onClick: ->(action) do
|
88
88
|
action.windows_reload
|
89
89
|
end
|
90
|
+
scroll.spacer height: 10
|
91
|
+
scroll.button \
|
92
|
+
text: 'Button with popover from server',
|
93
|
+
onClick: ->(action) do
|
94
|
+
key = SecureRandom.hex(3)
|
95
|
+
action.popovers_open \
|
96
|
+
url: json_ui_garage_url(path: 'views/popovers_open', key: key),
|
97
|
+
styleClass: 'popover-container',
|
98
|
+
key: key
|
99
|
+
end
|
90
100
|
|
91
101
|
scroll.spacer height: 10
|
92
102
|
scroll.button \
|
@@ -94,6 +104,29 @@ page.scroll padding: glib_json_padding_body, childViews: ->(scroll) do
|
|
94
104
|
tooltip: { text: 'Hello world' },
|
95
105
|
disabled: true
|
96
106
|
|
107
|
+
scroll.spacer height: 10
|
108
|
+
scroll.button \
|
109
|
+
text: 'Button with mouse enter and leave',
|
110
|
+
id: 'default',
|
111
|
+
onMouseEnter: ->(action) {
|
112
|
+
action.runMultiple childActions: ->(saction) do
|
113
|
+
saction.components_set targetId: 'default', data: { displayed: false }
|
114
|
+
saction.components_set targetId: 'hovered', data: { displayed: true }
|
115
|
+
end
|
116
|
+
}
|
117
|
+
scroll.button \
|
118
|
+
text: 'Button with mouse enter and leave (Active)',
|
119
|
+
id: 'hovered',
|
120
|
+
displayed: false,
|
121
|
+
onMouseLeave: ->(action) {
|
122
|
+
action.runMultiple childActions: ->(saction) do
|
123
|
+
saction.components_set targetId: 'default', data: { displayed: true }
|
124
|
+
saction.components_set targetId: 'hovered', data: { displayed: false }
|
125
|
+
end
|
126
|
+
}, onClick: ->(action) do
|
127
|
+
action.dialogs_alert message: 'Perform action'
|
128
|
+
end
|
129
|
+
|
97
130
|
scroll.spacer height: 20
|
98
131
|
scroll.button \
|
99
132
|
icon: 'info',
|
@@ -0,0 +1,10 @@
|
|
1
|
+
page = json_ui_page json
|
2
|
+
|
3
|
+
page.body childViews: ->(body) do
|
4
|
+
body.panels_responsive styleClass: 'popover-menu', childViews: ->(sres) do
|
5
|
+
sres.p text: "Current time: #{DateTime.current}", styleClass: 'pb-2'
|
6
|
+
sres.button text: 'Update', onClick: ->(action) do
|
7
|
+
action.popovers_open url: json_ui_garage_url(path: 'views/popovers_open', key: params[:key]), key: params[:key], updateExisting: true
|
8
|
+
end
|
9
|
+
end
|
10
|
+
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: 4.36.
|
4
|
+
version: 4.36.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ''
|
@@ -300,6 +300,7 @@ files:
|
|
300
300
|
- app/views/json_ui/garage/forms/update_options.json.jbuilder
|
301
301
|
- app/views/json_ui/garage/home/blank.json.jbuilder
|
302
302
|
- app/views/json_ui/garage/home/index.json.jbuilder
|
303
|
+
- app/views/json_ui/garage/home/print.json.jbuilder
|
303
304
|
- app/views/json_ui/garage/home/slow.json.jbuilder
|
304
305
|
- app/views/json_ui/garage/lists/_autoload_section.json.jbuilder
|
305
306
|
- app/views/json_ui/garage/lists/autoload_all.json.jbuilder
|
@@ -396,6 +397,7 @@ files:
|
|
396
397
|
- app/views/json_ui/garage/views/markdowns.json.jbuilder
|
397
398
|
- app/views/json_ui/garage/views/misc.json.jbuilder
|
398
399
|
- app/views/json_ui/garage/views/multimedia.json.jbuilder
|
400
|
+
- app/views/json_ui/garage/views/popovers_open.json.jbuilder
|
399
401
|
- app/views/json_ui/garage/views/progress.json.jbuilder
|
400
402
|
- app/views/json_ui/garage/views/shareButton.json.jbuilder
|
401
403
|
- app/views/json_ui/garage/views/steppers.json.jbuilder
|