2013-05-08 12:06:54 +00:00
|
|
|
/*!
|
|
|
|
* jQuery UI Effects Puff @VERSION
|
|
|
|
* http://jqueryui.com
|
|
|
|
*
|
2014-12-21 18:27:43 +00:00
|
|
|
* Copyright jQuery Foundation and other contributors
|
2013-05-08 12:06:54 +00:00
|
|
|
* Released under the MIT license.
|
|
|
|
* http://jquery.org/license
|
|
|
|
*/
|
2014-10-30 19:55:08 +00:00
|
|
|
|
|
|
|
//>>label: Puff Effect
|
|
|
|
//>>group: Effects
|
|
|
|
//>>description: Creates a puff effect by scaling the element up and hiding it at the same time.
|
|
|
|
//>>docs: http://api.jqueryui.com/puff-effect/
|
|
|
|
//>>demos: http://jqueryui.com/effect/
|
|
|
|
|
2013-07-12 16:40:48 +00:00
|
|
|
(function( factory ) {
|
|
|
|
if ( typeof define === "function" && define.amd ) {
|
2013-05-08 12:06:54 +00:00
|
|
|
|
2013-07-12 16:40:48 +00:00
|
|
|
// AMD. Register as an anonymous module.
|
|
|
|
define([
|
|
|
|
"jquery",
|
2013-12-02 18:36:12 +00:00
|
|
|
"./effect",
|
|
|
|
"./effect-scale"
|
2013-07-12 16:40:48 +00:00
|
|
|
], factory );
|
|
|
|
} else {
|
|
|
|
|
|
|
|
// Browser globals
|
|
|
|
factory( jQuery );
|
|
|
|
}
|
|
|
|
}(function( $ ) {
|
|
|
|
|
2012-12-26 13:35:42 +00:00
|
|
|
return $.effects.define( "puff", "hide", function( options, done ) {
|
|
|
|
var newOptions = $.extend( true, {}, options, {
|
2013-05-08 12:06:54 +00:00
|
|
|
fade: true,
|
2012-12-26 13:35:42 +00:00
|
|
|
percent: parseInt( options.percent, 10 ) || 150
|
2013-05-08 12:06:54 +00:00
|
|
|
});
|
|
|
|
|
2012-12-26 13:35:42 +00:00
|
|
|
$.effects.effect.scale.call( this, newOptions, done );
|
|
|
|
});
|
2013-05-08 12:06:54 +00:00
|
|
|
|
2013-07-12 16:40:48 +00:00
|
|
|
}));
|