jquery-ui-rails 2.0.2 → 3.0.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of jquery-ui-rails might be problematic. Click here for more details.

Files changed (131) hide show
  1. data/History.md +15 -0
  2. data/License.txt +2 -3
  3. data/README.md +17 -19
  4. data/Rakefile +79 -28
  5. data/lib/jquery/ui/rails/version.rb +1 -1
  6. data/vendor/assets/javascripts/jquery.ui.accordion.js +537 -417
  7. data/vendor/assets/javascripts/jquery.ui.all.js +17 -14
  8. data/vendor/assets/javascripts/jquery.ui.autocomplete.js +311 -339
  9. data/vendor/assets/javascripts/jquery.ui.button.js +63 -59
  10. data/vendor/assets/javascripts/jquery.ui.core.js +134 -112
  11. data/vendor/assets/javascripts/jquery.ui.datepicker-ar-DZ.js +2 -2
  12. data/vendor/assets/javascripts/jquery.ui.datepicker-ar.js +3 -3
  13. data/vendor/assets/javascripts/jquery.ui.datepicker-az.js +3 -3
  14. data/vendor/assets/javascripts/jquery.ui.datepicker-bg.js +16 -16
  15. data/vendor/assets/javascripts/jquery.ui.datepicker-bs.js +5 -5
  16. data/vendor/assets/javascripts/jquery.ui.datepicker-ca.js +13 -13
  17. data/vendor/assets/javascripts/jquery.ui.datepicker-cs.js +3 -3
  18. data/vendor/assets/javascripts/jquery.ui.datepicker-cy-GB.js +1 -1
  19. data/vendor/assets/javascripts/jquery.ui.datepicker-da.js +9 -9
  20. data/vendor/assets/javascripts/jquery.ui.datepicker-de.js +2 -2
  21. data/vendor/assets/javascripts/jquery.ui.datepicker-el.js +1 -1
  22. data/vendor/assets/javascripts/jquery.ui.datepicker-eo.js +2 -2
  23. data/vendor/assets/javascripts/jquery.ui.datepicker-es.js +6 -6
  24. data/vendor/assets/javascripts/jquery.ui.datepicker-et.js +1 -1
  25. data/vendor/assets/javascripts/jquery.ui.datepicker-eu.js +3 -3
  26. data/vendor/assets/javascripts/jquery.ui.datepicker-fa.js +3 -3
  27. data/vendor/assets/javascripts/jquery.ui.datepicker-fi.js +5 -5
  28. data/vendor/assets/javascripts/jquery.ui.datepicker-fo.js +3 -3
  29. data/vendor/assets/javascripts/jquery.ui.datepicker-fr-CH.js +3 -3
  30. data/vendor/assets/javascripts/jquery.ui.datepicker-fr.js +2 -2
  31. data/vendor/assets/javascripts/jquery.ui.datepicker-gl.js +6 -6
  32. data/vendor/assets/javascripts/jquery.ui.datepicker-he.js +2 -2
  33. data/vendor/assets/javascripts/jquery.ui.datepicker-hr.js +3 -3
  34. data/vendor/assets/javascripts/jquery.ui.datepicker-hy.js +3 -3
  35. data/vendor/assets/javascripts/jquery.ui.datepicker-id.js +3 -3
  36. data/vendor/assets/javascripts/jquery.ui.datepicker-is.js +11 -11
  37. data/vendor/assets/javascripts/jquery.ui.datepicker-it.js +3 -3
  38. data/vendor/assets/javascripts/jquery.ui.datepicker-ja.js +3 -3
  39. data/vendor/assets/javascripts/jquery.ui.datepicker-kk.js +2 -2
  40. data/vendor/assets/javascripts/jquery.ui.datepicker-ko.js +1 -1
  41. data/vendor/assets/javascripts/jquery.ui.datepicker-lt.js +3 -3
  42. data/vendor/assets/javascripts/jquery.ui.datepicker-lv.js +1 -1
  43. data/vendor/assets/javascripts/jquery.ui.datepicker-ml.js +1 -1
  44. data/vendor/assets/javascripts/jquery.ui.datepicker-ms.js +3 -3
  45. data/vendor/assets/javascripts/jquery.ui.datepicker-nl.js +1 -1
  46. data/vendor/assets/javascripts/jquery.ui.datepicker-no.js +18 -18
  47. data/vendor/assets/javascripts/jquery.ui.datepicker-pl.js +2 -2
  48. data/vendor/assets/javascripts/jquery.ui.datepicker-pt-BR.js +7 -7
  49. data/vendor/assets/javascripts/jquery.ui.datepicker-pt.js +6 -6
  50. data/vendor/assets/javascripts/jquery.ui.datepicker-rm.js +2 -2
  51. data/vendor/assets/javascripts/jquery.ui.datepicker-ro.js +2 -2
  52. data/vendor/assets/javascripts/jquery.ui.datepicker-ru.js +3 -3
  53. data/vendor/assets/javascripts/jquery.ui.datepicker-sk.js +2 -2
  54. data/vendor/assets/javascripts/jquery.ui.datepicker-sl.js +6 -6
  55. data/vendor/assets/javascripts/jquery.ui.datepicker-sq.js +2 -2
  56. data/vendor/assets/javascripts/jquery.ui.datepicker-sr-SR.js +2 -2
  57. data/vendor/assets/javascripts/jquery.ui.datepicker-sr.js +2 -2
  58. data/vendor/assets/javascripts/jquery.ui.datepicker-sv.js +9 -9
  59. data/vendor/assets/javascripts/jquery.ui.datepicker-th.js +3 -3
  60. data/vendor/assets/javascripts/jquery.ui.datepicker-tj.js +1 -1
  61. data/vendor/assets/javascripts/jquery.ui.datepicker-tr.js +2 -2
  62. data/vendor/assets/javascripts/jquery.ui.datepicker-uk.js +3 -3
  63. data/vendor/assets/javascripts/jquery.ui.datepicker-vi.js +2 -2
  64. data/vendor/assets/javascripts/jquery.ui.datepicker-zh-CN.js +2 -2
  65. data/vendor/assets/javascripts/jquery.ui.datepicker-zh-HK.js +2 -2
  66. data/vendor/assets/javascripts/jquery.ui.datepicker-zh-TW.js +2 -2
  67. data/vendor/assets/javascripts/jquery.ui.datepicker.js +51 -59
  68. data/vendor/assets/javascripts/jquery.ui.dialog.js +402 -409
  69. data/vendor/assets/javascripts/jquery.ui.draggable.js +79 -75
  70. data/vendor/assets/javascripts/jquery.ui.droppable.js +10 -17
  71. data/vendor/assets/javascripts/jquery.ui.effect-blind.js +84 -0
  72. data/vendor/assets/javascripts/jquery.ui.effect-bounce.js +115 -0
  73. data/vendor/assets/javascripts/jquery.ui.effect-clip.js +69 -0
  74. data/vendor/assets/javascripts/jquery.ui.effect-drop.js +67 -0
  75. data/vendor/assets/javascripts/jquery.ui.effect-explode.js +99 -0
  76. data/vendor/assets/javascripts/jquery.ui.effect-fade.js +32 -0
  77. data/vendor/assets/javascripts/jquery.ui.effect-fold.js +78 -0
  78. data/vendor/assets/javascripts/jquery.ui.effect-highlight.js +52 -0
  79. data/vendor/assets/javascripts/jquery.ui.effect-pulsate.js +65 -0
  80. data/vendor/assets/javascripts/jquery.ui.effect-scale.js +320 -0
  81. data/vendor/assets/javascripts/jquery.ui.effect-shake.js +76 -0
  82. data/vendor/assets/javascripts/jquery.ui.effect-slide.js +66 -0
  83. data/vendor/assets/javascripts/jquery.ui.effect-transfer.js +49 -0
  84. data/vendor/assets/javascripts/jquery.ui.effect.all.js +14 -0
  85. data/vendor/assets/javascripts/jquery.ui.effect.js +1276 -0
  86. data/vendor/assets/javascripts/jquery.ui.menu.js +614 -0
  87. data/vendor/assets/javascripts/jquery.ui.mouse.js +22 -20
  88. data/vendor/assets/javascripts/jquery.ui.position.js +367 -158
  89. data/vendor/assets/javascripts/jquery.ui.progressbar.js +10 -14
  90. data/vendor/assets/javascripts/jquery.ui.resizable.js +143 -149
  91. data/vendor/assets/javascripts/jquery.ui.selectable.js +22 -28
  92. data/vendor/assets/javascripts/jquery.ui.slider.js +88 -106
  93. data/vendor/assets/javascripts/jquery.ui.sortable.js +97 -95
  94. data/vendor/assets/javascripts/jquery.ui.spinner.js +482 -0
  95. data/vendor/assets/javascripts/jquery.ui.tabs.js +1189 -580
  96. data/vendor/assets/javascripts/jquery.ui.tooltip.js +402 -0
  97. data/vendor/assets/javascripts/jquery.ui.widget.js +373 -117
  98. data/vendor/assets/stylesheets/jquery.ui.accordion.css.erb +10 -13
  99. data/vendor/assets/stylesheets/jquery.ui.all.css.erb +4 -3
  100. data/vendor/assets/stylesheets/jquery.ui.autocomplete.css.erb +10 -44
  101. data/vendor/assets/stylesheets/jquery.ui.base.css.erb +7 -3
  102. data/vendor/assets/stylesheets/jquery.ui.button.css.erb +6 -4
  103. data/vendor/assets/stylesheets/jquery.ui.core.css.erb +5 -4
  104. data/vendor/assets/stylesheets/jquery.ui.datepicker.css.erb +4 -3
  105. data/vendor/assets/stylesheets/jquery.ui.dialog.css.erb +6 -5
  106. data/vendor/assets/stylesheets/jquery.ui.menu.css.erb +34 -0
  107. data/vendor/assets/stylesheets/jquery.ui.progressbar.css.erb +4 -3
  108. data/vendor/assets/stylesheets/jquery.ui.resizable.css.erb +4 -3
  109. data/vendor/assets/stylesheets/jquery.ui.selectable.css.erb +4 -3
  110. data/vendor/assets/stylesheets/jquery.ui.slider.css.erb +4 -3
  111. data/vendor/assets/stylesheets/jquery.ui.spinner.css.erb +27 -0
  112. data/vendor/assets/stylesheets/jquery.ui.tabs.css.erb +8 -8
  113. data/vendor/assets/stylesheets/jquery.ui.theme.css.erb +8 -7
  114. data/vendor/assets/stylesheets/jquery.ui.tooltip.css.erb +25 -0
  115. metadata +24 -19
  116. data/dependencies.js +0 -31
  117. data/vendor/assets/javascripts/jquery.effects.all.js +0 -14
  118. data/vendor/assets/javascripts/jquery.effects.blind.js +0 -51
  119. data/vendor/assets/javascripts/jquery.effects.bounce.js +0 -80
  120. data/vendor/assets/javascripts/jquery.effects.clip.js +0 -56
  121. data/vendor/assets/javascripts/jquery.effects.core.js +0 -612
  122. data/vendor/assets/javascripts/jquery.effects.drop.js +0 -52
  123. data/vendor/assets/javascripts/jquery.effects.explode.js +0 -81
  124. data/vendor/assets/javascripts/jquery.effects.fade.js +0 -34
  125. data/vendor/assets/javascripts/jquery.effects.fold.js +0 -58
  126. data/vendor/assets/javascripts/jquery.effects.highlight.js +0 -52
  127. data/vendor/assets/javascripts/jquery.effects.pulsate.js +0 -53
  128. data/vendor/assets/javascripts/jquery.effects.scale.js +0 -180
  129. data/vendor/assets/javascripts/jquery.effects.shake.js +0 -59
  130. data/vendor/assets/javascripts/jquery.effects.slide.js +0 -52
  131. data/vendor/assets/javascripts/jquery.effects.transfer.js +0 -47
@@ -0,0 +1,115 @@
1
+ //= require jquery.ui.effect
2
+
3
+ /*!
4
+ * jQuery UI Effects Bounce 1.9.2
5
+ * http://jqueryui.com
6
+ *
7
+ * Copyright 2012 jQuery Foundation and other contributors
8
+ * Released under the MIT license.
9
+ * http://jquery.org/license
10
+ *
11
+ * http://api.jqueryui.com/bounce-effect/
12
+ *
13
+ * Depends:
14
+ * jquery.ui.effect.js
15
+ */
16
+ (function( $, undefined ) {
17
+
18
+ $.effects.effect.bounce = function( o, done ) {
19
+ var el = $( this ),
20
+ props = [ "position", "top", "bottom", "left", "right", "height", "width" ],
21
+
22
+ // defaults:
23
+ mode = $.effects.setMode( el, o.mode || "effect" ),
24
+ hide = mode === "hide",
25
+ show = mode === "show",
26
+ direction = o.direction || "up",
27
+ distance = o.distance,
28
+ times = o.times || 5,
29
+
30
+ // number of internal animations
31
+ anims = times * 2 + ( show || hide ? 1 : 0 ),
32
+ speed = o.duration / anims,
33
+ easing = o.easing,
34
+
35
+ // utility:
36
+ ref = ( direction === "up" || direction === "down" ) ? "top" : "left",
37
+ motion = ( direction === "up" || direction === "left" ),
38
+ i,
39
+ upAnim,
40
+ downAnim,
41
+
42
+ // we will need to re-assemble the queue to stack our animations in place
43
+ queue = el.queue(),
44
+ queuelen = queue.length;
45
+
46
+ // Avoid touching opacity to prevent clearType and PNG issues in IE
47
+ if ( show || hide ) {
48
+ props.push( "opacity" );
49
+ }
50
+
51
+ $.effects.save( el, props );
52
+ el.show();
53
+ $.effects.createWrapper( el ); // Create Wrapper
54
+
55
+ // default distance for the BIGGEST bounce is the outer Distance / 3
56
+ if ( !distance ) {
57
+ distance = el[ ref === "top" ? "outerHeight" : "outerWidth" ]() / 3;
58
+ }
59
+
60
+ if ( show ) {
61
+ downAnim = { opacity: 1 };
62
+ downAnim[ ref ] = 0;
63
+
64
+ // if we are showing, force opacity 0 and set the initial position
65
+ // then do the "first" animation
66
+ el.css( "opacity", 0 )
67
+ .css( ref, motion ? -distance * 2 : distance * 2 )
68
+ .animate( downAnim, speed, easing );
69
+ }
70
+
71
+ // start at the smallest distance if we are hiding
72
+ if ( hide ) {
73
+ distance = distance / Math.pow( 2, times - 1 );
74
+ }
75
+
76
+ downAnim = {};
77
+ downAnim[ ref ] = 0;
78
+ // Bounces up/down/left/right then back to 0 -- times * 2 animations happen here
79
+ for ( i = 0; i < times; i++ ) {
80
+ upAnim = {};
81
+ upAnim[ ref ] = ( motion ? "-=" : "+=" ) + distance;
82
+
83
+ el.animate( upAnim, speed, easing )
84
+ .animate( downAnim, speed, easing );
85
+
86
+ distance = hide ? distance * 2 : distance / 2;
87
+ }
88
+
89
+ // Last Bounce when Hiding
90
+ if ( hide ) {
91
+ upAnim = { opacity: 0 };
92
+ upAnim[ ref ] = ( motion ? "-=" : "+=" ) + distance;
93
+
94
+ el.animate( upAnim, speed, easing );
95
+ }
96
+
97
+ el.queue(function() {
98
+ if ( hide ) {
99
+ el.hide();
100
+ }
101
+ $.effects.restore( el, props );
102
+ $.effects.removeWrapper( el );
103
+ done();
104
+ });
105
+
106
+ // inject all the animations we just queued to be first in line (after "inprogress")
107
+ if ( queuelen > 1) {
108
+ queue.splice.apply( queue,
109
+ [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) );
110
+ }
111
+ el.dequeue();
112
+
113
+ };
114
+
115
+ })(jQuery);
@@ -0,0 +1,69 @@
1
+ //= require jquery.ui.effect
2
+
3
+ /*!
4
+ * jQuery UI Effects Clip 1.9.2
5
+ * http://jqueryui.com
6
+ *
7
+ * Copyright 2012 jQuery Foundation and other contributors
8
+ * Released under the MIT license.
9
+ * http://jquery.org/license
10
+ *
11
+ * http://api.jqueryui.com/clip-effect/
12
+ *
13
+ * Depends:
14
+ * jquery.ui.effect.js
15
+ */
16
+ (function( $, undefined ) {
17
+
18
+ $.effects.effect.clip = function( o, done ) {
19
+ // Create element
20
+ var el = $( this ),
21
+ props = [ "position", "top", "bottom", "left", "right", "height", "width" ],
22
+ mode = $.effects.setMode( el, o.mode || "hide" ),
23
+ show = mode === "show",
24
+ direction = o.direction || "vertical",
25
+ vert = direction === "vertical",
26
+ size = vert ? "height" : "width",
27
+ position = vert ? "top" : "left",
28
+ animation = {},
29
+ wrapper, animate, distance;
30
+
31
+ // Save & Show
32
+ $.effects.save( el, props );
33
+ el.show();
34
+
35
+ // Create Wrapper
36
+ wrapper = $.effects.createWrapper( el ).css({
37
+ overflow: "hidden"
38
+ });
39
+ animate = ( el[0].tagName === "IMG" ) ? wrapper : el;
40
+ distance = animate[ size ]();
41
+
42
+ // Shift
43
+ if ( show ) {
44
+ animate.css( size, 0 );
45
+ animate.css( position, distance / 2 );
46
+ }
47
+
48
+ // Create Animation Object:
49
+ animation[ size ] = show ? distance : 0;
50
+ animation[ position ] = show ? 0 : distance / 2;
51
+
52
+ // Animate
53
+ animate.animate( animation, {
54
+ queue: false,
55
+ duration: o.duration,
56
+ easing: o.easing,
57
+ complete: function() {
58
+ if ( !show ) {
59
+ el.hide();
60
+ }
61
+ $.effects.restore( el, props );
62
+ $.effects.removeWrapper( el );
63
+ done();
64
+ }
65
+ });
66
+
67
+ };
68
+
69
+ })(jQuery);
@@ -0,0 +1,67 @@
1
+ //= require jquery.ui.effect
2
+
3
+ /*!
4
+ * jQuery UI Effects Drop 1.9.2
5
+ * http://jqueryui.com
6
+ *
7
+ * Copyright 2012 jQuery Foundation and other contributors
8
+ * Released under the MIT license.
9
+ * http://jquery.org/license
10
+ *
11
+ * http://api.jqueryui.com/drop-effect/
12
+ *
13
+ * Depends:
14
+ * jquery.ui.effect.js
15
+ */
16
+ (function( $, undefined ) {
17
+
18
+ $.effects.effect.drop = function( o, done ) {
19
+
20
+ var el = $( this ),
21
+ props = [ "position", "top", "bottom", "left", "right", "opacity", "height", "width" ],
22
+ mode = $.effects.setMode( el, o.mode || "hide" ),
23
+ show = mode === "show",
24
+ direction = o.direction || "left",
25
+ ref = ( direction === "up" || direction === "down" ) ? "top" : "left",
26
+ motion = ( direction === "up" || direction === "left" ) ? "pos" : "neg",
27
+ animation = {
28
+ opacity: show ? 1 : 0
29
+ },
30
+ distance;
31
+
32
+ // Adjust
33
+ $.effects.save( el, props );
34
+ el.show();
35
+ $.effects.createWrapper( el );
36
+
37
+ distance = o.distance || el[ ref === "top" ? "outerHeight": "outerWidth" ]( true ) / 2;
38
+
39
+ if ( show ) {
40
+ el
41
+ .css( "opacity", 0 )
42
+ .css( ref, motion === "pos" ? -distance : distance );
43
+ }
44
+
45
+ // Animation
46
+ animation[ ref ] = ( show ?
47
+ ( motion === "pos" ? "+=" : "-=" ) :
48
+ ( motion === "pos" ? "-=" : "+=" ) ) +
49
+ distance;
50
+
51
+ // Animate
52
+ el.animate( animation, {
53
+ queue: false,
54
+ duration: o.duration,
55
+ easing: o.easing,
56
+ complete: function() {
57
+ if ( mode === "hide" ) {
58
+ el.hide();
59
+ }
60
+ $.effects.restore( el, props );
61
+ $.effects.removeWrapper( el );
62
+ done();
63
+ }
64
+ });
65
+ };
66
+
67
+ })(jQuery);
@@ -0,0 +1,99 @@
1
+ //= require jquery.ui.effect
2
+
3
+ /*!
4
+ * jQuery UI Effects Explode 1.9.2
5
+ * http://jqueryui.com
6
+ *
7
+ * Copyright 2012 jQuery Foundation and other contributors
8
+ * Released under the MIT license.
9
+ * http://jquery.org/license
10
+ *
11
+ * http://api.jqueryui.com/explode-effect/
12
+ *
13
+ * Depends:
14
+ * jquery.ui.effect.js
15
+ */
16
+ (function( $, undefined ) {
17
+
18
+ $.effects.effect.explode = function( o, done ) {
19
+
20
+ var rows = o.pieces ? Math.round( Math.sqrt( o.pieces ) ) : 3,
21
+ cells = rows,
22
+ el = $( this ),
23
+ mode = $.effects.setMode( el, o.mode || "hide" ),
24
+ show = mode === "show",
25
+
26
+ // show and then visibility:hidden the element before calculating offset
27
+ offset = el.show().css( "visibility", "hidden" ).offset(),
28
+
29
+ // width and height of a piece
30
+ width = Math.ceil( el.outerWidth() / cells ),
31
+ height = Math.ceil( el.outerHeight() / rows ),
32
+ pieces = [],
33
+
34
+ // loop
35
+ i, j, left, top, mx, my;
36
+
37
+ // children animate complete:
38
+ function childComplete() {
39
+ pieces.push( this );
40
+ if ( pieces.length === rows * cells ) {
41
+ animComplete();
42
+ }
43
+ }
44
+
45
+ // clone the element for each row and cell.
46
+ for( i = 0; i < rows ; i++ ) { // ===>
47
+ top = offset.top + i * height;
48
+ my = i - ( rows - 1 ) / 2 ;
49
+
50
+ for( j = 0; j < cells ; j++ ) { // |||
51
+ left = offset.left + j * width;
52
+ mx = j - ( cells - 1 ) / 2 ;
53
+
54
+ // Create a clone of the now hidden main element that will be absolute positioned
55
+ // within a wrapper div off the -left and -top equal to size of our pieces
56
+ el
57
+ .clone()
58
+ .appendTo( "body" )
59
+ .wrap( "<div></div>" )
60
+ .css({
61
+ position: "absolute",
62
+ visibility: "visible",
63
+ left: -j * width,
64
+ top: -i * height
65
+ })
66
+
67
+ // select the wrapper - make it overflow: hidden and absolute positioned based on
68
+ // where the original was located +left and +top equal to the size of pieces
69
+ .parent()
70
+ .addClass( "ui-effects-explode" )
71
+ .css({
72
+ position: "absolute",
73
+ overflow: "hidden",
74
+ width: width,
75
+ height: height,
76
+ left: left + ( show ? mx * width : 0 ),
77
+ top: top + ( show ? my * height : 0 ),
78
+ opacity: show ? 0 : 1
79
+ }).animate({
80
+ left: left + ( show ? 0 : mx * width ),
81
+ top: top + ( show ? 0 : my * height ),
82
+ opacity: show ? 1 : 0
83
+ }, o.duration || 500, o.easing, childComplete );
84
+ }
85
+ }
86
+
87
+ function animComplete() {
88
+ el.css({
89
+ visibility: "visible"
90
+ });
91
+ $( pieces ).remove();
92
+ if ( !show ) {
93
+ el.hide();
94
+ }
95
+ done();
96
+ }
97
+ };
98
+
99
+ })(jQuery);
@@ -0,0 +1,32 @@
1
+ //= require jquery.ui.effect
2
+
3
+ /*!
4
+ * jQuery UI Effects Fade 1.9.2
5
+ * http://jqueryui.com
6
+ *
7
+ * Copyright 2012 jQuery Foundation and other contributors
8
+ * Released under the MIT license.
9
+ * http://jquery.org/license
10
+ *
11
+ * http://api.jqueryui.com/fade-effect/
12
+ *
13
+ * Depends:
14
+ * jquery.ui.effect.js
15
+ */
16
+ (function( $, undefined ) {
17
+
18
+ $.effects.effect.fade = function( o, done ) {
19
+ var el = $( this ),
20
+ mode = $.effects.setMode( el, o.mode || "toggle" );
21
+
22
+ el.animate({
23
+ opacity: mode
24
+ }, {
25
+ queue: false,
26
+ duration: o.duration,
27
+ easing: o.easing,
28
+ complete: done
29
+ });
30
+ };
31
+
32
+ })( jQuery );
@@ -0,0 +1,78 @@
1
+ //= require jquery.ui.effect
2
+
3
+ /*!
4
+ * jQuery UI Effects Fold 1.9.2
5
+ * http://jqueryui.com
6
+ *
7
+ * Copyright 2012 jQuery Foundation and other contributors
8
+ * Released under the MIT license.
9
+ * http://jquery.org/license
10
+ *
11
+ * http://api.jqueryui.com/fold-effect/
12
+ *
13
+ * Depends:
14
+ * jquery.ui.effect.js
15
+ */
16
+ (function( $, undefined ) {
17
+
18
+ $.effects.effect.fold = function( o, done ) {
19
+
20
+ // Create element
21
+ var el = $( this ),
22
+ props = [ "position", "top", "bottom", "left", "right", "height", "width" ],
23
+ mode = $.effects.setMode( el, o.mode || "hide" ),
24
+ show = mode === "show",
25
+ hide = mode === "hide",
26
+ size = o.size || 15,
27
+ percent = /([0-9]+)%/.exec( size ),
28
+ horizFirst = !!o.horizFirst,
29
+ widthFirst = show !== horizFirst,
30
+ ref = widthFirst ? [ "width", "height" ] : [ "height", "width" ],
31
+ duration = o.duration / 2,
32
+ wrapper, distance,
33
+ animation1 = {},
34
+ animation2 = {};
35
+
36
+ $.effects.save( el, props );
37
+ el.show();
38
+
39
+ // Create Wrapper
40
+ wrapper = $.effects.createWrapper( el ).css({
41
+ overflow: "hidden"
42
+ });
43
+ distance = widthFirst ?
44
+ [ wrapper.width(), wrapper.height() ] :
45
+ [ wrapper.height(), wrapper.width() ];
46
+
47
+ if ( percent ) {
48
+ size = parseInt( percent[ 1 ], 10 ) / 100 * distance[ hide ? 0 : 1 ];
49
+ }
50
+ if ( show ) {
51
+ wrapper.css( horizFirst ? {
52
+ height: 0,
53
+ width: size
54
+ } : {
55
+ height: size,
56
+ width: 0
57
+ });
58
+ }
59
+
60
+ // Animation
61
+ animation1[ ref[ 0 ] ] = show ? distance[ 0 ] : size;
62
+ animation2[ ref[ 1 ] ] = show ? distance[ 1 ] : 0;
63
+
64
+ // Animate
65
+ wrapper
66
+ .animate( animation1, duration, o.easing )
67
+ .animate( animation2, duration, o.easing, function() {
68
+ if ( hide ) {
69
+ el.hide();
70
+ }
71
+ $.effects.restore( el, props );
72
+ $.effects.removeWrapper( el );
73
+ done();
74
+ });
75
+
76
+ };
77
+
78
+ })(jQuery);