Skip to content

Commit aa597b1

Browse files
author
amrelbialy
committed
chore: release 1.1.0
1 parent ae02e20 commit aa597b1

File tree

4 files changed

+30
-4
lines changed

4 files changed

+30
-4
lines changed

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,15 @@ Types of changes:
2525
- ...
2626

2727
-------------
28+
29+
## 1.1.0 - 2021-07-19
30+
31+
### Deprecated
32+
33+
- Property **ignoreNodeImgSize** is deprecated. Use **imageSizeAttributes: 'ignore'** instead
34+
35+
### Added
36+
- new property: **imageSizeAttributes**
2837
## 1.0.7- 2020-02-12
2938
### Added
3039
- OnImgLoad to capture event on load

README.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
[![Release](https://img.shields.io/badge/release-v1.0.7-blue.svg)](https://github.com/scaleflex/vue-cloudimage-responsive-blur-hash/releases)
1+
[![Release](https://img.shields.io/badge/release-v1.1.0-blue.svg)](https://github.com/scaleflex/vue-cloudimage-responsive-blur-hash/releases)
22
[![Free plan](https://img.shields.io/badge/price-includes%20free%20plan-green.svg)](https://www.cloudimage.io/en/home#b38181a6-b9c8-4015-9742-7b1a1ad382d5)
33
[![Contributions welcome](https://img.shields.io/badge/contributions-welcome-orange.svg)](#contributing)
44
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://opensource.org/licenses/MIT)
@@ -315,6 +315,22 @@ Delay for processing an image after rendering component.
315315
**NOTE:** normally the parameter is not needed, but in some cases with integrating third part libraries it can fix wrong
316316
calculation of image container.
317317
318+
### ImageSizeAttributes
319+
320+
###### Type: **String** | possible values: 'use', 'ignore', 'take-ratio' | Default: **'use'**
321+
322+
If width and height attributes are set:
323+
324+
**use** - width & height attributes values will be used to calculate image size (according to user's DPR) and **ratio**.
325+
326+
**take-ratio** - width & height attributes values will be used only to calculate **ratio**.
327+
328+
**ignore** - width & height attributes will be ignored.
329+
330+
If width and height attributes are NOT set, image container size will be detected to calculate result image size (according to user's DPR)
331+
332+
*Note*: If only width or height attributes is set, ratio is going to be taken from ci-ratio image attribute
333+
318334
## <a name="image_properties"></a> Image properties
319335
320336
### src

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-cloudimage-responsive-blur-hash",
3-
"version": "1.0.7",
3+
"version": "1.1.0",
44
"main": "dist/index.cjs.js",
55
"module": "dist/index.es.js",
66
"description": "Cloudimage Responsive will smartly resize, compress and accelerate images across the World in your site for all devices. The plugin supports lazy loading technique with blur hash placeholder.",
@@ -36,7 +36,7 @@
3636
"publish-demo": "npm run build-demo && npm run deploy"
3737
},
3838
"dependencies": {
39-
"cloudimage-responsive-utils": "^2.0.16",
39+
"cloudimage-responsive-utils": "^2.3.0",
4040
"core-js": "^3.6.5",
4141
"throttle-debounce": "^2.3.0"
4242
},
@@ -83,4 +83,4 @@
8383
"webpack-cli": "^3.3.12",
8484
"webpack-dev-server": "^3.11.0"
8585
}
86-
}
86+
}

src/CloudImageProvider.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ export default {
3232
xl: "(min-width: 1200px)" // from 1200 USUALSCREEN
3333
},
3434
params: this.cloudImageConfig.params? processParams(this.cloudImageConfig.params) :'org_if_sml=1',
35+
imageSizeAttributes: this.cloudImageConfig.imageSizeAttributes || 'use',
3536
innerWidth: typeof window !== "undefined" ? window.innerWidth : null,
3637
previewQualityFactor: 10,
3738
doNotReplaceURL: this.cloudImageConfig.doNotReplaceURL || false,

0 commit comments

Comments
 (0)