jekyll-cloudinary 1.2.1 → 1.2.2
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/README.md +13 -9
- data/lib/jekyll/cloudinary/version.rb +1 -1
- data/lib/jekyll/cloudinary.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 6e8c01206c15de57029914a3523325093bccf3ce
|
|
4
|
+
data.tar.gz: 97444d725009ae6fa198e844a18910c65051b4ac
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 912ad98d4df1aed9c707238cbe4209f1acb8d797eb4560ba0ebf0b05834392936e0081d142e789b3f8aeb0b93e9e7f3caad7c105e001981e4cadef09fcf4e3c8
|
|
7
|
+
data.tar.gz: 88388d405cc7e8f2f762e3b21d8983c795763fa4b5b99c7285701d2a81550d9a5f05f3aab8238b23e56547cee3512e894459ec38ed04a0720e82e3e3f19e36d4
|
data/README.md
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
# Jekyll Cloudinary Liquid tag
|
|
2
2
|
|
|
3
|
+
[](https://badge.fury.io/rb/jekyll-cloudinary)
|
|
4
|
+
[](http://rubygems.org/gems/jekyll-cloudinary)
|
|
5
|
+
|
|
3
6
|
`jekyll-cloudinary` is a [Jekyll](http://jekyllrb.com/) plugin adding a [Liquid](http://liquidmarkup.org) tag to ease the use of [Cloudinary](http://cloudinary.com/invites/lpov9zyyucivvxsnalc5/sgyyc0j14k6p0sbt51nw) for responsive images in your Markdown/[Kramdown](http://kramdown.gettalong.org/) posts.
|
|
4
7
|
|
|
5
8
|
It builds the HTML for responsive images in the posts, using the `srcset` and `sizes` attributes for the `<img />` tag (see [the "varying size and density" section of this post by Jake Archibald](https://jakearchibald.com/2015/anatomy-of-responsive-images/#varying-size-and-density) if this is new for you). URLs in the `srcset` are cloudinary URLs that [fetch on-the-fly](http://cloudinary.com/features#fetch) the post's images and resizes them to several sizes.
|
|
@@ -84,26 +87,27 @@ This preset will generate five images 320 to 1600 pixels wide in the `srcset` an
|
|
|
84
87
|
With this preset, you only have to write this in your Markdown post:
|
|
85
88
|
|
|
86
89
|
```liquid
|
|
87
|
-
{% cloudinary /assets/img.jpg %}
|
|
90
|
+
{% cloudinary /assets/img.jpg alt="beautiful!" %}
|
|
88
91
|
```
|
|
89
92
|
|
|
90
93
|
To get this HTML:
|
|
91
94
|
|
|
92
95
|
```html
|
|
93
96
|
<img
|
|
94
|
-
src="https
|
|
97
|
+
src="https://<your-domain>/assets/img.jpg"
|
|
95
98
|
srcset="
|
|
96
|
-
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,w_320,q_auto,f_auto/https
|
|
97
|
-
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,
|
|
98
|
-
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,
|
|
99
|
-
http://res.cloudinary.com
|
|
100
|
-
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,
|
|
101
|
-
|
|
99
|
+
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,w_320,q_auto,f_auto/https://<your-domain>/assets/img.jpg 320w,
|
|
100
|
+
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,w_640,q_auto,f_auto/https://<your-domain>/assets/img.jpg 640w
|
|
101
|
+
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,w_960,q_auto,f_auto/https://<your-domain>/assets/img.jpg 960w
|
|
102
|
+
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,w_1280,q_auto,f_auto/https://<your-domain>/assets/img.jpg 1280w
|
|
103
|
+
http://res.cloudinary.com/<cloud_name>/image/fetch/c_scale,w_1600,q_auto,f_auto/https://<your-domain>/assets/img.jpg 1600w
|
|
104
|
+
"
|
|
102
105
|
sizes="(min-width: 50rem) 50rem, 90vw"
|
|
106
|
+
alt="beautiful!"
|
|
103
107
|
/>
|
|
104
108
|
```
|
|
105
109
|
|
|
106
|
-
There is a true default default preset, but you're strongly encouraged to define your own default preset.
|
|
110
|
+
There is a true default `default` preset, but you're strongly encouraged to define your own default preset.
|
|
107
111
|
|
|
108
112
|
#### Additional presets
|
|
109
113
|
|
data/lib/jekyll/cloudinary.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: jekyll-cloudinary
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.2.
|
|
4
|
+
version: 1.2.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Nicolas Hoizey
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2016-07-
|
|
11
|
+
date: 2016-07-11 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: jekyll
|