I was using lightbox2 in an AngularJS app and realized that it was pretty difficult to customize it.
The requirements were very simple,
The requirements were very simple,
- editing the album name/ picture description
- deleting album/picture
- different overlay than the usual title below/above the image
I made use of AngularUI modal since that was already used in my app. Besides, as they say, no point in rewriting stuff that's already there.
The usage is pretty simple,
<lightbox images="album"></lightbox>
where album is an array of image details. A sample image detail object would be
{src: "/path/to/img", header: "the data/info that should be displayed above the image", description: "the info to be displayed beside the image"}
The header and the description can also be HTML strings. The dimensions in tile view are 150px x 150px by default.
The directive can be customized/configured to handle various cases (inline editing using contenteditable, delete, change tile size, background, etc)