constructor-cms 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (305) hide show
  1. data/.idea/.name +1 -0
  2. data/.idea/constructor.iml +62 -0
  3. data/.idea/encodings.xml +5 -0
  4. data/.idea/misc.xml +5 -0
  5. data/.idea/modules.xml +9 -0
  6. data/.idea/scopes/scope_settings.xml +5 -0
  7. data/.idea/vcs.xml +7 -0
  8. data/.idea/workspace.xml +873 -0
  9. data/.rspec +2 -0
  10. data/cap/app/assets/images/constructor_cap/cross.png +0 -0
  11. data/cap/app/assets/images/constructor_cap/page_white_edit.png +0 -0
  12. data/cap/app/controllers/constructor_cap/emails_controller.rb +71 -0
  13. data/cap/app/models/constructor_cap/email.rb +15 -0
  14. data/cap/app/views/constructor_cap/emails/_form.haml +17 -0
  15. data/cap/app/views/constructor_cap/emails/edit.haml +5 -0
  16. data/cap/app/views/constructor_cap/emails/index.haml +27 -0
  17. data/cap/app/views/constructor_cap/emails/new.haml +5 -0
  18. data/cap/app/views/constructor_cap/emails/show.haml +54 -0
  19. data/cap/config/initializers/admin_menu.rb +4 -0
  20. data/cap/config/locales/ru.yml +23 -0
  21. data/cap/config/routes.rb +9 -0
  22. data/cap/constructor-cap.gemspec +19 -0
  23. data/cap/db/migrate/20110510182404_create_emails.rb +12 -0
  24. data/cap/lib/constructor-cap.rb +2 -0
  25. data/cap/lib/constructor_cap/engine.rb +6 -0
  26. data/config/routes.rb +4 -0
  27. data/constructor-cms.gemspec +21 -0
  28. data/core/app/assets/images/constructor_core/glyphicons-halflings-white.png +0 -0
  29. data/core/app/assets/images/constructor_core/glyphicons-halflings.png +0 -0
  30. data/core/app/assets/images/constructor_core/minus.gif +0 -0
  31. data/core/app/assets/images/constructor_core/plus.gif +0 -0
  32. data/core/app/assets/images/constructor_core/rss.png +0 -0
  33. data/core/app/assets/images/constructor_core/treeview-black-line.gif +0 -0
  34. data/core/app/assets/images/constructor_core/treeview-black.gif +0 -0
  35. data/core/app/assets/images/constructor_core/treeview-default-line.gif +0 -0
  36. data/core/app/assets/images/constructor_core/treeview-default.gif +0 -0
  37. data/core/app/assets/images/constructor_core/treeview-famfamfam-line.gif +0 -0
  38. data/core/app/assets/images/constructor_core/treeview-famfamfam.gif +0 -0
  39. data/core/app/assets/images/constructor_core/treeview-gray-line.gif +0 -0
  40. data/core/app/assets/images/constructor_core/treeview-gray.gif +0 -0
  41. data/core/app/assets/images/constructor_core/treeview-red-line.gif +0 -0
  42. data/core/app/assets/images/constructor_core/treeview-red.gif +0 -0
  43. data/core/app/assets/images/constructor_core/twitter.png +0 -0
  44. data/core/app/assets/images/constructor_core/widgets.png +0 -0
  45. data/core/app/assets/javascripts/constructor_core/application.js.coffee +57 -0
  46. data/core/app/assets/javascripts/constructor_core/bootstrap.js +2276 -0
  47. data/core/app/assets/javascripts/constructor_core/jquery.cookie.js +92 -0
  48. data/core/app/assets/javascripts/constructor_core/jquery.treeview.js +256 -0
  49. data/core/app/assets/javascripts/constructor_core/jquery_bundle.js.coffee +4 -0
  50. data/core/app/assets/javascripts/constructor_core/urlify.js +82 -0
  51. data/core/app/assets/stylesheets/constructor_core/application.css.scss +57 -0
  52. data/core/app/assets/stylesheets/constructor_core/bootstrap-responsive.css +1109 -0
  53. data/core/app/assets/stylesheets/constructor_core/bootstrap.css +6158 -0
  54. data/core/app/assets/stylesheets/constructor_core/jquery.treeview.css +73 -0
  55. data/core/app/controllers/constructor_core/admin_controller.rb +6 -0
  56. data/core/app/controllers/constructor_core/sessions_controller.rb +15 -0
  57. data/core/app/helpers/constructor_core/devise_helper.rb +24 -0
  58. data/core/app/models/constructor_core/user.rb +10 -0
  59. data/core/app/views/constructor_core/devise/confirmations/new.html.haml +10 -0
  60. data/core/app/views/constructor_core/devise/mailer/confirmation_instructions.html.haml +5 -0
  61. data/core/app/views/constructor_core/devise/mailer/reset_password_instructions.html.haml +7 -0
  62. data/core/app/views/constructor_core/devise/mailer/unlock_instructions.html.haml +5 -0
  63. data/core/app/views/constructor_core/devise/passwords/edit.html.haml +21 -0
  64. data/core/app/views/constructor_core/devise/passwords/new.html.haml +13 -0
  65. data/core/app/views/constructor_core/devise/registrations/edit.html.haml +28 -0
  66. data/core/app/views/constructor_core/devise/registrations/new.html.haml +20 -0
  67. data/core/app/views/constructor_core/devise/shared/_links.html.haml +19 -0
  68. data/core/app/views/constructor_core/devise/unlocks/new.html.haml +9 -0
  69. data/core/app/views/constructor_core/sessions/new.html.haml +24 -0
  70. data/core/app/views/layouts/constructor_core/application_admin.haml +65 -0
  71. data/core/config/environments/production.rb +3 -0
  72. data/core/config/initializers/devise.rb +223 -0
  73. data/core/config/locales/devise.en.yml +56 -0
  74. data/core/config/locales/devise.ru.yml +52 -0
  75. data/core/config/locales/ru.yml +12 -0
  76. data/core/config/routes.rb +9 -0
  77. data/core/constructor-core.gemspec +16 -0
  78. data/core/db/migrate/1_devise_users.rb +56 -0
  79. data/core/db/migrate/2_add_default_user.rb +9 -0
  80. data/core/lib/constructor-core.rb +23 -0
  81. data/core/lib/constructor_core/engine.rb +6 -0
  82. data/core/spec/factories.rb +2 -0
  83. data/core/spec/lib/nav/group_spec.rb +61 -0
  84. data/core/spec/lib/nav/item_spec.rb +151 -0
  85. data/core/spec/lib/nav_lib_spec.rb +60 -0
  86. data/core/spec/spec_helper.rb +34 -0
  87. data/core/vendor/assets/javascripts/.gitkeep +0 -0
  88. data/core/vendor/assets/javascripts/ckeditor/ckeditor.js +913 -0
  89. data/core/vendor/assets/javascripts/ckeditor/config.js +38 -0
  90. data/core/vendor/assets/javascripts/ckeditor/lang/en.js +5 -0
  91. data/core/vendor/assets/javascripts/ckeditor/lang/ru.js +5 -0
  92. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/a11yhelp.js +10 -0
  93. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/_translationstatus.txt +25 -0
  94. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ar.js +9 -0
  95. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/bg.js +9 -0
  96. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ca.js +9 -0
  97. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/cs.js +10 -0
  98. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/cy.js +9 -0
  99. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/da.js +9 -0
  100. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/de.js +10 -0
  101. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/el.js +10 -0
  102. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/en.js +9 -0
  103. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/eo.js +10 -0
  104. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/es.js +10 -0
  105. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/et.js +9 -0
  106. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/fa.js +9 -0
  107. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/fi.js +10 -0
  108. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/fr.js +10 -0
  109. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/gu.js +9 -0
  110. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/he.js +9 -0
  111. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/hi.js +9 -0
  112. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/hr.js +9 -0
  113. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/hu.js +9 -0
  114. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/it.js +10 -0
  115. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ja.js +9 -0
  116. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/km.js +9 -0
  117. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ku.js +10 -0
  118. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/lt.js +9 -0
  119. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/lv.js +10 -0
  120. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/mk.js +9 -0
  121. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/mn.js +9 -0
  122. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/nb.js +9 -0
  123. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/nl.js +10 -0
  124. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/no.js +9 -0
  125. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/pl.js +10 -0
  126. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/pt-br.js +9 -0
  127. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/pt.js +9 -0
  128. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ro.js +9 -0
  129. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ru.js +9 -0
  130. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sk.js +10 -0
  131. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sl.js +9 -0
  132. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/sv.js +10 -0
  133. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/th.js +9 -0
  134. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/tr.js +10 -0
  135. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ug.js +9 -0
  136. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/uk.js +9 -0
  137. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/vi.js +9 -0
  138. data/core/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/zh-cn.js +7 -0
  139. data/core/vendor/assets/javascripts/ckeditor/plugins/about/dialogs/about.js +6 -0
  140. data/core/vendor/assets/javascripts/ckeditor/plugins/about/dialogs/logo_ckeditor.png +0 -0
  141. data/core/vendor/assets/javascripts/ckeditor/plugins/clipboard/dialogs/paste.js +11 -0
  142. data/core/vendor/assets/javascripts/ckeditor/plugins/colordialog/dialogs/colordialog.js +13 -0
  143. data/core/vendor/assets/javascripts/ckeditor/plugins/dialog/dialogDefinition.js +4 -0
  144. data/core/vendor/assets/javascripts/ckeditor/plugins/div/dialogs/div.js +9 -0
  145. data/core/vendor/assets/javascripts/ckeditor/plugins/fakeobjects/images/spacer.gif +0 -0
  146. data/core/vendor/assets/javascripts/ckeditor/plugins/find/dialogs/find.js +24 -0
  147. data/core/vendor/assets/javascripts/ckeditor/plugins/icons.png +0 -0
  148. data/core/vendor/assets/javascripts/ckeditor/plugins/iframe/dialogs/iframe.js +10 -0
  149. data/core/vendor/assets/javascripts/ckeditor/plugins/iframe/images/placeholder.png +0 -0
  150. data/core/vendor/assets/javascripts/ckeditor/plugins/image/dialogs/image.js +43 -0
  151. data/core/vendor/assets/javascripts/ckeditor/plugins/image/images/noimage.png +0 -0
  152. data/core/vendor/assets/javascripts/ckeditor/plugins/link/dialogs/anchor.js +8 -0
  153. data/core/vendor/assets/javascripts/ckeditor/plugins/link/dialogs/link.js +36 -0
  154. data/core/vendor/assets/javascripts/ckeditor/plugins/link/images/anchor.png +0 -0
  155. data/core/vendor/assets/javascripts/ckeditor/plugins/liststyle/dialogs/liststyle.js +10 -0
  156. data/core/vendor/assets/javascripts/ckeditor/plugins/magicline/images/icon.png +0 -0
  157. data/core/vendor/assets/javascripts/ckeditor/plugins/pastefromword/filter/default.js +31 -0
  158. data/core/vendor/assets/javascripts/ckeditor/plugins/preview/preview.html +10 -0
  159. data/core/vendor/assets/javascripts/ckeditor/plugins/scayt/LICENSE.md +28 -0
  160. data/core/vendor/assets/javascripts/ckeditor/plugins/scayt/README.md +25 -0
  161. data/core/vendor/assets/javascripts/ckeditor/plugins/scayt/dialogs/options.js +20 -0
  162. data/core/vendor/assets/javascripts/ckeditor/plugins/scayt/dialogs/toolbar.css +71 -0
  163. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_address.png +0 -0
  164. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_blockquote.png +0 -0
  165. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_div.png +0 -0
  166. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_h1.png +0 -0
  167. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_h2.png +0 -0
  168. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_h3.png +0 -0
  169. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_h4.png +0 -0
  170. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_h5.png +0 -0
  171. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_h6.png +0 -0
  172. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_p.png +0 -0
  173. data/core/vendor/assets/javascripts/ckeditor/plugins/showblocks/images/block_pre.png +0 -0
  174. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/_translationstatus.txt +20 -0
  175. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ca.js +13 -0
  176. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/cs.js +13 -0
  177. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/cy.js +14 -0
  178. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/de.js +13 -0
  179. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/el.js +13 -0
  180. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/en.js +13 -0
  181. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/eo.js +12 -0
  182. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/et.js +13 -0
  183. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/fa.js +12 -0
  184. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/fi.js +13 -0
  185. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/fr.js +11 -0
  186. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/he.js +13 -0
  187. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/hr.js +13 -0
  188. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/it.js +14 -0
  189. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ku.js +13 -0
  190. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/lv.js +13 -0
  191. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/nb.js +11 -0
  192. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/nl.js +13 -0
  193. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/no.js +11 -0
  194. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/pl.js +12 -0
  195. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/pt-br.js +11 -0
  196. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/sk.js +13 -0
  197. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/sv.js +11 -0
  198. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/th.js +13 -0
  199. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/tr.js +12 -0
  200. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ug.js +13 -0
  201. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/zh-cn.js +9 -0
  202. data/core/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/specialchar.js +14 -0
  203. data/core/vendor/assets/javascripts/ckeditor/plugins/table/dialogs/table.js +21 -0
  204. data/core/vendor/assets/javascripts/ckeditor/plugins/tabletools/dialogs/tableCell.js +16 -0
  205. data/core/vendor/assets/javascripts/ckeditor/plugins/templates/dialogs/templates.css +84 -0
  206. data/core/vendor/assets/javascripts/ckeditor/plugins/templates/dialogs/templates.js +10 -0
  207. data/core/vendor/assets/javascripts/ckeditor/plugins/templates/templates/default.js +6 -0
  208. data/core/vendor/assets/javascripts/ckeditor/plugins/templates/templates/images/template1.gif +0 -0
  209. data/core/vendor/assets/javascripts/ckeditor/plugins/templates/templates/images/template2.gif +0 -0
  210. data/core/vendor/assets/javascripts/ckeditor/plugins/templates/templates/images/template3.gif +0 -0
  211. data/core/vendor/assets/javascripts/ckeditor/plugins/wsc/LICENSE.md +28 -0
  212. data/core/vendor/assets/javascripts/ckeditor/plugins/wsc/README.md +25 -0
  213. data/core/vendor/assets/javascripts/ckeditor/plugins/wsc/dialogs/ciframe.html +49 -0
  214. data/core/vendor/assets/javascripts/ckeditor/plugins/wsc/dialogs/tmpFrameset.html +52 -0
  215. data/core/vendor/assets/javascripts/ckeditor/plugins/wsc/dialogs/wsc.css +82 -0
  216. data/core/vendor/assets/javascripts/ckeditor/plugins/wsc/dialogs/wsc.js +11 -0
  217. data/core/vendor/assets/javascripts/ckeditor/styles.js +111 -0
  218. data/core/vendor/assets/stylesheets/.gitkeep +0 -0
  219. data/core/vendor/assets/stylesheets/ckeditor/contents.css +103 -0
  220. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/dialog.css +5 -0
  221. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/dialog_ie.css +5 -0
  222. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/dialog_ie7.css +5 -0
  223. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/dialog_ie8.css +5 -0
  224. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/dialog_opera.css +5 -0
  225. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/editor.css +5 -0
  226. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/editor_gecko.css +5 -0
  227. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/editor_ie.css +5 -0
  228. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/editor_ie7.css +5 -0
  229. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/editor_ie8.css +5 -0
  230. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/icons.png +0 -0
  231. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/images/arrow.png +0 -0
  232. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/images/close.png +0 -0
  233. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/images/mini.png +0 -0
  234. data/core/vendor/assets/stylesheets/ckeditor/skins/moono/readme.md +51 -0
  235. data/lib/constructor/engine.rb +6 -0
  236. data/lib/constructor-cms.rb +3 -0
  237. data/pages/app/assets/images/constructor_pages/arrow_down.png +0 -0
  238. data/pages/app/assets/images/constructor_pages/arrow_up.png +0 -0
  239. data/pages/app/assets/images/constructor_pages/information.png +0 -0
  240. data/pages/app/assets/images/constructor_pages/page_white_edit.png +0 -0
  241. data/pages/app/assets/images/constructor_pages/photos.png +0 -0
  242. data/pages/app/controllers/constructor_pages/fields_controller.rb +60 -0
  243. data/pages/app/controllers/constructor_pages/pages_controller.rb +207 -0
  244. data/pages/app/controllers/constructor_pages/templates_controller.rb +71 -0
  245. data/pages/app/helpers/constructor_pages/fields_helper.rb +18 -0
  246. data/pages/app/helpers/constructor_pages/pages_helper.rb +15 -0
  247. data/pages/app/helpers/constructor_pages/templates_helper.rb +11 -0
  248. data/pages/app/models/constructor_pages/field.rb +60 -0
  249. data/pages/app/models/constructor_pages/page.rb +117 -0
  250. data/pages/app/models/constructor_pages/template.rb +30 -0
  251. data/pages/app/models/constructor_pages/types/boolean_type.rb +12 -0
  252. data/pages/app/models/constructor_pages/types/date_type.rb +16 -0
  253. data/pages/app/models/constructor_pages/types/float_type.rb +12 -0
  254. data/pages/app/models/constructor_pages/types/html_type.rb +12 -0
  255. data/pages/app/models/constructor_pages/types/image_type.rb +18 -0
  256. data/pages/app/models/constructor_pages/types/integer_type.rb +12 -0
  257. data/pages/app/models/constructor_pages/types/string_type.rb +12 -0
  258. data/pages/app/models/constructor_pages/types/text_type.rb +12 -0
  259. data/pages/app/views/constructor_pages/fields/_form.haml +28 -0
  260. data/pages/app/views/constructor_pages/fields/edit.haml +6 -0
  261. data/pages/app/views/constructor_pages/fields/new.haml +6 -0
  262. data/pages/app/views/constructor_pages/fields/types/_boolean.haml +1 -0
  263. data/pages/app/views/constructor_pages/fields/types/_date.haml +1 -0
  264. data/pages/app/views/constructor_pages/fields/types/_float.haml +1 -0
  265. data/pages/app/views/constructor_pages/fields/types/_html.haml +1 -0
  266. data/pages/app/views/constructor_pages/fields/types/_image.haml +4 -0
  267. data/pages/app/views/constructor_pages/fields/types/_integer.haml +1 -0
  268. data/pages/app/views/constructor_pages/fields/types/_string.haml +1 -0
  269. data/pages/app/views/constructor_pages/fields/types/_text.haml +1 -0
  270. data/pages/app/views/constructor_pages/pages/_breadcrumbs.haml +7 -0
  271. data/pages/app/views/constructor_pages/pages/_form.haml +98 -0
  272. data/pages/app/views/constructor_pages/pages/_menu.haml +8 -0
  273. data/pages/app/views/constructor_pages/pages/_submenu.haml +6 -0
  274. data/pages/app/views/constructor_pages/pages/edit.haml +6 -0
  275. data/pages/app/views/constructor_pages/pages/error_404.haml +23 -0
  276. data/pages/app/views/constructor_pages/pages/index.haml +50 -0
  277. data/pages/app/views/constructor_pages/pages/new.haml +6 -0
  278. data/pages/app/views/constructor_pages/pages/show.haml +5 -0
  279. data/pages/app/views/constructor_pages/pages/sitemap.haml +12 -0
  280. data/pages/app/views/constructor_pages/templates/_form.haml +48 -0
  281. data/pages/app/views/constructor_pages/templates/edit.haml +6 -0
  282. data/pages/app/views/constructor_pages/templates/index.haml +38 -0
  283. data/pages/app/views/constructor_pages/templates/new.haml +6 -0
  284. data/pages/config/initializers/dragonfly.rb +9 -0
  285. data/pages/config/locales/ru.yml +39 -0
  286. data/pages/config/routes.rb +34 -0
  287. data/pages/constructor-pages.gemspec +21 -0
  288. data/pages/db/migrate/10_create_html_types.rb +15 -0
  289. data/pages/db/migrate/11_create_image_types.rb +16 -0
  290. data/pages/db/migrate/12_add_default_template.rb +13 -0
  291. data/pages/db/migrate/1_create_pages.rb +27 -0
  292. data/pages/db/migrate/2_create_templates.rb +18 -0
  293. data/pages/db/migrate/3_create_fields.rb +17 -0
  294. data/pages/db/migrate/4_create_string_types.rb +15 -0
  295. data/pages/db/migrate/5_create_float_types.rb +15 -0
  296. data/pages/db/migrate/6_create_boolean_types.rb +15 -0
  297. data/pages/db/migrate/7_create_integer_types.rb +15 -0
  298. data/pages/db/migrate/8_create_text_types.rb +15 -0
  299. data/pages/db/migrate/9_create_date_types.rb +15 -0
  300. data/pages/lib/constructor-pages.rb +7 -0
  301. data/pages/lib/constructor_pages/engine.rb +6 -0
  302. data/pages/public/hello.txt +1 -0
  303. data/pages/spec/factories.rb +7 -0
  304. data/pages/spec/models/page_model_spec.rb +113 -0
  305. metadata +396 -0
@@ -0,0 +1,12 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ CKEDITOR.plugins.setLang("specialchar","tr",{euro:"Euro işareti",lsquo:"Sol tek tırnak işareti",rsquo:"Sağ tek tırnak işareti",ldquo:"Sol çift tırnak işareti",rdquo:"Sağ çift tırnak işareti",ndash:"En tire",mdash:"Em tire",iexcl:"Ters ünlem işareti",cent:"Cent işareti",pound:"Pound işareti",curren:"Para birimi işareti",yen:"Yen işareti",brvbar:"Kırık bar",sect:"Bölüm işareti",uml:"İki sesli harfin ayrılması",copy:"Telif hakkı işareti",ordf:"Dişil sıralı gösterge",laquo:"Sol-işaret çift açı tırnak işareti",
6
+ not:"Not işareti",reg:"Kayıtlı işareti",macr:"Makron",deg:"Derece işareti",sup2:"İkili üstsimge",sup3:"Üçlü üstsimge",acute:"Aksan işareti",micro:"Mikro işareti",para:"Pilcrow işareti",middot:"Orta nokta",cedil:"Kedilla",sup1:"Üstsimge",ordm:"Eril sıralı gösterge",raquo:"Sağ işaret çift açı tırnak işareti",frac14:"Bayağı kesrin dörtte biri",frac12:"Bayağı kesrin bir yarım",frac34:"Bayağı kesrin dörtte üç",iquest:"Ters soru işareti",Agrave:"Aksanlı latin harfi",Aacute:"Aşırı aksanıyla Latin harfi",
7
+ Acirc:"Çarpık Latin harfi",Atilde:"Tilde latin harfi",Auml:"Sesli harf ayrılımlıı latin harfi",Aring:"Halkalı latin büyük A harfi",AElig:"Latin büyük Æ harfi",Ccedil:"Latin büyük C harfi ile kedilla",Egrave:"Aksanlı latin büyük E harfi",Eacute:"Aşırı vurgulu latin büyük E harfi",Ecirc:"Çarpık latin büyük E harfi",Euml:"Sesli harf ayrılımlıı latin büyük E harfi",Igrave:"Aksanlı latin büyük I harfi",Iacute:"Aşırı aksanlı latin büyük I harfi",Icirc:"Çarpık latin büyük I harfi",Iuml:"Sesli harf ayrılımlıı latin büyük I harfi",
8
+ ETH:"Latin büyük Eth harfi",Ntilde:"Tildeli latin büyük N harfi",Ograve:"Aksanlı latin büyük O harfi",Oacute:"Aşırı aksanlı latin büyük O harfi",Ocirc:"Çarpık latin büyük O harfi",Otilde:"Tildeli latin büyük O harfi",Ouml:"Sesli harf ayrılımlı latin büyük O harfi",times:"Çarpma işareti",Oslash:"Vurgulu latin büyük O harfi",Ugrave:"Aksanlı latin büyük U harfi",Uacute:"Aşırı aksanlı latin büyük U harfi",Ucirc:"Çarpık latin büyük U harfi",Uuml:"Sesli harf ayrılımlı latin büyük U harfi",Yacute:"Aşırı aksanlı latin büyük Y harfi",
9
+ THORN:"Latin büyük Thorn harfi",szlig:"Latin küçük keskin s harfi",agrave:"Aksanlı latin küçük a harfi",aacute:"Aşırı aksanlı latin küçük a harfi",acirc:"Çarpık latin küçük a harfi",atilde:"Tildeli latin küçük a harfi",auml:"Sesli harf ayrılımlı latin küçük a harfi",aring:"Halkalı latin küçük a harfi",aelig:"Latin büyük æ harfi",ccedil:"Kedillalı latin küçük c harfi",egrave:"Aksanlı latin küçük e harfi",eacute:"Aşırı aksanlı latin küçük e harfi",ecirc:"Çarpık latin küçük e harfi",euml:"Sesli harf ayrılımlı latin küçük e harfi",
10
+ igrave:"Aksanlı latin küçük i harfi",iacute:"Aşırı aksanlı latin küçük i harfi",icirc:"Çarpık latin küçük i harfi",iuml:"Sesli harf ayrılımlı latin küçük i harfi",eth:"Latin küçük eth harfi",ntilde:"Tildeli latin küçük n harfi",ograve:"Aksanlı latin küçük o harfi",oacute:"Aşırı aksanlı latin küçük o harfi",ocirc:"Çarpık latin küçük o harfi",otilde:"Tildeli latin küçük o harfi",ouml:"Sesli harf ayrılımlı latin küçük o harfi",divide:"Bölme işareti",oslash:"Vurgulu latin küçük o harfi",ugrave:"Aksanlı latin küçük u harfi",
11
+ uacute:"Aşırı aksanlı latin küçük u harfi",ucirc:"Çarpık latin küçük u harfi",uuml:"Sesli harf ayrılımlı latin küçük u harfi",yacute:"Aşırı aksanlı latin küçük y harfi",thorn:"Latin küçük thorn harfi",yuml:"Sesli harf ayrılımlı latin küçük y harfi",OElig:"Latin büyük bağlı OE harfi",oelig:"Latin küçük bağlı oe harfi",372:"Çarpık latin büyük W harfi",374:"Çarpık latin büyük Y harfi",373:"Çarpık latin küçük w harfi",375:"Çarpık latin küçük y harfi",sbquo:"Tek düşük-9 tırnak işareti",8219:"Tek yüksek-ters-9 tırnak işareti",
12
+ bdquo:"Çift düşük-9 tırnak işareti",hellip:"Yatay elips",trade:"Marka tescili işareti",9658:"Siyah sağ işaret işaretçisi",bull:"Koyu nokta",rarr:"Sağa doğru ok",rArr:"Sağa doğru çift ok",hArr:"Sol, sağ çift ok",diams:"Siyah elmas takımı",asymp:"Hemen hemen eşit"});
@@ -0,0 +1,13 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ CKEDITOR.plugins.setLang("specialchar","ug",{euro:"ياۋرو بەلگىسى",lsquo:"يالاڭ پەش سول",rsquo:"يالاڭ پەش ئوڭ",ldquo:"قوش پەش سول",rdquo:"قوش پەش ئوڭ",ndash:"سىزىقچە",mdash:"سىزىق",iexcl:"ئۈندەش",cent:"تىيىن بەلگىسى",pound:"فوند ستېرلىڭ",curren:"پۇل بەلگىسى",yen:"ياپونىيە يىنى",brvbar:"ئۈزۈك بالداق",sect:"پاراگراف بەلگىسى",uml:"تاۋۇش ئايرىش بەلگىسى",copy:"نەشر ھوقۇقى بەلگىسى",ordf:"Feminine ordinal indicator",laquo:"قوش تىرناق سول",not:"غەيرى بەلگە",reg:"خەتلەتكەن تاۋار ماركىسى",macr:"سوزۇش بەلگىسى",
6
+ deg:"گىرادۇس بەلگىسى",sup2:"يۇقىرى ئىندېكىس 2",sup3:"يۇقىرى ئىندېكىس 3",acute:"ئۇرغۇ بەلگىسى",micro:"Micro sign",para:"ئابزاس بەلگىسى",middot:"ئوتتۇرا چېكىت",cedil:"ئاستىغا قوشۇلىدىغان بەلگە",sup1:"يۇقىرى ئىندېكىس 1",ordm:"Masculine ordinal indicator",raquo:"قوش تىرناق ئوڭ",frac14:"ئاددىي كەسىر تۆتتىن بىر",frac12:"ئاددىي كەسىر ئىككىدىن بىر",frac34:"ئاددىي كەسىر ئۈچتىن تۆرت",iquest:"Inverted question mark",Agrave:"Latin capital letter A with grave accent",Aacute:"Latin capital letter A with acute accent",
7
+ Acirc:"Latin capital letter A with circumflex",Atilde:"Latin capital letter A with tilde",Auml:"Latin capital letter A with diaeresis",Aring:"Latin capital letter A with ring above",AElig:"Latin Capital letter Æ",Ccedil:"Latin capital letter C with cedilla",Egrave:"Latin capital letter E with grave accent",Eacute:"Latin capital letter E with acute accent",Ecirc:"Latin capital letter E with circumflex",Euml:"Latin capital letter E with diaeresis",Igrave:"Latin capital letter I with grave accent",Iacute:"Latin capital letter I with acute accent",
8
+ Icirc:"Latin capital letter I with circumflex",Iuml:"Latin capital letter I with diaeresis",ETH:"Latin capital letter Eth",Ntilde:"Latin capital letter N with tilde",Ograve:"قوش پەش ئوڭ",Oacute:"Latin capital letter O with acute accent",Ocirc:"Latin capital letter O with circumflex",Otilde:"Latin capital letter O with tilde",Ouml:"Latin capital letter O with diaeresis",times:"Multiplication sign",Oslash:"Latin capital letter O with stroke",Ugrave:"Latin capital letter U with grave accent",Uacute:"Latin capital letter U with acute accent",
9
+ Ucirc:"Latin capital letter U with circumflex",Uuml:"Latin capital letter U with diaeresis",Yacute:"Latin capital letter Y with acute accent",THORN:"Latin capital letter Thorn",szlig:"Latin small letter sharp s",agrave:"Latin small letter a with grave accent",aacute:"Latin small letter a with acute accent",acirc:"Latin small letter a with circumflex",atilde:"Latin small letter a with tilde",auml:"Latin small letter a with diaeresis",aring:"Latin small letter a with ring above",aelig:"Latin small letter æ",
10
+ ccedil:"Latin small letter c with cedilla",egrave:"Latin small letter e with grave accent",eacute:"Latin small letter e with acute accent",ecirc:"Latin small letter e with circumflex",euml:"Latin small letter e with diaeresis",igrave:"Latin small letter i with grave accent",iacute:"Latin small letter i with acute accent",icirc:"Latin small letter i with circumflex",iuml:"Latin small letter i with diaeresis",eth:"Latin small letter eth",ntilde:"تىك موللاق سوئال بەلگىسى",ograve:"Latin small letter o with grave accent",
11
+ oacute:"Latin small letter o with acute accent",ocirc:"Latin small letter o with circumflex",otilde:"Latin small letter o with tilde",ouml:"Latin small letter o with diaeresis",divide:"Division sign",oslash:"Latin small letter o with stroke",ugrave:"Latin small letter u with grave accent",uacute:"Latin small letter u with acute accent",ucirc:"Latin small letter u with circumflex",uuml:"Latin small letter u with diaeresis",yacute:"Latin small letter y with acute accent",thorn:"Latin small letter thorn",
12
+ yuml:"Latin small letter y with diaeresis",OElig:"Latin capital ligature OE",oelig:"Latin small ligature oe",372:"Latin capital letter W with circumflex",374:"Latin capital letter Y with circumflex",373:"Latin small letter w with circumflex",375:"Latin small letter y with circumflex",sbquo:"Single low-9 quotation mark",8219:"Single high-reversed-9 quotation mark",bdquo:"Double low-9 quotation mark",hellip:"Horizontal ellipsis",trade:"Trade mark sign",9658:"Black right-pointing pointer",bull:"Bullet",
13
+ rarr:"ئوڭ يا ئوق",rArr:"ئوڭ قوش سىزىق يا ئوق",hArr:"ئوڭ سول قوش سىزىق يا ئوق",diams:"ئۇيۇل غىچ",asymp:"تەخمىنەن تەڭ"});
@@ -0,0 +1,9 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ CKEDITOR.plugins.setLang("specialchar","zh-cn",{euro:"欧元符号",lsquo:"左单引号",rsquo:"右单引号",ldquo:"左双引号",rdquo:"右双引号",ndash:"短划线",mdash:"破折号",iexcl:"竖翻叹号",cent:"分币标记",pound:"英镑标记",curren:"货币标记",yen:"日元标记",brvbar:"间断条",sect:"节标记",uml:"分音符",copy:"版权所有标记",ordf:"阴性顺序指示符",laquo:"左指双尖引号",not:"非标记",reg:"注册标记",macr:"长音符",deg:"度标记",sup2:"上标二",sup3:"上标三",acute:"锐音符",micro:"微符",para:"段落标记",middot:"中间点",cedil:"下加符",sup1:"上标一",ordm:"阳性顺序指示符",raquo:"右指双尖引号",frac14:"普通分数四分之一",frac12:"普通分数二分之一",frac34:"普通分数四分之三",iquest:"竖翻问号",
6
+ Agrave:"带抑音符的拉丁文大写字母 A",Aacute:"带锐音符的拉丁文大写字母 A",Acirc:"带扬抑符的拉丁文大写字母 A",Atilde:"带颚化符的拉丁文大写字母 A",Auml:"带分音符的拉丁文大写字母 A",Aring:"带上圆圈的拉丁文大写字母 A",AElig:"拉丁文大写字母 Ae",Ccedil:"带下加符的拉丁文大写字母 C",Egrave:"带抑音符的拉丁文大写字母 E",Eacute:"带锐音符的拉丁文大写字母 E",Ecirc:"带扬抑符的拉丁文大写字母 E",Euml:"带分音符的拉丁文大写字母 E",Igrave:"带抑音符的拉丁文大写字母 I",Iacute:"带锐音符的拉丁文大写字母 I",Icirc:"带扬抑符的拉丁文大写字母 I",Iuml:"带分音符的拉丁文大写字母 I",ETH:"拉丁文大写字母 Eth",Ntilde:"带颚化符的拉丁文大写字母 N",Ograve:"带抑音符的拉丁文大写字母 O",Oacute:"带锐音符的拉丁文大写字母 O",Ocirc:"带扬抑符的拉丁文大写字母 O",Otilde:"带颚化符的拉丁文大写字母 O",
7
+ Ouml:"带分音符的拉丁文大写字母 O",times:"乘号",Oslash:"带粗线的拉丁文大写字母 O",Ugrave:"带抑音符的拉丁文大写字母 U",Uacute:"带锐音符的拉丁文大写字母 U",Ucirc:"带扬抑符的拉丁文大写字母 U",Uuml:"带分音符的拉丁文大写字母 U",Yacute:"带抑音符的拉丁文大写字母 Y",THORN:"拉丁文大写字母 Thorn",szlig:"拉丁文小写字母清音 S",agrave:"带抑音符的拉丁文小写字母 A",aacute:"带锐音符的拉丁文小写字母 A",acirc:"带扬抑符的拉丁文小写字母 A",atilde:"带颚化符的拉丁文小写字母 A",auml:"带分音符的拉丁文小写字母 A",aring:"带上圆圈的拉丁文小写字母 A",aelig:"拉丁文小写字母 Ae",ccedil:"带下加符的拉丁文小写字母 C",egrave:"带抑音符的拉丁文小写字母 E",eacute:"带锐音符的拉丁文小写字母 E",ecirc:"带扬抑符的拉丁文小写字母 E",euml:"带分音符的拉丁文小写字母 E",igrave:"带抑音符的拉丁文小写字母 I",
8
+ iacute:"带锐音符的拉丁文小写字母 I",icirc:"带扬抑符的拉丁文小写字母 I",iuml:"带分音符的拉丁文小写字母 I",eth:"拉丁文小写字母 Eth",ntilde:"带颚化符的拉丁文小写字母 N",ograve:"带抑音符的拉丁文小写字母 O",oacute:"带锐音符的拉丁文小写字母 O",ocirc:"带扬抑符的拉丁文小写字母 O",otilde:"带颚化符的拉丁文小写字母 O",ouml:"带分音符的拉丁文小写字母 O",divide:"除号",oslash:"带粗线的拉丁文小写字母 O",ugrave:"带抑音符的拉丁文小写字母 U",uacute:"带锐音符的拉丁文小写字母 U",ucirc:"带扬抑符的拉丁文小写字母 U",uuml:"带分音符的拉丁文小写字母 U",yacute:"带抑音符的拉丁文小写字母 Y",thorn:"拉丁文小写字母 Thorn",yuml:"带分音符的拉丁文小写字母 Y",OElig:"拉丁文大写连字 Oe",oelig:"拉丁文小写连字 Oe",372:"带扬抑符的拉丁文大写字母 W",374:"带扬抑符的拉丁文大写字母 Y",
9
+ 373:"带扬抑符的拉丁文小写字母 W",375:"带扬抑符的拉丁文小写字母 Y",sbquo:"单下 9 形引号",8219:"单高横翻 9 形引号",bdquo:"双下 9 形引号",hellip:"水平省略号",trade:"商标标志",9658:"实心右指指针",bull:"加重号",rarr:"向右箭头",rArr:"向右双线箭头",hArr:"左右双线箭头",diams:"实心方块纸牌",asymp:"约等于"});
@@ -0,0 +1,14 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ CKEDITOR.dialog.add("specialchar",function(i){var e,l=i.lang.specialchar,k=function(c){var b,c=c.data?c.data.getTarget():new CKEDITOR.dom.element(c);if("a"==c.getName()&&(b=c.getChild(0).getHtml()))c.removeClass("cke_light_background"),e.hide(),c=i.document.createElement("span"),c.setHtml(b),i.insertText(c.getText())},m=CKEDITOR.tools.addFunction(k),j,g=function(c,b){var a,b=b||c.data.getTarget();"span"==b.getName()&&(b=b.getParent());if("a"==b.getName()&&(a=b.getChild(0).getHtml())){j&&d(null,j);
6
+ var f=e.getContentElement("info","htmlPreview").getElement();e.getContentElement("info","charPreview").getElement().setHtml(a);f.setHtml(CKEDITOR.tools.htmlEncode(a));b.getParent().addClass("cke_light_background");j=b}},d=function(c,b){b=b||c.data.getTarget();"span"==b.getName()&&(b=b.getParent());"a"==b.getName()&&(e.getContentElement("info","charPreview").getElement().setHtml(" "),e.getContentElement("info","htmlPreview").getElement().setHtml(" "),b.getParent().removeClass("cke_light_background"),
7
+ j=void 0)},n=CKEDITOR.tools.addFunction(function(c){var c=new CKEDITOR.dom.event(c),b=c.getTarget(),a;a=c.getKeystroke();var f="rtl"==i.lang.dir;switch(a){case 38:if(a=b.getParent().getParent().getPrevious())a=a.getChild([b.getParent().getIndex(),0]),a.focus(),d(null,b),g(null,a);c.preventDefault();break;case 40:if(a=b.getParent().getParent().getNext())if((a=a.getChild([b.getParent().getIndex(),0]))&&1==a.type)a.focus(),d(null,b),g(null,a);c.preventDefault();break;case 32:k({data:c});c.preventDefault();
8
+ break;case f?37:39:if(a=b.getParent().getNext())a=a.getChild(0),1==a.type?(a.focus(),d(null,b),g(null,a),c.preventDefault(!0)):d(null,b);else if(a=b.getParent().getParent().getNext())(a=a.getChild([0,0]))&&1==a.type?(a.focus(),d(null,b),g(null,a),c.preventDefault(!0)):d(null,b);break;case f?39:37:(a=b.getParent().getPrevious())?(a=a.getChild(0),a.focus(),d(null,b),g(null,a),c.preventDefault(!0)):(a=b.getParent().getParent().getPrevious())?(a=a.getLast().getChild(0),a.focus(),d(null,b),g(null,a),c.preventDefault(!0)):
9
+ d(null,b)}});return{title:l.title,minWidth:430,minHeight:280,buttons:[CKEDITOR.dialog.cancelButton],charColumns:17,onLoad:function(){for(var c=this.definition.charColumns,b=i.config.specialChars,a=CKEDITOR.tools.getNextId()+"_specialchar_table_label",f=['<table role="listbox" aria-labelledby="'+a+'" style="width: 320px; height: 100%; border-collapse: separate;" align="center" cellspacing="2" cellpadding="2" border="0">'],d=0,g=b.length,h,e;d<g;){f.push('<tr role="presentation">');for(var j=0;j<c;j++,
10
+ d++){if(h=b[d]){h instanceof Array?(e=h[1],h=h[0]):(e=h.replace("&","").replace(";","").replace("#",""),e=l[e]||h);var k="cke_specialchar_label_"+d+"_"+CKEDITOR.tools.getNextNumber();f.push('<td class="cke_dark_background" style="cursor: default" role="presentation"><a href="javascript: void(0);" role="option" aria-posinset="'+(d+1)+'"',' aria-setsize="'+g+'"',' aria-labelledby="'+k+'"',' class="cke_specialchar" title="',CKEDITOR.tools.htmlEncode(e),'" onkeydown="CKEDITOR.tools.callFunction( '+n+
11
+ ', event, this )" onclick="CKEDITOR.tools.callFunction('+m+', this); return false;" tabindex="-1"><span style="margin: 0 auto;cursor: inherit">'+h+'</span><span class="cke_voice_label" id="'+k+'">'+e+"</span></a>")}else f.push('<td class="cke_dark_background">&nbsp;');f.push("</td>")}f.push("</tr>")}f.push("</tbody></table>",'<span id="'+a+'" class="cke_voice_label">'+l.options+"</span>");this.getContentElement("info","charContainer").getElement().setHtml(f.join(""))},contents:[{id:"info",label:i.lang.common.generalTab,
12
+ title:i.lang.common.generalTab,padding:0,align:"top",elements:[{type:"hbox",align:"top",widths:["320px","90px"],children:[{type:"html",id:"charContainer",html:"",onMouseover:g,onMouseout:d,focus:function(){var c=this.getElement().getElementsByTag("a").getItem(0);setTimeout(function(){c.focus();g(null,c)},0)},onShow:function(){var c=this.getElement().getChild([0,0,0,0,0]);setTimeout(function(){c.focus();g(null,c)},0)},onLoad:function(c){e=c.sender}},{type:"hbox",align:"top",widths:["100%"],children:[{type:"vbox",
13
+ align:"top",children:[{type:"html",html:"<div></div>"},{type:"html",id:"charPreview",className:"cke_dark_background",style:"border:1px solid #eeeeee;font-size:28px;height:40px;width:70px;padding-top:9px;font-family:'Microsoft Sans Serif',Arial,Helvetica,Verdana;text-align:center;",html:"<div>&nbsp;</div>"},{type:"html",id:"htmlPreview",className:"cke_dark_background",style:"border:1px solid #eeeeee;font-size:14px;height:20px;width:70px;padding-top:2px;font-family:'Microsoft Sans Serif',Arial,Helvetica,Verdana;text-align:center;",
14
+ html:"<div>&nbsp;</div>"}]}]}]}]}]}});
@@ -0,0 +1,21 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ (function(){function r(a){for(var e=0,l=0,k=0,m,g=a.$.rows.length;k<g;k++){m=a.$.rows[k];for(var d=e=0,c,b=m.cells.length;d<b;d++)c=m.cells[d],e+=c.colSpan;e>l&&(l=e)}return l}function o(a){return function(){var e=this.getValue(),e=!!(CKEDITOR.dialog.validate.integer()(e)&&0<e);e||(alert(a),this.select());return e}}function n(a,e){var l=function(g){return new CKEDITOR.dom.element(g,a.document)},n=a.editable(),m=a.plugins.dialogadvtab;return{title:a.lang.table.title,minWidth:310,minHeight:CKEDITOR.env.ie?
6
+ 310:280,onLoad:function(){var g=this,a=g.getContentElement("advanced","advStyles");if(a)a.on("change",function(){var a=this.getStyle("width",""),b=g.getContentElement("info","txtWidth");b&&b.setValue(a,!0);a=this.getStyle("height","");(b=g.getContentElement("info","txtHeight"))&&b.setValue(a,!0)})},onShow:function(){var g=a.getSelection(),d=g.getRanges(),c,b=this.getContentElement("info","txtRows"),h=this.getContentElement("info","txtCols"),p=this.getContentElement("info","txtWidth"),f=this.getContentElement("info",
7
+ "txtHeight");"tableProperties"==e&&((g=g.getSelectedElement())&&g.is("table")?c=g:0<d.length&&(CKEDITOR.env.webkit&&d[0].shrink(CKEDITOR.NODE_ELEMENT),c=a.elementPath(d[0].getCommonAncestor(!0)).contains("table",1)),this._.selectedElement=c);c?(this.setupContent(c),b&&b.disable(),h&&h.disable()):(b&&b.enable(),h&&h.enable());p&&p.onChange();f&&f.onChange()},onOk:function(){var g=a.getSelection(),d=this._.selectedElement&&g.createBookmarks(),c=this._.selectedElement||l("table"),b={};this.commitContent(b,
8
+ c);if(b.info){b=b.info;if(!this._.selectedElement)for(var h=c.append(l("tbody")),e=parseInt(b.txtRows,10)||0,f=parseInt(b.txtCols,10)||0,i=0;i<e;i++)for(var j=h.append(l("tr")),k=0;k<f;k++){var m=j.append(l("td"));CKEDITOR.env.ie||m.append(l("br"))}e=b.selHeaders;if(!c.$.tHead&&("row"==e||"both"==e)){j=new CKEDITOR.dom.element(c.$.createTHead());h=c.getElementsByTag("tbody").getItem(0);h=h.getElementsByTag("tr").getItem(0);for(i=0;i<h.getChildCount();i++)f=h.getChild(i),f.type==CKEDITOR.NODE_ELEMENT&&
9
+ !f.data("cke-bookmark")&&(f.renameNode("th"),f.setAttribute("scope","col"));j.append(h.remove())}if(null!==c.$.tHead&&!("row"==e||"both"==e)){j=new CKEDITOR.dom.element(c.$.tHead);h=c.getElementsByTag("tbody").getItem(0);for(k=h.getFirst();0<j.getChildCount();){h=j.getFirst();for(i=0;i<h.getChildCount();i++)f=h.getChild(i),f.type==CKEDITOR.NODE_ELEMENT&&(f.renameNode("td"),f.removeAttribute("scope"));h.insertBefore(k)}j.remove()}if(!this.hasColumnHeaders&&("col"==e||"both"==e))for(j=0;j<c.$.rows.length;j++)f=
10
+ new CKEDITOR.dom.element(c.$.rows[j].cells[0]),f.renameNode("th"),f.setAttribute("scope","row");if(this.hasColumnHeaders&&!("col"==e||"both"==e))for(i=0;i<c.$.rows.length;i++)j=new CKEDITOR.dom.element(c.$.rows[i]),"tbody"==j.getParent().getName()&&(f=new CKEDITOR.dom.element(j.$.cells[0]),f.renameNode("td"),f.removeAttribute("scope"));b.txtHeight?c.setStyle("height",b.txtHeight):c.removeStyle("height");b.txtWidth?c.setStyle("width",b.txtWidth):c.removeStyle("width");c.getAttribute("style")||c.removeAttribute("style")}if(this._.selectedElement)try{g.selectBookmarks(d)}catch(n){}else a.insertElement(c),
11
+ setTimeout(function(){var g=new CKEDITOR.dom.element(c.$.rows[0].cells[0]),b=a.createRange();b.moveToPosition(g,CKEDITOR.POSITION_AFTER_START);b.select()},0)},contents:[{id:"info",label:a.lang.table.title,elements:[{type:"hbox",widths:[null,null],styles:["vertical-align:top"],children:[{type:"vbox",padding:0,children:[{type:"text",id:"txtRows","default":3,label:a.lang.table.rows,required:!0,controlStyle:"width:5em",validate:o(a.lang.table.invalidRows),setup:function(a){this.setValue(a.$.rows.length)},
12
+ commit:k},{type:"text",id:"txtCols","default":2,label:a.lang.table.columns,required:!0,controlStyle:"width:5em",validate:o(a.lang.table.invalidCols),setup:function(a){this.setValue(r(a))},commit:k},{type:"html",html:"&nbsp;"},{type:"select",id:"selHeaders",requiredContent:"th","default":"",label:a.lang.table.headers,items:[[a.lang.table.headersNone,""],[a.lang.table.headersRow,"row"],[a.lang.table.headersColumn,"col"],[a.lang.table.headersBoth,"both"]],setup:function(a){var d=this.getDialog();d.hasColumnHeaders=
13
+ !0;for(var c=0;c<a.$.rows.length;c++){var b=a.$.rows[c].cells[0];if(b&&"th"!=b.nodeName.toLowerCase()){d.hasColumnHeaders=!1;break}}null!==a.$.tHead?this.setValue(d.hasColumnHeaders?"both":"row"):this.setValue(d.hasColumnHeaders?"col":"")},commit:k},{type:"text",id:"txtBorder",requiredContent:"table[border]","default":a.filter.check("table[border]")?1:0,label:a.lang.table.border,controlStyle:"width:3em",validate:CKEDITOR.dialog.validate.number(a.lang.table.invalidBorder),setup:function(a){this.setValue(a.getAttribute("border")||
14
+ "")},commit:function(a,d){this.getValue()?d.setAttribute("border",this.getValue()):d.removeAttribute("border")}},{id:"cmbAlign",type:"select",requiredContent:"table[align]","default":"",label:a.lang.common.align,items:[[a.lang.common.notSet,""],[a.lang.common.alignLeft,"left"],[a.lang.common.alignCenter,"center"],[a.lang.common.alignRight,"right"]],setup:function(a){this.setValue(a.getAttribute("align")||"")},commit:function(a,d){this.getValue()?d.setAttribute("align",this.getValue()):d.removeAttribute("align")}}]},
15
+ {type:"vbox",padding:0,children:[{type:"hbox",widths:["5em"],children:[{type:"text",id:"txtWidth",requiredContent:"table{width}",controlStyle:"width:5em",label:a.lang.common.width,title:a.lang.common.cssLengthTooltip,"default":a.filter.check("table{width}")?500>n.getSize("width")?"100%":500:0,getValue:q,validate:CKEDITOR.dialog.validate.cssLength(a.lang.common.invalidCssLength.replace("%1",a.lang.common.width)),onChange:function(){var a=this.getDialog().getContentElement("advanced","advStyles");a&&
16
+ a.updateStyle("width",this.getValue())},setup:function(a){this.setValue(a.getStyle("width"))},commit:k}]},{type:"hbox",widths:["5em"],children:[{type:"text",id:"txtHeight",requiredContent:"table{height}",controlStyle:"width:5em",label:a.lang.common.height,title:a.lang.common.cssLengthTooltip,"default":"",getValue:q,validate:CKEDITOR.dialog.validate.cssLength(a.lang.common.invalidCssLength.replace("%1",a.lang.common.height)),onChange:function(){var a=this.getDialog().getContentElement("advanced","advStyles");
17
+ a&&a.updateStyle("height",this.getValue())},setup:function(a){(a=a.getStyle("height"))&&this.setValue(a)},commit:k}]},{type:"html",html:"&nbsp;"},{type:"text",id:"txtCellSpace",requiredContent:"table[cellspacing]",controlStyle:"width:3em",label:a.lang.table.cellSpace,"default":a.filter.check("table[cellspacing]")?1:0,validate:CKEDITOR.dialog.validate.number(a.lang.table.invalidCellSpacing),setup:function(a){this.setValue(a.getAttribute("cellSpacing")||"")},commit:function(a,d){this.getValue()?d.setAttribute("cellSpacing",
18
+ this.getValue()):d.removeAttribute("cellSpacing")}},{type:"text",id:"txtCellPad",requiredContent:"table[cellpadding]",controlStyle:"width:3em",label:a.lang.table.cellPad,"default":a.filter.check("table[cellpadding]")?1:0,validate:CKEDITOR.dialog.validate.number(a.lang.table.invalidCellPadding),setup:function(a){this.setValue(a.getAttribute("cellPadding")||"")},commit:function(a,d){this.getValue()?d.setAttribute("cellPadding",this.getValue()):d.removeAttribute("cellPadding")}}]}]},{type:"html",align:"right",
19
+ html:""},{type:"vbox",padding:0,children:[{type:"text",id:"txtCaption",requiredContent:"caption",label:a.lang.table.caption,setup:function(a){this.enable();a=a.getElementsByTag("caption");if(0<a.count()){var a=a.getItem(0),d=a.getFirst(CKEDITOR.dom.walker.nodeType(CKEDITOR.NODE_ELEMENT));d&&!d.equals(a.getBogus())?(this.disable(),this.setValue(a.getText())):(a=CKEDITOR.tools.trim(a.getText()),this.setValue(a))}},commit:function(e,d){if(this.isEnabled()){var c=this.getValue(),b=d.getElementsByTag("caption");
20
+ if(c)0<b.count()?(b=b.getItem(0),b.setHtml("")):(b=new CKEDITOR.dom.element("caption",a.document),d.getChildCount()?b.insertBefore(d.getFirst()):b.appendTo(d)),b.append(new CKEDITOR.dom.text(c,a.document));else if(0<b.count())for(c=b.count()-1;0<=c;c--)b.getItem(c).remove()}}},{type:"text",id:"txtSummary",requiredContent:"table[summary]",label:a.lang.table.summary,setup:function(a){this.setValue(a.getAttribute("summary")||"")},commit:function(a,d){this.getValue()?d.setAttribute("summary",this.getValue()):
21
+ d.removeAttribute("summary")}}]}]},m&&m.createAdvancedTab(a,null,"table")]}}var q=CKEDITOR.tools.cssLength,k=function(a){var e=this.id;a.info||(a.info={});a.info[e]=this.getValue()};CKEDITOR.dialog.add("table",function(a){return n(a,"table")});CKEDITOR.dialog.add("tableProperties",function(a){return n(a,"tableProperties")})})();
@@ -0,0 +1,16 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ CKEDITOR.dialog.add("cellProperties",function(f){var g=f.lang.table,c=g.cell,d=f.lang.common,h=CKEDITOR.dialog.validate,j=/^(\d+(?:\.\d+)?)(px|%)$/,e={type:"html",html:"&nbsp;"},k="rtl"==f.lang.dir,i=f.plugins.colordialog;return{title:c.title,minWidth:CKEDITOR.env.ie&&CKEDITOR.env.quirks?450:410,minHeight:CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.quirks)?230:220,contents:[{id:"info",label:c.title,accessKey:"I",elements:[{type:"hbox",widths:["40%","5%","40%"],children:[{type:"vbox",padding:0,
6
+ children:[{type:"hbox",widths:["70%","30%"],children:[{type:"text",id:"width",width:"100px",label:d.width,validate:h.number(c.invalidWidth),onLoad:function(){var a=this.getDialog().getContentElement("info","widthType").getElement(),b=this.getInputElement(),c=b.getAttribute("aria-labelledby");b.setAttribute("aria-labelledby",[c,a.$.id].join(" "))},setup:function(a){var b=parseInt(a.getAttribute("width"),10),a=parseInt(a.getStyle("width"),10);!isNaN(b)&&this.setValue(b);!isNaN(a)&&this.setValue(a)},
7
+ commit:function(a){var b=parseInt(this.getValue(),10),c=this.getDialog().getValueOf("info","widthType");isNaN(b)?a.removeStyle("width"):a.setStyle("width",b+c);a.removeAttribute("width")},"default":""},{type:"select",id:"widthType",label:f.lang.table.widthUnit,labelStyle:"visibility:hidden","default":"px",items:[[g.widthPx,"px"],[g.widthPc,"%"]],setup:function(a){(a=j.exec(a.getStyle("width")||a.getAttribute("width")))&&this.setValue(a[2])}}]},{type:"hbox",widths:["70%","30%"],children:[{type:"text",
8
+ id:"height",label:d.height,width:"100px","default":"",validate:h.number(c.invalidHeight),onLoad:function(){var a=this.getDialog().getContentElement("info","htmlHeightType").getElement(),b=this.getInputElement(),c=b.getAttribute("aria-labelledby");b.setAttribute("aria-labelledby",[c,a.$.id].join(" "))},setup:function(a){var b=parseInt(a.getAttribute("height"),10),a=parseInt(a.getStyle("height"),10);!isNaN(b)&&this.setValue(b);!isNaN(a)&&this.setValue(a)},commit:function(a){var b=parseInt(this.getValue(),
9
+ 10);isNaN(b)?a.removeStyle("height"):a.setStyle("height",CKEDITOR.tools.cssLength(b));a.removeAttribute("height")}},{id:"htmlHeightType",type:"html",html:"<br />"+g.widthPx}]},e,{type:"select",id:"wordWrap",label:c.wordWrap,"default":"yes",items:[[c.yes,"yes"],[c.no,"no"]],setup:function(a){var b=a.getAttribute("noWrap");("nowrap"==a.getStyle("white-space")||b)&&this.setValue("no")},commit:function(a){"no"==this.getValue()?a.setStyle("white-space","nowrap"):a.removeStyle("white-space");a.removeAttribute("noWrap")}},
10
+ e,{type:"select",id:"hAlign",label:c.hAlign,"default":"",items:[[d.notSet,""],[d.alignLeft,"left"],[d.alignCenter,"center"],[d.alignRight,"right"]],setup:function(a){var b=a.getAttribute("align");this.setValue(a.getStyle("text-align")||b||"")},commit:function(a){var b=this.getValue();b?a.setStyle("text-align",b):a.removeStyle("text-align");a.removeAttribute("align")}},{type:"select",id:"vAlign",label:c.vAlign,"default":"",items:[[d.notSet,""],[d.alignTop,"top"],[d.alignMiddle,"middle"],[d.alignBottom,
11
+ "bottom"],[c.alignBaseline,"baseline"]],setup:function(a){var b=a.getAttribute("vAlign"),a=a.getStyle("vertical-align");switch(a){case "top":case "middle":case "bottom":case "baseline":break;default:a=""}this.setValue(a||b||"")},commit:function(a){var b=this.getValue();b?a.setStyle("vertical-align",b):a.removeStyle("vertical-align");a.removeAttribute("vAlign")}}]},e,{type:"vbox",padding:0,children:[{type:"select",id:"cellType",label:c.cellType,"default":"td",items:[[c.data,"td"],[c.header,"th"]],
12
+ setup:function(a){this.setValue(a.getName())},commit:function(a){a.renameNode(this.getValue())}},e,{type:"text",id:"rowSpan",label:c.rowSpan,"default":"",validate:h.integer(c.invalidRowSpan),setup:function(a){(a=parseInt(a.getAttribute("rowSpan"),10))&&1!=a&&this.setValue(a)},commit:function(a){var b=parseInt(this.getValue(),10);b&&1!=b?a.setAttribute("rowSpan",this.getValue()):a.removeAttribute("rowSpan")}},{type:"text",id:"colSpan",label:c.colSpan,"default":"",validate:h.integer(c.invalidColSpan),
13
+ setup:function(a){(a=parseInt(a.getAttribute("colSpan"),10))&&1!=a&&this.setValue(a)},commit:function(a){var b=parseInt(this.getValue(),10);b&&1!=b?a.setAttribute("colSpan",this.getValue()):a.removeAttribute("colSpan")}},e,{type:"hbox",padding:0,widths:["60%","40%"],children:[{type:"text",id:"bgColor",label:c.bgColor,"default":"",setup:function(a){var b=a.getAttribute("bgColor");this.setValue(a.getStyle("background-color")||b)},commit:function(a){this.getValue()?a.setStyle("background-color",this.getValue()):
14
+ a.removeStyle("background-color");a.removeAttribute("bgColor")}},i?{type:"button",id:"bgColorChoose","class":"colorChooser",label:c.chooseColor,onLoad:function(){this.getElement().getParent().setStyle("vertical-align","bottom")},onClick:function(){f.getColorFromDialog(function(a){a&&this.getDialog().getContentElement("info","bgColor").setValue(a);this.focus()},this)}}:e]},e,{type:"hbox",padding:0,widths:["60%","40%"],children:[{type:"text",id:"borderColor",label:c.borderColor,"default":"",setup:function(a){var b=
15
+ a.getAttribute("borderColor");this.setValue(a.getStyle("border-color")||b)},commit:function(a){this.getValue()?a.setStyle("border-color",this.getValue()):a.removeStyle("border-color");a.removeAttribute("borderColor")}},i?{type:"button",id:"borderColorChoose","class":"colorChooser",label:c.chooseColor,style:(k?"margin-right":"margin-left")+": 10px",onLoad:function(){this.getElement().getParent().setStyle("vertical-align","bottom")},onClick:function(){f.getColorFromDialog(function(a){a&&this.getDialog().getContentElement("info",
16
+ "borderColor").setValue(a);this.focus()},this)}}:e]}]}]}]}],onShow:function(){this.cells=CKEDITOR.plugins.tabletools.getSelectedCells(this._.editor.getSelection());this.setupContent(this.cells[0])},onOk:function(){for(var a=this._.editor.getSelection(),b=a.createBookmarks(),c=this.cells,d=0;d<c.length;d++)this.commitContent(c[d]);this._.editor.forceNextSelectionCheck();a.selectBookmarks(b);this._.editor.selectionChange()}}});
@@ -0,0 +1,84 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+
6
+ .cke_tpl_list
7
+ {
8
+ border: #dcdcdc 2px solid;
9
+ background-color: #ffffff;
10
+ overflow-y: auto;
11
+ overflow-x: hidden;
12
+ width: 100%;
13
+ height: 220px;
14
+ }
15
+
16
+ .cke_tpl_item
17
+ {
18
+ margin: 5px;
19
+ padding: 7px;
20
+ border: #eeeeee 1px solid;
21
+ *width: 88%;
22
+ }
23
+
24
+ .cke_tpl_preview
25
+ {
26
+ border-collapse: separate;
27
+ text-indent:0;
28
+ width: 100%;
29
+ }
30
+ .cke_tpl_preview td
31
+ {
32
+ padding: 2px;
33
+ vertical-align: middle;
34
+ }
35
+ .cke_tpl_preview .cke_tpl_preview_img
36
+ {
37
+ width: 100px;
38
+ }
39
+ .cke_tpl_preview span
40
+ {
41
+ white-space: normal;
42
+ }
43
+
44
+ .cke_tpl_title
45
+ {
46
+ font-weight: bold;
47
+ }
48
+
49
+ .cke_tpl_list a:hover .cke_tpl_item,
50
+ .cke_tpl_list a:focus .cke_tpl_item,
51
+ .cke_tpl_list a:active .cke_tpl_item
52
+ {
53
+ border: #ff9933 1px solid;
54
+ background-color: #fffacd;
55
+ }
56
+
57
+ .cke_tpl_list a:hover *,
58
+ .cke_tpl_list a:focus *,
59
+ .cke_tpl_list a:active *
60
+ {
61
+ cursor: pointer;
62
+ }
63
+
64
+ /* IE6 contextual selectors childs won't get :hover transition until,
65
+ the hover style of the link itself contains certain CSS declarations.*/
66
+ .cke_browser_ie6 .cke_tpl_list a:active,
67
+ .cke_browser_ie6 .cke_tpl_list a:hover,
68
+ .cke_browser_ie6 .cke_tpl_list a:focus
69
+ {
70
+ background-position: 0 0;
71
+ }
72
+
73
+ .cke_hc .cke_tpl_list a:hover .cke_tpl_item,
74
+ .cke_hc .cke_tpl_list a:focus .cke_tpl_item,
75
+ .cke_hc .cke_tpl_list a:active .cke_tpl_item
76
+ {
77
+ border-width: 3px;
78
+ }
79
+
80
+ .cke_tpl_empty, .cke_tpl_loading
81
+ {
82
+ text-align: center;
83
+ padding: 5px;
84
+ }
@@ -0,0 +1,10 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ (function(){CKEDITOR.dialog.add("templates",function(c){function o(a,b){var k=CKEDITOR.dom.element.createFromHtml('<a href="javascript:void(0)" tabIndex="-1" role="option" ><div class="cke_tpl_item"></div></a>'),d='<table style="width:350px;" class="cke_tpl_preview" role="presentation"><tr>';a.image&&b&&(d+='<td class="cke_tpl_preview_img"><img src="'+CKEDITOR.getUrl(b+a.image)+'"'+(CKEDITOR.env.ie6Compat?' onload="this.width=this.width"':"")+' alt="" title=""></td>');d+='<td style="white-space:normal;"><span class="cke_tpl_title">'+
6
+ a.title+"</span><br/>";a.description&&(d+="<span>"+a.description+"</span>");k.getFirst().setHtml(d+"</td></tr></table>");k.on("click",function(){p(a.html)});return k}function p(a){var b=CKEDITOR.dialog.getCurrent();b.getValueOf("selectTpl","chkInsertOpt")?(c.fire("saveSnapshot"),c.setData(a,function(){b.hide();var a=c.createRange();a.moveToElementEditStart(c.editable());a.select();setTimeout(function(){c.fire("saveSnapshot")},0)})):(c.insertHtml(a),b.hide())}function i(a){var b=a.data.getTarget(),
7
+ c=g.equals(b);if(c||g.contains(b)){var d=a.data.getKeystroke(),f=g.getElementsByTag("a"),e;if(f){if(c)e=f.getItem(0);else switch(d){case 40:e=b.getNext();break;case 38:e=b.getPrevious();break;case 13:case 32:b.fire("click")}e&&(e.focus(),a.data.preventDefault())}}}var h=CKEDITOR.plugins.get("templates");CKEDITOR.document.appendStyleSheet(CKEDITOR.getUrl(h.path+"dialogs/templates.css"));var g,h="cke_tpl_list_label_"+CKEDITOR.tools.getNextNumber(),f=c.lang.templates,l=c.config;return{title:c.lang.templates.title,
8
+ minWidth:CKEDITOR.env.ie?440:400,minHeight:340,contents:[{id:"selectTpl",label:f.title,elements:[{type:"vbox",padding:5,children:[{id:"selectTplText",type:"html",html:"<span>"+f.selectPromptMsg+"</span>"},{id:"templatesList",type:"html",focus:!0,html:'<div class="cke_tpl_list" tabIndex="-1" role="listbox" aria-labelledby="'+h+'"><div class="cke_tpl_loading"><span></span></div></div><span class="cke_voice_label" id="'+h+'">'+f.options+"</span>"},{id:"chkInsertOpt",type:"checkbox",label:f.insertOption,
9
+ "default":l.templates_replaceContent}]}]}],buttons:[CKEDITOR.dialog.cancelButton],onShow:function(){var a=this.getContentElement("selectTpl","templatesList");g=a.getElement();CKEDITOR.loadTemplates(l.templates_files,function(){var b=(l.templates||"default").split(",");if(b.length){var c=g;c.setHtml("");for(var d=0,h=b.length;d<h;d++)for(var e=CKEDITOR.getTemplates(b[d]),i=e.imagesPath,e=e.templates,n=e.length,j=0;j<n;j++){var m=o(e[j],i);m.setAttribute("aria-posinset",j+1);m.setAttribute("aria-setsize",
10
+ n);c.append(m)}a.focus()}else g.setHtml('<div class="cke_tpl_empty"><span>'+f.emptyListMsg+"</span></div>")});this._.element.on("keydown",i)},onHide:function(){this._.element.removeListener("keydown",i)}}})})();
@@ -0,0 +1,6 @@
1
+ /*
2
+ Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ CKEDITOR.addTemplates("default",{imagesPath:CKEDITOR.getUrl(CKEDITOR.plugins.getPath("templates")+"templates/images/"),templates:[{title:"Image and Title",image:"template1.gif",description:"One main image with a title and text that surround the image.",html:'<h3><img style="margin-right: 10px" height="100" width="100" align="left"/>Type the title here</h3><p>Type the text here</p>'},{title:"Strange Template",image:"template2.gif",description:"A template that defines two colums, each one with a title, and some text.",
6
+ html:'<table cellspacing="0" cellpadding="0" style="width:100%" border="0"><tr><td style="width:50%"><h3>Title 1</h3></td><td></td><td style="width:50%"><h3>Title 2</h3></td></tr><tr><td>Text 1</td><td></td><td>Text 2</td></tr></table><p>More text goes here.</p>'},{title:"Text and Table",image:"template3.gif",description:"A title with some text and a table.",html:'<div style="width: 80%"><h3>Title goes here</h3><table style="width:150px;float: right" cellspacing="0" cellpadding="0" border="1"><caption style="border:solid 1px black"><strong>Table title</strong></caption></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr><tr><td>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td></tr></table><p>Type the text here</p></div>'}]});
@@ -0,0 +1,28 @@
1
+ Software License Agreement
2
+ ==========================
3
+
4
+ **CKEditor WSC Plugin**
5
+ Copyright &copy; 2012, [CKSource](http://cksource.com) - Frederico Knabben. All rights reserved.
6
+
7
+ Licensed under the terms of any of the following licenses at your choice:
8
+
9
+ * GNU General Public License Version 2 or later (the "GPL"):
10
+ http://www.gnu.org/licenses/gpl.html
11
+
12
+ * GNU Lesser General Public License Version 2.1 or later (the "LGPL"):
13
+ http://www.gnu.org/licenses/lgpl.html
14
+
15
+ * Mozilla Public License Version 1.1 or later (the "MPL"):
16
+ http://www.mozilla.org/MPL/MPL-1.1.html
17
+
18
+ You are not required to, but if you want to explicitly declare the license you have chosen to be bound to when using, reproducing, modifying and distributing this software, just include a text file titled "legal.txt" in your version of this software, indicating your license choice.
19
+
20
+ Sources of Intellectual Property Included in this plugin
21
+ --------------------------------------------------------
22
+
23
+ Where not otherwise indicated, all plugin content is authored by CKSource engineers and consists of CKSource-owned intellectual property. In some specific instances, the plugin will incorporate work done by developers outside of CKSource with their express permission.
24
+
25
+ Trademarks
26
+ ----------
27
+
28
+ CKEditor is a trademark of CKSource - Frederico Knabben. All other brand and product names are trademarks, registered trademarks or service marks of their respective holders.
@@ -0,0 +1,25 @@
1
+ CKEditor WebSpellChecker Plugin
2
+ ===============================
3
+
4
+ This plugin brings Web Spell Checker (WSC) into CKEditor.
5
+
6
+ WSC is "installation-less", using the web-services of [WebSpellChecker.net](http://www.webspellchecker.net/). It's an out of the box solution.
7
+
8
+ Installation
9
+ ------------
10
+
11
+ 1. Clone/copy this repository contents in a new "plugins/wsc" folder in your CKEditor installation.
12
+ 2. Enable the "wsc" plugin in the CKEditor configuration file (config.js):
13
+
14
+ config.extraPlugins = 'wsc';
15
+
16
+ That's all. WSC will appear on the editor toolbar and will be ready to use.
17
+
18
+ License
19
+ -------
20
+
21
+ Licensed under the terms of any of the following licenses at your choice: [GPL](http://www.gnu.org/licenses/gpl.html), [LGPL](http://www.gnu.org/licenses/lgpl.html) and [MPL](http://www.mozilla.org/MPL/MPL-1.1.html).
22
+
23
+ See LICENSE.md for more information.
24
+
25
+ Developed in cooperation with [WebSpellChecker.net](http://www.webspellchecker.net/).
@@ -0,0 +1,49 @@
1
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
+ <!--
3
+ Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved.
4
+ For licensing, see LICENSE.html or http://ckeditor.com/license
5
+ -->
6
+ <html>
7
+ <head>
8
+ <title></title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
10
+ <script type="text/javascript">
11
+
12
+ function gup( name )
13
+ {
14
+ name = name.replace( /[\[]/, '\\\[' ).replace( /[\]]/, '\\\]' ) ;
15
+ var regexS = '[\\?&]' + name + '=([^&#]*)' ;
16
+ var regex = new RegExp( regexS ) ;
17
+ var results = regex.exec( window.location.href ) ;
18
+
19
+ if ( results )
20
+ return results[ 1 ] ;
21
+ else
22
+ return '' ;
23
+ }
24
+
25
+ var interval;
26
+
27
+ function sendData2Master()
28
+ {
29
+ var destination = window.parent.parent ;
30
+ try
31
+ {
32
+ if ( destination.XDTMaster )
33
+ {
34
+ var t = destination.XDTMaster.read( [ gup( 'cmd' ), gup( 'data' ) ] ) ;
35
+ window.clearInterval( interval ) ;
36
+ }
37
+ }
38
+ catch (e) {}
39
+ }
40
+
41
+ function onLoad()
42
+ {
43
+ interval = window.setInterval( sendData2Master, 100 );
44
+ }
45
+
46
+ </script>
47
+ </head>
48
+ <body onload="onLoad()"><p></p></body>
49
+ </html>
@@ -0,0 +1,52 @@
1
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
2
+ <!--
3
+ Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved.
4
+ For licensing, see LICENSE.html or http://ckeditor.com/license
5
+ -->
6
+ <html>
7
+ <head>
8
+ <title></title>
9
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
10
+ <script type="text/javascript">
11
+
12
+ function doLoadScript( url )
13
+ {
14
+ if ( !url )
15
+ return false ;
16
+
17
+ var s = document.createElement( "script" ) ;
18
+ s.type = "text/javascript" ;
19
+ s.src = url ;
20
+ document.getElementsByTagName( "head" )[ 0 ].appendChild( s ) ;
21
+
22
+ return true ;
23
+ }
24
+
25
+ var opener;
26
+ function tryLoad()
27
+ {
28
+ opener = window.parent;
29
+
30
+ // get access to global parameters
31
+ var oParams = window.opener.oldFramesetPageParams;
32
+
33
+ // make frameset rows string prepare
34
+ var sFramesetRows = ( parseInt( oParams.firstframeh, 10 ) || '30') + ",*," + ( parseInt( oParams.thirdframeh, 10 ) || '150' ) + ',0' ;
35
+ document.getElementById( 'itFrameset' ).rows = sFramesetRows ;
36
+
37
+ // dynamic including init frames and crossdomain transport code
38
+ // from config sproxy_js_frameset url
39
+ var addScriptUrl = oParams.sproxy_js_frameset ;
40
+ doLoadScript( addScriptUrl ) ;
41
+ }
42
+
43
+ </script>
44
+ </head>
45
+
46
+ <frameset id="itFrameset" onload="tryLoad();" border="0" rows="30,*,*,0">
47
+ <frame scrolling="no" framespacing="0" frameborder="0" noresize="noresize" marginheight="0" marginwidth="2" src="" name="navbar"></frame>
48
+ <frame scrolling="auto" framespacing="0" frameborder="0" noresize="noresize" marginheight="0" marginwidth="0" src="" name="mid"></frame>
49
+ <frame scrolling="no" framespacing="0" frameborder="0" noresize="noresize" marginheight="1" marginwidth="1" src="" name="bot"></frame>
50
+ <frame scrolling="no" framespacing="0" frameborder="0" noresize="noresize" marginheight="1" marginwidth="1" src="" name="spellsuggestall"></frame>
51
+ </frameset>
52
+ </html>
@@ -0,0 +1,82 @@
1
+ /*
2
+ Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+
6
+ html, body
7
+ {
8
+ background-color: transparent;
9
+ margin: 0px;
10
+ padding: 0px;
11
+ }
12
+
13
+ body
14
+ {
15
+ padding: 10px;
16
+ }
17
+
18
+ body, td, input, select, textarea
19
+ {
20
+ font-size: 11px;
21
+ font-family: 'Microsoft Sans Serif' , Arial, Helvetica, Verdana;
22
+ }
23
+
24
+ .midtext
25
+ {
26
+ padding:0px;
27
+ margin:10px;
28
+ }
29
+
30
+ .midtext p
31
+ {
32
+ padding:0px;
33
+ margin:10px;
34
+ }
35
+
36
+ .Button
37
+ {
38
+ border: #737357 1px solid;
39
+ color: #3b3b1f;
40
+ background-color: #c7c78f;
41
+ }
42
+
43
+ .PopupTabArea
44
+ {
45
+ color: #737357;
46
+ background-color: #e3e3c7;
47
+ }
48
+
49
+ .PopupTitleBorder
50
+ {
51
+ border-bottom: #d5d59d 1px solid;
52
+ }
53
+ .PopupTabEmptyArea
54
+ {
55
+ padding-left: 10px;
56
+ border-bottom: #d5d59d 1px solid;
57
+ }
58
+
59
+ .PopupTab, .PopupTabSelected
60
+ {
61
+ border-right: #d5d59d 1px solid;
62
+ border-top: #d5d59d 1px solid;
63
+ border-left: #d5d59d 1px solid;
64
+ padding: 3px 5px 3px 5px;
65
+ color: #737357;
66
+ }
67
+
68
+ .PopupTab
69
+ {
70
+ margin-top: 1px;
71
+ border-bottom: #d5d59d 1px solid;
72
+ cursor: pointer;
73
+ }
74
+
75
+ .PopupTabSelected
76
+ {
77
+ font-weight: bold;
78
+ cursor: default;
79
+ padding-top: 4px;
80
+ border-bottom: #f1f1e3 1px solid;
81
+ background-color: #f1f1e3;
82
+ }
@@ -0,0 +1,11 @@
1
+ /*
2
+ Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved.
3
+ For licensing, see LICENSE.html or http://ckeditor.com/license
4
+ */
5
+ CKEDITOR.dialog.add("checkspell",function(a){function c(a,c){var d=0;return function(){"function"==typeof window.doSpell?("undefined"!=typeof e&&window.clearInterval(e),j(a)):180==d++&&window._cancelOnError(c)}}function j(c){var f=new window._SP_FCK_LangCompare,b=CKEDITOR.getUrl(a.plugins.wsc.path+"dialogs/"),e=b+"tmpFrameset.html";window.gFCKPluginName="wsc";f.setDefaulLangCode(a.config.defaultLanguage);window.doSpell({ctrl:g,lang:a.config.wsc_lang||f.getSPLangCode(a.langCode),intLang:a.config.wsc_uiLang||
6
+ f.getSPLangCode(a.langCode),winType:d,onCancel:function(){c.hide()},onFinish:function(b){a.focus();c.getParentEditor().setData(b.value);c.hide()},staticFrame:e,framesetPath:e,iframePath:b+"ciframe.html",schemaURI:b+"wsc.css",userDictionaryName:a.config.wsc_userDictionaryName,customDictionaryName:a.config.wsc_customDictionaryIds&&a.config.wsc_customDictionaryIds.split(","),domainName:a.config.wsc_domainName});CKEDITOR.document.getById(h).setStyle("display","none");CKEDITOR.document.getById(d).setStyle("display",
7
+ "block")}var b=CKEDITOR.tools.getNextNumber(),d="cke_frame_"+b,g="cke_data_"+b,h="cke_error_"+b,e,b=document.location.protocol||"http:",i=a.lang.wsc.notAvailable,k='<textarea style="display: none" id="'+g+'" rows="10" cols="40"> </textarea><div id="'+h+'" style="display:none;color:red;font-size:16px;font-weight:bold;padding-top:160px;text-align:center;z-index:11;"></div><iframe src="" style="width:100%;background-color:#f1f1e3;" frameborder="0" name="'+d+'" id="'+d+'" allowtransparency="1"></iframe>',
8
+ l=a.config.wsc_customLoaderScript||b+"//loader.webspellchecker.net/sproxy_fck/sproxy.php?plugin=fck2&customerid="+a.config.wsc_customerId+"&cmd=script&doc=wsc&schema=22";a.config.wsc_customLoaderScript&&(i+='<p style="color:#000;font-size:11px;font-weight: normal;text-align:center;padding-top:10px">'+a.lang.wsc.errorLoading.replace(/%s/g,a.config.wsc_customLoaderScript)+"</p>");window._cancelOnError=function(c){if("undefined"==typeof window.WSC_Error){CKEDITOR.document.getById(d).setStyle("display",
9
+ "none");var b=CKEDITOR.document.getById(h);b.setStyle("display","block");b.setHtml(c||a.lang.wsc.notAvailable)}};return{title:a.config.wsc_dialogTitle||a.lang.wsc.title,minWidth:485,minHeight:380,buttons:[CKEDITOR.dialog.cancelButton],onShow:function(){var b=this.getContentElement("general","content").getElement();b.setHtml(k);b.getChild(2).setStyle("height",this._.contentSize.height+"px");"function"!=typeof window.doSpell&&CKEDITOR.document.getHead().append(CKEDITOR.document.createElement("script",
10
+ {attributes:{type:"text/javascript",src:l}}));b=a.getData();CKEDITOR.document.getById(g).setValue(b);e=window.setInterval(c(this,i),250)},onHide:function(){window.ooo=void 0;window.int_framsetLoaded=void 0;window.framesetLoaded=void 0;window.is_window_opened=!1},contents:[{id:"general",label:a.config.wsc_dialogTitle||a.lang.wsc.title,padding:0,elements:[{type:"html",id:"content",html:""}]}]}});
11
+ CKEDITOR.dialog.on("resize",function(a){var a=a.data,c=a.dialog;"checkspell"==c._.name&&((c=(c=c.getContentElement("general","content").getElement())&&c.getChild(2))&&c.setSize("height",a.height),c&&c.setSize("width",a.width))});