amp-html 1.2.0 → 1.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/amp-html/railtie.rb +10 -0
- data/lib/amp-html/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c4414d8d2b77925120d24c626431409ecb4bfe7fa8bebedb470fe4cbab974310
|
4
|
+
data.tar.gz: c962baa1eae33a9c8bb48aa7e9dc241fc5db0043ccf1d5860f5569f757a9e4d7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4780d88842bf79ab3516fd58d19610a6e77b7a8198248cedd693c8621ce98d7753480b0015be84d06aaeef5e1dd985cf73917dd9755e704115945a6d3a38106c
|
7
|
+
data.tar.gz: 06a323ad7fa41ea8c7d51555496fa4308cffc0e19900320625656f5f2ee0f2a2088891ab1ff6dc115d0a159c4070b3823dc2c1d4c2694e293aa0e5d2366f959e
|
data/CHANGELOG.md
CHANGED
data/lib/amp-html/railtie.rb
CHANGED
@@ -20,6 +20,7 @@ module AmpHtml
|
|
20
20
|
else
|
21
21
|
options[:href] ||= href
|
22
22
|
end
|
23
|
+
options
|
23
24
|
else
|
24
25
|
false
|
25
26
|
end
|
@@ -32,6 +33,7 @@ module AmpHtml
|
|
32
33
|
else
|
33
34
|
options[:href] ||= href
|
34
35
|
end
|
36
|
+
options
|
35
37
|
end
|
36
38
|
end
|
37
39
|
config.define_component 'amp/head'
|
@@ -43,6 +45,7 @@ module AmpHtml
|
|
43
45
|
|
44
46
|
config.define_component 'amp/img', layout: 'responsive' do |options|
|
45
47
|
options[:src] = image_url options[:src]
|
48
|
+
options
|
46
49
|
end
|
47
50
|
config.define_component 'amp/video', layout: 'responsive' do |options|
|
48
51
|
options[:poster] = image_url(options[:poster]) if options.has_key?(:poster)
|
@@ -52,6 +55,7 @@ module AmpHtml
|
|
52
55
|
source[:src] = asset_url options[:src]
|
53
56
|
end
|
54
57
|
end
|
58
|
+
options
|
55
59
|
end
|
56
60
|
config.define_component 'amp/audio' do |options|
|
57
61
|
options[:src] = asset_url(options[:src]) if options.has_key?(:src)
|
@@ -60,6 +64,7 @@ module AmpHtml
|
|
60
64
|
source[:src] = asset_url options[:src]
|
61
65
|
end
|
62
66
|
end
|
67
|
+
options
|
63
68
|
end
|
64
69
|
|
65
70
|
|
@@ -83,22 +88,27 @@ module AmpHtml
|
|
83
88
|
#{'valid:' + options[:valid] + ';' if options[:valid]}
|
84
89
|
#{'invalid:' + options[:invalid] + ';' if options[:invalid]}"
|
85
90
|
options = options.except(:submit, :success, :error, :valid, :invalid)
|
91
|
+
options
|
86
92
|
end
|
87
93
|
config.define_component 'amp/form-response', type: :success do |options|
|
88
94
|
options[:"submit-#{options.delete(:type)}"] = true
|
95
|
+
options
|
89
96
|
end
|
90
97
|
config.define_component 'amp/input' do |options|
|
91
98
|
options[:on] = "#{options[:on] + ';' if options[:on]}
|
92
99
|
#{'onchange:' + options[:onchange] + ';' if options[:onchange]}"
|
93
100
|
options = options.except(:onchange)
|
101
|
+
options
|
94
102
|
end
|
95
103
|
config.define_component 'amp/selector', layout: 'container' do |options|
|
96
104
|
options[:on] = "#{options[:on] + ';' if options[:on]}
|
97
105
|
#{'onchange:' + options[:onchange] + ';' if options[:onchange]}"
|
98
106
|
options = options.except(:onchange)
|
107
|
+
options
|
99
108
|
end
|
100
109
|
config.define_component 'amp/mustache' do |options|
|
101
110
|
options[:type] = 'amp-mustache'
|
111
|
+
options
|
102
112
|
end
|
103
113
|
|
104
114
|
|
data/lib/amp-html/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: amp-html
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jonas Hübotter
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-02-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: railties
|