angular-modal-gallery
angular-modal-gallery copied to clipboard
Custom DownloadUrl
I'm submitting a...
[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report
[x] Feature request
[ ] Documentation issue or request
[ ] Support request
As per https://github.com/Ks89/angular-modal-gallery/issues/183#issuecomment-669228041
Current behavior
Calling modalGalleryService.open with the option config.libConfig.currentImageConfig.downloadable: true results in a download button on the page which downloads the file specified in modal.img
Expected behavior
It would be great that the download button downloads the "extUrl" or another property than "img". Maybe a "downloadUrl" property which takes priority over img when specified.
What is the motivation / use case for changing the behavior?
The reason behind this is that we show a resized image on the Webapp and allow the download of the full sized image.
Environment (the most important section to fill very carefully)
- @ks89/angular-modal-gallery version: 8.0.0-beta.4
- Node version: 12.14.1
- npm version: 6.14.5
- Operating System and version: macOS 10.15.6
- Angular version: 9.1.11
- angular-cli version (or SystemJS/Webpack): 9.1.9
- I'm using Server Side Rendering with angular-universal: NO
- I'm compiling with mode: PROD with AOT
Browser:
- [ ] Chrome (desktop) version 85.0.4183.83
Others:
good idea to create a dedicated issue