cloudinary-community / cloudinary-community/cloudinary-util
[Bug] `url-loader` ignores `height` option when crop mode is "limit"
- Dominant language
- TypeScript
- Stars
- 14
- Forks
- 23
- PR merge metrics
- No merged PRs in 30d
Description
# **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:**
https://github.com/cloudinary-community/cloudinary-util/blob/6f966dad3ef375c5f9de2710760129582bd9cc82/packages/url-loader/src/plugins/cropping.ts#L227-L229
## **Steps To Reproduce the error**
```ts
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
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.