jquery-ui-rails 5.0.4 → 7.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (279) hide show
  1. checksums.yaml +7 -0
  2. data/.gitmodules +1 -1
  3. data/.travis.yml +1 -1
  4. data/History.md +23 -2
  5. data/README.md +67 -50
  6. data/Rakefile +58 -29
  7. data/VERSIONS.md +4 -0
  8. data/app/assets/images/jquery-ui/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  9. data/app/assets/images/jquery-ui/ui-icons_444444_256x240.png +0 -0
  10. data/app/assets/images/jquery-ui/ui-icons_555555_256x240.png +0 -0
  11. data/app/assets/images/jquery-ui/ui-icons_777620_256x240.png +0 -0
  12. data/app/assets/images/jquery-ui/ui-icons_777777_256x240.png +0 -0
  13. data/app/assets/images/jquery-ui/ui-icons_cc0000_256x240.png +0 -0
  14. data/app/assets/images/jquery-ui/ui-icons_ffffff_256x240.png +0 -0
  15. data/app/assets/javascripts/jquery-ui/core.js +15 -304
  16. data/app/assets/javascripts/jquery-ui/data.js +45 -0
  17. data/app/assets/javascripts/jquery-ui/disable-selection.js +51 -0
  18. data/app/assets/javascripts/jquery-ui/effect.all.js +15 -16
  19. data/app/assets/javascripts/jquery-ui/effect.js +565 -891
  20. data/app/assets/javascripts/jquery-ui/effects/effect-blind.js +76 -0
  21. data/app/assets/javascripts/jquery-ui/effects/effect-bounce.js +116 -0
  22. data/app/assets/javascripts/jquery-ui/effects/effect-clip.js +71 -0
  23. data/app/assets/javascripts/jquery-ui/effects/effect-drop.js +75 -0
  24. data/app/assets/javascripts/jquery-ui/effects/effect-explode.js +117 -0
  25. data/app/assets/javascripts/jquery-ui/effects/effect-fade.js +53 -0
  26. data/app/assets/javascripts/jquery-ui/effects/effect-fold.js +95 -0
  27. data/app/assets/javascripts/jquery-ui/effects/effect-highlight.js +63 -0
  28. data/app/assets/javascripts/jquery-ui/effects/effect-puff.js +49 -0
  29. data/app/assets/javascripts/jquery-ui/effects/effect-pulsate.js +70 -0
  30. data/app/assets/javascripts/jquery-ui/effects/effect-scale.js +63 -0
  31. data/app/assets/javascripts/jquery-ui/effects/effect-shake.js +80 -0
  32. data/app/assets/javascripts/jquery-ui/effects/effect-size.js +199 -0
  33. data/app/assets/javascripts/jquery-ui/effects/effect-slide.js +82 -0
  34. data/app/assets/javascripts/jquery-ui/effects/effect-transfer.js +46 -0
  35. data/app/assets/javascripts/jquery-ui/focusable.js +89 -0
  36. data/app/assets/javascripts/jquery-ui/form-reset-mixin.js +83 -0
  37. data/app/assets/javascripts/jquery-ui/form.js +25 -0
  38. data/app/assets/javascripts/jquery-ui/i18n/datepicker-af.js +40 -0
  39. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ar-DZ.js +42 -0
  40. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ar.js +42 -0
  41. data/app/assets/javascripts/jquery-ui/i18n/datepicker-az.js +40 -0
  42. data/app/assets/javascripts/jquery-ui/i18n/datepicker-be.js +40 -0
  43. data/app/assets/javascripts/jquery-ui/i18n/datepicker-bg.js +41 -0
  44. data/app/assets/javascripts/jquery-ui/i18n/datepicker-bs.js +40 -0
  45. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ca.js +40 -0
  46. data/app/assets/javascripts/jquery-ui/i18n/datepicker-cs.js +40 -0
  47. data/app/assets/javascripts/jquery-ui/i18n/datepicker-cy-GB.js +48 -0
  48. data/app/assets/javascripts/jquery-ui/i18n/datepicker-da.js +40 -0
  49. data/app/assets/javascripts/jquery-ui/i18n/datepicker-de-AT.js +41 -0
  50. data/app/assets/javascripts/jquery-ui/i18n/datepicker-de.js +40 -0
  51. data/app/assets/javascripts/jquery-ui/i18n/datepicker-el.js +40 -0
  52. data/app/assets/javascripts/jquery-ui/i18n/datepicker-en-AU.js +40 -0
  53. data/app/assets/javascripts/jquery-ui/i18n/datepicker-en-GB.js +40 -0
  54. data/app/assets/javascripts/jquery-ui/i18n/datepicker-en-NZ.js +40 -0
  55. data/app/assets/javascripts/jquery-ui/i18n/datepicker-eo.js +40 -0
  56. data/app/assets/javascripts/jquery-ui/i18n/datepicker-es.js +40 -0
  57. data/app/assets/javascripts/jquery-ui/i18n/datepicker-et.js +48 -0
  58. data/app/assets/javascripts/jquery-ui/i18n/datepicker-eu.js +39 -0
  59. data/app/assets/javascripts/jquery-ui/i18n/datepicker-fa.js +76 -0
  60. data/app/assets/javascripts/jquery-ui/i18n/datepicker-fi.js +40 -0
  61. data/app/assets/javascripts/jquery-ui/i18n/datepicker-fo.js +48 -0
  62. data/app/assets/javascripts/jquery-ui/i18n/datepicker-fr-CA.js +40 -0
  63. data/app/assets/javascripts/jquery-ui/i18n/datepicker-fr-CH.js +40 -0
  64. data/app/assets/javascripts/jquery-ui/i18n/datepicker-fr.js +42 -0
  65. data/app/assets/javascripts/jquery-ui/i18n/datepicker-gl.js +40 -0
  66. data/app/assets/javascripts/jquery-ui/i18n/datepicker-he.js +40 -0
  67. data/app/assets/javascripts/jquery-ui/i18n/datepicker-hi.js +40 -0
  68. data/app/assets/javascripts/jquery-ui/i18n/datepicker-hr.js +40 -0
  69. data/app/assets/javascripts/jquery-ui/i18n/datepicker-hu.js +39 -0
  70. data/app/assets/javascripts/jquery-ui/i18n/datepicker-hy.js +40 -0
  71. data/app/assets/javascripts/jquery-ui/i18n/datepicker-id.js +40 -0
  72. data/app/assets/javascripts/jquery-ui/i18n/datepicker-is.js +48 -0
  73. data/app/assets/javascripts/jquery-ui/i18n/datepicker-it-CH.js +40 -0
  74. data/app/assets/javascripts/jquery-ui/i18n/datepicker-it.js +40 -0
  75. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ja.js +40 -0
  76. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ka.js +51 -0
  77. data/app/assets/javascripts/jquery-ui/i18n/datepicker-kk.js +40 -0
  78. data/app/assets/javascripts/jquery-ui/i18n/datepicker-km.js +40 -0
  79. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ko.js +40 -0
  80. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ky.js +41 -0
  81. data/app/assets/javascripts/jquery-ui/i18n/datepicker-lb.js +48 -0
  82. data/app/assets/javascripts/jquery-ui/i18n/datepicker-lt.js +48 -0
  83. data/app/assets/javascripts/jquery-ui/i18n/datepicker-lv.js +48 -0
  84. data/app/assets/javascripts/jquery-ui/i18n/datepicker-mk.js +40 -0
  85. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ml.js +40 -0
  86. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ms.js +40 -0
  87. data/app/assets/javascripts/jquery-ui/i18n/datepicker-nb.js +52 -0
  88. data/app/assets/javascripts/jquery-ui/i18n/datepicker-nl-BE.js +40 -0
  89. data/app/assets/javascripts/jquery-ui/i18n/datepicker-nl.js +40 -0
  90. data/app/assets/javascripts/jquery-ui/i18n/datepicker-nn.js +52 -0
  91. data/app/assets/javascripts/jquery-ui/i18n/datepicker-no.js +53 -0
  92. data/app/assets/javascripts/jquery-ui/i18n/datepicker-pl.js +40 -0
  93. data/app/assets/javascripts/jquery-ui/i18n/datepicker-pt-BR.js +48 -0
  94. data/app/assets/javascripts/jquery-ui/i18n/datepicker-pt.js +47 -0
  95. data/app/assets/javascripts/jquery-ui/i18n/datepicker-rm.js +64 -0
  96. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ro.js +43 -0
  97. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ru.js +40 -0
  98. data/app/assets/javascripts/jquery-ui/i18n/datepicker-sk.js +40 -0
  99. data/app/assets/javascripts/jquery-ui/i18n/datepicker-sl.js +41 -0
  100. data/app/assets/javascripts/jquery-ui/i18n/datepicker-sq.js +40 -0
  101. data/app/assets/javascripts/jquery-ui/i18n/datepicker-sr-SR.js +40 -0
  102. data/app/assets/javascripts/jquery-ui/i18n/datepicker-sr.js +40 -0
  103. data/app/assets/javascripts/jquery-ui/i18n/datepicker-sv.js +40 -0
  104. data/app/assets/javascripts/jquery-ui/i18n/datepicker-ta.js +56 -0
  105. data/app/assets/javascripts/jquery-ui/i18n/datepicker-th.js +40 -0
  106. data/app/assets/javascripts/jquery-ui/i18n/datepicker-tj.js +40 -0
  107. data/app/assets/javascripts/jquery-ui/i18n/datepicker-tr.js +40 -0
  108. data/app/assets/javascripts/jquery-ui/i18n/datepicker-uk.js +41 -0
  109. data/app/assets/javascripts/jquery-ui/i18n/datepicker-vi.js +40 -0
  110. data/app/assets/javascripts/jquery-ui/i18n/datepicker-zh-CN.js +40 -0
  111. data/app/assets/javascripts/jquery-ui/i18n/datepicker-zh-HK.js +40 -0
  112. data/app/assets/javascripts/jquery-ui/i18n/datepicker-zh-TW.js +40 -0
  113. data/app/assets/javascripts/jquery-ui/ie.js +20 -0
  114. data/app/assets/javascripts/jquery-ui/jquery-patch.js +91 -0
  115. data/app/assets/javascripts/jquery-ui/jquery-var-for-color.js +24 -0
  116. data/app/assets/javascripts/jquery-ui/keycode.js +51 -0
  117. data/app/assets/javascripts/jquery-ui/labels.js +71 -0
  118. data/app/assets/javascripts/jquery-ui/plugin.js +49 -0
  119. data/app/assets/javascripts/jquery-ui/position.js +107 -111
  120. data/app/assets/javascripts/jquery-ui/safe-active-element.js +46 -0
  121. data/app/assets/javascripts/jquery-ui/safe-blur.js +27 -0
  122. data/app/assets/javascripts/jquery-ui/scroll-parent.js +50 -0
  123. data/app/assets/javascripts/jquery-ui/tabbable.js +41 -0
  124. data/app/assets/javascripts/jquery-ui/unique-id.js +54 -0
  125. data/app/assets/javascripts/jquery-ui/vendor/jquery-color/jquery.color.js +722 -0
  126. data/app/assets/javascripts/jquery-ui/version.js +20 -0
  127. data/app/assets/javascripts/jquery-ui/widget.js +359 -163
  128. data/app/assets/javascripts/jquery-ui/{accordion.js → widgets/accordion.js} +200 -163
  129. data/app/assets/javascripts/jquery-ui/{autocomplete.js → widgets/autocomplete.js} +153 -106
  130. data/app/assets/javascripts/jquery-ui/widgets/button.js +454 -0
  131. data/app/assets/javascripts/jquery-ui/widgets/checkboxradio.js +289 -0
  132. data/app/assets/javascripts/jquery-ui/widgets/controlgroup.js +304 -0
  133. data/app/assets/javascripts/jquery-ui/widgets/datepicker.js +2243 -0
  134. data/app/assets/javascripts/jquery-ui/{dialog.js → widgets/dialog.js} +267 -181
  135. data/app/assets/javascripts/jquery-ui/{draggable.js → widgets/draggable.js} +430 -294
  136. data/app/assets/javascripts/jquery-ui/{droppable.js → widgets/droppable.js} +174 -84
  137. data/app/assets/javascripts/jquery-ui/{menu.js → widgets/menu.js} +228 -158
  138. data/app/assets/javascripts/jquery-ui/widgets/mouse.js +241 -0
  139. data/app/assets/javascripts/jquery-ui/{progressbar.js → widgets/progressbar.js} +63 -41
  140. data/app/assets/javascripts/jquery-ui/widgets/resizable.js +1225 -0
  141. data/app/assets/javascripts/jquery-ui/widgets/selectable.js +321 -0
  142. data/app/assets/javascripts/jquery-ui/{selectmenu.js → widgets/selectmenu.js} +259 -177
  143. data/app/assets/javascripts/jquery-ui/{slider.js → widgets/slider.js} +199 -160
  144. data/app/assets/javascripts/jquery-ui/widgets/sortable.js +1623 -0
  145. data/app/assets/javascripts/jquery-ui/{spinner.js → widgets/spinner.js} +184 -114
  146. data/app/assets/javascripts/jquery-ui/{tabs.js → widgets/tabs.js} +258 -211
  147. data/app/assets/javascripts/jquery-ui/{tooltip.js → widgets/tooltip.js} +165 -100
  148. data/app/assets/javascripts/jquery-ui.js +53 -33
  149. data/app/assets/stylesheets/jquery-ui/accordion.css +1 -15
  150. data/app/assets/stylesheets/jquery-ui/all.css +1 -1
  151. data/app/assets/stylesheets/jquery-ui/autocomplete.css +1 -3
  152. data/app/assets/stylesheets/jquery-ui/base.css +3 -1
  153. data/app/assets/stylesheets/jquery-ui/button.css +35 -68
  154. data/app/assets/stylesheets/jquery-ui/checkboxradio.css +37 -0
  155. data/app/assets/stylesheets/jquery-ui/controlgroup.css +68 -0
  156. data/app/assets/stylesheets/jquery-ui/core.css +12 -8
  157. data/app/assets/stylesheets/jquery-ui/datepicker.css +11 -2
  158. data/app/assets/stylesheets/jquery-ui/dialog.css +38 -11
  159. data/app/assets/stylesheets/jquery-ui/draggable.css +1 -2
  160. data/app/assets/stylesheets/jquery-ui/menu.css +7 -7
  161. data/app/assets/stylesheets/jquery-ui/progressbar.css +2 -3
  162. data/app/assets/stylesheets/jquery-ui/resizable.css +1 -2
  163. data/app/assets/stylesheets/jquery-ui/selectable.css +1 -2
  164. data/app/assets/stylesheets/jquery-ui/selectmenu.css +11 -22
  165. data/app/assets/stylesheets/jquery-ui/slider.css +2 -3
  166. data/app/assets/stylesheets/jquery-ui/sortable.css +1 -2
  167. data/app/assets/stylesheets/jquery-ui/spinner.css +7 -22
  168. data/app/assets/stylesheets/jquery-ui/tabs.css +1 -2
  169. data/app/assets/stylesheets/jquery-ui/theme.css.erb +121 -92
  170. data/app/assets/stylesheets/jquery-ui/tooltip.css +1 -4
  171. data/lib/jquery/ui/rails/version.rb +2 -2
  172. metadata +153 -146
  173. data/app/assets/images/jquery-ui/ui-bg_flat_75_ffffff_40x100.png +0 -0
  174. data/app/assets/images/jquery-ui/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
  175. data/app/assets/images/jquery-ui/ui-bg_glass_65_ffffff_1x400.png +0 -0
  176. data/app/assets/images/jquery-ui/ui-bg_glass_75_dadada_1x400.png +0 -0
  177. data/app/assets/images/jquery-ui/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
  178. data/app/assets/images/jquery-ui/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  179. data/app/assets/images/jquery-ui/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
  180. data/app/assets/images/jquery-ui/ui-icons_222222_256x240.png +0 -0
  181. data/app/assets/images/jquery-ui/ui-icons_2e83ff_256x240.png +0 -0
  182. data/app/assets/images/jquery-ui/ui-icons_454545_256x240.png +0 -0
  183. data/app/assets/images/jquery-ui/ui-icons_888888_256x240.png +0 -0
  184. data/app/assets/images/jquery-ui/ui-icons_cd0a0a_256x240.png +0 -0
  185. data/app/assets/javascripts/jquery-ui/button.js +0 -414
  186. data/app/assets/javascripts/jquery-ui/datepicker-af.js +0 -37
  187. data/app/assets/javascripts/jquery-ui/datepicker-ar-DZ.js +0 -37
  188. data/app/assets/javascripts/jquery-ui/datepicker-ar.js +0 -38
  189. data/app/assets/javascripts/jquery-ui/datepicker-az.js +0 -37
  190. data/app/assets/javascripts/jquery-ui/datepicker-be.js +0 -37
  191. data/app/assets/javascripts/jquery-ui/datepicker-bg.js +0 -38
  192. data/app/assets/javascripts/jquery-ui/datepicker-bs.js +0 -37
  193. data/app/assets/javascripts/jquery-ui/datepicker-ca.js +0 -37
  194. data/app/assets/javascripts/jquery-ui/datepicker-cs.js +0 -37
  195. data/app/assets/javascripts/jquery-ui/datepicker-cy-GB.js +0 -37
  196. data/app/assets/javascripts/jquery-ui/datepicker-da.js +0 -37
  197. data/app/assets/javascripts/jquery-ui/datepicker-de.js +0 -37
  198. data/app/assets/javascripts/jquery-ui/datepicker-el.js +0 -37
  199. data/app/assets/javascripts/jquery-ui/datepicker-en-AU.js +0 -37
  200. data/app/assets/javascripts/jquery-ui/datepicker-en-GB.js +0 -37
  201. data/app/assets/javascripts/jquery-ui/datepicker-en-NZ.js +0 -37
  202. data/app/assets/javascripts/jquery-ui/datepicker-eo.js +0 -37
  203. data/app/assets/javascripts/jquery-ui/datepicker-es.js +0 -37
  204. data/app/assets/javascripts/jquery-ui/datepicker-et.js +0 -37
  205. data/app/assets/javascripts/jquery-ui/datepicker-eu.js +0 -36
  206. data/app/assets/javascripts/jquery-ui/datepicker-fa.js +0 -73
  207. data/app/assets/javascripts/jquery-ui/datepicker-fi.js +0 -37
  208. data/app/assets/javascripts/jquery-ui/datepicker-fo.js +0 -37
  209. data/app/assets/javascripts/jquery-ui/datepicker-fr-CA.js +0 -37
  210. data/app/assets/javascripts/jquery-ui/datepicker-fr-CH.js +0 -37
  211. data/app/assets/javascripts/jquery-ui/datepicker-fr.js +0 -39
  212. data/app/assets/javascripts/jquery-ui/datepicker-gl.js +0 -37
  213. data/app/assets/javascripts/jquery-ui/datepicker-he.js +0 -37
  214. data/app/assets/javascripts/jquery-ui/datepicker-hi.js +0 -37
  215. data/app/assets/javascripts/jquery-ui/datepicker-hr.js +0 -37
  216. data/app/assets/javascripts/jquery-ui/datepicker-hu.js +0 -36
  217. data/app/assets/javascripts/jquery-ui/datepicker-hy.js +0 -37
  218. data/app/assets/javascripts/jquery-ui/datepicker-id.js +0 -37
  219. data/app/assets/javascripts/jquery-ui/datepicker-is.js +0 -37
  220. data/app/assets/javascripts/jquery-ui/datepicker-it-CH.js +0 -37
  221. data/app/assets/javascripts/jquery-ui/datepicker-it.js +0 -37
  222. data/app/assets/javascripts/jquery-ui/datepicker-ja.js +0 -37
  223. data/app/assets/javascripts/jquery-ui/datepicker-ka.js +0 -35
  224. data/app/assets/javascripts/jquery-ui/datepicker-kk.js +0 -37
  225. data/app/assets/javascripts/jquery-ui/datepicker-km.js +0 -37
  226. data/app/assets/javascripts/jquery-ui/datepicker-ko.js +0 -37
  227. data/app/assets/javascripts/jquery-ui/datepicker-ky.js +0 -38
  228. data/app/assets/javascripts/jquery-ui/datepicker-lb.js +0 -37
  229. data/app/assets/javascripts/jquery-ui/datepicker-lt.js +0 -37
  230. data/app/assets/javascripts/jquery-ui/datepicker-lv.js +0 -37
  231. data/app/assets/javascripts/jquery-ui/datepicker-mk.js +0 -37
  232. data/app/assets/javascripts/jquery-ui/datepicker-ml.js +0 -37
  233. data/app/assets/javascripts/jquery-ui/datepicker-ms.js +0 -37
  234. data/app/assets/javascripts/jquery-ui/datepicker-nb.js +0 -36
  235. data/app/assets/javascripts/jquery-ui/datepicker-nl-BE.js +0 -37
  236. data/app/assets/javascripts/jquery-ui/datepicker-nl.js +0 -37
  237. data/app/assets/javascripts/jquery-ui/datepicker-nn.js +0 -36
  238. data/app/assets/javascripts/jquery-ui/datepicker-no.js +0 -37
  239. data/app/assets/javascripts/jquery-ui/datepicker-pl.js +0 -37
  240. data/app/assets/javascripts/jquery-ui/datepicker-pt-BR.js +0 -37
  241. data/app/assets/javascripts/jquery-ui/datepicker-pt.js +0 -36
  242. data/app/assets/javascripts/jquery-ui/datepicker-rm.js +0 -35
  243. data/app/assets/javascripts/jquery-ui/datepicker-ro.js +0 -40
  244. data/app/assets/javascripts/jquery-ui/datepicker-ru.js +0 -37
  245. data/app/assets/javascripts/jquery-ui/datepicker-sk.js +0 -37
  246. data/app/assets/javascripts/jquery-ui/datepicker-sl.js +0 -38
  247. data/app/assets/javascripts/jquery-ui/datepicker-sq.js +0 -37
  248. data/app/assets/javascripts/jquery-ui/datepicker-sr-SR.js +0 -37
  249. data/app/assets/javascripts/jquery-ui/datepicker-sr.js +0 -37
  250. data/app/assets/javascripts/jquery-ui/datepicker-sv.js +0 -37
  251. data/app/assets/javascripts/jquery-ui/datepicker-ta.js +0 -37
  252. data/app/assets/javascripts/jquery-ui/datepicker-th.js +0 -37
  253. data/app/assets/javascripts/jquery-ui/datepicker-tj.js +0 -37
  254. data/app/assets/javascripts/jquery-ui/datepicker-tr.js +0 -37
  255. data/app/assets/javascripts/jquery-ui/datepicker-uk.js +0 -38
  256. data/app/assets/javascripts/jquery-ui/datepicker-vi.js +0 -37
  257. data/app/assets/javascripts/jquery-ui/datepicker-zh-CN.js +0 -37
  258. data/app/assets/javascripts/jquery-ui/datepicker-zh-HK.js +0 -37
  259. data/app/assets/javascripts/jquery-ui/datepicker-zh-TW.js +0 -37
  260. data/app/assets/javascripts/jquery-ui/datepicker.js +0 -2086
  261. data/app/assets/javascripts/jquery-ui/effect-blind.js +0 -92
  262. data/app/assets/javascripts/jquery-ui/effect-bounce.js +0 -125
  263. data/app/assets/javascripts/jquery-ui/effect-clip.js +0 -79
  264. data/app/assets/javascripts/jquery-ui/effect-drop.js +0 -77
  265. data/app/assets/javascripts/jquery-ui/effect-explode.js +0 -109
  266. data/app/assets/javascripts/jquery-ui/effect-fade.js +0 -42
  267. data/app/assets/javascripts/jquery-ui/effect-fold.js +0 -88
  268. data/app/assets/javascripts/jquery-ui/effect-highlight.js +0 -62
  269. data/app/assets/javascripts/jquery-ui/effect-puff.js +0 -63
  270. data/app/assets/javascripts/jquery-ui/effect-pulsate.js +0 -75
  271. data/app/assets/javascripts/jquery-ui/effect-scale.js +0 -92
  272. data/app/assets/javascripts/jquery-ui/effect-shake.js +0 -86
  273. data/app/assets/javascripts/jquery-ui/effect-size.js +0 -235
  274. data/app/assets/javascripts/jquery-ui/effect-slide.js +0 -76
  275. data/app/assets/javascripts/jquery-ui/effect-transfer.js +0 -59
  276. data/app/assets/javascripts/jquery-ui/mouse.js +0 -202
  277. data/app/assets/javascripts/jquery-ui/resizable.js +0 -1183
  278. data/app/assets/javascripts/jquery-ui/selectable.js +0 -291
  279. data/app/assets/javascripts/jquery-ui/sortable.js +0 -1308
@@ -1,1183 +0,0 @@
1
- //= require jquery-ui/core
2
- //= require jquery-ui/widget
3
- //= require jquery-ui/mouse
4
-
5
- /*!
6
- * jQuery UI Resizable 1.11.3
7
- * http://jqueryui.com
8
- *
9
- * Copyright jQuery Foundation and other contributors
10
- * Released under the MIT license.
11
- * http://jquery.org/license
12
- *
13
- * http://api.jqueryui.com/resizable/
14
- */
15
- (function( factory ) {
16
- if ( typeof define === "function" && define.amd ) {
17
-
18
- // AMD. Register as an anonymous module.
19
- define([
20
- "jquery",
21
- "./core",
22
- "./mouse",
23
- "./widget"
24
- ], factory );
25
- } else {
26
-
27
- // Browser globals
28
- factory( jQuery );
29
- }
30
- }(function( $ ) {
31
-
32
- $.widget("ui.resizable", $.ui.mouse, {
33
- version: "1.11.3",
34
- widgetEventPrefix: "resize",
35
- options: {
36
- alsoResize: false,
37
- animate: false,
38
- animateDuration: "slow",
39
- animateEasing: "swing",
40
- aspectRatio: false,
41
- autoHide: false,
42
- containment: false,
43
- ghost: false,
44
- grid: false,
45
- handles: "e,s,se",
46
- helper: false,
47
- maxHeight: null,
48
- maxWidth: null,
49
- minHeight: 10,
50
- minWidth: 10,
51
- // See #7960
52
- zIndex: 90,
53
-
54
- // callbacks
55
- resize: null,
56
- start: null,
57
- stop: null
58
- },
59
-
60
- _num: function( value ) {
61
- return parseInt( value, 10 ) || 0;
62
- },
63
-
64
- _isNumber: function( value ) {
65
- return !isNaN( parseInt( value, 10 ) );
66
- },
67
-
68
- _hasScroll: function( el, a ) {
69
-
70
- if ( $( el ).css( "overflow" ) === "hidden") {
71
- return false;
72
- }
73
-
74
- var scroll = ( a && a === "left" ) ? "scrollLeft" : "scrollTop",
75
- has = false;
76
-
77
- if ( el[ scroll ] > 0 ) {
78
- return true;
79
- }
80
-
81
- // TODO: determine which cases actually cause this to happen
82
- // if the element doesn't have the scroll set, see if it's possible to
83
- // set the scroll
84
- el[ scroll ] = 1;
85
- has = ( el[ scroll ] > 0 );
86
- el[ scroll ] = 0;
87
- return has;
88
- },
89
-
90
- _create: function() {
91
-
92
- var n, i, handle, axis, hname,
93
- that = this,
94
- o = this.options;
95
- this.element.addClass("ui-resizable");
96
-
97
- $.extend(this, {
98
- _aspectRatio: !!(o.aspectRatio),
99
- aspectRatio: o.aspectRatio,
100
- originalElement: this.element,
101
- _proportionallyResizeElements: [],
102
- _helper: o.helper || o.ghost || o.animate ? o.helper || "ui-resizable-helper" : null
103
- });
104
-
105
- // Wrap the element if it cannot hold child nodes
106
- if (this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)) {
107
-
108
- this.element.wrap(
109
- $("<div class='ui-wrapper' style='overflow: hidden;'></div>").css({
110
- position: this.element.css("position"),
111
- width: this.element.outerWidth(),
112
- height: this.element.outerHeight(),
113
- top: this.element.css("top"),
114
- left: this.element.css("left")
115
- })
116
- );
117
-
118
- this.element = this.element.parent().data(
119
- "ui-resizable", this.element.resizable( "instance" )
120
- );
121
-
122
- this.elementIsWrapper = true;
123
-
124
- this.element.css({
125
- marginLeft: this.originalElement.css("marginLeft"),
126
- marginTop: this.originalElement.css("marginTop"),
127
- marginRight: this.originalElement.css("marginRight"),
128
- marginBottom: this.originalElement.css("marginBottom")
129
- });
130
- this.originalElement.css({
131
- marginLeft: 0,
132
- marginTop: 0,
133
- marginRight: 0,
134
- marginBottom: 0
135
- });
136
- // support: Safari
137
- // Prevent Safari textarea resize
138
- this.originalResizeStyle = this.originalElement.css("resize");
139
- this.originalElement.css("resize", "none");
140
-
141
- this._proportionallyResizeElements.push( this.originalElement.css({
142
- position: "static",
143
- zoom: 1,
144
- display: "block"
145
- }) );
146
-
147
- // support: IE9
148
- // avoid IE jump (hard set the margin)
149
- this.originalElement.css({ margin: this.originalElement.css("margin") });
150
-
151
- this._proportionallyResize();
152
- }
153
-
154
- this.handles = o.handles ||
155
- ( !$(".ui-resizable-handle", this.element).length ?
156
- "e,s,se" : {
157
- n: ".ui-resizable-n",
158
- e: ".ui-resizable-e",
159
- s: ".ui-resizable-s",
160
- w: ".ui-resizable-w",
161
- se: ".ui-resizable-se",
162
- sw: ".ui-resizable-sw",
163
- ne: ".ui-resizable-ne",
164
- nw: ".ui-resizable-nw"
165
- } );
166
-
167
- if (this.handles.constructor === String) {
168
-
169
- if ( this.handles === "all") {
170
- this.handles = "n,e,s,w,se,sw,ne,nw";
171
- }
172
-
173
- n = this.handles.split(",");
174
- this.handles = {};
175
-
176
- for (i = 0; i < n.length; i++) {
177
-
178
- handle = $.trim(n[i]);
179
- hname = "ui-resizable-" + handle;
180
- axis = $("<div class='ui-resizable-handle " + hname + "'></div>");
181
-
182
- axis.css({ zIndex: o.zIndex });
183
-
184
- // TODO : What's going on here?
185
- if ("se" === handle) {
186
- axis.addClass("ui-icon ui-icon-gripsmall-diagonal-se");
187
- }
188
-
189
- this.handles[handle] = ".ui-resizable-" + handle;
190
- this.element.append(axis);
191
- }
192
-
193
- }
194
-
195
- this._renderAxis = function(target) {
196
-
197
- var i, axis, padPos, padWrapper;
198
-
199
- target = target || this.element;
200
-
201
- for (i in this.handles) {
202
-
203
- if (this.handles[i].constructor === String) {
204
- this.handles[i] = this.element.children( this.handles[ i ] ).first().show();
205
- }
206
-
207
- if (this.elementIsWrapper && this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)) {
208
-
209
- axis = $(this.handles[i], this.element);
210
-
211
- padWrapper = /sw|ne|nw|se|n|s/.test(i) ? axis.outerHeight() : axis.outerWidth();
212
-
213
- padPos = [ "padding",
214
- /ne|nw|n/.test(i) ? "Top" :
215
- /se|sw|s/.test(i) ? "Bottom" :
216
- /^e$/.test(i) ? "Right" : "Left" ].join("");
217
-
218
- target.css(padPos, padWrapper);
219
-
220
- this._proportionallyResize();
221
-
222
- }
223
-
224
- // TODO: What's that good for? There's not anything to be executed left
225
- if (!$(this.handles[i]).length) {
226
- continue;
227
- }
228
- }
229
- };
230
-
231
- // TODO: make renderAxis a prototype function
232
- this._renderAxis(this.element);
233
-
234
- this._handles = $(".ui-resizable-handle", this.element)
235
- .disableSelection();
236
-
237
- this._handles.mouseover(function() {
238
- if (!that.resizing) {
239
- if (this.className) {
240
- axis = this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i);
241
- }
242
- that.axis = axis && axis[1] ? axis[1] : "se";
243
- }
244
- });
245
-
246
- if (o.autoHide) {
247
- this._handles.hide();
248
- $(this.element)
249
- .addClass("ui-resizable-autohide")
250
- .mouseenter(function() {
251
- if (o.disabled) {
252
- return;
253
- }
254
- $(this).removeClass("ui-resizable-autohide");
255
- that._handles.show();
256
- })
257
- .mouseleave(function() {
258
- if (o.disabled) {
259
- return;
260
- }
261
- if (!that.resizing) {
262
- $(this).addClass("ui-resizable-autohide");
263
- that._handles.hide();
264
- }
265
- });
266
- }
267
-
268
- this._mouseInit();
269
-
270
- },
271
-
272
- _destroy: function() {
273
-
274
- this._mouseDestroy();
275
-
276
- var wrapper,
277
- _destroy = function(exp) {
278
- $(exp)
279
- .removeClass("ui-resizable ui-resizable-disabled ui-resizable-resizing")
280
- .removeData("resizable")
281
- .removeData("ui-resizable")
282
- .unbind(".resizable")
283
- .find(".ui-resizable-handle")
284
- .remove();
285
- };
286
-
287
- // TODO: Unwrap at same DOM position
288
- if (this.elementIsWrapper) {
289
- _destroy(this.element);
290
- wrapper = this.element;
291
- this.originalElement.css({
292
- position: wrapper.css("position"),
293
- width: wrapper.outerWidth(),
294
- height: wrapper.outerHeight(),
295
- top: wrapper.css("top"),
296
- left: wrapper.css("left")
297
- }).insertAfter( wrapper );
298
- wrapper.remove();
299
- }
300
-
301
- this.originalElement.css("resize", this.originalResizeStyle);
302
- _destroy(this.originalElement);
303
-
304
- return this;
305
- },
306
-
307
- _mouseCapture: function(event) {
308
- var i, handle,
309
- capture = false;
310
-
311
- for (i in this.handles) {
312
- handle = $(this.handles[i])[0];
313
- if (handle === event.target || $.contains(handle, event.target)) {
314
- capture = true;
315
- }
316
- }
317
-
318
- return !this.options.disabled && capture;
319
- },
320
-
321
- _mouseStart: function(event) {
322
-
323
- var curleft, curtop, cursor,
324
- o = this.options,
325
- el = this.element;
326
-
327
- this.resizing = true;
328
-
329
- this._renderProxy();
330
-
331
- curleft = this._num(this.helper.css("left"));
332
- curtop = this._num(this.helper.css("top"));
333
-
334
- if (o.containment) {
335
- curleft += $(o.containment).scrollLeft() || 0;
336
- curtop += $(o.containment).scrollTop() || 0;
337
- }
338
-
339
- this.offset = this.helper.offset();
340
- this.position = { left: curleft, top: curtop };
341
-
342
- this.size = this._helper ? {
343
- width: this.helper.width(),
344
- height: this.helper.height()
345
- } : {
346
- width: el.width(),
347
- height: el.height()
348
- };
349
-
350
- this.originalSize = this._helper ? {
351
- width: el.outerWidth(),
352
- height: el.outerHeight()
353
- } : {
354
- width: el.width(),
355
- height: el.height()
356
- };
357
-
358
- this.sizeDiff = {
359
- width: el.outerWidth() - el.width(),
360
- height: el.outerHeight() - el.height()
361
- };
362
-
363
- this.originalPosition = { left: curleft, top: curtop };
364
- this.originalMousePosition = { left: event.pageX, top: event.pageY };
365
-
366
- this.aspectRatio = (typeof o.aspectRatio === "number") ?
367
- o.aspectRatio :
368
- ((this.originalSize.width / this.originalSize.height) || 1);
369
-
370
- cursor = $(".ui-resizable-" + this.axis).css("cursor");
371
- $("body").css("cursor", cursor === "auto" ? this.axis + "-resize" : cursor);
372
-
373
- el.addClass("ui-resizable-resizing");
374
- this._propagate("start", event);
375
- return true;
376
- },
377
-
378
- _mouseDrag: function(event) {
379
-
380
- var data, props,
381
- smp = this.originalMousePosition,
382
- a = this.axis,
383
- dx = (event.pageX - smp.left) || 0,
384
- dy = (event.pageY - smp.top) || 0,
385
- trigger = this._change[a];
386
-
387
- this._updatePrevProperties();
388
-
389
- if (!trigger) {
390
- return false;
391
- }
392
-
393
- data = trigger.apply(this, [ event, dx, dy ]);
394
-
395
- this._updateVirtualBoundaries(event.shiftKey);
396
- if (this._aspectRatio || event.shiftKey) {
397
- data = this._updateRatio(data, event);
398
- }
399
-
400
- data = this._respectSize(data, event);
401
-
402
- this._updateCache(data);
403
-
404
- this._propagate("resize", event);
405
-
406
- props = this._applyChanges();
407
-
408
- if ( !this._helper && this._proportionallyResizeElements.length ) {
409
- this._proportionallyResize();
410
- }
411
-
412
- if ( !$.isEmptyObject( props ) ) {
413
- this._updatePrevProperties();
414
- this._trigger( "resize", event, this.ui() );
415
- this._applyChanges();
416
- }
417
-
418
- return false;
419
- },
420
-
421
- _mouseStop: function(event) {
422
-
423
- this.resizing = false;
424
- var pr, ista, soffseth, soffsetw, s, left, top,
425
- o = this.options, that = this;
426
-
427
- if (this._helper) {
428
-
429
- pr = this._proportionallyResizeElements;
430
- ista = pr.length && (/textarea/i).test(pr[0].nodeName);
431
- soffseth = ista && this._hasScroll(pr[0], "left") ? 0 : that.sizeDiff.height;
432
- soffsetw = ista ? 0 : that.sizeDiff.width;
433
-
434
- s = {
435
- width: (that.helper.width() - soffsetw),
436
- height: (that.helper.height() - soffseth)
437
- };
438
- left = (parseInt(that.element.css("left"), 10) +
439
- (that.position.left - that.originalPosition.left)) || null;
440
- top = (parseInt(that.element.css("top"), 10) +
441
- (that.position.top - that.originalPosition.top)) || null;
442
-
443
- if (!o.animate) {
444
- this.element.css($.extend(s, { top: top, left: left }));
445
- }
446
-
447
- that.helper.height(that.size.height);
448
- that.helper.width(that.size.width);
449
-
450
- if (this._helper && !o.animate) {
451
- this._proportionallyResize();
452
- }
453
- }
454
-
455
- $("body").css("cursor", "auto");
456
-
457
- this.element.removeClass("ui-resizable-resizing");
458
-
459
- this._propagate("stop", event);
460
-
461
- if (this._helper) {
462
- this.helper.remove();
463
- }
464
-
465
- return false;
466
-
467
- },
468
-
469
- _updatePrevProperties: function() {
470
- this.prevPosition = {
471
- top: this.position.top,
472
- left: this.position.left
473
- };
474
- this.prevSize = {
475
- width: this.size.width,
476
- height: this.size.height
477
- };
478
- },
479
-
480
- _applyChanges: function() {
481
- var props = {};
482
-
483
- if ( this.position.top !== this.prevPosition.top ) {
484
- props.top = this.position.top + "px";
485
- }
486
- if ( this.position.left !== this.prevPosition.left ) {
487
- props.left = this.position.left + "px";
488
- }
489
- if ( this.size.width !== this.prevSize.width ) {
490
- props.width = this.size.width + "px";
491
- }
492
- if ( this.size.height !== this.prevSize.height ) {
493
- props.height = this.size.height + "px";
494
- }
495
-
496
- this.helper.css( props );
497
-
498
- return props;
499
- },
500
-
501
- _updateVirtualBoundaries: function(forceAspectRatio) {
502
- var pMinWidth, pMaxWidth, pMinHeight, pMaxHeight, b,
503
- o = this.options;
504
-
505
- b = {
506
- minWidth: this._isNumber(o.minWidth) ? o.minWidth : 0,
507
- maxWidth: this._isNumber(o.maxWidth) ? o.maxWidth : Infinity,
508
- minHeight: this._isNumber(o.minHeight) ? o.minHeight : 0,
509
- maxHeight: this._isNumber(o.maxHeight) ? o.maxHeight : Infinity
510
- };
511
-
512
- if (this._aspectRatio || forceAspectRatio) {
513
- pMinWidth = b.minHeight * this.aspectRatio;
514
- pMinHeight = b.minWidth / this.aspectRatio;
515
- pMaxWidth = b.maxHeight * this.aspectRatio;
516
- pMaxHeight = b.maxWidth / this.aspectRatio;
517
-
518
- if (pMinWidth > b.minWidth) {
519
- b.minWidth = pMinWidth;
520
- }
521
- if (pMinHeight > b.minHeight) {
522
- b.minHeight = pMinHeight;
523
- }
524
- if (pMaxWidth < b.maxWidth) {
525
- b.maxWidth = pMaxWidth;
526
- }
527
- if (pMaxHeight < b.maxHeight) {
528
- b.maxHeight = pMaxHeight;
529
- }
530
- }
531
- this._vBoundaries = b;
532
- },
533
-
534
- _updateCache: function(data) {
535
- this.offset = this.helper.offset();
536
- if (this._isNumber(data.left)) {
537
- this.position.left = data.left;
538
- }
539
- if (this._isNumber(data.top)) {
540
- this.position.top = data.top;
541
- }
542
- if (this._isNumber(data.height)) {
543
- this.size.height = data.height;
544
- }
545
- if (this._isNumber(data.width)) {
546
- this.size.width = data.width;
547
- }
548
- },
549
-
550
- _updateRatio: function( data ) {
551
-
552
- var cpos = this.position,
553
- csize = this.size,
554
- a = this.axis;
555
-
556
- if (this._isNumber(data.height)) {
557
- data.width = (data.height * this.aspectRatio);
558
- } else if (this._isNumber(data.width)) {
559
- data.height = (data.width / this.aspectRatio);
560
- }
561
-
562
- if (a === "sw") {
563
- data.left = cpos.left + (csize.width - data.width);
564
- data.top = null;
565
- }
566
- if (a === "nw") {
567
- data.top = cpos.top + (csize.height - data.height);
568
- data.left = cpos.left + (csize.width - data.width);
569
- }
570
-
571
- return data;
572
- },
573
-
574
- _respectSize: function( data ) {
575
-
576
- var o = this._vBoundaries,
577
- a = this.axis,
578
- ismaxw = this._isNumber(data.width) && o.maxWidth && (o.maxWidth < data.width),
579
- ismaxh = this._isNumber(data.height) && o.maxHeight && (o.maxHeight < data.height),
580
- isminw = this._isNumber(data.width) && o.minWidth && (o.minWidth > data.width),
581
- isminh = this._isNumber(data.height) && o.minHeight && (o.minHeight > data.height),
582
- dw = this.originalPosition.left + this.originalSize.width,
583
- dh = this.position.top + this.size.height,
584
- cw = /sw|nw|w/.test(a), ch = /nw|ne|n/.test(a);
585
- if (isminw) {
586
- data.width = o.minWidth;
587
- }
588
- if (isminh) {
589
- data.height = o.minHeight;
590
- }
591
- if (ismaxw) {
592
- data.width = o.maxWidth;
593
- }
594
- if (ismaxh) {
595
- data.height = o.maxHeight;
596
- }
597
-
598
- if (isminw && cw) {
599
- data.left = dw - o.minWidth;
600
- }
601
- if (ismaxw && cw) {
602
- data.left = dw - o.maxWidth;
603
- }
604
- if (isminh && ch) {
605
- data.top = dh - o.minHeight;
606
- }
607
- if (ismaxh && ch) {
608
- data.top = dh - o.maxHeight;
609
- }
610
-
611
- // Fixing jump error on top/left - bug #2330
612
- if (!data.width && !data.height && !data.left && data.top) {
613
- data.top = null;
614
- } else if (!data.width && !data.height && !data.top && data.left) {
615
- data.left = null;
616
- }
617
-
618
- return data;
619
- },
620
-
621
- _getPaddingPlusBorderDimensions: function( element ) {
622
- var i = 0,
623
- widths = [],
624
- borders = [
625
- element.css( "borderTopWidth" ),
626
- element.css( "borderRightWidth" ),
627
- element.css( "borderBottomWidth" ),
628
- element.css( "borderLeftWidth" )
629
- ],
630
- paddings = [
631
- element.css( "paddingTop" ),
632
- element.css( "paddingRight" ),
633
- element.css( "paddingBottom" ),
634
- element.css( "paddingLeft" )
635
- ];
636
-
637
- for ( ; i < 4; i++ ) {
638
- widths[ i ] = ( parseInt( borders[ i ], 10 ) || 0 );
639
- widths[ i ] += ( parseInt( paddings[ i ], 10 ) || 0 );
640
- }
641
-
642
- return {
643
- height: widths[ 0 ] + widths[ 2 ],
644
- width: widths[ 1 ] + widths[ 3 ]
645
- };
646
- },
647
-
648
- _proportionallyResize: function() {
649
-
650
- if (!this._proportionallyResizeElements.length) {
651
- return;
652
- }
653
-
654
- var prel,
655
- i = 0,
656
- element = this.helper || this.element;
657
-
658
- for ( ; i < this._proportionallyResizeElements.length; i++) {
659
-
660
- prel = this._proportionallyResizeElements[i];
661
-
662
- // TODO: Seems like a bug to cache this.outerDimensions
663
- // considering that we are in a loop.
664
- if (!this.outerDimensions) {
665
- this.outerDimensions = this._getPaddingPlusBorderDimensions( prel );
666
- }
667
-
668
- prel.css({
669
- height: (element.height() - this.outerDimensions.height) || 0,
670
- width: (element.width() - this.outerDimensions.width) || 0
671
- });
672
-
673
- }
674
-
675
- },
676
-
677
- _renderProxy: function() {
678
-
679
- var el = this.element, o = this.options;
680
- this.elementOffset = el.offset();
681
-
682
- if (this._helper) {
683
-
684
- this.helper = this.helper || $("<div style='overflow:hidden;'></div>");
685
-
686
- this.helper.addClass(this._helper).css({
687
- width: this.element.outerWidth() - 1,
688
- height: this.element.outerHeight() - 1,
689
- position: "absolute",
690
- left: this.elementOffset.left + "px",
691
- top: this.elementOffset.top + "px",
692
- zIndex: ++o.zIndex //TODO: Don't modify option
693
- });
694
-
695
- this.helper
696
- .appendTo("body")
697
- .disableSelection();
698
-
699
- } else {
700
- this.helper = this.element;
701
- }
702
-
703
- },
704
-
705
- _change: {
706
- e: function(event, dx) {
707
- return { width: this.originalSize.width + dx };
708
- },
709
- w: function(event, dx) {
710
- var cs = this.originalSize, sp = this.originalPosition;
711
- return { left: sp.left + dx, width: cs.width - dx };
712
- },
713
- n: function(event, dx, dy) {
714
- var cs = this.originalSize, sp = this.originalPosition;
715
- return { top: sp.top + dy, height: cs.height - dy };
716
- },
717
- s: function(event, dx, dy) {
718
- return { height: this.originalSize.height + dy };
719
- },
720
- se: function(event, dx, dy) {
721
- return $.extend(this._change.s.apply(this, arguments),
722
- this._change.e.apply(this, [ event, dx, dy ]));
723
- },
724
- sw: function(event, dx, dy) {
725
- return $.extend(this._change.s.apply(this, arguments),
726
- this._change.w.apply(this, [ event, dx, dy ]));
727
- },
728
- ne: function(event, dx, dy) {
729
- return $.extend(this._change.n.apply(this, arguments),
730
- this._change.e.apply(this, [ event, dx, dy ]));
731
- },
732
- nw: function(event, dx, dy) {
733
- return $.extend(this._change.n.apply(this, arguments),
734
- this._change.w.apply(this, [ event, dx, dy ]));
735
- }
736
- },
737
-
738
- _propagate: function(n, event) {
739
- $.ui.plugin.call(this, n, [ event, this.ui() ]);
740
- (n !== "resize" && this._trigger(n, event, this.ui()));
741
- },
742
-
743
- plugins: {},
744
-
745
- ui: function() {
746
- return {
747
- originalElement: this.originalElement,
748
- element: this.element,
749
- helper: this.helper,
750
- position: this.position,
751
- size: this.size,
752
- originalSize: this.originalSize,
753
- originalPosition: this.originalPosition
754
- };
755
- }
756
-
757
- });
758
-
759
- /*
760
- * Resizable Extensions
761
- */
762
-
763
- $.ui.plugin.add("resizable", "animate", {
764
-
765
- stop: function( event ) {
766
- var that = $(this).resizable( "instance" ),
767
- o = that.options,
768
- pr = that._proportionallyResizeElements,
769
- ista = pr.length && (/textarea/i).test(pr[0].nodeName),
770
- soffseth = ista && that._hasScroll(pr[0], "left") ? 0 : that.sizeDiff.height,
771
- soffsetw = ista ? 0 : that.sizeDiff.width,
772
- style = { width: (that.size.width - soffsetw), height: (that.size.height - soffseth) },
773
- left = (parseInt(that.element.css("left"), 10) +
774
- (that.position.left - that.originalPosition.left)) || null,
775
- top = (parseInt(that.element.css("top"), 10) +
776
- (that.position.top - that.originalPosition.top)) || null;
777
-
778
- that.element.animate(
779
- $.extend(style, top && left ? { top: top, left: left } : {}), {
780
- duration: o.animateDuration,
781
- easing: o.animateEasing,
782
- step: function() {
783
-
784
- var data = {
785
- width: parseInt(that.element.css("width"), 10),
786
- height: parseInt(that.element.css("height"), 10),
787
- top: parseInt(that.element.css("top"), 10),
788
- left: parseInt(that.element.css("left"), 10)
789
- };
790
-
791
- if (pr && pr.length) {
792
- $(pr[0]).css({ width: data.width, height: data.height });
793
- }
794
-
795
- // propagating resize, and updating values for each animation step
796
- that._updateCache(data);
797
- that._propagate("resize", event);
798
-
799
- }
800
- }
801
- );
802
- }
803
-
804
- });
805
-
806
- $.ui.plugin.add( "resizable", "containment", {
807
-
808
- start: function() {
809
- var element, p, co, ch, cw, width, height,
810
- that = $( this ).resizable( "instance" ),
811
- o = that.options,
812
- el = that.element,
813
- oc = o.containment,
814
- ce = ( oc instanceof $ ) ? oc.get( 0 ) : ( /parent/.test( oc ) ) ? el.parent().get( 0 ) : oc;
815
-
816
- if ( !ce ) {
817
- return;
818
- }
819
-
820
- that.containerElement = $( ce );
821
-
822
- if ( /document/.test( oc ) || oc === document ) {
823
- that.containerOffset = {
824
- left: 0,
825
- top: 0
826
- };
827
- that.containerPosition = {
828
- left: 0,
829
- top: 0
830
- };
831
-
832
- that.parentData = {
833
- element: $( document ),
834
- left: 0,
835
- top: 0,
836
- width: $( document ).width(),
837
- height: $( document ).height() || document.body.parentNode.scrollHeight
838
- };
839
- } else {
840
- element = $( ce );
841
- p = [];
842
- $([ "Top", "Right", "Left", "Bottom" ]).each(function( i, name ) {
843
- p[ i ] = that._num( element.css( "padding" + name ) );
844
- });
845
-
846
- that.containerOffset = element.offset();
847
- that.containerPosition = element.position();
848
- that.containerSize = {
849
- height: ( element.innerHeight() - p[ 3 ] ),
850
- width: ( element.innerWidth() - p[ 1 ] )
851
- };
852
-
853
- co = that.containerOffset;
854
- ch = that.containerSize.height;
855
- cw = that.containerSize.width;
856
- width = ( that._hasScroll ( ce, "left" ) ? ce.scrollWidth : cw );
857
- height = ( that._hasScroll ( ce ) ? ce.scrollHeight : ch ) ;
858
-
859
- that.parentData = {
860
- element: ce,
861
- left: co.left,
862
- top: co.top,
863
- width: width,
864
- height: height
865
- };
866
- }
867
- },
868
-
869
- resize: function( event ) {
870
- var woset, hoset, isParent, isOffsetRelative,
871
- that = $( this ).resizable( "instance" ),
872
- o = that.options,
873
- co = that.containerOffset,
874
- cp = that.position,
875
- pRatio = that._aspectRatio || event.shiftKey,
876
- cop = {
877
- top: 0,
878
- left: 0
879
- },
880
- ce = that.containerElement,
881
- continueResize = true;
882
-
883
- if ( ce[ 0 ] !== document && ( /static/ ).test( ce.css( "position" ) ) ) {
884
- cop = co;
885
- }
886
-
887
- if ( cp.left < ( that._helper ? co.left : 0 ) ) {
888
- that.size.width = that.size.width +
889
- ( that._helper ?
890
- ( that.position.left - co.left ) :
891
- ( that.position.left - cop.left ) );
892
-
893
- if ( pRatio ) {
894
- that.size.height = that.size.width / that.aspectRatio;
895
- continueResize = false;
896
- }
897
- that.position.left = o.helper ? co.left : 0;
898
- }
899
-
900
- if ( cp.top < ( that._helper ? co.top : 0 ) ) {
901
- that.size.height = that.size.height +
902
- ( that._helper ?
903
- ( that.position.top - co.top ) :
904
- that.position.top );
905
-
906
- if ( pRatio ) {
907
- that.size.width = that.size.height * that.aspectRatio;
908
- continueResize = false;
909
- }
910
- that.position.top = that._helper ? co.top : 0;
911
- }
912
-
913
- isParent = that.containerElement.get( 0 ) === that.element.parent().get( 0 );
914
- isOffsetRelative = /relative|absolute/.test( that.containerElement.css( "position" ) );
915
-
916
- if ( isParent && isOffsetRelative ) {
917
- that.offset.left = that.parentData.left + that.position.left;
918
- that.offset.top = that.parentData.top + that.position.top;
919
- } else {
920
- that.offset.left = that.element.offset().left;
921
- that.offset.top = that.element.offset().top;
922
- }
923
-
924
- woset = Math.abs( that.sizeDiff.width +
925
- (that._helper ?
926
- that.offset.left - cop.left :
927
- (that.offset.left - co.left)) );
928
-
929
- hoset = Math.abs( that.sizeDiff.height +
930
- (that._helper ?
931
- that.offset.top - cop.top :
932
- (that.offset.top - co.top)) );
933
-
934
- if ( woset + that.size.width >= that.parentData.width ) {
935
- that.size.width = that.parentData.width - woset;
936
- if ( pRatio ) {
937
- that.size.height = that.size.width / that.aspectRatio;
938
- continueResize = false;
939
- }
940
- }
941
-
942
- if ( hoset + that.size.height >= that.parentData.height ) {
943
- that.size.height = that.parentData.height - hoset;
944
- if ( pRatio ) {
945
- that.size.width = that.size.height * that.aspectRatio;
946
- continueResize = false;
947
- }
948
- }
949
-
950
- if ( !continueResize ) {
951
- that.position.left = that.prevPosition.left;
952
- that.position.top = that.prevPosition.top;
953
- that.size.width = that.prevSize.width;
954
- that.size.height = that.prevSize.height;
955
- }
956
- },
957
-
958
- stop: function() {
959
- var that = $( this ).resizable( "instance" ),
960
- o = that.options,
961
- co = that.containerOffset,
962
- cop = that.containerPosition,
963
- ce = that.containerElement,
964
- helper = $( that.helper ),
965
- ho = helper.offset(),
966
- w = helper.outerWidth() - that.sizeDiff.width,
967
- h = helper.outerHeight() - that.sizeDiff.height;
968
-
969
- if ( that._helper && !o.animate && ( /relative/ ).test( ce.css( "position" ) ) ) {
970
- $( this ).css({
971
- left: ho.left - cop.left - co.left,
972
- width: w,
973
- height: h
974
- });
975
- }
976
-
977
- if ( that._helper && !o.animate && ( /static/ ).test( ce.css( "position" ) ) ) {
978
- $( this ).css({
979
- left: ho.left - cop.left - co.left,
980
- width: w,
981
- height: h
982
- });
983
- }
984
- }
985
- });
986
-
987
- $.ui.plugin.add("resizable", "alsoResize", {
988
-
989
- start: function() {
990
- var that = $(this).resizable( "instance" ),
991
- o = that.options,
992
- _store = function(exp) {
993
- $(exp).each(function() {
994
- var el = $(this);
995
- el.data("ui-resizable-alsoresize", {
996
- width: parseInt(el.width(), 10), height: parseInt(el.height(), 10),
997
- left: parseInt(el.css("left"), 10), top: parseInt(el.css("top"), 10)
998
- });
999
- });
1000
- };
1001
-
1002
- if (typeof(o.alsoResize) === "object" && !o.alsoResize.parentNode) {
1003
- if (o.alsoResize.length) {
1004
- o.alsoResize = o.alsoResize[0];
1005
- _store(o.alsoResize);
1006
- } else {
1007
- $.each(o.alsoResize, function(exp) {
1008
- _store(exp);
1009
- });
1010
- }
1011
- } else {
1012
- _store(o.alsoResize);
1013
- }
1014
- },
1015
-
1016
- resize: function(event, ui) {
1017
- var that = $(this).resizable( "instance" ),
1018
- o = that.options,
1019
- os = that.originalSize,
1020
- op = that.originalPosition,
1021
- delta = {
1022
- height: (that.size.height - os.height) || 0,
1023
- width: (that.size.width - os.width) || 0,
1024
- top: (that.position.top - op.top) || 0,
1025
- left: (that.position.left - op.left) || 0
1026
- },
1027
-
1028
- _alsoResize = function(exp, c) {
1029
- $(exp).each(function() {
1030
- var el = $(this), start = $(this).data("ui-resizable-alsoresize"), style = {},
1031
- css = c && c.length ?
1032
- c :
1033
- el.parents(ui.originalElement[0]).length ?
1034
- [ "width", "height" ] :
1035
- [ "width", "height", "top", "left" ];
1036
-
1037
- $.each(css, function(i, prop) {
1038
- var sum = (start[prop] || 0) + (delta[prop] || 0);
1039
- if (sum && sum >= 0) {
1040
- style[prop] = sum || null;
1041
- }
1042
- });
1043
-
1044
- el.css(style);
1045
- });
1046
- };
1047
-
1048
- if (typeof(o.alsoResize) === "object" && !o.alsoResize.nodeType) {
1049
- $.each(o.alsoResize, function(exp, c) {
1050
- _alsoResize(exp, c);
1051
- });
1052
- } else {
1053
- _alsoResize(o.alsoResize);
1054
- }
1055
- },
1056
-
1057
- stop: function() {
1058
- $(this).removeData("resizable-alsoresize");
1059
- }
1060
- });
1061
-
1062
- $.ui.plugin.add("resizable", "ghost", {
1063
-
1064
- start: function() {
1065
-
1066
- var that = $(this).resizable( "instance" ), o = that.options, cs = that.size;
1067
-
1068
- that.ghost = that.originalElement.clone();
1069
- that.ghost
1070
- .css({
1071
- opacity: 0.25,
1072
- display: "block",
1073
- position: "relative",
1074
- height: cs.height,
1075
- width: cs.width,
1076
- margin: 0,
1077
- left: 0,
1078
- top: 0
1079
- })
1080
- .addClass("ui-resizable-ghost")
1081
- .addClass(typeof o.ghost === "string" ? o.ghost : "");
1082
-
1083
- that.ghost.appendTo(that.helper);
1084
-
1085
- },
1086
-
1087
- resize: function() {
1088
- var that = $(this).resizable( "instance" );
1089
- if (that.ghost) {
1090
- that.ghost.css({
1091
- position: "relative",
1092
- height: that.size.height,
1093
- width: that.size.width
1094
- });
1095
- }
1096
- },
1097
-
1098
- stop: function() {
1099
- var that = $(this).resizable( "instance" );
1100
- if (that.ghost && that.helper) {
1101
- that.helper.get(0).removeChild(that.ghost.get(0));
1102
- }
1103
- }
1104
-
1105
- });
1106
-
1107
- $.ui.plugin.add("resizable", "grid", {
1108
-
1109
- resize: function() {
1110
- var outerDimensions,
1111
- that = $(this).resizable( "instance" ),
1112
- o = that.options,
1113
- cs = that.size,
1114
- os = that.originalSize,
1115
- op = that.originalPosition,
1116
- a = that.axis,
1117
- grid = typeof o.grid === "number" ? [ o.grid, o.grid ] : o.grid,
1118
- gridX = (grid[0] || 1),
1119
- gridY = (grid[1] || 1),
1120
- ox = Math.round((cs.width - os.width) / gridX) * gridX,
1121
- oy = Math.round((cs.height - os.height) / gridY) * gridY,
1122
- newWidth = os.width + ox,
1123
- newHeight = os.height + oy,
1124
- isMaxWidth = o.maxWidth && (o.maxWidth < newWidth),
1125
- isMaxHeight = o.maxHeight && (o.maxHeight < newHeight),
1126
- isMinWidth = o.minWidth && (o.minWidth > newWidth),
1127
- isMinHeight = o.minHeight && (o.minHeight > newHeight);
1128
-
1129
- o.grid = grid;
1130
-
1131
- if (isMinWidth) {
1132
- newWidth += gridX;
1133
- }
1134
- if (isMinHeight) {
1135
- newHeight += gridY;
1136
- }
1137
- if (isMaxWidth) {
1138
- newWidth -= gridX;
1139
- }
1140
- if (isMaxHeight) {
1141
- newHeight -= gridY;
1142
- }
1143
-
1144
- if (/^(se|s|e)$/.test(a)) {
1145
- that.size.width = newWidth;
1146
- that.size.height = newHeight;
1147
- } else if (/^(ne)$/.test(a)) {
1148
- that.size.width = newWidth;
1149
- that.size.height = newHeight;
1150
- that.position.top = op.top - oy;
1151
- } else if (/^(sw)$/.test(a)) {
1152
- that.size.width = newWidth;
1153
- that.size.height = newHeight;
1154
- that.position.left = op.left - ox;
1155
- } else {
1156
- if ( newHeight - gridY <= 0 || newWidth - gridX <= 0) {
1157
- outerDimensions = that._getPaddingPlusBorderDimensions( this );
1158
- }
1159
-
1160
- if ( newHeight - gridY > 0 ) {
1161
- that.size.height = newHeight;
1162
- that.position.top = op.top - oy;
1163
- } else {
1164
- newHeight = gridY - outerDimensions.height;
1165
- that.size.height = newHeight;
1166
- that.position.top = op.top + os.height - newHeight;
1167
- }
1168
- if ( newWidth - gridX > 0 ) {
1169
- that.size.width = newWidth;
1170
- that.position.left = op.left - ox;
1171
- } else {
1172
- newWidth = gridX - outerDimensions.width;
1173
- that.size.width = newWidth;
1174
- that.position.left = op.left + os.width - newWidth;
1175
- }
1176
- }
1177
- }
1178
-
1179
- });
1180
-
1181
- return $.ui.resizable;
1182
-
1183
- }));