drg_default_html_editor 0.5.50.3 → 0.7.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (543) hide show
  1. checksums.yaml +5 -5
  2. data/app/assets/images/arrow.png +0 -0
  3. data/app/assets/images/close.png +0 -0
  4. data/app/assets/images/lock-open.png +0 -0
  5. data/app/assets/images/lock.png +0 -0
  6. data/app/assets/images/refresh.png +0 -0
  7. data/app/assets/images/spinner.gif +0 -0
  8. data/app/assets/javascripts/ckeditor/CHANGES.md +2040 -415
  9. data/app/assets/javascripts/ckeditor/LICENSE.md +180 -8
  10. data/app/assets/javascripts/ckeditor/README.md +5 -5
  11. data/app/assets/javascripts/ckeditor/SECURITY.md +10 -0
  12. data/app/assets/javascripts/ckeditor/adapters/jquery.js +8 -8
  13. data/app/assets/javascripts/ckeditor/bender-runner.config.json +16 -0
  14. data/app/assets/javascripts/ckeditor/build-config.js +68 -47
  15. data/app/assets/javascripts/ckeditor/ckeditor.js +1420 -974
  16. data/app/assets/javascripts/ckeditor/config.js +7 -2
  17. data/app/assets/javascripts/ckeditor/contents.css +83 -9
  18. data/app/assets/javascripts/ckeditor/lang/af.js +4 -4
  19. data/app/assets/javascripts/ckeditor/lang/ar.js +4 -4
  20. data/app/assets/javascripts/ckeditor/lang/az.js +5 -0
  21. data/app/assets/javascripts/ckeditor/lang/bg.js +4 -4
  22. data/app/assets/javascripts/ckeditor/lang/bn.js +4 -4
  23. data/app/assets/javascripts/ckeditor/lang/bs.js +4 -4
  24. data/app/assets/javascripts/ckeditor/lang/ca.js +4 -4
  25. data/app/assets/javascripts/ckeditor/lang/cs.js +4 -4
  26. data/app/assets/javascripts/ckeditor/lang/cy.js +4 -4
  27. data/app/assets/javascripts/ckeditor/lang/da.js +4 -4
  28. data/app/assets/javascripts/ckeditor/lang/de-ch.js +5 -0
  29. data/app/assets/javascripts/ckeditor/lang/de.js +4 -4
  30. data/app/assets/javascripts/ckeditor/lang/el.js +4 -4
  31. data/app/assets/javascripts/ckeditor/lang/en-au.js +4 -4
  32. data/app/assets/javascripts/ckeditor/lang/en-ca.js +4 -4
  33. data/app/assets/javascripts/ckeditor/lang/en-gb.js +4 -4
  34. data/app/assets/javascripts/ckeditor/lang/en.js +4 -4
  35. data/app/assets/javascripts/ckeditor/lang/eo.js +4 -4
  36. data/app/assets/javascripts/ckeditor/lang/es-mx.js +5 -0
  37. data/app/assets/javascripts/ckeditor/lang/es.js +4 -4
  38. data/app/assets/javascripts/ckeditor/lang/et.js +4 -4
  39. data/app/assets/javascripts/ckeditor/lang/eu.js +4 -4
  40. data/app/assets/javascripts/ckeditor/lang/fa.js +4 -4
  41. data/app/assets/javascripts/ckeditor/lang/fi.js +4 -4
  42. data/app/assets/javascripts/ckeditor/lang/fo.js +4 -4
  43. data/app/assets/javascripts/ckeditor/lang/fr-ca.js +4 -4
  44. data/app/assets/javascripts/ckeditor/lang/fr.js +4 -4
  45. data/app/assets/javascripts/ckeditor/lang/gl.js +4 -4
  46. data/app/assets/javascripts/ckeditor/lang/gu.js +4 -4
  47. data/app/assets/javascripts/ckeditor/lang/he.js +4 -4
  48. data/app/assets/javascripts/ckeditor/lang/hi.js +4 -4
  49. data/app/assets/javascripts/ckeditor/lang/hr.js +4 -4
  50. data/app/assets/javascripts/ckeditor/lang/hu.js +4 -4
  51. data/app/assets/javascripts/ckeditor/lang/id.js +4 -4
  52. data/app/assets/javascripts/ckeditor/lang/is.js +4 -4
  53. data/app/assets/javascripts/ckeditor/lang/it.js +4 -4
  54. data/app/assets/javascripts/ckeditor/lang/ja.js +4 -4
  55. data/app/assets/javascripts/ckeditor/lang/ka.js +4 -4
  56. data/app/assets/javascripts/ckeditor/lang/km.js +4 -4
  57. data/app/assets/javascripts/ckeditor/lang/ko.js +4 -4
  58. data/app/assets/javascripts/ckeditor/lang/ku.js +4 -4
  59. data/app/assets/javascripts/ckeditor/lang/lt.js +4 -4
  60. data/app/assets/javascripts/ckeditor/lang/lv.js +4 -4
  61. data/app/assets/javascripts/ckeditor/lang/mk.js +4 -4
  62. data/app/assets/javascripts/ckeditor/lang/mn.js +4 -4
  63. data/app/assets/javascripts/ckeditor/lang/ms.js +4 -4
  64. data/app/assets/javascripts/ckeditor/lang/nb.js +4 -4
  65. data/app/assets/javascripts/ckeditor/lang/nl.js +4 -4
  66. data/app/assets/javascripts/ckeditor/lang/no.js +4 -4
  67. data/app/assets/javascripts/ckeditor/lang/oc.js +5 -0
  68. data/app/assets/javascripts/ckeditor/lang/pl.js +4 -4
  69. data/app/assets/javascripts/ckeditor/lang/pt-br.js +4 -4
  70. data/app/assets/javascripts/ckeditor/lang/pt.js +4 -4
  71. data/app/assets/javascripts/ckeditor/lang/ro.js +4 -4
  72. data/app/assets/javascripts/ckeditor/lang/ru.js +4 -4
  73. data/app/assets/javascripts/ckeditor/lang/si.js +4 -4
  74. data/app/assets/javascripts/ckeditor/lang/sk.js +4 -4
  75. data/app/assets/javascripts/ckeditor/lang/sl.js +4 -4
  76. data/app/assets/javascripts/ckeditor/lang/sq.js +4 -4
  77. data/app/assets/javascripts/ckeditor/lang/sr-latn.js +4 -4
  78. data/app/assets/javascripts/ckeditor/lang/sr.js +4 -4
  79. data/app/assets/javascripts/ckeditor/lang/sv.js +4 -4
  80. data/app/assets/javascripts/ckeditor/lang/th.js +4 -4
  81. data/app/assets/javascripts/ckeditor/lang/tr.js +4 -4
  82. data/app/assets/javascripts/ckeditor/lang/tt.js +4 -4
  83. data/app/assets/javascripts/ckeditor/lang/ug.js +4 -4
  84. data/app/assets/javascripts/ckeditor/lang/uk.js +4 -4
  85. data/app/assets/javascripts/ckeditor/lang/vi.js +4 -4
  86. data/app/assets/javascripts/ckeditor/lang/zh-cn.js +4 -4
  87. data/app/assets/javascripts/ckeditor/lang/zh.js +4 -4
  88. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/a11yhelp.js +7 -7
  89. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/_translationstatus.txt +2 -2
  90. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/af.js +11 -0
  91. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ar.js +10 -9
  92. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/az.js +11 -0
  93. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/bg.js +8 -7
  94. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ca.js +10 -10
  95. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/cs.js +10 -11
  96. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/cy.js +7 -7
  97. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/da.js +9 -9
  98. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/de-ch.js +13 -0
  99. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/de.js +11 -10
  100. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/el.js +7 -7
  101. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/en-au.js +11 -0
  102. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/en-gb.js +7 -6
  103. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/en.js +7 -6
  104. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/eo.js +7 -7
  105. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/es-mx.js +13 -0
  106. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/es.js +9 -8
  107. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/et.js +9 -9
  108. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/eu.js +12 -0
  109. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/fa.js +7 -7
  110. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/fi.js +8 -8
  111. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/fo.js +12 -0
  112. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/fr-ca.js +8 -8
  113. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/fr.js +11 -11
  114. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/gl.js +8 -8
  115. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/gu.js +7 -6
  116. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/he.js +7 -7
  117. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/hi.js +7 -6
  118. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/hr.js +9 -9
  119. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/hu.js +6 -7
  120. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/id.js +9 -9
  121. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/it.js +7 -7
  122. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ja.js +5 -5
  123. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/km.js +7 -6
  124. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ko.js +8 -8
  125. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ku.js +8 -9
  126. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/lt.js +7 -6
  127. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/lv.js +7 -7
  128. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/mk.js +10 -9
  129. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/mn.js +7 -6
  130. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/nb.js +9 -9
  131. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/nl.js +6 -6
  132. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/no.js +10 -9
  133. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/oc.js +12 -0
  134. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/pl.js +10 -10
  135. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/pt-br.js +9 -8
  136. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/pt.js +10 -10
  137. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ro.js +10 -10
  138. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ru.js +7 -7
  139. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/si.js +8 -8
  140. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sk.js +8 -9
  141. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sl.js +9 -9
  142. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sq.js +10 -9
  143. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sr-latn.js +10 -9
  144. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sr.js +10 -9
  145. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sv.js +9 -10
  146. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/th.js +7 -6
  147. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/tr.js +8 -8
  148. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/tt.js +10 -9
  149. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ug.js +8 -7
  150. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/uk.js +8 -8
  151. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/vi.js +7 -7
  152. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/zh-cn.js +7 -7
  153. data/app/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/zh.js +7 -8
  154. data/app/assets/javascripts/ckeditor/plugins/about/dialogs/about.js +6 -5
  155. data/app/assets/javascripts/ckeditor/plugins/about/dialogs/hidpi/logo_ckeditor.png +0 -0
  156. data/app/assets/javascripts/ckeditor/plugins/about/dialogs/logo_ckeditor.png +0 -0
  157. data/app/assets/javascripts/ckeditor/plugins/clipboard/dialogs/paste.js +9 -9
  158. data/app/assets/javascripts/ckeditor/plugins/colordialog/dialogs/colordialog.css +20 -0
  159. data/app/assets/javascripts/ckeditor/plugins/colordialog/dialogs/colordialog.js +12 -11
  160. data/app/assets/javascripts/ckeditor/plugins/copyformatting/cursors/cursor-disabled.svg +25 -0
  161. data/app/assets/javascripts/ckeditor/plugins/copyformatting/cursors/cursor.svg +14 -0
  162. data/app/assets/javascripts/ckeditor/plugins/copyformatting/styles/copyformatting.css +45 -0
  163. data/app/assets/javascripts/ckeditor/plugins/dialog/dialogDefinition.js +2 -2
  164. data/app/assets/javascripts/ckeditor/plugins/dialog/styles/dialog.css +18 -0
  165. data/app/assets/javascripts/ckeditor/plugins/div/dialogs/div.js +9 -8
  166. data/app/assets/javascripts/ckeditor/plugins/find/dialogs/find.js +24 -22
  167. data/app/assets/javascripts/ckeditor/plugins/icons.png +0 -0
  168. data/app/assets/javascripts/ckeditor/plugins/icons_hidpi.png +0 -0
  169. data/app/assets/javascripts/ckeditor/plugins/image/dialogs/image-org.js +44 -0
  170. data/app/assets/javascripts/ckeditor/plugins/image/dialogs/image.js +1286 -43
  171. data/app/assets/javascripts/ckeditor/plugins/image/images/noimage.png +0 -0
  172. data/app/assets/javascripts/ckeditor/plugins/link/dialogs/anchor.js +6 -5
  173. data/app/assets/javascripts/ckeditor/plugins/link/dialogs/link.js +28 -24
  174. data/app/assets/javascripts/ckeditor/plugins/link/images/anchor.png +0 -0
  175. data/app/assets/javascripts/ckeditor/plugins/link/images/hidpi/anchor.png +0 -0
  176. data/app/assets/javascripts/ckeditor/plugins/liststyle/dialogs/liststyle.js +8 -8
  177. data/app/assets/javascripts/ckeditor/plugins/magicline/images/hidpi/icon-rtl.png +0 -0
  178. data/app/assets/javascripts/ckeditor/plugins/magicline/images/hidpi/icon.png +0 -0
  179. data/app/assets/javascripts/ckeditor/plugins/magicline/images/icon-rtl.png +0 -0
  180. data/app/assets/javascripts/ckeditor/plugins/magicline/images/icon.png +0 -0
  181. data/app/assets/javascripts/ckeditor/plugins/pagebreak/images/pagebreak.gif +0 -0
  182. data/app/assets/javascripts/ckeditor/plugins/pastefromgdocs/filter/default.js +8 -0
  183. data/app/assets/javascripts/ckeditor/plugins/pastefromlibreoffice/filter/default.js +11 -0
  184. data/app/assets/javascripts/ckeditor/plugins/pastefromword/filter/default.js +40 -29
  185. data/app/assets/javascripts/ckeditor/plugins/pastetools/filter/common.js +24 -0
  186. data/app/assets/javascripts/ckeditor/plugins/pastetools/filter/image.js +12 -0
  187. data/app/assets/javascripts/ckeditor/plugins/preview/images/pagebreak.gif +0 -0
  188. data/app/assets/javascripts/ckeditor/plugins/preview/styles/screen.css +10 -0
  189. data/app/assets/javascripts/ckeditor/plugins/scayt/CHANGELOG.md +4 -0
  190. data/app/assets/javascripts/ckeditor/plugins/scayt/README.md +63 -7
  191. data/app/assets/javascripts/ckeditor/plugins/scayt/dialogs/dialog.css +23 -0
  192. data/app/assets/javascripts/ckeditor/plugins/scayt/dialogs/options.js +32 -17
  193. data/app/assets/javascripts/ckeditor/plugins/scayt/skins/moono-lisa/scayt.css +25 -0
  194. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_address.png +0 -0
  195. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_blockquote.png +0 -0
  196. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_div.png +0 -0
  197. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_h1.png +0 -0
  198. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_h2.png +0 -0
  199. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_h3.png +0 -0
  200. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_h4.png +0 -0
  201. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_h5.png +0 -0
  202. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_h6.png +0 -0
  203. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_p.png +0 -0
  204. data/app/assets/javascripts/ckeditor/plugins/showblocks/images/block_pre.png +0 -0
  205. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/_translationstatus.txt +2 -2
  206. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/af.js +13 -0
  207. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ar.js +3 -3
  208. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/az.js +10 -0
  209. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/bg.js +4 -4
  210. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ca.js +2 -2
  211. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/cs.js +3 -3
  212. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/cy.js +2 -2
  213. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/da.js +11 -0
  214. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/de-ch.js +13 -0
  215. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/de.js +11 -11
  216. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/el.js +5 -5
  217. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/en-au.js +13 -0
  218. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/en-ca.js +13 -0
  219. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/en-gb.js +3 -3
  220. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/en.js +3 -3
  221. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/eo.js +2 -2
  222. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/es-mx.js +13 -0
  223. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/es.js +2 -2
  224. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/et.js +9 -11
  225. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/eu.js +13 -0
  226. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/fa.js +2 -2
  227. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/fi.js +3 -3
  228. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/fr-ca.js +2 -2
  229. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/fr.js +10 -9
  230. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/gl.js +2 -2
  231. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/he.js +2 -2
  232. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/hr.js +11 -11
  233. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/hu.js +2 -2
  234. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/id.js +11 -11
  235. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/it.js +3 -3
  236. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ja.js +2 -2
  237. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/km.js +3 -3
  238. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ko.js +10 -0
  239. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ku.js +2 -2
  240. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/lt.js +13 -0
  241. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/lv.js +2 -2
  242. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/nb.js +2 -2
  243. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/nl.js +2 -2
  244. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/no.js +2 -2
  245. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/oc.js +12 -0
  246. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/pl.js +3 -3
  247. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/pt-br.js +2 -2
  248. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/pt.js +11 -11
  249. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ro.js +13 -0
  250. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ru.js +2 -2
  251. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/si.js +3 -3
  252. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/sk.js +2 -2
  253. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/sl.js +10 -10
  254. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/sq.js +5 -5
  255. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/sr-latn.js +13 -0
  256. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/sr.js +13 -0
  257. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/sv.js +2 -2
  258. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/th.js +3 -3
  259. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/tr.js +2 -2
  260. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/tt.js +6 -6
  261. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ug.js +3 -3
  262. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/uk.js +2 -2
  263. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/vi.js +2 -2
  264. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/zh-cn.js +3 -3
  265. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/zh.js +7 -10
  266. data/app/assets/javascripts/ckeditor/plugins/specialchar/dialogs/specialchar.js +12 -12
  267. data/app/assets/javascripts/ckeditor/plugins/table/dialogs/table.js +20 -19
  268. data/app/assets/javascripts/ckeditor/plugins/tableselection/styles/tableselection.css +36 -0
  269. data/app/assets/javascripts/ckeditor/plugins/tabletools/dialogs/tableCell.js +16 -15
  270. data/app/assets/javascripts/ckeditor/plugins/templates/dialogs/templates.css +2 -2
  271. data/app/assets/javascripts/ckeditor/plugins/templates/dialogs/templates.js +9 -8
  272. data/app/assets/javascripts/ckeditor/plugins/templates/templatedefinition.js +4 -0
  273. data/app/assets/javascripts/ckeditor/plugins/templates/templates/default.js +5 -4
  274. data/app/assets/javascripts/ckeditor/plugins/templates/templates/images/template1.gif +0 -0
  275. data/app/assets/javascripts/ckeditor/plugins/templates/templates/images/template2.gif +0 -0
  276. data/app/assets/javascripts/ckeditor/plugins/templates/templates/images/template3.gif +0 -0
  277. data/app/assets/javascripts/ckeditor/plugins/widget/images/handle.png +0 -0
  278. data/app/assets/javascripts/ckeditor/samples/css/samples.css +1637 -0
  279. data/app/assets/javascripts/ckeditor/samples/img/github-top.png +0 -0
  280. data/app/assets/javascripts/ckeditor/samples/img/header-bg.png +0 -0
  281. data/app/assets/javascripts/ckeditor/samples/img/header-separator.png +0 -0
  282. data/app/assets/javascripts/ckeditor/samples/img/logo.png +0 -0
  283. data/app/assets/javascripts/ckeditor/samples/img/logo.svg +13 -0
  284. data/app/assets/javascripts/ckeditor/samples/img/navigation-tip.png +0 -0
  285. data/app/assets/javascripts/ckeditor/samples/index.html +115 -113
  286. data/app/assets/javascripts/ckeditor/samples/js/sample.js +53 -0
  287. data/app/assets/javascripts/ckeditor/samples/js/sf.js +17 -0
  288. data/app/assets/javascripts/ckeditor/samples/{ajax.html → old/ajax.html} +10 -7
  289. data/app/assets/javascripts/ckeditor/samples/{api.html → old/api.html} +19 -16
  290. data/app/assets/javascripts/ckeditor/samples/{appendto.html → old/appendto.html} +12 -9
  291. data/app/assets/javascripts/ckeditor/samples/old/assets/inlineall/logo.png +0 -0
  292. data/app/assets/javascripts/ckeditor/samples/{assets → old/assets}/outputxhtml/outputxhtml.css +2 -2
  293. data/app/assets/javascripts/ckeditor/samples/{assets → old/assets}/posteddata.php +6 -5
  294. data/app/assets/javascripts/ckeditor/samples/old/assets/sample.jpg +0 -0
  295. data/app/assets/javascripts/ckeditor/samples/old/assets/uilanguages/languages.js +7 -0
  296. data/app/assets/javascripts/ckeditor/samples/{datafiltering.html → old/datafiltering.html} +125 -18
  297. data/app/assets/javascripts/ckeditor/samples/{plugins → old}/dialog/assets/my_dialog.js +3 -3
  298. data/app/assets/javascripts/ckeditor/samples/{plugins → old}/dialog/dialog.html +14 -11
  299. data/app/assets/javascripts/ckeditor/samples/{divreplace.html → old/divreplace.html} +10 -7
  300. data/app/assets/javascripts/ckeditor/samples/{plugins → old}/enterkey/enterkey.html +14 -11
  301. data/app/assets/javascripts/ckeditor/samples/{plugins → old}/htmlwriter/outputhtml.html +14 -11
  302. data/app/assets/javascripts/ckeditor/samples/old/index.html +129 -0
  303. data/app/assets/javascripts/ckeditor/samples/{inlineall.html → old/inlineall.html} +16 -13
  304. data/app/assets/javascripts/ckeditor/samples/{inlinebycode.html → old/inlinebycode.html} +11 -8
  305. data/app/assets/javascripts/ckeditor/samples/{inlinetextarea.html → old/inlinetextarea.html} +12 -9
  306. data/app/assets/javascripts/ckeditor/samples/{jquery.html → old/jquery.html} +13 -10
  307. data/app/assets/javascripts/ckeditor/samples/{plugins → old}/magicline/magicline.html +11 -8
  308. data/app/assets/javascripts/ckeditor/samples/{readonly.html → old/readonly.html} +13 -10
  309. data/app/assets/javascripts/ckeditor/samples/{replacebyclass.html → old/replacebyclass.html} +10 -7
  310. data/app/assets/javascripts/ckeditor/samples/{replacebycode.html → old/replacebycode.html} +10 -7
  311. data/app/assets/javascripts/ckeditor/samples/{sample.css → old/sample.css} +6 -14
  312. data/app/assets/javascripts/ckeditor/samples/{sample.js → old/sample.js} +2 -2
  313. data/app/assets/javascripts/ckeditor/samples/{sample_posteddata.php → old/sample_posteddata.php} +2 -2
  314. data/app/assets/javascripts/ckeditor/samples/{tabindex.html → old/tabindex.html} +10 -7
  315. data/app/assets/javascripts/ckeditor/samples/{plugins → old}/toolbar/toolbar.html +15 -12
  316. data/app/assets/javascripts/ckeditor/samples/{uicolor.html → old/uicolor.html} +11 -8
  317. data/app/assets/javascripts/ckeditor/samples/{uilanguages.html → old/uilanguages.html} +13 -10
  318. data/app/assets/javascripts/ckeditor/samples/old/wysiwygarea/fullpage.html +80 -0
  319. data/app/assets/javascripts/ckeditor/samples/{xhtmlstyle.html → old/xhtmlstyle.html} +12 -9
  320. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/css/fontello.css +55 -0
  321. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/LICENSE.txt +10 -0
  322. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/config.json +28 -0
  323. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/fontello.eot +0 -0
  324. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/fontello.svg +14 -0
  325. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/fontello.ttf +0 -0
  326. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/fontello.woff +0 -0
  327. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/index.html +447 -0
  328. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/js/abstracttoolbarmodifier.js +13 -0
  329. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/js/fulltoolbareditor.js +9 -0
  330. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/js/toolbarmodifier.js +33 -0
  331. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/js/toolbartextmodifier.js +14 -0
  332. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/LICENSE +19 -0
  333. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/codemirror.css +325 -0
  334. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/codemirror.js +288 -0
  335. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/javascript.js +25 -0
  336. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/neo.css +36 -0
  337. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/show-hint.css +38 -0
  338. data/app/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/show-hint.js +16 -0
  339. data/app/assets/javascripts/ckeditor/skins/moono-lisa/dialog.css +5 -0
  340. data/app/assets/javascripts/ckeditor/skins/moono-lisa/dialog_ie.css +5 -0
  341. data/app/assets/javascripts/ckeditor/skins/moono-lisa/dialog_ie8.css +5 -0
  342. data/app/assets/javascripts/ckeditor/skins/moono-lisa/dialog_iequirks.css +5 -0
  343. data/app/assets/javascripts/ckeditor/skins/moono-lisa/editor.css +5 -0
  344. data/app/assets/javascripts/ckeditor/skins/moono-lisa/editor_gecko.css +5 -0
  345. data/app/assets/javascripts/ckeditor/skins/moono-lisa/editor_ie.css +5 -0
  346. data/app/assets/javascripts/ckeditor/skins/moono-lisa/editor_ie8.css +5 -0
  347. data/app/assets/javascripts/ckeditor/skins/moono-lisa/editor_iequirks.css +5 -0
  348. data/app/assets/javascripts/ckeditor/skins/moono-lisa/icons.png +0 -0
  349. data/app/assets/javascripts/ckeditor/skins/moono-lisa/icons_hidpi.png +0 -0
  350. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/arrow.png +0 -0
  351. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/close.png +0 -0
  352. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/hidpi/close.png +0 -0
  353. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/hidpi/lock-open.png +0 -0
  354. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/hidpi/lock.png +0 -0
  355. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/hidpi/refresh.png +0 -0
  356. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/lock-open.png +0 -0
  357. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/lock.png +0 -0
  358. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/refresh.png +0 -0
  359. data/app/assets/javascripts/ckeditor/skins/moono-lisa/images/spinner.gif +0 -0
  360. data/app/assets/javascripts/ckeditor/skins/{moono → moono-lisa}/readme.md +11 -16
  361. data/app/assets/javascripts/ckeditor/styles.js +43 -17
  362. data/app/assets/javascripts/ckeditor/vendor/promise.js +13 -0
  363. data/app/assets/javascripts/drg_default_html_editor_cms.js +1 -4
  364. data/app/assets/stylesheets/drg_default_html_editor_cms.css +3 -3
  365. data/app/{controllers/dc_elfinder_controller.rb → models/drgcms_form_fields/ckeditor.rb} +33 -32
  366. data/lib/drg_default_html_editor/version.rb +1 -1
  367. data/lib/drg_default_html_editor.rb +2 -3
  368. data/lib/tasks/drg_default_html_editor_tasks.rake +16 -4
  369. metadata +169 -249
  370. data/app/assets/javascripts/ckeditor/plugins/flash/dialogs/flash.js +0 -24
  371. data/app/assets/javascripts/ckeditor/plugins/flash/images/placeholder.png +0 -0
  372. data/app/assets/javascripts/ckeditor/plugins/forms/dialogs/button.js +0 -8
  373. data/app/assets/javascripts/ckeditor/plugins/forms/dialogs/checkbox.js +0 -8
  374. data/app/assets/javascripts/ckeditor/plugins/forms/dialogs/form.js +0 -8
  375. data/app/assets/javascripts/ckeditor/plugins/forms/dialogs/hiddenfield.js +0 -8
  376. data/app/assets/javascripts/ckeditor/plugins/forms/dialogs/radio.js +0 -8
  377. data/app/assets/javascripts/ckeditor/plugins/forms/dialogs/select.js +0 -20
  378. data/app/assets/javascripts/ckeditor/plugins/forms/dialogs/textarea.js +0 -8
  379. data/app/assets/javascripts/ckeditor/plugins/forms/dialogs/textfield.js +0 -10
  380. data/app/assets/javascripts/ckeditor/plugins/forms/images/hiddenfield.gif +0 -0
  381. data/app/assets/javascripts/ckeditor/plugins/iframe/dialogs/iframe.js +0 -10
  382. data/app/assets/javascripts/ckeditor/plugins/iframe/images/placeholder.png +0 -0
  383. data/app/assets/javascripts/ckeditor/plugins/smiley/dialogs/smiley.js +0 -10
  384. data/app/assets/javascripts/ckeditor/plugins/smiley/images/angel_smile.gif +0 -0
  385. data/app/assets/javascripts/ckeditor/plugins/smiley/images/angel_smile.png +0 -0
  386. data/app/assets/javascripts/ckeditor/plugins/smiley/images/angry_smile.gif +0 -0
  387. data/app/assets/javascripts/ckeditor/plugins/smiley/images/angry_smile.png +0 -0
  388. data/app/assets/javascripts/ckeditor/plugins/smiley/images/broken_heart.gif +0 -0
  389. data/app/assets/javascripts/ckeditor/plugins/smiley/images/broken_heart.png +0 -0
  390. data/app/assets/javascripts/ckeditor/plugins/smiley/images/confused_smile.gif +0 -0
  391. data/app/assets/javascripts/ckeditor/plugins/smiley/images/confused_smile.png +0 -0
  392. data/app/assets/javascripts/ckeditor/plugins/smiley/images/cry_smile.gif +0 -0
  393. data/app/assets/javascripts/ckeditor/plugins/smiley/images/cry_smile.png +0 -0
  394. data/app/assets/javascripts/ckeditor/plugins/smiley/images/devil_smile.gif +0 -0
  395. data/app/assets/javascripts/ckeditor/plugins/smiley/images/devil_smile.png +0 -0
  396. data/app/assets/javascripts/ckeditor/plugins/smiley/images/embaressed_smile.gif +0 -0
  397. data/app/assets/javascripts/ckeditor/plugins/smiley/images/embarrassed_smile.gif +0 -0
  398. data/app/assets/javascripts/ckeditor/plugins/smiley/images/embarrassed_smile.png +0 -0
  399. data/app/assets/javascripts/ckeditor/plugins/smiley/images/envelope.gif +0 -0
  400. data/app/assets/javascripts/ckeditor/plugins/smiley/images/envelope.png +0 -0
  401. data/app/assets/javascripts/ckeditor/plugins/smiley/images/heart.gif +0 -0
  402. data/app/assets/javascripts/ckeditor/plugins/smiley/images/heart.png +0 -0
  403. data/app/assets/javascripts/ckeditor/plugins/smiley/images/kiss.gif +0 -0
  404. data/app/assets/javascripts/ckeditor/plugins/smiley/images/kiss.png +0 -0
  405. data/app/assets/javascripts/ckeditor/plugins/smiley/images/lightbulb.gif +0 -0
  406. data/app/assets/javascripts/ckeditor/plugins/smiley/images/lightbulb.png +0 -0
  407. data/app/assets/javascripts/ckeditor/plugins/smiley/images/omg_smile.gif +0 -0
  408. data/app/assets/javascripts/ckeditor/plugins/smiley/images/omg_smile.png +0 -0
  409. data/app/assets/javascripts/ckeditor/plugins/smiley/images/regular_smile.gif +0 -0
  410. data/app/assets/javascripts/ckeditor/plugins/smiley/images/regular_smile.png +0 -0
  411. data/app/assets/javascripts/ckeditor/plugins/smiley/images/sad_smile.gif +0 -0
  412. data/app/assets/javascripts/ckeditor/plugins/smiley/images/sad_smile.png +0 -0
  413. data/app/assets/javascripts/ckeditor/plugins/smiley/images/shades_smile.gif +0 -0
  414. data/app/assets/javascripts/ckeditor/plugins/smiley/images/shades_smile.png +0 -0
  415. data/app/assets/javascripts/ckeditor/plugins/smiley/images/teeth_smile.gif +0 -0
  416. data/app/assets/javascripts/ckeditor/plugins/smiley/images/teeth_smile.png +0 -0
  417. data/app/assets/javascripts/ckeditor/plugins/smiley/images/thumbs_down.gif +0 -0
  418. data/app/assets/javascripts/ckeditor/plugins/smiley/images/thumbs_down.png +0 -0
  419. data/app/assets/javascripts/ckeditor/plugins/smiley/images/thumbs_up.gif +0 -0
  420. data/app/assets/javascripts/ckeditor/plugins/smiley/images/thumbs_up.png +0 -0
  421. data/app/assets/javascripts/ckeditor/plugins/smiley/images/tongue_smile.gif +0 -0
  422. data/app/assets/javascripts/ckeditor/plugins/smiley/images/tongue_smile.png +0 -0
  423. data/app/assets/javascripts/ckeditor/plugins/smiley/images/tounge_smile.gif +0 -0
  424. data/app/assets/javascripts/ckeditor/plugins/smiley/images/whatchutalkingabout_smile.gif +0 -0
  425. data/app/assets/javascripts/ckeditor/plugins/smiley/images/whatchutalkingabout_smile.png +0 -0
  426. data/app/assets/javascripts/ckeditor/plugins/smiley/images/wink_smile.gif +0 -0
  427. data/app/assets/javascripts/ckeditor/plugins/smiley/images/wink_smile.png +0 -0
  428. data/app/assets/javascripts/ckeditor/plugins/wsc/LICENSE.md +0 -28
  429. data/app/assets/javascripts/ckeditor/plugins/wsc/README.md +0 -25
  430. data/app/assets/javascripts/ckeditor/plugins/wsc/dialogs/ciframe.html +0 -66
  431. data/app/assets/javascripts/ckeditor/plugins/wsc/dialogs/tmpFrameset.html +0 -52
  432. data/app/assets/javascripts/ckeditor/plugins/wsc/dialogs/wsc.css +0 -82
  433. data/app/assets/javascripts/ckeditor/plugins/wsc/dialogs/wsc.js +0 -74
  434. data/app/assets/javascripts/ckeditor/plugins/wsc/dialogs/wsc_ie.js +0 -11
  435. data/app/assets/javascripts/ckeditor/samples/assets/inlineall/logo.png +0 -0
  436. data/app/assets/javascripts/ckeditor/samples/assets/sample.jpg +0 -0
  437. data/app/assets/javascripts/ckeditor/samples/assets/uilanguages/languages.js +0 -7
  438. data/app/assets/javascripts/ckeditor/samples/plugins/htmlwriter/assets/outputforflash/outputforflash.fla +0 -0
  439. data/app/assets/javascripts/ckeditor/samples/plugins/htmlwriter/assets/outputforflash/outputforflash.swf +0 -0
  440. data/app/assets/javascripts/ckeditor/samples/plugins/htmlwriter/assets/outputforflash/swfobject.js +0 -18
  441. data/app/assets/javascripts/ckeditor/samples/plugins/htmlwriter/outputforflash.html +0 -280
  442. data/app/assets/javascripts/ckeditor/samples/plugins/wysiwygarea/fullpage.html +0 -77
  443. data/app/assets/javascripts/ckeditor/skins/moono/dialog.css +0 -5
  444. data/app/assets/javascripts/ckeditor/skins/moono/dialog_ie.css +0 -5
  445. data/app/assets/javascripts/ckeditor/skins/moono/dialog_ie7.css +0 -5
  446. data/app/assets/javascripts/ckeditor/skins/moono/dialog_ie8.css +0 -5
  447. data/app/assets/javascripts/ckeditor/skins/moono/dialog_iequirks.css +0 -5
  448. data/app/assets/javascripts/ckeditor/skins/moono/editor.css +0 -5
  449. data/app/assets/javascripts/ckeditor/skins/moono/editor_gecko.css +0 -5
  450. data/app/assets/javascripts/ckeditor/skins/moono/editor_ie.css +0 -5
  451. data/app/assets/javascripts/ckeditor/skins/moono/editor_ie7.css +0 -5
  452. data/app/assets/javascripts/ckeditor/skins/moono/editor_ie8.css +0 -5
  453. data/app/assets/javascripts/ckeditor/skins/moono/editor_iequirks.css +0 -5
  454. data/app/assets/javascripts/ckeditor/skins/moono/icons.png +0 -0
  455. data/app/assets/javascripts/ckeditor/skins/moono/icons_hidpi.png +0 -0
  456. data/app/assets/javascripts/ckeditor/skins/moono/images/arrow.png +0 -0
  457. data/app/assets/javascripts/ckeditor/skins/moono/images/close.png +0 -0
  458. data/app/assets/javascripts/ckeditor/skins/moono/images/hidpi/close.png +0 -0
  459. data/app/assets/javascripts/ckeditor/skins/moono/images/hidpi/lock-open.png +0 -0
  460. data/app/assets/javascripts/ckeditor/skins/moono/images/hidpi/lock.png +0 -0
  461. data/app/assets/javascripts/ckeditor/skins/moono/images/hidpi/refresh.png +0 -0
  462. data/app/assets/javascripts/ckeditor/skins/moono/images/lock-open.png +0 -0
  463. data/app/assets/javascripts/ckeditor/skins/moono/images/lock.png +0 -0
  464. data/app/assets/javascripts/ckeditor/skins/moono/images/refresh.png +0 -0
  465. data/app/assets/javascripts/elfinder/Changelog +0 -494
  466. data/app/assets/javascripts/elfinder/LICENSE.md +0 -15
  467. data/app/assets/javascripts/elfinder/README.md +0 -209
  468. data/app/assets/javascripts/elfinder/bower.json +0 -28
  469. data/app/assets/javascripts/elfinder/composer.json +0 -39
  470. data/app/assets/javascripts/elfinder/css/elfinder.full.css +0 -3034
  471. data/app/assets/javascripts/elfinder/css/elfinder.min.css +0 -9
  472. data/app/assets/javascripts/elfinder/css/theme.css +0 -68
  473. data/app/assets/javascripts/elfinder/elfinder.html +0 -61
  474. data/app/assets/javascripts/elfinder/img/arrows-active.png +0 -0
  475. data/app/assets/javascripts/elfinder/img/arrows-normal.png +0 -0
  476. data/app/assets/javascripts/elfinder/img/crop.gif +0 -0
  477. data/app/assets/javascripts/elfinder/img/dialogs.png +0 -0
  478. data/app/assets/javascripts/elfinder/img/icons-big.png +0 -0
  479. data/app/assets/javascripts/elfinder/img/icons-small.png +0 -0
  480. data/app/assets/javascripts/elfinder/img/logo.png +0 -0
  481. data/app/assets/javascripts/elfinder/img/progress.gif +0 -0
  482. data/app/assets/javascripts/elfinder/img/quicklook-bg.png +0 -0
  483. data/app/assets/javascripts/elfinder/img/quicklook-icons.png +0 -0
  484. data/app/assets/javascripts/elfinder/img/resize.png +0 -0
  485. data/app/assets/javascripts/elfinder/img/spinner-mini.gif +0 -0
  486. data/app/assets/javascripts/elfinder/img/toolbar.png +0 -0
  487. data/app/assets/javascripts/elfinder/img/volume_icon_box.png +0 -0
  488. data/app/assets/javascripts/elfinder/img/volume_icon_dropbox.png +0 -0
  489. data/app/assets/javascripts/elfinder/img/volume_icon_ftp.png +0 -0
  490. data/app/assets/javascripts/elfinder/img/volume_icon_googledrive.png +0 -0
  491. data/app/assets/javascripts/elfinder/img/volume_icon_local.png +0 -0
  492. data/app/assets/javascripts/elfinder/img/volume_icon_onedrive.png +0 -0
  493. data/app/assets/javascripts/elfinder/img/volume_icon_sql.png +0 -0
  494. data/app/assets/javascripts/elfinder/js/elfinder.full.js +0 -23025
  495. data/app/assets/javascripts/elfinder/js/elfinder.min.js +0 -20
  496. data/app/assets/javascripts/elfinder/js/extras/encoding-japanese.min.js +0 -35
  497. data/app/assets/javascripts/elfinder/js/extras/quicklook.googledocs.js +0 -69
  498. data/app/assets/javascripts/elfinder/js/i18n/elfinder.LANG.js +0 -479
  499. data/app/assets/javascripts/elfinder/js/i18n/elfinder.ar.js +0 -375
  500. data/app/assets/javascripts/elfinder/js/i18n/elfinder.bg.js +0 -412
  501. data/app/assets/javascripts/elfinder/js/i18n/elfinder.ca.js +0 -375
  502. data/app/assets/javascripts/elfinder/js/i18n/elfinder.cs.js +0 -469
  503. data/app/assets/javascripts/elfinder/js/i18n/elfinder.da.js +0 -374
  504. data/app/assets/javascripts/elfinder/js/i18n/elfinder.de.js +0 -457
  505. data/app/assets/javascripts/elfinder/js/i18n/elfinder.el.js +0 -374
  506. data/app/assets/javascripts/elfinder/js/i18n/elfinder.es.js +0 -433
  507. data/app/assets/javascripts/elfinder/js/i18n/elfinder.fa.js +0 -374
  508. data/app/assets/javascripts/elfinder/js/i18n/elfinder.fallback.js +0 -11
  509. data/app/assets/javascripts/elfinder/js/i18n/elfinder.fo.js +0 -419
  510. data/app/assets/javascripts/elfinder/js/i18n/elfinder.fr.js +0 -419
  511. data/app/assets/javascripts/elfinder/js/i18n/elfinder.he.js +0 -375
  512. data/app/assets/javascripts/elfinder/js/i18n/elfinder.hr.js +0 -434
  513. data/app/assets/javascripts/elfinder/js/i18n/elfinder.hu.js +0 -447
  514. data/app/assets/javascripts/elfinder/js/i18n/elfinder.id.js +0 -373
  515. data/app/assets/javascripts/elfinder/js/i18n/elfinder.it.js +0 -448
  516. data/app/assets/javascripts/elfinder/js/i18n/elfinder.jp.js +0 -474
  517. data/app/assets/javascripts/elfinder/js/i18n/elfinder.ko.js +0 -374
  518. data/app/assets/javascripts/elfinder/js/i18n/elfinder.nl.js +0 -419
  519. data/app/assets/javascripts/elfinder/js/i18n/elfinder.no.js +0 -374
  520. data/app/assets/javascripts/elfinder/js/i18n/elfinder.pl.js +0 -455
  521. data/app/assets/javascripts/elfinder/js/i18n/elfinder.pt_BR.js +0 -438
  522. data/app/assets/javascripts/elfinder/js/i18n/elfinder.ro.js +0 -417
  523. data/app/assets/javascripts/elfinder/js/i18n/elfinder.ru.js +0 -440
  524. data/app/assets/javascripts/elfinder/js/i18n/elfinder.sk.js +0 -469
  525. data/app/assets/javascripts/elfinder/js/i18n/elfinder.sl.js +0 -374
  526. data/app/assets/javascripts/elfinder/js/i18n/elfinder.sr.js +0 -374
  527. data/app/assets/javascripts/elfinder/js/i18n/elfinder.sv.js +0 -375
  528. data/app/assets/javascripts/elfinder/js/i18n/elfinder.tr.js +0 -468
  529. data/app/assets/javascripts/elfinder/js/i18n/elfinder.ug_CN.js +0 -374
  530. data/app/assets/javascripts/elfinder/js/i18n/elfinder.uk.js +0 -391
  531. data/app/assets/javascripts/elfinder/js/i18n/elfinder.vi.js +0 -374
  532. data/app/assets/javascripts/elfinder/js/i18n/elfinder.zh_CN.js +0 -467
  533. data/app/assets/javascripts/elfinder/js/i18n/elfinder.zh_TW.js +0 -472
  534. data/app/assets/javascripts/elfinder/js/proxy/elFinderSupportVer1.js +0 -420
  535. data/app/assets/javascripts/elfinder/main.default.js +0 -94
  536. data/app/assets/javascripts/elfinder/package.json +0 -13
  537. data/app/assets/javascripts/elfinder/sounds/rm.wav +0 -0
  538. data/config/initializers/load_patches.rb +0 -30
  539. data/config/routes.rb +0 -2
  540. data/lib/drg_default_html_editor.rb~ +0 -6
  541. data/lib/patches/drgcms_form_field.rb +0 -121
  542. data/lib/patches/patch_for_elfinder.rb +0 -115
  543. data/lib/tasks/drg_default_html_editor_copy_assets.rake +0 -18
@@ -0,0 +1,447 @@
1
+ <!DOCTYPE html>
2
+ <!--
3
+ Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved.
4
+ For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
5
+ -->
6
+ <!--[if IE 8]><html class="ie8"><![endif]-->
7
+ <!--[if gt IE 8]><html><![endif]-->
8
+ <!--[if !IE]><!--><html lang="en"><!--<![endif]-->
9
+ <head>
10
+ <meta charset="utf-8">
11
+ <title>Toolbar Configurator</title>
12
+ <script src="../../ckeditor.js"></script>
13
+ <script>
14
+ if ( CKEDITOR.env.ie && CKEDITOR.env.version < 9 )
15
+ CKEDITOR.tools.enableHtml5Elements( document );
16
+ </script>
17
+ <link rel="stylesheet" href="lib/codemirror/codemirror.css">
18
+ <link rel="stylesheet" href="lib/codemirror/show-hint.css">
19
+ <link rel="stylesheet" href="lib/codemirror/neo.css">
20
+ <link rel="stylesheet" href="css/fontello.css">
21
+ <link rel="stylesheet" href="../css/samples.css">
22
+ <meta name="description" content="Try the latest sample of CKEditor 4 and learn more about customizing your WYSIWYG editor with endless possibilities.">
23
+ </head>
24
+ <body id="toolbar">
25
+
26
+ <nav class="navigation-a">
27
+ <div class="grid-container">
28
+ <ul class="navigation-a-left grid-width-70">
29
+ <li><a href="https://ckeditor.com/ckeditor-4/">Project Homepage</a></li>
30
+ <li><a href="https://github.com/ckeditor/ckeditor4/issues">I found a bug</a></li>
31
+ <li><a href="https://github.com/ckeditor/ckeditor4" class="icon-pos-right icon-navigation-a-github">Fork CKEditor on GitHub</a></li>
32
+ </ul>
33
+ <ul class="navigation-a-right grid-width-30">
34
+ <li><a href="https://ckeditor.com/blog/">CKEditor Blog</a></li>
35
+ </ul>
36
+ </div>
37
+ </nav>
38
+
39
+ <header class="header-a">
40
+ <div class="grid-container">
41
+ <h1 class="header-a-logo grid-width-30">
42
+ <a href="../index.html"><img src="../img/logo.svg" onerror="this.src='../img/logo.png'; this.onerror=null;" alt="CKEditor Logo"></a>
43
+ </h1>
44
+ <nav class="navigation-b grid-width-70">
45
+ <ul>
46
+ <li><a href="../index.html" class="button-a">Start</a></li>
47
+ <li><a href="index.html" class="button-a button-a-background">Toolbar configurator</a></li>
48
+ </ul>
49
+ </nav>
50
+ </div>
51
+ </header>
52
+
53
+ <main>
54
+ <div class="adjoined-top">
55
+ <div class="grid-container">
56
+ <div class="content grid-width-100">
57
+ <div class="grid-container-nested">
58
+ <h1 class="grid-width-60">
59
+ Toolbar Configurator
60
+ <a href="#help-content" type="button" title="Configurator help" id="help" class="button-a button-a-background button-a-no-text icon-pos-left icon-question-mark">Help</a>
61
+ </h1>
62
+
63
+ <div class="grid-width-40 grid-switch-magic">
64
+ <div class="switch">
65
+ <span class="balloon-a balloon-a-se">Select configurator type</span>
66
+ <input type="radio" name="radio" data-num="1" id="radio-basic" />
67
+ <input type="radio" name="radio" data-num="2" id="radio-advanced" />
68
+ <label data-for="1" for="radio-basic">Basic</label>
69
+ <span class="switch-inner">
70
+ <span class="handler"></span>
71
+ </span>
72
+ <label data-for="2" for="radio-advanced">Advanced</label>
73
+ </div>
74
+ </div>
75
+ </div>
76
+ </div>
77
+ </div>
78
+ </div>
79
+ <div class="adjoined-bottom">
80
+ <div class="grid-container">
81
+ <div class="grid-width-100">
82
+ <div class="editors-container">
83
+ <div id="editor-basic"></div>
84
+ <div id="editor-advanced"></div>
85
+ </div>
86
+ </div>
87
+ </div>
88
+ </div>
89
+
90
+ <div class="grid-container configurator">
91
+ <div class="content grid-width-100">
92
+ <div class="configurator">
93
+ <div>
94
+ <div id="toolbarModifierWrapper"></div>
95
+ </div>
96
+ </div>
97
+ </div>
98
+ </div>
99
+
100
+ <div id="help-content">
101
+ <div class="grid-container">
102
+ <div class="grid-width-100">
103
+ <h2>What Am I Doing Here?</h2>
104
+
105
+ <div class="grid-container grid-container-nested">
106
+ <div class="basic">
107
+ <div class="grid-width-50">
108
+ <p>Arrange <a href="https://ckeditor.com/docs/ckeditor4/latest/api/CKEDITOR_config.html#cfg-toolbarGroups">toolbar groups</a>, toggle <a href="https://ckeditor.com/docs/ckeditor4/latest/api/CKEDITOR_config.html#cfg-removeButtons">button visibility</a> according to your needs and get your toolbar configuration.</p>
109
+ <p>You can replace the content of the <a href="../../config.js"><code>config.js</code></a> file with the generated configuration. If you already set some configuration options you will need to merge both configurations.</p>
110
+ </div>
111
+ <div class="grid-width-50">
112
+ <p>Read more about different ways of <a href="https://ckeditor.com/docs/ckeditor4/latest/guide/dev_configuration.html">setting configuration</a> and do not forget about <strong>clearing browser cache</strong>.</p>
113
+ <p>Arranging toolbar groups is the recommended way of configuring the toolbar, but if you need more freedom you can use the <a href="#advanced">advanced configurator</a>.</p>
114
+ </div>
115
+ </div>
116
+ <div class="advanced" style="display: none;">
117
+ <div class="grid-width-50">
118
+ <p>With this code editor you can edit your <a href="https://ckeditor.com/docs/ckeditor4/latest/api/CKEDITOR_config.html#cfg-toolbar">toolbar configuration</a> live.</p>
119
+ <p>You can replace the content of the <a href="../../config.js"><code>config.js</code></a> file with the generated configuration. If you already set some configuration options you will need to merge both configurations.</p>
120
+ </div>
121
+ <div class="grid-width-50">
122
+ <p>Read more about different ways of <a href="https://ckeditor.com/docs/ckeditor4/latest/guide/dev_configuration.html">setting configuration</a> and do not forget about <strong>clearing browser cache</strong>.</p>
123
+ </div>
124
+ </div>
125
+ </div>
126
+
127
+ <p class="grid-container grid-container-nested">
128
+ <button type="button" class="help-content-close grid-width-100 button-a button-a-background">Got it. Let's play!</button>
129
+ </p>
130
+ </div>
131
+ </div>
132
+ </div>
133
+ </main>
134
+
135
+ <footer class="footer-a grid-container">
136
+ <p class="grid-width-100">
137
+ CKEditor &ndash; The text editor for the Internet &ndash; <a class="samples" href="https://ckeditor.com/">https://ckeditor.com</a>
138
+ </p>
139
+ <p class="grid-width-100" id="copy">
140
+ Copyright &copy; 2003-2022, <a class="samples" href="https://cksource.com/">CKSource</a> Holding sp. z o.o. All rights reserved.
141
+ </p>
142
+ </footer>
143
+
144
+ <script src="lib/codemirror/codemirror.js"></script>
145
+ <script src="lib/codemirror/javascript.js"></script>
146
+ <script src="lib/codemirror/show-hint.js"></script>
147
+
148
+ <script src="js/fulltoolbareditor.js"></script>
149
+ <script src="js/abstracttoolbarmodifier.js"></script>
150
+ <script src="js/toolbarmodifier.js"></script>
151
+ <script src="js/toolbartextmodifier.js"></script>
152
+ <script src="../js/sf.js"></script>
153
+
154
+ <script>
155
+ ( function() {
156
+ 'use strict';
157
+
158
+ var mode = ( window.location.hash.substr( 1 ) === 'advanced' ) ? 'advanced' : 'basic',
159
+ configuratorSection = CKEDITOR.document.findOne( 'main > .grid-container.configurator' ),
160
+ basicInstruction = CKEDITOR.document.findOne( '#help-content .basic' ),
161
+ advancedInstruction = CKEDITOR.document.findOne( '#help-content .advanced' ),
162
+
163
+ // Configurator mode switcher.
164
+ modeSwitchBasic = CKEDITOR.document.getById( 'radio-basic' ),
165
+ modeSwitchAdvanced = CKEDITOR.document.getById( 'radio-advanced' );
166
+
167
+ // Initial setup
168
+ function updateSwitcher() {
169
+ if ( mode === 'advanced' ) {
170
+ modeSwitchAdvanced.$.checked = true;
171
+ } else {
172
+ modeSwitchBasic.$.checked = true;
173
+ }
174
+ }
175
+
176
+ updateSwitcher();
177
+
178
+ CKEDITOR.document.getWindow().on( 'hashchange', function( e ) {
179
+ var hash = window.location.hash.substr( 1 );
180
+ if ( !( hash === 'advanced' || hash === 'basic' ) ) {
181
+ return;
182
+ }
183
+ mode = hash;
184
+ onToolbarsDone( mode );
185
+ } );
186
+
187
+ CKEDITOR.document.getWindow().on( 'resize', function() {
188
+ updateToolbar( ( mode === 'basic' ? toolbarModifier : toolbarTextModifier )[ 'editorInstance' ] );
189
+ } );
190
+
191
+ function onRefresh( modifier ) {
192
+ modifier = modifier || this;
193
+
194
+ if ( mode === 'basic' && modifier instanceof ToolbarConfigurator.ToolbarTextModifier ) {
195
+ return;
196
+ }
197
+
198
+ // CodeMirror container becomes visible, so we need to refresh and to avoid rendering problems.
199
+ if ( mode === 'advanced' && modifier instanceof ToolbarConfigurator.ToolbarTextModifier ) {
200
+ modifier.codeContainer.refresh();
201
+ }
202
+
203
+ updateToolbar( modifier.editorInstance );
204
+ }
205
+
206
+ function updateToolbar( editor ) {
207
+ var editorContainer = editor.container;
208
+
209
+ // Not always editor is loaded.
210
+ if ( !editorContainer ) {
211
+ return;
212
+ }
213
+
214
+ var displayStyle = editorContainer.getStyle( 'display' );
215
+
216
+ editorContainer.setStyle( 'display', 'block' );
217
+
218
+ var newHeight = editorContainer.getSize( 'height' );
219
+
220
+ var newMarginTop = parseInt( editorContainer.getComputedStyle( 'margin-top' ), 10 );
221
+ newMarginTop = ( isNaN( newMarginTop ) ? 0 : Number( newMarginTop ) );
222
+
223
+ var newMarginBottom = parseInt( editorContainer.getComputedStyle( 'margin-bottom' ), 10 );
224
+ newMarginBottom = ( isNaN( newMarginBottom ) ? 0 : Number( newMarginBottom ) );
225
+
226
+ var result = newHeight + newMarginTop + newMarginBottom;
227
+
228
+ editorContainer.setStyle( 'display', displayStyle );
229
+
230
+ editor.container.getAscendant( 'div' ).setStyle( 'height', result + 'px' );
231
+ }
232
+
233
+ var toolbarModifier = new ToolbarConfigurator.ToolbarModifier( 'editor-basic' );
234
+
235
+ var done = 0;
236
+ toolbarModifier.init( onToolbarInit );
237
+ toolbarModifier.onRefresh = onRefresh;
238
+
239
+ CKEDITOR.document.getById( 'toolbarModifierWrapper' ).append( toolbarModifier.mainContainer );
240
+
241
+ var toolbarTextModifier = new ToolbarConfigurator.ToolbarTextModifier( 'editor-advanced' );
242
+ toolbarTextModifier.init( onToolbarInit );
243
+ toolbarTextModifier.onRefresh = onRefresh;
244
+
245
+ function onToolbarInit() {
246
+ if ( ++done === 2 ) {
247
+ onToolbarsDone();
248
+
249
+ positionSticky.watch( CKEDITOR.document.findOne( '.toolbar' ), function() {
250
+ return mode === 'advanced';
251
+ } );
252
+ }
253
+ }
254
+
255
+ function onToolbarsDone() {
256
+ if ( mode === 'basic' ) {
257
+ toggleModeBasic( false );
258
+ } else {
259
+ toggleModeAdvanced( false );
260
+ }
261
+
262
+ updateSwitcher();
263
+
264
+ setTimeout( function() {
265
+ CKEDITOR.document.findOne( '.editors-container' ).addClass( 'active' );
266
+ CKEDITOR.document.findOne( '#toolbarModifierWrapper' ).addClass( 'active' );
267
+ }, 200 );
268
+ }
269
+
270
+ CKEDITOR.document.getById( 'toolbarModifierWrapper' ).append( toolbarTextModifier.mainContainer );
271
+
272
+ function toogleModeSwitch( onElement, offElement, onModifier, offModifier ) {
273
+ onElement.addClass( 'fancy-button-active' );
274
+ offElement.removeClass( 'fancy-button-active' );
275
+
276
+ onModifier.showUI();
277
+ offModifier.hideUI();
278
+ }
279
+
280
+ function toggleModeBasic( callOnRefresh ) {
281
+ callOnRefresh = ( callOnRefresh !== false );
282
+ mode = 'basic';
283
+ window.location.hash = '#basic';
284
+ toogleModeSwitch( modeSwitchBasic, modeSwitchAdvanced, toolbarModifier, toolbarTextModifier );
285
+
286
+ configuratorSection.removeClass( 'freed-width' );
287
+ basicInstruction.show();
288
+ advancedInstruction.hide();
289
+
290
+ callOnRefresh && onRefresh( toolbarModifier );
291
+ }
292
+
293
+ function toggleModeAdvanced( callOnRefresh ) {
294
+ callOnRefresh = ( callOnRefresh !== false );
295
+ mode = 'advanced';
296
+ window.location.hash = '#advanced';
297
+ toogleModeSwitch( modeSwitchAdvanced, modeSwitchBasic, toolbarTextModifier, toolbarModifier );
298
+
299
+ configuratorSection.addClass( 'freed-width' );
300
+ advancedInstruction.show();
301
+ basicInstruction.hide();
302
+
303
+ callOnRefresh && onRefresh( toolbarTextModifier );
304
+ }
305
+
306
+ modeSwitchBasic.on( 'click', toggleModeBasic );
307
+ modeSwitchAdvanced.on( 'click', toggleModeAdvanced );
308
+
309
+ //
310
+ // Position:sticky for the toolbar.
311
+ //
312
+
313
+ // Will make elements behave like they were styled with position:sticky.
314
+ var positionSticky = {
315
+ // Store object: {
316
+ // element: CKEDITOR.dom.element, // Element which will float.
317
+ // placeholder: CKEDITOR.dom.element, // Placeholder which is place to prevent page bounce.
318
+ // isFixed: boolean // Whether element float now.
319
+ // }
320
+ watched: [],
321
+
322
+ active: [],
323
+
324
+ staticContainer: null,
325
+
326
+ init: function() {
327
+ var element = CKEDITOR.dom.element.createFromHtml(
328
+ '<div class="staticContainer">' +
329
+ '<div class="grid-container" >' +
330
+ '<div class="grid-width-100">' +
331
+ '<div class="inner"></div>' +
332
+ '</div>' +
333
+ '</div>' +
334
+ '</div>' );
335
+
336
+ this.staticContainer = element.findOne( '.inner' );
337
+
338
+ CKEDITOR.document.getBody().append( element );
339
+ },
340
+
341
+ watch: function( element, preventFunc ) {
342
+ this.watched.push( {
343
+ element: element,
344
+ placeholder: new CKEDITOR.dom.element( 'div' ),
345
+ isFixed: false,
346
+ preventFunc: preventFunc
347
+ } );
348
+ },
349
+
350
+ checkAll: function() {
351
+ for ( var i = 0; i < this.watched.length; i++ ) {
352
+ this.check( this.watched[ i ] );
353
+ }
354
+ },
355
+
356
+ check: function( element ) {
357
+ var isFixed = element.isFixed;
358
+ var shouldBeFixed = this.shouldBeFixed( element );
359
+
360
+ // Nothing to be done.
361
+ if ( isFixed === shouldBeFixed ) {
362
+ return;
363
+ }
364
+
365
+ var placeholder = element.placeholder;
366
+
367
+ if ( isFixed ) {
368
+ // Unfixing.
369
+
370
+ element.element.insertBefore( placeholder );
371
+ placeholder.remove();
372
+
373
+ element.element.removeStyle( 'margin' );
374
+
375
+ this.active.splice( CKEDITOR.tools.indexOf( this.active, element ), 1 );
376
+
377
+ } else {
378
+ // Fixing.
379
+ placeholder.setStyle( 'width', element.element.getSize( 'width' ) + 'px' );
380
+ placeholder.setStyle( 'height', element.element.getSize( 'height' ) + 'px' );
381
+ placeholder.setStyle( 'margin-bottom', element.element.getComputedStyle( 'margin-bottom' ) );
382
+ placeholder.setStyle( 'display', element.element.getComputedStyle( 'display' ) );
383
+ placeholder.insertAfter( element.element );
384
+
385
+ this.staticContainer.append( element.element );
386
+
387
+ this.active.push( element );
388
+ }
389
+
390
+ element.isFixed = !element.isFixed;
391
+ },
392
+
393
+ shouldBeFixed: function( element ) {
394
+ if ( element.preventFunc && element.preventFunc() ) {
395
+ return false;
396
+ }
397
+
398
+ // If element is already fixed we are checking it's placeholder.
399
+ var related = ( element.isFixed ? element.placeholder : element.element ),
400
+ clientRect = related.$.getBoundingClientRect(),
401
+ staticHeight = this.staticContainer.getSize('height' ),
402
+ elemHeight = element.element.getSize( 'height' );
403
+
404
+ if ( element.isFixed ) {
405
+ return ( clientRect.top + elemHeight < staticHeight );
406
+ } else {
407
+ return ( clientRect.top < staticHeight );
408
+ }
409
+ }
410
+ };
411
+
412
+ positionSticky.init();
413
+
414
+ CKEDITOR.document.getWindow().on( 'scroll',
415
+ CKEDITOR.tools.eventsBuffer( 100, positionSticky.checkAll, positionSticky ).input
416
+ );
417
+
418
+ // Make the toolbar sticky.
419
+ positionSticky.watch( CKEDITOR.document.findOne( '.editors-container' ) );
420
+
421
+ // Help button and help-content.
422
+ ( function() {
423
+ var helpButton = CKEDITOR.document.getById( 'help' ),
424
+ helpContent = CKEDITOR.document.getById( 'help-content' );
425
+
426
+ // Don't show help button on IE8 because it's unsupported by Pico Modal.
427
+ if ( CKEDITOR.env.ie && CKEDITOR.env.version == 8 ) {
428
+ helpButton.hide();
429
+ } else {
430
+ // Display help modal when the button is clicked.
431
+ helpButton.on( 'click', function( evt ) {
432
+ SF.modal( {
433
+ // Clone modal content from DOM.
434
+ content: helpContent.getHtml(),
435
+
436
+ afterCreate: function( modal ) {
437
+ // Enable modal content button to close the modal.
438
+ new CKEDITOR.dom.element( modal.modalElem() ).findOne( '.help-content-close' ).once( 'click', modal.close );
439
+ }
440
+ } ).show();
441
+ } );
442
+ }
443
+ } )();
444
+ } )();
445
+ </script>
446
+ </body>
447
+ </html>
@@ -0,0 +1,13 @@
1
+ "function"!=typeof Object.create&&function(){var a=function(){};Object.create=function(b){if(1<arguments.length)throw Error("Second argument not supported");if(null===b)throw Error("Cannot set a null [[Prototype]]");if("object"!=typeof b)throw TypeError("Argument must be an object");a.prototype=b;return new a}}();
2
+ CKEDITOR.plugins.add("toolbarconfiguratorarea",{afterInit:function(a){a.addMode("wysiwyg",function(b){var c=CKEDITOR.dom.element.createFromHtml('\x3cdiv class\x3d"cke_wysiwyg_div cke_reset" hidefocus\x3d"true"\x3e\x3c/div\x3e');a.ui.space("contents").append(c);c=a.editable(c);c.detach=CKEDITOR.tools.override(c.detach,function(b){return function(){b.apply(this,arguments);this.remove()}});a.setData(a.getData(1),b);a.fire("contentDom")});a.dataProcessor.toHtml=function(b){return b};a.dataProcessor.toDataFormat=
3
+ function(b){return b}}});Object.keys||(Object.keys=function(){var a=Object.prototype.hasOwnProperty,b=!{toString:null}.propertyIsEnumerable("toString"),c="toString toLocaleString valueOf hasOwnProperty isPrototypeOf propertyIsEnumerable constructor".split(" "),e=c.length;return function(d){if("object"!==typeof d&&("function"!==typeof d||null===d))throw new TypeError("Object.keys called on non-object");var g=[],f;for(f in d)a.call(d,f)&&g.push(f);if(b)for(f=0;f<e;f++)a.call(d,c[f])&&g.push(c[f]);return g}}());
4
+ (function(){function a(b,c){this.cfg=c||{};this.hidden=!1;this.editorId=b;this.fullToolbarEditor=new ToolbarConfigurator.FullToolbarEditor;this.actualConfig=this.originalConfig=this.mainContainer=null;this.isEditableVisible=this.waitForReady=!1;this.toolbarContainer=null;this.toolbarButtons=[]}ToolbarConfigurator.AbstractToolbarModifier=a;a.prototype.setConfig=function(b){this._onInit(void 0,b,!0)};a.prototype.init=function(b){var c=this;this.mainContainer=new CKEDITOR.dom.element("div");if(null!==
5
+ this.fullToolbarEditor.editorInstance)throw"Only one instance of ToolbarModifier is allowed";this.editorInstance||this._createEditor(!1);this.editorInstance.once("loaded",function(){c.fullToolbarEditor.init(function(){c._onInit(b);if("function"==typeof c.onRefresh)c.onRefresh()},c.editorInstance.config)});return this.mainContainer};a.prototype._onInit=function(b,c){this.originalConfig=this.editorInstance.config;this.actualConfig=c?JSON.parse(c):JSON.parse(JSON.stringify(this.originalConfig));if(!this.actualConfig.toolbarGroups&&
6
+ !this.actualConfig.toolbar){for(var a=this.actualConfig,d=this.editorInstance.toolbar,g=[],f=d.length,k=0;k<f;k++){var h=d[k];"string"==typeof h?g.push(h):g.push({name:h.name,groups:h.groups?h.groups.slice():[]})}a.toolbarGroups=g}"function"===typeof b&&b(this.mainContainer)};a.prototype._createModifier=function(){this.mainContainer.addClass("unselectable");this.modifyContainer&&this.modifyContainer.remove();this.modifyContainer=new CKEDITOR.dom.element("div");this.modifyContainer.addClass("toolbarModifier");
7
+ this.mainContainer.append(this.modifyContainer);return this.mainContainer};a.prototype.getEditableArea=function(){return this.editorInstance.container.findOne("#"+this.editorInstance.id+"_contents")};a.prototype._hideEditable=function(){var b=this.getEditableArea();this.isEditableVisible=!1;this.lastEditableAreaHeight=b.getStyle("height");b.setStyle("height","0")};a.prototype._showEditable=function(){this.isEditableVisible=!0;this.getEditableArea().setStyle("height",this.lastEditableAreaHeight||"auto")};
8
+ a.prototype._toggleEditable=function(){this.isEditableVisible?this._hideEditable():this._showEditable()};a.prototype._refreshEditor=function(){function b(){c.editorInstance.destroy();c._createEditor(!0,c.getActualConfig());c.waitForReady=!1}var c=this,a=this.editorInstance.status;this.waitForReady||("unloaded"==a||"loaded"==a?(this.waitForReady=!0,this.editorInstance.once("instanceReady",function(){b()},this)):b())};a.prototype._createEditor=function(b,c){function e(){}var d=this;this.editorInstance=
9
+ CKEDITOR.replace(this.editorId);this.editorInstance.on("configLoaded",function(){var b=d.editorInstance.config;c&&CKEDITOR.tools.extend(b,c,!0);a.extendPluginsConfig(b)});this.editorInstance.on("uiSpace",function(b){"top"!=b.data.space&&b.stop()},null,null,-999);this.editorInstance.once("loaded",function(){var c=d.editorInstance.ui.instances,a;for(a in c)c[a]&&(c[a].click=e,c[a].onClick=e);d.isEditableVisible||d._hideEditable();d.currentActive&&d.currentActive.name&&d._highlightGroup(d.currentActive.name);
10
+ d.hidden?d.hideUI():d.showUI();if(b&&"function"===typeof d.onRefresh)d.onRefresh()})};a.prototype.getActualConfig=function(){return JSON.parse(JSON.stringify(this.actualConfig))};a.prototype._createToolbar=function(){if(this.toolbarButtons.length){this.toolbarContainer=new CKEDITOR.dom.element("div");this.toolbarContainer.addClass("toolbar");for(var b=this.toolbarButtons.length,c=0;c<b;c+=1)this._createToolbarBtn(this.toolbarButtons[c])}};a.prototype._createToolbarBtn=function(b){var c=ToolbarConfigurator.FullToolbarEditor.createButton("string"===
11
+ typeof b.text?b.text:b.text.inactive,b.cssClass);this.toolbarContainer.append(c);c.data("group",b.group);c.addClass(b.position);c.on("click",function(){b.clickCallback.call(this,c,b)},this);return c};a.prototype._fixGroups=function(b){b=b.toolbarGroups||[];for(var c=b.length,a=0;a<c;a+=1){var d=b[a];"/"==d?(d=b[a]={},d.type="separator",d.name="separator"+CKEDITOR.tools.getNextNumber()):(d.groups=d.groups||[],-1==CKEDITOR.tools.indexOf(d.groups,d.name)&&(this.editorInstance.ui.addToolbarGroup(d.name,
12
+ d.groups[d.groups.length-1],d.name),d.groups.push(d.name)),this._fixSubgroups(d))}};a.prototype._fixSubgroups=function(b){b=b.groups;for(var c=b.length,a=0;a<c;a+=1){var d=b[a];b[a]={name:d,totalBtns:ToolbarConfigurator.ToolbarModifier.getTotalSubGroupButtonsNumber(d,this.fullToolbarEditor)}}};a.stringifyJSONintoOneLine=function(b,a){a=a||{};var e=JSON.stringify(b,null,""),e=e.replace(/\n/g,"");a.addSpaces&&(e=e.replace(/(\{|:|,|\[|\])/g,function(a){return a+" "}),e=e.replace(/(\])/g,function(a){return" "+
13
+ a}));a.noQuotesOnKey&&(e=e.replace(/"(\w*)":/g,function(a,b){return b+":"}));a.singleQuotes&&(e=e.replace(/\"/g,"'"));return e};a.prototype.hideUI=function(){this.hidden=!0;this.mainContainer.hide();this.editorInstance.container&&this.editorInstance.container.hide()};a.prototype.showUI=function(){this.hidden=!1;this.mainContainer.show();this.editorInstance.container&&this.editorInstance.container.show()};a.extendPluginsConfig=function(a){var c=a.extraPlugins;a.extraPlugins=(c?c+",":"")+"toolbarconfiguratorarea"}})();
@@ -0,0 +1,9 @@
1
+ window.ToolbarConfigurator={};
2
+ (function(){function e(){this.instanceid="fte"+CKEDITOR.tools.getNextId();this.textarea=new CKEDITOR.dom.element("textarea");this.textarea.setAttributes({id:this.instanceid,name:this.instanceid,contentEditable:!0});this.editorInstance=this.buttons=null}ToolbarConfigurator.FullToolbarEditor=e;e.prototype.init=function(b){var a=this;document.body.appendChild(this.textarea.$);CKEDITOR.replace(this.instanceid);this.editorInstance=CKEDITOR.instances[this.instanceid];this.editorInstance.once("configLoaded",function(d){var c=
3
+ d.editor.config;delete c.removeButtons;delete c.toolbarGroups;delete c.toolbar;ToolbarConfigurator.AbstractToolbarModifier.extendPluginsConfig(c);d.editor.once("loaded",function(){a.buttons=e.toolbarToButtons(a.editorInstance.toolbar);a.buttonsByGroup=e.groupButtons(a.buttons);a.buttonNamesByGroup=a.groupButtonNamesByGroup(a.buttons);d.editor.container.hide();"function"===typeof b&&b(a.buttons)})})};e.prototype.groupButtonNamesByGroup=function(b){var a=this;b=e.groupButtons(b);for(var d in b)b[d]=
4
+ e.map(b[d],function(b){return a.getCamelCasedButtonName(b.name)});return b};e.prototype.getGroupByName=function(b){for(var a=this.editorInstance.config.toolbarGroups||this.getFullToolbarGroupsConfig(),d=a.length,c=0;c<d;c+=1)if(a[c].name===b)return a[c];return null};e.prototype.getCamelCasedButtonName=function(b){var a=this.editorInstance.ui.items,d;for(d in a)if(a[d].name==b)return d;return null};e.prototype.getFullToolbarGroupsConfig=function(b){b=!0===b?!0:!1;for(var a=[],d=this.editorInstance.toolbar,
5
+ c=d.length,f=0;f<c;f+=1){var e=d[f],g={};"string"!=typeof e.name?b&&a.push("/"):(g.name=e.name,e.groups&&(g.groups=Array.prototype.slice.call(e.groups)),a.push(g))}return a};e.filter=function(b,a){for(var d=b&&b.length?b.length:0,c=[],f=0;f<d;f+=1)a(b[f])&&c.push(b[f]);return c};e.map=function(b,a){var d;if(CKEDITOR.tools.isArray(b)){d=[];for(var c=b.length,f=0;f<c;f+=1)d.push(a(b[f]))}else for(c in d={},b)d[c]=a(b[c]);return d};e.groupButtons=function(b){for(var a={},d=b.length,c=0;c<d;c+=1){var f=
6
+ b[c],e=f.toolbar?f.toolbar.split(",")[0]:"others";a[e]=a[e]||[];a[e].push(f)}return a};e.toolbarToButtons=function(b){for(var a=[],d=b.length,c=0;c<d;c+=1)"object"==typeof b[c]&&(a=a.concat(e.groupToButtons(b[c])));return a};e.createToolbarButton=function(b){var a=new CKEDITOR.dom.element("a"),d=e.createIcon(b.name,b.icon,b.command);a.setStyle("float","none");a.addClass("cke_"+("rtl"==CKEDITOR.lang.dir?"rtl":"ltr"));if(b instanceof CKEDITOR.ui.button)a.addClass("cke_button"),a.addClass("cke_toolgroup"),
7
+ a.append(d);else if(CKEDITOR.ui.richCombo&&b instanceof CKEDITOR.ui.richCombo){var d=new CKEDITOR.dom.element("span"),c=new CKEDITOR.dom.element("span"),f=new CKEDITOR.dom.element("span");a.addClass("cke_combo_button");d.addClass("cke_combo_text");d.addClass("cke_combo_inlinelabel");d.setText(b.label);c.addClass("cke_combo_open");f.addClass("cke_combo_arrow");c.append(f);a.append(d);a.append(c)}return a};e.createIcon=function(b,a,d){var c=CKEDITOR.skin.getIconStyle(b,"rtl"==CKEDITOR.lang.dir),c=(c=
8
+ c||CKEDITOR.skin.getIconStyle(a,"rtl"==CKEDITOR.lang.dir))||CKEDITOR.skin.getIconStyle(d,"rtl"==CKEDITOR.lang.dir);a=new CKEDITOR.dom.element("span");a.addClass("cke_button_icon");a.addClass("cke_button__"+b+"_icon");a.setAttribute("style",c);a.setStyle("float","none");return a};e.createButton=function(b,a){var d=new CKEDITOR.dom.element("button");d.addClass("button-a");d.setAttribute("type","button");if("string"==typeof a){a=a.split(" ");for(var c=a.length;c--;)d.addClass(a[c])}d.setHtml(b);return d};
9
+ e.groupToButtons=function(b){for(var a=[],d=(b=b.items)?b.length:0,c=0;c<d;c+=1){var f=b[c];if(f instanceof CKEDITOR.ui.button||CKEDITOR.ui.richCombo&&f instanceof CKEDITOR.ui.richCombo)f.$=e.createToolbarButton(f),a.push(f)}return a}})();
@@ -0,0 +1,33 @@
1
+ (function(){function d(a,b){l.call(this,a,b);this.actualConfig=this.originalConfig=this.removedButtons=null;this.emptyVisible=!1;this.state="edit";this.toolbarButtons=[{text:{active:"Hide empty toolbar groups",inactive:"Show empty toolbar groups"},group:"edit",position:"left",cssClass:"button-a-soft",clickCallback:function(a,b){a[a.hasClass("button-a-background")?"removeClass":"addClass"]("button-a-background");this._toggleVisibilityEmptyElements();this.emptyVisible?a.setText(b.text.active):a.setText(b.text.inactive)}},
2
+ {text:"Add row separator",group:"edit",position:"left",cssClass:"button-a-soft",clickCallback:function(){this._addSeparator()}},{text:"Select config",group:"config",position:"left",cssClass:"button-a-soft",clickCallback:function(){this.configContainer.findOne("textarea").$.select()}},{text:"Back to configurator",group:"config",position:"right",cssClass:"button-a-background",clickCallback:function(){if("paste"===this.state){var a=this.configContainer.findOne("textarea").getValue();(a=d.evaluateToolbarGroupsConfig(a))?
3
+ this.setConfig(a):alert("Your pasted config is wrong.")}this.state="edit";this._showConfigurationTool();this.showToolbarBtnsByGroupName(this.state)}},{text:'Get toolbar \x3cspan class\x3d"highlight"\x3econfig\x3c/span\x3e',group:"edit",position:"right",cssClass:"button-a-background icon-pos-left icon-download",clickCallback:function(){this.state="config";this._showConfig();this.showToolbarBtnsByGroupName(this.state)}}];this.cachedActiveElement=null}var l=ToolbarConfigurator.AbstractToolbarModifier;
4
+ ToolbarConfigurator.ToolbarModifier=d;d.prototype=Object.create(ToolbarConfigurator.AbstractToolbarModifier.prototype);d.prototype.getActualConfig=function(){var a=l.prototype.getActualConfig.call(this);if(a.toolbarGroups)for(var b=a.toolbarGroups.length,c=0;c<b;c+=1)a.toolbarGroups[c]=d.parseGroupToConfigValue(a.toolbarGroups[c]);return a};d.prototype._onInit=function(a,b,c){c=!0===c;l.prototype._onInit.call(this,void 0,b);this.removedButtons=[];c?this.removedButtons=this.actualConfig.removeButtons?
5
+ this.actualConfig.removeButtons.split(","):[]:"removeButtons"in this.originalConfig?this.removedButtons=this.originalConfig.removeButtons?this.originalConfig.removeButtons.split(","):[]:(this.originalConfig.removeButtons="",this.removedButtons=[]);this.actualConfig.toolbarGroups||(this.actualConfig.toolbarGroups=this.fullToolbarEditor.getFullToolbarGroupsConfig());this._fixGroups(this.actualConfig);this._calculateTotalBtns();this._createModifier();this._refreshMoveBtnsAvalibility();this._refreshBtnTabIndexes();
6
+ "function"===typeof a&&a(this.mainContainer)};d.prototype._showConfigurationTool=function(){this.configContainer.addClass("hidden");this.modifyContainer.removeClass("hidden")};d.prototype._showConfig=function(){var a=this.getActualConfig(),b,c;if(a.toolbarGroups){b=a.toolbarGroups;for(var e=this.cfg.trimEmptyGroups,f=[],g=b.length,m=0;m<g;m++){var h=b[m];if("/"===h)f.push("'/'");else{if(e)for(var k=h.groups.length;k--;)0===d.getTotalSubGroupButtonsNumber(h.groups[k],this.fullToolbarEditor)&&h.groups.splice(k,
7
+ 1);e&&0===h.groups.length||f.push(l.stringifyJSONintoOneLine(h,{addSpaces:!0,noQuotesOnKey:!0,singleQuotes:!0}))}}b="\n\t\t"+f.join(",\n\t\t")}a.removeButtons&&(c=a.removeButtons);a=['\x3ctextarea class\x3d"configCode" readonly\x3eCKEDITOR.editorConfig \x3d function( config ) {\n',b?"\tconfig.toolbarGroups \x3d ["+b+"\n\t];":"",c?"\n\n":"",c?"\tconfig.removeButtons \x3d '"+c+"';":"","\n};\x3c/textarea\x3e"].join("");this.modifyContainer.addClass("hidden");this.configContainer.removeClass("hidden");
8
+ this.configContainer.setHtml(a)};d.prototype._toggleVisibilityEmptyElements=function(){this.modifyContainer.hasClass("empty-visible")?(this.modifyContainer.removeClass("empty-visible"),this.emptyVisible=!1):(this.modifyContainer.addClass("empty-visible"),this.emptyVisible=!0);this._refreshMoveBtnsAvalibility()};d.prototype._createModifier=function(){function a(){b._highlightGroup(this.data("name"))}var b=this;l.prototype._createModifier.call(this);this.modifyContainer.setHtml(this._toolbarConfigToListString());
9
+ var c=this.modifyContainer.find('li[data-type\x3d"group"]');this.modifyContainer.on("mouseleave",function(){this._dehighlightActiveToolGroup()},this);for(var e=c.count(),f=0;f<e;f+=1)c.getItem(f).on("mouseenter",a);CKEDITOR.document.on("keypress",function(a){a=a.data.$.keyCode;a=32===a||13===a;var c=new CKEDITOR.dom.element(CKEDITOR.document.$.activeElement);c.getAscendant(function(a){return a.$===b.mainContainer.$})&&a&&"button"===c.data("type")&&c.findOne("input").$.click()});this.modifyContainer.on("click",
10
+ function(a){var c=a.data.$,e=new CKEDITOR.dom.element(c.target||c.srcElement);if(a=d.getGroupOrSeparatorLiAncestor(e)){b.cachedActiveElement=document.activeElement;if(e.$ instanceof HTMLInputElement)b._handleCheckboxClicked(e);else if(e.$ instanceof HTMLButtonElement&&(c.preventDefault?c.preventDefault():c.returnValue=!1,(c=b._handleAnchorClicked(e.$))&&"remove"==c.action))return;c=a.data("type");a=a.data("name");b._setActiveElement(c,a);b.cachedActiveElement&&b.cachedActiveElement.focus()}});this.toolbarContainer||
11
+ (this._createToolbar(),this.toolbarContainer.insertBefore(this.mainContainer.getChildren().getItem(0)));this.showToolbarBtnsByGroupName("edit");this.configContainer||(this.configContainer=new CKEDITOR.dom.element("div"),this.configContainer.addClass("configContainer"),this.configContainer.addClass("hidden"),this.mainContainer.append(this.configContainer));return this.mainContainer};d.prototype.showToolbarBtnsByGroupName=function(a){if(this.toolbarContainer)for(var b=this.toolbarContainer.find("button"),
12
+ c=b.count(),e=0;e<c;e+=1){var d=b.getItem(e);d.data("group")==a?d.removeClass("hidden"):d.addClass("hidden")}};d.parseGroupToConfigValue=function(a){if("separator"==a.type)return"/";var b=a.groups,c=b.length;delete a.totalBtns;for(var e=0;e<c;e+=1)b[e]=b[e].name;return a};d.getGroupOrSeparatorLiAncestor=function(a){return a.$ instanceof HTMLLIElement&&"group"==a.data("type")?a:d.getFirstAncestor(a,function(a){a=a.data("type");return"group"==a||"separator"==a})};d.prototype._setActiveElement=function(a,
13
+ b){this.currentActive&&this.currentActive.elem.removeClass("active");if(null===a)this._dehighlightActiveToolGroup(),this.currentActive=null;else{var c=this.mainContainer.findOne('ul[data-type\x3dtable-body] li[data-type\x3d"'+a+'"][data-name\x3d"'+b+'"]');c.addClass("active");this.currentActive={type:a,name:b,elem:c};"group"==a&&this._highlightGroup(b);"separator"==a&&this._dehighlightActiveToolGroup()}};d.prototype.getActiveToolGroup=function(){return this.editorInstance.container?this.editorInstance.container.findOne(".cke_toolgroup.active, .cke_toolbar.active"):
14
+ null};d.prototype._dehighlightActiveToolGroup=function(){var a=this.getActiveToolGroup();a&&a.removeClass("active");this.editorInstance.container&&this.editorInstance.container.removeClass("some-toolbar-active")};d.prototype._highlightGroup=function(a){this.editorInstance.container&&(a=this.getFirstEnabledButtonInGroup(a),a=this.editorInstance.container.findOne(".cke_button__"+a+", .cke_combo__"+a),this._dehighlightActiveToolGroup(),this.editorInstance.container&&this.editorInstance.container.addClass("some-toolbar-active"),
15
+ a&&(a=d.getFirstAncestor(a,function(a){return a.hasClass("cke_toolbar")}))&&a.addClass("active"))};d.prototype.getFirstEnabledButtonInGroup=function(a){var b=this.actualConfig.toolbarGroups;a=this.getGroupIndex(a);b=b[a];if(-1===a)return null;a=b.groups?b.groups.length:0;for(var c=0;c<a;c+=1){var e=this.getFirstEnabledButtonInSubgroup(b.groups[c].name);if(e)return e}return null};d.prototype.getFirstEnabledButtonInSubgroup=function(a){for(var b=(a=this.fullToolbarEditor.buttonsByGroup[a])?a.length:
16
+ 0,c=0;c<b;c+=1){var e=a[c].name;if(!this.isButtonRemoved(e))return e}return null};d.prototype._handleCheckboxClicked=function(a){var b=a.getAscendant("li").data("name");a.$.checked?this._removeButtonFromRemoved(b):this._addButtonToRemoved(b)};d.prototype._handleAnchorClicked=function(a){a=new CKEDITOR.dom.element(a);var b=a.getAscendant("li"),c=b.getAscendant("ul"),e=b.data("type"),d=b.data("name"),g=a.data("direction"),m="up"===g?b.getPrevious():b.getNext(),h;if(a.hasClass("disabled"))return null;
17
+ if(a.hasClass("remove"))return b.remove(),this._removeSeparator(b.data("name")),this._setActiveElement(null),{action:"remove"};if(!a.hasClass("move")||!m)return{action:null};if("group"===e||"separator"===e)h=this._moveGroup(g,d);"subgroup"===e&&(h=b.getAscendant("li").data("name"),h=this._moveSubgroup(g,h,d));"up"===g&&b.insertBefore(c.getChild(h));"down"===g&&b.insertAfter(c.getChild(h));for(var k;b="up"===g?b.getPrevious():b.getNext();)if(this.emptyVisible||!b.hasClass("empty")){k=b;break}k||(k=
18
+ '[data-direction\x3d"'+("up"===g?"down":"up")+'"]',this.cachedActiveElement=a.getParent().findOne(k));this._refreshMoveBtnsAvalibility();this._refreshBtnTabIndexes();return{action:"move"}};d.prototype._refreshMoveBtnsAvalibility=function(){function a(a){var c=a.count();for(d=0;d<c;d+=1)b._disableElementsInList(a.getItem(d))}for(var b=this,c=this.mainContainer.find("ul[data-type\x3dtable-body] li \x3e p \x3e span \x3e button.move.disabled"),e=c.count(),d=0;d<e;d+=1)c.getItem(d).removeClass("disabled");
19
+ a(this.mainContainer.find("ul[data-type\x3dtable-body]"));a(this.mainContainer.find("ul[data-type\x3dtable-body] \x3e li \x3e ul"))};d.prototype._refreshBtnTabIndexes=function(){for(var a=this.mainContainer.find('[data-tab\x3d"true"]'),b=a.count(),c=0;c<b;c++){var e=a.getItem(c),d=e.hasClass("disabled");e.setAttribute("tabindex",d?-1:c)}};d.prototype._disableElementsInList=function(a){function b(a){return!a.hasClass("empty")}if(a.getChildren().count()){var c;this.emptyVisible?(c=a.getFirst(),a=a.getLast()):
20
+ (c=a.getFirst(b),a=a.getLast(b));if(c)var e=c.findOne('p button[data-direction\x3d"up"]');if(a)var d=a.findOne('p button[data-direction\x3d"down"]');e&&(e.addClass("disabled"),e.setAttribute("tabindex","-1"));d&&(d.addClass("disabled"),d.setAttribute("tabindex","-1"))}};d.prototype.getGroupIndex=function(a){for(var b=this.actualConfig.toolbarGroups,c=b.length,d=0;d<c;d+=1)if(b[d].name===a)return d;return-1};d.prototype._addSeparator=function(){var a=this._determineSeparatorToAddIndex(),b=d.createSeparatorLiteral(),
21
+ c=CKEDITOR.dom.element.createFromHtml(d.getToolbarSeparatorString(b));this.actualConfig.toolbarGroups.splice(a,0,b);c.insertBefore(this.modifyContainer.findOne("ul[data-type\x3dtable-body]").getChild(a));this._setActiveElement("separator",b.name);this._refreshMoveBtnsAvalibility();this._refreshBtnTabIndexes();this._refreshEditor()};d.prototype._removeSeparator=function(a){var b=CKEDITOR.tools.indexOf(this.actualConfig.toolbarGroups,function(b){return"separator"==b.type&&b.name==a});this.actualConfig.toolbarGroups.splice(b,
22
+ 1);this._refreshMoveBtnsAvalibility();this._refreshBtnTabIndexes();this._refreshEditor()};d.prototype._determineSeparatorToAddIndex=function(){return this.currentActive?("group"==this.currentActive.elem.data("type")||"separator"==this.currentActive.elem.data("type")?this.currentActive.elem:this.currentActive.elem.getAscendant("li")).getIndex():0};d.prototype._moveElement=function(a,b,c){function e(a){return a.totalBtns||"separator"==a.type}c=this.emptyVisible?"down"==c?b+1:b-1:d.getFirstElementIndexWith(a,
23
+ b,c,e);return d.moveTo(c-b,a,b)};d.prototype._moveGroup=function(a,b){var c=this.getGroupIndex(b),c=this._moveElement(this.actualConfig.toolbarGroups,c,a);this._refreshMoveBtnsAvalibility();this._refreshBtnTabIndexes();this._refreshEditor();return c};d.prototype._moveSubgroup=function(a,b,c){b=this.getGroupIndex(b);b=this.actualConfig.toolbarGroups[b];var d=CKEDITOR.tools.indexOf(b.groups,function(a){return a.name==c});a=this._moveElement(b.groups,d,a);this._refreshEditor();return a};d.prototype._calculateTotalBtns=
24
+ function(){for(var a=this.actualConfig.toolbarGroups,b=a.length;b--;){var c=a[b],e=d.getTotalGroupButtonsNumber(c,this.fullToolbarEditor);"separator"!=c.type&&(c.totalBtns=e)}};d.prototype._addButtonToRemoved=function(a){if(-1!=CKEDITOR.tools.indexOf(this.removedButtons,a))throw"Button already added to removed";this.removedButtons.push(a);this.actualConfig.removeButtons=this.removedButtons.join(",");this._refreshEditor()};d.prototype._removeButtonFromRemoved=function(a){a=CKEDITOR.tools.indexOf(this.removedButtons,
25
+ a);if(-1===a)throw"Trying to remove button from removed, but not found";this.removedButtons.splice(a,1);this.actualConfig.removeButtons=this.removedButtons.join(",");this._refreshEditor()};d.parseGroupToConfigValue=function(a){if("separator"==a.type)return"/";var b=a.groups,c=b.length;delete a.totalBtns;for(var d=0;d<c;d+=1)b[d]=b[d].name;return a};d.getGroupOrSeparatorLiAncestor=function(a){return a.$ instanceof HTMLLIElement&&"group"==a.data("type")?a:d.getFirstAncestor(a,function(a){a=a.data("type");
26
+ return"group"==a||"separator"==a})};d.createSeparatorLiteral=function(){return{type:"separator",name:"separator"+CKEDITOR.tools.getNextNumber()}};d.prototype._toolbarConfigToListString=function(){for(var a=this.actualConfig.toolbarGroups||[],b='\x3cul data-type\x3d"table-body"\x3e',c=a.length,e=0;e<c;e+=1)var f=a[e],b="separator"===f.type?b+d.getToolbarSeparatorString(f):b+this._getToolbarGroupString(f);b+="\x3c/ul\x3e";return d.getToolbarHeaderString()+b};d.prototype._getToolbarGroupString=function(a){var b=
27
+ a.groups,c;c=""+['\x3cli data-type\x3d"group" data-name\x3d"',a.name,'" ',a.totalBtns?"":'class\x3d"empty"',"\x3e"].join("");c+=d.getToolbarElementPreString(a)+"\x3cul\x3e";a=b.length;for(var e=0;e<a;e+=1){var f=b[e];c+=this._getToolbarSubgroupString(f,this.fullToolbarEditor.buttonsByGroup[f.name])}return c+"\x3c/ul\x3e\x3c/li\x3e"};d.getToolbarSeparatorString=function(a){return['\x3cli data-type\x3d"',a.type,'" data-name\x3d"',a.name,'"\x3e',d.getToolbarElementPreString("row separator"),"\x3c/li\x3e"].join("")};
28
+ d.getToolbarHeaderString=function(){return'\x3cul data-type\x3d"table-header"\x3e\x3cli data-type\x3d"header"\x3e\x3cp\x3eToolbars\x3c/p\x3e\x3cul\x3e\x3cli\x3e\x3cp\x3eToolbar groups\x3c/p\x3e\x3cp\x3eToolbar group items\x3c/p\x3e\x3c/li\x3e\x3c/ul\x3e\x3c/li\x3e\x3c/ul\x3e'};d.getFirstAncestor=function(a,b){for(var c=a.getParents(),d=c.length;d--;)if(b(c[d]))return c[d];return null};d.getFirstElementIndexWith=function(a,b,c,d){for(;"up"===c?b--:++b<a.length;)if(d(a[b]))return b;return-1};d.moveTo=
29
+ function(a,b,c){var d;-1!==c&&(d=b.splice(c,1)[0]);a=c+a;b.splice(a,0,d);return a};d.getTotalSubGroupButtonsNumber=function(a,b){var c=b.buttonsByGroup["string"==typeof a?a:a.name];return c?c.length:0};d.getTotalGroupButtonsNumber=function(a,b){for(var c=0,e=a.groups,f=e?e.length:0,g=0;g<f;g+=1)c+=d.getTotalSubGroupButtonsNumber(e[g],b);return c};d.prototype._getToolbarSubgroupString=function(a,b){var c;c=""+['\x3cli data-type\x3d"subgroup" data-name\x3d"',a.name,'" ',a.totalBtns?"":'class\x3d"empty" ',
30
+ "\x3e"].join("");c+=d.getToolbarElementPreString(a.name);c+="\x3cul\x3e";for(var e=b?b.length:0,f=0;f<e;f+=1)c+=this.getButtonString(b[f]);return c+="\x3c/ul\x3e\x3c/li\x3e"};d.prototype._getConfigButtonName=function(a){var b=this.fullToolbarEditor.editorInstance.ui.items,c;for(c in b)if(b[c].name==a)return c;return null};d.prototype.isButtonRemoved=function(a){return-1!=CKEDITOR.tools.indexOf(this.removedButtons,this._getConfigButtonName(a))};d.prototype.getButtonString=function(a){var b=this.isButtonRemoved(a.name)?
31
+ "":'checked\x3d"checked"';return['\x3cli data-tab\x3d"true" data-type\x3d"button" data-name\x3d"',this._getConfigButtonName(a.name),'"\x3e\x3clabel title\x3d"',a.label,'" \x3e\x3cinput tabindex\x3d"-1"type\x3d"checkbox"',b,"/\x3e",a.$.getOuterHtml(),"\x3c/label\x3e\x3c/li\x3e"].join("")};d.getToolbarElementPreString=function(a){a=a.name?a.name:a;return['\x3cp\x3e\x3cspan\x3e\x3cbutton title\x3d"Move element upward" data-tab\x3d"true" data-direction\x3d"up" class\x3d"move icon-up-big"\x3e\x3c/button\x3e\x3cbutton title\x3d"Move element downward" data-tab\x3d"true" data-direction\x3d"down" class\x3d"move icon-down-big"\x3e\x3c/button\x3e',
32
+ "row separator"==a?'\x3cbutton title\x3d"Remove element" data-tab\x3d"true" class\x3d"remove icon-trash"\x3e\x3c/button\x3e':"",a,"\x3c/span\x3e\x3c/p\x3e"].join("")};d.evaluateToolbarGroupsConfig=function(a){return a=function(a){var c={},d;try{d=eval("("+a+")")}catch(f){try{d=eval(a)}catch(g){return null}}return c.toolbarGroups&&"number"===typeof c.toolbarGroups.length?JSON.stringify(c):d&&"number"===typeof d.length?JSON.stringify({toolbarGroups:d}):d&&d.toolbarGroups?JSON.stringify(d):null}(a)};
33
+ return d})();
@@ -0,0 +1,14 @@
1
+ (function(){function e(a){l.call(this,a);this.hintContainer=this.codeContainer=null}var l=ToolbarConfigurator.AbstractToolbarModifier,g=ToolbarConfigurator.FullToolbarEditor;ToolbarConfigurator.ToolbarTextModifier=e;e.prototype=Object.create(l.prototype);e.prototype._onInit=function(a,d){l.prototype._onInit.call(this,void 0,d);this._createModifier(d?this.actualConfig:void 0);"function"===typeof a&&a(this.mainContainer)};e.prototype._createModifier=function(a){function d(a){var b=c(a);if(null!==b.charsBetween){var d=
2
+ k.getUnusedButtonsArray(k.actualConfig.toolbar,!0,b.charsBetween),e=a.getCursor(),b=CodeMirror.Pos(e.line,e.ch-b.charsBetween.length),h=a.getTokenAt(e);"{"===a.getTokenAt({line:e.line,ch:h.start}).string&&(d=["name"]);if(0!==d.length)return new f(b,e,d)}}function f(a,c,b){this.from=a;this.to=c;this.list=b;this._handlers=[]}function c(a,c){var b={};b.cur=a.getCursor();b.tok=a.getTokenAt(b.cur);b["char"]=c||b.tok.string.charAt(b.tok.string.length-1);var d=a.getRange(CodeMirror.Pos(b.cur.line,0),b.cur).split("").reverse().join(""),
3
+ d=d.replace(/(['|"]\w*['|"])/g,"");b.charsBetween=d.match(/(^\w*)(['|"])/);b.charsBetween&&(b.endChar=b.charsBetween[2],b.charsBetween=b.charsBetween[1].split("").reverse().join(""));return b}function b(a){setTimeout(function(){a.state.completionActive||CodeMirror.showHint(a,d,{hintsClass:"toolbar-modifier",completeSingle:!1})},100);return CodeMirror.Pass}var k=this;this._createToolbar();this.toolbarContainer&&this.mainContainer.append(this.toolbarContainer);l.prototype._createModifier.call(this);
4
+ this._setupActualConfig(a);a=this.actualConfig.toolbar;a=CKEDITOR.tools.isArray(a)?"\tconfig.toolbar \x3d "+("[\n\t\t"+g.map(a,function(a){return l.stringifyJSONintoOneLine(a,{addSpaces:!0,noQuotesOnKey:!0,singleQuotes:!0})}).join(",\n\t\t")+"\n\t]")+";":"config.toolbar \x3d [];";a=["CKEDITOR.editorConfig \x3d function( config ) {\n",a,"\n};"].join("");var e=new CKEDITOR.dom.element("div");e.addClass("codemirror-wrapper");this.modifyContainer.append(e);this.codeContainer=CodeMirror(e.$,{mode:{name:"javascript",
5
+ json:!0},lineNumbers:!1,lineWrapping:!0,viewportMargin:Infinity,value:a,smartIndent:!1,indentWithTabs:!0,indentUnit:4,tabSize:4,theme:"neo",extraKeys:{Left:b,Right:b,"'''":b,"'\"'":b,Backspace:b,Delete:b,"Shift-Tab":"indentLess"}});this.codeContainer.on("endCompletion",function(a,b){var d=c(a);void 0!==b&&a.replaceSelection(d.endChar)});this.codeContainer.on("change",function(){var a=k.codeContainer.getValue(),a=k._evaluateValue(a);null!==a?(k.actualConfig.toolbar=a.toolbar?a.toolbar:k.actualConfig.toolbar,
6
+ k._fillHintByUnusedElements(),k._refreshEditor(),k.mainContainer.removeClass("invalid")):k.mainContainer.addClass("invalid")});this.hintContainer=new CKEDITOR.dom.element("div");this.hintContainer.addClass("toolbarModifier-hints");this._fillHintByUnusedElements();this.hintContainer.insertBefore(e)};e.prototype._fillHintByUnusedElements=function(){var a=this.getUnusedButtonsArray(this.actualConfig.toolbar,!0),a=this.groupButtonNamesByGroup(a),d=g.map(a,function(a){var b=g.map(a.buttons,function(a){return"\x3ccode\x3e"+
7
+ a+"\x3c/code\x3e "}).join("");return["\x3cdt\x3e\x3ccode\x3e",a.name,"\x3c/code\x3e\x3c/dt\x3e\x3cdd\x3e",b,"\x3c/dd\x3e"].join("")}).join(" "),f='\x3cdt class\x3d"list-header"\x3eToolbar group\x3c/dt\x3e\x3cdd class\x3d"list-header"\x3eUnused items\x3c/dd\x3e';a.length||(f="\x3cp\x3eAll items are in use.\x3c/p\x3e");this.codeContainer.refresh();this.hintContainer.setHtml("\x3ch3\x3eUnused toolbar items\x3c/h3\x3e\x3cdl\x3e"+f+d+"\x3c/dl\x3e")};e.prototype.getToolbarGroupByButtonName=function(a){var d=
8
+ this.fullToolbarEditor.buttonNamesByGroup,f;for(f in d)for(var c=d[f],b=c.length;b--;)if(a===c[b])return f;return null};e.prototype.getUnusedButtonsArray=function(a,d,f){d=!0===d?!0:!1;var c=e.mapToolbarCfgToElementsList(a);a=Object.keys(this.fullToolbarEditor.editorInstance.ui.items);a=g.filter(a,function(a){var d="-"===a;a=void 0===f||0===a.toLowerCase().indexOf(f.toLowerCase());return!d&&a});a=g.filter(a,function(a){return-1==CKEDITOR.tools.indexOf(c,a)});d&&a.sort();return a};e.prototype.groupButtonNamesByGroup=
9
+ function(a){var d=[],f=JSON.parse(JSON.stringify(this.fullToolbarEditor.buttonNamesByGroup)),c;for(c in f){var b=f[c],b=g.filter(b,function(b){return-1!==CKEDITOR.tools.indexOf(a,b)});b.length&&d.push({name:c,buttons:b})}return d};e.mapToolbarCfgToElementsList=function(a){function d(a){return"-"!==a}for(var f=[],c=a.length,b=0;b<c;b+=1)a[b]&&"string"!==typeof a[b]&&(f=f.concat(g.filter(a[b].items,d)));return f};e.prototype._setupActualConfig=function(a){a=a||this.editorInstance.config;CKEDITOR.tools.isArray(a.toolbar)||
10
+ (a.toolbarGroups||(a.toolbarGroups=this.fullToolbarEditor.getFullToolbarGroupsConfig(!0)),this._fixGroups(a),a.toolbar=this._mapToolbarGroupsToToolbar(a.toolbarGroups,this.actualConfig.removeButtons),this.actualConfig.toolbar=a.toolbar,this.actualConfig.removeButtons="")};e.prototype._mapToolbarGroupsToToolbar=function(a,d){d=d||this.editorInstance.config.removedBtns;d="string"==typeof d?d.split(","):[];for(var f=a.length;f--;){var c=this._mapToolbarSubgroup(a[f],d);"separator"===a[f].type?a[f]="/":
11
+ CKEDITOR.tools.isArray(c)&&0===c.length?a.splice(f,1):a[f]="string"==typeof c?c:{name:a[f].name,items:c}}return a};e.prototype._mapToolbarSubgroup=function(a,d){if("string"==typeof a)return a;for(var f=a.groups?a.groups.length:0,c=[],b=0;b<f;b+=1){var e=a.groups[b],e=this.fullToolbarEditor.buttonsByGroup["string"===typeof e?e:e.name]||[],e=this._mapButtonsToButtonsNames(e,d),g=e.length,c=c.concat(e);g&&c.push("-")}"-"==c[c.length-1]&&c.pop();return c};e.prototype._mapButtonsToButtonsNames=function(a,
12
+ d){for(var f=a.length;f--;){var c=a[f],c="string"===typeof c?c:this.fullToolbarEditor.getCamelCasedButtonName(c.name);-1!==CKEDITOR.tools.indexOf(d,c)?a.splice(f,1):a[f]=c}return a};e.prototype._evaluateValue=function(a){var d;try{var f={};Function("var CKEDITOR \x3d {}; "+a+"; return CKEDITOR;")().editorConfig(f);d=f;for(var c=d.toolbar.length;c--;)d.toolbar[c]||d.toolbar.splice(c,1)}catch(b){d=null}return d};e.prototype.mapToolbarToToolbarGroups=function(a){function d(a,b){a=a.slice();for(var d=
13
+ b.length;d--;){var c=a.indexOf(b[d]);-1!==c&&a.splice(c,1)}return a}for(var f={},c=[],b=[],c=a.length,e=0;e<c;e++)if("/"===a[e])b.push("/");else{var g=a[e].items,m={};m.name=a[e].name;m.groups=[];for(var l=g.length,p=0;p<l;p++){var n=g[p];if("-"!==n){var h=this.getToolbarGroupByButtonName(n);-1===m.groups.indexOf(h)&&m.groups.push(h);f[h]=f[h]||{};h=f[h].buttons=f[h].buttons||{};h[n]=h[n]||{used:0,origin:m.name};h[n].used++}}b.push(m)}c=function(a,b){var c=[],e;for(e in a)var f=a[e],g=b[e].slice(),
14
+ c=c.concat(d(g,Object.keys(f.buttons)));return c}(f,this.fullToolbarEditor.buttonNamesByGroup);return{toolbarGroups:b,removeButtons:c.join(",")}};return e})();
@@ -0,0 +1,19 @@
1
+ Copyright (C) 2014 by Marijn Haverbeke <marijnh@gmail.com> and others
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy
4
+ of this software and associated documentation files (the "Software"), to deal
5
+ in the Software without restriction, including without limitation the rights
6
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
+ copies of the Software, and to permit persons to whom the Software is
8
+ furnished to do so, subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in
11
+ all copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19
+ THE SOFTWARE.