Bug Report
Describe the bug
The url-loader removes the height when the crop mode is set to limit. Therefore, it ignores the height portion of the "limit" transformation and only enforces a width limit.
Relevant code reference:
|
if (!["limit"].includes(crop) && typeof height === "number") { |
|
transformations.push(`h_${height}`); |
|
} |
Steps To Reproduce the error
const url = constructCloudinaryUrl({
options: {
src: 'my-public-id',
width: 800,
height: 600
},
config: {
cloud: {
cloudName: 'my-cloud'
}
}
});
Expected behaviour
I expect the url to have a h_600 param
Bug Report
Describe the bug
The
url-loaderremoves the height when the crop mode is set tolimit. Therefore, it ignores theheightportion of the "limit" transformation and only enforces a width limit.Relevant code reference:
cloudinary-util/packages/url-loader/src/plugins/cropping.ts
Lines 227 to 229 in 6f966da
Steps To Reproduce the error
Expected behaviour
I expect the url to have a
h_600param