Ks89 / angular-modal-gallery

Modal image gallery for Angular
https://ks89.github.io/angular-modal-gallery-2024-v12.github.io/
MIT License
146 stars 80 forks source link

Ability to set fallback image #194

Closed sm-g closed 4 years ago

sm-g commented 5 years ago

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

Current behavior

When ModalImage.img or PlainImage.img points to url, returning 404, the default browser fallback image shown in place of PlainImage and still loading spinner in place of ModalImage.

Expected behavior

Ability to set fallback image, i.e. to configure onerror of <img>:

onerror="this.src='error.jpg';this.onerror='';"

Environment


- @ks89/angular-modal-gallery version: 7.2.1
- Operating System and version:  Windows
- I'm using Server Side Rendering with angular-universal: NO
- I'm compiling with mode: DEBUG



Browser:
- [ x] Any            
Ks89 commented 5 years ago

Interesting idea.

Ks89 commented 4 years ago

Feature implemented and scheduled for angular-modal-gallery 8.0.0-beta.1 that is coming soon. I pushed all commits into branch 800.

I'm sorry for the big delay, but version 8, required a huge effort.

Issue closed.