vitals_image 0.2.0 → 0.2.1
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/CHANGELOG.md +5 -1
- data/README.md +16 -3
- data/lib/vitals_image/gem_version.rb +1 -1
- data/lib/vitals_image/optimizer/active_storage.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: 7c75ba4087e4d7a4028c7264bb3aa2fe3a5084eb1f627714d58e468f3a999289
|
4
|
+
data.tar.gz: 625fe4c2c4462b749b0c841e218461c7740e633e054a2f269b9b34f41b5fde04
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b8042b6efa3d6c6164a62a4ccc6b576a9993525f8efbbd8e19ad0a1fa7ac6d15d28c0e68e5604ae22823c6a39266747c3180f72350bce97889c3a3a228f8c02c
|
7
|
+
data.tar.gz: fb2a462820d0228734fef483bee2beefefab5065556a8e916c37493c9ffe651c442b21cd193f82375b59e2c19b72bd702a9d91abc10c636fbcac90cc5f2f6904
|
data/CHANGELOG.md
CHANGED
@@ -1,8 +1,12 @@
|
|
1
1
|
## [Unreleased]
|
2
2
|
|
3
|
+
## [0.2.1] - 2021-05-22
|
4
|
+
|
5
|
+
- Do not attempt to transform invariable images
|
6
|
+
|
3
7
|
## [0.2.0] - 2021-05-18
|
4
8
|
|
5
|
-
- Use the `
|
9
|
+
- Use the `optimal_quality` value of blob metadata instead of fixed `85` if its available;
|
6
10
|
- Remove some unecessary configs;
|
7
11
|
- Drop analyzers and use `active_analysis` gem instead;
|
8
12
|
- Use "retry once" strategy instead of `create_or_find_by`;
|
data/README.md
CHANGED
@@ -135,15 +135,28 @@ The following configuration options are available. The defaults were chosen for
|
|
135
135
|
| png_optimization | see below | see below | Hash of options to pass to active storage when optimizing a PNG. |
|
136
136
|
| active_storage_route | `:inherited` | `:inherited` | Defines how urls of active storage images will be generated. If `inherited` it will use the same as active storage. Other valid options are `redirect`, `proxy` and `public`. Whatever is set here can be overriden in the helper. |
|
137
137
|
|
138
|
+
Minimagick
|
138
139
|
```ruby
|
139
140
|
# jpeg_conversion
|
140
|
-
{
|
141
|
+
{ saver: { strip: true, quality: 85, interlace: "JPEG", sampling_factor: "4:2:0", colorspace: "sRGB", background: :white, flatten: true, alpha: :off }, format: "jpg" }
|
141
142
|
|
142
143
|
# jpeg_optimization:
|
143
|
-
{
|
144
|
+
{ saver: { strip: true, quality: 85, interlace: "JPEG", sampling_factor: "4:2:0", colorspace: "sRGB" } }
|
144
145
|
|
145
146
|
# png_optimization:
|
146
|
-
{ strip: true, quality: 00 }
|
147
|
+
{ saver: { strip: true, quality: 00 } }
|
148
|
+
```
|
149
|
+
|
150
|
+
Vips
|
151
|
+
```ruby
|
152
|
+
# jpeg_conversion
|
153
|
+
{ saver: { strip: true, quality: 85, interlace: true, optimize_coding: true, trellis_quant: true, quant_table: 3, background: 255 }, format: "jpg" }
|
154
|
+
|
155
|
+
# jpeg_optimization:
|
156
|
+
{ saver: { strip: true, quality: 85, interlace: true, optimize_coding: true, trellis_quant: true, quant_table: 3 } }
|
157
|
+
|
158
|
+
# png_optimization:
|
159
|
+
{ saver: { strip: true, compression: 9 } }
|
147
160
|
```
|
148
161
|
|
149
162
|
These can be configured in your environment files, just like any other rails settings:
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vitals_image
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Breno Gazzola
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-06-
|
11
|
+
date: 2021-06-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activejob
|