locomotive-aloha-rails 0.20.1.5 → 0.23.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (1280) hide show
  1. data/README.md +4 -4
  2. data/Rakefile +15 -6
  3. data/app/assets/javascripts/aloha.js +1 -0
  4. data/lib/aloha/rails/engine.rb +1 -1
  5. data/lib/aloha/rails/version.rb +2 -2
  6. data/vendor/assets/javascripts/aloha/css/aloha-common-extra.css +24 -0
  7. data/vendor/assets/javascripts/aloha/css/aloha-core.css +4 -29
  8. data/vendor/assets/javascripts/aloha/css/aloha-reset.css +24 -0
  9. data/vendor/assets/javascripts/aloha/css/aloha-sidebar.css +77 -89
  10. data/vendor/assets/javascripts/aloha/css/aloha.css +31 -7777
  11. data/vendor/assets/javascripts/aloha/img/arrow-down.png +0 -0
  12. data/vendor/assets/javascripts/aloha/img/arrow-left.png +0 -0
  13. data/vendor/assets/javascripts/aloha/img/arrow.png +0 -0
  14. data/vendor/assets/javascripts/aloha/img/base-multi.png +0 -0
  15. data/vendor/assets/javascripts/aloha/img/base.png +0 -0
  16. data/vendor/assets/javascripts/aloha/img/bg.png +0 -0
  17. data/vendor/assets/javascripts/aloha/img/breadcrumb-divider.png +0 -0
  18. data/vendor/assets/javascripts/aloha/img/gentics-logo.png +0 -0
  19. data/vendor/assets/javascripts/aloha/img/grabhandle.png +0 -0
  20. data/vendor/assets/javascripts/aloha/img/maximize.png +0 -0
  21. data/vendor/assets/javascripts/aloha/img/multisplit-base.jpg +0 -0
  22. data/vendor/assets/javascripts/aloha/img/multisplit-close.gif +0 -0
  23. data/vendor/assets/javascripts/aloha/img/multisplit-open.gif +0 -0
  24. data/vendor/assets/javascripts/aloha/img/pin.png +0 -0
  25. data/vendor/assets/javascripts/aloha/img/removeformat.png +0 -0
  26. data/vendor/assets/javascripts/aloha/img/text_indent.png +0 -0
  27. data/vendor/assets/javascripts/aloha/img/text_indent_remove.png +0 -0
  28. data/vendor/assets/javascripts/aloha/lib/aloha-jquery-noconflict.js +12 -0
  29. data/vendor/assets/javascripts/aloha/lib/aloha.js +532 -89342
  30. data/vendor/assets/javascripts/aloha/lib/aloha/block-jump.js +153 -0
  31. data/vendor/assets/javascripts/aloha/lib/aloha/command.js +161 -123
  32. data/vendor/assets/javascripts/aloha/lib/aloha/console.js +312 -295
  33. data/vendor/assets/javascripts/aloha/lib/aloha/contenthandlermanager.js +82 -44
  34. data/vendor/assets/javascripts/aloha/lib/aloha/copypaste.js +108 -0
  35. data/vendor/assets/javascripts/aloha/lib/aloha/core.js +453 -410
  36. data/vendor/assets/javascripts/aloha/lib/aloha/ecma5shims.js +307 -277
  37. data/vendor/assets/javascripts/aloha/lib/aloha/editable.js +548 -408
  38. data/vendor/assets/javascripts/aloha/lib/aloha/engine.js +7359 -7182
  39. data/vendor/assets/javascripts/aloha/lib/aloha/ephemera.js +485 -0
  40. data/vendor/assets/javascripts/aloha/lib/aloha/ierange-m2.js +28 -545
  41. data/vendor/assets/javascripts/aloha/lib/aloha/jquery.aloha.js +364 -146
  42. data/vendor/assets/javascripts/aloha/lib/aloha/markup.js +1272 -1255
  43. data/vendor/assets/javascripts/aloha/lib/aloha/nls/ca/i18n.js +11 -0
  44. data/vendor/assets/javascripts/aloha/lib/aloha/nls/de/i18n.js +11 -10
  45. data/vendor/assets/javascripts/aloha/lib/aloha/nls/i18n.js +19 -19
  46. data/vendor/assets/javascripts/aloha/lib/aloha/nls/mk/i18n.js +11 -0
  47. data/vendor/assets/javascripts/aloha/lib/aloha/nls/pt-br/i18n.js +11 -0
  48. data/vendor/assets/javascripts/aloha/lib/aloha/nls/ru/i18n.js +11 -0
  49. data/vendor/assets/javascripts/aloha/lib/aloha/nls/uk/i18n.js +11 -0
  50. data/vendor/assets/javascripts/aloha/lib/aloha/nls/zh-hans/i18n.js +11 -0
  51. data/vendor/assets/javascripts/aloha/lib/aloha/observable.js +43 -36
  52. data/vendor/assets/javascripts/aloha/lib/aloha/plugin.js +80 -75
  53. data/vendor/assets/javascripts/aloha/lib/aloha/pluginmanager.js +146 -97
  54. data/vendor/assets/javascripts/aloha/lib/aloha/rangy-core.js +30 -3242
  55. data/vendor/assets/javascripts/aloha/lib/aloha/registry.js +102 -24
  56. data/vendor/assets/javascripts/aloha/lib/aloha/repository.js +137 -123
  57. data/vendor/assets/javascripts/aloha/lib/aloha/repositorymanager.js +742 -571
  58. data/vendor/assets/javascripts/aloha/lib/aloha/repositoryobjects.js +77 -61
  59. data/vendor/assets/javascripts/aloha/lib/aloha/selection.js +2402 -2102
  60. data/vendor/assets/javascripts/aloha/lib/aloha/sidebar.js +566 -664
  61. data/vendor/assets/javascripts/aloha/lib/aloha/state-override.js +125 -0
  62. data/vendor/assets/javascripts/aloha/lib/css.js +329 -187
  63. data/vendor/assets/javascripts/aloha/lib/i18n.js +118 -79
  64. data/vendor/assets/javascripts/aloha/lib/require.js +1424 -1384
  65. data/vendor/assets/javascripts/aloha/lib/text.js +39 -13
  66. data/vendor/assets/javascripts/aloha/lib/util/arrays.js +240 -0
  67. data/vendor/assets/javascripts/aloha/lib/util/browser.js +32 -0
  68. data/vendor/assets/javascripts/aloha/lib/util/class.js +67 -69
  69. data/vendor/assets/javascripts/aloha/lib/util/dom.js +1525 -1504
  70. data/vendor/assets/javascripts/aloha/lib/util/dom2.js +748 -0
  71. data/vendor/assets/javascripts/aloha/lib/util/functions.js +62 -0
  72. data/vendor/assets/javascripts/aloha/lib/util/html.js +121 -0
  73. data/vendor/assets/javascripts/aloha/lib/util/json2.js +240 -257
  74. data/vendor/assets/javascripts/aloha/lib/util/keys.js +65 -0
  75. data/vendor/assets/javascripts/aloha/lib/util/lang.js +89 -66
  76. data/vendor/assets/javascripts/aloha/lib/util/maps.js +108 -0
  77. data/vendor/assets/javascripts/aloha/lib/util/misc.js +51 -0
  78. data/vendor/assets/javascripts/aloha/lib/util/position.js +176 -158
  79. data/vendor/assets/javascripts/aloha/lib/util/range-context.js +528 -0
  80. data/vendor/assets/javascripts/aloha/lib/util/range.js +799 -805
  81. data/vendor/assets/javascripts/aloha/lib/util/strings.js +114 -0
  82. data/vendor/assets/javascripts/aloha/lib/util/trees.js +336 -0
  83. data/vendor/assets/javascripts/aloha/lib/vendor/3rdparty.txt +70 -0
  84. data/vendor/assets/javascripts/aloha/lib/vendor/amplify.store.js +298 -0
  85. data/vendor/assets/javascripts/aloha/lib/vendor/class.js +76 -0
  86. data/vendor/assets/javascripts/aloha/{plugins/extra/browser → lib}/vendor/grid.locale.de.js +138 -139
  87. data/vendor/assets/javascripts/aloha/{plugins/extra/browser → lib}/vendor/grid.locale.en.js +43 -44
  88. data/vendor/assets/javascripts/aloha/lib/vendor/ierange-m2.js +508 -0
  89. data/vendor/assets/javascripts/aloha/lib/vendor/{jquery-1.6.1.js → jquery-1.7.2.js} +2553 -2068
  90. data/vendor/assets/javascripts/aloha/lib/vendor/jquery-ui-1.9.0.custom-aloha.js +14711 -0
  91. data/vendor/assets/javascripts/aloha/{plugins/extra/browser/vendor/jquery.jqGrid.js → lib/vendor/jquery.jqgrid.js} +5 -3
  92. data/vendor/assets/javascripts/aloha/{plugins/extra/browser → lib}/vendor/jquery.jstree.js +4 -4
  93. data/vendor/assets/javascripts/aloha/lib/vendor/jquery.layout-1.3.0-rc30.7.js +5924 -0
  94. data/vendor/assets/javascripts/aloha/lib/vendor/pubsub/js/pubsub-unminified.js +187 -0
  95. data/vendor/assets/javascripts/aloha/lib/vendor/pubsub/js/pubsub.js +2 -0
  96. data/vendor/assets/javascripts/aloha/lib/vendor/rangy-core.js +3295 -0
  97. data/vendor/assets/javascripts/aloha/{plugins/extra/browser → lib/vendor/repository-browser}/css/jstree.css +0 -0
  98. data/vendor/assets/javascripts/aloha/{plugins/extra/browser/css/browsercombined.css → lib/vendor/repository-browser/css/repository-browser.css} +64 -60
  99. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/arrow-000-medium.png +0 -0
  100. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/arrow-180.png +0 -0
  101. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/arrow-315-medium.png +0 -0
  102. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/arrow-stop-180.png +0 -0
  103. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/arrow-stop.png +0 -0
  104. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/arrow.png +0 -0
  105. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/control-stop-square-small.png +0 -0
  106. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/folder-horizontal-open.png +0 -0
  107. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/folder-open.png +0 -0
  108. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/magnifier-left.png +0 -0
  109. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/page.png +0 -0
  110. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/picture.png +0 -0
  111. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/sort-alphabet-descending.png +0 -0
  112. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/sort-alphabet.png +0 -0
  113. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/img/throbber.gif +0 -0
  114. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/js/repository-browser-unminified.js +1450 -0
  115. data/vendor/assets/javascripts/aloha/lib/vendor/repository-browser/js/repository-browser.js +32 -0
  116. data/vendor/assets/javascripts/aloha/lib/vendor/sanitize.js +18 -7
  117. data/vendor/assets/javascripts/aloha/plugins/common/abbr/css/abbr.css +1 -0
  118. data/vendor/assets/javascripts/aloha/plugins/common/abbr/img/remabbr.png +0 -0
  119. data/vendor/assets/javascripts/aloha/plugins/common/abbr/lib/abbr-plugin.js +119 -109
  120. data/vendor/assets/javascripts/aloha/plugins/common/abbr/nls/ca/i18n.js +6 -0
  121. data/vendor/assets/javascripts/aloha/plugins/common/abbr/nls/de/i18n.js +6 -1
  122. data/vendor/assets/javascripts/aloha/plugins/common/abbr/nls/i18n.js +14 -3
  123. data/vendor/assets/javascripts/aloha/plugins/common/abbr/nls/mk/i18n.js +6 -0
  124. data/vendor/assets/javascripts/aloha/plugins/common/abbr/nls/pt-br/i18n.js +6 -0
  125. data/vendor/assets/javascripts/aloha/plugins/common/abbr/nls/ru/i18n.js +6 -0
  126. data/vendor/assets/javascripts/aloha/plugins/common/abbr/nls/uk/i18n.js +6 -0
  127. data/vendor/assets/javascripts/aloha/plugins/common/abbr/nls/zh-hans/i18n.js +6 -0
  128. data/vendor/assets/javascripts/aloha/plugins/common/abbr/package.json +0 -0
  129. data/vendor/assets/javascripts/aloha/plugins/common/align/css/align.css +17 -5
  130. data/vendor/assets/javascripts/aloha/plugins/common/align/img/align.png +0 -0
  131. data/vendor/assets/javascripts/aloha/plugins/common/align/lib/align-plugin.js +463 -353
  132. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/ca/i18n.js +6 -0
  133. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/de/i18n.js +6 -0
  134. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/i18n.js +16 -4
  135. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/mk/i18n.js +6 -0
  136. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/pt-br/i18n.js +6 -0
  137. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/ru/i18n.js +6 -0
  138. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/uk/i18n.js +6 -0
  139. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/zh-hans/i18n.js +6 -0
  140. data/vendor/assets/javascripts/aloha/plugins/common/block/css/block.css +13 -7
  141. data/vendor/assets/javascripts/aloha/plugins/common/block/lib/block-plugin.js +270 -24
  142. data/vendor/assets/javascripts/aloha/plugins/common/block/lib/block.js +268 -49
  143. data/vendor/assets/javascripts/aloha/plugins/common/block/lib/blockcontenthandler.js +27 -8
  144. data/vendor/assets/javascripts/aloha/plugins/common/block/lib/blockmanager.js +624 -479
  145. data/vendor/assets/javascripts/aloha/plugins/common/block/lib/editor.js +30 -11
  146. data/vendor/assets/javascripts/aloha/plugins/common/block/lib/editormanager.js +26 -7
  147. data/vendor/assets/javascripts/aloha/plugins/common/block/lib/sidebarattributeeditor.js +33 -13
  148. data/vendor/assets/javascripts/aloha/plugins/common/block/nls/ca/i18n.js +3 -0
  149. data/vendor/assets/javascripts/aloha/plugins/common/block/nls/de/i18n.js +3 -0
  150. data/vendor/assets/javascripts/aloha/plugins/common/block/nls/i18n.js +12 -0
  151. data/vendor/assets/javascripts/aloha/plugins/common/block/nls/mk/i18n.js +3 -0
  152. data/vendor/assets/javascripts/aloha/plugins/common/block/nls/pt-br/i18n.js +3 -0
  153. data/vendor/assets/javascripts/aloha/plugins/common/block/nls/ru/i18n.js +3 -0
  154. data/vendor/assets/javascripts/aloha/plugins/common/block/nls/uk/i18n.js +3 -0
  155. data/vendor/assets/javascripts/aloha/plugins/common/block/nls/zh-hans/i18n.js +3 -0
  156. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/css/characterpicker.css +29 -26
  157. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/img/icon.png +0 -0
  158. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/lib/characterpicker-plugin.js +445 -215
  159. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/nls/ca/i18n.js +3 -0
  160. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/nls/de/i18n.js +3 -1
  161. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/nls/i18n.js +11 -3
  162. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/nls/mk/i18n.js +3 -0
  163. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/nls/pt-br/i18n.js +3 -0
  164. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/nls/ru/i18n.js +3 -0
  165. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/nls/uk/i18n.js +3 -0
  166. data/vendor/assets/javascripts/aloha/plugins/common/characterpicker/nls/zh-hans/i18n.js +3 -0
  167. data/vendor/assets/javascripts/aloha/plugins/common/commands/css/abbr.css +0 -0
  168. data/vendor/assets/javascripts/aloha/plugins/common/commands/lib/commands-plugin.js +27 -9
  169. data/vendor/assets/javascripts/aloha/plugins/common/commands/lib/inserthtml.js +28 -9
  170. data/vendor/assets/javascripts/aloha/plugins/common/commands/package.json +0 -0
  171. data/vendor/assets/javascripts/aloha/plugins/common/contenthandler/lib/blockelementcontenthandler.js +173 -0
  172. data/vendor/assets/javascripts/aloha/plugins/common/contenthandler/lib/contenthandler-plugin.js +45 -34
  173. data/vendor/assets/javascripts/aloha/plugins/common/contenthandler/lib/contenthandler-utils.js +58 -0
  174. data/vendor/assets/javascripts/aloha/plugins/common/contenthandler/lib/genericcontenthandler.js +320 -255
  175. data/vendor/assets/javascripts/aloha/plugins/common/contenthandler/lib/oembedcontenthandler.js +420 -235
  176. data/vendor/assets/javascripts/aloha/plugins/common/contenthandler/lib/sanitizecontenthandler.js +82 -33
  177. data/vendor/assets/javascripts/aloha/plugins/common/contenthandler/lib/wordcontenthandler.js +204 -128
  178. data/vendor/assets/javascripts/aloha/plugins/common/dom-to-xhtml/lib/dom-to-xhtml-plugin.js +57 -12
  179. data/vendor/assets/javascripts/aloha/plugins/common/dom-to-xhtml/lib/dom-to-xhtml.js +186 -77
  180. data/vendor/assets/javascripts/aloha/plugins/common/format/img/em.png +0 -0
  181. data/vendor/assets/javascripts/aloha/plugins/common/format/img/strong.png +0 -0
  182. data/vendor/assets/javascripts/aloha/plugins/common/format/lib/format-plugin.js +480 -255
  183. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/ca/i18n.js +52 -0
  184. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/de/i18n.js +52 -1
  185. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/i18n.js +60 -9
  186. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/mk/i18n.js +52 -0
  187. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/pt-br/i18n.js +52 -0
  188. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/ru/i18n.js +52 -1
  189. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/uk/i18n.js +52 -0
  190. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/zh-hans/i18n.js +52 -0
  191. data/vendor/assets/javascripts/aloha/plugins/common/highlighteditables/css/highlighteditables.css +0 -0
  192. data/vendor/assets/javascripts/aloha/plugins/common/highlighteditables/lib/highlighteditables-plugin.js +43 -15
  193. data/vendor/assets/javascripts/aloha/plugins/common/highlighteditables/package.json +0 -0
  194. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/css/horizontalruler.css +2 -3
  195. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/img/icon.png +0 -0
  196. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/lib/horizontalruler-plugin.js +53 -28
  197. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/nls/ca/i18n.js +3 -0
  198. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/nls/de/i18n.js +3 -1
  199. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/nls/i18n.js +11 -3
  200. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/nls/mk/i18n.js +3 -0
  201. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/nls/pt-br/i18n.js +3 -0
  202. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/nls/ru/i18n.js +3 -0
  203. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/nls/uk/i18n.js +3 -0
  204. data/vendor/assets/javascripts/aloha/plugins/common/horizontalruler/nls/zh-hans/i18n.js +3 -0
  205. data/vendor/assets/javascripts/aloha/plugins/common/image/README.md +5 -22
  206. data/vendor/assets/javascripts/aloha/plugins/common/image/css/image.css +24 -15
  207. data/vendor/assets/javascripts/aloha/plugins/common/image/img/blank.jpg +0 -0
  208. data/vendor/assets/javascripts/aloha/plugins/common/image/img/cropnresize.png +0 -0
  209. data/vendor/assets/javascripts/aloha/plugins/common/image/img/handle-sw.png +0 -0
  210. data/vendor/assets/javascripts/aloha/plugins/common/image/img/image-align-left.png +0 -0
  211. data/vendor/assets/javascripts/aloha/plugins/common/image/img/image-align-none.png +0 -0
  212. data/vendor/assets/javascripts/aloha/plugins/common/image/img/image-align-right.png +0 -0
  213. data/vendor/assets/javascripts/aloha/plugins/common/image/img/image-border.png +0 -0
  214. data/vendor/assets/javascripts/aloha/plugins/common/image/img/image-title.png +0 -0
  215. data/vendor/assets/javascripts/aloha/plugins/common/image/img/image.gif +0 -0
  216. data/vendor/assets/javascripts/aloha/plugins/common/image/img/padding-decrease.gif +0 -0
  217. data/vendor/assets/javascripts/aloha/plugins/common/image/img/padding-increase.gif +0 -0
  218. data/vendor/assets/javascripts/aloha/plugins/common/image/img/page.png +0 -0
  219. data/vendor/assets/javascripts/aloha/plugins/common/image/img/size-decrease.gif +0 -0
  220. data/vendor/assets/javascripts/aloha/plugins/common/image/img/size-increase.gif +0 -0
  221. data/vendor/assets/javascripts/aloha/plugins/common/image/lib/image-floatingMenu.js +308 -0
  222. data/vendor/assets/javascripts/aloha/plugins/{extra/browser/README → common/image/lib/image-plugin-actions.js} +0 -0
  223. data/vendor/assets/javascripts/aloha/plugins/common/image/lib/image-plugin.js +1330 -1632
  224. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/ca/i18n.js +32 -0
  225. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/de/i18n.js +32 -1
  226. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/i18n.js +39 -5
  227. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/mk/i18n.js +32 -0
  228. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/pt-br/i18n.js +32 -0
  229. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/ru/i18n.js +32 -16
  230. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/uk/i18n.js +32 -0
  231. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/zh-hans/i18n.js +32 -0
  232. data/vendor/assets/javascripts/aloha/plugins/common/image/package.json +0 -0
  233. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/jcrop/jcrop.gif +0 -0
  234. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/jcrop/jquery.jcrop.css +0 -0
  235. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/jcrop/jquery.jcrop.min.js +3 -1
  236. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/mousewheel/mousewheel.js +42 -17
  237. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_diagonals-thick_18_b81900_40x40.png +0 -0
  238. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_diagonals-thick_20_666666_40x40.png +0 -0
  239. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_flat_10_000000_40x100.png +0 -0
  240. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_glass_100_f6f6f6_1x400.png +0 -0
  241. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_glass_100_fdf5ce_1x400.png +0 -0
  242. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  243. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_gloss-wave_35_f6a828_500x100.png +0 -0
  244. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_highlight-soft_100_eeeeee_1x100.png +0 -0
  245. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-bg_highlight-soft_75_ffe45c_1x100.png +0 -0
  246. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-icons_222222_256x240.png +0 -0
  247. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-icons_228ef1_256x240.png +0 -0
  248. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-icons_ef8c08_256x240.png +0 -0
  249. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-icons_ffd27a_256x240.png +0 -0
  250. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/images/ui-icons_ffffff_256x240.png +0 -0
  251. data/vendor/assets/javascripts/aloha/plugins/common/link/css/link.css +58 -55
  252. data/vendor/assets/javascripts/aloha/plugins/common/link/extra/delicious.js +26 -8
  253. data/vendor/assets/javascripts/aloha/plugins/common/link/extra/linklist.js +91 -73
  254. data/vendor/assets/javascripts/aloha/plugins/common/link/extra/slowlinklist.js +29 -10
  255. data/vendor/assets/javascripts/aloha/plugins/common/link/lib/link-plugin.js +429 -297
  256. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/ca/i18n.js +14 -0
  257. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/de/i18n.js +14 -13
  258. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/i18n.js +23 -9
  259. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/mk/i18n.js +14 -0
  260. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/pt-br/i18n.js +14 -0
  261. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/ru/i18n.js +14 -6
  262. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/uk/i18n.js +14 -0
  263. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/zh-hans/i18n.js +14 -0
  264. data/vendor/assets/javascripts/aloha/plugins/common/list/lib/list-plugin.js +150 -121
  265. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/ca/i18n.js +7 -0
  266. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/de/i18n.js +7 -5
  267. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/i18n.js +15 -8
  268. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/mk/i18n.js +7 -0
  269. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/pt-br/i18n.js +7 -0
  270. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/ru/i18n.js +7 -1
  271. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/uk/i18n.js +7 -0
  272. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/zh-hans/i18n.js +7 -0
  273. data/vendor/assets/javascripts/aloha/plugins/common/list/package.json +0 -0
  274. data/vendor/assets/javascripts/aloha/plugins/common/paste/lib/paste-plugin.js +338 -192
  275. data/vendor/assets/javascripts/aloha/plugins/common/table/css/table.css +5 -40
  276. data/vendor/assets/javascripts/aloha/plugins/common/table/img/down.cur +0 -0
  277. data/vendor/assets/javascripts/aloha/plugins/common/table/img/left.cur +0 -0
  278. data/vendor/assets/javascripts/aloha/plugins/common/table/img/table_layout.png +0 -0
  279. data/vendor/assets/javascripts/aloha/plugins/common/table/img/wai-green.png +0 -0
  280. data/vendor/assets/javascripts/aloha/plugins/common/table/img/wai-red.png +0 -0
  281. data/vendor/assets/javascripts/aloha/plugins/common/table/lib/table-cell.js +177 -106
  282. data/vendor/assets/javascripts/aloha/plugins/common/table/lib/table-create-layer.js +5 -2
  283. data/vendor/assets/javascripts/aloha/plugins/common/table/lib/table-plugin-utils.js +147 -8
  284. data/vendor/assets/javascripts/aloha/plugins/common/table/lib/table-plugin.js +925 -892
  285. data/vendor/assets/javascripts/aloha/plugins/common/table/lib/table-selection.js +10 -6
  286. data/vendor/assets/javascripts/aloha/plugins/common/table/lib/table.js +577 -193
  287. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/ca/i18n.js +28 -0
  288. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/de/i18n.js +28 -27
  289. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/i18n.js +37 -36
  290. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/mk/i18n.js +28 -0
  291. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/pt-br/i18n.js +28 -0
  292. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/ru/i18n.js +28 -1
  293. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/uk/i18n.js +28 -0
  294. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/zh-hans/i18n.js +28 -0
  295. data/vendor/assets/javascripts/aloha/plugins/common/table/package.json +0 -0
  296. data/vendor/assets/javascripts/aloha/plugins/common/ui/css/jquery-ui-1.9m6.css +430 -0
  297. data/vendor/assets/javascripts/aloha/plugins/common/ui/css/ui.css +689 -0
  298. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/blockquote.png +0 -0
  299. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/character-picker.png +0 -0
  300. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/em.png +0 -0
  301. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/format-block.png +0 -0
  302. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/format-inline.png +0 -0
  303. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/indent.png +0 -0
  304. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/jqueryui/ui-icons_222222_256x240.png +0 -0
  305. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/justify.png +0 -0
  306. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/language-annotation.png +0 -0
  307. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview.png +0 -0
  308. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/anchor.png +0 -0
  309. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/blockquote.png +0 -0
  310. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/caption.png +0 -0
  311. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/cite.png +0 -0
  312. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/dd.png +0 -0
  313. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/div.png +0 -0
  314. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/dl.png +0 -0
  315. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/dt.png +0 -0
  316. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/h1.png +0 -0
  317. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/h2.png +0 -0
  318. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/h3.png +0 -0
  319. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/h4.png +0 -0
  320. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/h5.png +0 -0
  321. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/h6.png +0 -0
  322. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/p.png +0 -0
  323. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/pre.png +0 -0
  324. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/q.png +0 -0
  325. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/table.png +0 -0
  326. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/td.png +0 -0
  327. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/metaview/th.png +0 -0
  328. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/multisplit-close.gif +0 -0
  329. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/multisplit-open.gif +0 -0
  330. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/outdent.png +0 -0
  331. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/quote.png +0 -0
  332. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/removeformat.png +0 -0
  333. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/strong.png +0 -0
  334. data/vendor/assets/javascripts/aloha/plugins/common/ui/img/tree.png +0 -0
  335. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/arena.js +11 -0
  336. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/autocomplete.js +70 -0
  337. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/button.js +114 -0
  338. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/component.js +121 -0
  339. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/container.js +210 -0
  340. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/context.js +53 -0
  341. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/dialog.js +215 -0
  342. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/floating.js +405 -0
  343. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/menuButton.js +169 -0
  344. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/multiSplit.js +237 -0
  345. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/port-helper-attribute-field.js +444 -0
  346. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/port-helper-multi-split.js +71 -0
  347. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/scopes.js +187 -0
  348. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/settings.js +202 -0
  349. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/subguarded.js +183 -0
  350. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/surface.js +106 -0
  351. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/tab.js +281 -0
  352. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/text.js +33 -0
  353. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/toggleButton.js +57 -0
  354. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/toolbar.js +251 -0
  355. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/ui-plugin.js +169 -0
  356. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/ui.js +181 -0
  357. data/vendor/assets/javascripts/aloha/plugins/common/ui/lib/utils.js +104 -0
  358. data/vendor/assets/javascripts/aloha/plugins/common/ui/nls/ca/i18n.js +46 -0
  359. data/vendor/assets/javascripts/aloha/plugins/common/ui/nls/de/i18n.js +47 -0
  360. data/vendor/assets/javascripts/aloha/plugins/common/ui/nls/i18n.js +75 -0
  361. data/vendor/assets/javascripts/aloha/plugins/common/ui/nls/mk/i18n.js +46 -0
  362. data/vendor/assets/javascripts/aloha/plugins/common/ui/nls/pt-br/i18n.js +46 -0
  363. data/vendor/assets/javascripts/aloha/plugins/common/ui/nls/ru/i18n.js +46 -0
  364. data/vendor/assets/javascripts/aloha/plugins/common/ui/nls/uk/i18n.js +46 -0
  365. data/vendor/assets/javascripts/aloha/plugins/common/ui/nls/zh-hans/i18n.js +46 -0
  366. data/vendor/assets/javascripts/aloha/plugins/common/ui/vendor/jquery-ui-autocomplete-html.js +42 -0
  367. data/vendor/assets/javascripts/aloha/plugins/common/undo/lib/undo-plugin.js +165 -134
  368. data/vendor/assets/javascripts/aloha/plugins/common/undo/package.json +0 -0
  369. data/vendor/assets/javascripts/aloha/plugins/common/undo/vendor/undo.js +2 -0
  370. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/lib/attributes-plugin.js +27 -7
  371. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/ca/i18n.js +5 -0
  372. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/de/i18n.js +5 -1
  373. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/i18n.js +13 -4
  374. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/mk/i18n.js +5 -0
  375. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/pt-br/i18n.js +5 -0
  376. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/ru/i18n.js +5 -0
  377. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/uk/i18n.js +5 -0
  378. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/zh-hans/i18n.js +5 -0
  379. data/vendor/assets/javascripts/aloha/plugins/extra/captioned-image/css/captioned-image.css +15 -0
  380. data/vendor/assets/javascripts/aloha/plugins/extra/captioned-image/lib/captioned-image-plugin.js +555 -0
  381. data/vendor/assets/javascripts/aloha/plugins/extra/cite/img/blockquote.png +0 -0
  382. data/vendor/assets/javascripts/aloha/plugins/extra/cite/img/icon_cite.png +0 -0
  383. data/vendor/assets/javascripts/aloha/plugins/extra/cite/lib/cite-plugin.js +369 -308
  384. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/ca/i18n.js +4 -0
  385. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/de/i18n.js +4 -1
  386. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/i18n.js +12 -3
  387. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/mk/i18n.js +4 -0
  388. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/pt-br/i18n.js +4 -0
  389. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/ru/i18n.js +4 -0
  390. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/uk/i18n.js +4 -0
  391. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/zh-hans/i18n.js +4 -0
  392. data/vendor/assets/javascripts/aloha/plugins/extra/comments/img/add-icon.png +0 -0
  393. data/vendor/assets/javascripts/aloha/plugins/extra/comments/img/add.png +0 -0
  394. data/vendor/assets/javascripts/aloha/plugins/extra/comments/img/comments.png +0 -0
  395. data/vendor/assets/javascripts/aloha/plugins/extra/comments/img/hr.png +0 -0
  396. data/vendor/assets/javascripts/aloha/plugins/extra/comments/img/textbox.png +0 -0
  397. data/vendor/assets/javascripts/aloha/plugins/extra/comments/{src/comments.js → lib/comments-plugin.js} +38 -15
  398. data/vendor/assets/javascripts/aloha/plugins/extra/comments/{src → lib}/comments.css +0 -0
  399. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/README.md +1 -1
  400. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/TODO.md +0 -0
  401. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/img/cross.png +0 -0
  402. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/img/hourglass.png +0 -0
  403. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/img/loading.gif +0 -0
  404. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/img/page.png +0 -0
  405. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/img/tick.png +0 -0
  406. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/lib/draganddropfiles-plugin.js +1 -1
  407. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/lib/dragndropfiles.css +0 -0
  408. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/lib/dragndropfiles.js +27 -13
  409. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/lib/dropfilesrepository.js +2 -2
  410. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/nls/ca/i18n.js +3 -0
  411. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/nls/de/i18n.js +3 -0
  412. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/nls/i18n.js +12 -0
  413. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/nls/mk/i18n.js +3 -0
  414. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/nls/pt-br/i18n.js +3 -0
  415. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/nls/ru/i18n.js +3 -0
  416. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/nls/uk/i18n.js +3 -0
  417. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/nls/zh-hans/i18n.js +3 -0
  418. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/package.json +0 -0
  419. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/README.md +1 -3
  420. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/css/formatless.css +1 -1
  421. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/img/button.png +0 -0
  422. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/lib/formatlesshandler.js +76 -46
  423. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/lib/formatlesspaste-plugin.js +217 -90
  424. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/nls/ca/i18n.js +3 -0
  425. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/nls/de/i18n.js +3 -1
  426. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/nls/i18n.js +10 -5
  427. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/nls/mk/i18n.js +3 -0
  428. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/nls/pt-br/i18n.js +3 -0
  429. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/nls/ru/i18n.js +3 -0
  430. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/nls/uk/i18n.js +3 -0
  431. data/vendor/assets/javascripts/aloha/plugins/extra/formatlesspaste/nls/zh-hans/i18n.js +3 -0
  432. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/lib/headerids-plugin.js +69 -30
  433. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/ca/i18n.js +6 -0
  434. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/de/i18n.js +6 -1
  435. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/i18n.js +14 -4
  436. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/mk/i18n.js +6 -0
  437. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/pt-br/i18n.js +6 -0
  438. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/ru/i18n.js +6 -0
  439. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/uk/i18n.js +6 -0
  440. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/zh-hans/i18n.js +6 -0
  441. data/vendor/assets/javascripts/aloha/plugins/extra/hints/README.md +12 -0
  442. data/vendor/assets/javascripts/aloha/plugins/extra/hints/css/hints.css +29 -0
  443. data/vendor/assets/javascripts/aloha/plugins/extra/hints/lib/hints-plugin.js +97 -0
  444. data/vendor/assets/javascripts/aloha/plugins/extra/hints/package.json +3 -3
  445. data/vendor/assets/javascripts/aloha/plugins/extra/hints/vendor/tipsy.js +242 -0
  446. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/README +0 -0
  447. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/lib/imagebrowser-plugin.js +160 -0
  448. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/nls/ca/i18n.js +6 -0
  449. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/nls/de/i18n.js +6 -0
  450. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/nls/i18n.js +15 -0
  451. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/nls/mk/i18n.js +6 -0
  452. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/nls/pt-br/i18n.js +6 -0
  453. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/nls/ru/i18n.js +6 -0
  454. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/nls/uk/i18n.js +6 -0
  455. data/vendor/assets/javascripts/aloha/plugins/extra/imagebrowser/nls/zh-hans/i18n.js +6 -0
  456. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ad.png +0 -0
  457. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ae.png +0 -0
  458. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/af.png +0 -0
  459. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ag.png +0 -0
  460. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ai.png +0 -0
  461. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/al.png +0 -0
  462. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/am.png +0 -0
  463. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/an.png +0 -0
  464. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ao.png +0 -0
  465. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ar.png +0 -0
  466. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/as.png +0 -0
  467. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/at.png +0 -0
  468. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/au.png +0 -0
  469. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/aw.png +0 -0
  470. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ax.png +0 -0
  471. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/az.png +0 -0
  472. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ba.png +0 -0
  473. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bb.png +0 -0
  474. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bd.png +0 -0
  475. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/be.png +0 -0
  476. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bf.png +0 -0
  477. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bg.png +0 -0
  478. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bh.png +0 -0
  479. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bi.png +0 -0
  480. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bj.png +0 -0
  481. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bm.png +0 -0
  482. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bn.png +0 -0
  483. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bo.png +0 -0
  484. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/br.png +0 -0
  485. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bs.png +0 -0
  486. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bt.png +0 -0
  487. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bv.png +0 -0
  488. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bw.png +0 -0
  489. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/by.png +0 -0
  490. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/bz.png +0 -0
  491. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ca.png +0 -0
  492. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/catalonia.png +0 -0
  493. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cc.png +0 -0
  494. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cd.png +0 -0
  495. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cf.png +0 -0
  496. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cg.png +0 -0
  497. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ch.png +0 -0
  498. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ci.png +0 -0
  499. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ck.png +0 -0
  500. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cl.png +0 -0
  501. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cm.png +0 -0
  502. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cn.png +0 -0
  503. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/co.png +0 -0
  504. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cr.png +0 -0
  505. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cs.png +0 -0
  506. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cu.png +0 -0
  507. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cv.png +0 -0
  508. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cx.png +0 -0
  509. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cy.png +0 -0
  510. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/cz.png +0 -0
  511. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/de.png +0 -0
  512. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/dj.png +0 -0
  513. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/dk.png +0 -0
  514. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/dm.png +0 -0
  515. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/do.png +0 -0
  516. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/dz.png +0 -0
  517. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ec.png +0 -0
  518. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ee.png +0 -0
  519. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/eg.png +0 -0
  520. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/eh.png +0 -0
  521. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/en.png +0 -0
  522. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/er.png +0 -0
  523. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/es.png +0 -0
  524. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/et.png +0 -0
  525. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/europeanunion.png +0 -0
  526. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/fam.png +0 -0
  527. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/fi.png +0 -0
  528. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/fj.png +0 -0
  529. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/fk.png +0 -0
  530. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/fm.png +0 -0
  531. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/fo.png +0 -0
  532. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/fr.png +0 -0
  533. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ga.png +0 -0
  534. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gb.png +0 -0
  535. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gd.png +0 -0
  536. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ge.png +0 -0
  537. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gf.png +0 -0
  538. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gh.png +0 -0
  539. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gi.png +0 -0
  540. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gl.png +0 -0
  541. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gm.png +0 -0
  542. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gn.png +0 -0
  543. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gp.png +0 -0
  544. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gq.png +0 -0
  545. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gr.png +0 -0
  546. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gs.png +0 -0
  547. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gt.png +0 -0
  548. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gu.png +0 -0
  549. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gw.png +0 -0
  550. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/gy.png +0 -0
  551. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/hk.png +0 -0
  552. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/hm.png +0 -0
  553. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/hn.png +0 -0
  554. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/hr.png +0 -0
  555. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ht.png +0 -0
  556. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/hu.png +0 -0
  557. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/id.png +0 -0
  558. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ie.png +0 -0
  559. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/il.png +0 -0
  560. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/in.png +0 -0
  561. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/io.png +0 -0
  562. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/iq.png +0 -0
  563. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ir.png +0 -0
  564. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/is.png +0 -0
  565. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/it.png +0 -0
  566. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/jm.png +0 -0
  567. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/jo.png +0 -0
  568. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/jp.png +0 -0
  569. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ke.png +0 -0
  570. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/kg.png +0 -0
  571. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/kh.png +0 -0
  572. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ki.png +0 -0
  573. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/km.png +0 -0
  574. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/kn.png +0 -0
  575. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/kp.png +0 -0
  576. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/kr.png +0 -0
  577. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/kw.png +0 -0
  578. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ky.png +0 -0
  579. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/kz.png +0 -0
  580. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/la.png +0 -0
  581. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/lb.png +0 -0
  582. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/lc.png +0 -0
  583. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/li.png +0 -0
  584. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/lk.png +0 -0
  585. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/lr.png +0 -0
  586. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ls.png +0 -0
  587. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/lt.png +0 -0
  588. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/lu.png +0 -0
  589. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/lv.png +0 -0
  590. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ly.png +0 -0
  591. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ma.png +0 -0
  592. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mc.png +0 -0
  593. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/md.png +0 -0
  594. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/me.png +0 -0
  595. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mg.png +0 -0
  596. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mh.png +0 -0
  597. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mk.png +0 -0
  598. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ml.png +0 -0
  599. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mm.png +0 -0
  600. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mn.png +0 -0
  601. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mo.png +0 -0
  602. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mp.png +0 -0
  603. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mq.png +0 -0
  604. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mr.png +0 -0
  605. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ms.png +0 -0
  606. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mt.png +0 -0
  607. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mu.png +0 -0
  608. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mv.png +0 -0
  609. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mw.png +0 -0
  610. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mx.png +0 -0
  611. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/my.png +0 -0
  612. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/mz.png +0 -0
  613. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/na.png +0 -0
  614. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/nc.png +0 -0
  615. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ne.png +0 -0
  616. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/nf.png +0 -0
  617. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ng.png +0 -0
  618. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ni.png +0 -0
  619. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/nl.png +0 -0
  620. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/no.png +0 -0
  621. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/np.png +0 -0
  622. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/nr.png +0 -0
  623. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/nu.png +0 -0
  624. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/nz.png +0 -0
  625. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/om.png +0 -0
  626. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pa.png +0 -0
  627. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pe.png +0 -0
  628. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pf.png +0 -0
  629. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pg.png +0 -0
  630. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ph.png +0 -0
  631. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pk.png +0 -0
  632. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pl.png +0 -0
  633. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pm.png +0 -0
  634. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pn.png +0 -0
  635. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pr.png +0 -0
  636. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ps.png +0 -0
  637. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pt.png +0 -0
  638. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/pw.png +0 -0
  639. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/py.png +0 -0
  640. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/qa.png +0 -0
  641. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/re.png +0 -0
  642. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ro.png +0 -0
  643. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/rs.png +0 -0
  644. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ru.png +0 -0
  645. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/rw.png +0 -0
  646. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sa.png +0 -0
  647. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sb.png +0 -0
  648. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sc.png +0 -0
  649. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/scotland.png +0 -0
  650. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sd.png +0 -0
  651. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/se.png +0 -0
  652. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sg.png +0 -0
  653. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sh.png +0 -0
  654. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/si.png +0 -0
  655. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sj.png +0 -0
  656. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sk.png +0 -0
  657. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sl.png +0 -0
  658. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sm.png +0 -0
  659. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sn.png +0 -0
  660. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/so.png +0 -0
  661. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sr.png +0 -0
  662. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/st.png +0 -0
  663. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sv.png +0 -0
  664. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sy.png +0 -0
  665. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/sz.png +0 -0
  666. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tc.png +0 -0
  667. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/td.png +0 -0
  668. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tf.png +0 -0
  669. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tg.png +0 -0
  670. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/th.png +0 -0
  671. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tj.png +0 -0
  672. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tk.png +0 -0
  673. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tl.png +0 -0
  674. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tm.png +0 -0
  675. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tn.png +0 -0
  676. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/to.png +0 -0
  677. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tr.png +0 -0
  678. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tt.png +0 -0
  679. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tv.png +0 -0
  680. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tw.png +0 -0
  681. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/tz.png +0 -0
  682. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ua.png +0 -0
  683. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ug.png +0 -0
  684. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/um.png +0 -0
  685. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/us.png +0 -0
  686. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/uy.png +0 -0
  687. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/uz.png +0 -0
  688. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/va.png +0 -0
  689. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/vc.png +0 -0
  690. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ve.png +0 -0
  691. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/vg.png +0 -0
  692. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/vi.png +0 -0
  693. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/vn.png +0 -0
  694. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/vu.png +0 -0
  695. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/wales.png +0 -0
  696. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/wf.png +0 -0
  697. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ws.png +0 -0
  698. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/ye.png +0 -0
  699. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/yt.png +0 -0
  700. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/za.png +0 -0
  701. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/zm.png +0 -0
  702. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/img/flags/zw.png +0 -0
  703. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/lib/linkbrowser-plugin.js +96 -100
  704. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/ca/i18n.js +6 -0
  705. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/de/i18n.js +6 -1
  706. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/i18n.js +14 -6
  707. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/mk/i18n.js +6 -0
  708. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/pt-br/i18n.js +6 -0
  709. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/ru/i18n.js +6 -1
  710. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/uk/i18n.js +6 -0
  711. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/zh-hans/i18n.js +6 -0
  712. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/nls/ca/i18n.js +28 -0
  713. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/nls/de/i18n.js +28 -0
  714. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/nls/i18n.js +37 -0
  715. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/nls/mk/i18n.js +28 -0
  716. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/nls/pt-br/i18n.js +28 -0
  717. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/nls/ru/i18n.js +28 -0
  718. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/nls/uk/i18n.js +28 -0
  719. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/nls/zh-hans/i18n.js +28 -0
  720. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/package.json +0 -0
  721. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/{proxy.php → proxy.php.example} +0 -0
  722. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/src/linkchecker.css +0 -0
  723. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/src/linkchecker.js +28 -15
  724. data/vendor/assets/javascripts/aloha/plugins/extra/listenforcer/lib/listenforcer-plugin.js +56 -31
  725. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/css/metaview.css +6 -14
  726. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/anchor.png +0 -0
  727. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/blockquote.png +0 -0
  728. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/button.png +0 -0
  729. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/caption.png +0 -0
  730. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/cite.png +0 -0
  731. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/dd.png +0 -0
  732. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/div.png +0 -0
  733. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/dl.png +0 -0
  734. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/dt.png +0 -0
  735. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/h1.png +0 -0
  736. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/h2.png +0 -0
  737. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/h3.png +0 -0
  738. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/h4.png +0 -0
  739. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/h5.png +0 -0
  740. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/h6.png +0 -0
  741. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/hr.png +0 -0
  742. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/icon_cite.png +0 -0
  743. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/p.png +0 -0
  744. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/pre.png +0 -0
  745. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/table.png +0 -0
  746. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/td.png +0 -0
  747. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/img/th.png +0 -0
  748. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/lib/metaview-plugin.js +178 -74
  749. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/ca/i18n.js +3 -0
  750. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/de/i18n.js +3 -1
  751. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/i18n.js +11 -4
  752. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/mk/i18n.js +3 -0
  753. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/pt-br/i18n.js +3 -0
  754. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/ru/i18n.js +3 -0
  755. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/uk/i18n.js +3 -0
  756. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/zh-hans/i18n.js +3 -0
  757. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/css/numerated-headers.css +1 -1
  758. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/img/headers.png +0 -0
  759. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/lib/numerated-headers-plugin.js +405 -217
  760. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/ca/i18n.js +5 -0
  761. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/de/i18n.js +5 -1
  762. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/i18n.js +13 -4
  763. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/mk/i18n.js +5 -0
  764. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/pt-br/i18n.js +5 -0
  765. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/ru/i18n.js +5 -0
  766. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/uk/i18n.js +5 -0
  767. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/zh-hans/i18n.js +5 -0
  768. data/vendor/assets/javascripts/aloha/plugins/extra/profiler/lib/profiler-plugin.js +29 -10
  769. data/vendor/assets/javascripts/aloha/plugins/extra/ribbon/README.md +0 -0
  770. data/vendor/assets/javascripts/aloha/plugins/extra/ribbon/css/ribbon.css +49 -5
  771. data/vendor/assets/javascripts/aloha/{img → plugins/extra/ribbon/img}/fade-in.png +0 -0
  772. data/vendor/assets/javascripts/aloha/{img → plugins/extra/ribbon/img}/fade-out.png +0 -0
  773. data/vendor/assets/javascripts/aloha/plugins/extra/ribbon/lib/ribbon-plugin.js +108 -150
  774. data/vendor/assets/javascripts/aloha/plugins/extra/ribbon/package.json +0 -0
  775. data/vendor/assets/javascripts/aloha/plugins/extra/sourceview/css/sourceview.css +18 -0
  776. data/vendor/assets/javascripts/aloha/plugins/extra/sourceview/lib/sourceview-plugin.js +252 -0
  777. data/vendor/assets/javascripts/aloha/plugins/extra/sourceview/vendor/htmlbeautifier.js +468 -0
  778. data/vendor/assets/javascripts/aloha/plugins/extra/textcolor/css/textcolor.css +50 -0
  779. data/vendor/assets/javascripts/aloha/{lib/vendor/ext-3.2.1/resources/images/gray/window/left-right.png → plugins/extra/textcolor/img/icon.png} +0 -0
  780. data/vendor/assets/javascripts/aloha/plugins/extra/textcolor/lib/textcolor-plugin.js +420 -0
  781. data/vendor/assets/javascripts/aloha/plugins/extra/textcolor/nls/de/i18n.js +3 -0
  782. data/vendor/assets/javascripts/aloha/plugins/extra/textcolor/nls/i18n.js +6 -0
  783. data/vendor/assets/javascripts/aloha/plugins/extra/toc/lib/toc-plugin.js +56 -39
  784. data/vendor/assets/javascripts/aloha/plugins/extra/toc/nls/ca/i18n.js +3 -0
  785. data/vendor/assets/javascripts/aloha/plugins/extra/toc/nls/de/i18n.js +3 -3
  786. data/vendor/assets/javascripts/aloha/plugins/extra/toc/nls/i18n.js +11 -3
  787. data/vendor/assets/javascripts/aloha/plugins/extra/toc/nls/mk/i18n.js +3 -0
  788. data/vendor/assets/javascripts/aloha/plugins/extra/toc/nls/pt-br/i18n.js +3 -0
  789. data/vendor/assets/javascripts/aloha/plugins/extra/toc/nls/ru/i18n.js +3 -0
  790. data/vendor/assets/javascripts/aloha/plugins/extra/toc/nls/uk/i18n.js +3 -0
  791. data/vendor/assets/javascripts/aloha/plugins/extra/toc/nls/zh-hans/i18n.js +3 -0
  792. data/vendor/assets/javascripts/aloha/plugins/extra/toc/package.json +0 -0
  793. data/vendor/assets/javascripts/aloha/plugins/extra/validation/lib/validation-plugin.js +277 -0
  794. metadata +293 -508
  795. data/vendor/assets/javascripts/aloha/css/ext-aloha-reset.css +0 -33
  796. data/vendor/assets/javascripts/aloha/css/ext-aloha.css +0 -360
  797. data/vendor/assets/javascripts/aloha/img/base-big.png +0 -0
  798. data/vendor/assets/javascripts/aloha/lib/aloha-bootstrap.js +0 -28276
  799. data/vendor/assets/javascripts/aloha/lib/aloha/ecma5.js +0 -194
  800. data/vendor/assets/javascripts/aloha/lib/aloha/ext-alohaproxy.js +0 -86
  801. data/vendor/assets/javascripts/aloha/lib/aloha/ext-alohareader.js +0 -50
  802. data/vendor/assets/javascripts/aloha/lib/aloha/ext-alohatreeloader.js +0 -77
  803. data/vendor/assets/javascripts/aloha/lib/aloha/ext.js +0 -32
  804. data/vendor/assets/javascripts/aloha/lib/aloha/floatingmenu.js +0 -1496
  805. data/vendor/assets/javascripts/aloha/lib/aloha/jquery.js +0 -34
  806. data/vendor/assets/javascripts/aloha/lib/aloha/jquery.patch.js +0 -115
  807. data/vendor/assets/javascripts/aloha/lib/aloha/message.js +0 -115
  808. data/vendor/assets/javascripts/aloha/lib/aloha/ui-attributefield.js +0 -530
  809. data/vendor/assets/javascripts/aloha/lib/aloha/ui-browser.js +0 -214
  810. data/vendor/assets/javascripts/aloha/lib/aloha/ui.js +0 -889
  811. data/vendor/assets/javascripts/aloha/lib/jquery-plugin.js +0 -49
  812. data/vendor/assets/javascripts/aloha/lib/order.js +0 -140
  813. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/adapter/jquery/ext-jquery-adapter-debug.js +0 -2470
  814. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/adapter/jquery/ext-jquery-adapter.js +0 -7
  815. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/ext-all-debug.js +0 -47708
  816. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/ext-all.js +0 -13
  817. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/gpl-3.0.txt +0 -674
  818. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/license.txt +0 -42
  819. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/charts.swf +0 -0
  820. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/css/ext-all.css +0 -5903
  821. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/css/ext-all.less +0 -6795
  822. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/css/xtheme-gray.css +0 -1692
  823. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/expressinstall.swf +0 -0
  824. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/box/corners-blue.gif +0 -0
  825. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/box/corners.gif +0 -0
  826. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/box/l-blue.gif +0 -0
  827. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/box/l.gif +0 -0
  828. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/box/r-blue.gif +0 -0
  829. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/box/r.gif +0 -0
  830. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/box/tb-blue.gif +0 -0
  831. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/box/tb.gif +0 -0
  832. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/arrow.gif +0 -0
  833. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/btn.gif +0 -0
  834. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/group-cs.gif +0 -0
  835. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/group-lr.gif +0 -0
  836. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/group-tb.gif +0 -0
  837. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/s-arrow-b-noline.gif +0 -0
  838. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/s-arrow-b.gif +0 -0
  839. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/s-arrow-bo.gif +0 -0
  840. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/s-arrow-noline.gif +0 -0
  841. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/s-arrow-o.gif +0 -0
  842. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/button/s-arrow.gif +0 -0
  843. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/dd/drop-add.gif +0 -0
  844. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/dd/drop-no.gif +0 -0
  845. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/dd/drop-yes.gif +0 -0
  846. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/editor/tb-sprite.gif +0 -0
  847. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/checkbox.gif +0 -0
  848. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/clear-trigger.gif +0 -0
  849. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/clear-trigger.psd +0 -0
  850. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/date-trigger.gif +0 -0
  851. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/date-trigger.psd +0 -0
  852. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/error-tip-corners.gif +0 -0
  853. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/exclamation.gif +0 -0
  854. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/radio.gif +0 -0
  855. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/search-trigger.gif +0 -0
  856. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/search-trigger.psd +0 -0
  857. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/text-bg.gif +0 -0
  858. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/trigger-square.gif +0 -0
  859. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/trigger-square.psd +0 -0
  860. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/trigger-tpl.gif +0 -0
  861. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/trigger.gif +0 -0
  862. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/form/trigger.psd +0 -0
  863. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/gradient-bg.gif +0 -0
  864. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/arrow-left-white.gif +0 -0
  865. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/arrow-right-white.gif +0 -0
  866. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/col-move-bottom.gif +0 -0
  867. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/col-move-top.gif +0 -0
  868. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/columns.gif +0 -0
  869. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/dirty.gif +0 -0
  870. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/done.gif +0 -0
  871. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/drop-no.gif +0 -0
  872. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/drop-yes.gif +0 -0
  873. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/footer-bg.gif +0 -0
  874. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid-blue-hd.gif +0 -0
  875. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid-blue-split.gif +0 -0
  876. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid-hrow.gif +0 -0
  877. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid-loading.gif +0 -0
  878. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid-split.gif +0 -0
  879. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid-vista-hd.gif +0 -0
  880. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid3-hd-btn.gif +0 -0
  881. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid3-hrow-over.gif +0 -0
  882. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid3-hrow.gif +0 -0
  883. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid3-special-col-bg.gif +0 -0
  884. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/grid3-special-col-sel-bg.gif +0 -0
  885. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/group-by.gif +0 -0
  886. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/group-collapse.gif +0 -0
  887. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/group-expand-sprite.gif +0 -0
  888. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/group-expand.gif +0 -0
  889. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/hd-pop.gif +0 -0
  890. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/hmenu-asc.gif +0 -0
  891. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/hmenu-desc.gif +0 -0
  892. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/hmenu-lock.gif +0 -0
  893. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/hmenu-lock.png +0 -0
  894. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/hmenu-unlock.gif +0 -0
  895. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/hmenu-unlock.png +0 -0
  896. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/invalid_line.gif +0 -0
  897. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/loading.gif +0 -0
  898. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/mso-hd.gif +0 -0
  899. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/nowait.gif +0 -0
  900. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/page-first-disabled.gif +0 -0
  901. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/page-first.gif +0 -0
  902. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/page-last-disabled.gif +0 -0
  903. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/page-last.gif +0 -0
  904. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/page-next-disabled.gif +0 -0
  905. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/page-next.gif +0 -0
  906. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/page-prev-disabled.gif +0 -0
  907. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/page-prev.gif +0 -0
  908. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/pick-button.gif +0 -0
  909. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/refresh.gif +0 -0
  910. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/row-check-sprite.gif +0 -0
  911. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/row-expand-sprite.gif +0 -0
  912. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/row-over.gif +0 -0
  913. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/row-sel.gif +0 -0
  914. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/sort-hd.gif +0 -0
  915. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/sort_asc.gif +0 -0
  916. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/sort_desc.gif +0 -0
  917. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/grid/wait.gif +0 -0
  918. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/collapse.gif +0 -0
  919. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/expand.gif +0 -0
  920. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/gradient-bg.gif +0 -0
  921. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/mini-bottom.gif +0 -0
  922. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/mini-left.gif +0 -0
  923. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/mini-right.gif +0 -0
  924. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/mini-top.gif +0 -0
  925. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/ns-collapse.gif +0 -0
  926. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/ns-expand.gif +0 -0
  927. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/panel-close.gif +0 -0
  928. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/panel-title-bg.gif +0 -0
  929. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/panel-title-light-bg.gif +0 -0
  930. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/stick.gif +0 -0
  931. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/stuck.gif +0 -0
  932. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/tab-close-on.gif +0 -0
  933. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/layout/tab-close.gif +0 -0
  934. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/menu/checked.gif +0 -0
  935. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/menu/group-checked.gif +0 -0
  936. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/menu/item-over.gif +0 -0
  937. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/menu/menu-parent.gif +0 -0
  938. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/menu/menu.gif +0 -0
  939. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/menu/unchecked.gif +0 -0
  940. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/corners-sprite.gif +0 -0
  941. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/left-right.gif +0 -0
  942. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/light-hd.gif +0 -0
  943. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/tool-sprite-tpl.gif +0 -0
  944. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/tool-sprites.gif +0 -0
  945. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/tools-sprites-trans.gif +0 -0
  946. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/top-bottom.gif +0 -0
  947. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/top-bottom.png +0 -0
  948. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/white-corners-sprite.gif +0 -0
  949. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/white-left-right.gif +0 -0
  950. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/panel/white-top-bottom.gif +0 -0
  951. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/progress/progress-bg.gif +0 -0
  952. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/qtip/bg.gif +0 -0
  953. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/qtip/close.gif +0 -0
  954. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/qtip/tip-anchor-sprite.gif +0 -0
  955. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/qtip/tip-sprite.gif +0 -0
  956. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/s.gif +0 -0
  957. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shadow-c.png +0 -0
  958. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shadow-lr.png +0 -0
  959. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shadow.png +0 -0
  960. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/blue-loading.gif +0 -0
  961. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/calendar.gif +0 -0
  962. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/glass-bg.gif +0 -0
  963. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/hd-sprite.gif +0 -0
  964. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/large-loading.gif +0 -0
  965. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/left-btn.gif +0 -0
  966. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/loading-balls.gif +0 -0
  967. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/right-btn.gif +0 -0
  968. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/shared/warning.gif +0 -0
  969. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/e-handle-dark.gif +0 -0
  970. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/e-handle.gif +0 -0
  971. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/ne-handle-dark.gif +0 -0
  972. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/ne-handle.gif +0 -0
  973. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/nw-handle-dark.gif +0 -0
  974. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/nw-handle.gif +0 -0
  975. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/s-handle-dark.gif +0 -0
  976. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/s-handle.gif +0 -0
  977. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/se-handle-dark.gif +0 -0
  978. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/se-handle.gif +0 -0
  979. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/square.gif +0 -0
  980. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/sw-handle-dark.gif +0 -0
  981. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/sizer/sw-handle.gif +0 -0
  982. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/slider/slider-bg.png +0 -0
  983. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/slider/slider-thumb.png +0 -0
  984. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/slider/slider-v-bg.png +0 -0
  985. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/slider/slider-v-thumb.png +0 -0
  986. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/scroll-left.gif +0 -0
  987. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/scroll-right.gif +0 -0
  988. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/scroller-bg.gif +0 -0
  989. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-btm-inactive-left-bg.gif +0 -0
  990. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-btm-inactive-right-bg.gif +0 -0
  991. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-btm-left-bg.gif +0 -0
  992. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-btm-over-left-bg.gif +0 -0
  993. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-btm-over-right-bg.gif +0 -0
  994. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-btm-right-bg.gif +0 -0
  995. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-close.gif +0 -0
  996. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-strip-bg.gif +0 -0
  997. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-strip-bg.png +0 -0
  998. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tab-strip-btm-bg.gif +0 -0
  999. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tabs/tabs-sprite.gif +0 -0
  1000. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/bg.gif +0 -0
  1001. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/btn-arrow-light.gif +0 -0
  1002. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/btn-arrow.gif +0 -0
  1003. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/btn-over-bg.gif +0 -0
  1004. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/gray-bg.gif +0 -0
  1005. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/more.gif +0 -0
  1006. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/tb-bg.gif +0 -0
  1007. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/tb-btn-sprite.gif +0 -0
  1008. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/tb-xl-btn-sprite.gif +0 -0
  1009. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/toolbar/tb-xl-sep.gif +0 -0
  1010. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/arrows.gif +0 -0
  1011. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/drop-add.gif +0 -0
  1012. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/drop-between.gif +0 -0
  1013. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/drop-no.gif +0 -0
  1014. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/drop-over.gif +0 -0
  1015. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/drop-under.gif +0 -0
  1016. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/drop-yes.gif +0 -0
  1017. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-end-minus-nl.gif +0 -0
  1018. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-end-minus.gif +0 -0
  1019. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-end-plus-nl.gif +0 -0
  1020. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-end-plus.gif +0 -0
  1021. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-end.gif +0 -0
  1022. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-line.gif +0 -0
  1023. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-minus-nl.gif +0 -0
  1024. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-minus.gif +0 -0
  1025. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-plus-nl.gif +0 -0
  1026. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow-plus.gif +0 -0
  1027. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/elbow.gif +0 -0
  1028. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/folder-open.gif +0 -0
  1029. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/folder.gif +0 -0
  1030. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/leaf.gif +0 -0
  1031. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/loading.gif +0 -0
  1032. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/tree/s.gif +0 -0
  1033. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/icon-error.gif +0 -0
  1034. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/icon-info.gif +0 -0
  1035. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/icon-question.gif +0 -0
  1036. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/icon-warning.gif +0 -0
  1037. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/left-corners.png +0 -0
  1038. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/left-corners.psd +0 -0
  1039. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/left-right.png +0 -0
  1040. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/left-right.psd +0 -0
  1041. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/right-corners.png +0 -0
  1042. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/right-corners.psd +0 -0
  1043. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/top-bottom.png +0 -0
  1044. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/default/window/top-bottom.psd +0 -0
  1045. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/button/btn-arrow.gif +0 -0
  1046. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/button/btn-sprite.gif +0 -0
  1047. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/button/btn.gif +0 -0
  1048. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/button/group-cs.gif +0 -0
  1049. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/button/group-lr.gif +0 -0
  1050. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/button/group-tb.gif +0 -0
  1051. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/button/s-arrow-bo.gif +0 -0
  1052. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/button/s-arrow-o.gif +0 -0
  1053. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/form/clear-trigger.gif +0 -0
  1054. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/form/date-trigger.gif +0 -0
  1055. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/form/search-trigger.gif +0 -0
  1056. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/form/trigger-square.gif +0 -0
  1057. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/form/trigger.gif +0 -0
  1058. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/gradient-bg.gif +0 -0
  1059. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/col-move-bottom.gif +0 -0
  1060. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/col-move-top.gif +0 -0
  1061. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/grid3-hd-btn.gif +0 -0
  1062. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/grid3-hrow-over.gif +0 -0
  1063. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/grid3-hrow-over2.gif +0 -0
  1064. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/grid3-hrow.gif +0 -0
  1065. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/grid3-hrow2.gif +0 -0
  1066. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/grid3-special-col-bg.gif +0 -0
  1067. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/grid3-special-col-bg2.gif +0 -0
  1068. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/grid3-special-col-sel-bg.gif +0 -0
  1069. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/group-collapse.gif +0 -0
  1070. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/group-expand-sprite.gif +0 -0
  1071. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/group-expand.gif +0 -0
  1072. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/page-first.gif +0 -0
  1073. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/page-last.gif +0 -0
  1074. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/page-next.gif +0 -0
  1075. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/page-prev.gif +0 -0
  1076. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/refresh.gif +0 -0
  1077. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/row-expand-sprite.gif +0 -0
  1078. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/sort_asc.gif +0 -0
  1079. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/grid/sort_desc.gif +0 -0
  1080. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/menu/group-checked.gif +0 -0
  1081. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/menu/item-over-disabled.gif +0 -0
  1082. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/menu/item-over.gif +0 -0
  1083. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/menu/menu-parent.gif +0 -0
  1084. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/corners-sprite.gif +0 -0
  1085. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/left-right.gif +0 -0
  1086. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/light-hd.gif +0 -0
  1087. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/tool-sprite-tpl.gif +0 -0
  1088. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/tool-sprites.gif +0 -0
  1089. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/tools-sprites-trans.gif +0 -0
  1090. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/top-bottom.gif +0 -0
  1091. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/top-bottom.png +0 -0
  1092. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/white-corners-sprite.gif +0 -0
  1093. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/white-left-right.gif +0 -0
  1094. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/panel/white-top-bottom.gif +0 -0
  1095. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/progress/progress-bg.gif +0 -0
  1096. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/qtip/bg.gif +0 -0
  1097. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/qtip/close.gif +0 -0
  1098. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/qtip/tip-anchor-sprite.gif +0 -0
  1099. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/qtip/tip-sprite.gif +0 -0
  1100. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/s.gif +0 -0
  1101. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/shared/hd-sprite.gif +0 -0
  1102. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/shared/left-btn.gif +0 -0
  1103. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/shared/right-btn.gif +0 -0
  1104. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/sizer/e-handle.gif +0 -0
  1105. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/sizer/ne-handle.gif +0 -0
  1106. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/sizer/nw-handle.gif +0 -0
  1107. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/sizer/s-handle.gif +0 -0
  1108. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/sizer/se-handle.gif +0 -0
  1109. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/sizer/square.gif +0 -0
  1110. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/sizer/sw-handle.gif +0 -0
  1111. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/slider/slider-thumb.png +0 -0
  1112. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/slider/slider-v-thumb.png +0 -0
  1113. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/scroll-left.gif +0 -0
  1114. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/scroll-right.gif +0 -0
  1115. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/scroller-bg.gif +0 -0
  1116. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-btm-inactive-left-bg.gif +0 -0
  1117. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-btm-inactive-right-bg.gif +0 -0
  1118. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-btm-left-bg.gif +0 -0
  1119. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-btm-over-left-bg.gif +0 -0
  1120. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-btm-over-right-bg.gif +0 -0
  1121. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-btm-right-bg.gif +0 -0
  1122. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-close.gif +0 -0
  1123. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-strip-bg.gif +0 -0
  1124. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-strip-bg.png +0 -0
  1125. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tab-strip-btm-bg.gif +0 -0
  1126. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tabs/tabs-sprite.gif +0 -0
  1127. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/toolbar/bg.gif +0 -0
  1128. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/toolbar/btn-arrow-light.gif +0 -0
  1129. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/toolbar/btn-arrow.gif +0 -0
  1130. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/toolbar/btn-over-bg.gif +0 -0
  1131. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/toolbar/gray-bg.gif +0 -0
  1132. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/toolbar/more.gif +0 -0
  1133. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/toolbar/tb-bg.gif +0 -0
  1134. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/toolbar/tb-btn-sprite.gif +0 -0
  1135. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tree/arrows.gif +0 -0
  1136. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tree/elbow-end-minus-nl.gif +0 -0
  1137. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tree/elbow-end-minus.gif +0 -0
  1138. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tree/elbow-end-plus-nl.gif +0 -0
  1139. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/tree/elbow-end-plus.gif +0 -0
  1140. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/window/icon-error.gif +0 -0
  1141. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/window/icon-info.gif +0 -0
  1142. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/window/icon-question.gif +0 -0
  1143. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/window/icon-warning.gif +0 -0
  1144. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/window/left-corners.png +0 -0
  1145. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/window/left-corners.pspimage +0 -0
  1146. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/window/right-corners.png +0 -0
  1147. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/images/gray/window/top-bottom.png +0 -0
  1148. data/vendor/assets/javascripts/aloha/lib/vendor/ext-3.2.1/resources/resources.jsb +0 -507
  1149. data/vendor/assets/javascripts/aloha/lib/vendor/jquery.json-2.2.min.js +0 -33
  1150. data/vendor/assets/javascripts/aloha/lib/vendor/jquery.store.js +0 -470
  1151. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/en/i18n.js +0 -1
  1152. data/vendor/assets/javascripts/aloha/plugins/common/align/nls/fr/i18n.js +0 -1
  1153. data/vendor/assets/javascripts/aloha/plugins/common/block/lib/jquery-ui-1.8.16.custom.min.js +0 -198
  1154. data/vendor/assets/javascripts/aloha/plugins/common/format/css/format.css +0 -8
  1155. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/eo/i18n.js +0 -1
  1156. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/fi/i18n.js +0 -1
  1157. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/fr/i18n.js +0 -1
  1158. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/it/i18n.js +0 -1
  1159. data/vendor/assets/javascripts/aloha/plugins/common/format/nls/pl/i18n.js +0 -1
  1160. data/vendor/assets/javascripts/aloha/plugins/common/image/AGPL3 +0 -661
  1161. data/vendor/assets/javascripts/aloha/plugins/common/image/LICENSE +0 -25
  1162. data/vendor/assets/javascripts/aloha/plugins/common/image/demo/crop.html +0 -76
  1163. data/vendor/assets/javascripts/aloha/plugins/common/image/demo/crop.php +0 -21
  1164. data/vendor/assets/javascripts/aloha/plugins/common/image/demo/cropnresize.jpg +0 -0
  1165. data/vendor/assets/javascripts/aloha/plugins/common/image/demo/index.html +0 -120
  1166. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/cz/i18n.js +0 -16
  1167. data/vendor/assets/javascripts/aloha/plugins/common/image/nls/fr/i18n.js +0 -1
  1168. data/vendor/assets/javascripts/aloha/plugins/common/image/test/test.css +0 -12
  1169. data/vendor/assets/javascripts/aloha/plugins/common/image/test/test.html +0 -40
  1170. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/jquery-ui-1.8.10.custom.min.js +0 -97
  1171. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/jquery-ui-1.8.10.cropnresize.css +0 -33
  1172. data/vendor/assets/javascripts/aloha/plugins/common/image/vendor/ui/ui-lightness/jquery-ui-1.8.10.custom.css +0 -314
  1173. data/vendor/assets/javascripts/aloha/plugins/common/link/demo/background.png +0 -0
  1174. data/vendor/assets/javascripts/aloha/plugins/common/link/demo/external-link-ltr-icon.png +0 -0
  1175. data/vendor/assets/javascripts/aloha/plugins/common/link/demo/index.css +0 -91
  1176. data/vendor/assets/javascripts/aloha/plugins/common/link/demo/index.html +0 -91
  1177. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/fr/i18n.js +0 -6
  1178. data/vendor/assets/javascripts/aloha/plugins/common/link/nls/pl/i18n.js +0 -6
  1179. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/eo/i18n.js +0 -1
  1180. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/fi/i18n.js +0 -1
  1181. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/fr/i18n.js +0 -1
  1182. data/vendor/assets/javascripts/aloha/plugins/common/list/nls/it/i18n.js +0 -1
  1183. data/vendor/assets/javascripts/aloha/plugins/common/paste/README.md +0 -3
  1184. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/eo/i18n.js +0 -1
  1185. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/fi/i18n.js +0 -1
  1186. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/fr/i18n.js +0 -1
  1187. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/it/i18n.js +0 -1
  1188. data/vendor/assets/javascripts/aloha/plugins/common/table/nls/pl/i18n.js +0 -1
  1189. data/vendor/assets/javascripts/aloha/plugins/common/undo/demo/index.css +0 -49
  1190. data/vendor/assets/javascripts/aloha/plugins/common/undo/demo/index.html +0 -85
  1191. data/vendor/assets/javascripts/aloha/plugins/extra/attributes/nls/en/i18n.js +0 -1
  1192. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/browser.css +0 -360
  1193. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/browser.jqgrid.css +0 -374
  1194. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
  1195. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
  1196. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
  1197. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
  1198. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-bg_glass_75_dadada_1x400.png +0 -0
  1199. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
  1200. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
  1201. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
  1202. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-icons_222222_256x240.png +0 -0
  1203. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-icons_2e83ff_256x240.png +0 -0
  1204. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-icons_454545_256x240.png +0 -0
  1205. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-icons_888888_256x240.png +0 -0
  1206. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/images/ui-icons_cd0a0a_256x240.png +0 -0
  1207. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/jquery-ui-1.8.13.custom.css +0 -319
  1208. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/throbber.gif +0 -0
  1209. data/vendor/assets/javascripts/aloha/plugins/extra/browser/css/ui.jqgrid.css +0 -148
  1210. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/arrow-000-medium.png +0 -0
  1211. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/arrow-180.png +0 -0
  1212. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/arrow-315-medium.png +0 -0
  1213. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/arrow-stop-180.png +0 -0
  1214. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/arrow-stop.png +0 -0
  1215. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/arrow.png +0 -0
  1216. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/control-stop-square-small.png +0 -0
  1217. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/folder-horizontal-open.png +0 -0
  1218. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/folder-open.png +0 -0
  1219. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/gcn-icons/gcn-icon-file.gif +0 -0
  1220. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/gcn-icons/gcn-icon-image.gif +0 -0
  1221. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/gcn-icons/gcn-icon-page.gif +0 -0
  1222. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/magnifier-left.png +0 -0
  1223. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/page.png +0 -0
  1224. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/picture.png +0 -0
  1225. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/sort-alphabet-descending.png +0 -0
  1226. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/sort-alphabet.png +0 -0
  1227. data/vendor/assets/javascripts/aloha/plugins/extra/browser/img/throbber.gif +0 -0
  1228. data/vendor/assets/javascripts/aloha/plugins/extra/browser/lib/browser-plugin.js +0 -10
  1229. data/vendor/assets/javascripts/aloha/plugins/extra/browser/lib/browser.js +0 -1126
  1230. data/vendor/assets/javascripts/aloha/plugins/extra/browser/lib/locale.js +0 -26
  1231. data/vendor/assets/javascripts/aloha/plugins/extra/browser/nls/de.json +0 -1
  1232. data/vendor/assets/javascripts/aloha/plugins/extra/browser/nls/de/i18n.js +0 -18
  1233. data/vendor/assets/javascripts/aloha/plugins/extra/browser/nls/en.json +0 -1
  1234. data/vendor/assets/javascripts/aloha/plugins/extra/browser/nls/en/i18n.js +0 -18
  1235. data/vendor/assets/javascripts/aloha/plugins/extra/browser/nls/i18n.js +0 -4
  1236. data/vendor/assets/javascripts/aloha/plugins/extra/browser/vendor/jquery.ui.js +0 -761
  1237. data/vendor/assets/javascripts/aloha/plugins/extra/browser/vendor/ui-layout.js +0 -113
  1238. data/vendor/assets/javascripts/aloha/plugins/extra/cite/nls/en/i18n.js +0 -1
  1239. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/AGPL3 +0 -661
  1240. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/LICENSE +0 -25
  1241. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/demo/index.css +0 -47
  1242. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/demo/index.html +0 -101
  1243. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/demo/migration/index.css +0 -189
  1244. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/demo/migration/index.html +0 -321
  1245. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/demo/specs/DragnDropnImage.graphml +0 -677
  1246. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/demo/style.css +0 -47
  1247. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/demo/upload.php +0 -26
  1248. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/i18n/en.json +0 -1
  1249. data/vendor/assets/javascripts/aloha/plugins/extra/draganddropfiles/i18n/fr.json +0 -1
  1250. data/vendor/assets/javascripts/aloha/plugins/extra/headerids/nls/en/i18n.js +0 -1
  1251. data/vendor/assets/javascripts/aloha/plugins/extra/hints/dep/jquery.poshytip.js +0 -470
  1252. data/vendor/assets/javascripts/aloha/plugins/extra/hints/i18n/de.json +0 -1
  1253. data/vendor/assets/javascripts/aloha/plugins/extra/hints/i18n/en.json +0 -1
  1254. data/vendor/assets/javascripts/aloha/plugins/extra/hints/img/tip-twitter_arrows.gif +0 -0
  1255. data/vendor/assets/javascripts/aloha/plugins/extra/hints/src/hints.css +0 -61
  1256. data/vendor/assets/javascripts/aloha/plugins/extra/hints/src/hints.js +0 -49
  1257. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/fr/i18n.js +0 -1
  1258. data/vendor/assets/javascripts/aloha/plugins/extra/linkbrowser/nls/pl/i18n.js +0 -1
  1259. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/demo/index.css +0 -49
  1260. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/demo/index.html +0 -82
  1261. data/vendor/assets/javascripts/aloha/plugins/extra/linkchecker/i18n/en.json +0 -1
  1262. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/de.json +0 -1
  1263. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/en.json +0 -1
  1264. data/vendor/assets/javascripts/aloha/plugins/extra/metaview/nls/en/i18n.js +0 -1
  1265. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/demo/index.css +0 -189
  1266. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/demo/index.html +0 -139
  1267. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/demo/js/aloha-config.js +0 -115
  1268. data/vendor/assets/javascripts/aloha/plugins/extra/numerated-headers/nls/en/i18n.js +0 -1
  1269. data/vendor/assets/javascripts/aloha/plugins/extra/ribbon/LICENSE.md +0 -662
  1270. data/vendor/assets/javascripts/aloha/plugins/extra/vie/LICENSE +0 -22
  1271. data/vendor/assets/javascripts/aloha/plugins/extra/vie/README.markdown +0 -65
  1272. data/vendor/assets/javascripts/aloha/plugins/extra/vie/demo/index.html +0 -93
  1273. data/vendor/assets/javascripts/aloha/plugins/extra/vie/img/cms-decoupled-communications.png +0 -0
  1274. data/vendor/assets/javascripts/aloha/plugins/extra/vie/package.json +0 -1
  1275. data/vendor/assets/javascripts/aloha/plugins/extra/vie/src/backbone-min.js +0 -27
  1276. data/vendor/assets/javascripts/aloha/plugins/extra/vie/src/underscore-min.js +0 -25
  1277. data/vendor/assets/javascripts/aloha/plugins/extra/vie/src/vie-aloha.js +0 -74
  1278. data/vendor/assets/javascripts/aloha/plugins/extra/vie/src/vie-collectionmanager.js +0 -70
  1279. data/vendor/assets/javascripts/aloha/plugins/extra/vie/src/vie-containermanager.js +0 -263
  1280. data/vendor/assets/javascripts/aloha/plugins/extra/vie/src/vie.js +0 -20
@@ -1,9 +1,9 @@
1
1
  /**
2
- * @license RequireJS i18n 0.24.0 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.
2
+ * @license RequireJS i18n 2.0.1 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved.
3
3
  * Available via the MIT or new BSD license.
4
- * see: http://github.com/jrburke/requirejs for details
4
+ * see: http://github.com/requirejs/i18n for details
5
5
  */
6
- /*jslint regexp: false, nomen: false, plusplus: false, strict: false */
6
+ /*jslint regexp: true */
7
7
  /*global require: false, navigator: false, define: false */
8
8
 
9
9
  /**
@@ -35,6 +35,8 @@
35
35
  * for the nls/fr-fr/colors bundle to be that mixed in locale.
36
36
  */
37
37
  (function () {
38
+ 'use strict';
39
+
38
40
  //regexp for reconstructing the master bundle name from parts of the regexp match
39
41
  //nlsRegExp.exec("foo/bar/baz/nls/en-ca/foo") gives:
40
42
  //["foo/bar/baz/nls/en-ca/foo", "foo/bar/baz/nls/", "/", "/", "en-ca", "foo"]
@@ -57,97 +59,134 @@
57
59
 
58
60
  function addIfExists(req, locale, toLoad, prefix, suffix) {
59
61
  var fullName = prefix + locale + '/' + suffix;
60
- if (require._fileExists(req.nameToUrl(fullName, null))) {
62
+ if (require._fileExists(req.toUrl(fullName))) {
61
63
  toLoad.push(fullName);
62
64
  }
63
65
  }
64
66
 
65
- define({
66
- version: '0.24.0',
67
- /**
68
- * Called when a dependency needs to be loaded.
69
- */
70
- load: function (name, req, onLoad, config) {
71
- config = config || {};
72
-
73
- var masterName,
74
- match = nlsRegExp.exec(name),
75
- prefix = match[1],
76
- locale = match[4],
77
- suffix = match[5],
78
- parts = locale.split("-"),
79
- toLoad = [],
80
- value = {},
81
- i, part, current = "";
82
-
83
- //If match[5] is blank, it means this is the top bundle definition,
84
- //so it does not have to be handled. Locale-specific requests
85
- //will have a match[4] value but no match[5]
86
- if (match[5]) {
87
- //locale-specific bundle
88
- prefix = match[1];
89
- masterName = prefix + suffix;
90
- } else {
91
- //Top-level bundle.
92
- masterName = name;
93
- suffix = match[4];
94
- locale = config.locale || (config.locale =
95
- typeof navigator === "undefined" ? "root" :
96
- (navigator.language ||
97
- navigator.userLanguage || "root").toLowerCase());
98
- parts = locale.split("-");
67
+ /**
68
+ * Simple function to mix in properties from source into target,
69
+ * but only if target does not already have a property of the same name.
70
+ * This is not robust in IE for transferring methods that match
71
+ * Object.prototype names, but the uses of mixin here seem unlikely to
72
+ * trigger a problem related to that.
73
+ */
74
+ function mixin(target, source, force) {
75
+ var prop;
76
+ for (prop in source) {
77
+ if (source.hasOwnProperty(prop) && (!target.hasOwnProperty(prop) || force)) {
78
+ target[prop] = source[prop];
79
+ } else if (typeof source[prop] === 'object') {
80
+ mixin(target[prop], source[prop], force);
99
81
  }
82
+ }
83
+ }
84
+
85
+ define(['module'], function (module) {
86
+ var masterConfig = module.config();
87
+
88
+ return {
89
+ version: '2.0.1',
90
+ /**
91
+ * Called when a dependency needs to be loaded.
92
+ */
93
+ load: function (name, req, onLoad, config) {
94
+ config = config || {};
100
95
 
101
- if (config.isBuild) {
102
- //Check for existence of all locale possible files and
103
- //require them if exist.
104
- toLoad.push(masterName);
105
- addIfExists(req, "root", toLoad, prefix, suffix);
106
- for (i = 0; (part = parts[i]); i++) {
107
- current += (current ? "-" : "") + part;
108
- addIfExists(req, current, toLoad, prefix, suffix);
96
+ if (config.locale) {
97
+ masterConfig.locale = config.locale;
98
+ }
99
+
100
+ var masterName,
101
+ match = nlsRegExp.exec(name),
102
+ prefix = match[1],
103
+ locale = match[4],
104
+ suffix = match[5],
105
+ parts = locale.split("-"),
106
+ toLoad = [],
107
+ value = {},
108
+ i, part, current = "";
109
+
110
+ //If match[5] is blank, it means this is the top bundle definition,
111
+ //so it does not have to be handled. Locale-specific requests
112
+ //will have a match[4] value but no match[5]
113
+ if (match[5]) {
114
+ //locale-specific bundle
115
+ prefix = match[1];
116
+ masterName = prefix + suffix;
117
+ } else {
118
+ //Top-level bundle.
119
+ masterName = name;
120
+ suffix = match[4];
121
+ locale = masterConfig.locale;
122
+ if (!locale) {
123
+ locale = masterConfig.locale =
124
+ typeof navigator === "undefined" ? "root" :
125
+ (navigator.language ||
126
+ navigator.userLanguage || "root").toLowerCase();
127
+ }
128
+ parts = locale.split("-");
109
129
  }
110
- req(toLoad);
111
- onLoad();
112
- } else {
113
- //First, fetch the master bundle, it knows what locales are available.
114
- req([masterName], function (master) {
115
- //Figure out the best fit
116
- var needed = [];
117
-
118
- //Always allow for root, then do the rest of the locale parts.
119
- addPart("root", master, needed, toLoad, prefix, suffix);
120
- for (i = 0; (part = parts[i]); i++) {
130
+
131
+ if (config.isBuild) {
132
+ //Check for existence of all locale possible files and
133
+ //require them if exist.
134
+ toLoad.push(masterName);
135
+ addIfExists(req, "root", toLoad, prefix, suffix);
136
+ for (i = 0; i < parts.length; i++) {
137
+ part = parts[i];
121
138
  current += (current ? "-" : "") + part;
122
- addPart(current, master, needed, toLoad, prefix, suffix);
139
+ addIfExists(req, current, toLoad, prefix, suffix);
123
140
  }
124
141
 
125
- //Load all the parts missing.
126
142
  req(toLoad, function () {
127
- var i, partBundle;
128
- for (i = needed.length - 1; i > -1 && (part = needed[i]); i--) {
129
- partBundle = master[part];
130
- if (partBundle === true || partBundle === 1) {
131
- partBundle = req(prefix + part + '/' + suffix);
132
- }
133
- require.mixin(value, partBundle);
143
+ onLoad();
144
+ });
145
+ } else {
146
+ //First, fetch the master bundle, it knows what locales are available.
147
+ req([masterName], function (master) {
148
+ //Figure out the best fit
149
+ var needed = [],
150
+ part;
151
+
152
+ //Always allow for root, then do the rest of the locale parts.
153
+ addPart("root", master, needed, toLoad, prefix, suffix);
154
+ for (i = 0; i < parts.length; i++) {
155
+ part = parts[i];
156
+ current += (current ? "-" : "") + part;
157
+ addPart(current, master, needed, toLoad, prefix, suffix);
134
158
  }
135
-
136
- // MODIFICATION FROM ALOHA START: add a t() function
137
- value.t = function(key) {
138
- if (this[key]) {
139
- return this[key];
140
- } else {
141
- return key;
159
+
160
+ //Load all the parts missing.
161
+ req(toLoad, function () {
162
+ var i, partBundle, part;
163
+ for (i = needed.length - 1; i > -1 && needed[i]; i--) {
164
+ part = needed[i];
165
+ partBundle = master[part];
166
+ if (partBundle === true || partBundle === 1) {
167
+ partBundle = req(prefix + part + '/' + suffix);
168
+ }
169
+ mixin(value, partBundle);
170
+ }
171
+
172
+ // MODIFICATION FROM ALOHA START: add a t() function
173
+ value.t = function( key, defaultValue ) {
174
+ if ( this[key] ) {
175
+ return this[key];
176
+ } else if ( defaultValue ) {
177
+ return defaultValue;
178
+ } else {
179
+ return key;
180
+ }
142
181
  }
143
- }
144
- // END OF ALOHA MODIFICATION
182
+ // END OF ALOHA MODIFICATION
145
183
 
146
- //All done, notify the loader.
147
- onLoad(value);
184
+ //All done, notify the loader.
185
+ onLoad(value);
186
+ });
148
187
  });
149
- });
188
+ }
150
189
  }
151
- }
190
+ };
152
191
  });
153
192
  }());
@@ -1,54 +1,100 @@
1
1
  /** vim: et:ts=4:sw=4:sts=4
2
- * @license RequireJS 0.26.0+ Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.
2
+ * @license RequireJS 2.0.5 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved.
3
3
  * Available via the MIT or new BSD license.
4
4
  * see: http://github.com/jrburke/requirejs for details
5
5
  */
6
- /*jslint strict: false, plusplus: false */
7
- /*global window: false, navigator: false, document: false, importScripts: false,
8
- jQuery: false, clearInterval: false, setInterval: false, self: false,
9
- setTimeout: false, opera: false */
6
+ //Not using strict: uneven strict support in browsers, #392, and causes
7
+ //problems with requirejs.exec()/transpiler plugins that may not be strict.
8
+ /*jslint regexp: true, nomen: true, sloppy: true */
9
+ /*global window, navigator, document, importScripts, jQuery, setTimeout, opera */
10
10
 
11
11
  var requirejs, require, define;
12
- (function () {
13
- //Change this version number for each release.
14
- var version = "0.26.0+",
15
- commentRegExp = /(\/\*([\s\S]*?)\*\/|\/\/(.*)$)/mg,
16
- cjsRequireRegExp = /require\(\s*["']([^'"\s]+)["']\s*\)/g,
17
- currDirRegExp = /^\.\//,
12
+ (function (global) {
13
+ var req, s, head, baseElement, dataMain, src,
14
+ interactiveScript, currentlyAddingScript, mainScript, subPath,
15
+ version = '2.0.5',
16
+ commentRegExp = /(\/\*([\s\S]*?)\*\/|([^:]|^)\/\/(.*)$)/mg,
17
+ cjsRequireRegExp = /[^.]\s*require\s*\(\s*["']([^'"\s]+)["']\s*\)/g,
18
18
  jsSuffixRegExp = /\.js$/,
19
- ostring = Object.prototype.toString,
19
+ currDirRegExp = /^\.\//,
20
+ op = Object.prototype,
21
+ ostring = op.toString,
22
+ hasOwn = op.hasOwnProperty,
20
23
  ap = Array.prototype,
21
24
  aps = ap.slice,
22
25
  apsp = ap.splice,
23
- isBrowser = !!(typeof window !== "undefined" && navigator && document),
24
- isWebWorker = !isBrowser && typeof importScripts !== "undefined",
26
+ isBrowser = !!(typeof window !== 'undefined' && navigator && document),
27
+ isWebWorker = !isBrowser && typeof importScripts !== 'undefined',
25
28
  //PS3 indicates loaded and complete, but need to wait for complete
26
- //specifically. Sequence is "loading", "loaded", execution,
27
- // then "complete". The UA check is unfortunate, but not sure how
29
+ //specifically. Sequence is 'loading', 'loaded', execution,
30
+ // then 'complete'. The UA check is unfortunate, but not sure how
28
31
  //to feature test w/o causing perf issues.
29
32
  readyRegExp = isBrowser && navigator.platform === 'PLAYSTATION 3' ?
30
33
  /^complete$/ : /^(complete|loaded)$/,
31
- defContextName = "_",
34
+ defContextName = '_',
32
35
  //Oh the tragedy, detecting opera. See the usage of isOpera for reason.
33
- isOpera = typeof opera !== "undefined" && opera.toString() === "[object Opera]",
34
- reqWaitIdPrefix = "_r@@",
35
- empty = {},
36
+ isOpera = typeof opera !== 'undefined' && opera.toString() === '[object Opera]',
36
37
  contexts = {},
38
+ cfg = {},
37
39
  globalDefQueue = [],
38
- interactiveScript = null,
39
- isDone = false,
40
- checkLoadedDepth = 0,
41
- useInteractive = false,
42
- req, cfg = {}, currentlyAddingScript, s, head, baseElement, scripts, script,
43
- src, subPath, mainScript, dataMain, i, scrollIntervalId, setReadyState, ctx,
44
- jQueryCheck, checkLoadedTimeoutId;
40
+ useInteractive = false;
45
41
 
46
42
  function isFunction(it) {
47
- return ostring.call(it) === "[object Function]";
43
+ return ostring.call(it) === '[object Function]';
48
44
  }
49
45
 
50
46
  function isArray(it) {
51
- return ostring.call(it) === "[object Array]";
47
+ return ostring.call(it) === '[object Array]';
48
+ }
49
+
50
+ /**
51
+ * Helper function for iterating over an array. If the func returns
52
+ * a true value, it will break out of the loop.
53
+ */
54
+ function each(ary, func) {
55
+ if (ary) {
56
+ var i;
57
+ for (i = 0; i < ary.length; i += 1) {
58
+ if (ary[i] && func(ary[i], i, ary)) {
59
+ break;
60
+ }
61
+ }
62
+ }
63
+ }
64
+
65
+ /**
66
+ * Helper function for iterating over an array backwards. If the func
67
+ * returns a true value, it will break out of the loop.
68
+ */
69
+ function eachReverse(ary, func) {
70
+ if (ary) {
71
+ var i;
72
+ for (i = ary.length - 1; i > -1; i -= 1) {
73
+ if (ary[i] && func(ary[i], i, ary)) {
74
+ break;
75
+ }
76
+ }
77
+ }
78
+ }
79
+
80
+ function hasProp(obj, prop) {
81
+ return hasOwn.call(obj, prop);
82
+ }
83
+
84
+ /**
85
+ * Cycles over properties in an object and calls a function for each
86
+ * property value. If the function returns a truthy value, then the
87
+ * iteration is stopped.
88
+ */
89
+ function eachProp(obj, func) {
90
+ var prop;
91
+ for (prop in obj) {
92
+ if (obj.hasOwnProperty(prop)) {
93
+ if (func(obj[prop], prop)) {
94
+ break;
95
+ }
96
+ }
97
+ }
52
98
  }
53
99
 
54
100
  /**
@@ -58,13 +104,82 @@ var requirejs, require, define;
58
104
  * Object.prototype names, but the uses of mixin here seem unlikely to
59
105
  * trigger a problem related to that.
60
106
  */
61
- function mixin(target, source, force) {
62
- for (var prop in source) {
63
- if (!(prop in empty) && (!(prop in target) || force)) {
64
- target[prop] = source[prop];
65
- }
107
+ function mixin(target, source, force, deepStringMixin) {
108
+ if (source) {
109
+ eachProp(source, function (value, prop) {
110
+ if (force || !hasProp(target, prop)) {
111
+ if (deepStringMixin && typeof value !== 'string') {
112
+ if (!target[prop]) {
113
+ target[prop] = {};
114
+ }
115
+ mixin(target[prop], value, force, deepStringMixin);
116
+ } else {
117
+ target[prop] = value;
118
+ }
119
+ }
120
+ });
121
+ }
122
+ return target;
123
+ }
124
+
125
+ //Similar to Function.prototype.bind, but the 'this' object is specified
126
+ //first, since it is easier to read/figure out what 'this' will be.
127
+ function bind(obj, fn) {
128
+ return function () {
129
+ return fn.apply(obj, arguments);
130
+ };
131
+ }
132
+
133
+ function scripts() {
134
+ return document.getElementsByTagName('script');
135
+ }
136
+
137
+ //Allow getting a global that expressed in
138
+ //dot notation, like 'a.b.c'.
139
+ function getGlobal(value) {
140
+ if (!value) {
141
+ return value;
66
142
  }
67
- return req;
143
+ var g = global;
144
+ each(value.split('.'), function (part) {
145
+ g = g[part];
146
+ });
147
+ return g;
148
+ }
149
+
150
+ function makeContextModuleFunc(func, relMap, enableBuildCallback) {
151
+ return function () {
152
+ //A version of a require function that passes a moduleName
153
+ //value for items that may need to
154
+ //look up paths relative to the moduleName
155
+ var args = aps.call(arguments, 0), lastArg;
156
+ if (enableBuildCallback &&
157
+ isFunction((lastArg = args[args.length - 1]))) {
158
+ lastArg.__requireJsBuild = true;
159
+ }
160
+ args.push(relMap);
161
+ return func.apply(null, args);
162
+ };
163
+ }
164
+
165
+ function addRequireMethods(req, context, relMap) {
166
+ each([
167
+ ['toUrl'],
168
+ ['undef'],
169
+ ['defined', 'requireDefined'],
170
+ ['specified', 'requireSpecified']
171
+ ], function (item) {
172
+ var prop = item[1] || item[0];
173
+ req[item[0]] = context ? makeContextModuleFunc(context[prop], relMap) :
174
+ //If no context, then use default context. Reference from
175
+ //contexts instead of early binding to default context, so
176
+ //that during builds, the latest instance of the default
177
+ //context with its config gets used.
178
+ function () {
179
+ var ctx = contexts[defContextName];
180
+ return ctx[prop].apply(ctx, arguments);
181
+ };
182
+ });
68
183
  }
69
184
 
70
185
  /**
@@ -75,125 +190,60 @@ var requirejs, require, define;
75
190
  *
76
191
  * @returns {Error}
77
192
  */
78
- function makeError(id, msg, err) {
193
+ function makeError(id, msg, err, requireModules) {
79
194
  var e = new Error(msg + '\nhttp://requirejs.org/docs/errors.html#' + id);
195
+ e.requireType = id;
196
+ e.requireModules = requireModules;
80
197
  if (err) {
81
198
  e.originalError = err;
82
199
  }
83
200
  return e;
84
201
  }
85
202
 
86
- /**
87
- * Used to set up package paths from a packagePaths or packages config object.
88
- * @param {Object} pkgs the object to store the new package config
89
- * @param {Array} currentPackages an array of packages to configure
90
- * @param {String} [dir] a prefix dir to use.
91
- */
92
- function configurePackageDir(pkgs, currentPackages, dir) {
93
- var i, location, pkgObj;
94
-
95
- for (i = 0; (pkgObj = currentPackages[i]); i++) {
96
- pkgObj = typeof pkgObj === "string" ? { name: pkgObj } : pkgObj;
97
- location = pkgObj.location;
98
-
99
- //Add dir to the path, but avoid paths that start with a slash
100
- //or have a colon (indicates a protocol)
101
- if (dir && (!location || (location.indexOf("/") !== 0 && location.indexOf(":") === -1))) {
102
- location = dir + "/" + (location || pkgObj.name);
103
- }
104
-
105
- //Create a brand new object on pkgs, since currentPackages can
106
- //be passed in again, and config.pkgs is the internal transformed
107
- //state for all package configs.
108
- pkgs[pkgObj.name] = {
109
- name: pkgObj.name,
110
- location: location || pkgObj.name,
111
- //Remove leading dot in main, so main paths are normalized,
112
- //and remove any trailing .js, since different package
113
- //envs have different conventions: some use a module name,
114
- //some use a file name.
115
- main: (pkgObj.main || "main")
116
- .replace(currDirRegExp, '')
117
- .replace(jsSuffixRegExp, '')
118
- };
119
- }
120
- }
121
-
122
- /**
123
- * jQuery 1.4.3-1.5.x use a readyWait/ready() pairing to hold DOM
124
- * ready callbacks, but jQuery 1.6 supports a holdReady() API instead.
125
- * At some point remove the readyWait/ready() support and just stick
126
- * with using holdReady.
127
- */
128
- function jQueryHoldReady($, shouldHold) {
129
- if ($.holdReady) {
130
- $.holdReady(shouldHold);
131
- } else if (shouldHold) {
132
- $.readyWait += 1;
133
- } else {
134
- $.ready(true);
135
- }
136
- }
137
-
138
- if (typeof define !== "undefined") {
203
+ if (typeof define !== 'undefined') {
139
204
  //If a define is already in play via another AMD loader,
140
205
  //do not overwrite.
141
206
  return;
142
207
  }
143
208
 
144
- if (typeof requirejs !== "undefined") {
209
+ if (typeof requirejs !== 'undefined') {
145
210
  if (isFunction(requirejs)) {
146
211
  //Do not overwrite and existing requirejs instance.
147
212
  return;
148
- } else {
149
- cfg = requirejs;
150
- requirejs = undefined;
151
213
  }
214
+ cfg = requirejs;
215
+ requirejs = undefined;
152
216
  }
153
217
 
154
218
  //Allow for a require config object
155
- if (typeof require !== "undefined" && !isFunction(require)) {
219
+ if (typeof require !== 'undefined' && !isFunction(require)) {
156
220
  //assume it is a config object.
157
221
  cfg = require;
158
222
  require = undefined;
159
223
  }
160
224
 
161
- /**
162
- * Creates a new context for use in require and define calls.
163
- * Handle most of the heavy lifting. Do not want to use an object
164
- * with prototype here to avoid using "this" in require, in case it
165
- * needs to be used in more super secure envs that do not want this.
166
- * Also there should not be that many contexts in the page. Usually just
167
- * one for the default context, but could be extra for multiversion cases
168
- * or if a package needs a special context for a dependency that conflicts
169
- * with the standard context.
170
- */
171
225
  function newContext(contextName) {
172
- var context, resume,
226
+ var inCheckLoaded, Module, context, handlers,
227
+ checkLoadedTimeoutId,
173
228
  config = {
174
229
  waitSeconds: 7,
175
- baseUrl: s.baseUrl || "./",
230
+ baseUrl: './',
176
231
  paths: {},
177
232
  pkgs: {},
178
- catchError: {}
233
+ shim: {}
179
234
  },
235
+ registry = {},
236
+ undefEvents = {},
180
237
  defQueue = [],
181
- specified = {
182
- "require": true,
183
- "exports": true,
184
- "module": true
185
- },
186
- urlMap = {},
187
238
  defined = {},
188
- loaded = {},
189
- waiting = {},
190
- waitAry = [],
191
- waitIdCounter = 0,
192
- managerCallbacks = {},
193
- plugins = {},
194
- pluginsQueue = {},
195
- resumeDepth = 0,
196
- normalizedWaiting = {};
239
+ urlFetched = {},
240
+ requireCounter = 1,
241
+ unnormalizedCounter = 1,
242
+ //Used to track the order in which modules
243
+ //should be executed, by the order they
244
+ //load. Important for consistent cycle resolution
245
+ //behavior.
246
+ waitAry = [];
197
247
 
198
248
  /**
199
249
  * Trims the . and .. from an array of path segments.
@@ -206,11 +256,12 @@ var requirejs, require, define;
206
256
  */
207
257
  function trimDots(ary) {
208
258
  var i, part;
209
- for (i = 0; (part = ary[i]); i++) {
210
- if (part === ".") {
259
+ for (i = 0; ary[i]; i += 1) {
260
+ part = ary[i];
261
+ if (part === '.') {
211
262
  ary.splice(i, 1);
212
263
  i -= 1;
213
- } else if (part === "..") {
264
+ } else if (part === '..') {
214
265
  if (i === 1 && (ary[2] === '..' || ary[0] === '..')) {
215
266
  //End of the line. Keep at least one non-dot
216
267
  //path segment at the front so it can be mapped
@@ -233,13 +284,20 @@ var requirejs, require, define;
233
284
  * @param {String} name the relative name
234
285
  * @param {String} baseName a real name that the name arg is relative
235
286
  * to.
287
+ * @param {Boolean} applyMap apply the map config to the value. Should
288
+ * only be done if this normalization is for a dependency ID.
236
289
  * @returns {String} normalized name
237
290
  */
238
- function normalize(name, baseName) {
239
- var pkgName, pkgConfig;
291
+ function normalize(name, baseName, applyMap) {
292
+ var pkgName, pkgConfig, mapValue, nameParts, i, j, nameSegment,
293
+ foundMap, foundI, foundStarMap, starI,
294
+ baseParts = baseName && baseName.split('/'),
295
+ normalizedBaseParts = baseParts,
296
+ map = config.map,
297
+ starMap = map && map['*'];
240
298
 
241
299
  //Adjust any relative paths.
242
- if (name && name.charAt(0) === ".") {
300
+ if (name && name.charAt(0) === '.') {
243
301
  //If have a base name, try to normalize against it,
244
302
  //otherwise, assume it is a top-level require that will
245
303
  //be relative to baseUrl in the end.
@@ -247,32 +305,112 @@ var requirejs, require, define;
247
305
  if (config.pkgs[baseName]) {
248
306
  //If the baseName is a package name, then just treat it as one
249
307
  //name to concat the name with.
250
- baseName = [baseName];
308
+ normalizedBaseParts = baseParts = [baseName];
251
309
  } else {
252
310
  //Convert baseName to array, and lop off the last part,
253
- //so that . matches that "directory" and not name of the baseName's
254
- //module. For instance, baseName of "one/two/three", maps to
255
- //"one/two/three.js", but we want the directory, "one/two" for
311
+ //so that . matches that 'directory' and not name of the baseName's
312
+ //module. For instance, baseName of 'one/two/three', maps to
313
+ //'one/two/three.js', but we want the directory, 'one/two' for
256
314
  //this normalization.
257
- baseName = baseName.split("/");
258
- baseName = baseName.slice(0, baseName.length - 1);
315
+ normalizedBaseParts = baseParts.slice(0, baseParts.length - 1);
259
316
  }
260
317
 
261
- name = baseName.concat(name.split("/"));
318
+ name = normalizedBaseParts.concat(name.split('/'));
262
319
  trimDots(name);
263
320
 
264
321
  //Some use of packages may use a . path to reference the
265
- //"main" module name, so normalize for that.
322
+ //'main' module name, so normalize for that.
266
323
  pkgConfig = config.pkgs[(pkgName = name[0])];
267
- name = name.join("/");
324
+ name = name.join('/');
268
325
  if (pkgConfig && name === pkgName + '/' + pkgConfig.main) {
269
326
  name = pkgName;
270
327
  }
328
+ } else if (name.indexOf('./') === 0) {
329
+ // No baseName, so this is ID is resolved relative
330
+ // to baseUrl, pull off the leading dot.
331
+ name = name.substring(2);
271
332
  }
272
333
  }
334
+
335
+ //Apply map config if available.
336
+ if (applyMap && (baseParts || starMap) && map) {
337
+ nameParts = name.split('/');
338
+
339
+ for (i = nameParts.length; i > 0; i -= 1) {
340
+ nameSegment = nameParts.slice(0, i).join('/');
341
+
342
+ if (baseParts) {
343
+ //Find the longest baseName segment match in the config.
344
+ //So, do joins on the biggest to smallest lengths of baseParts.
345
+ for (j = baseParts.length; j > 0; j -= 1) {
346
+ mapValue = map[baseParts.slice(0, j).join('/')];
347
+
348
+ //baseName segment has config, find if it has one for
349
+ //this name.
350
+ if (mapValue) {
351
+ mapValue = mapValue[nameSegment];
352
+ if (mapValue) {
353
+ //Match, update name to the new value.
354
+ foundMap = mapValue;
355
+ foundI = i;
356
+ break;
357
+ }
358
+ }
359
+ }
360
+ }
361
+
362
+ if (foundMap) {
363
+ break;
364
+ }
365
+
366
+ //Check for a star map match, but just hold on to it,
367
+ //if there is a shorter segment match later in a matching
368
+ //config, then favor over this star map.
369
+ if (!foundStarMap && starMap && starMap[nameSegment]) {
370
+ foundStarMap = starMap[nameSegment];
371
+ starI = i;
372
+ }
373
+ }
374
+
375
+ if (!foundMap && foundStarMap) {
376
+ foundMap = foundStarMap;
377
+ foundI = starI;
378
+ }
379
+
380
+ if (foundMap) {
381
+ nameParts.splice(0, foundI, foundMap);
382
+ name = nameParts.join('/');
383
+ }
384
+ }
385
+
273
386
  return name;
274
387
  }
275
388
 
389
+ function removeScript(name) {
390
+ if (isBrowser) {
391
+ each(scripts(), function (scriptNode) {
392
+ if (scriptNode.getAttribute('data-requiremodule') === name &&
393
+ scriptNode.getAttribute('data-requirecontext') === context.contextName) {
394
+ scriptNode.parentNode.removeChild(scriptNode);
395
+ return true;
396
+ }
397
+ });
398
+ }
399
+ }
400
+
401
+ function hasPathFallback(id) {
402
+ var pathConfig = config.paths[id];
403
+ if (pathConfig && isArray(pathConfig) && pathConfig.length > 1) {
404
+ removeScript(id);
405
+ //Pop off the first array value, since it failed, and
406
+ //retry
407
+ pathConfig.shift();
408
+ context.undef(id);
409
+ context.require([id]);
410
+ return true;
411
+ }
412
+ }
413
+
276
414
  /**
277
415
  * Creates a module mapping that includes plugin prefix, module
278
416
  * name, and path. If parentModuleMap is provided it will
@@ -281,15 +419,28 @@ var requirejs, require, define;
281
419
  * @param {String} name the module name
282
420
  * @param {String} [parentModuleMap] parent module map
283
421
  * for the module name, used to resolve relative names.
422
+ * @param {Boolean} isNormalized: is the ID already normalized.
423
+ * This is true if this call is done for a define() module ID.
424
+ * @param {Boolean} applyMap: apply the map config to the ID.
425
+ * Should only be true if this map is for a dependency.
284
426
  *
285
427
  * @returns {Object}
286
428
  */
287
- function makeModuleMap(name, parentModuleMap) {
288
- var index = name ? name.indexOf("!") : -1,
429
+ function makeModuleMap(name, parentModuleMap, isNormalized, applyMap) {
430
+ var url, pluginModule, suffix,
431
+ index = name ? name.indexOf('!') : -1,
289
432
  prefix = null,
290
433
  parentName = parentModuleMap ? parentModuleMap.name : null,
291
434
  originalName = name,
292
- normalizedName, url, pluginModule;
435
+ isDefine = true,
436
+ normalizedName = '';
437
+
438
+ //If no name, then it means it is a require call, generate an
439
+ //internal name.
440
+ if (!name) {
441
+ isDefine = false;
442
+ name = '_@r' + (requireCounter += 1);
443
+ }
293
444
 
294
445
  if (index !== -1) {
295
446
  prefix = name.substring(0, index);
@@ -297,585 +448,362 @@ var requirejs, require, define;
297
448
  }
298
449
 
299
450
  if (prefix) {
300
- prefix = normalize(prefix, parentName);
451
+ prefix = normalize(prefix, parentName, applyMap);
452
+ pluginModule = defined[prefix];
301
453
  }
302
454
 
303
455
  //Account for relative paths if there is a base name.
304
456
  if (name) {
305
457
  if (prefix) {
306
- pluginModule = defined[prefix];
307
- if (pluginModule) {
308
- //Plugin is loaded, use its normalize method, otherwise,
309
- //normalize name as usual.
310
- if (pluginModule.normalize) {
311
- normalizedName = pluginModule.normalize(name, function (name) {
312
- return normalize(name, parentName);
313
- });
314
- } else {
315
- normalizedName = normalize(name, parentName);
316
- }
458
+ if (pluginModule && pluginModule.normalize) {
459
+ //Plugin is loaded, use its normalize method.
460
+ normalizedName = pluginModule.normalize(name, function (name) {
461
+ return normalize(name, parentName, applyMap);
462
+ });
317
463
  } else {
318
- //Plugin is not loaded yet, so do not normalize
319
- //the name, wait for plugin to load to see if
320
- //it has a normalize method. To avoid possible
321
- //ambiguity with relative names loaded from another
322
- //plugin, use the parent's name as part of this name.
323
- normalizedName = '__$p' + parentName + '@' + (name || '');
464
+ normalizedName = normalize(name, parentName, applyMap);
324
465
  }
325
466
  } else {
326
- normalizedName = normalize(name, parentName);
327
- }
328
-
329
- url = urlMap[normalizedName];
330
- if (!url) {
331
- //Calculate url for the module, if it has a name.
332
- if (req.toModuleUrl) {
333
- //Special logic required for a particular engine,
334
- //like Node.
335
- url = req.toModuleUrl(context, normalizedName, parentModuleMap);
336
- } else {
337
- url = context.nameToUrl(normalizedName, null, parentModuleMap);
338
- }
339
-
340
- //Store the URL mapping for later.
341
- urlMap[normalizedName] = url;
467
+ //A regular module.
468
+ normalizedName = normalize(name, parentName, applyMap);
469
+ url = context.nameToUrl(normalizedName);
342
470
  }
343
471
  }
344
472
 
473
+ //If the id is a plugin id that cannot be determined if it needs
474
+ //normalization, stamp it with a unique ID so two matching relative
475
+ //ids that may conflict can be separate.
476
+ suffix = prefix && !pluginModule && !isNormalized ?
477
+ '_unnormalized' + (unnormalizedCounter += 1) :
478
+ '';
479
+
345
480
  return {
346
481
  prefix: prefix,
347
482
  name: normalizedName,
348
483
  parentMap: parentModuleMap,
484
+ unnormalized: !!suffix,
349
485
  url: url,
350
486
  originalName: originalName,
351
- fullName: prefix ? prefix + "!" + (normalizedName || '') : normalizedName
487
+ isDefine: isDefine,
488
+ id: (prefix ?
489
+ prefix + '!' + normalizedName :
490
+ normalizedName) + suffix
352
491
  };
353
492
  }
354
493
 
355
- /**
356
- * Determine if priority loading is done. If so clear the priorityWait
357
- */
358
- function isPriorityDone() {
359
- var priorityDone = true,
360
- priorityWait = config.priorityWait,
361
- priorityName, i;
362
- if (priorityWait) {
363
- for (i = 0; (priorityName = priorityWait[i]); i++) {
364
- if (!loaded[priorityName]) {
365
- priorityDone = false;
366
- break;
367
- }
368
- }
369
- if (priorityDone) {
370
- delete config.priorityWait;
371
- }
494
+ function getModule(depMap) {
495
+ var id = depMap.id,
496
+ mod = registry[id];
497
+
498
+ if (!mod) {
499
+ mod = registry[id] = new context.Module(depMap);
372
500
  }
373
- return priorityDone;
374
- }
375
501
 
376
- /**
377
- * Helper function that creates a setExports function for a "module"
378
- * CommonJS dependency. Do this here to avoid creating a closure that
379
- * is part of a loop.
380
- */
381
- function makeSetExports(moduleObj) {
382
- return function (exports) {
383
- moduleObj.exports = exports;
384
- };
502
+ return mod;
385
503
  }
386
504
 
387
- function makeContextModuleFunc(func, relModuleMap, enableBuildCallback) {
388
- return function () {
389
- //A version of a require function that passes a moduleName
390
- //value for items that may need to
391
- //look up paths relative to the moduleName
392
- var args = [].concat(aps.call(arguments, 0)), lastArg;
393
- if (enableBuildCallback &&
394
- isFunction((lastArg = args[args.length - 1]))) {
395
- lastArg.__requireJsBuild = true;
396
- }
397
- args.push(relModuleMap);
398
- return func.apply(null, args);
399
- };
400
- }
505
+ function on(depMap, name, fn) {
506
+ var id = depMap.id,
507
+ mod = registry[id];
401
508
 
402
- /**
403
- * Helper function that creates a require function object to give to
404
- * modules that ask for it as a dependency. It needs to be specific
405
- * per module because of the implication of path mappings that may
406
- * need to be relative to the module name.
407
- */
408
- function makeRequire(relModuleMap, enableBuildCallback) {
409
- var modRequire = makeContextModuleFunc(context.require, relModuleMap, enableBuildCallback);
410
-
411
- mixin(modRequire, {
412
- nameToUrl: makeContextModuleFunc(context.nameToUrl, relModuleMap),
413
- toUrl: makeContextModuleFunc(context.toUrl, relModuleMap),
414
- defined: makeContextModuleFunc(context.requireDefined, relModuleMap),
415
- specified: makeContextModuleFunc(context.requireSpecified, relModuleMap),
416
- ready: req.ready,
417
- isBrowser: req.isBrowser
418
- });
419
- //Something used by node.
420
- if (req.paths) {
421
- modRequire.paths = req.paths;
509
+ if (hasProp(defined, id) &&
510
+ (!mod || mod.defineEmitComplete)) {
511
+ if (name === 'defined') {
512
+ fn(defined[id]);
513
+ }
514
+ } else {
515
+ getModule(depMap).on(name, fn);
422
516
  }
423
- return modRequire;
424
517
  }
425
518
 
426
- /**
427
- * Used to update the normalized name for plugin-based dependencies
428
- * after a plugin loads, since it can have its own normalization structure.
429
- * @param {String} pluginName the normalized plugin module name.
430
- */
431
- function updateNormalizedNames(pluginName) {
432
-
433
- var oldFullName, oldModuleMap, moduleMap, fullName, callbacks,
434
- i, j, k, depArray, existingCallbacks,
435
- maps = normalizedWaiting[pluginName];
436
-
437
- if (maps) {
438
- for (i = 0; (oldModuleMap = maps[i]); i++) {
439
- oldFullName = oldModuleMap.fullName;
440
- moduleMap = makeModuleMap(oldModuleMap.originalName, oldModuleMap.parentMap);
441
- fullName = moduleMap.fullName;
442
- //Callbacks could be undefined if the same plugin!name was
443
- //required twice in a row, so use empty array in that case.
444
- callbacks = managerCallbacks[oldFullName] || [];
445
- existingCallbacks = managerCallbacks[fullName];
446
-
447
- if (fullName !== oldFullName) {
448
- //Update the specified object, but only if it is already
449
- //in there. In sync environments, it may not be yet.
450
- if (oldFullName in specified) {
451
- delete specified[oldFullName];
452
- specified[fullName] = true;
453
- }
519
+ function onError(err, errback) {
520
+ var ids = err.requireModules,
521
+ notified = false;
454
522
 
455
- //Update managerCallbacks to use the correct normalized name.
456
- //If there are already callbacks for the normalized name,
457
- //just add to them.
458
- if (existingCallbacks) {
459
- managerCallbacks[fullName] = existingCallbacks.concat(callbacks);
460
- } else {
461
- managerCallbacks[fullName] = callbacks;
462
- }
463
- delete managerCallbacks[oldFullName];
464
-
465
- //In each manager callback, update the normalized name in the depArray.
466
- for (j = 0; j < callbacks.length; j++) {
467
- depArray = callbacks[j].depArray;
468
- for (k = 0; k < depArray.length; k++) {
469
- if (depArray[k] === oldFullName) {
470
- depArray[k] = fullName;
471
- }
472
- }
523
+ if (errback) {
524
+ errback(err);
525
+ } else {
526
+ each(ids, function (id) {
527
+ var mod = registry[id];
528
+ if (mod) {
529
+ //Set error on module, so it skips timeout checks.
530
+ mod.error = err;
531
+ if (mod.events.error) {
532
+ notified = true;
533
+ mod.emit('error', err);
473
534
  }
474
535
  }
536
+ });
537
+
538
+ if (!notified) {
539
+ req.onError(err);
475
540
  }
476
541
  }
477
-
478
- delete normalizedWaiting[pluginName];
479
542
  }
480
543
 
481
- /*
482
- * Queues a dependency for checking after the loader is out of a
483
- * "paused" state, for example while a script file is being loaded
484
- * in the browser, where it may have many modules defined in it.
485
- *
486
- * depName will be fully qualified, no relative . or .. path.
544
+ /**
545
+ * Internal method to transfer globalQueue items to this context's
546
+ * defQueue.
487
547
  */
488
- function queueDependency(dep) {
489
- //Make sure to load any plugin and associate the dependency
490
- //with that plugin.
491
- var prefix = dep.prefix,
492
- fullName = dep.fullName;
493
-
494
- //Do not bother if the depName is already in transit
495
- if (specified[fullName] || fullName in defined) {
496
- return;
548
+ function takeGlobalQueue() {
549
+ //Push all the globalDefQueue items into the context's defQueue
550
+ if (globalDefQueue.length) {
551
+ //Array splice in the values since the context code has a
552
+ //local var ref to defQueue, so cannot just reassign the one
553
+ //on context.
554
+ apsp.apply(defQueue,
555
+ [defQueue.length - 1, 0].concat(globalDefQueue));
556
+ globalDefQueue = [];
497
557
  }
558
+ }
498
559
 
499
- if (prefix && !plugins[prefix]) {
500
- //Queue up loading of the dependency, track it
501
- //via context.plugins. Mark it as a plugin so
502
- //that the build system will know to treat it
503
- //special.
504
- plugins[prefix] = undefined;
505
-
506
- //Remember this dep that needs to have normaliztion done
507
- //after the plugin loads.
508
- (normalizedWaiting[prefix] || (normalizedWaiting[prefix] = []))
509
- .push(dep);
510
-
511
- //Register an action to do once the plugin loads, to update
512
- //all managerCallbacks to use a properly normalized module
513
- //name.
514
- (managerCallbacks[prefix] ||
515
- (managerCallbacks[prefix] = [])).push({
516
- onDep: function (name, value) {
517
- if (name === prefix) {
518
- updateNormalizedNames(prefix);
519
- }
520
- }
521
- });
560
+ /**
561
+ * Helper function that creates a require function object to give to
562
+ * modules that ask for it as a dependency. It needs to be specific
563
+ * per module because of the implication of path mappings that may
564
+ * need to be relative to the module name.
565
+ */
566
+ function makeRequire(mod, enableBuildCallback, altRequire) {
567
+ var relMap = mod && mod.map,
568
+ modRequire = makeContextModuleFunc(altRequire || context.require,
569
+ relMap,
570
+ enableBuildCallback);
522
571
 
523
- queueDependency(makeModuleMap(prefix));
524
- }
572
+ addRequireMethods(modRequire, context, relMap);
573
+ modRequire.isBrowser = isBrowser;
525
574
 
526
- context.paused.push(dep);
575
+ return modRequire;
527
576
  }
528
577
 
529
- function execManager(manager) {
530
- var i, ret, waitingCallbacks, err, errFile, errModuleTree,
531
- cb = manager.callback,
532
- fullName = manager.fullName,
533
- args = [],
534
- ary = manager.depArray;
535
-
536
- //Call the callback to define the module, if necessary.
537
- if (cb && isFunction(cb)) {
538
- //Pull out the defined dependencies and pass the ordered
539
- //values to the callback.
540
- if (ary) {
541
- for (i = 0; i < ary.length; i++) {
542
- args.push(manager.deps[ary[i]]);
543
- }
578
+ handlers = {
579
+ 'require': function (mod) {
580
+ return makeRequire(mod);
581
+ },
582
+ 'exports': function (mod) {
583
+ mod.usingExports = true;
584
+ if (mod.map.isDefine) {
585
+ return (mod.exports = defined[mod.map.id] = {});
544
586
  }
587
+ },
588
+ 'module': function (mod) {
589
+ return (mod.module = {
590
+ id: mod.map.id,
591
+ uri: mod.map.url,
592
+ config: function () {
593
+ return (config.config && config.config[mod.map.id]) || {};
594
+ },
595
+ exports: defined[mod.map.id]
596
+ });
597
+ }
598
+ };
545
599
 
546
- if (config.catchError.define) {
547
- try {
548
- ret = req.execCb(fullName, manager.callback, args, defined[fullName]);
549
- } catch (e) {
550
- err = e;
551
- }
552
- } else {
553
- ret = req.execCb(fullName, manager.callback, args, defined[fullName]);
554
- }
600
+ function removeWaiting(id) {
601
+ //Clean up machinery used for waiting modules.
602
+ delete registry[id];
555
603
 
556
- if (fullName) {
557
- //If setting exports via "module" is in play,
558
- //favor that over return value and exports. After that,
559
- //favor a non-undefined return value over exports use.
560
- if (manager.cjsModule && manager.cjsModule.exports !== undefined) {
561
- ret = defined[fullName] = manager.cjsModule.exports;
562
- } else if (ret === undefined && manager.usingExports) {
563
- //exports already set the defined value.
564
- ret = defined[fullName];
565
- } else {
566
- //Use the return value from the function.
567
- defined[fullName] = ret;
604
+ each(waitAry, function (mod, i) {
605
+ if (mod.map.id === id) {
606
+ waitAry.splice(i, 1);
607
+ if (!mod.defined) {
608
+ context.waitCount -= 1;
568
609
  }
610
+ return true;
569
611
  }
570
- } else if (fullName) {
571
- //May just be an object definition for the module. Only
572
- //worry about defining if have a module name.
573
- ret = defined[fullName] = cb;
574
- }
612
+ });
613
+ }
575
614
 
576
- //Clean up waiting. Do this before error calls, and before
577
- //calling back waitingCallbacks, so that bookkeeping is correct
578
- //in the event of an error and error is reported in correct order,
579
- //since the waitingCallbacks will likely have errors if the
580
- //onError function does not throw.
581
- if (waiting[manager.waitId]) {
582
- delete waiting[manager.waitId];
583
- manager.isDone = true;
584
- context.waitCount -= 1;
585
- if (context.waitCount === 0) {
586
- //Clear the wait array used for cycles.
587
- waitAry = [];
588
- }
589
- }
615
+ function findCycle(mod, traced) {
616
+ var id = mod.map.id,
617
+ depArray = mod.depMaps,
618
+ foundModule;
590
619
 
591
- if (err) {
592
- errFile = (fullName ? makeModuleMap(fullName).url : '') ||
593
- err.fileName || err.sourceURL;
594
- errModuleTree = err.moduleTree;
595
- err = makeError('defineerror', 'Error evaluating ' +
596
- 'module "' + fullName + '" at location "' +
597
- errFile + '":\n' +
598
- err + '\nfileName:' + errFile +
599
- '\nlineNumber: ' + (err.lineNumber || err.line), err);
600
- err.moduleName = fullName;
601
- err.moduleTree = errModuleTree;
602
- return req.onError(err);
620
+ //Do not bother with unitialized modules or not yet enabled
621
+ //modules.
622
+ if (!mod.inited) {
623
+ return;
603
624
  }
604
625
 
605
- if (fullName) {
606
- //If anything was waiting for this module to be defined,
607
- //notify them now.
608
- waitingCallbacks = managerCallbacks[fullName];
609
- if (waitingCallbacks) {
610
- for (i = 0; i < waitingCallbacks.length; i++) {
611
- waitingCallbacks[i].onDep(fullName, ret);
612
- }
613
- delete managerCallbacks[fullName];
614
- }
626
+ //Found the cycle.
627
+ if (traced[id]) {
628
+ return mod;
615
629
  }
616
630
 
617
- return undefined;
618
- }
631
+ traced[id] = true;
619
632
 
620
- function main(inName, depArray, callback, relModuleMap) {
621
- var moduleMap = makeModuleMap(inName, relModuleMap),
622
- name = moduleMap.name,
623
- fullName = moduleMap.fullName,
624
- uniques = {},
625
- manager = {
626
- //Use a wait ID because some entries are anon
627
- //async require calls.
628
- waitId: name || reqWaitIdPrefix + (waitIdCounter++),
629
- depCount: 0,
630
- depMax: 0,
631
- prefix: moduleMap.prefix,
632
- name: name,
633
- fullName: fullName,
634
- deps: {},
635
- depArray: depArray,
636
- callback: callback,
637
- onDep: function (depName, value) {
638
- if (!(depName in manager.deps)) {
639
- manager.deps[depName] = value;
640
- manager.depCount += 1;
641
- if (manager.depCount === manager.depMax) {
642
- //All done, execute!
643
- execManager(manager);
644
- }
645
- }
646
- }
647
- },
648
- i, depArg, depName, cjsMod;
649
-
650
- if (fullName) {
651
- //If module already defined for context, or already loaded,
652
- //then leave. Also leave if jQuery is registering but it does
653
- //not match the desired version number in the config.
654
- if (fullName in defined || loaded[fullName] === true ||
655
- (fullName === "jquery" && config.jQuery &&
656
- config.jQuery !== callback().fn.jquery)) {
633
+ //Trace through the dependencies.
634
+ each(depArray, function (depMap) {
635
+ var depId = depMap.id,
636
+ depMod = registry[depId];
637
+
638
+ if (!depMod) {
657
639
  return;
658
640
  }
659
641
 
660
- //Set specified/loaded here for modules that are also loaded
661
- //as part of a layer, where onScriptLoad is not fired
662
- //for those cases. Do this after the inline define and
663
- //dependency tracing is done.
664
- specified[fullName] = true;
665
- loaded[fullName] = true;
666
-
667
- //If module is jQuery set up delaying its dom ready listeners.
668
- if (fullName === "jquery" && callback) {
669
- jQueryCheck(callback());
642
+ if (!depMod.inited || !depMod.enabled) {
643
+ //Dependency is not inited, so this cannot
644
+ //be used to determine a cycle.
645
+ foundModule = null;
646
+ delete traced[id];
647
+ return true;
670
648
  }
671
- }
672
-
673
- //Add the dependencies to the deps field, and register for callbacks
674
- //on the dependencies.
675
- for (i = 0; i < depArray.length; i++) {
676
- depArg = depArray[i];
677
- //There could be cases like in IE, where a trailing comma will
678
- //introduce a null dependency, so only treat a real dependency
679
- //value as a dependency.
680
- if (depArg) {
681
- //Split the dependency name into plugin and name parts
682
- depArg = makeModuleMap(depArg, (name ? moduleMap : relModuleMap));
683
- depName = depArg.fullName;
684
-
685
- //Fix the name in depArray to be just the name, since
686
- //that is how it will be called back later.
687
- depArray[i] = depName;
688
-
689
- //Fast path CommonJS standard dependencies.
690
- if (depName === "require") {
691
- manager.deps[depName] = makeRequire(moduleMap);
692
- } else if (depName === "exports") {
693
- //CommonJS module spec 1.1
694
- manager.deps[depName] = defined[fullName] = {};
695
- manager.usingExports = true;
696
- } else if (depName === "module") {
697
- //CommonJS module spec 1.1
698
- manager.cjsModule = cjsMod = manager.deps[depName] = {
699
- id: name,
700
- uri: name ? context.nameToUrl(name, null, relModuleMap) : undefined,
701
- exports: defined[fullName]
702
- };
703
- cjsMod.setExports = makeSetExports(cjsMod);
704
- } else if (depName in defined && !(depName in waiting)) {
705
- //Module already defined, no need to wait for it.
706
- manager.deps[depName] = defined[depName];
707
- } else if (!uniques[depName]) {
708
649
 
709
- //A dynamic dependency.
710
- manager.depMax += 1;
650
+ //mixin traced to a new object for each dependency, so that
651
+ //sibling dependencies in this object to not generate a
652
+ //false positive match on a cycle. Ideally an Object.create
653
+ //type of prototype delegation would be used here, but
654
+ //optimizing for file size vs. execution speed since hopefully
655
+ //the trees are small for circular dependency scans relative
656
+ //to the full app perf.
657
+ return (foundModule = findCycle(depMod, mixin({}, traced)));
658
+ });
711
659
 
712
- queueDependency(depArg);
660
+ return foundModule;
661
+ }
713
662
 
714
- //Register to get notification when dependency loads.
715
- (managerCallbacks[depName] ||
716
- (managerCallbacks[depName] = [])).push(manager);
663
+ function forceExec(mod, traced, uninited) {
664
+ var id = mod.map.id,
665
+ depArray = mod.depMaps;
717
666
 
718
- uniques[depName] = true;
719
- }
720
- }
667
+ if (!mod.inited || !mod.map.isDefine) {
668
+ return;
721
669
  }
722
670
 
723
- //Do not bother tracking the manager if it is all done.
724
- if (manager.depCount === manager.depMax) {
725
- //All done, execute!
726
- execManager(manager);
727
- } else {
728
- waiting[manager.waitId] = manager;
729
- waitAry.push(manager);
730
- context.waitCount += 1;
671
+ if (traced[id]) {
672
+ return defined[id];
731
673
  }
732
- }
733
674
 
734
- /**
735
- * Convenience method to call main for a define call that was put on
736
- * hold in the defQueue.
737
- */
738
- function callDefMain(args) {
739
- main.apply(null, args);
740
- //Mark the module loaded. Must do it here in addition
741
- //to doing it in define in case a script does
742
- //not call define
743
- loaded[args[0]] = true;
744
- }
675
+ traced[id] = mod;
745
676
 
746
- /**
747
- * jQuery 1.4.3+ supports ways to hold off calling
748
- * calling jQuery ready callbacks until all scripts are loaded. Be sure
749
- * to track it if the capability exists.. Also, since jQuery 1.4.3 does
750
- * not register as a module, need to do some global inference checking.
751
- * Even if it does register as a module, not guaranteed to be the precise
752
- * name of the global. If a jQuery is tracked for this context, then go
753
- * ahead and register it as a module too, if not already in process.
754
- */
755
- jQueryCheck = function (jqCandidate) {
756
- if (!context.jQuery) {
757
- var $ = jqCandidate || (typeof jQuery !== "undefined" ? jQuery : null);
758
-
759
- if ($) {
760
- //If a specific version of jQuery is wanted, make sure to only
761
- //use this jQuery if it matches.
762
- if (config.jQuery && $.fn.jquery !== config.jQuery) {
763
- return;
764
- }
677
+ each(depArray, function (depMap) {
678
+ var depId = depMap.id,
679
+ depMod = registry[depId],
680
+ value;
765
681
 
766
- if ("holdReady" in $ || "readyWait" in $) {
767
- context.jQuery = $;
768
-
769
- //Manually create a "jquery" module entry if not one already
770
- //or in process. Note this could trigger an attempt at
771
- //a second jQuery registration, but does no harm since
772
- //the first one wins, and it is the same value anyway.
773
- callDefMain(["jquery", [], function () {
774
- return jQuery;
775
- }]);
776
-
777
- //Ask jQuery to hold DOM ready callbacks.
778
- if (context.scriptCount) {
779
- jQueryHoldReady($, true);
780
- context.jQueryIncremented = true;
781
- }
782
- }
682
+ if (handlers[depId]) {
683
+ return;
783
684
  }
784
- }
785
- };
786
685
 
787
- function forceExec(manager, traced) {
788
- if (manager.isDone) {
789
- return undefined;
790
- }
791
-
792
- var fullName = manager.fullName,
793
- depArray = manager.depArray,
794
- depName, i;
795
- if (fullName) {
796
- if (traced[fullName]) {
797
- return defined[fullName];
798
- }
686
+ if (depMod) {
687
+ if (!depMod.inited || !depMod.enabled) {
688
+ //Dependency is not inited,
689
+ //so this module cannot be
690
+ //given a forced value yet.
691
+ uninited[id] = true;
692
+ return;
693
+ }
799
694
 
800
- traced[fullName] = true;
801
- }
695
+ //Get the value for the current dependency
696
+ value = forceExec(depMod, traced, uninited);
802
697
 
803
- //forceExec all of its dependencies.
804
- for (i = 0; i < depArray.length; i++) {
805
- //Some array members may be null, like if a trailing comma
806
- //IE, so do the explicit [i] access and check if it has a value.
807
- depName = depArray[i];
808
- if (depName) {
809
- if (!manager.deps[depName] && waiting[depName]) {
810
- manager.onDep(depName, forceExec(waiting[depName], traced));
698
+ //Even with forcing it may not be done,
699
+ //in particular if the module is waiting
700
+ //on a plugin resource.
701
+ if (!uninited[depId]) {
702
+ mod.defineDepById(depId, value);
811
703
  }
812
704
  }
813
- }
705
+ });
814
706
 
815
- return fullName ? defined[fullName] : undefined;
707
+ mod.check(true);
708
+
709
+ return defined[id];
710
+ }
711
+
712
+ function modCheck(mod) {
713
+ mod.check();
816
714
  }
817
715
 
818
- /**
819
- * Checks if all modules for a context are loaded, and if so, evaluates the
820
- * new ones in right dependency order.
821
- *
822
- * @private
823
- */
824
716
  function checkLoaded() {
825
- var waitInterval = config.waitSeconds * 1000,
717
+ var map, modId, err, usingPathFallback,
718
+ waitInterval = config.waitSeconds * 1000,
826
719
  //It is possible to disable the wait interval by using waitSeconds of 0.
827
720
  expired = waitInterval && (context.startTime + waitInterval) < new Date().getTime(),
828
- noLoads = "", hasLoadedProp = false, stillLoading = false, prop,
829
- err, manager;
830
-
831
- //If there are items still in the paused queue processing wait.
832
- //This is particularly important in the sync case where each paused
833
- //item is processed right away but there may be more waiting.
834
- if (context.pausedCount > 0) {
835
- return undefined;
721
+ noLoads = [],
722
+ stillLoading = false,
723
+ needCycleCheck = true;
724
+
725
+ //Do not bother if this call was a result of a cycle break.
726
+ if (inCheckLoaded) {
727
+ return;
836
728
  }
837
729
 
838
- //Determine if priority loading is done. If so clear the priority. If
839
- //not, then do not check
840
- if (config.priorityWait) {
841
- if (isPriorityDone()) {
842
- //Call resume, since it could have
843
- //some waiting dependencies to trace.
844
- resume();
845
- } else {
846
- return undefined;
730
+ inCheckLoaded = true;
731
+
732
+ //Figure out the state of all the modules.
733
+ eachProp(registry, function (mod) {
734
+ map = mod.map;
735
+ modId = map.id;
736
+
737
+ //Skip things that are not enabled or in error state.
738
+ if (!mod.enabled) {
739
+ return;
847
740
  }
848
- }
849
741
 
850
- //See if anything is still in flight.
851
- for (prop in loaded) {
852
- if (!(prop in empty)) {
853
- hasLoadedProp = true;
854
- if (!loaded[prop]) {
855
- if (expired) {
856
- noLoads += prop + " ";
857
- } else {
742
+ if (!mod.error) {
743
+ //If the module should be executed, and it has not
744
+ //been inited and time is up, remember it.
745
+ if (!mod.inited && expired) {
746
+ if (hasPathFallback(modId)) {
747
+ usingPathFallback = true;
858
748
  stillLoading = true;
859
- break;
749
+ } else {
750
+ noLoads.push(modId);
751
+ removeScript(modId);
752
+ }
753
+ } else if (!mod.inited && mod.fetched && map.isDefine) {
754
+ stillLoading = true;
755
+ if (!map.prefix) {
756
+ //No reason to keep looking for unfinished
757
+ //loading. If the only stillLoading is a
758
+ //plugin resource though, keep going,
759
+ //because it may be that a plugin resource
760
+ //is waiting on a non-plugin cycle.
761
+ return (needCycleCheck = false);
860
762
  }
861
763
  }
862
764
  }
863
- }
765
+ });
864
766
 
865
- //Check for exit conditions.
866
- if (!hasLoadedProp && !context.waitCount) {
867
- //If the loaded object had no items, then the rest of
868
- //the work below does not need to be done.
869
- return undefined;
870
- }
871
- if (expired && noLoads) {
767
+ if (expired && noLoads.length) {
872
768
  //If wait time expired, throw error of unloaded modules.
873
- err = makeError("timeout", "Load timeout for modules: " + noLoads);
874
- err.requireType = "timeout";
875
- err.requireModules = noLoads;
876
- return req.onError(err);
769
+ err = makeError('timeout', 'Load timeout for modules: ' + noLoads, null, noLoads);
770
+ err.contextName = context.contextName;
771
+ return onError(err);
877
772
  }
878
- if (stillLoading || context.scriptCount) {
773
+
774
+ //Not expired, check for a cycle.
775
+ if (needCycleCheck) {
776
+
777
+ each(waitAry, function (mod) {
778
+ if (mod.defined) {
779
+ return;
780
+ }
781
+
782
+ var cycleMod = findCycle(mod, {}),
783
+ traced = {};
784
+
785
+ if (cycleMod) {
786
+ forceExec(cycleMod, traced, {});
787
+
788
+ //traced modules may have been
789
+ //removed from the registry, but
790
+ //their listeners still need to
791
+ //be called.
792
+ eachProp(traced, modCheck);
793
+ }
794
+ });
795
+
796
+ //Now that dependencies have
797
+ //been satisfied, trigger the
798
+ //completion check that then
799
+ //notifies listeners.
800
+ eachProp(registry, modCheck);
801
+ }
802
+
803
+ //If still waiting on loads, and the waiting load is something
804
+ //other than a plugin resource, or there are still outstanding
805
+ //scripts, then just try back later.
806
+ if ((!expired || usingPathFallback) && stillLoading) {
879
807
  //Something is still waiting to load. Wait for it, but only
880
808
  //if a timeout is not already in effect.
881
809
  if ((isBrowser || isWebWorker) && !checkLoadedTimeoutId) {
@@ -884,328 +812,578 @@ var requirejs, require, define;
884
812
  checkLoaded();
885
813
  }, 50);
886
814
  }
887
- return undefined;
888
- }
889
-
890
- //If still have items in the waiting cue, but all modules have
891
- //been loaded, then it means there are some circular dependencies
892
- //that need to be broken.
893
- //However, as a waiting thing is fired, then it can add items to
894
- //the waiting cue, and those items should not be fired yet, so
895
- //make sure to redo the checkLoaded call after breaking a single
896
- //cycle, if nothing else loaded then this logic will pick it up
897
- //again.
898
- if (context.waitCount) {
899
- //Cycle through the waitAry, and call items in sequence.
900
- for (i = 0; (manager = waitAry[i]); i++) {
901
- forceExec(manager, {});
902
- }
903
-
904
- //Only allow this recursion to a certain depth. Only
905
- //triggered by errors in calling a module in which its
906
- //modules waiting on it cannot finish loading, or some circular
907
- //dependencies that then may add more dependencies.
908
- //The value of 5 is a bit arbitrary. Hopefully just one extra
909
- //pass, or two for the case of circular dependencies generating
910
- //more work that gets resolved in the sync node case.
911
- if (checkLoadedDepth < 5) {
912
- checkLoadedDepth += 1;
913
- checkLoaded();
914
- }
915
815
  }
916
816
 
917
- checkLoadedDepth = 0;
918
-
919
- //Check for DOM ready, and nothing is waiting across contexts.
920
- req.checkReadyState();
921
-
922
- return undefined;
817
+ inCheckLoaded = false;
923
818
  }
924
819
 
925
- function callPlugin(pluginName, dep) {
926
- var name = dep.name,
927
- fullName = dep.fullName,
928
- load;
820
+ Module = function (map) {
821
+ this.events = undefEvents[map.id] || {};
822
+ this.map = map;
823
+ this.shim = config.shim[map.id];
824
+ this.depExports = [];
825
+ this.depMaps = [];
826
+ this.depMatched = [];
827
+ this.pluginMaps = {};
828
+ this.depCount = 0;
829
+
830
+ /* this.exports this.factory
831
+ this.depMaps = [],
832
+ this.enabled, this.fetched
833
+ */
834
+ };
929
835
 
930
- //Do not bother if plugin is already defined or being loaded.
931
- if (fullName in defined || fullName in loaded) {
932
- return;
933
- }
836
+ Module.prototype = {
837
+ init: function (depMaps, factory, errback, options) {
838
+ options = options || {};
934
839
 
935
- if (!plugins[pluginName]) {
936
- plugins[pluginName] = defined[pluginName];
937
- }
840
+ //Do not do more inits if already done. Can happen if there
841
+ //are multiple define calls for the same module. That is not
842
+ //a normal, common case, but it is also not unexpected.
843
+ if (this.inited) {
844
+ return;
845
+ }
938
846
 
939
- //Only set loaded to false for tracking if it has not already been set.
940
- if (!loaded[fullName]) {
941
- loaded[fullName] = false;
942
- }
847
+ this.factory = factory;
848
+
849
+ if (errback) {
850
+ //Register for errors on this module.
851
+ this.on('error', errback);
852
+ } else if (this.events.error) {
853
+ //If no errback already, but there are error listeners
854
+ //on this module, set up an errback to pass to the deps.
855
+ errback = bind(this, function (err) {
856
+ this.emit('error', err);
857
+ });
858
+ }
943
859
 
944
- load = function (ret) {
945
- //Allow the build process to register plugin-loaded dependencies.
946
- if (req.onPluginLoad) {
947
- req.onPluginLoad(context, pluginName, name, ret);
860
+ //Do a copy of the dependency array, so that
861
+ //source inputs are not modified. For example
862
+ //"shim" deps are passed in here directly, and
863
+ //doing a direct modification of the depMaps array
864
+ //would affect that config.
865
+ this.depMaps = depMaps && depMaps.slice(0);
866
+ this.depMaps.rjsSkipMap = depMaps.rjsSkipMap;
867
+
868
+ this.errback = errback;
869
+
870
+ //Indicate this module has be initialized
871
+ this.inited = true;
872
+
873
+ this.ignore = options.ignore;
874
+
875
+ //Could have option to init this module in enabled mode,
876
+ //or could have been previously marked as enabled. However,
877
+ //the dependencies are not known until init is called. So
878
+ //if enabled previously, now trigger dependencies as enabled.
879
+ if (options.enabled || this.enabled) {
880
+ //Enable this module and dependencies.
881
+ //Will call this.check()
882
+ this.enable();
883
+ } else {
884
+ this.check();
948
885
  }
886
+ },
887
+
888
+ defineDepById: function (id, depExports) {
889
+ var i;
949
890
 
950
- execManager({
951
- prefix: dep.prefix,
952
- name: dep.name,
953
- fullName: dep.fullName,
954
- callback: function () {
955
- return ret;
891
+ //Find the index for this dependency.
892
+ each(this.depMaps, function (map, index) {
893
+ if (map.id === id) {
894
+ i = index;
895
+ return true;
956
896
  }
957
897
  });
958
- loaded[fullName] = true;
959
- };
960
898
 
961
- //Allow plugins to load other code without having to know the
962
- //context or how to "complete" the load.
963
- load.fromText = function (moduleName, text) {
964
- /*jslint evil: true */
965
- var hasInteractive = useInteractive;
899
+ return this.defineDep(i, depExports);
900
+ },
966
901
 
967
- //Indicate a the module is in process of loading.
968
- context.loaded[moduleName] = false;
969
- context.scriptCount += 1;
902
+ defineDep: function (i, depExports) {
903
+ //Because of cycles, defined callback for a given
904
+ //export can be called more than once.
905
+ if (!this.depMatched[i]) {
906
+ this.depMatched[i] = true;
907
+ this.depCount -= 1;
908
+ this.depExports[i] = depExports;
909
+ }
910
+ },
970
911
 
971
- //Turn off interactive script matching for IE for any define
972
- //calls in the text, then turn it back on at the end.
973
- if (hasInteractive) {
974
- useInteractive = false;
912
+ fetch: function () {
913
+ if (this.fetched) {
914
+ return;
975
915
  }
916
+ this.fetched = true;
976
917
 
977
- req.exec(text);
918
+ context.startTime = (new Date()).getTime();
978
919
 
979
- if (hasInteractive) {
980
- useInteractive = true;
981
- }
920
+ var map = this.map;
982
921
 
983
- //Support anonymous modules.
984
- context.completeLoad(moduleName);
985
- };
922
+ //If the manager is for a plugin managed resource,
923
+ //ask the plugin to load it now.
924
+ if (this.shim) {
925
+ makeRequire(this, true)(this.shim.deps || [], bind(this, function () {
926
+ return map.prefix ? this.callPlugin() : this.load();
927
+ }));
928
+ } else {
929
+ //Regular dependency.
930
+ return map.prefix ? this.callPlugin() : this.load();
931
+ }
932
+ },
986
933
 
987
- //Use parentName here since the plugin's name is not reliable,
988
- //could be some weird string with no path that actually wants to
989
- //reference the parentName's path.
990
- plugins[pluginName].load(name, makeRequire(dep.parentMap, true), load, config);
991
- }
934
+ load: function () {
935
+ var url = this.map.url;
992
936
 
993
- function loadPaused(dep) {
994
- //Renormalize dependency if its name was waiting on a plugin
995
- //to load, which as since loaded.
996
- if (dep.prefix && dep.name && dep.name.indexOf('__$p') === 0 && defined[dep.prefix]) {
997
- dep = makeModuleMap(dep.originalName, dep.parentMap);
998
- }
937
+ //Regular dependency.
938
+ if (!urlFetched[url]) {
939
+ urlFetched[url] = true;
940
+ context.load(this.map.id, url);
941
+ }
942
+ },
999
943
 
1000
- var pluginName = dep.prefix,
1001
- fullName = dep.fullName,
1002
- urlFetched = context.urlFetched;
944
+ /**
945
+ * Checks is the module is ready to define itself, and if so,
946
+ * define it. If the silent argument is true, then it will just
947
+ * define, but not notify listeners, and not ask for a context-wide
948
+ * check of all loaded modules. That is useful for cycle breaking.
949
+ */
950
+ check: function (silent) {
951
+ if (!this.enabled || this.enabling) {
952
+ return;
953
+ }
1003
954
 
1004
- //Do not bother if the dependency has already been specified.
1005
- if (specified[fullName] || loaded[fullName]) {
1006
- return;
1007
- } else {
1008
- specified[fullName] = true;
1009
- }
955
+ var err, cjsModule,
956
+ id = this.map.id,
957
+ depExports = this.depExports,
958
+ exports = this.exports,
959
+ factory = this.factory;
960
+
961
+ if (!this.inited) {
962
+ this.fetch();
963
+ } else if (this.error) {
964
+ this.emit('error', this.error);
965
+ } else if (!this.defining) {
966
+ //The factory could trigger another require call
967
+ //that would result in checking this module to
968
+ //define itself again. If already in the process
969
+ //of doing that, skip this work.
970
+ this.defining = true;
971
+
972
+ if (this.depCount < 1 && !this.defined) {
973
+ if (isFunction(factory)) {
974
+ //If there is an error listener, favor passing
975
+ //to that instead of throwing an error.
976
+ if (this.events.error) {
977
+ try {
978
+ exports = context.execCb(id, factory, depExports, exports);
979
+ } catch (e) {
980
+ err = e;
981
+ }
982
+ } else {
983
+ exports = context.execCb(id, factory, depExports, exports);
984
+ }
1010
985
 
1011
- if (pluginName) {
1012
- //If plugin not loaded, wait for it.
1013
- //set up callback list. if no list, then register
1014
- //managerCallback for that plugin.
1015
- if (defined[pluginName]) {
1016
- callPlugin(pluginName, dep);
1017
- } else {
1018
- if (!pluginsQueue[pluginName]) {
1019
- pluginsQueue[pluginName] = [];
1020
- (managerCallbacks[pluginName] ||
1021
- (managerCallbacks[pluginName] = [])).push({
1022
- onDep: function (name, value) {
1023
- if (name === pluginName) {
1024
- var i, oldModuleMap, ary = pluginsQueue[pluginName];
1025
-
1026
- //Now update all queued plugin actions.
1027
- for (i = 0; i < ary.length; i++) {
1028
- oldModuleMap = ary[i];
1029
- //Update the moduleMap since the
1030
- //module name may be normalized
1031
- //differently now.
1032
- callPlugin(pluginName,
1033
- makeModuleMap(oldModuleMap.originalName, oldModuleMap.parentMap));
1034
- }
1035
- delete pluginsQueue[pluginName];
986
+ if (this.map.isDefine) {
987
+ //If setting exports via 'module' is in play,
988
+ //favor that over return value and exports. After that,
989
+ //favor a non-undefined return value over exports use.
990
+ cjsModule = this.module;
991
+ if (cjsModule &&
992
+ cjsModule.exports !== undefined &&
993
+ //Make sure it is not already the exports value
994
+ cjsModule.exports !== this.exports) {
995
+ exports = cjsModule.exports;
996
+ } else if (exports === undefined && this.usingExports) {
997
+ //exports already set the defined value.
998
+ exports = this.exports;
1036
999
  }
1037
1000
  }
1038
- });
1001
+
1002
+ if (err) {
1003
+ err.requireMap = this.map;
1004
+ err.requireModules = [this.map.id];
1005
+ err.requireType = 'define';
1006
+ return onError((this.error = err));
1007
+ }
1008
+
1009
+ } else {
1010
+ //Just a literal value
1011
+ exports = factory;
1012
+ }
1013
+
1014
+ this.exports = exports;
1015
+
1016
+ if (this.map.isDefine && !this.ignore) {
1017
+ defined[id] = exports;
1018
+
1019
+ if (req.onResourceLoad) {
1020
+ req.onResourceLoad(context, this.map, this.depMaps);
1021
+ }
1022
+ }
1023
+
1024
+ //Clean up
1025
+ delete registry[id];
1026
+
1027
+ this.defined = true;
1028
+ context.waitCount -= 1;
1029
+ if (context.waitCount === 0) {
1030
+ //Clear the wait array used for cycles.
1031
+ waitAry = [];
1032
+ }
1033
+ }
1034
+
1035
+ //Finished the define stage. Allow calling check again
1036
+ //to allow define notifications below in the case of a
1037
+ //cycle.
1038
+ this.defining = false;
1039
+
1040
+ if (!silent) {
1041
+ if (this.defined && !this.defineEmitted) {
1042
+ this.defineEmitted = true;
1043
+ this.emit('defined', this.exports);
1044
+ this.defineEmitComplete = true;
1045
+ }
1039
1046
  }
1040
- pluginsQueue[pluginName].push(dep);
1041
- }
1042
- } else {
1043
- if (!urlFetched[dep.url]) {
1044
- req.load(context, fullName, dep.url);
1045
- urlFetched[dep.url] = true;
1046
1047
  }
1047
- }
1048
- }
1048
+ },
1049
1049
 
1050
- /**
1051
- * Resumes tracing of dependencies and then checks if everything is loaded.
1052
- */
1053
- resume = function () {
1054
- var args, i, p;
1050
+ callPlugin: function () {
1051
+ var map = this.map,
1052
+ id = map.id,
1053
+ pluginMap = makeModuleMap(map.prefix, null, false, true);
1054
+
1055
+ on(pluginMap, 'defined', bind(this, function (plugin) {
1056
+ var load, normalizedMap, normalizedMod,
1057
+ name = this.map.name,
1058
+ parentName = this.map.parentMap ? this.map.parentMap.name : null;
1059
+
1060
+ //If current map is not normalized, wait for that
1061
+ //normalized name to load instead of continuing.
1062
+ if (this.map.unnormalized) {
1063
+ //Normalize the ID if the plugin allows it.
1064
+ if (plugin.normalize) {
1065
+ name = plugin.normalize(name, function (name) {
1066
+ return normalize(name, parentName, true);
1067
+ }) || '';
1068
+ }
1069
+
1070
+ normalizedMap = makeModuleMap(map.prefix + '!' + name,
1071
+ this.map.parentMap,
1072
+ false,
1073
+ true);
1074
+ on(normalizedMap,
1075
+ 'defined', bind(this, function (value) {
1076
+ this.init([], function () { return value; }, null, {
1077
+ enabled: true,
1078
+ ignore: true
1079
+ });
1080
+ }));
1081
+ normalizedMod = registry[normalizedMap.id];
1082
+ if (normalizedMod) {
1083
+ if (this.events.error) {
1084
+ normalizedMod.on('error', bind(this, function (err) {
1085
+ this.emit('error', err);
1086
+ }));
1087
+ }
1088
+ normalizedMod.enable();
1089
+ }
1055
1090
 
1056
- resumeDepth += 1;
1091
+ return;
1092
+ }
1057
1093
 
1058
- if (context.scriptCount <= 0) {
1059
- //Synchronous envs will push the number below zero with the
1060
- //decrement above, be sure to set it back to zero for good measure.
1061
- //require() calls that also do not end up loading scripts could
1062
- //push the number negative too.
1063
- context.scriptCount = 0;
1064
- }
1094
+ load = bind(this, function (value) {
1095
+ this.init([], function () { return value; }, null, {
1096
+ enabled: true
1097
+ });
1098
+ });
1065
1099
 
1066
- //Make sure any remaining defQueue items get properly processed.
1067
- while (defQueue.length) {
1068
- args = defQueue.shift();
1069
- if (args[0] === null) {
1070
- return req.onError(makeError('mismatch', 'Mismatched anonymous define() module: ' + args[args.length - 1]));
1071
- } else {
1072
- callDefMain(args);
1100
+ load.error = bind(this, function (err) {
1101
+ this.inited = true;
1102
+ this.error = err;
1103
+ err.requireModules = [id];
1104
+
1105
+ //Remove temp unnormalized modules for this module,
1106
+ //since they will never be resolved otherwise now.
1107
+ eachProp(registry, function (mod) {
1108
+ if (mod.map.id.indexOf(id + '_unnormalized') === 0) {
1109
+ removeWaiting(mod.map.id);
1110
+ }
1111
+ });
1112
+
1113
+ onError(err);
1114
+ });
1115
+
1116
+ //Allow plugins to load other code without having to know the
1117
+ //context or how to 'complete' the load.
1118
+ load.fromText = function (moduleName, text) {
1119
+ /*jslint evil: true */
1120
+ var hasInteractive = useInteractive;
1121
+
1122
+ //Turn off interactive script matching for IE for any define
1123
+ //calls in the text, then turn it back on at the end.
1124
+ if (hasInteractive) {
1125
+ useInteractive = false;
1126
+ }
1127
+
1128
+ //Prime the system by creating a module instance for
1129
+ //it.
1130
+ getModule(makeModuleMap(moduleName));
1131
+
1132
+ req.exec(text);
1133
+
1134
+ if (hasInteractive) {
1135
+ useInteractive = true;
1136
+ }
1137
+
1138
+ //Support anonymous modules.
1139
+ context.completeLoad(moduleName);
1140
+ };
1141
+
1142
+ //Use parentName here since the plugin's name is not reliable,
1143
+ //could be some weird string with no path that actually wants to
1144
+ //reference the parentName's path.
1145
+ plugin.load(map.name, makeRequire(map.parentMap, true, function (deps, cb, er) {
1146
+ deps.rjsSkipMap = true;
1147
+ return context.require(deps, cb, er);
1148
+ }), load, config);
1149
+ }));
1150
+
1151
+ context.enable(pluginMap, this);
1152
+ this.pluginMaps[pluginMap.id] = pluginMap;
1153
+ },
1154
+
1155
+ enable: function () {
1156
+ this.enabled = true;
1157
+
1158
+ if (!this.waitPushed) {
1159
+ waitAry.push(this);
1160
+ context.waitCount += 1;
1161
+ this.waitPushed = true;
1073
1162
  }
1074
- }
1075
1163
 
1076
- //Skip the resume of paused dependencies
1077
- //if current context is in priority wait.
1078
- if (!config.priorityWait || isPriorityDone()) {
1079
- while (context.paused.length) {
1080
- p = context.paused;
1081
- context.pausedCount += p.length;
1082
- //Reset paused list
1083
- context.paused = [];
1084
-
1085
- for (i = 0; (args = p[i]); i++) {
1086
- loadPaused(args);
1164
+ //Set flag mentioning that the module is enabling,
1165
+ //so that immediate calls to the defined callbacks
1166
+ //for dependencies do not trigger inadvertent load
1167
+ //with the depCount still being zero.
1168
+ this.enabling = true;
1169
+
1170
+ //Enable each dependency
1171
+ each(this.depMaps, bind(this, function (depMap, i) {
1172
+ var id, mod, handler;
1173
+
1174
+ if (typeof depMap === 'string') {
1175
+ //Dependency needs to be converted to a depMap
1176
+ //and wired up to this module.
1177
+ depMap = makeModuleMap(depMap,
1178
+ (this.map.isDefine ? this.map : this.map.parentMap),
1179
+ false,
1180
+ !this.depMaps.rjsSkipMap);
1181
+ this.depMaps[i] = depMap;
1182
+
1183
+ handler = handlers[depMap.id];
1184
+
1185
+ if (handler) {
1186
+ this.depExports[i] = handler(this);
1187
+ return;
1188
+ }
1189
+
1190
+ this.depCount += 1;
1191
+
1192
+ on(depMap, 'defined', bind(this, function (depExports) {
1193
+ this.defineDep(i, depExports);
1194
+ this.check();
1195
+ }));
1196
+
1197
+ if (this.errback) {
1198
+ on(depMap, 'error', this.errback);
1199
+ }
1087
1200
  }
1088
- //Move the start time for timeout forward.
1089
- context.startTime = (new Date()).getTime();
1090
- context.pausedCount -= p.length;
1201
+
1202
+ id = depMap.id;
1203
+ mod = registry[id];
1204
+
1205
+ //Skip special modules like 'require', 'exports', 'module'
1206
+ //Also, don't call enable if it is already enabled,
1207
+ //important in circular dependency cases.
1208
+ if (!handlers[id] && mod && !mod.enabled) {
1209
+ context.enable(depMap, this);
1210
+ }
1211
+ }));
1212
+
1213
+ //Enable each plugin that is used in
1214
+ //a dependency
1215
+ eachProp(this.pluginMaps, bind(this, function (pluginMap) {
1216
+ var mod = registry[pluginMap.id];
1217
+ if (mod && !mod.enabled) {
1218
+ context.enable(pluginMap, this);
1219
+ }
1220
+ }));
1221
+
1222
+ this.enabling = false;
1223
+
1224
+ this.check();
1225
+ },
1226
+
1227
+ on: function (name, cb) {
1228
+ var cbs = this.events[name];
1229
+ if (!cbs) {
1230
+ cbs = this.events[name] = [];
1231
+ }
1232
+ cbs.push(cb);
1233
+ },
1234
+
1235
+ emit: function (name, evt) {
1236
+ each(this.events[name], function (cb) {
1237
+ cb(evt);
1238
+ });
1239
+ if (name === 'error') {
1240
+ //Now that the error handler was triggered, remove
1241
+ //the listeners, since this broken Module instance
1242
+ //can stay around for a while in the registry/waitAry.
1243
+ delete this.events[name];
1091
1244
  }
1092
1245
  }
1246
+ };
1093
1247
 
1094
- //Only check if loaded when resume depth is 1. It is likely that
1095
- //it is only greater than 1 in sync environments where a factory
1096
- //function also then calls the callback-style require. In those
1097
- //cases, the checkLoaded should not occur until the resume
1098
- //depth is back at the top level.
1099
- if (resumeDepth === 1) {
1100
- checkLoaded();
1248
+ function callGetModule(args) {
1249
+ getModule(makeModuleMap(args[0], null, true)).init(args[1], args[2]);
1250
+ }
1251
+
1252
+ function removeListener(node, func, name, ieName) {
1253
+ //Favor detachEvent because of IE9
1254
+ //issue, see attachEvent/addEventListener comment elsewhere
1255
+ //in this file.
1256
+ if (node.detachEvent && !isOpera) {
1257
+ //Probably IE. If not it will throw an error, which will be
1258
+ //useful to know.
1259
+ if (ieName) {
1260
+ node.detachEvent(ieName, func);
1261
+ }
1262
+ } else {
1263
+ node.removeEventListener(name, func, false);
1101
1264
  }
1265
+ }
1102
1266
 
1103
- resumeDepth -= 1;
1267
+ /**
1268
+ * Given an event from a script node, get the requirejs info from it,
1269
+ * and then removes the event listeners on the node.
1270
+ * @param {Event} evt
1271
+ * @returns {Object}
1272
+ */
1273
+ function getScriptData(evt) {
1274
+ //Using currentTarget instead of target for Firefox 2.0's sake. Not
1275
+ //all old browsers will be supported, but this one was easy enough
1276
+ //to support and still makes sense.
1277
+ var node = evt.currentTarget || evt.srcElement;
1104
1278
 
1105
- return undefined;
1106
- };
1279
+ //Remove the listeners once here.
1280
+ removeListener(node, context.onScriptLoad, 'load', 'onreadystatechange');
1281
+ removeListener(node, context.onScriptError, 'error');
1107
1282
 
1108
- //Define the context object. Many of these fields are on here
1109
- //just to make debugging easier.
1110
- context = {
1111
- contextName: contextName,
1283
+ return {
1284
+ node: node,
1285
+ id: node && node.getAttribute('data-requiremodule')
1286
+ };
1287
+ }
1288
+
1289
+ return (context = {
1112
1290
  config: config,
1113
- defQueue: defQueue,
1114
- waiting: waiting,
1115
- waitCount: 0,
1116
- specified: specified,
1117
- loaded: loaded,
1118
- urlMap: urlMap,
1119
- scriptCount: 0,
1120
- urlFetched: {},
1291
+ contextName: contextName,
1292
+ registry: registry,
1121
1293
  defined: defined,
1122
- paused: [],
1123
- pausedCount: 0,
1124
- plugins: plugins,
1125
- managerCallbacks: managerCallbacks,
1294
+ urlFetched: urlFetched,
1295
+ waitCount: 0,
1296
+ defQueue: defQueue,
1297
+ Module: Module,
1126
1298
  makeModuleMap: makeModuleMap,
1127
- normalize: normalize,
1299
+
1128
1300
  /**
1129
1301
  * Set a configuration for the context.
1130
1302
  * @param {Object} cfg config object to integrate.
1131
1303
  */
1132
1304
  configure: function (cfg) {
1133
- var paths, prop, packages, pkgs, packagePaths, requireWait;
1134
-
1135
1305
  //Make sure the baseUrl ends in a slash.
1136
1306
  if (cfg.baseUrl) {
1137
- if (cfg.baseUrl.charAt(cfg.baseUrl.length - 1) !== "/") {
1138
- cfg.baseUrl += "/";
1307
+ if (cfg.baseUrl.charAt(cfg.baseUrl.length - 1) !== '/') {
1308
+ cfg.baseUrl += '/';
1139
1309
  }
1140
1310
  }
1141
1311
 
1142
1312
  //Save off the paths and packages since they require special processing,
1143
1313
  //they are additive.
1144
- paths = config.paths;
1145
- packages = config.packages;
1146
- pkgs = config.pkgs;
1314
+ var pkgs = config.pkgs,
1315
+ shim = config.shim,
1316
+ paths = config.paths,
1317
+ map = config.map;
1147
1318
 
1148
1319
  //Mix in the config values, favoring the new values over
1149
1320
  //existing ones in context.config.
1150
1321
  mixin(config, cfg, true);
1151
1322
 
1152
- //Adjust paths if necessary.
1153
- if (cfg.paths) {
1154
- for (prop in cfg.paths) {
1155
- if (!(prop in empty)) {
1156
- paths[prop] = cfg.paths[prop];
1157
- }
1158
- }
1159
- config.paths = paths;
1323
+ //Merge paths.
1324
+ config.paths = mixin(paths, cfg.paths, true);
1325
+
1326
+ //Merge map
1327
+ if (cfg.map) {
1328
+ config.map = mixin(map || {}, cfg.map, true, true);
1160
1329
  }
1161
1330
 
1162
- packagePaths = cfg.packagePaths;
1163
- if (packagePaths || cfg.packages) {
1164
- //Convert packagePaths into a packages config.
1165
- if (packagePaths) {
1166
- for (prop in packagePaths) {
1167
- if (!(prop in empty)) {
1168
- configurePackageDir(pkgs, packagePaths[prop], prop);
1169
- }
1331
+ //Merge shim
1332
+ if (cfg.shim) {
1333
+ eachProp(cfg.shim, function (value, id) {
1334
+ //Normalize the structure
1335
+ if (isArray(value)) {
1336
+ value = {
1337
+ deps: value
1338
+ };
1170
1339
  }
1171
- }
1340
+ if (value.exports && !value.exports.__buildReady) {
1341
+ value.exports = context.makeShimExports(value.exports);
1342
+ }
1343
+ shim[id] = value;
1344
+ });
1345
+ config.shim = shim;
1346
+ }
1172
1347
 
1173
- //Adjust packages if necessary.
1174
- if (cfg.packages) {
1175
- configurePackageDir(pkgs, cfg.packages);
1176
- }
1348
+ //Adjust packages if necessary.
1349
+ if (cfg.packages) {
1350
+ each(cfg.packages, function (pkgObj) {
1351
+ var location;
1352
+
1353
+ pkgObj = typeof pkgObj === 'string' ? { name: pkgObj } : pkgObj;
1354
+ location = pkgObj.location;
1355
+
1356
+ //Create a brand new object on pkgs, since currentPackages can
1357
+ //be passed in again, and config.pkgs is the internal transformed
1358
+ //state for all package configs.
1359
+ pkgs[pkgObj.name] = {
1360
+ name: pkgObj.name,
1361
+ location: location || pkgObj.name,
1362
+ //Remove leading dot in main, so main paths are normalized,
1363
+ //and remove any trailing .js, since different package
1364
+ //envs have different conventions: some use a module name,
1365
+ //some use a file name.
1366
+ main: (pkgObj.main || 'main')
1367
+ .replace(currDirRegExp, '')
1368
+ .replace(jsSuffixRegExp, '')
1369
+ };
1370
+ });
1177
1371
 
1178
1372
  //Done with modifications, assing packages back to context config
1179
1373
  config.pkgs = pkgs;
1180
1374
  }
1181
1375
 
1182
- //If priority loading is in effect, trigger the loads now
1183
- if (cfg.priority) {
1184
- //Hold on to requireWait value, and reset it after done
1185
- requireWait = context.requireWait;
1186
-
1187
- //Allow tracing some require calls to allow the fetching
1188
- //of the priority config.
1189
- context.requireWait = false;
1190
- //But first, call resume to register any defined modules that may
1191
- //be in a data-main built file before the priority config
1192
- //call. Also grab any waiting define calls for this context.
1193
- context.takeGlobalQueue();
1194
- resume();
1195
-
1196
- context.require(cfg.priority);
1197
-
1198
- //Trigger a resume right away, for the case when
1199
- //the script with the priority load is done as part
1200
- //of a data-main call. In that case the normal resume
1201
- //call will not happen because the scriptCount will be
1202
- //at 1, since the script for data-main is being processed.
1203
- resume();
1204
-
1205
- //Restore previous state.
1206
- context.requireWait = requireWait;
1207
- config.priorityWait = cfg.priority;
1208
- }
1376
+ //If there are any "waiting to execute" modules in the registry,
1377
+ //update the maps for them, since their info, like URLs to load,
1378
+ //may have changed.
1379
+ eachProp(registry, function (mod, id) {
1380
+ //If module already has init called, since it is too
1381
+ //late to modify them, and ignore unnormalized ones
1382
+ //since they are transient.
1383
+ if (!mod.inited && !mod.map.unnormalized) {
1384
+ mod.map = makeModuleMap(id);
1385
+ }
1386
+ });
1209
1387
 
1210
1388
  //If a deps array or a config callback is specified, then call
1211
1389
  //require with those args. This is useful when require is defined as a
@@ -1213,80 +1391,138 @@ var requirejs, require, define;
1213
1391
  if (cfg.deps || cfg.callback) {
1214
1392
  context.require(cfg.deps || [], cfg.callback);
1215
1393
  }
1394
+ },
1216
1395
 
1217
- //Set up ready callback, if asked. Useful when require is defined as a
1218
- //config object before require.js is loaded.
1219
- if (cfg.ready) {
1220
- req.ready(cfg.ready);
1396
+ makeShimExports: function (exports) {
1397
+ var func;
1398
+ if (typeof exports === 'string') {
1399
+ func = function () {
1400
+ return getGlobal(exports);
1401
+ };
1402
+ //Save the exports for use in nodefine checking.
1403
+ func.exports = exports;
1404
+ return func;
1405
+ } else {
1406
+ return function () {
1407
+ return exports.apply(global, arguments);
1408
+ };
1221
1409
  }
1222
1410
  },
1223
1411
 
1224
- requireDefined: function (moduleName, relModuleMap) {
1225
- return makeModuleMap(moduleName, relModuleMap).fullName in defined;
1412
+ requireDefined: function (id, relMap) {
1413
+ return hasProp(defined, makeModuleMap(id, relMap, false, true).id);
1226
1414
  },
1227
1415
 
1228
- requireSpecified: function (moduleName, relModuleMap) {
1229
- return makeModuleMap(moduleName, relModuleMap).fullName in specified;
1416
+ requireSpecified: function (id, relMap) {
1417
+ id = makeModuleMap(id, relMap, false, true).id;
1418
+ return hasProp(defined, id) || hasProp(registry, id);
1230
1419
  },
1231
1420
 
1232
- require: function (deps, callback, relModuleMap) {
1233
- var moduleName, fullName, moduleMap;
1234
- if (typeof deps === "string") {
1421
+ require: function (deps, callback, errback, relMap) {
1422
+ var moduleName, id, map, requireMod, args;
1423
+ if (typeof deps === 'string') {
1424
+ if (isFunction(callback)) {
1425
+ //Invalid call
1426
+ return onError(makeError('requireargs', 'Invalid require call'), errback);
1427
+ }
1428
+
1235
1429
  //Synchronous access to one module. If require.get is
1236
1430
  //available (as in the Node adapter), prefer that.
1237
1431
  //In this case deps is the moduleName and callback is
1238
- //the relModuleMap
1432
+ //the relMap
1239
1433
  if (req.get) {
1240
1434
  return req.get(context, deps, callback);
1241
1435
  }
1242
1436
 
1243
1437
  //Just return the module wanted. In this scenario, the
1244
- //second arg (if passed) is just the relModuleMap.
1438
+ //second arg (if passed) is just the relMap.
1245
1439
  moduleName = deps;
1246
- relModuleMap = callback;
1440
+ relMap = callback;
1247
1441
 
1248
1442
  //Normalize module name, if it contains . or ..
1249
- moduleMap = makeModuleMap(moduleName, relModuleMap);
1250
- fullName = moduleMap.fullName;
1443
+ map = makeModuleMap(moduleName, relMap, false, true);
1444
+ id = map.id;
1251
1445
 
1252
- if (!(fullName in defined)) {
1253
- return req.onError(makeError("notloaded", "Module name '" +
1254
- moduleMap.fullName +
1255
- "' has not been loaded yet for context: " +
1446
+ if (!hasProp(defined, id)) {
1447
+ return onError(makeError('notloaded', 'Module name "' +
1448
+ id +
1449
+ '" has not been loaded yet for context: ' +
1256
1450
  contextName));
1257
1451
  }
1258
- return defined[fullName];
1452
+ return defined[id];
1453
+ }
1454
+
1455
+ //Callback require. Normalize args. if callback or errback is
1456
+ //not a function, it means it is a relMap. Test errback first.
1457
+ if (errback && !isFunction(errback)) {
1458
+ relMap = errback;
1459
+ errback = undefined;
1259
1460
  }
1461
+ if (callback && !isFunction(callback)) {
1462
+ relMap = callback;
1463
+ callback = undefined;
1464
+ }
1465
+
1466
+ //Any defined modules in the global queue, intake them now.
1467
+ takeGlobalQueue();
1260
1468
 
1261
- main(null, deps, callback, relModuleMap);
1262
-
1263
- //If the require call does not trigger anything new to load,
1264
- //then resume the dependency processing.
1265
- if (!context.requireWait) {
1266
- while (!context.scriptCount && context.paused.length) {
1267
- //For built layers, there can be some defined
1268
- //modules waiting for intake into the context,
1269
- //in particular module plugins. Take them.
1270
- context.takeGlobalQueue();
1271
- resume();
1469
+ //Make sure any remaining defQueue items get properly processed.
1470
+ while (defQueue.length) {
1471
+ args = defQueue.shift();
1472
+ if (args[0] === null) {
1473
+ return onError(makeError('mismatch', 'Mismatched anonymous define() module: ' + args[args.length - 1]));
1474
+ } else {
1475
+ //args are id, deps, factory. Should be normalized by the
1476
+ //define() function.
1477
+ callGetModule(args);
1272
1478
  }
1273
1479
  }
1480
+
1481
+ //Mark all the dependencies as needing to be loaded.
1482
+ requireMod = getModule(makeModuleMap(null, relMap));
1483
+
1484
+ requireMod.init(deps, callback, errback, {
1485
+ enabled: true
1486
+ });
1487
+
1488
+ checkLoaded();
1489
+
1274
1490
  return context.require;
1275
1491
  },
1276
1492
 
1493
+ undef: function (id) {
1494
+ //Bind any waiting define() calls to this context,
1495
+ //fix for #408
1496
+ takeGlobalQueue();
1497
+
1498
+ var map = makeModuleMap(id, null, true),
1499
+ mod = registry[id];
1500
+
1501
+ delete defined[id];
1502
+ delete urlFetched[map.url];
1503
+ delete undefEvents[id];
1504
+
1505
+ if (mod) {
1506
+ //Hold on to listeners in case the
1507
+ //module will be attempted to be reloaded
1508
+ //using a different config.
1509
+ if (mod.events.defined) {
1510
+ undefEvents[id] = mod.events;
1511
+ }
1512
+
1513
+ removeWaiting(id);
1514
+ }
1515
+ },
1516
+
1277
1517
  /**
1278
- * Internal method to transfer globalQueue items to this context's
1279
- * defQueue.
1518
+ * Called to enable a module if it is still in the registry
1519
+ * awaiting enablement. parent module is passed in for context,
1520
+ * used by the optimizer.
1280
1521
  */
1281
- takeGlobalQueue: function () {
1282
- //Push all the globalDefQueue items into the context's defQueue
1283
- if (globalDefQueue.length) {
1284
- //Array splice in the values since the context code has a
1285
- //local var ref to defQueue, so cannot just reassign the one
1286
- //on context.
1287
- apsp.apply(context.defQueue,
1288
- [context.defQueue.length - 1, 0].concat(globalDefQueue));
1289
- globalDefQueue = [];
1522
+ enable: function (depMap, parent) {
1523
+ var mod = registry[depMap.id];
1524
+ if (mod) {
1525
+ getModule(depMap).enable();
1290
1526
  }
1291
1527
  },
1292
1528
 
@@ -1297,61 +1533,53 @@ var requirejs, require, define;
1297
1533
  * @param {String} moduleName the name of the module to potentially complete.
1298
1534
  */
1299
1535
  completeLoad: function (moduleName) {
1300
- var args;
1536
+ var found, args, mod,
1537
+ shim = config.shim[moduleName] || {},
1538
+ shExports = shim.exports && shim.exports.exports;
1301
1539
 
1302
- context.takeGlobalQueue();
1540
+ takeGlobalQueue();
1303
1541
 
1304
1542
  while (defQueue.length) {
1305
1543
  args = defQueue.shift();
1306
-
1307
1544
  if (args[0] === null) {
1308
1545
  args[0] = moduleName;
1309
- break;
1546
+ //If already found an anonymous module and bound it
1547
+ //to this name, then this is some other anon module
1548
+ //waiting for its completeLoad to fire.
1549
+ if (found) {
1550
+ break;
1551
+ }
1552
+ found = true;
1310
1553
  } else if (args[0] === moduleName) {
1311
1554
  //Found matching define call for this script!
1312
- break;
1313
- } else {
1314
- //Some other named define call, most likely the result
1315
- //of a build layer that included many define calls.
1316
- callDefMain(args);
1317
- args = null;
1555
+ found = true;
1318
1556
  }
1319
- }
1320
- if (args) {
1321
- callDefMain(args);
1322
- } else {
1323
- //A script that does not call define(), so just simulate
1324
- //the call for it. Special exception for jQuery dynamic load.
1325
- callDefMain([moduleName, [],
1326
- moduleName === "jquery" && typeof jQuery !== "undefined" ?
1327
- function () {
1328
- return jQuery;
1329
- } : null]);
1330
- }
1331
1557
 
1332
- //Mark the script as loaded. Note that this can be different from a
1333
- //moduleName that maps to a define call. This line is important
1334
- //for traditional browser scripts.
1335
- loaded[moduleName] = true;
1336
-
1337
- //If a global jQuery is defined, check for it. Need to do it here
1338
- //instead of main() since stock jQuery does not register as
1339
- //a module via define.
1340
- jQueryCheck();
1341
-
1342
- //Doing this scriptCount decrement branching because sync envs
1343
- //need to decrement after resume, otherwise it looks like
1344
- //loading is complete after the first dependency is fetched.
1345
- //For browsers, it works fine to decrement after, but it means
1346
- //the checkLoaded setTimeout 50 ms cost is taken. To avoid
1347
- //that cost, decrement beforehand.
1348
- if (req.isAsync) {
1349
- context.scriptCount -= 1;
1558
+ callGetModule(args);
1350
1559
  }
1351
- resume();
1352
- if (!req.isAsync) {
1353
- context.scriptCount -= 1;
1560
+
1561
+ //Do this after the cycle of callGetModule in case the result
1562
+ //of those calls/init calls changes the registry.
1563
+ mod = registry[moduleName];
1564
+
1565
+ if (!found && !defined[moduleName] && mod && !mod.inited) {
1566
+ if (config.enforceDefine && (!shExports || !getGlobal(shExports))) {
1567
+ if (hasPathFallback(moduleName)) {
1568
+ return;
1569
+ } else {
1570
+ return onError(makeError('nodefine',
1571
+ 'No define call for ' + moduleName,
1572
+ null,
1573
+ [moduleName]));
1574
+ }
1575
+ } else {
1576
+ //A script that does not call define(), so just simulate
1577
+ //the call for it.
1578
+ callGetModule([moduleName, (shim.deps || []), shim.exports]);
1579
+ }
1354
1580
  }
1581
+
1582
+ checkLoaded();
1355
1583
  },
1356
1584
 
1357
1585
  /**
@@ -1360,7 +1588,7 @@ var requirejs, require, define;
1360
1588
  * plain URLs like nameToUrl.
1361
1589
  */
1362
1590
  toUrl: function (moduleNamePlusExt, relModuleMap) {
1363
- var index = moduleNamePlusExt.lastIndexOf("."),
1591
+ var index = moduleNamePlusExt.lastIndexOf('.'),
1364
1592
  ext = null;
1365
1593
 
1366
1594
  if (index !== -1) {
@@ -1368,43 +1596,52 @@ var requirejs, require, define;
1368
1596
  moduleNamePlusExt = moduleNamePlusExt.substring(0, index);
1369
1597
  }
1370
1598
 
1371
- return context.nameToUrl(moduleNamePlusExt, ext, relModuleMap);
1599
+ return context.nameToUrl(normalize(moduleNamePlusExt, relModuleMap && relModuleMap.id, true),
1600
+ ext);
1372
1601
  },
1373
1602
 
1374
1603
  /**
1375
1604
  * Converts a module name to a file path. Supports cases where
1376
1605
  * moduleName may actually be just an URL.
1606
+ * Note that it **does not** call normalize on the moduleName,
1607
+ * it is assumed to have already been normalized. This is an
1608
+ * internal API, not a public one. Use toUrl for the public API.
1377
1609
  */
1378
- nameToUrl: function (moduleName, ext, relModuleMap) {
1610
+ nameToUrl: function (moduleName, ext) {
1379
1611
  var paths, pkgs, pkg, pkgPath, syms, i, parentModule, url,
1380
- config = context.config;
1381
-
1382
- //Normalize module name if have a base relative module name to work from.
1383
- moduleName = normalize(moduleName, relModuleMap && relModuleMap.fullName);
1612
+ parentPath;
1384
1613
 
1385
1614
  //If a colon is in the URL, it indicates a protocol is used and it is just
1386
- //an URL to a file, or if it starts with a slash or ends with .js, it is just a plain file.
1615
+ //an URL to a file, or if it starts with a slash, contains a query arg (i.e. ?)
1616
+ //or ends with .js, then assume the user meant to use an url and not a module id.
1387
1617
  //The slash is important for protocol-less URLs as well as full paths.
1388
1618
  if (req.jsExtRegExp.test(moduleName)) {
1389
1619
  //Just a plain path, not module name lookup, so just return it.
1390
1620
  //Add extension if it is included. This is a bit wonky, only non-.js things pass
1391
1621
  //an extension, this method probably needs to be reworked.
1392
- url = moduleName + (ext ? ext : "");
1622
+ url = moduleName + (ext || '');
1393
1623
  } else {
1394
1624
  //A module that needs to be converted to a path.
1395
1625
  paths = config.paths;
1396
1626
  pkgs = config.pkgs;
1397
1627
 
1398
- syms = moduleName.split("/");
1628
+ syms = moduleName.split('/');
1399
1629
  //For each module name segment, see if there is a path
1400
1630
  //registered for it. Start with most specific name
1401
1631
  //and work up from it.
1402
- for (i = syms.length; i > 0; i--) {
1403
- parentModule = syms.slice(0, i).join("/");
1404
- if (paths[parentModule]) {
1405
- syms.splice(0, i, paths[parentModule]);
1632
+ for (i = syms.length; i > 0; i -= 1) {
1633
+ parentModule = syms.slice(0, i).join('/');
1634
+ pkg = pkgs[parentModule];
1635
+ parentPath = paths[parentModule];
1636
+ if (parentPath) {
1637
+ //If an array, it means there are a few choices,
1638
+ //Choose the one that is desired
1639
+ if (isArray(parentPath)) {
1640
+ parentPath = parentPath[0];
1641
+ }
1642
+ syms.splice(0, i, parentPath);
1406
1643
  break;
1407
- } else if ((pkg = pkgs[parentModule])) {
1644
+ } else if (pkg) {
1408
1645
  //If module name is just the package name, then looking
1409
1646
  //for the main module.
1410
1647
  if (moduleName === pkg.name) {
@@ -1418,22 +1655,65 @@ var requirejs, require, define;
1418
1655
  }
1419
1656
 
1420
1657
  //Join the path parts together, then figure out if baseUrl is needed.
1421
- url = syms.join("/") + (ext || ".js");
1422
- url = (url.charAt(0) === '/' || url.match(/^\w+:/) ? "" : config.baseUrl) + url;
1658
+ url = syms.join('/');
1659
+ url += (ext || (/\?/.test(url) ? '' : '.js'));
1660
+ url = (url.charAt(0) === '/' || url.match(/^[\w\+\.\-]+:/) ? '' : config.baseUrl) + url;
1423
1661
  }
1424
1662
 
1425
1663
  return config.urlArgs ? url +
1426
1664
  ((url.indexOf('?') === -1 ? '?' : '&') +
1427
1665
  config.urlArgs) : url;
1428
- }
1429
- };
1666
+ },
1430
1667
 
1431
- //Make these visible on the context so can be called at the very
1432
- //end of the file to bootstrap
1433
- context.jQueryCheck = jQueryCheck;
1434
- context.resume = resume;
1668
+ //Delegates to req.load. Broken out as a separate function to
1669
+ //allow overriding in the optimizer.
1670
+ load: function (id, url) {
1671
+ req.load(context, id, url);
1672
+ },
1435
1673
 
1436
- return context;
1674
+ /**
1675
+ * Executes a module callack function. Broken out as a separate function
1676
+ * solely to allow the build system to sequence the files in the built
1677
+ * layer in the right sequence.
1678
+ *
1679
+ * @private
1680
+ */
1681
+ execCb: function (name, callback, args, exports) {
1682
+ return callback.apply(exports, args);
1683
+ },
1684
+
1685
+ /**
1686
+ * callback for script loads, used to check status of loading.
1687
+ *
1688
+ * @param {Event} evt the event from the browser for the script
1689
+ * that was loaded.
1690
+ */
1691
+ onScriptLoad: function (evt) {
1692
+ //Using currentTarget instead of target for Firefox 2.0's sake. Not
1693
+ //all old browsers will be supported, but this one was easy enough
1694
+ //to support and still makes sense.
1695
+ if (evt.type === 'load' ||
1696
+ (readyRegExp.test((evt.currentTarget || evt.srcElement).readyState))) {
1697
+ //Reset interactive script so a script node is not held onto for
1698
+ //to long.
1699
+ interactiveScript = null;
1700
+
1701
+ //Pull out the name of the module and the context.
1702
+ var data = getScriptData(evt);
1703
+ context.completeLoad(data.id);
1704
+ }
1705
+ },
1706
+
1707
+ /**
1708
+ * Callback for script errors.
1709
+ */
1710
+ onScriptError: function (evt) {
1711
+ var data = getScriptData(evt);
1712
+ if (!hasPathFallback(data.id)) {
1713
+ return onError(makeError('scripterror', 'Script error', evt, [data.id]));
1714
+ }
1715
+ }
1716
+ });
1437
1717
  }
1438
1718
 
1439
1719
  /**
@@ -1450,20 +1730,21 @@ var requirejs, require, define;
1450
1730
  * on a require that are not standardized), and to give a short
1451
1731
  * name for minification/local scope use.
1452
1732
  */
1453
- req = requirejs = function (deps, callback) {
1733
+ req = requirejs = function (deps, callback, errback, optional) {
1454
1734
 
1455
1735
  //Find the right context, use default
1456
- var contextName = defContextName,
1457
- context, config;
1736
+ var context, config,
1737
+ contextName = defContextName;
1458
1738
 
1459
1739
  // Determine if have config object in the call.
1460
- if (!isArray(deps) && typeof deps !== "string") {
1740
+ if (!isArray(deps) && typeof deps !== 'string') {
1461
1741
  // deps is a config object
1462
1742
  config = deps;
1463
1743
  if (isArray(callback)) {
1464
1744
  // Adjust args if there are dependencies
1465
1745
  deps = callback;
1466
- callback = arguments[2];
1746
+ callback = errback;
1747
+ errback = optional;
1467
1748
  } else {
1468
1749
  deps = [];
1469
1750
  }
@@ -1473,14 +1754,16 @@ var requirejs, require, define;
1473
1754
  contextName = config.context;
1474
1755
  }
1475
1756
 
1476
- context = contexts[contextName] ||
1477
- (contexts[contextName] = newContext(contextName));
1757
+ context = contexts[contextName];
1758
+ if (!context) {
1759
+ context = contexts[contextName] = req.s.newContext(contextName);
1760
+ }
1478
1761
 
1479
1762
  if (config) {
1480
1763
  context.configure(config);
1481
1764
  }
1482
1765
 
1483
- return context.require(deps, callback);
1766
+ return context.require(deps, callback, errback);
1484
1767
  };
1485
1768
 
1486
1769
  /**
@@ -1494,39 +1777,33 @@ var requirejs, require, define;
1494
1777
  /**
1495
1778
  * Export require as a global, but only if it does not already exist.
1496
1779
  */
1497
- if (typeof require === "undefined") {
1780
+ if (!require) {
1498
1781
  require = req;
1499
1782
  }
1500
1783
 
1501
- /**
1502
- * Global require.toUrl(), to match global require, mostly useful
1503
- * for debugging/work in the global space.
1504
- */
1505
- req.toUrl = function (moduleNamePlusExt) {
1506
- return contexts[defContextName].toUrl(moduleNamePlusExt);
1507
- };
1508
-
1509
1784
  req.version = version;
1510
- req.isArray = isArray;
1511
- req.isFunction = isFunction;
1512
- req.mixin = mixin;
1785
+
1513
1786
  //Used to filter out dependencies that are already paths.
1514
1787
  req.jsExtRegExp = /^\/|:|\?|\.js$/;
1788
+ req.isBrowser = isBrowser;
1515
1789
  s = req.s = {
1516
1790
  contexts: contexts,
1517
- //Stores a list of URLs that should not get async script tag treatment.
1518
- skipAsync: {},
1519
- isPageLoaded: !isBrowser,
1520
- readyCalls: []
1791
+ newContext: newContext
1521
1792
  };
1522
1793
 
1523
- req.isAsync = req.isBrowser = isBrowser;
1794
+ //Create default context.
1795
+ req({});
1796
+
1797
+ //Exports some context-sensitive methods on global require, using
1798
+ //default context if no context specified.
1799
+ addRequireMethods(req);
1800
+
1524
1801
  if (isBrowser) {
1525
- head = s.head = document.getElementsByTagName("head")[0];
1802
+ head = s.head = document.getElementsByTagName('head')[0];
1526
1803
  //If BASE tag is in play, using appendChild is a problem for IE6.
1527
1804
  //When that browser dies, this can be removed. Details in this jQuery bug:
1528
1805
  //http://dev.jquery.com/ticket/2709
1529
- baseElement = document.getElementsByTagName("base")[0];
1806
+ baseElement = document.getElementsByTagName('base')[0];
1530
1807
  if (baseElement) {
1531
1808
  head = s.head = baseElement.parentNode;
1532
1809
  }
@@ -1551,215 +1828,19 @@ var requirejs, require, define;
1551
1828
  * @param {Object} url the URL to the module.
1552
1829
  */
1553
1830
  req.load = function (context, moduleName, url) {
1554
- var loaded = context.loaded;
1555
-
1556
- isDone = false;
1557
-
1558
- //Only set loaded to false for tracking if it has not already been set.
1559
- if (!loaded[moduleName]) {
1560
- loaded[moduleName] = false;
1561
- }
1562
-
1563
- context.scriptCount += 1;
1564
- req.attach(url, context, moduleName);
1565
-
1566
- //If tracking a jQuery, then make sure its ready callbacks
1567
- //are put on hold to prevent its ready callbacks from
1568
- //triggering too soon.
1569
- if (context.jQuery && !context.jQueryIncremented) {
1570
- jQueryHoldReady(context.jQuery, true);
1571
- context.jQueryIncremented = true;
1572
- }
1573
- };
1574
-
1575
- function getInteractiveScript() {
1576
- var scripts, i, script;
1577
- if (interactiveScript && interactiveScript.readyState === 'interactive') {
1578
- return interactiveScript;
1579
- }
1580
-
1581
- scripts = document.getElementsByTagName('script');
1582
- for (i = scripts.length - 1; i > -1 && (script = scripts[i]); i--) {
1583
- if (script.readyState === 'interactive') {
1584
- return (interactiveScript = script);
1585
- }
1586
- }
1587
-
1588
- return null;
1589
- }
1590
-
1591
- /**
1592
- * The function that handles definitions of modules. Differs from
1593
- * require() in that a string for the module should be the first argument,
1594
- * and the function to execute after dependencies are loaded should
1595
- * return a value to define the module corresponding to the first argument's
1596
- * name.
1597
- */
1598
- define = req.def = function (name, deps, callback) {
1599
- var node, context;
1600
-
1601
- //Allow for anonymous functions
1602
- if (typeof name !== 'string') {
1603
- //Adjust args appropriately
1604
- callback = deps;
1605
- deps = name;
1606
- name = null;
1607
- }
1608
-
1609
- //This module may not have dependencies
1610
- if (!req.isArray(deps)) {
1611
- callback = deps;
1612
- deps = [];
1613
- }
1614
-
1615
- //If no name, and callback is a function, then figure out if it a
1616
- //CommonJS thing with dependencies.
1617
- if (!name && !deps.length && req.isFunction(callback)) {
1618
- //Remove comments from the callback string,
1619
- //look for require calls, and pull them into the dependencies,
1620
- //but only if there are function args.
1621
- if (callback.length) {
1622
- callback
1623
- .toString()
1624
- .replace(commentRegExp, "")
1625
- .replace(cjsRequireRegExp, function (match, dep) {
1626
- deps.push(dep);
1627
- });
1628
-
1629
- //May be a CommonJS thing even without require calls, but still
1630
- //could use exports, and module. Avoid doing exports and module
1631
- //work though if it just needs require.
1632
- //REQUIRES the function to expect the CommonJS variables in the
1633
- //order listed below.
1634
- deps = (callback.length === 1 ? ["require"] : ["require", "exports", "module"]).concat(deps);
1635
- }
1636
- }
1637
-
1638
- //If in IE 6-8 and hit an anonymous define() call, do the interactive
1639
- //work.
1640
- if (useInteractive) {
1641
- node = currentlyAddingScript || getInteractiveScript();
1642
- if (node) {
1643
- if (!name) {
1644
- name = node.getAttribute("data-requiremodule");
1645
- }
1646
- context = contexts[node.getAttribute("data-requirecontext")];
1647
- }
1648
- }
1649
-
1650
- //Always save off evaluating the def call until the script onload handler.
1651
- //This allows multiple modules to be in a file without prematurely
1652
- //tracing dependencies, and allows for anonymous module support,
1653
- //where the module name is not known until the script onload event
1654
- //occurs. If no context, use the global queue, and get it processed
1655
- //in the onscript load callback.
1656
- (context ? context.defQueue : globalDefQueue).push([name, deps, callback]);
1657
-
1658
- return undefined;
1659
- };
1660
-
1661
- define.amd = {
1662
- multiversion: true,
1663
- plugins: true,
1664
- jQuery: true
1665
- };
1666
-
1667
- /**
1668
- * Executes the text. Normally just uses eval, but can be modified
1669
- * to use a more environment specific call.
1670
- * @param {String} text the text to execute/evaluate.
1671
- */
1672
- req.exec = function (text) {
1673
- return eval(text);
1674
- };
1675
-
1676
- /**
1677
- * Executes a module callack function. Broken out as a separate function
1678
- * solely to allow the build system to sequence the files in the built
1679
- * layer in the right sequence.
1680
- *
1681
- * @private
1682
- */
1683
- req.execCb = function (name, callback, args, exports) {
1684
- return callback.apply(exports, args);
1685
- };
1686
-
1687
- /**
1688
- * callback for script loads, used to check status of loading.
1689
- *
1690
- * @param {Event} evt the event from the browser for the script
1691
- * that was loaded.
1692
- *
1693
- * @private
1694
- */
1695
- req.onScriptLoad = function (evt) {
1696
- //Using currentTarget instead of target for Firefox 2.0's sake. Not
1697
- //all old browsers will be supported, but this one was easy enough
1698
- //to support and still makes sense.
1699
- var node = evt.currentTarget || evt.srcElement || currentlyAddingScript, contextName, moduleName,
1700
- context;
1701
-
1702
- if (evt.type === "load" || readyRegExp.test(node.readyState)) {
1703
- //Reset interactive script so a script node is not held onto for
1704
- //to long.
1705
- interactiveScript = null;
1706
-
1707
- //Pull out the name of the module and the context.
1708
- contextName = node.getAttribute("data-requirecontext");
1709
- moduleName = node.getAttribute("data-requiremodule");
1710
- context = contexts[contextName];
1711
-
1712
- contexts[contextName].completeLoad(moduleName);
1713
-
1714
- //Clean up script binding. Favor detachEvent because of IE9
1715
- //issue, see attachEvent/addEventListener comment elsewhere
1716
- //in this file.
1717
- if (node.detachEvent && !isOpera) {
1718
- //Probably IE. If not it will throw an error, which will be
1719
- //useful to know.
1720
- node.detachEvent("onreadystatechange", req.onScriptLoad);
1721
- } else {
1722
- node.removeEventListener("load", req.onScriptLoad, false);
1723
- }
1724
- }
1725
- };
1726
-
1727
- /**
1728
- * Attaches the script represented by the URL to the current
1729
- * environment. Right now only supports browser loading,
1730
- * but can be redefined in other environments to do the right thing.
1731
- * @param {String} url the url of the script to attach.
1732
- * @param {Object} context the context that wants the script.
1733
- * @param {moduleName} the name of the module that is associated with the script.
1734
- * @param {Function} [callback] optional callback, defaults to require.onScriptLoad
1735
- * @param {String} [type] optional type, defaults to text/javascript
1736
- */
1737
- req.attach = function (url, context, moduleName, callback, type) {
1738
- var node, loaded;
1831
+ var config = (context && context.config) || {},
1832
+ node;
1739
1833
  if (isBrowser) {
1740
1834
  //In the browser so use a script tag
1741
- callback = callback || req.onScriptLoad;
1742
- node = context && context.config && context.config.xhtml ?
1743
- document.createElementNS("http://www.w3.org/1999/xhtml", "html:script") :
1744
- document.createElement("script");
1745
- node.type = type || "text/javascript";
1746
- node.charset = "utf-8";
1747
- //Use async so Gecko does not block on executing the script if something
1748
- //like a long-polling comet tag is being run first. Gecko likes
1749
- //to evaluate scripts in DOM order, even for dynamic scripts.
1750
- //It will fetch them async, but only evaluate the contents in DOM
1751
- //order, so a long-polling script tag can delay execution of scripts
1752
- //after it. But telling Gecko we expect async gets us the behavior
1753
- //we want -- execute it whenever it is finished downloading. Only
1754
- //Helps Firefox 3.6+
1755
- //Allow some URLs to not be fetched async. Mostly helps the order!
1756
- //plugin
1757
- node.async = !s.skipAsync[url];
1758
-
1759
- if (context) {
1760
- node.setAttribute("data-requirecontext", context.contextName);
1761
- }
1762
- node.setAttribute("data-requiremodule", moduleName);
1835
+ node = config.xhtml ?
1836
+ document.createElementNS('http://www.w3.org/1999/xhtml', 'html:script') :
1837
+ document.createElement('script');
1838
+ node.type = config.scriptType || 'text/javascript';
1839
+ node.charset = 'utf-8';
1840
+ node.async = true;
1841
+
1842
+ node.setAttribute('data-requirecontext', context.contextName);
1843
+ node.setAttribute('data-requiremodule', moduleName);
1763
1844
 
1764
1845
  //Set up load listener. Test attachEvent first because IE9 has
1765
1846
  //a subtle issue in its addEventListener and script onload firings
@@ -1769,16 +1850,38 @@ var requirejs, require, define;
1769
1850
  //https://connect.microsoft.com/IE/feedback/details/648057/script-onload-event-is-not-fired-immediately-after-script-execution
1770
1851
  //UNFORTUNATELY Opera implements attachEvent but does not follow the script
1771
1852
  //script execution mode.
1772
- if (node.attachEvent && !isOpera) {
1853
+ if (node.attachEvent &&
1854
+ //Check if node.attachEvent is artificially added by custom script or
1855
+ //natively supported by browser
1856
+ //read https://github.com/jrburke/requirejs/issues/187
1857
+ //if we can NOT find [native code] then it must NOT natively supported.
1858
+ //in IE8, node.attachEvent does not have toString()
1859
+ //Note the test for "[native code" with no closing brace, see:
1860
+ //https://github.com/jrburke/requirejs/issues/273
1861
+ !(node.attachEvent.toString && node.attachEvent.toString().indexOf('[native code') < 0) &&
1862
+ !isOpera) {
1773
1863
  //Probably IE. IE (at least 6-8) do not fire
1774
1864
  //script onload right after executing the script, so
1775
1865
  //we cannot tie the anonymous define call to a name.
1776
- //However, IE reports the script as being in "interactive"
1866
+ //However, IE reports the script as being in 'interactive'
1777
1867
  //readyState at the time of the define call.
1778
1868
  useInteractive = true;
1779
- node.attachEvent("onreadystatechange", callback);
1869
+
1870
+ node.attachEvent('onreadystatechange', context.onScriptLoad);
1871
+ //It would be great to add an error handler here to catch
1872
+ //404s in IE9+. However, onreadystatechange will fire before
1873
+ //the error handler, so that does not help. If addEvenListener
1874
+ //is used, then IE will fire error before load, but we cannot
1875
+ //use that pathway given the connect.microsoft.com issue
1876
+ //mentioned above about not doing the 'script execute,
1877
+ //then fire the script load event listener before execute
1878
+ //next script' that other browsers do.
1879
+ //Best hope: IE10 fixes the issues,
1880
+ //and then destroys all installs of IE 6-9.
1881
+ //node.attachEvent('onerror', context.onScriptError);
1780
1882
  } else {
1781
- node.addEventListener("load", callback, false);
1883
+ node.addEventListener('load', context.onScriptLoad, false);
1884
+ node.addEventListener('error', context.onScriptError, false);
1782
1885
  }
1783
1886
  node.src = url;
1784
1887
 
@@ -1793,6 +1896,7 @@ var requirejs, require, define;
1793
1896
  head.appendChild(node);
1794
1897
  }
1795
1898
  currentlyAddingScript = null;
1899
+
1796
1900
  return node;
1797
1901
  } else if (isWebWorker) {
1798
1902
  //In a web worker, use importScripts. This is not a very
@@ -1801,24 +1905,31 @@ var requirejs, require, define;
1801
1905
  //are in play, the expectation that a build has been done so that
1802
1906
  //only one script needs to be loaded anyway. This may need to be
1803
1907
  //reevaluated if other use cases become common.
1804
- loaded = context.loaded;
1805
- loaded[moduleName] = false;
1806
-
1807
1908
  importScripts(url);
1808
1909
 
1809
1910
  //Account for anonymous modules
1810
1911
  context.completeLoad(moduleName);
1811
1912
  }
1812
- return null;
1813
1913
  };
1814
1914
 
1915
+ function getInteractiveScript() {
1916
+ if (interactiveScript && interactiveScript.readyState === 'interactive') {
1917
+ return interactiveScript;
1918
+ }
1919
+
1920
+ eachReverse(scripts(), function (script) {
1921
+ if (script.readyState === 'interactive') {
1922
+ return (interactiveScript = script);
1923
+ }
1924
+ });
1925
+ return interactiveScript;
1926
+ }
1927
+
1815
1928
  //Look for a data-main script attribute, which could also adjust the baseUrl.
1816
1929
  if (isBrowser) {
1817
1930
  //Figure out baseUrl. Get it from the script tag with require.js in it.
1818
- scripts = document.getElementsByTagName("script");
1819
-
1820
- for (i = scripts.length - 1; i > -1 && (script = scripts[i]); i--) {
1821
- //Set the "head" where we can append children by
1931
+ eachReverse(scripts(), function (script) {
1932
+ //Set the 'head' where we can append children by
1822
1933
  //using the script's parent.
1823
1934
  if (!head) {
1824
1935
  head = script.parentNode;
@@ -1827,7 +1938,9 @@ var requirejs, require, define;
1827
1938
  //Look for a data-main attribute to set main script for the page
1828
1939
  //to load. If it is there, the path to data main becomes the
1829
1940
  //baseUrl, if it is not already set.
1830
- if ((dataMain = script.getAttribute('data-main'))) {
1941
+ dataMain = script.getAttribute('data-main');
1942
+ if (dataMain) {
1943
+ //Set final baseUrl if there is not already an explicit one.
1831
1944
  if (!cfg.baseUrl) {
1832
1945
  //Pull off the directory of data-main for use as the
1833
1946
  //baseUrl.
@@ -1835,179 +1948,106 @@ var requirejs, require, define;
1835
1948
  mainScript = src.pop();
1836
1949
  subPath = src.length ? src.join('/') + '/' : './';
1837
1950
 
1838
- //Set final config.
1839
1951
  cfg.baseUrl = subPath;
1840
- //Strip off any trailing .js since dataMain is now
1841
- //like a module name.
1842
- dataMain = mainScript.replace(jsSuffixRegExp, '');
1952
+ dataMain = mainScript;
1843
1953
  }
1844
1954
 
1955
+ //Strip off any trailing .js since dataMain is now
1956
+ //like a module name.
1957
+ dataMain = dataMain.replace(jsSuffixRegExp, '');
1958
+
1845
1959
  //Put the data-main script in the files to load.
1846
1960
  cfg.deps = cfg.deps ? cfg.deps.concat(dataMain) : [dataMain];
1847
1961
 
1848
- break;
1962
+ return true;
1849
1963
  }
1850
- }
1964
+ });
1851
1965
  }
1852
1966
 
1853
- //Set baseUrl based on config.
1854
- s.baseUrl = cfg.baseUrl;
1855
-
1856
- //****** START page load functionality ****************
1857
1967
  /**
1858
- * Sets the page as loaded and triggers check for all modules loaded.
1968
+ * The function that handles definitions of modules. Differs from
1969
+ * require() in that a string for the module should be the first argument,
1970
+ * and the function to execute after dependencies are loaded should
1971
+ * return a value to define the module corresponding to the first argument's
1972
+ * name.
1859
1973
  */
1860
- req.pageLoaded = function () {
1861
- if (!s.isPageLoaded) {
1862
- s.isPageLoaded = true;
1863
- if (scrollIntervalId) {
1864
- clearInterval(scrollIntervalId);
1865
- }
1866
-
1867
- //Part of a fix for FF < 3.6 where readyState was not set to
1868
- //complete so libraries like jQuery that check for readyState
1869
- //after page load where not getting initialized correctly.
1870
- //Original approach suggested by Andrea Giammarchi:
1871
- //http://webreflection.blogspot.com/2009/11/195-chars-to-help-lazy-loading.html
1872
- //see other setReadyState reference for the rest of the fix.
1873
- if (setReadyState) {
1874
- document.readyState = "complete";
1875
- }
1974
+ define = function (name, deps, callback) {
1975
+ var node, context;
1876
1976
 
1877
- req.callReady();
1977
+ //Allow for anonymous functions
1978
+ if (typeof name !== 'string') {
1979
+ //Adjust args appropriately
1980
+ callback = deps;
1981
+ deps = name;
1982
+ name = null;
1878
1983
  }
1879
- };
1880
1984
 
1881
- //See if there is nothing waiting across contexts, and if not, trigger
1882
- //callReady.
1883
- req.checkReadyState = function () {
1884
- var contexts = s.contexts, prop;
1885
- for (prop in contexts) {
1886
- if (!(prop in empty)) {
1887
- if (contexts[prop].waitCount) {
1888
- return;
1889
- }
1890
- }
1985
+ //This module may not have dependencies
1986
+ if (!isArray(deps)) {
1987
+ callback = deps;
1988
+ deps = [];
1891
1989
  }
1892
- s.isDone = true;
1893
- req.callReady();
1894
- };
1895
1990
 
1896
- /**
1897
- * Internal function that calls back any ready functions. If you are
1898
- * integrating RequireJS with another library without require.ready support,
1899
- * you can define this method to call your page ready code instead.
1900
- */
1901
- req.callReady = function () {
1902
- var callbacks = s.readyCalls, i, callback, contexts, context, prop;
1903
-
1904
- if (s.isPageLoaded && s.isDone) {
1905
- if (callbacks.length) {
1906
- s.readyCalls = [];
1907
- for (i = 0; (callback = callbacks[i]); i++) {
1908
- callback();
1909
- }
1991
+ //If no name, and callback is a function, then figure out if it a
1992
+ //CommonJS thing with dependencies.
1993
+ if (!deps.length && isFunction(callback)) {
1994
+ //Remove comments from the callback string,
1995
+ //look for require calls, and pull them into the dependencies,
1996
+ //but only if there are function args.
1997
+ if (callback.length) {
1998
+ callback
1999
+ .toString()
2000
+ .replace(commentRegExp, '')
2001
+ .replace(cjsRequireRegExp, function (match, dep) {
2002
+ deps.push(dep);
2003
+ });
2004
+
2005
+ //May be a CommonJS thing even without require calls, but still
2006
+ //could use exports, and module. Avoid doing exports and module
2007
+ //work though if it just needs require.
2008
+ //REQUIRES the function to expect the CommonJS variables in the
2009
+ //order listed below.
2010
+ deps = (callback.length === 1 ? ['require'] : ['require', 'exports', 'module']).concat(deps);
1910
2011
  }
2012
+ }
1911
2013
 
1912
- //If jQuery with DOM ready delayed, release it now.
1913
- contexts = s.contexts;
1914
- for (prop in contexts) {
1915
- if (!(prop in empty)) {
1916
- context = contexts[prop];
1917
- if (context.jQueryIncremented) {
1918
- jQueryHoldReady(context.jQuery, false);
1919
- context.jQueryIncremented = false;
1920
- }
2014
+ //If in IE 6-8 and hit an anonymous define() call, do the interactive
2015
+ //work.
2016
+ if (useInteractive) {
2017
+ node = currentlyAddingScript || getInteractiveScript();
2018
+ if (node) {
2019
+ if (!name) {
2020
+ name = node.getAttribute('data-requiremodule');
1921
2021
  }
2022
+ context = contexts[node.getAttribute('data-requirecontext')];
1922
2023
  }
1923
2024
  }
2025
+
2026
+ //Always save off evaluating the def call until the script onload handler.
2027
+ //This allows multiple modules to be in a file without prematurely
2028
+ //tracing dependencies, and allows for anonymous module support,
2029
+ //where the module name is not known until the script onload event
2030
+ //occurs. If no context, use the global queue, and get it processed
2031
+ //in the onscript load callback.
2032
+ (context ? context.defQueue : globalDefQueue).push([name, deps, callback]);
1924
2033
  };
1925
2034
 
1926
- /**
1927
- * Registers functions to call when the page is loaded
1928
- */
1929
- req.ready = function (callback) {
1930
- if (s.isPageLoaded && s.isDone) {
1931
- callback();
1932
- } else {
1933
- s.readyCalls.push(callback);
1934
- }
1935
- return req;
2035
+ define.amd = {
2036
+ jQuery: true
1936
2037
  };
1937
2038
 
1938
- if (isBrowser) {
1939
- if (document.addEventListener) {
1940
- //Standards. Hooray! Assumption here that if standards based,
1941
- //it knows about DOMContentLoaded.
1942
- document.addEventListener("DOMContentLoaded", req.pageLoaded, false);
1943
- window.addEventListener("load", req.pageLoaded, false);
1944
- //Part of FF < 3.6 readystate fix (see setReadyState refs for more info)
1945
- if (!document.readyState) {
1946
- setReadyState = true;
1947
- document.readyState = "loading";
1948
- }
1949
- } else if (window.attachEvent) {
1950
- window.attachEvent("onload", req.pageLoaded);
1951
-
1952
- //DOMContentLoaded approximation, as found by Diego Perini:
1953
- //http://javascript.nwbox.com/IEContentLoaded/
1954
- if (self === self.top) {
1955
- scrollIntervalId = setInterval(function () {
1956
- try {
1957
- //From this ticket:
1958
- //http://bugs.dojotoolkit.org/ticket/11106,
1959
- //In IE HTML Application (HTA), such as in a selenium test,
1960
- //javascript in the iframe can't see anything outside
1961
- //of it, so self===self.top is true, but the iframe is
1962
- //not the top window and doScroll will be available
1963
- //before document.body is set. Test document.body
1964
- //before trying the doScroll trick.
1965
- if (document.body) {
1966
- document.documentElement.doScroll("left");
1967
- req.pageLoaded();
1968
- }
1969
- } catch (e) {}
1970
- }, 30);
1971
- }
1972
- }
1973
2039
 
1974
- //Check if document already complete, and if so, just trigger page load
1975
- //listeners. NOTE: does not work with Firefox before 3.6. To support
1976
- //those browsers, manually call require.pageLoaded().
1977
- if (document.readyState === "complete") {
1978
- req.pageLoaded();
1979
- }
1980
- }
1981
- //****** END page load functionality ****************
2040
+ /**
2041
+ * Executes the text. Normally just uses eval, but can be modified
2042
+ * to use a better, environment-specific call. Only used for transpiling
2043
+ * loader plugins, not for plain JS modules.
2044
+ * @param {String} text the text to execute/evaluate.
2045
+ */
2046
+ req.exec = function (text) {
2047
+ /*jslint evil: true */
2048
+ return eval(text);
2049
+ };
1982
2050
 
1983
- //Set up default context. If require was a configuration object, use that as base config.
2051
+ //Set up with config info.
1984
2052
  req(cfg);
1985
-
1986
- //If modules are built into require.js, then need to make sure dependencies are
1987
- //traced. Use a setTimeout in the browser world, to allow all the modules to register
1988
- //themselves. In a non-browser env, assume that modules are not built into require.js,
1989
- //which seems odd to do on the server.
1990
- if (req.isAsync && typeof setTimeout !== "undefined") {
1991
- ctx = s.contexts[(cfg.context || defContextName)];
1992
- //Indicate that the script that includes require() is still loading,
1993
- //so that require()'d dependencies are not traced until the end of the
1994
- //file is parsed (approximated via the setTimeout call).
1995
- ctx.requireWait = true;
1996
- setTimeout(function () {
1997
- ctx.requireWait = false;
1998
-
1999
- //Any modules included with the require.js file will be in the
2000
- //global queue, assign them to this context.
2001
- ctx.takeGlobalQueue();
2002
-
2003
- //Allow for jQuery to be loaded/already in the page, and if jQuery 1.4.3,
2004
- //make sure to hold onto it for readyWait triggering.
2005
- ctx.jQueryCheck();
2006
-
2007
- if (!ctx.scriptCount) {
2008
- ctx.resume();
2009
- }
2010
- req.checkReadyState();
2011
- }, 0);
2012
- }
2013
- }());
2053
+ }(this));