Biblioteca lightbox de imagen mínima-views. js
| Autor: | adrianklimek |
|---|---|
| Views Total: | 2,143 |
| Sitio oficial: | Ir a la web |
| Actualizado: | September 17, 2018 |
| Licencia: | MIT |
Vista prévia
Descripción
Views.js is a lightweight vanilla JavaScript plugin which enables you open and display your images in a responsive, configurable lightbox popup.
Funcionamiento
Coloque el archivo JavaScript principal justo antes de la etiqueta del cuerpo de cierre.
<script src="src/views.js"></script>
Inicialice views. js con las opciones predeterminadas.
var viewer = new Views(Element);
Personalice el lightbox de la imagen con las siguientes opciones.
var viewer = new Views(Element,{
defaultTheme: true,
prefix: '',
loader: '',
closeButton: '<svg version="1.1" id="close-svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="24px" height="24px" viewBox="0 0 32 32" enable-background="new 0 0 32 32" xml:space="preserve"><line fill="none" stroke="#fff" stroke-width="2" stroke-linecap="round" stroke-miterlimit="10" x1="6.808" y1="6.808" x2="25.192" y2="25.192"/><line fill="none" stroke="#fff" stroke-width="2" stroke-linecap="round" stroke-miterlimit="10" x1="6.808" y1="25.192" x2="25.192" y2="6.808"/></svg>',
anywhereToClose: true,
openAnimationDuration: 0,
closeAnimationDuration: 0
}); Registro de cambios
09/17/2018
- Añadir z-index





