glib-web 0.4.58 → 0.4.59

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4bf76c52f94ec06c17e2fd9f77872274d543d084
4
- data.tar.gz: 22360685e95d144e2a6507a25064b39f9b898155
3
+ metadata.gz: 43d8906b4ef965875d75a600b81d440ad34b32bb
4
+ data.tar.gz: 40d4203cecc000335fb49303f7f41c569213d56d
5
5
  SHA512:
6
- metadata.gz: 625bf8b69fa353e6766726a86f2a1876f72d65bb12a848f0914c941616160ddb3dd058a2e8e82b55d21f104835dc95356082d3db224cafc72a9a4c03808846b8
7
- data.tar.gz: f4a282069197813a3e9e715cc349d8348bad37f35362b262092096e6dc26f638a8e63007712fb7478148c7f0e3e61fc421211e5f56022e78c92b18c822577f28
6
+ metadata.gz: 7f8d68129838007a4844863e5120e78f8006d33c9b7bd275c2afe61e186942503d56d9aff8d377405d2e08d3a4f3602dd1cce0dea2ffaa08b46dc1e81bc37ae2
7
+ data.tar.gz: a9c1d10c6e926951e31a2a62c0f212d179effaabeb26f7f965f2967659b783b50cc0a5ad91738ab35a8e0e6d5c07b31420b3f462813dd1530eb5445cef379d44
@@ -189,13 +189,23 @@ module Glib
189
189
  end
190
190
 
191
191
  json.set!(propName) do
192
- data[:material] ||= {}
193
- data[:material][:name] = name if name
192
+ if name
193
+ data[:material] ||= {}
194
+ data[:material][:name] = name
195
+ end
194
196
 
195
- material = data[:material]
196
- json.material do
197
- json.name material[:name]
198
- json.size material[:size] if material[:size]
197
+ if (material = data[:material])
198
+ json.material do
199
+ json.name material[:name]
200
+ json.size material[:size] if material[:size]
201
+ end
202
+ end
203
+
204
+ if (fa = data[:fa])
205
+ json.fa do
206
+ json.name fa[:name]
207
+ json.size fa[:size] if fa[:size]
208
+ end
199
209
  end
200
210
 
201
211
  if (custom = data[:custom])
@@ -80,6 +80,7 @@ module Glib
80
80
  end
81
81
 
82
82
  class Markdown < AbstractText
83
+ bool :previewVideo
83
84
  end
84
85
 
85
86
  class Label < AbstractText
@@ -5,7 +5,7 @@ json_ui_page json do |page|
5
5
 
6
6
  page.scroll padding: glib_json_padding_body, childViews: ->(scroll) do
7
7
  scroll.spacer height: 20
8
- scroll.h2 text: 'Paragraph'
8
+ scroll.h2 text: 'Markdown'
9
9
  scroll.spacer height: 6
10
10
  scroll.markdown text:
11
11
  '# h1 Heading' + "\n" +
@@ -25,6 +25,17 @@ json_ui_page json do |page|
25
25
  "\n" +
26
26
  '_This is italic text_' + "\n" +
27
27
  "\n" +
28
- '~~Strikethrough~~' + "\n"
28
+ '~~Strikethrough~~' + "\n" +
29
+ "\n" +
30
+ 'https://www.google.com' + "\n"
31
+
32
+ scroll.spacer height: 20
33
+ scroll.h2 text: 'Markdown with preview'
34
+ scroll.spacer height: 6
35
+ scroll.markdown text: 'Here is the video: https://www.youtube.com/watch?v=947op8yKJRY', previewVideo: true
36
+
37
+ scroll.spacer height: 10
38
+ scroll.markdown text: 'Some videos: https://youtu.be/ATnpEOo3GJA, https://www.youtube.com/watch?v=947op8yKJRY', previewVideo: true
39
+
29
40
  end
30
41
  end
@@ -1,13 +1,6 @@
1
1
  module Glib
2
2
  module JsonCrawler
3
3
  class Router
4
- @@crawler_actions = Set.new
5
- @@store_action = false
6
-
7
- def self.crawler_actions
8
- @@crawler_actions
9
- end
10
-
11
4
  def self.log(action, url, response = nil)
12
5
  @@logger.puts ' ' * @@depth + [
13
6
  action,
@@ -16,11 +9,10 @@ module Glib
16
9
  ].compact.join(' :: ')
17
10
  end
18
11
 
19
- def self.set_up(logger, store_action)
12
+ def self.set_up(logger)
20
13
  @@depth = -1
21
14
  @@logger = logger
22
15
  @@visitor = Glib::Json::Traversal::Visitor.new
23
- @@store_action = store_action
24
16
  end
25
17
 
26
18
  def self.step(http, args)
@@ -38,12 +30,8 @@ module Glib
38
30
  @@depth += 1
39
31
  child = case action
40
32
  when 'initiate_navigation'
41
- @@crawler_actions.add([action, params['url']]) if @@store_action
42
33
  JsonCrawler::NavInitiate.new(http, params, action)
43
34
  when 'windows/open-v1', 'dialogs/open-v1', 'windows/reload-v1'
44
- unless action == 'dialogs/open-v1'
45
- @@crawler_actions.add([action, params['url']]) if @@store_action
46
- end
47
35
  JsonCrawler::WindowsOpen.new(http, params, action)
48
36
  # when 'http/delete-v1'
49
37
  # JsonCrawler::ActionHttp.new(:delete, http, params, action)
@@ -54,9 +42,6 @@ module Glib
54
42
  raise 'Submit action needs to be inside a form' if forms.size < 1
55
43
  JsonCrawler::FormsSubmit.new(http, params, action, forms.last)
56
44
  else
57
- unless ['http/delete-v1', 'dialogs/oauth-v1', 'windows/openWeb-v1'].include?(action)
58
- @@crawler_actions.add([action, params['url']]) if @@store_action
59
- end
60
45
  self.log action, params['url']
61
46
  end
62
47
  @@depth -= 1
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.4.58
4
+ version: 0.4.59
5
5
  platform: ruby
6
6
  authors:
7
7
  - ''