jquery-ui-middleman 4.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (153) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +2 -0
  3. data/.gitmodules +3 -0
  4. data/.travis.yml +2 -0
  5. data/Gemfile +3 -0
  6. data/History.md +115 -0
  7. data/License.txt +2 -0
  8. data/README.md +226 -0
  9. data/Rakefile +221 -0
  10. data/VERSIONS.md +27 -0
  11. data/app/assets/images/jquery-ui/animated-overlay.gif +0 -0
  12. data/app/assets/images/jquery-ui/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  13. data/app/assets/images/jquery-ui/ui-bg_flat_75_ffffff_40x100.png +0 -0
  14. data/app/assets/images/jquery-ui/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
  15. data/app/assets/images/jquery-ui/ui-bg_glass_65_ffffff_1x400.png +0 -0
  16. data/app/assets/images/jquery-ui/ui-bg_glass_75_dadada_1x400.png +0 -0
  17. data/app/assets/images/jquery-ui/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
  18. data/app/assets/images/jquery-ui/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  19. data/app/assets/images/jquery-ui/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
  20. data/app/assets/images/jquery-ui/ui-icons_222222_256x240.png +0 -0
  21. data/app/assets/images/jquery-ui/ui-icons_2e83ff_256x240.png +0 -0
  22. data/app/assets/images/jquery-ui/ui-icons_454545_256x240.png +0 -0
  23. data/app/assets/images/jquery-ui/ui-icons_888888_256x240.png +0 -0
  24. data/app/assets/images/jquery-ui/ui-icons_cd0a0a_256x240.png +0 -0
  25. data/app/assets/javascripts/jquery.ui.accordion.js +575 -0
  26. data/app/assets/javascripts/jquery.ui.all.js +34 -0
  27. data/app/assets/javascripts/jquery.ui.autocomplete.js +615 -0
  28. data/app/assets/javascripts/jquery.ui.button.js +422 -0
  29. data/app/assets/javascripts/jquery.ui.core.js +320 -0
  30. data/app/assets/javascripts/jquery.ui.datepicker-af.js +23 -0
  31. data/app/assets/javascripts/jquery.ui.datepicker-ar-DZ.js +23 -0
  32. data/app/assets/javascripts/jquery.ui.datepicker-ar.js +23 -0
  33. data/app/assets/javascripts/jquery.ui.datepicker-az.js +23 -0
  34. data/app/assets/javascripts/jquery.ui.datepicker-be.js +23 -0
  35. data/app/assets/javascripts/jquery.ui.datepicker-bg.js +24 -0
  36. data/app/assets/javascripts/jquery.ui.datepicker-bs.js +23 -0
  37. data/app/assets/javascripts/jquery.ui.datepicker-ca.js +23 -0
  38. data/app/assets/javascripts/jquery.ui.datepicker-cs.js +23 -0
  39. data/app/assets/javascripts/jquery.ui.datepicker-cy-GB.js +23 -0
  40. data/app/assets/javascripts/jquery.ui.datepicker-da.js +23 -0
  41. data/app/assets/javascripts/jquery.ui.datepicker-de.js +23 -0
  42. data/app/assets/javascripts/jquery.ui.datepicker-el.js +23 -0
  43. data/app/assets/javascripts/jquery.ui.datepicker-en-AU.js +23 -0
  44. data/app/assets/javascripts/jquery.ui.datepicker-en-GB.js +23 -0
  45. data/app/assets/javascripts/jquery.ui.datepicker-en-NZ.js +23 -0
  46. data/app/assets/javascripts/jquery.ui.datepicker-eo.js +23 -0
  47. data/app/assets/javascripts/jquery.ui.datepicker-es.js +23 -0
  48. data/app/assets/javascripts/jquery.ui.datepicker-et.js +23 -0
  49. data/app/assets/javascripts/jquery.ui.datepicker-eu.js +23 -0
  50. data/app/assets/javascripts/jquery.ui.datepicker-fa.js +59 -0
  51. data/app/assets/javascripts/jquery.ui.datepicker-fi.js +23 -0
  52. data/app/assets/javascripts/jquery.ui.datepicker-fo.js +23 -0
  53. data/app/assets/javascripts/jquery.ui.datepicker-fr-CA.js +23 -0
  54. data/app/assets/javascripts/jquery.ui.datepicker-fr-CH.js +23 -0
  55. data/app/assets/javascripts/jquery.ui.datepicker-fr.js +25 -0
  56. data/app/assets/javascripts/jquery.ui.datepicker-gl.js +23 -0
  57. data/app/assets/javascripts/jquery.ui.datepicker-he.js +23 -0
  58. data/app/assets/javascripts/jquery.ui.datepicker-hi.js +23 -0
  59. data/app/assets/javascripts/jquery.ui.datepicker-hr.js +23 -0
  60. data/app/assets/javascripts/jquery.ui.datepicker-hu.js +23 -0
  61. data/app/assets/javascripts/jquery.ui.datepicker-hy.js +23 -0
  62. data/app/assets/javascripts/jquery.ui.datepicker-id.js +23 -0
  63. data/app/assets/javascripts/jquery.ui.datepicker-is.js +23 -0
  64. data/app/assets/javascripts/jquery.ui.datepicker-it.js +23 -0
  65. data/app/assets/javascripts/jquery.ui.datepicker-ja.js +23 -0
  66. data/app/assets/javascripts/jquery.ui.datepicker-ka.js +21 -0
  67. data/app/assets/javascripts/jquery.ui.datepicker-kk.js +23 -0
  68. data/app/assets/javascripts/jquery.ui.datepicker-km.js +23 -0
  69. data/app/assets/javascripts/jquery.ui.datepicker-ko.js +23 -0
  70. data/app/assets/javascripts/jquery.ui.datepicker-ky.js +24 -0
  71. data/app/assets/javascripts/jquery.ui.datepicker-lb.js +23 -0
  72. data/app/assets/javascripts/jquery.ui.datepicker-lt.js +23 -0
  73. data/app/assets/javascripts/jquery.ui.datepicker-lv.js +23 -0
  74. data/app/assets/javascripts/jquery.ui.datepicker-mk.js +23 -0
  75. data/app/assets/javascripts/jquery.ui.datepicker-ml.js +23 -0
  76. data/app/assets/javascripts/jquery.ui.datepicker-ms.js +23 -0
  77. data/app/assets/javascripts/jquery.ui.datepicker-nb.js +22 -0
  78. data/app/assets/javascripts/jquery.ui.datepicker-nl-BE.js +23 -0
  79. data/app/assets/javascripts/jquery.ui.datepicker-nl.js +23 -0
  80. data/app/assets/javascripts/jquery.ui.datepicker-nn.js +22 -0
  81. data/app/assets/javascripts/jquery.ui.datepicker-no.js +23 -0
  82. data/app/assets/javascripts/jquery.ui.datepicker-pl.js +23 -0
  83. data/app/assets/javascripts/jquery.ui.datepicker-pt-BR.js +23 -0
  84. data/app/assets/javascripts/jquery.ui.datepicker-pt.js +22 -0
  85. data/app/assets/javascripts/jquery.ui.datepicker-rm.js +21 -0
  86. data/app/assets/javascripts/jquery.ui.datepicker-ro.js +26 -0
  87. data/app/assets/javascripts/jquery.ui.datepicker-ru.js +23 -0
  88. data/app/assets/javascripts/jquery.ui.datepicker-sk.js +23 -0
  89. data/app/assets/javascripts/jquery.ui.datepicker-sl.js +24 -0
  90. data/app/assets/javascripts/jquery.ui.datepicker-sq.js +23 -0
  91. data/app/assets/javascripts/jquery.ui.datepicker-sr-SR.js +23 -0
  92. data/app/assets/javascripts/jquery.ui.datepicker-sr.js +23 -0
  93. data/app/assets/javascripts/jquery.ui.datepicker-sv.js +23 -0
  94. data/app/assets/javascripts/jquery.ui.datepicker-ta.js +23 -0
  95. data/app/assets/javascripts/jquery.ui.datepicker-th.js +23 -0
  96. data/app/assets/javascripts/jquery.ui.datepicker-tj.js +23 -0
  97. data/app/assets/javascripts/jquery.ui.datepicker-tr.js +23 -0
  98. data/app/assets/javascripts/jquery.ui.datepicker-uk.js +24 -0
  99. data/app/assets/javascripts/jquery.ui.datepicker-vi.js +23 -0
  100. data/app/assets/javascripts/jquery.ui.datepicker-zh-CN.js +23 -0
  101. data/app/assets/javascripts/jquery.ui.datepicker-zh-HK.js +23 -0
  102. data/app/assets/javascripts/jquery.ui.datepicker-zh-TW.js +23 -0
  103. data/app/assets/javascripts/jquery.ui.datepicker.js +2040 -0
  104. data/app/assets/javascripts/jquery.ui.dialog.js +815 -0
  105. data/app/assets/javascripts/jquery.ui.draggable.js +962 -0
  106. data/app/assets/javascripts/jquery.ui.droppable.js +377 -0
  107. data/app/assets/javascripts/jquery.ui.effect-blind.js +84 -0
  108. data/app/assets/javascripts/jquery.ui.effect-bounce.js +115 -0
  109. data/app/assets/javascripts/jquery.ui.effect-clip.js +69 -0
  110. data/app/assets/javascripts/jquery.ui.effect-drop.js +67 -0
  111. data/app/assets/javascripts/jquery.ui.effect-explode.js +99 -0
  112. data/app/assets/javascripts/jquery.ui.effect-fade.js +32 -0
  113. data/app/assets/javascripts/jquery.ui.effect-fold.js +78 -0
  114. data/app/assets/javascripts/jquery.ui.effect-highlight.js +52 -0
  115. data/app/assets/javascripts/jquery.ui.effect-pulsate.js +65 -0
  116. data/app/assets/javascripts/jquery.ui.effect-scale.js +320 -0
  117. data/app/assets/javascripts/jquery.ui.effect-shake.js +76 -0
  118. data/app/assets/javascripts/jquery.ui.effect-slide.js +66 -0
  119. data/app/assets/javascripts/jquery.ui.effect-transfer.js +49 -0
  120. data/app/assets/javascripts/jquery.ui.effect.all.js +14 -0
  121. data/app/assets/javascripts/jquery.ui.effect.js +1289 -0
  122. data/app/assets/javascripts/jquery.ui.menu.js +625 -0
  123. data/app/assets/javascripts/jquery.ui.mouse.js +172 -0
  124. data/app/assets/javascripts/jquery.ui.position.js +497 -0
  125. data/app/assets/javascripts/jquery.ui.progressbar.js +148 -0
  126. data/app/assets/javascripts/jquery.ui.resizable.js +972 -0
  127. data/app/assets/javascripts/jquery.ui.selectable.js +281 -0
  128. data/app/assets/javascripts/jquery.ui.slider.js +676 -0
  129. data/app/assets/javascripts/jquery.ui.sortable.js +1289 -0
  130. data/app/assets/javascripts/jquery.ui.spinner.js +497 -0
  131. data/app/assets/javascripts/jquery.ui.tabs.js +849 -0
  132. data/app/assets/javascripts/jquery.ui.tooltip.js +406 -0
  133. data/app/assets/javascripts/jquery.ui.widget.js +521 -0
  134. data/app/assets/stylesheets/jquery.ui.accordion.css.erb +42 -0
  135. data/app/assets/stylesheets/jquery.ui.all.css.erb +14 -0
  136. data/app/assets/stylesheets/jquery.ui.autocomplete.css.erb +21 -0
  137. data/app/assets/stylesheets/jquery.ui.base.css.erb +27 -0
  138. data/app/assets/stylesheets/jquery.ui.button.css.erb +118 -0
  139. data/app/assets/stylesheets/jquery.ui.core.css.erb +93 -0
  140. data/app/assets/stylesheets/jquery.ui.datepicker.css.erb +182 -0
  141. data/app/assets/stylesheets/jquery.ui.dialog.css.erb +75 -0
  142. data/app/assets/stylesheets/jquery.ui.menu.css.erb +83 -0
  143. data/app/assets/stylesheets/jquery.ui.progressbar.css.erb +32 -0
  144. data/app/assets/stylesheets/jquery.ui.resizable.css.erb +82 -0
  145. data/app/assets/stylesheets/jquery.ui.selectable.css.erb +19 -0
  146. data/app/assets/stylesheets/jquery.ui.slider.css.erb +77 -0
  147. data/app/assets/stylesheets/jquery.ui.spinner.css.erb +70 -0
  148. data/app/assets/stylesheets/jquery.ui.tabs.css.erb +56 -0
  149. data/app/assets/stylesheets/jquery.ui.theme.css.erb +409 -0
  150. data/app/assets/stylesheets/jquery.ui.tooltip.css.erb +23 -0
  151. data/lib/jquery-ui-middleman.rb +1 -0
  152. data/lib/jquery/ui/version.rb +6 -0
  153. metadata +209 -0
@@ -0,0 +1,377 @@
1
+ //= require jquery.ui.core
2
+ //= require jquery.ui.widget
3
+ //= require jquery.ui.mouse
4
+ //= require jquery.ui.draggable
5
+
6
+ /*!
7
+ * jQuery UI Droppable 1.10.3
8
+ * http://jqueryui.com
9
+ *
10
+ * Copyright 2013 jQuery Foundation and other contributors
11
+ * Released under the MIT license.
12
+ * http://jquery.org/license
13
+ *
14
+ * http://api.jqueryui.com/droppable/
15
+ *
16
+ * Depends:
17
+ * jquery.ui.core.js
18
+ * jquery.ui.widget.js
19
+ * jquery.ui.mouse.js
20
+ * jquery.ui.draggable.js
21
+ */
22
+ (function( $, undefined ) {
23
+
24
+ function isOverAxis( x, reference, size ) {
25
+ return ( x > reference ) && ( x < ( reference + size ) );
26
+ }
27
+
28
+ $.widget("ui.droppable", {
29
+ version: "1.10.3",
30
+ widgetEventPrefix: "drop",
31
+ options: {
32
+ accept: "*",
33
+ activeClass: false,
34
+ addClasses: true,
35
+ greedy: false,
36
+ hoverClass: false,
37
+ scope: "default",
38
+ tolerance: "intersect",
39
+
40
+ // callbacks
41
+ activate: null,
42
+ deactivate: null,
43
+ drop: null,
44
+ out: null,
45
+ over: null
46
+ },
47
+ _create: function() {
48
+
49
+ var o = this.options,
50
+ accept = o.accept;
51
+
52
+ this.isover = false;
53
+ this.isout = true;
54
+
55
+ this.accept = $.isFunction(accept) ? accept : function(d) {
56
+ return d.is(accept);
57
+ };
58
+
59
+ //Store the droppable's proportions
60
+ this.proportions = { width: this.element[0].offsetWidth, height: this.element[0].offsetHeight };
61
+
62
+ // Add the reference and positions to the manager
63
+ $.ui.ddmanager.droppables[o.scope] = $.ui.ddmanager.droppables[o.scope] || [];
64
+ $.ui.ddmanager.droppables[o.scope].push(this);
65
+
66
+ (o.addClasses && this.element.addClass("ui-droppable"));
67
+
68
+ },
69
+
70
+ _destroy: function() {
71
+ var i = 0,
72
+ drop = $.ui.ddmanager.droppables[this.options.scope];
73
+
74
+ for ( ; i < drop.length; i++ ) {
75
+ if ( drop[i] === this ) {
76
+ drop.splice(i, 1);
77
+ }
78
+ }
79
+
80
+ this.element.removeClass("ui-droppable ui-droppable-disabled");
81
+ },
82
+
83
+ _setOption: function(key, value) {
84
+
85
+ if(key === "accept") {
86
+ this.accept = $.isFunction(value) ? value : function(d) {
87
+ return d.is(value);
88
+ };
89
+ }
90
+ $.Widget.prototype._setOption.apply(this, arguments);
91
+ },
92
+
93
+ _activate: function(event) {
94
+ var draggable = $.ui.ddmanager.current;
95
+ if(this.options.activeClass) {
96
+ this.element.addClass(this.options.activeClass);
97
+ }
98
+ if(draggable){
99
+ this._trigger("activate", event, this.ui(draggable));
100
+ }
101
+ },
102
+
103
+ _deactivate: function(event) {
104
+ var draggable = $.ui.ddmanager.current;
105
+ if(this.options.activeClass) {
106
+ this.element.removeClass(this.options.activeClass);
107
+ }
108
+ if(draggable){
109
+ this._trigger("deactivate", event, this.ui(draggable));
110
+ }
111
+ },
112
+
113
+ _over: function(event) {
114
+
115
+ var draggable = $.ui.ddmanager.current;
116
+
117
+ // Bail if draggable and droppable are same element
118
+ if (!draggable || (draggable.currentItem || draggable.element)[0] === this.element[0]) {
119
+ return;
120
+ }
121
+
122
+ if (this.accept.call(this.element[0],(draggable.currentItem || draggable.element))) {
123
+ if(this.options.hoverClass) {
124
+ this.element.addClass(this.options.hoverClass);
125
+ }
126
+ this._trigger("over", event, this.ui(draggable));
127
+ }
128
+
129
+ },
130
+
131
+ _out: function(event) {
132
+
133
+ var draggable = $.ui.ddmanager.current;
134
+
135
+ // Bail if draggable and droppable are same element
136
+ if (!draggable || (draggable.currentItem || draggable.element)[0] === this.element[0]) {
137
+ return;
138
+ }
139
+
140
+ if (this.accept.call(this.element[0],(draggable.currentItem || draggable.element))) {
141
+ if(this.options.hoverClass) {
142
+ this.element.removeClass(this.options.hoverClass);
143
+ }
144
+ this._trigger("out", event, this.ui(draggable));
145
+ }
146
+
147
+ },
148
+
149
+ _drop: function(event,custom) {
150
+
151
+ var draggable = custom || $.ui.ddmanager.current,
152
+ childrenIntersection = false;
153
+
154
+ // Bail if draggable and droppable are same element
155
+ if (!draggable || (draggable.currentItem || draggable.element)[0] === this.element[0]) {
156
+ return false;
157
+ }
158
+
159
+ this.element.find(":data(ui-droppable)").not(".ui-draggable-dragging").each(function() {
160
+ var inst = $.data(this, "ui-droppable");
161
+ if(
162
+ inst.options.greedy &&
163
+ !inst.options.disabled &&
164
+ inst.options.scope === draggable.options.scope &&
165
+ inst.accept.call(inst.element[0], (draggable.currentItem || draggable.element)) &&
166
+ $.ui.intersect(draggable, $.extend(inst, { offset: inst.element.offset() }), inst.options.tolerance)
167
+ ) { childrenIntersection = true; return false; }
168
+ });
169
+ if(childrenIntersection) {
170
+ return false;
171
+ }
172
+
173
+ if(this.accept.call(this.element[0],(draggable.currentItem || draggable.element))) {
174
+ if(this.options.activeClass) {
175
+ this.element.removeClass(this.options.activeClass);
176
+ }
177
+ if(this.options.hoverClass) {
178
+ this.element.removeClass(this.options.hoverClass);
179
+ }
180
+ this._trigger("drop", event, this.ui(draggable));
181
+ return this.element;
182
+ }
183
+
184
+ return false;
185
+
186
+ },
187
+
188
+ ui: function(c) {
189
+ return {
190
+ draggable: (c.currentItem || c.element),
191
+ helper: c.helper,
192
+ position: c.position,
193
+ offset: c.positionAbs
194
+ };
195
+ }
196
+
197
+ });
198
+
199
+ $.ui.intersect = function(draggable, droppable, toleranceMode) {
200
+
201
+ if (!droppable.offset) {
202
+ return false;
203
+ }
204
+
205
+ var draggableLeft, draggableTop,
206
+ x1 = (draggable.positionAbs || draggable.position.absolute).left, x2 = x1 + draggable.helperProportions.width,
207
+ y1 = (draggable.positionAbs || draggable.position.absolute).top, y2 = y1 + draggable.helperProportions.height,
208
+ l = droppable.offset.left, r = l + droppable.proportions.width,
209
+ t = droppable.offset.top, b = t + droppable.proportions.height;
210
+
211
+ switch (toleranceMode) {
212
+ case "fit":
213
+ return (l <= x1 && x2 <= r && t <= y1 && y2 <= b);
214
+ case "intersect":
215
+ return (l < x1 + (draggable.helperProportions.width / 2) && // Right Half
216
+ x2 - (draggable.helperProportions.width / 2) < r && // Left Half
217
+ t < y1 + (draggable.helperProportions.height / 2) && // Bottom Half
218
+ y2 - (draggable.helperProportions.height / 2) < b ); // Top Half
219
+ case "pointer":
220
+ draggableLeft = ((draggable.positionAbs || draggable.position.absolute).left + (draggable.clickOffset || draggable.offset.click).left);
221
+ draggableTop = ((draggable.positionAbs || draggable.position.absolute).top + (draggable.clickOffset || draggable.offset.click).top);
222
+ return isOverAxis( draggableTop, t, droppable.proportions.height ) && isOverAxis( draggableLeft, l, droppable.proportions.width );
223
+ case "touch":
224
+ return (
225
+ (y1 >= t && y1 <= b) || // Top edge touching
226
+ (y2 >= t && y2 <= b) || // Bottom edge touching
227
+ (y1 < t && y2 > b) // Surrounded vertically
228
+ ) && (
229
+ (x1 >= l && x1 <= r) || // Left edge touching
230
+ (x2 >= l && x2 <= r) || // Right edge touching
231
+ (x1 < l && x2 > r) // Surrounded horizontally
232
+ );
233
+ default:
234
+ return false;
235
+ }
236
+
237
+ };
238
+
239
+ /*
240
+ This manager tracks offsets of draggables and droppables
241
+ */
242
+ $.ui.ddmanager = {
243
+ current: null,
244
+ droppables: { "default": [] },
245
+ prepareOffsets: function(t, event) {
246
+
247
+ var i, j,
248
+ m = $.ui.ddmanager.droppables[t.options.scope] || [],
249
+ type = event ? event.type : null, // workaround for #2317
250
+ list = (t.currentItem || t.element).find(":data(ui-droppable)").addBack();
251
+
252
+ droppablesLoop: for (i = 0; i < m.length; i++) {
253
+
254
+ //No disabled and non-accepted
255
+ if(m[i].options.disabled || (t && !m[i].accept.call(m[i].element[0],(t.currentItem || t.element)))) {
256
+ continue;
257
+ }
258
+
259
+ // Filter out elements in the current dragged item
260
+ for (j=0; j < list.length; j++) {
261
+ if(list[j] === m[i].element[0]) {
262
+ m[i].proportions.height = 0;
263
+ continue droppablesLoop;
264
+ }
265
+ }
266
+
267
+ m[i].visible = m[i].element.css("display") !== "none";
268
+ if(!m[i].visible) {
269
+ continue;
270
+ }
271
+
272
+ //Activate the droppable if used directly from draggables
273
+ if(type === "mousedown") {
274
+ m[i]._activate.call(m[i], event);
275
+ }
276
+
277
+ m[i].offset = m[i].element.offset();
278
+ m[i].proportions = { width: m[i].element[0].offsetWidth, height: m[i].element[0].offsetHeight };
279
+
280
+ }
281
+
282
+ },
283
+ drop: function(draggable, event) {
284
+
285
+ var dropped = false;
286
+ // Create a copy of the droppables in case the list changes during the drop (#9116)
287
+ $.each(($.ui.ddmanager.droppables[draggable.options.scope] || []).slice(), function() {
288
+
289
+ if(!this.options) {
290
+ return;
291
+ }
292
+ if (!this.options.disabled && this.visible && $.ui.intersect(draggable, this, this.options.tolerance)) {
293
+ dropped = this._drop.call(this, event) || dropped;
294
+ }
295
+
296
+ if (!this.options.disabled && this.visible && this.accept.call(this.element[0],(draggable.currentItem || draggable.element))) {
297
+ this.isout = true;
298
+ this.isover = false;
299
+ this._deactivate.call(this, event);
300
+ }
301
+
302
+ });
303
+ return dropped;
304
+
305
+ },
306
+ dragStart: function( draggable, event ) {
307
+ //Listen for scrolling so that if the dragging causes scrolling the position of the droppables can be recalculated (see #5003)
308
+ draggable.element.parentsUntil( "body" ).bind( "scroll.droppable", function() {
309
+ if( !draggable.options.refreshPositions ) {
310
+ $.ui.ddmanager.prepareOffsets( draggable, event );
311
+ }
312
+ });
313
+ },
314
+ drag: function(draggable, event) {
315
+
316
+ //If you have a highly dynamic page, you might try this option. It renders positions every time you move the mouse.
317
+ if(draggable.options.refreshPositions) {
318
+ $.ui.ddmanager.prepareOffsets(draggable, event);
319
+ }
320
+
321
+ //Run through all droppables and check their positions based on specific tolerance options
322
+ $.each($.ui.ddmanager.droppables[draggable.options.scope] || [], function() {
323
+
324
+ if(this.options.disabled || this.greedyChild || !this.visible) {
325
+ return;
326
+ }
327
+
328
+ var parentInstance, scope, parent,
329
+ intersects = $.ui.intersect(draggable, this, this.options.tolerance),
330
+ c = !intersects && this.isover ? "isout" : (intersects && !this.isover ? "isover" : null);
331
+ if(!c) {
332
+ return;
333
+ }
334
+
335
+ if (this.options.greedy) {
336
+ // find droppable parents with same scope
337
+ scope = this.options.scope;
338
+ parent = this.element.parents(":data(ui-droppable)").filter(function () {
339
+ return $.data(this, "ui-droppable").options.scope === scope;
340
+ });
341
+
342
+ if (parent.length) {
343
+ parentInstance = $.data(parent[0], "ui-droppable");
344
+ parentInstance.greedyChild = (c === "isover");
345
+ }
346
+ }
347
+
348
+ // we just moved into a greedy child
349
+ if (parentInstance && c === "isover") {
350
+ parentInstance.isover = false;
351
+ parentInstance.isout = true;
352
+ parentInstance._out.call(parentInstance, event);
353
+ }
354
+
355
+ this[c] = true;
356
+ this[c === "isout" ? "isover" : "isout"] = false;
357
+ this[c === "isover" ? "_over" : "_out"].call(this, event);
358
+
359
+ // we just moved out of a greedy child
360
+ if (parentInstance && c === "isout") {
361
+ parentInstance.isout = false;
362
+ parentInstance.isover = true;
363
+ parentInstance._over.call(parentInstance, event);
364
+ }
365
+ });
366
+
367
+ },
368
+ dragStop: function( draggable, event ) {
369
+ draggable.element.parentsUntil( "body" ).unbind( "scroll.droppable" );
370
+ //Call prepareOffsets one final time since IE does not fire return scroll events when overflow was caused by drag (see #5003)
371
+ if( !draggable.options.refreshPositions ) {
372
+ $.ui.ddmanager.prepareOffsets( draggable, event );
373
+ }
374
+ }
375
+ };
376
+
377
+ })(jQuery);
@@ -0,0 +1,84 @@
1
+ //= require jquery.ui.effect
2
+
3
+ /*!
4
+ * jQuery UI Effects Blind 1.10.3
5
+ * http://jqueryui.com
6
+ *
7
+ * Copyright 2013 jQuery Foundation and other contributors
8
+ * Released under the MIT license.
9
+ * http://jquery.org/license
10
+ *
11
+ * http://api.jqueryui.com/blind-effect/
12
+ *
13
+ * Depends:
14
+ * jquery.ui.effect.js
15
+ */
16
+ (function( $, undefined ) {
17
+
18
+ var rvertical = /up|down|vertical/,
19
+ rpositivemotion = /up|left|vertical|horizontal/;
20
+
21
+ $.effects.effect.blind = function( o, done ) {
22
+ // Create element
23
+ var el = $( this ),
24
+ props = [ "position", "top", "bottom", "left", "right", "height", "width" ],
25
+ mode = $.effects.setMode( el, o.mode || "hide" ),
26
+ direction = o.direction || "up",
27
+ vertical = rvertical.test( direction ),
28
+ ref = vertical ? "height" : "width",
29
+ ref2 = vertical ? "top" : "left",
30
+ motion = rpositivemotion.test( direction ),
31
+ animation = {},
32
+ show = mode === "show",
33
+ wrapper, distance, margin;
34
+
35
+ // if already wrapped, the wrapper's properties are my property. #6245
36
+ if ( el.parent().is( ".ui-effects-wrapper" ) ) {
37
+ $.effects.save( el.parent(), props );
38
+ } else {
39
+ $.effects.save( el, props );
40
+ }
41
+ el.show();
42
+ wrapper = $.effects.createWrapper( el ).css({
43
+ overflow: "hidden"
44
+ });
45
+
46
+ distance = wrapper[ ref ]();
47
+ margin = parseFloat( wrapper.css( ref2 ) ) || 0;
48
+
49
+ animation[ ref ] = show ? distance : 0;
50
+ if ( !motion ) {
51
+ el
52
+ .css( vertical ? "bottom" : "right", 0 )
53
+ .css( vertical ? "top" : "left", "auto" )
54
+ .css({ position: "absolute" });
55
+
56
+ animation[ ref2 ] = show ? margin : distance + margin;
57
+ }
58
+
59
+ // start at 0 if we are showing
60
+ if ( show ) {
61
+ wrapper.css( ref, 0 );
62
+ if ( ! motion ) {
63
+ wrapper.css( ref2, margin + distance );
64
+ }
65
+ }
66
+
67
+ // Animate
68
+ wrapper.animate( animation, {
69
+ duration: o.duration,
70
+ easing: o.easing,
71
+ queue: false,
72
+ complete: function() {
73
+ if ( mode === "hide" ) {
74
+ el.hide();
75
+ }
76
+ $.effects.restore( el, props );
77
+ $.effects.removeWrapper( el );
78
+ done();
79
+ }
80
+ });
81
+
82
+ };
83
+
84
+ })(jQuery);