Skip to content

webdeveric/lightbox

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lightbox

This is a jQuery plugin that provides a simple lightbox.

Example Usage

$('.button').lightbox({
    // parameters go here
}).on("lightbox-closed", function() {
    // console.log("You just closed the lightbox.");
});

Default parameters

{
    container: ".lightbox",
    content: ".lightbox-content",
    isOpenClass: "open",
    activeClass: "active",
    closeOnClick: ".lightbox-overlay, .lightbox-close, .lightbox-frame",
    closeOnESC: true,
    descendantSelector: null,
    processAjaxResponse: function(data, textStatus, jqXHR) {

        var ct = jqXHR.getResponseHeader("content-type") || "";

        if (ct.indexOf("json") > -1) {
            return data.content;
        }

        return data;
    }
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors