https://github.com/james2doyle/jquery.doodal.js
a very simplistic modal plugin for jQuery. Has custom events, allows stacking, and is powered by CSS transitions.
https://github.com/james2doyle/jquery.doodal.js
Last synced: 2 months ago
JSON representation
a very simplistic modal plugin for jQuery. Has custom events, allows stacking, and is powered by CSS transitions.
- Host: GitHub
- URL: https://github.com/james2doyle/jquery.doodal.js
- Owner: james2doyle
- License: mit
- Created: 2013-09-09T19:53:48.000Z (almost 13 years ago)
- Default Branch: master
- Last Pushed: 2013-09-18T16:35:34.000Z (over 12 years ago)
- Last Synced: 2025-03-03T20:03:20.550Z (over 1 year ago)
- Language: CSS
- Homepage: http://james2doyle.github.io/jquery.doodal.js/
- Size: 426 KB
- Stars: 2
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
jquery.doodal.js
================
> jQuery.doodal.js is a very simplistic modal plugin for jQuery. It has custom events, allows stacking, and is powered by CSS transitions
[See the demo](http://james2doyle.github.io/jquery.doodal.js/)
### Usage
Instatiate a new doodal.
```javascript
$('.doodal').doodal({
closeclass: '.doodal-close',
trueclass: '.doodal-true',
falseclass: '.doodal-false',
showclass: 'showing',
escape: true // bind escape key to close
});
```
Those are all the default options so in this specific example I am not actually overwriting anything.
Now trigger an `open` to see it:
```javascript
$('#doodal1').trigger('open');
```
### Custom Events
* *open*: - when the modal starts to open
* *afteropen*: - after the animation is over and it is open
* *ontrue*: - for confirms yes button
* *onfalse*: - for confirms no button
* *close*: - when the close is clicked
* *afterclose*: - after the animation is over and it is hidden