https://github.com/webdeveric/lightbox
https://github.com/webdeveric/lightbox
Last synced: 21 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/webdeveric/lightbox
- Owner: webdeveric
- Created: 2014-11-03T04:49:54.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2014-11-24T04:18:56.000Z (over 11 years ago)
- Last Synced: 2025-03-01T18:15:40.087Z (over 1 year ago)
- Language: JavaScript
- Size: 246 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Lightbox
This is a jQuery plugin that provides a simple lightbox.
## Example Usage
```javascript
$('.button').lightbox({
// parameters go here
}).on("lightbox-closed", function() {
// console.log("You just closed the lightbox.");
});
```
## Default parameters
```javascript
{
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;
}
}
```