compact / angular-bootstrap-lightbox

An AngularJS lightbox built using UI Bootstrap Modal.
http://compact.github.io/angular-bootstrap-lightbox/
MIT License
306 stars 134 forks source link

Failed to load image when image property is not "url" #79

Open maheshtc opened 7 years ago

maheshtc commented 7 years ago

I have been trying to integrate this angular plugin. But I stuck at one place where my image object do not have property name "url". It is "imgUrl" and not possible to alter this property name to "url". What should I pass in openModel method when image property name is not same? Please guide me to correct this issue.

viktorhunko commented 7 years ago

@maheshtc you can set proper field name in your configs: LightboxProvider.getImageUrl = image => { return image. imgUrl; };