Lovely.IO

The Next Generation of Front-Side

Package Info

Links
Size
1.36 KB (gzipped)
Tags
UI, zoom
Author
Nikolay Nemshilov
License
MIT
Versions
CDN Links
Dependencies

Zoom

Zoom is a lightweight version of a lightbox widget that works just with images and zooms them instead of showing the screen locker and a lightbox dialog

Usage

Use the standard link and image markup with the data-zoom attribute

<a href="image-full.png" data-zoom=""><img src="image-thmb.png"></a>

Options can go inside of the data-zoom attribute in JSON format

<a href="image-full.jpg" data-zoom='{"fxDuration": 0}'>
  <img src="image-thmb.jpg">
</a>

After that hook this module on your page in any standard way, say by using the Lovely loader

Lovely(['zoom'], function(Zoom) {
  // Zoom.Options
});

It will automatically handle all the clicks on your links marked with the data-zoom attribute

Options

You can use the following options with your Zoom instances

Events

In addition to the normal DOM events, instances of the Zoom class emit the following events

Copyright And License

This project is released under the terms of the MIT license

Copyright (C) 2012 Nikolay Nemshilov