equal
deleted
inserted
replaced
1 /*! |
1 /*! |
2 * jQuery UI Effects Size 1.12.1 |
2 * jQuery UI Effects Size 1.13.1 |
3 * http://jqueryui.com |
3 * http://jqueryui.com |
4 * |
4 * |
5 * Copyright jQuery Foundation and other contributors |
5 * Copyright jQuery Foundation and other contributors |
6 * Released under the MIT license. |
6 * Released under the MIT license. |
7 * http://jquery.org/license |
7 * http://jquery.org/license |
12 //>>description: Resize an element to a specified width and height. |
12 //>>description: Resize an element to a specified width and height. |
13 //>>docs: http://api.jqueryui.com/size-effect/ |
13 //>>docs: http://api.jqueryui.com/size-effect/ |
14 //>>demos: http://jqueryui.com/effect/ |
14 //>>demos: http://jqueryui.com/effect/ |
15 |
15 |
16 ( function( factory ) { |
16 ( function( factory ) { |
|
17 "use strict"; |
|
18 |
17 if ( typeof define === "function" && define.amd ) { |
19 if ( typeof define === "function" && define.amd ) { |
18 |
20 |
19 // AMD. Register as an anonymous module. |
21 // AMD. Register as an anonymous module. |
20 define( [ |
22 define( [ |
21 "jquery", |
23 "jquery", |
24 } else { |
26 } else { |
25 |
27 |
26 // Browser globals |
28 // Browser globals |
27 factory( jQuery ); |
29 factory( jQuery ); |
28 } |
30 } |
29 }( function( $ ) { |
31 } )( function( $ ) { |
|
32 "use strict"; |
30 |
33 |
31 return $.effects.define( "size", function( options, done ) { |
34 return $.effects.define( "size", function( options, done ) { |
32 |
35 |
33 // Create element |
36 // Create element |
34 var baseline, factor, temp, |
37 var baseline, factor, temp, |
102 from.top = ( original.outerHeight - from.outerHeight ) * baseline.y + pos.top; |
105 from.top = ( original.outerHeight - from.outerHeight ) * baseline.y + pos.top; |
103 from.left = ( original.outerWidth - from.outerWidth ) * baseline.x + pos.left; |
106 from.left = ( original.outerWidth - from.outerWidth ) * baseline.x + pos.left; |
104 to.top = ( original.outerHeight - to.outerHeight ) * baseline.y + pos.top; |
107 to.top = ( original.outerHeight - to.outerHeight ) * baseline.y + pos.top; |
105 to.left = ( original.outerWidth - to.outerWidth ) * baseline.x + pos.left; |
108 to.left = ( original.outerWidth - to.outerWidth ) * baseline.x + pos.left; |
106 } |
109 } |
|
110 delete from.outerHeight; |
|
111 delete from.outerWidth; |
107 element.css( from ); |
112 element.css( from ); |
108 |
113 |
109 // Animate the children if desired |
114 // Animate the children if desired |
110 if ( scale === "content" || scale === "both" ) { |
115 if ( scale === "content" || scale === "both" ) { |
111 |
116 |
185 } |
190 } |
186 } ); |
191 } ); |
187 |
192 |
188 } ); |
193 } ); |
189 |
194 |
190 } ) ); |
195 } ); |