jekyll-img-srcset 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/jekyll-img-srcset.rb +1 -5
- 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: bf79fa5f1ff463976c7dbde6bc5e1b405ebb92ab44cc6cd8c60060507cefa0b7
|
4
|
+
data.tar.gz: 40674108c46079ffcf0cf211eda8a80f649e0b8e5baf0c3e7a1a842a90e5d170
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aa7ffe7b1cf84795ca502e50fba30517b25c2cc070e499271902ff18ffd8c188e14e9ec8e9a9ccbedb7eb9e1f552e6515349078cc58e67b0aaf0dd2fd898b2c2
|
7
|
+
data.tar.gz: 59256b325e7c5ba46307240c8c85ee94a0a134deaec5e44872bef72dc46b943f213ee561c4473c6823304ee5a3e8765ccbf6f8ef6f3ea35a2ffe589632c22970
|
data/lib/jekyll-img-srcset.rb
CHANGED
@@ -55,11 +55,7 @@ def format_image(ident, sizes, original_width, url, caption, title, baseurl, bas
|
|
55
55
|
end
|
56
56
|
content += ">"
|
57
57
|
content += "<div>"
|
58
|
-
srcset_sizes = if sizes.length > 0
|
59
|
-
sizes.map do | size |
|
60
|
-
"(min-width: #{(size*1.16).floor}) #{size}px"
|
61
|
-
end.join(", ") + ", 100vw"
|
62
|
-
elsif not ident[:sizes].nil? and ident[:sizes].length > 0
|
58
|
+
srcset_sizes = if not ident[:sizes].nil? and ident[:sizes].length > 0
|
63
59
|
ident[:sizes]
|
64
60
|
else
|
65
61
|
"(min-width: 1180px) 1024px, (min-width: 980px) 844px, (min-width: 740px) 640, 100vw"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-img-srcset
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jan-Philipp Stauffert
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-12-
|
11
|
+
date: 2019-12-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jekyll
|