spiderfw 0.6.27 → 0.6.28

Sign up to get free protection for your applications and to get access to all the features.
Files changed (179) hide show
  1. data/CHANGELOG +4 -0
  2. data/VERSION +1 -1
  3. data/apps/core/admin/admin.rb +6 -2
  4. data/apps/core/admin/controllers/admin_controller.rb +10 -3
  5. data/apps/core/admin/controllers/app_admin_controller.rb +15 -0
  6. data/apps/core/admin/public/css/sass/admin.css +29 -33
  7. data/apps/core/admin/public/css/sass/grid.css +14 -0
  8. data/apps/core/admin/public/sass/admin.scss +3 -2
  9. data/apps/core/admin/views/admin.layout.shtml +1 -0
  10. data/apps/core/auth/controllers/mixins/auth_helper.rb +15 -5
  11. data/apps/core/components/assets.rb +60 -41
  12. data/apps/core/components/public/js/jquery/jquery-1.8.3.js +9472 -0
  13. data/apps/core/components/public/js/jquery/jquery-ui-1.8.11/ui/jquery.ui.core.js +1 -1
  14. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/button_bg.png +0 -0
  15. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/datepicker.gif +0 -0
  16. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/icon_sprite.png +0 -0
  17. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/progress_bar.gif +0 -0
  18. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/slider_h_bg.gif +0 -0
  19. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/slider_handles.png +0 -0
  20. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/slider_v_bg.gif +0 -0
  21. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/tab_bg.gif +0 -0
  22. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/the_gradient.gif +0 -0
  23. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-anim_basic_16x16.gif +0 -0
  24. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_diagonals-thick_18_b81900_40x40.png +0 -0
  25. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_diagonals-thick_20_666666_40x40.png +0 -0
  26. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_flat_10_000000_40x100.png +0 -0
  27. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_glass_100_f6f6f6_1x400.png +0 -0
  28. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_glass_100_fdf5ce_1x400.png +0 -0
  29. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  30. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_gloss-wave_35_f6a828_500x100.png +0 -0
  31. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_highlight-soft_100_eeeeee_1x100.png +0 -0
  32. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-bg_highlight-soft_75_ffe45c_1x100.png +0 -0
  33. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-icons_222222_256x240.png +0 -0
  34. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-icons_228ef1_256x240.png +0 -0
  35. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-icons_ef8c08_256x240.png +0 -0
  36. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-icons_ffd27a_256x240.png +0 -0
  37. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/images/ui-icons_ffffff_256x240.png +0 -0
  38. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/css/Aristo/jquery-ui.custom.css +528 -0
  39. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-af.js +23 -0
  40. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ar-DZ.js +23 -0
  41. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ar.js +23 -0
  42. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-az.js +23 -0
  43. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-be.js +23 -0
  44. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-bg.js +24 -0
  45. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-bs.js +23 -0
  46. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ca.js +23 -0
  47. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-cs.js +23 -0
  48. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-cy-GB.js +23 -0
  49. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-da.js +23 -0
  50. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-de.js +23 -0
  51. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-el.js +23 -0
  52. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-en-AU.js +23 -0
  53. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-en-GB.js +23 -0
  54. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-en-NZ.js +23 -0
  55. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-eo.js +23 -0
  56. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-es.js +23 -0
  57. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-et.js +23 -0
  58. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-eu.js +23 -0
  59. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-fa.js +59 -0
  60. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-fi.js +23 -0
  61. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-fo.js +23 -0
  62. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-fr-CA.js +23 -0
  63. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-fr-CH.js +23 -0
  64. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-fr.js +25 -0
  65. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-gl.js +23 -0
  66. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-he.js +23 -0
  67. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-hi.js +23 -0
  68. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-hr.js +23 -0
  69. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-hu.js +23 -0
  70. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-hy.js +23 -0
  71. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-id.js +23 -0
  72. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-is.js +23 -0
  73. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-it.js +23 -0
  74. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ja.js +23 -0
  75. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ka.js +21 -0
  76. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-kk.js +23 -0
  77. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-km.js +23 -0
  78. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ko.js +23 -0
  79. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ky.js +24 -0
  80. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-lb.js +23 -0
  81. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-lt.js +23 -0
  82. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-lv.js +23 -0
  83. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-mk.js +23 -0
  84. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ml.js +23 -0
  85. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ms.js +23 -0
  86. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-nb.js +22 -0
  87. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-nl-BE.js +23 -0
  88. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-nl.js +23 -0
  89. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-nn.js +22 -0
  90. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-no.js +23 -0
  91. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-pl.js +23 -0
  92. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-pt-BR.js +23 -0
  93. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-pt.js +22 -0
  94. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-rm.js +21 -0
  95. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ro.js +26 -0
  96. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ru.js +23 -0
  97. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-sk.js +23 -0
  98. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-sl.js +24 -0
  99. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-sq.js +23 -0
  100. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-sr-SR.js +23 -0
  101. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-sr.js +23 -0
  102. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-sv.js +23 -0
  103. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-ta.js +23 -0
  104. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-th.js +23 -0
  105. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-tj.js +23 -0
  106. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-tr.js +23 -0
  107. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-uk.js +24 -0
  108. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-vi.js +23 -0
  109. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-zh-CN.js +23 -0
  110. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-zh-HK.js +23 -0
  111. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/i18n/jquery.ui.datepicker-zh-TW.js +23 -0
  112. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.accordion.js +571 -0
  113. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.autocomplete.js +614 -0
  114. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.button.js +419 -0
  115. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.core.js +324 -0
  116. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.datepicker.js +2044 -0
  117. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.dialog.js +767 -0
  118. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.draggable.js +941 -0
  119. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.droppable.js +364 -0
  120. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-blind.js +82 -0
  121. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-bounce.js +113 -0
  122. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-clip.js +67 -0
  123. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-drop.js +65 -0
  124. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-explode.js +97 -0
  125. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-fade.js +30 -0
  126. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-fold.js +76 -0
  127. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-highlight.js +50 -0
  128. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-pulsate.js +63 -0
  129. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-scale.js +318 -0
  130. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-shake.js +74 -0
  131. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-slide.js +64 -0
  132. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect-transfer.js +47 -0
  133. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.effect.js +1259 -0
  134. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.menu.js +621 -0
  135. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.mouse.js +169 -0
  136. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.position.js +497 -0
  137. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.progressbar.js +145 -0
  138. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.resizable.js +963 -0
  139. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.selectable.js +269 -0
  140. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.slider.js +641 -0
  141. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.sortable.js +1236 -0
  142. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.spinner.js +492 -0
  143. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.tabs.js +846 -0
  144. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.tooltip.js +400 -0
  145. data/apps/core/components/public/js/jquery/jquery-ui-1.9.2/ui/jquery.ui.widget.js +521 -0
  146. data/apps/core/components/public/js/jquery/plugins/bsmselect/js/jquery.bsmselect.js +3 -1
  147. data/apps/core/components/public/js/plugins/sortable.js +5 -5
  148. data/apps/core/components/widgets/month_calendar/month_calendar.shtml +1 -1
  149. data/apps/core/components/widgets/table/table.rb +18 -5
  150. data/apps/core/forms/public/date_time.js +3 -0
  151. data/apps/core/forms/widgets/form/form.rb +1 -1
  152. data/apps/core/forms/widgets/inputs/date_time/date_time.rb +5 -0
  153. data/apps/core/forms/widgets/inputs/file_input/file_input.rb +1 -1
  154. data/apps/core/forms/widgets/inputs/select/select.rb +11 -16
  155. data/apps/messenger/config/options.rb +5 -5
  156. data/apps/messenger/controllers/messenger_admin_controller.rb +1 -1
  157. data/apps/messenger/controllers/messenger_controller.rb +1 -1
  158. data/apps/messenger/lib/backends/mobyt.rb +1 -1
  159. data/apps/messenger/messenger.rb +4 -2
  160. data/apps/messenger/views/admin/index.shtml +1 -1
  161. data/lib/spiderfw/controller/dispatcher.rb +5 -5
  162. data/lib/spiderfw/controller/mixins/visual.rb +10 -8
  163. data/lib/spiderfw/http/http.rb +1 -1
  164. data/lib/spiderfw/model/base_model.rb +2 -2
  165. data/lib/spiderfw/model/mappers/db_mapper.rb +4 -2
  166. data/lib/spiderfw/model/mixins/tree.rb +4 -5
  167. data/lib/spiderfw/model/model.rb +2 -1
  168. data/lib/spiderfw/model/storage/db/adapters/mysql.rb +18 -20
  169. data/lib/spiderfw/model/storage/db/adapters/oracle.rb +1 -1
  170. data/lib/spiderfw/spider.rb +5 -1
  171. data/lib/spiderfw/templates/blocks/layout_assets.rb +5 -2
  172. data/lib/spiderfw/templates/layout.rb +7 -3
  173. data/lib/spiderfw/templates/template.rb +8 -1
  174. data/lib/spiderfw/utils/monkey/date_time.rb +7 -5
  175. data/lib/spiderfw/utils/monkey/module.rb +12 -0
  176. metadata +373 -157
  177. data/lib/spiderfw/model/storage/db/connectors/mysql.rb +0 -16
  178. data/lib/spiderfw/model/storage/db/connectors/mysql2.rb +0 -9
  179. /data/apps/core/admin/public/img/{icons-s845a69dd9f.png → icons-s8b18557db6.png} +0 -0
@@ -0,0 +1,97 @@
1
+ /*!
2
+ * jQuery UI Effects Explode @VERSION
3
+ * http://jqueryui.com
4
+ *
5
+ * Copyright 2012 jQuery Foundation and other contributors
6
+ * Released under the MIT license.
7
+ * http://jquery.org/license
8
+ *
9
+ * http://api.jqueryui.com/explode-effect/
10
+ *
11
+ * Depends:
12
+ * jquery.ui.effect.js
13
+ */
14
+ (function( $, undefined ) {
15
+
16
+ $.effects.effect.explode = function( o, done ) {
17
+
18
+ var rows = o.pieces ? Math.round( Math.sqrt( o.pieces ) ) : 3,
19
+ cells = rows,
20
+ el = $( this ),
21
+ mode = $.effects.setMode( el, o.mode || "hide" ),
22
+ show = mode === "show",
23
+
24
+ // show and then visibility:hidden the element before calculating offset
25
+ offset = el.show().css( "visibility", "hidden" ).offset(),
26
+
27
+ // width and height of a piece
28
+ width = Math.ceil( el.outerWidth() / cells ),
29
+ height = Math.ceil( el.outerHeight() / rows ),
30
+ pieces = [],
31
+
32
+ // loop
33
+ i, j, left, top, mx, my;
34
+
35
+ // children animate complete:
36
+ function childComplete() {
37
+ pieces.push( this );
38
+ if ( pieces.length === rows * cells ) {
39
+ animComplete();
40
+ }
41
+ }
42
+
43
+ // clone the element for each row and cell.
44
+ for( i = 0; i < rows ; i++ ) { // ===>
45
+ top = offset.top + i * height;
46
+ my = i - ( rows - 1 ) / 2 ;
47
+
48
+ for( j = 0; j < cells ; j++ ) { // |||
49
+ left = offset.left + j * width;
50
+ mx = j - ( cells - 1 ) / 2 ;
51
+
52
+ // Create a clone of the now hidden main element that will be absolute positioned
53
+ // within a wrapper div off the -left and -top equal to size of our pieces
54
+ el
55
+ .clone()
56
+ .appendTo( "body" )
57
+ .wrap( "<div></div>" )
58
+ .css({
59
+ position: "absolute",
60
+ visibility: "visible",
61
+ left: -j * width,
62
+ top: -i * height
63
+ })
64
+
65
+ // select the wrapper - make it overflow: hidden and absolute positioned based on
66
+ // where the original was located +left and +top equal to the size of pieces
67
+ .parent()
68
+ .addClass( "ui-effects-explode" )
69
+ .css({
70
+ position: "absolute",
71
+ overflow: "hidden",
72
+ width: width,
73
+ height: height,
74
+ left: left + ( show ? mx * width : 0 ),
75
+ top: top + ( show ? my * height : 0 ),
76
+ opacity: show ? 0 : 1
77
+ }).animate({
78
+ left: left + ( show ? 0 : mx * width ),
79
+ top: top + ( show ? 0 : my * height ),
80
+ opacity: show ? 1 : 0
81
+ }, o.duration || 500, o.easing, childComplete );
82
+ }
83
+ }
84
+
85
+ function animComplete() {
86
+ el.css({
87
+ visibility: "visible"
88
+ });
89
+ $( pieces ).remove();
90
+ if ( !show ) {
91
+ el.hide();
92
+ }
93
+ done();
94
+ }
95
+ };
96
+
97
+ })(jQuery);
@@ -0,0 +1,30 @@
1
+ /*!
2
+ * jQuery UI Effects Fade @VERSION
3
+ * http://jqueryui.com
4
+ *
5
+ * Copyright 2012 jQuery Foundation and other contributors
6
+ * Released under the MIT license.
7
+ * http://jquery.org/license
8
+ *
9
+ * http://api.jqueryui.com/fade-effect/
10
+ *
11
+ * Depends:
12
+ * jquery.ui.effect.js
13
+ */
14
+ (function( $, undefined ) {
15
+
16
+ $.effects.effect.fade = function( o, done ) {
17
+ var el = $( this ),
18
+ mode = $.effects.setMode( el, o.mode || "toggle" );
19
+
20
+ el.animate({
21
+ opacity: mode
22
+ }, {
23
+ queue: false,
24
+ duration: o.duration,
25
+ easing: o.easing,
26
+ complete: done
27
+ });
28
+ };
29
+
30
+ })( jQuery );
@@ -0,0 +1,76 @@
1
+ /*!
2
+ * jQuery UI Effects Fold @VERSION
3
+ * http://jqueryui.com
4
+ *
5
+ * Copyright 2012 jQuery Foundation and other contributors
6
+ * Released under the MIT license.
7
+ * http://jquery.org/license
8
+ *
9
+ * http://api.jqueryui.com/fold-effect/
10
+ *
11
+ * Depends:
12
+ * jquery.ui.effect.js
13
+ */
14
+ (function( $, undefined ) {
15
+
16
+ $.effects.effect.fold = function( o, done ) {
17
+
18
+ // Create element
19
+ var el = $( this ),
20
+ props = [ "position", "top", "bottom", "left", "right", "height", "width" ],
21
+ mode = $.effects.setMode( el, o.mode || "hide" ),
22
+ show = mode === "show",
23
+ hide = mode === "hide",
24
+ size = o.size || 15,
25
+ percent = /([0-9]+)%/.exec( size ),
26
+ horizFirst = !!o.horizFirst,
27
+ widthFirst = show !== horizFirst,
28
+ ref = widthFirst ? [ "width", "height" ] : [ "height", "width" ],
29
+ duration = o.duration / 2,
30
+ wrapper, distance,
31
+ animation1 = {},
32
+ animation2 = {};
33
+
34
+ $.effects.save( el, props );
35
+ el.show();
36
+
37
+ // Create Wrapper
38
+ wrapper = $.effects.createWrapper( el ).css({
39
+ overflow: "hidden"
40
+ });
41
+ distance = widthFirst ?
42
+ [ wrapper.width(), wrapper.height() ] :
43
+ [ wrapper.height(), wrapper.width() ];
44
+
45
+ if ( percent ) {
46
+ size = parseInt( percent[ 1 ], 10 ) / 100 * distance[ hide ? 0 : 1 ];
47
+ }
48
+ if ( show ) {
49
+ wrapper.css( horizFirst ? {
50
+ height: 0,
51
+ width: size
52
+ } : {
53
+ height: size,
54
+ width: 0
55
+ });
56
+ }
57
+
58
+ // Animation
59
+ animation1[ ref[ 0 ] ] = show ? distance[ 0 ] : size;
60
+ animation2[ ref[ 1 ] ] = show ? distance[ 1 ] : 0;
61
+
62
+ // Animate
63
+ wrapper
64
+ .animate( animation1, duration, o.easing )
65
+ .animate( animation2, duration, o.easing, function() {
66
+ if ( hide ) {
67
+ el.hide();
68
+ }
69
+ $.effects.restore( el, props );
70
+ $.effects.removeWrapper( el );
71
+ done();
72
+ });
73
+
74
+ };
75
+
76
+ })(jQuery);
@@ -0,0 +1,50 @@
1
+ /*!
2
+ * jQuery UI Effects Highlight @VERSION
3
+ * http://jqueryui.com
4
+ *
5
+ * Copyright 2012 jQuery Foundation and other contributors
6
+ * Released under the MIT license.
7
+ * http://jquery.org/license
8
+ *
9
+ * http://api.jqueryui.com/highlight-effect/
10
+ *
11
+ * Depends:
12
+ * jquery.ui.effect.js
13
+ */
14
+ (function( $, undefined ) {
15
+
16
+ $.effects.effect.highlight = function( o, done ) {
17
+ var elem = $( this ),
18
+ props = [ "backgroundImage", "backgroundColor", "opacity" ],
19
+ mode = $.effects.setMode( elem, o.mode || "show" ),
20
+ animation = {
21
+ backgroundColor: elem.css( "backgroundColor" )
22
+ };
23
+
24
+ if (mode === "hide") {
25
+ animation.opacity = 0;
26
+ }
27
+
28
+ $.effects.save( elem, props );
29
+
30
+ elem
31
+ .show()
32
+ .css({
33
+ backgroundImage: "none",
34
+ backgroundColor: o.color || "#ffff99"
35
+ })
36
+ .animate( animation, {
37
+ queue: false,
38
+ duration: o.duration,
39
+ easing: o.easing,
40
+ complete: function() {
41
+ if ( mode === "hide" ) {
42
+ elem.hide();
43
+ }
44
+ $.effects.restore( elem, props );
45
+ done();
46
+ }
47
+ });
48
+ };
49
+
50
+ })(jQuery);
@@ -0,0 +1,63 @@
1
+ /*!
2
+ * jQuery UI Effects Pulsate @VERSION
3
+ * http://jqueryui.com
4
+ *
5
+ * Copyright 2012 jQuery Foundation and other contributors
6
+ * Released under the MIT license.
7
+ * http://jquery.org/license
8
+ *
9
+ * http://api.jqueryui.com/pulsate-effect/
10
+ *
11
+ * Depends:
12
+ * jquery.ui.effect.js
13
+ */
14
+ (function( $, undefined ) {
15
+
16
+ $.effects.effect.pulsate = function( o, done ) {
17
+ var elem = $( this ),
18
+ mode = $.effects.setMode( elem, o.mode || "show" ),
19
+ show = mode === "show",
20
+ hide = mode === "hide",
21
+ showhide = ( show || mode === "hide" ),
22
+
23
+ // showing or hiding leaves of the "last" animation
24
+ anims = ( ( o.times || 5 ) * 2 ) + ( showhide ? 1 : 0 ),
25
+ duration = o.duration / anims,
26
+ animateTo = 0,
27
+ queue = elem.queue(),
28
+ queuelen = queue.length,
29
+ i;
30
+
31
+ if ( show || !elem.is(":visible")) {
32
+ elem.css( "opacity", 0 ).show();
33
+ animateTo = 1;
34
+ }
35
+
36
+ // anims - 1 opacity "toggles"
37
+ for ( i = 1; i < anims; i++ ) {
38
+ elem.animate({
39
+ opacity: animateTo
40
+ }, duration, o.easing );
41
+ animateTo = 1 - animateTo;
42
+ }
43
+
44
+ elem.animate({
45
+ opacity: animateTo
46
+ }, duration, o.easing);
47
+
48
+ elem.queue(function() {
49
+ if ( hide ) {
50
+ elem.hide();
51
+ }
52
+ done();
53
+ });
54
+
55
+ // We just queued up "anims" animations, we need to put them next in the queue
56
+ if ( queuelen > 1 ) {
57
+ queue.splice.apply( queue,
58
+ [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) );
59
+ }
60
+ elem.dequeue();
61
+ };
62
+
63
+ })(jQuery);
@@ -0,0 +1,318 @@
1
+ /*!
2
+ * jQuery UI Effects Scale @VERSION
3
+ * http://jqueryui.com
4
+ *
5
+ * Copyright 2012 jQuery Foundation and other contributors
6
+ * Released under the MIT license.
7
+ * http://jquery.org/license
8
+ *
9
+ * http://api.jqueryui.com/scale-effect/
10
+ *
11
+ * Depends:
12
+ * jquery.ui.effect.js
13
+ */
14
+ (function( $, undefined ) {
15
+
16
+ $.effects.effect.puff = function( o, done ) {
17
+ var elem = $( this ),
18
+ mode = $.effects.setMode( elem, o.mode || "hide" ),
19
+ hide = mode === "hide",
20
+ percent = parseInt( o.percent, 10 ) || 150,
21
+ factor = percent / 100,
22
+ original = {
23
+ height: elem.height(),
24
+ width: elem.width(),
25
+ outerHeight: elem.outerHeight(),
26
+ outerWidth: elem.outerWidth()
27
+ };
28
+
29
+ $.extend( o, {
30
+ effect: "scale",
31
+ queue: false,
32
+ fade: true,
33
+ mode: mode,
34
+ complete: done,
35
+ percent: hide ? percent : 100,
36
+ from: hide ?
37
+ original :
38
+ {
39
+ height: original.height * factor,
40
+ width: original.width * factor,
41
+ outerHeight: original.outerHeight * factor,
42
+ outerWidth: original.outerWidth * factor
43
+ }
44
+ });
45
+
46
+ elem.effect( o );
47
+ };
48
+
49
+ $.effects.effect.scale = function( o, done ) {
50
+
51
+ // Create element
52
+ var el = $( this ),
53
+ options = $.extend( true, {}, o ),
54
+ mode = $.effects.setMode( el, o.mode || "effect" ),
55
+ percent = parseInt( o.percent, 10 ) ||
56
+ ( parseInt( o.percent, 10 ) === 0 ? 0 : ( mode === "hide" ? 0 : 100 ) ),
57
+ direction = o.direction || "both",
58
+ origin = o.origin,
59
+ original = {
60
+ height: el.height(),
61
+ width: el.width(),
62
+ outerHeight: el.outerHeight(),
63
+ outerWidth: el.outerWidth()
64
+ },
65
+ factor = {
66
+ y: direction !== "horizontal" ? (percent / 100) : 1,
67
+ x: direction !== "vertical" ? (percent / 100) : 1
68
+ };
69
+
70
+ // We are going to pass this effect to the size effect:
71
+ options.effect = "size";
72
+ options.queue = false;
73
+ options.complete = done;
74
+
75
+ // Set default origin and restore for show/hide
76
+ if ( mode !== "effect" ) {
77
+ options.origin = origin || ["middle","center"];
78
+ options.restore = true;
79
+ }
80
+
81
+ options.from = o.from || ( mode === "show" ? {
82
+ height: 0,
83
+ width: 0,
84
+ outerHeight: 0,
85
+ outerWidth: 0
86
+ } : original );
87
+ options.to = {
88
+ height: original.height * factor.y,
89
+ width: original.width * factor.x,
90
+ outerHeight: original.outerHeight * factor.y,
91
+ outerWidth: original.outerWidth * factor.x
92
+ };
93
+
94
+ // Fade option to support puff
95
+ if ( options.fade ) {
96
+ if ( mode === "show" ) {
97
+ options.from.opacity = 0;
98
+ options.to.opacity = 1;
99
+ }
100
+ if ( mode === "hide" ) {
101
+ options.from.opacity = 1;
102
+ options.to.opacity = 0;
103
+ }
104
+ }
105
+
106
+ // Animate
107
+ el.effect( options );
108
+
109
+ };
110
+
111
+ $.effects.effect.size = function( o, done ) {
112
+
113
+ // Create element
114
+ var original, baseline, factor,
115
+ el = $( this ),
116
+ props0 = [ "position", "top", "bottom", "left", "right", "width", "height", "overflow", "opacity" ],
117
+
118
+ // Always restore
119
+ props1 = [ "position", "top", "bottom", "left", "right", "overflow", "opacity" ],
120
+
121
+ // Copy for children
122
+ props2 = [ "width", "height", "overflow" ],
123
+ cProps = [ "fontSize" ],
124
+ vProps = [ "borderTopWidth", "borderBottomWidth", "paddingTop", "paddingBottom" ],
125
+ hProps = [ "borderLeftWidth", "borderRightWidth", "paddingLeft", "paddingRight" ],
126
+
127
+ // Set options
128
+ mode = $.effects.setMode( el, o.mode || "effect" ),
129
+ restore = o.restore || mode !== "effect",
130
+ scale = o.scale || "both",
131
+ origin = o.origin || [ "middle", "center" ],
132
+ position = el.css( "position" ),
133
+ props = restore ? props0 : props1,
134
+ zero = {
135
+ height: 0,
136
+ width: 0,
137
+ outerHeight: 0,
138
+ outerWidth: 0
139
+ };
140
+
141
+ if ( mode === "show" ) {
142
+ el.show();
143
+ }
144
+ original = {
145
+ height: el.height(),
146
+ width: el.width(),
147
+ outerHeight: el.outerHeight(),
148
+ outerWidth: el.outerWidth()
149
+ };
150
+
151
+ if ( o.mode === "toggle" && mode === "show" ) {
152
+ el.from = o.to || zero;
153
+ el.to = o.from || original;
154
+ } else {
155
+ el.from = o.from || ( mode === "show" ? zero : original );
156
+ el.to = o.to || ( mode === "hide" ? zero : original );
157
+ }
158
+
159
+ // Set scaling factor
160
+ factor = {
161
+ from: {
162
+ y: el.from.height / original.height,
163
+ x: el.from.width / original.width
164
+ },
165
+ to: {
166
+ y: el.to.height / original.height,
167
+ x: el.to.width / original.width
168
+ }
169
+ };
170
+
171
+ // Scale the css box
172
+ if ( scale === "box" || scale === "both" ) {
173
+
174
+ // Vertical props scaling
175
+ if ( factor.from.y !== factor.to.y ) {
176
+ props = props.concat( vProps );
177
+ el.from = $.effects.setTransition( el, vProps, factor.from.y, el.from );
178
+ el.to = $.effects.setTransition( el, vProps, factor.to.y, el.to );
179
+ }
180
+
181
+ // Horizontal props scaling
182
+ if ( factor.from.x !== factor.to.x ) {
183
+ props = props.concat( hProps );
184
+ el.from = $.effects.setTransition( el, hProps, factor.from.x, el.from );
185
+ el.to = $.effects.setTransition( el, hProps, factor.to.x, el.to );
186
+ }
187
+ }
188
+
189
+ // Scale the content
190
+ if ( scale === "content" || scale === "both" ) {
191
+
192
+ // Vertical props scaling
193
+ if ( factor.from.y !== factor.to.y ) {
194
+ props = props.concat( cProps ).concat( props2 );
195
+ el.from = $.effects.setTransition( el, cProps, factor.from.y, el.from );
196
+ el.to = $.effects.setTransition( el, cProps, factor.to.y, el.to );
197
+ }
198
+ }
199
+
200
+ $.effects.save( el, props );
201
+ el.show();
202
+ $.effects.createWrapper( el );
203
+ el.css( "overflow", "hidden" ).css( el.from );
204
+
205
+ // Adjust
206
+ if (origin) { // Calculate baseline shifts
207
+ baseline = $.effects.getBaseline( origin, original );
208
+ el.from.top = ( original.outerHeight - el.outerHeight() ) * baseline.y;
209
+ el.from.left = ( original.outerWidth - el.outerWidth() ) * baseline.x;
210
+ el.to.top = ( original.outerHeight - el.to.outerHeight ) * baseline.y;
211
+ el.to.left = ( original.outerWidth - el.to.outerWidth ) * baseline.x;
212
+ }
213
+ el.css( el.from ); // set top & left
214
+
215
+ // Animate
216
+ if ( scale === "content" || scale === "both" ) { // Scale the children
217
+
218
+ // Add margins/font-size
219
+ vProps = vProps.concat([ "marginTop", "marginBottom" ]).concat(cProps);
220
+ hProps = hProps.concat([ "marginLeft", "marginRight" ]);
221
+ props2 = props0.concat(vProps).concat(hProps);
222
+
223
+ el.find( "*[width]" ).each( function(){
224
+ var child = $( this ),
225
+ c_original = {
226
+ height: child.height(),
227
+ width: child.width(),
228
+ outerHeight: child.outerHeight(),
229
+ outerWidth: child.outerWidth()
230
+ };
231
+ if (restore) {
232
+ $.effects.save(child, props2);
233
+ }
234
+
235
+ child.from = {
236
+ height: c_original.height * factor.from.y,
237
+ width: c_original.width * factor.from.x,
238
+ outerHeight: c_original.outerHeight * factor.from.y,
239
+ outerWidth: c_original.outerWidth * factor.from.x
240
+ };
241
+ child.to = {
242
+ height: c_original.height * factor.to.y,
243
+ width: c_original.width * factor.to.x,
244
+ outerHeight: c_original.height * factor.to.y,
245
+ outerWidth: c_original.width * factor.to.x
246
+ };
247
+
248
+ // Vertical props scaling
249
+ if ( factor.from.y !== factor.to.y ) {
250
+ child.from = $.effects.setTransition( child, vProps, factor.from.y, child.from );
251
+ child.to = $.effects.setTransition( child, vProps, factor.to.y, child.to );
252
+ }
253
+
254
+ // Horizontal props scaling
255
+ if ( factor.from.x !== factor.to.x ) {
256
+ child.from = $.effects.setTransition( child, hProps, factor.from.x, child.from );
257
+ child.to = $.effects.setTransition( child, hProps, factor.to.x, child.to );
258
+ }
259
+
260
+ // Animate children
261
+ child.css( child.from );
262
+ child.animate( child.to, o.duration, o.easing, function() {
263
+
264
+ // Restore children
265
+ if ( restore ) {
266
+ $.effects.restore( child, props2 );
267
+ }
268
+ });
269
+ });
270
+ }
271
+
272
+ // Animate
273
+ el.animate( el.to, {
274
+ queue: false,
275
+ duration: o.duration,
276
+ easing: o.easing,
277
+ complete: function() {
278
+ if ( el.to.opacity === 0 ) {
279
+ el.css( "opacity", el.from.opacity );
280
+ }
281
+ if( mode === "hide" ) {
282
+ el.hide();
283
+ }
284
+ $.effects.restore( el, props );
285
+ if ( !restore ) {
286
+
287
+ // we need to calculate our new positioning based on the scaling
288
+ if ( position === "static" ) {
289
+ el.css({
290
+ position: "relative",
291
+ top: el.to.top,
292
+ left: el.to.left
293
+ });
294
+ } else {
295
+ $.each([ "top", "left" ], function( idx, pos ) {
296
+ el.css( pos, function( _, str ) {
297
+ var val = parseInt( str, 10 ),
298
+ toRef = idx ? el.to.left : el.to.top;
299
+
300
+ // if original was "auto", recalculate the new value from wrapper
301
+ if ( str === "auto" ) {
302
+ return toRef + "px";
303
+ }
304
+
305
+ return val + toRef + "px";
306
+ });
307
+ });
308
+ }
309
+ }
310
+
311
+ $.effects.removeWrapper( el );
312
+ done();
313
+ }
314
+ });
315
+
316
+ };
317
+
318
+ })(jQuery);
@@ -0,0 +1,74 @@
1
+ /*!
2
+ * jQuery UI Effects Shake @VERSION
3
+ * http://jqueryui.com
4
+ *
5
+ * Copyright 2012 jQuery Foundation and other contributors
6
+ * Released under the MIT license.
7
+ * http://jquery.org/license
8
+ *
9
+ * http://api.jqueryui.com/shake-effect/
10
+ *
11
+ * Depends:
12
+ * jquery.ui.effect.js
13
+ */
14
+ (function( $, undefined ) {
15
+
16
+ $.effects.effect.shake = function( o, done ) {
17
+
18
+ var el = $( this ),
19
+ props = [ "position", "top", "bottom", "left", "right", "height", "width" ],
20
+ mode = $.effects.setMode( el, o.mode || "effect" ),
21
+ direction = o.direction || "left",
22
+ distance = o.distance || 20,
23
+ times = o.times || 3,
24
+ anims = times * 2 + 1,
25
+ speed = Math.round(o.duration/anims),
26
+ ref = (direction === "up" || direction === "down") ? "top" : "left",
27
+ positiveMotion = (direction === "up" || direction === "left"),
28
+ animation = {},
29
+ animation1 = {},
30
+ animation2 = {},
31
+ i,
32
+
33
+ // we will need to re-assemble the queue to stack our animations in place
34
+ queue = el.queue(),
35
+ queuelen = queue.length;
36
+
37
+ $.effects.save( el, props );
38
+ el.show();
39
+ $.effects.createWrapper( el );
40
+
41
+ // Animation
42
+ animation[ ref ] = ( positiveMotion ? "-=" : "+=" ) + distance;
43
+ animation1[ ref ] = ( positiveMotion ? "+=" : "-=" ) + distance * 2;
44
+ animation2[ ref ] = ( positiveMotion ? "-=" : "+=" ) + distance * 2;
45
+
46
+ // Animate
47
+ el.animate( animation, speed, o.easing );
48
+
49
+ // Shakes
50
+ for ( i = 1; i < times; i++ ) {
51
+ el.animate( animation1, speed, o.easing ).animate( animation2, speed, o.easing );
52
+ }
53
+ el
54
+ .animate( animation1, speed, o.easing )
55
+ .animate( animation, speed / 2, o.easing )
56
+ .queue(function() {
57
+ if ( mode === "hide" ) {
58
+ el.hide();
59
+ }
60
+ $.effects.restore( el, props );
61
+ $.effects.removeWrapper( el );
62
+ done();
63
+ });
64
+
65
+ // inject all the animations we just queued to be first in line (after "inprogress")
66
+ if ( queuelen > 1) {
67
+ queue.splice.apply( queue,
68
+ [ 1, 0 ].concat( queue.splice( queuelen, anims + 1 ) ) );
69
+ }
70
+ el.dequeue();
71
+
72
+ };
73
+
74
+ })(jQuery);