bedrock_sass 0.1.9 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (534) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -5
  3. data/assets/_vendor/ace/ace.js +21635 -0
  4. data/assets/_vendor/ace/ext-beautify.js +318 -0
  5. data/assets/_vendor/ace/ext-elastic_tabstops_lite.js +277 -0
  6. data/assets/_vendor/ace/ext-emmet.js +1226 -0
  7. data/assets/_vendor/ace/ext-error_marker.js +10 -0
  8. data/assets/_vendor/ace/ext-keybinding_menu.js +189 -0
  9. data/assets/_vendor/ace/ext-language_tools.js +1997 -0
  10. data/assets/_vendor/ace/ext-linking.js +65 -0
  11. data/assets/_vendor/ace/ext-modelist.js +228 -0
  12. data/assets/_vendor/ace/ext-options.js +750 -0
  13. data/assets/_vendor/ace/ext-rtl.js +110 -0
  14. data/assets/_vendor/ace/ext-searchbox.js +512 -0
  15. data/assets/_vendor/ace/ext-settings_menu.js +771 -0
  16. data/assets/_vendor/ace/ext-spellcheck.js +75 -0
  17. data/assets/_vendor/ace/ext-split.js +208 -0
  18. data/assets/_vendor/ace/ext-static_highlight.js +226 -0
  19. data/assets/_vendor/ace/ext-statusbar.js +57 -0
  20. data/assets/_vendor/ace/ext-textarea.js +567 -0
  21. data/assets/_vendor/ace/ext-themelist.js +67 -0
  22. data/assets/_vendor/ace/ext-whitespace.js +210 -0
  23. data/assets/_vendor/ace/keybinding-emacs.js +1165 -0
  24. data/assets/_vendor/ace/keybinding-vim.js +5673 -0
  25. data/assets/_vendor/ace/mode-abap.js +222 -0
  26. data/assets/_vendor/ace/mode-abc.js +267 -0
  27. data/assets/_vendor/ace/mode-actionscript.js +274 -0
  28. data/assets/_vendor/ace/mode-ada.js +138 -0
  29. data/assets/_vendor/ace/mode-apache_conf.js +363 -0
  30. data/assets/_vendor/ace/mode-applescript.js +279 -0
  31. data/assets/_vendor/ace/mode-asciidoc.js +349 -0
  32. data/assets/_vendor/ace/mode-asl.js +422 -0
  33. data/assets/_vendor/ace/mode-assembly_x86.js +193 -0
  34. data/assets/_vendor/ace/mode-autohotkey.js +243 -0
  35. data/assets/_vendor/ace/mode-batchfile.js +230 -0
  36. data/assets/_vendor/ace/mode-bro.js +334 -0
  37. data/assets/_vendor/ace/mode-c9search.js +294 -0
  38. data/assets/_vendor/ace/mode-c_cpp.js +502 -0
  39. data/assets/_vendor/ace/mode-cirru.js +211 -0
  40. data/assets/_vendor/ace/mode-clojure.js +314 -0
  41. data/assets/_vendor/ace/mode-cobol.js +102 -0
  42. data/assets/_vendor/ace/mode-coffee.js +400 -0
  43. data/assets/_vendor/ace/mode-coldfusion.js +2596 -0
  44. data/assets/_vendor/ace/mode-csharp.js +502 -0
  45. data/assets/_vendor/ace/mode-csound_document.js +3749 -0
  46. data/assets/_vendor/ace/mode-csound_orchestra.js +2687 -0
  47. data/assets/_vendor/ace/mode-csound_score.js +454 -0
  48. data/assets/_vendor/ace/mode-csp.js +60 -0
  49. data/assets/_vendor/ace/mode-css.js +723 -0
  50. data/assets/_vendor/ace/mode-curly.js +2564 -0
  51. data/assets/_vendor/ace/mode-d.js +520 -0
  52. data/assets/_vendor/ace/mode-dart.js +703 -0
  53. data/assets/_vendor/ace/mode-diff.js +146 -0
  54. data/assets/_vendor/ace/mode-django.js +2594 -0
  55. data/assets/_vendor/ace/mode-dockerfile.js +498 -0
  56. data/assets/_vendor/ace/mode-dot.js +418 -0
  57. data/assets/_vendor/ace/mode-drools.js +496 -0
  58. data/assets/_vendor/ace/mode-edifact.js +165 -0
  59. data/assets/_vendor/ace/mode-eiffel.js +136 -0
  60. data/assets/_vendor/ace/mode-ejs.js +3026 -0
  61. data/assets/_vendor/ace/mode-elixir.js +501 -0
  62. data/assets/_vendor/ace/mode-elm.js +307 -0
  63. data/assets/_vendor/ace/mode-erlang.js +1009 -0
  64. data/assets/_vendor/ace/mode-forth.js +297 -0
  65. data/assets/_vendor/ace/mode-fortran.js +431 -0
  66. data/assets/_vendor/ace/mode-fsharp.js +314 -0
  67. data/assets/_vendor/ace/mode-ftl.js +1192 -0
  68. data/assets/_vendor/ace/mode-gcode.js +94 -0
  69. data/assets/_vendor/ace/mode-gherkin.js +172 -0
  70. data/assets/_vendor/ace/mode-gitignore.js +60 -0
  71. data/assets/_vendor/ace/mode-glsl.js +579 -0
  72. data/assets/_vendor/ace/mode-gobstones.js +929 -0
  73. data/assets/_vendor/ace/mode-golang.js +414 -0
  74. data/assets/_vendor/ace/mode-graphqlschema.js +214 -0
  75. data/assets/_vendor/ace/mode-groovy.js +986 -0
  76. data/assets/_vendor/ace/mode-haml.js +1555 -0
  77. data/assets/_vendor/ace/mode-handlebars.js +2622 -0
  78. data/assets/_vendor/ace/mode-haskell.js +379 -0
  79. data/assets/_vendor/ace/mode-haskell_cabal.js +142 -0
  80. data/assets/_vendor/ace/mode-haxe.js +386 -0
  81. data/assets/_vendor/ace/mode-hjson.js +353 -0
  82. data/assets/_vendor/ace/mode-html.js +2509 -0
  83. data/assets/_vendor/ace/mode-html_elixir.js +3087 -0
  84. data/assets/_vendor/ace/mode-html_ruby.js +3043 -0
  85. data/assets/_vendor/ace/mode-ini.js +163 -0
  86. data/assets/_vendor/ace/mode-io.js +253 -0
  87. data/assets/_vendor/ace/mode-jack.js +347 -0
  88. data/assets/_vendor/ace/mode-jade.js +2126 -0
  89. data/assets/_vendor/ace/mode-java.js +975 -0
  90. data/assets/_vendor/ace/mode-javascript.js +797 -0
  91. data/assets/_vendor/ace/mode-json.js +327 -0
  92. data/assets/_vendor/ace/mode-jsoniq.js +4940 -0
  93. data/assets/_vendor/ace/mode-jsp.js +1430 -0
  94. data/assets/_vendor/ace/mode-jssm.js +325 -0
  95. data/assets/_vendor/ace/mode-jsx.js +412 -0
  96. data/assets/_vendor/ace/mode-julia.js +303 -0
  97. data/assets/_vendor/ace/mode-kotlin.js +795 -0
  98. data/assets/_vendor/ace/mode-latex.js +297 -0
  99. data/assets/_vendor/ace/mode-less.js +841 -0
  100. data/assets/_vendor/ace/mode-liquid.js +1193 -0
  101. data/assets/_vendor/ace/mode-lisp.js +112 -0
  102. data/assets/_vendor/ace/mode-livescript.js +280 -0
  103. data/assets/_vendor/ace/mode-logiql.js +317 -0
  104. data/assets/_vendor/ace/mode-lsl.js +343 -0
  105. data/assets/_vendor/ace/mode-lua.js +432 -0
  106. data/assets/_vendor/ace/mode-luapage.js +3007 -0
  107. data/assets/_vendor/ace/mode-lucene.js +87 -0
  108. data/assets/_vendor/ace/mode-makefile.js +410 -0
  109. data/assets/_vendor/ace/mode-markdown.js +3189 -0
  110. data/assets/_vendor/ace/mode-mask.js +1802 -0
  111. data/assets/_vendor/ace/mode-matlab.js +264 -0
  112. data/assets/_vendor/ace/mode-maze.js +291 -0
  113. data/assets/_vendor/ace/mode-mel.js +263 -0
  114. data/assets/_vendor/ace/mode-mixal.js +123 -0
  115. data/assets/_vendor/ace/mode-mushcode.js +681 -0
  116. data/assets/_vendor/ace/mode-mysql.js +168 -0
  117. data/assets/_vendor/ace/mode-nix.js +646 -0
  118. data/assets/_vendor/ace/mode-nsis.js +312 -0
  119. data/assets/_vendor/ace/mode-objectivec.js +739 -0
  120. data/assets/_vendor/ace/mode-ocaml.js +422 -0
  121. data/assets/_vendor/ace/mode-pascal.js +205 -0
  122. data/assets/_vendor/ace/mode-perl.js +380 -0
  123. data/assets/_vendor/ace/mode-pgsql.js +1508 -0
  124. data/assets/_vendor/ace/mode-php.js +13088 -0
  125. data/assets/_vendor/ace/mode-php_laravel_blade.js +13289 -0
  126. data/assets/_vendor/ace/mode-pig.js +310 -0
  127. data/assets/_vendor/ace/mode-plain_text.js +33 -0
  128. data/assets/_vendor/ace/mode-powershell.js +418 -0
  129. data/assets/_vendor/ace/mode-praat.js +478 -0
  130. data/assets/_vendor/ace/mode-prolog.js +371 -0
  131. data/assets/_vendor/ace/mode-properties.js +81 -0
  132. data/assets/_vendor/ace/mode-protobuf.js +592 -0
  133. data/assets/_vendor/ace/mode-puppet.js +370 -0
  134. data/assets/_vendor/ace/mode-python.js +273 -0
  135. data/assets/_vendor/ace/mode-r.js +310 -0
  136. data/assets/_vendor/ace/mode-razor.js +2869 -0
  137. data/assets/_vendor/ace/mode-rdoc.js +243 -0
  138. data/assets/_vendor/ace/mode-red.js +450 -0
  139. data/assets/_vendor/ace/mode-redshift.js +361 -0
  140. data/assets/_vendor/ace/mode-rhtml.js +2806 -0
  141. data/assets/_vendor/ace/mode-rst.js +257 -0
  142. data/assets/_vendor/ace/mode-ruby.js +497 -0
  143. data/assets/_vendor/ace/mode-rust.js +279 -0
  144. data/assets/_vendor/ace/mode-sass.js +441 -0
  145. data/assets/_vendor/ace/mode-scad.js +414 -0
  146. data/assets/_vendor/ace/mode-scala.js +982 -0
  147. data/assets/_vendor/ace/mode-scheme.js +232 -0
  148. data/assets/_vendor/ace/mode-scss.js +606 -0
  149. data/assets/_vendor/ace/mode-sh.js +447 -0
  150. data/assets/_vendor/ace/mode-sjs.js +1014 -0
  151. data/assets/_vendor/ace/mode-slim.js +4736 -0
  152. data/assets/_vendor/ace/mode-smarty.js +2635 -0
  153. data/assets/_vendor/ace/mode-snippets.js +207 -0
  154. data/assets/_vendor/ace/mode-soy_template.js +2847 -0
  155. data/assets/_vendor/ace/mode-space.js +168 -0
  156. data/assets/_vendor/ace/mode-sparql.js +320 -0
  157. data/assets/_vendor/ace/mode-sql.js +111 -0
  158. data/assets/_vendor/ace/mode-sqlserver.js +444 -0
  159. data/assets/_vendor/ace/mode-stylus.js +471 -0
  160. data/assets/_vendor/ace/mode-svg.js +1581 -0
  161. data/assets/_vendor/ace/mode-swift.js +390 -0
  162. data/assets/_vendor/ace/mode-tcl.js +383 -0
  163. data/assets/_vendor/ace/mode-terraform.js +398 -0
  164. data/assets/_vendor/ace/mode-tex.js +159 -0
  165. data/assets/_vendor/ace/mode-text.js +10 -0
  166. data/assets/_vendor/ace/mode-textile.js +150 -0
  167. data/assets/_vendor/ace/mode-toml.js +154 -0
  168. data/assets/_vendor/ace/mode-tsx.js +887 -0
  169. data/assets/_vendor/ace/mode-turtle.js +296 -0
  170. data/assets/_vendor/ace/mode-twig.js +2693 -0
  171. data/assets/_vendor/ace/mode-typescript.js +868 -0
  172. data/assets/_vendor/ace/mode-vala.js +676 -0
  173. data/assets/_vendor/ace/mode-vbscript.js +207 -0
  174. data/assets/_vendor/ace/mode-velocity.js +2790 -0
  175. data/assets/_vendor/ace/mode-verilog.js +119 -0
  176. data/assets/_vendor/ace/mode-vhdl.js +118 -0
  177. data/assets/_vendor/ace/mode-wollok.js +911 -0
  178. data/assets/_vendor/ace/mode-xml.js +677 -0
  179. data/assets/_vendor/ace/mode-xquery.js +4922 -0
  180. data/assets/_vendor/ace/mode-yaml.js +300 -0
  181. data/assets/_vendor/ace/snippets/abap.js +15 -0
  182. data/assets/_vendor/ace/snippets/abc.js +46 -0
  183. data/assets/_vendor/ace/snippets/actionscript.js +172 -0
  184. data/assets/_vendor/ace/snippets/ada.js +15 -0
  185. data/assets/_vendor/ace/snippets/apache_conf.js +15 -0
  186. data/assets/_vendor/ace/snippets/applescript.js +15 -0
  187. data/assets/_vendor/ace/snippets/asciidoc.js +15 -0
  188. data/assets/_vendor/ace/snippets/asl.js +14 -0
  189. data/assets/_vendor/ace/snippets/assembly_x86.js +15 -0
  190. data/assets/_vendor/ace/snippets/autohotkey.js +15 -0
  191. data/assets/_vendor/ace/snippets/batchfile.js +15 -0
  192. data/assets/_vendor/ace/snippets/bro.js +15 -0
  193. data/assets/_vendor/ace/snippets/c9search.js +15 -0
  194. data/assets/_vendor/ace/snippets/c_cpp.js +146 -0
  195. data/assets/_vendor/ace/snippets/cirru.js +15 -0
  196. data/assets/_vendor/ace/snippets/clojure.js +105 -0
  197. data/assets/_vendor/ace/snippets/cobol.js +15 -0
  198. data/assets/_vendor/ace/snippets/coffee.js +110 -0
  199. data/assets/_vendor/ace/snippets/coldfusion.js +15 -0
  200. data/assets/_vendor/ace/snippets/csharp.js +15 -0
  201. data/assets/_vendor/ace/snippets/csound_document.js +25 -0
  202. data/assets/_vendor/ace/snippets/csound_orchestra.js +62 -0
  203. data/assets/_vendor/ace/snippets/csound_score.js +15 -0
  204. data/assets/_vendor/ace/snippets/csp.js +15 -0
  205. data/assets/_vendor/ace/snippets/css.js +982 -0
  206. data/assets/_vendor/ace/snippets/curly.js +15 -0
  207. data/assets/_vendor/ace/snippets/d.js +15 -0
  208. data/assets/_vendor/ace/snippets/dart.js +98 -0
  209. data/assets/_vendor/ace/snippets/diff.js +26 -0
  210. data/assets/_vendor/ace/snippets/django.js +123 -0
  211. data/assets/_vendor/ace/snippets/dockerfile.js +15 -0
  212. data/assets/_vendor/ace/snippets/dot.js +15 -0
  213. data/assets/_vendor/ace/snippets/drools.js +34 -0
  214. data/assets/_vendor/ace/snippets/edifact.js +255 -0
  215. data/assets/_vendor/ace/snippets/eiffel.js +15 -0
  216. data/assets/_vendor/ace/snippets/ejs.js +15 -0
  217. data/assets/_vendor/ace/snippets/elixir.js +15 -0
  218. data/assets/_vendor/ace/snippets/elm.js +15 -0
  219. data/assets/_vendor/ace/snippets/erlang.js +175 -0
  220. data/assets/_vendor/ace/snippets/forth.js +15 -0
  221. data/assets/_vendor/ace/snippets/fortran.js +15 -0
  222. data/assets/_vendor/ace/snippets/fsharp.js +15 -0
  223. data/assets/_vendor/ace/snippets/ftl.js +15 -0
  224. data/assets/_vendor/ace/snippets/gcode.js +15 -0
  225. data/assets/_vendor/ace/snippets/gherkin.js +15 -0
  226. data/assets/_vendor/ace/snippets/gitignore.js +15 -0
  227. data/assets/_vendor/ace/snippets/glsl.js +15 -0
  228. data/assets/_vendor/ace/snippets/gobstones.js +49 -0
  229. data/assets/_vendor/ace/snippets/golang.js +15 -0
  230. data/assets/_vendor/ace/snippets/graphqlschema.js +47 -0
  231. data/assets/_vendor/ace/snippets/groovy.js +15 -0
  232. data/assets/_vendor/ace/snippets/haml.js +35 -0
  233. data/assets/_vendor/ace/snippets/handlebars.js +15 -0
  234. data/assets/_vendor/ace/snippets/haskell.js +97 -0
  235. data/assets/_vendor/ace/snippets/haskell_cabal.js +15 -0
  236. data/assets/_vendor/ace/snippets/haxe.js +15 -0
  237. data/assets/_vendor/ace/snippets/hjson.js +15 -0
  238. data/assets/_vendor/ace/snippets/html.js +870 -0
  239. data/assets/_vendor/ace/snippets/html_elixir.js +15 -0
  240. data/assets/_vendor/ace/snippets/html_ruby.js +15 -0
  241. data/assets/_vendor/ace/snippets/ini.js +15 -0
  242. data/assets/_vendor/ace/snippets/io.js +77 -0
  243. data/assets/_vendor/ace/snippets/jack.js +15 -0
  244. data/assets/_vendor/ace/snippets/jade.js +15 -0
  245. data/assets/_vendor/ace/snippets/java.js +255 -0
  246. data/assets/_vendor/ace/snippets/javascript.js +210 -0
  247. data/assets/_vendor/ace/snippets/json.js +15 -0
  248. data/assets/_vendor/ace/snippets/jsoniq.js +76 -0
  249. data/assets/_vendor/ace/snippets/jsp.js +114 -0
  250. data/assets/_vendor/ace/snippets/jssm.js +15 -0
  251. data/assets/_vendor/ace/snippets/jsx.js +15 -0
  252. data/assets/_vendor/ace/snippets/julia.js +15 -0
  253. data/assets/_vendor/ace/snippets/kotlin.js +15 -0
  254. data/assets/_vendor/ace/snippets/latex.js +15 -0
  255. data/assets/_vendor/ace/snippets/less.js +15 -0
  256. data/assets/_vendor/ace/snippets/liquid.js +15 -0
  257. data/assets/_vendor/ace/snippets/lisp.js +15 -0
  258. data/assets/_vendor/ace/snippets/livescript.js +15 -0
  259. data/assets/_vendor/ace/snippets/logiql.js +15 -0
  260. data/assets/_vendor/ace/snippets/lsl.js +1247 -0
  261. data/assets/_vendor/ace/snippets/lua.js +36 -0
  262. data/assets/_vendor/ace/snippets/luapage.js +15 -0
  263. data/assets/_vendor/ace/snippets/lucene.js +15 -0
  264. data/assets/_vendor/ace/snippets/makefile.js +19 -0
  265. data/assets/_vendor/ace/snippets/markdown.js +103 -0
  266. data/assets/_vendor/ace/snippets/mask.js +15 -0
  267. data/assets/_vendor/ace/snippets/matlab.js +15 -0
  268. data/assets/_vendor/ace/snippets/maze.js +24 -0
  269. data/assets/_vendor/ace/snippets/mel.js +15 -0
  270. data/assets/_vendor/ace/snippets/mixal.js +15 -0
  271. data/assets/_vendor/ace/snippets/mushcode.js +15 -0
  272. data/assets/_vendor/ace/snippets/mysql.js +15 -0
  273. data/assets/_vendor/ace/snippets/nix.js +15 -0
  274. data/assets/_vendor/ace/snippets/nsis.js +15 -0
  275. data/assets/_vendor/ace/snippets/objectivec.js +15 -0
  276. data/assets/_vendor/ace/snippets/ocaml.js +15 -0
  277. data/assets/_vendor/ace/snippets/pascal.js +15 -0
  278. data/assets/_vendor/ace/snippets/perl.js +362 -0
  279. data/assets/_vendor/ace/snippets/pgsql.js +15 -0
  280. data/assets/_vendor/ace/snippets/php.js +398 -0
  281. data/assets/_vendor/ace/snippets/php_laravel_blade.js +15 -0
  282. data/assets/_vendor/ace/snippets/pig.js +15 -0
  283. data/assets/_vendor/ace/snippets/plain_text.js +15 -0
  284. data/assets/_vendor/ace/snippets/powershell.js +15 -0
  285. data/assets/_vendor/ace/snippets/praat.js +15 -0
  286. data/assets/_vendor/ace/snippets/prolog.js +15 -0
  287. data/assets/_vendor/ace/snippets/properties.js +15 -0
  288. data/assets/_vendor/ace/snippets/protobuf.js +15 -0
  289. data/assets/_vendor/ace/snippets/puppet.js +15 -0
  290. data/assets/_vendor/ace/snippets/python.js +173 -0
  291. data/assets/_vendor/ace/snippets/r.js +136 -0
  292. data/assets/_vendor/ace/snippets/razor.js +18 -0
  293. data/assets/_vendor/ace/snippets/rdoc.js +15 -0
  294. data/assets/_vendor/ace/snippets/red.js +15 -0
  295. data/assets/_vendor/ace/snippets/redshift.js +15 -0
  296. data/assets/_vendor/ace/snippets/rhtml.js +15 -0
  297. data/assets/_vendor/ace/snippets/rst.js +37 -0
  298. data/assets/_vendor/ace/snippets/ruby.js +943 -0
  299. data/assets/_vendor/ace/snippets/rust.js +15 -0
  300. data/assets/_vendor/ace/snippets/sass.js +15 -0
  301. data/assets/_vendor/ace/snippets/scad.js +15 -0
  302. data/assets/_vendor/ace/snippets/scala.js +15 -0
  303. data/assets/_vendor/ace/snippets/scheme.js +15 -0
  304. data/assets/_vendor/ace/snippets/scss.js +15 -0
  305. data/assets/_vendor/ace/snippets/sh.js +98 -0
  306. data/assets/_vendor/ace/snippets/sjs.js +15 -0
  307. data/assets/_vendor/ace/snippets/slim.js +15 -0
  308. data/assets/_vendor/ace/snippets/smarty.js +15 -0
  309. data/assets/_vendor/ace/snippets/snippets.js +24 -0
  310. data/assets/_vendor/ace/snippets/soy_template.js +15 -0
  311. data/assets/_vendor/ace/snippets/space.js +15 -0
  312. data/assets/_vendor/ace/snippets/sparql.js +15 -0
  313. data/assets/_vendor/ace/snippets/sql.js +41 -0
  314. data/assets/_vendor/ace/snippets/sqlserver.js +84 -0
  315. data/assets/_vendor/ace/snippets/stylus.js +15 -0
  316. data/assets/_vendor/ace/snippets/svg.js +15 -0
  317. data/assets/_vendor/ace/snippets/swift.js +15 -0
  318. data/assets/_vendor/ace/snippets/tcl.js +107 -0
  319. data/assets/_vendor/ace/snippets/terraform.js +15 -0
  320. data/assets/_vendor/ace/snippets/tex.js +205 -0
  321. data/assets/_vendor/ace/snippets/text.js +15 -0
  322. data/assets/_vendor/ace/snippets/textile.js +45 -0
  323. data/assets/_vendor/ace/snippets/toml.js +15 -0
  324. data/assets/_vendor/ace/snippets/tsx.js +15 -0
  325. data/assets/_vendor/ace/snippets/turtle.js +15 -0
  326. data/assets/_vendor/ace/snippets/twig.js +15 -0
  327. data/assets/_vendor/ace/snippets/typescript.js +15 -0
  328. data/assets/_vendor/ace/snippets/vala.js +201 -0
  329. data/assets/_vendor/ace/snippets/vbscript.js +15 -0
  330. data/assets/_vendor/ace/snippets/velocity.js +44 -0
  331. data/assets/_vendor/ace/snippets/verilog.js +15 -0
  332. data/assets/_vendor/ace/snippets/vhdl.js +15 -0
  333. data/assets/_vendor/ace/snippets/wollok.js +99 -0
  334. data/assets/_vendor/ace/snippets/xml.js +15 -0
  335. data/assets/_vendor/ace/snippets/xquery.js +76 -0
  336. data/assets/_vendor/ace/snippets/yaml.js +15 -0
  337. data/assets/_vendor/ace/theme-ambiance.js +185 -0
  338. data/assets/_vendor/ace/theme-chaos.js +164 -0
  339. data/assets/_vendor/ace/theme-chrome.js +136 -0
  340. data/assets/_vendor/ace/theme-clouds.js +103 -0
  341. data/assets/_vendor/ace/theme-clouds_midnight.js +104 -0
  342. data/assets/_vendor/ace/theme-cobalt.js +121 -0
  343. data/assets/_vendor/ace/theme-crimson_editor.js +126 -0
  344. data/assets/_vendor/ace/theme-dawn.js +116 -0
  345. data/assets/_vendor/ace/theme-dracula.js +136 -0
  346. data/assets/_vendor/ace/theme-dreamweaver.js +149 -0
  347. data/assets/_vendor/ace/theme-eclipse.js +106 -0
  348. data/assets/_vendor/ace/theme-github.js +110 -0
  349. data/assets/_vendor/ace/theme-gob.js +120 -0
  350. data/assets/_vendor/ace/theme-gruvbox.js +90 -0
  351. data/assets/_vendor/ace/theme-idle_fingers.js +104 -0
  352. data/assets/_vendor/ace/theme-iplastic.js +129 -0
  353. data/assets/_vendor/ace/theme-katzenmilch.js +129 -0
  354. data/assets/_vendor/ace/theme-kr_theme.js +112 -0
  355. data/assets/_vendor/ace/theme-kuroir.js +69 -0
  356. data/assets/_vendor/ace/theme-merbivore.js +103 -0
  357. data/assets/_vendor/ace/theme-merbivore_soft.js +104 -0
  358. data/assets/_vendor/ace/theme-mono_industrial.js +115 -0
  359. data/assets/_vendor/ace/theme-monokai.js +113 -0
  360. data/assets/_vendor/ace/theme-pastel_on_dark.js +116 -0
  361. data/assets/_vendor/ace/theme-solarized_dark.js +96 -0
  362. data/assets/_vendor/ace/theme-solarized_light.js +99 -0
  363. data/assets/_vendor/ace/theme-sqlserver.js +146 -0
  364. data/assets/_vendor/ace/theme-terminal.js +122 -0
  365. data/assets/_vendor/ace/theme-textmate.js +138 -0
  366. data/assets/_vendor/ace/theme-tomorrow.js +116 -0
  367. data/assets/_vendor/ace/theme-tomorrow_night.js +116 -0
  368. data/assets/_vendor/ace/theme-tomorrow_night_blue.js +114 -0
  369. data/assets/_vendor/ace/theme-tomorrow_night_bright.js +129 -0
  370. data/assets/_vendor/ace/theme-tomorrow_night_eighties.js +116 -0
  371. data/assets/_vendor/ace/theme-twilight.js +117 -0
  372. data/assets/_vendor/ace/theme-vibrant_ink.js +102 -0
  373. data/assets/_vendor/ace/theme-xcode.js +96 -0
  374. data/assets/_vendor/ace/worker-coffee.js +2165 -0
  375. data/assets/_vendor/ace/worker-css.js +8764 -0
  376. data/assets/_vendor/ace/worker-html.js +11614 -0
  377. data/assets/_vendor/ace/worker-javascript.js +12491 -0
  378. data/assets/_vendor/ace/worker-json.js +2396 -0
  379. data/assets/_vendor/ace/worker-lua.js +3637 -0
  380. data/assets/_vendor/ace/worker-php.js +4313 -0
  381. data/assets/_vendor/ace/worker-xml.js +3899 -0
  382. data/assets/_vendor/ace/worker-xquery.js +70688 -0
  383. data/assets/_vendor/motion-ui/_settings.scss +1 -0
  384. data/assets/_vendor/motion-ui/effects/_fade.scss +1 -4
  385. data/assets/_vendor/motion-ui/effects/_hinge.scss +4 -3
  386. data/assets/_vendor/motion-ui/effects/_shake.scss +1 -1
  387. data/assets/_vendor/motion-ui/effects/_slide.scss +4 -3
  388. data/assets/_vendor/motion-ui/effects/_spin.scss +4 -3
  389. data/assets/_vendor/motion-ui/effects/_wiggle.scss +1 -1
  390. data/assets/_vendor/motion-ui/effects/_zoom.scss +2 -2
  391. data/assets/_vendor/motion-ui/motion-ui.scss +2 -0
  392. data/assets/_vendor/motion-ui/transitions/_fade.scss +6 -4
  393. data/assets/_vendor/motion-ui/transitions/_hinge.scss +3 -2
  394. data/assets/_vendor/motion-ui/transitions/_slide.scss +3 -2
  395. data/assets/_vendor/motion-ui/transitions/_spin.scss +2 -1
  396. data/assets/_vendor/motion-ui/transitions/_zoom.scss +6 -4
  397. data/assets/_vendor/motion-ui/util/_animation.scss +1 -1
  398. data/assets/_vendor/motion-ui/util/_args.scss +2 -2
  399. data/assets/_vendor/motion-ui/util/_function.scss +94 -0
  400. data/assets/_vendor/motion-ui/util/_keyframe.scss +5 -5
  401. data/assets/_vendor/motion-ui/util/_series.scss +20 -17
  402. data/assets/_vendor/motion-ui/util/_string.scss +36 -0
  403. data/assets/_vendor/tinymce/plugins/advlist/plugin.js +136 -404
  404. data/assets/_vendor/tinymce/plugins/advlist/plugin.min.js +1 -1
  405. data/assets/_vendor/tinymce/plugins/anchor/plugin.js +103 -323
  406. data/assets/_vendor/tinymce/plugins/anchor/plugin.min.js +1 -1
  407. data/assets/_vendor/tinymce/plugins/autolink/plugin.js +153 -377
  408. data/assets/_vendor/tinymce/plugins/autolink/plugin.min.js +1 -1
  409. data/assets/_vendor/tinymce/plugins/autoresize/plugin.js +145 -427
  410. data/assets/_vendor/tinymce/plugins/autoresize/plugin.min.js +1 -1
  411. data/assets/_vendor/tinymce/plugins/autosave/plugin.js +197 -579
  412. data/assets/_vendor/tinymce/plugins/autosave/plugin.min.js +1 -1
  413. data/assets/_vendor/tinymce/plugins/bbcode/plugin.js +88 -251
  414. data/assets/_vendor/tinymce/plugins/bbcode/plugin.min.js +1 -1
  415. data/assets/_vendor/tinymce/plugins/charmap/plugin.js +1243 -818
  416. data/assets/_vendor/tinymce/plugins/charmap/plugin.min.js +1 -1
  417. data/assets/_vendor/tinymce/plugins/code/plugin.js +82 -326
  418. data/assets/_vendor/tinymce/plugins/code/plugin.min.js +1 -1
  419. data/assets/_vendor/tinymce/plugins/codesample/plugin.js +829 -1444
  420. data/assets/_vendor/tinymce/plugins/codesample/plugin.min.js +1 -1
  421. data/assets/_vendor/tinymce/plugins/colorpicker/plugin.js +111 -257
  422. data/assets/_vendor/tinymce/plugins/colorpicker/plugin.min.js +1 -1
  423. data/assets/_vendor/tinymce/plugins/contextmenu/plugin.js +141 -469
  424. data/assets/_vendor/tinymce/plugins/contextmenu/plugin.min.js +1 -1
  425. data/assets/_vendor/tinymce/plugins/directionality/plugin.js +57 -261
  426. data/assets/_vendor/tinymce/plugins/directionality/plugin.min.js +1 -1
  427. data/assets/_vendor/tinymce/plugins/emoticons/plugin.js +78 -247
  428. data/assets/_vendor/tinymce/plugins/emoticons/plugin.min.js +1 -1
  429. data/assets/_vendor/tinymce/plugins/fullpage/plugin.js +463 -906
  430. data/assets/_vendor/tinymce/plugins/fullpage/plugin.min.js +1 -1
  431. data/assets/_vendor/tinymce/plugins/fullscreen/plugin.js +149 -427
  432. data/assets/_vendor/tinymce/plugins/fullscreen/plugin.min.js +1 -1
  433. data/assets/_vendor/tinymce/plugins/help/plugin.js +634 -1434
  434. data/assets/_vendor/tinymce/plugins/help/plugin.min.js +1 -1
  435. data/assets/_vendor/tinymce/plugins/hr/plugin.js +29 -185
  436. data/assets/_vendor/tinymce/plugins/hr/plugin.min.js +1 -1
  437. data/assets/_vendor/tinymce/plugins/image/plugin.js +1147 -1508
  438. data/assets/_vendor/tinymce/plugins/image/plugin.min.js +1 -1
  439. data/assets/_vendor/tinymce/plugins/imagetools/plugin.js +3319 -4079
  440. data/assets/_vendor/tinymce/plugins/imagetools/plugin.min.js +1 -2
  441. data/assets/_vendor/tinymce/plugins/importcss/plugin.js +230 -543
  442. data/assets/_vendor/tinymce/plugins/importcss/plugin.min.js +1 -1
  443. data/assets/_vendor/tinymce/plugins/insertdatetime/plugin.js +151 -460
  444. data/assets/_vendor/tinymce/plugins/insertdatetime/plugin.min.js +1 -1
  445. data/assets/_vendor/tinymce/plugins/legacyoutput/plugin.js +204 -379
  446. data/assets/_vendor/tinymce/plugins/legacyoutput/plugin.min.js +1 -1
  447. data/assets/_vendor/tinymce/plugins/link/plugin.js +644 -1162
  448. data/assets/_vendor/tinymce/plugins/link/plugin.min.js +1 -1
  449. data/assets/_vendor/tinymce/plugins/lists/plugin.js +1005 -1875
  450. data/assets/_vendor/tinymce/plugins/lists/plugin.min.js +1 -1
  451. data/assets/_vendor/tinymce/plugins/media/plugin.js +1066 -1926
  452. data/assets/_vendor/tinymce/plugins/media/plugin.min.js +1 -1
  453. data/assets/_vendor/tinymce/plugins/nonbreaking/plugin.js +70 -298
  454. data/assets/_vendor/tinymce/plugins/nonbreaking/plugin.min.js +1 -1
  455. data/assets/_vendor/tinymce/plugins/noneditable/plugin.js +96 -294
  456. data/assets/_vendor/tinymce/plugins/noneditable/plugin.min.js +1 -1
  457. data/assets/_vendor/tinymce/plugins/pagebreak/plugin.js +92 -337
  458. data/assets/_vendor/tinymce/plugins/pagebreak/plugin.min.js +1 -1
  459. data/assets/_vendor/tinymce/plugins/paste/plugin.js +1363 -2801
  460. data/assets/_vendor/tinymce/plugins/paste/plugin.min.js +1 -1
  461. data/assets/_vendor/tinymce/plugins/preview/plugin.js +106 -393
  462. data/assets/_vendor/tinymce/plugins/preview/plugin.min.js +1 -1
  463. data/assets/_vendor/tinymce/plugins/print/plugin.js +29 -185
  464. data/assets/_vendor/tinymce/plugins/print/plugin.min.js +1 -1
  465. data/assets/_vendor/tinymce/plugins/save/plugin.js +100 -350
  466. data/assets/_vendor/tinymce/plugins/save/plugin.min.js +1 -1
  467. data/assets/_vendor/tinymce/plugins/searchreplace/plugin.js +491 -865
  468. data/assets/_vendor/tinymce/plugins/searchreplace/plugin.min.js +1 -1
  469. data/assets/_vendor/tinymce/plugins/spellchecker/plugin.js +630 -1292
  470. data/assets/_vendor/tinymce/plugins/spellchecker/plugin.min.js +1 -1
  471. data/assets/_vendor/tinymce/plugins/tabfocus/plugin.js +96 -391
  472. data/assets/_vendor/tinymce/plugins/tabfocus/plugin.min.js +1 -1
  473. data/assets/_vendor/tinymce/plugins/table/plugin.js +9537 -14920
  474. data/assets/_vendor/tinymce/plugins/table/plugin.min.js +1 -5
  475. data/assets/_vendor/tinymce/plugins/template/plugin.js +309 -771
  476. data/assets/_vendor/tinymce/plugins/template/plugin.min.js +1 -1
  477. data/assets/_vendor/tinymce/plugins/textcolor/plugin.js +319 -592
  478. data/assets/_vendor/tinymce/plugins/textcolor/plugin.min.js +1 -1
  479. data/assets/_vendor/tinymce/plugins/textpattern/plugin.js +326 -674
  480. data/assets/_vendor/tinymce/plugins/textpattern/plugin.min.js +1 -1
  481. data/assets/_vendor/tinymce/plugins/toc/plugin.js +199 -530
  482. data/assets/_vendor/tinymce/plugins/toc/plugin.min.js +1 -1
  483. data/assets/_vendor/tinymce/plugins/visualblocks/plugin.js +112 -436
  484. data/assets/_vendor/tinymce/plugins/visualblocks/plugin.min.js +1 -1
  485. data/assets/_vendor/tinymce/plugins/visualchars/plugin.js +428 -1248
  486. data/assets/_vendor/tinymce/plugins/visualchars/plugin.min.js +1 -1
  487. data/assets/_vendor/tinymce/plugins/wordcount/plugin.js +307 -699
  488. data/assets/_vendor/tinymce/plugins/wordcount/plugin.min.js +1 -1
  489. data/assets/_vendor/tinymce/skins/lightgray/content.inline.min.css +1 -1
  490. data/assets/_vendor/tinymce/skins/lightgray/content.min.css +1 -1
  491. data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.eot +0 -0
  492. data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.svg +1 -1
  493. data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.ttf +0 -0
  494. data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.woff +0 -0
  495. data/assets/_vendor/tinymce/skins/lightgray/skin.min.css +1 -1
  496. data/assets/_vendor/tinymce/skins/lightgray/skin.mobile.min.css +1 -1
  497. data/assets/_vendor/tinymce/themes/inlite/theme.js +9693 -18245
  498. data/assets/_vendor/tinymce/themes/inlite/theme.min.js +1 -5
  499. data/assets/_vendor/tinymce/themes/mobile/theme.js +12629 -22467
  500. data/assets/_vendor/tinymce/themes/mobile/theme.min.js +1 -8
  501. data/assets/_vendor/tinymce/themes/modern/theme.js +9510 -17780
  502. data/assets/_vendor/tinymce/themes/modern/theme.min.js +1 -5
  503. data/assets/_vendor/tinymce/tinymce.js +25087 -42606
  504. data/assets/_vendor/yoastseo/css/_icons.scss +7 -7
  505. data/assets/_vendor/yoastseo/css/_snippet-editor.scss +1 -1
  506. data/assets/bedrock/js/bedrock.js +1 -71697
  507. data/assets/bedrock/scss/_bedrock-components.scss +20 -0
  508. data/assets/bedrock/scss/_bedrock-settings.scss +12 -4
  509. data/assets/bedrock/scss/_foundation-settings.scss +4 -2
  510. data/assets/bedrock/scss/components/ace-editor.scss +21 -0
  511. data/assets/bedrock/scss/components/attachments-grid.scss +18 -15
  512. data/assets/bedrock/scss/components/date-picker.scss +146 -0
  513. data/assets/bedrock/scss/components/dropzone-upload.scss +7 -0
  514. data/assets/bedrock/scss/components/file-input.scss +7 -0
  515. data/assets/bedrock/scss/components/file-preview.scss +36 -0
  516. data/assets/bedrock/scss/components/frame-embed.scss +23 -0
  517. data/assets/bedrock/scss/components/global.scss +27 -0
  518. data/assets/bedrock/scss/components/helper-classes.scss +1 -0
  519. data/assets/bedrock/scss/components/icon-box.scss +38 -0
  520. data/assets/bedrock/scss/components/item-list.scss +66 -0
  521. data/assets/bedrock/scss/components/lists.scss +58 -0
  522. data/assets/bedrock/scss/components/off-canvas-menu.scss +27 -15
  523. data/assets/bedrock/scss/components/place-autocomplete.scss +90 -0
  524. data/assets/bedrock/scss/components/rrule-generator.scss +102 -0
  525. data/assets/bedrock/scss/components/rrule-reveal.scss +14 -0
  526. data/assets/bedrock/scss/components/select-box.scss +1 -0
  527. data/assets/bedrock/scss/components/seo-analysis.scss +5 -0
  528. data/assets/bedrock/scss/components/textarea.scss +14 -2
  529. data/assets/bedrock/scss/components/tiny-mce-editor.scss +5 -16
  530. data/lib/bedrock_sass.rb +5 -0
  531. data/lib/bedrock_sass/version.rb +1 -1
  532. data/lib/tasks/before_assets_precompile.rake +1 -0
  533. metadata +395 -4
  534. data/CODE_OF_CONDUCT.md +0 -74
@@ -1 +1 @@
1
- !function(){var a={},b=function(b){for(var c=a[b],e=c.deps,f=c.defn,g=e.length,h=new Array(g),i=0;i<g;++i)h[i]=d(e[i]);var j=f.apply(null,h);if(void 0===j)throw"module ["+b+"] returned undefined";c.instance=j},c=function(b,c,d){if("string"!=typeof b)throw"module id must be a string";if(void 0===c)throw"no dependencies for "+b;if(void 0===d)throw"no definition function for "+b;a[b]={deps:c,defn:d,instance:void 0}},d=function(c){var d=a[c];if(void 0===d)throw"module ["+c+"] was undefined";return void 0===d.instance&&b(c),d.instance},e=function(a,b){for(var c=a.length,e=new Array(c),f=0;f<c;++f)e[f]=d(a[f]);b.apply(null,e)},f={};f.bolt={module:{api:{define:c,require:e,demand:d}}};var g=c,h=function(a,b){g(a,[],function(){return b})};h("4",tinymce.util.Tools.resolve),g("1",["4"],function(a){return a("tinymce.PluginManager")}),g("7",["4"],function(a){return a("tinymce.dom.DOMUtils")}),g("8",["4"],function(a){return a("tinymce.util.Tools")}),g("6",[],function(){var a=function(a){return a.getParam("save_enablewhendirty",!0)},b=function(a){return!!a.getParam("save_onsavecallback")},c=function(a){return!!a.getParam("save_oncancelcallback")};return{enableWhenDirty:a,hasOnSaveCallback:b,hasOnCancelCallback:c}}),g("5",["7","8","6"],function(a,b,c){var d=function(a,b){a.notificationManager.open({text:a.translate(b),type:"error"})},e=function(b){var e;if(e=a.DOM.getParent(b.id,"form"),!c.enableWhenDirty(b)||b.isDirty())return b.save(),c.hasOnSaveCallback(b)?(b.execCallback("save_onsavecallback",b),void b.nodeChanged()):void(e?(b.setDirty(!1),e.onsubmit&&!e.onsubmit()||("function"==typeof e.submit?e.submit():d(b,"Error: Form submit field collision.")),b.nodeChanged()):d(b,"Error: No form element found."))},f=function(a){var d=b.trim(a.startContent);return c.hasOnCancelCallback(a)?void a.execCallback("save_oncancelcallback",a):(a.setContent(d),a.undoManager.clear(),void a.nodeChanged())};return{save:e,cancel:f}}),g("2",["5"],function(a){var b=function(b){b.addCommand("mceSave",function(){a.save(b)}),b.addCommand("mceCancel",function(){a.cancel(b)})};return{register:b}}),g("3",["6"],function(a){var b=function(b){return function(c){var d=c.control;b.on("nodeChange dirty",function(){d.disabled(a.enableWhenDirty(b)&&!b.isDirty())})}},c=function(a){a.addButton("save",{icon:"save",text:"Save",cmd:"mceSave",disabled:!0,onPostRender:b(a)}),a.addButton("cancel",{text:"Cancel",icon:!1,cmd:"mceCancel",disabled:!0,onPostRender:b(a)}),a.addShortcut("Meta+S","","mceSave")};return{register:c}}),g("0",["1","2","3"],function(a,b,c){return a.add("save",function(a){c.register(a),b.register(a)}),function(){}}),d("0")()}();
1
+ !function(){"use strict";var n=tinymce.util.Tools.resolve("tinymce.PluginManager"),t=tinymce.util.Tools.resolve("tinymce.dom.DOMUtils"),a=tinymce.util.Tools.resolve("tinymce.util.Tools"),o=function(n){return n.getParam("save_enablewhendirty",!0)},c=function(n){return!!n.getParam("save_onsavecallback")},i=function(n){return!!n.getParam("save_oncancelcallback")},r=function(n,e){n.notificationManager.open({text:n.translate(e),type:"error"})},e=function(n){var e;if(e=t.DOM.getParent(n.id,"form"),!o(n)||n.isDirty()){if(n.save(),c(n))return n.execCallback("save_onsavecallback",n),void n.nodeChanged();e?(n.setDirty(!1),e.onsubmit&&!e.onsubmit()||("function"==typeof e.submit?e.submit():r(n,"Error: Form submit field collision.")),n.nodeChanged()):r(n,"Error: No form element found.")}},l=function(n){var e=a.trim(n.startContent);i(n)?n.execCallback("save_oncancelcallback",n):(n.setContent(e),n.undoManager.clear(),n.nodeChanged())},d=function(n){n.addCommand("mceSave",function(){e(n)}),n.addCommand("mceCancel",function(){l(n)})},s=function(t){return function(n){var e=n.control;t.on("nodeChange dirty",function(){e.disabled(o(t)&&!t.isDirty())})}},u=function(n){n.addButton("save",{icon:"save",text:"Save",cmd:"mceSave",disabled:!0,onPostRender:s(n)}),n.addButton("cancel",{text:"Cancel",icon:!1,cmd:"mceCancel",disabled:!0,onPostRender:s(n)}),n.addShortcut("Meta+S","","mceSave")};n.add("save",function(n){u(n),d(n)})}();
@@ -1,279 +1,103 @@
1
1
  (function () {
2
+ var searchreplace = (function () {
3
+ 'use strict';
2
4
 
3
- var defs = {}; // id -> {dependencies, definition, instance (possibly undefined)}
4
-
5
- // Used when there is no 'main' module.
6
- // The name is probably (hopefully) unique so minification removes for releases.
7
- var register_3795 = function (id) {
8
- var module = dem(id);
9
- var fragments = id.split('.');
10
- var target = Function('return this;')();
11
- for (var i = 0; i < fragments.length - 1; ++i) {
12
- if (target[fragments[i]] === undefined)
13
- target[fragments[i]] = {};
14
- target = target[fragments[i]];
15
- }
16
- target[fragments[fragments.length - 1]] = module;
17
- };
18
-
19
- var instantiate = function (id) {
20
- var actual = defs[id];
21
- var dependencies = actual.deps;
22
- var definition = actual.defn;
23
- var len = dependencies.length;
24
- var instances = new Array(len);
25
- for (var i = 0; i < len; ++i)
26
- instances[i] = dem(dependencies[i]);
27
- var defResult = definition.apply(null, instances);
28
- if (defResult === undefined)
29
- throw 'module [' + id + '] returned undefined';
30
- actual.instance = defResult;
31
- };
32
-
33
- var def = function (id, dependencies, definition) {
34
- if (typeof id !== 'string')
35
- throw 'module id must be a string';
36
- else if (dependencies === undefined)
37
- throw 'no dependencies for ' + id;
38
- else if (definition === undefined)
39
- throw 'no definition function for ' + id;
40
- defs[id] = {
41
- deps: dependencies,
42
- defn: definition,
43
- instance: undefined
44
- };
45
- };
46
-
47
- var dem = function (id) {
48
- var actual = defs[id];
49
- if (actual === undefined)
50
- throw 'module [' + id + '] was undefined';
51
- else if (actual.instance === undefined)
52
- instantiate(id);
53
- return actual.instance;
54
- };
55
-
56
- var req = function (ids, callback) {
57
- var len = ids.length;
58
- var instances = new Array(len);
59
- for (var i = 0; i < len; ++i)
60
- instances[i] = dem(ids[i]);
61
- callback.apply(null, instances);
62
- };
63
-
64
- var ephox = {};
65
-
66
- ephox.bolt = {
67
- module: {
68
- api: {
69
- define: def,
70
- require: req,
71
- demand: dem
72
- }
73
- }
74
- };
75
-
76
- var define = def;
77
- var require = req;
78
- var demand = dem;
79
- // this helps with minification when using a lot of global references
80
- var defineGlobal = function (id, ref) {
81
- define(id, [], function () { return ref; });
82
- };
83
- /*jsc
84
- ["tinymce.plugins.searchreplace.Plugin","ephox.katamari.api.Cell","tinymce.core.PluginManager","tinymce.plugins.searchreplace.api.Api","tinymce.plugins.searchreplace.api.Commands","tinymce.plugins.searchreplace.ui.Buttons","global!tinymce.util.Tools.resolve","tinymce.plugins.searchreplace.core.Actions","tinymce.plugins.searchreplace.ui.Dialog","tinymce.core.util.Tools","tinymce.plugins.searchreplace.core.FindReplaceText"]
85
- jsc*/
86
- define(
87
- 'ephox.katamari.api.Cell',
88
-
89
- [
90
- ],
91
-
92
- function () {
93
- var Cell = function (initial) {
94
- var value = initial;
95
-
96
- var get = function () {
97
- return value;
98
- };
99
-
100
- var set = function (v) {
101
- value = v;
102
- };
103
-
104
- var clone = function () {
105
- return Cell(get());
106
- };
107
-
108
- return {
109
- get: get,
110
- set: set,
111
- clone: clone
112
- };
5
+ var Cell = function (initial) {
6
+ var value = initial;
7
+ var get = function () {
8
+ return value;
113
9
  };
10
+ var set = function (v) {
11
+ value = v;
12
+ };
13
+ var clone = function () {
14
+ return Cell(get());
15
+ };
16
+ return {
17
+ get: get,
18
+ set: set,
19
+ clone: clone
20
+ };
21
+ };
114
22
 
115
- return Cell;
116
- }
117
- );
118
-
119
- defineGlobal("global!tinymce.util.Tools.resolve", tinymce.util.Tools.resolve);
120
- /**
121
- * ResolveGlobal.js
122
- *
123
- * Released under LGPL License.
124
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
125
- *
126
- * License: http://www.tinymce.com/license
127
- * Contributing: http://www.tinymce.com/contributing
128
- */
129
-
130
- define(
131
- 'tinymce.core.PluginManager',
132
- [
133
- 'global!tinymce.util.Tools.resolve'
134
- ],
135
- function (resolve) {
136
- return resolve('tinymce.PluginManager');
137
- }
138
- );
23
+ var global = tinymce.util.Tools.resolve('tinymce.PluginManager');
139
24
 
140
- /**
141
- * ResolveGlobal.js
142
- *
143
- * Released under LGPL License.
144
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
145
- *
146
- * License: http://www.tinymce.com/license
147
- * Contributing: http://www.tinymce.com/contributing
148
- */
25
+ var global$1 = tinymce.util.Tools.resolve('tinymce.util.Tools');
149
26
 
150
- define(
151
- 'tinymce.core.util.Tools',
152
- [
153
- 'global!tinymce.util.Tools.resolve'
154
- ],
155
- function (resolve) {
156
- return resolve('tinymce.util.Tools');
27
+ function isContentEditableFalse(node) {
28
+ return node && node.nodeType === 1 && node.contentEditable === 'false';
157
29
  }
158
- );
159
-
160
- /**
161
- * FindReplaceText.js
162
- *
163
- * Released under LGPL License.
164
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
165
- *
166
- * License: http://www.tinymce.com/license
167
- * Contributing: http://www.tinymce.com/contributing
168
- */
169
-
170
- /*jshint smarttabs:true, undef:true, unused:true, latedef:true, curly:true, bitwise:true */
171
- /*eslint no-labels:0, no-constant-condition: 0 */
172
-
173
- define(
174
- 'tinymce.plugins.searchreplace.core.FindReplaceText',
175
- [
176
- ],
177
- function () {
178
- function isContentEditableFalse(node) {
179
- return node && node.nodeType === 1 && node.contentEditable === "false";
180
- }
181
-
182
- // Based on work developed by: James Padolsey http://james.padolsey.com
183
- // released under UNLICENSE that is compatible with LGPL
184
- // TODO: Handle contentEditable edgecase:
185
- // <p>text<span contentEditable="false">text<span contentEditable="true">text</span>text</span>text</p>
186
- function findAndReplaceDOMText(regex, node, replacementNode, captureGroup, schema) {
187
- var m, matches = [], text, count = 0, doc;
188
- var blockElementsMap, hiddenTextElementsMap, shortEndedElementsMap;
189
-
190
- doc = node.ownerDocument;
191
- blockElementsMap = schema.getBlockElements(); // H1-H6, P, TD etc
192
- hiddenTextElementsMap = schema.getWhiteSpaceElements(); // TEXTAREA, PRE, STYLE, SCRIPT
193
- shortEndedElementsMap = schema.getShortEndedElements(); // BR, IMG, INPUT
194
-
195
- function getMatchIndexes(m, captureGroup) {
196
- captureGroup = captureGroup || 0;
197
-
198
- if (!m[0]) {
199
- throw 'findAndReplaceDOMText cannot handle zero-length matches';
200
- }
201
-
202
- var index = m.index;
203
-
204
- if (captureGroup > 0) {
205
- var cg = m[captureGroup];
206
-
207
- if (!cg) {
208
- throw 'Invalid capture group';
209
- }
210
-
211
- index += m[0].indexOf(cg);
212
- m[0] = cg;
213
- }
214
-
215
- return [index, index + m[0].length, [m[0]]];
30
+ function findAndReplaceDOMText(regex, node, replacementNode, captureGroup, schema) {
31
+ var m;
32
+ var matches = [];
33
+ var text, count = 0, doc;
34
+ var blockElementsMap, hiddenTextElementsMap, shortEndedElementsMap;
35
+ doc = node.ownerDocument;
36
+ blockElementsMap = schema.getBlockElements();
37
+ hiddenTextElementsMap = schema.getWhiteSpaceElements();
38
+ shortEndedElementsMap = schema.getShortEndedElements();
39
+ function getMatchIndexes(m, captureGroup) {
40
+ captureGroup = captureGroup || 0;
41
+ if (!m[0]) {
42
+ throw new Error('findAndReplaceDOMText cannot handle zero-length matches');
216
43
  }
217
-
218
- function getText(node) {
219
- var txt;
220
-
221
- if (node.nodeType === 3) {
222
- return node.data;
223
- }
224
-
225
- if (hiddenTextElementsMap[node.nodeName] && !blockElementsMap[node.nodeName]) {
226
- return '';
227
- }
228
-
229
- txt = '';
230
-
231
- if (isContentEditableFalse(node)) {
232
- return '\n';
233
- }
234
-
235
- if (blockElementsMap[node.nodeName] || shortEndedElementsMap[node.nodeName]) {
236
- txt += '\n';
44
+ var index = m.index;
45
+ if (captureGroup > 0) {
46
+ var cg = m[captureGroup];
47
+ if (!cg) {
48
+ throw new Error('Invalid capture group');
237
49
  }
238
-
239
- if ((node = node.firstChild)) {
240
- do {
241
- txt += getText(node);
242
- } while ((node = node.nextSibling));
243
- }
244
-
245
- return txt;
50
+ index += m[0].indexOf(cg);
51
+ m[0] = cg;
246
52
  }
247
-
248
- function stepThroughMatches(node, matches, replaceFn) {
249
- var startNode, endNode, startNodeIndex,
250
- endNodeIndex, innerNodes = [], atIndex = 0, curNode = node,
251
- matchLocation = matches.shift(), matchIndex = 0;
252
-
253
- out: while (true) {
53
+ return [
54
+ index,
55
+ index + m[0].length,
56
+ [m[0]]
57
+ ];
58
+ }
59
+ function getText(node) {
60
+ var txt;
61
+ if (node.nodeType === 3) {
62
+ return node.data;
63
+ }
64
+ if (hiddenTextElementsMap[node.nodeName] && !blockElementsMap[node.nodeName]) {
65
+ return '';
66
+ }
67
+ txt = '';
68
+ if (isContentEditableFalse(node)) {
69
+ return '\n';
70
+ }
71
+ if (blockElementsMap[node.nodeName] || shortEndedElementsMap[node.nodeName]) {
72
+ txt += '\n';
73
+ }
74
+ if (node = node.firstChild) {
75
+ do {
76
+ txt += getText(node);
77
+ } while (node = node.nextSibling);
78
+ }
79
+ return txt;
80
+ }
81
+ function stepThroughMatches(node, matches, replaceFn) {
82
+ var startNode, endNode, startNodeIndex, endNodeIndex, innerNodes = [], atIndex = 0, curNode = node, matchLocation = matches.shift(), matchIndex = 0;
83
+ out:
84
+ while (true) {
254
85
  if (blockElementsMap[curNode.nodeName] || shortEndedElementsMap[curNode.nodeName] || isContentEditableFalse(curNode)) {
255
86
  atIndex++;
256
87
  }
257
-
258
88
  if (curNode.nodeType === 3) {
259
89
  if (!endNode && curNode.length + atIndex >= matchLocation[1]) {
260
- // We've found the ending
261
90
  endNode = curNode;
262
91
  endNodeIndex = matchLocation[1] - atIndex;
263
92
  } else if (startNode) {
264
- // Intersecting node
265
93
  innerNodes.push(curNode);
266
94
  }
267
-
268
95
  if (!startNode && curNode.length + atIndex > matchLocation[0]) {
269
- // We've found the match start
270
96
  startNode = curNode;
271
97
  startNodeIndex = matchLocation[0] - atIndex;
272
98
  }
273
-
274
99
  atIndex += curNode.length;
275
100
  }
276
-
277
101
  if (startNode && endNode) {
278
102
  curNode = replaceFn({
279
103
  startNode: startNode,
@@ -284,33 +108,24 @@ define(
284
108
  match: matchLocation[2],
285
109
  matchIndex: matchIndex
286
110
  });
287
-
288
- // replaceFn has to return the node that replaced the endNode
289
- // and then we step back so we can continue from the end of the
290
- // match:
291
- atIndex -= (endNode.length - endNodeIndex);
111
+ atIndex -= endNode.length - endNodeIndex;
292
112
  startNode = null;
293
113
  endNode = null;
294
114
  innerNodes = [];
295
115
  matchLocation = matches.shift();
296
116
  matchIndex++;
297
-
298
117
  if (!matchLocation) {
299
- break; // no more matches
118
+ break;
300
119
  }
301
120
  } else if ((!hiddenTextElementsMap[curNode.nodeName] || blockElementsMap[curNode.nodeName]) && curNode.firstChild) {
302
121
  if (!isContentEditableFalse(curNode)) {
303
- // Move down
304
122
  curNode = curNode.firstChild;
305
123
  continue;
306
124
  }
307
125
  } else if (curNode.nextSibling) {
308
- // Move forward:
309
126
  curNode = curNode.nextSibling;
310
127
  continue;
311
128
  }
312
-
313
- // Move forward or up:
314
129
  while (true) {
315
130
  if (curNode.nextSibling) {
316
131
  curNode = curNode.nextSibling;
@@ -322,656 +137,467 @@ define(
322
137
  }
323
138
  }
324
139
  }
325
- }
326
-
327
- /**
328
- * Generates the actual replaceFn which splits up text nodes
329
- * and inserts the replacement element.
330
- */
331
- function genReplacer(nodeName) {
332
- var makeReplacementNode;
333
-
334
- if (typeof nodeName !== 'function') {
335
- var stencilNode = nodeName.nodeType ? nodeName : doc.createElement(nodeName);
336
-
337
- makeReplacementNode = function (fill, matchIndex) {
338
- var clone = stencilNode.cloneNode(false);
339
-
340
- clone.setAttribute('data-mce-index', matchIndex);
341
-
342
- if (fill) {
343
- clone.appendChild(doc.createTextNode(fill));
344
- }
345
-
346
- return clone;
347
- };
348
- } else {
349
- makeReplacementNode = nodeName;
350
- }
351
-
352
- return function (range) {
353
- var before, after, parentNode, startNode = range.startNode,
354
- endNode = range.endNode, matchIndex = range.matchIndex;
355
-
356
- if (startNode === endNode) {
357
- var node = startNode;
358
-
359
- parentNode = node.parentNode;
360
- if (range.startNodeIndex > 0) {
361
- // Add `before` text node (before the match)
362
- before = doc.createTextNode(node.data.substring(0, range.startNodeIndex));
363
- parentNode.insertBefore(before, node);
364
- }
365
-
366
- // Create the replacement node:
367
- var el = makeReplacementNode(range.match[0], matchIndex);
368
- parentNode.insertBefore(el, node);
369
- if (range.endNodeIndex < node.length) {
370
- // Add `after` text node (after the match)
371
- after = doc.createTextNode(node.data.substring(range.endNodeIndex));
372
- parentNode.insertBefore(after, node);
373
- }
374
-
375
- node.parentNode.removeChild(node);
376
-
377
- return el;
378
- }
379
-
380
- // Replace startNode -> [innerNodes...] -> endNode (in that order)
381
- before = doc.createTextNode(startNode.data.substring(0, range.startNodeIndex));
382
- after = doc.createTextNode(endNode.data.substring(range.endNodeIndex));
383
- var elA = makeReplacementNode(startNode.data.substring(range.startNodeIndex), matchIndex);
384
- var innerEls = [];
385
-
386
- for (var i = 0, l = range.innerNodes.length; i < l; ++i) {
387
- var innerNode = range.innerNodes[i];
388
- var innerEl = makeReplacementNode(innerNode.data, matchIndex);
389
- innerNode.parentNode.replaceChild(innerEl, innerNode);
390
- innerEls.push(innerEl);
140
+ }
141
+ function genReplacer(nodeName) {
142
+ var makeReplacementNode;
143
+ if (typeof nodeName !== 'function') {
144
+ var stencilNode_1 = nodeName.nodeType ? nodeName : doc.createElement(nodeName);
145
+ makeReplacementNode = function (fill, matchIndex) {
146
+ var clone = stencilNode_1.cloneNode(false);
147
+ clone.setAttribute('data-mce-index', matchIndex);
148
+ if (fill) {
149
+ clone.appendChild(doc.createTextNode(fill));
391
150
  }
392
-
393
- var elB = makeReplacementNode(endNode.data.substring(0, range.endNodeIndex), matchIndex);
394
-
395
- parentNode = startNode.parentNode;
396
- parentNode.insertBefore(before, startNode);
397
- parentNode.insertBefore(elA, startNode);
398
- parentNode.removeChild(startNode);
399
-
400
- parentNode = endNode.parentNode;
401
- parentNode.insertBefore(elB, endNode);
402
- parentNode.insertBefore(after, endNode);
403
- parentNode.removeChild(endNode);
404
-
405
- return elB;
151
+ return clone;
406
152
  };
153
+ } else {
154
+ makeReplacementNode = nodeName;
407
155
  }
408
-
409
- text = getText(node);
410
- if (!text) {
411
- return;
412
- }
413
-
414
- if (regex.global) {
415
- while ((m = regex.exec(text))) {
416
- matches.push(getMatchIndexes(m, captureGroup));
156
+ return function (range) {
157
+ var before;
158
+ var after;
159
+ var parentNode;
160
+ var startNode = range.startNode;
161
+ var endNode = range.endNode;
162
+ var matchIndex = range.matchIndex;
163
+ if (startNode === endNode) {
164
+ var node_1 = startNode;
165
+ parentNode = node_1.parentNode;
166
+ if (range.startNodeIndex > 0) {
167
+ before = doc.createTextNode(node_1.data.substring(0, range.startNodeIndex));
168
+ parentNode.insertBefore(before, node_1);
169
+ }
170
+ var el = makeReplacementNode(range.match[0], matchIndex);
171
+ parentNode.insertBefore(el, node_1);
172
+ if (range.endNodeIndex < node_1.length) {
173
+ after = doc.createTextNode(node_1.data.substring(range.endNodeIndex));
174
+ parentNode.insertBefore(after, node_1);
175
+ }
176
+ node_1.parentNode.removeChild(node_1);
177
+ return el;
417
178
  }
418
- } else {
419
- m = text.match(regex);
179
+ before = doc.createTextNode(startNode.data.substring(0, range.startNodeIndex));
180
+ after = doc.createTextNode(endNode.data.substring(range.endNodeIndex));
181
+ var elA = makeReplacementNode(startNode.data.substring(range.startNodeIndex), matchIndex);
182
+ var innerEls = [];
183
+ for (var i = 0, l = range.innerNodes.length; i < l; ++i) {
184
+ var innerNode = range.innerNodes[i];
185
+ var innerEl = makeReplacementNode(innerNode.data, matchIndex);
186
+ innerNode.parentNode.replaceChild(innerEl, innerNode);
187
+ innerEls.push(innerEl);
188
+ }
189
+ var elB = makeReplacementNode(endNode.data.substring(0, range.endNodeIndex), matchIndex);
190
+ parentNode = startNode.parentNode;
191
+ parentNode.insertBefore(before, startNode);
192
+ parentNode.insertBefore(elA, startNode);
193
+ parentNode.removeChild(startNode);
194
+ parentNode = endNode.parentNode;
195
+ parentNode.insertBefore(elB, endNode);
196
+ parentNode.insertBefore(after, endNode);
197
+ parentNode.removeChild(endNode);
198
+ return elB;
199
+ };
200
+ }
201
+ text = getText(node);
202
+ if (!text) {
203
+ return;
204
+ }
205
+ if (regex.global) {
206
+ while (m = regex.exec(text)) {
420
207
  matches.push(getMatchIndexes(m, captureGroup));
421
208
  }
422
-
423
- if (matches.length) {
424
- count = matches.length;
425
- stepThroughMatches(node, matches, genReplacer(replacementNode));
426
- }
427
-
428
- return count;
209
+ } else {
210
+ m = text.match(regex);
211
+ matches.push(getMatchIndexes(m, captureGroup));
429
212
  }
430
-
431
- return {
432
- findAndReplaceDOMText: findAndReplaceDOMText
433
- };
213
+ if (matches.length) {
214
+ count = matches.length;
215
+ stepThroughMatches(node, matches, genReplacer(replacementNode));
216
+ }
217
+ return count;
434
218
  }
435
- );
436
- /**
437
- * Actions.js
438
- *
439
- * Released under LGPL License.
440
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
441
- *
442
- * License: http://www.tinymce.com/license
443
- * Contributing: http://www.tinymce.com/contributing
444
- */
445
-
446
- define(
447
- 'tinymce.plugins.searchreplace.core.Actions',
448
- [
449
- 'tinymce.core.util.Tools',
450
- 'tinymce.plugins.searchreplace.core.FindReplaceText'
451
- ],
452
- function (Tools, FindReplaceText) {
453
- var getElmIndex = function (elm) {
454
- var value = elm.getAttribute('data-mce-index');
455
-
456
- if (typeof value === "number") {
457
- return "" + value;
458
- }
459
-
460
- return value;
461
- };
462
-
463
- var markAllMatches = function (editor, currentIndexState, regex) {
464
- var node, marker;
465
-
466
- marker = editor.dom.create('span', {
467
- 'data-mce-bogus': 1
468
- });
469
-
470
- marker.className = 'mce-match-marker'; // IE 7 adds class="mce-match-marker" and class=mce-match-marker
471
- node = editor.getBody();
472
-
473
- done(editor, currentIndexState, false);
474
-
475
- return FindReplaceText.findAndReplaceDOMText(regex, node, marker, false, editor.schema);
476
- };
477
-
478
- var unwrap = function (node) {
479
- var parentNode = node.parentNode;
219
+ var $_g9bydlk0jm0ofzvp = { findAndReplaceDOMText: findAndReplaceDOMText };
480
220
 
481
- if (node.firstChild) {
482
- parentNode.insertBefore(node.firstChild, node);
483
- }
484
-
485
- node.parentNode.removeChild(node);
486
- };
487
-
488
- var findSpansByIndex = function (editor, index) {
489
- var nodes, spans = [];
490
-
491
- nodes = Tools.toArray(editor.getBody().getElementsByTagName('span'));
492
- if (nodes.length) {
493
- for (var i = 0; i < nodes.length; i++) {
494
- var nodeIndex = getElmIndex(nodes[i]);
495
-
496
- if (nodeIndex === null || !nodeIndex.length) {
497
- continue;
498
- }
499
-
500
- if (nodeIndex === index.toString()) {
501
- spans.push(nodes[i]);
502
- }
221
+ var getElmIndex = function (elm) {
222
+ var value = elm.getAttribute('data-mce-index');
223
+ if (typeof value === 'number') {
224
+ return '' + value;
225
+ }
226
+ return value;
227
+ };
228
+ var markAllMatches = function (editor, currentIndexState, regex) {
229
+ var node, marker;
230
+ marker = editor.dom.create('span', { 'data-mce-bogus': 1 });
231
+ marker.className = 'mce-match-marker';
232
+ node = editor.getBody();
233
+ done(editor, currentIndexState, false);
234
+ return $_g9bydlk0jm0ofzvp.findAndReplaceDOMText(regex, node, marker, false, editor.schema);
235
+ };
236
+ var unwrap = function (node) {
237
+ var parentNode = node.parentNode;
238
+ if (node.firstChild) {
239
+ parentNode.insertBefore(node.firstChild, node);
240
+ }
241
+ node.parentNode.removeChild(node);
242
+ };
243
+ var findSpansByIndex = function (editor, index) {
244
+ var nodes;
245
+ var spans = [];
246
+ nodes = global$1.toArray(editor.getBody().getElementsByTagName('span'));
247
+ if (nodes.length) {
248
+ for (var i = 0; i < nodes.length; i++) {
249
+ var nodeIndex = getElmIndex(nodes[i]);
250
+ if (nodeIndex === null || !nodeIndex.length) {
251
+ continue;
252
+ }
253
+ if (nodeIndex === index.toString()) {
254
+ spans.push(nodes[i]);
503
255
  }
504
256
  }
505
-
506
- return spans;
507
- };
508
-
509
- var moveSelection = function (editor, currentIndexState, forward) {
510
- var testIndex = currentIndexState.get(), dom = editor.dom;
511
-
512
- forward = forward !== false;
513
-
514
- if (forward) {
515
- testIndex++;
516
- } else {
517
- testIndex--;
518
- }
519
-
520
- dom.removeClass(findSpansByIndex(editor, currentIndexState.get()), 'mce-match-marker-selected');
521
-
522
- var spans = findSpansByIndex(editor, testIndex);
523
- if (spans.length) {
524
- dom.addClass(findSpansByIndex(editor, testIndex), 'mce-match-marker-selected');
525
- editor.selection.scrollIntoView(spans[0]);
526
- return testIndex;
527
- }
528
-
529
- return -1;
530
- };
531
-
532
- var removeNode = function (dom, node) {
533
- var parent = node.parentNode;
534
-
535
- dom.remove(node);
536
-
537
- if (dom.isEmpty(parent)) {
538
- dom.remove(parent);
539
- }
540
- };
541
-
542
- var find = function (editor, currentIndexState, text, matchCase, wholeWord) {
543
- text = text.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
544
- text = text.replace(/\s/g, '\\s');
545
- text = wholeWord ? '\\b' + text + '\\b' : text;
546
-
547
- var count = markAllMatches(editor, currentIndexState, new RegExp(text, matchCase ? 'g' : 'gi'));
548
-
549
- if (count) {
550
- currentIndexState.set(-1);
551
- currentIndexState.set(moveSelection(editor, currentIndexState, true));
552
- }
553
-
554
- return count;
555
- };
556
-
557
- var next = function (editor, currentIndexState) {
558
- var index = moveSelection(editor, currentIndexState, true);
559
-
560
- if (index !== -1) {
561
- currentIndexState.set(index);
562
- }
563
- };
564
-
565
- var prev = function (editor, currentIndexState) {
566
- var index = moveSelection(editor, currentIndexState, false);
567
-
568
- if (index !== -1) {
569
- currentIndexState.set(index);
570
- }
571
- };
572
-
573
- var isMatchSpan = function (node) {
574
- var matchIndex = getElmIndex(node);
575
-
576
- return matchIndex !== null && matchIndex.length > 0;
577
- };
578
-
579
- var replace = function (editor, currentIndexState, text, forward, all) {
580
- var i, nodes, node, matchIndex, currentMatchIndex, nextIndex = currentIndexState.get(), hasMore;
581
-
582
- forward = forward !== false;
583
-
584
- node = editor.getBody();
585
- nodes = Tools.grep(Tools.toArray(node.getElementsByTagName('span')), isMatchSpan);
586
- for (i = 0; i < nodes.length; i++) {
587
- var nodeIndex = getElmIndex(nodes[i]);
588
-
589
- matchIndex = currentMatchIndex = parseInt(nodeIndex, 10);
590
- if (all || matchIndex === currentIndexState.get()) {
591
- if (text.length) {
592
- nodes[i].firstChild.nodeValue = text;
593
- unwrap(nodes[i]);
594
- } else {
257
+ }
258
+ return spans;
259
+ };
260
+ var moveSelection = function (editor, currentIndexState, forward) {
261
+ var testIndex = currentIndexState.get();
262
+ var dom = editor.dom;
263
+ forward = forward !== false;
264
+ if (forward) {
265
+ testIndex++;
266
+ } else {
267
+ testIndex--;
268
+ }
269
+ dom.removeClass(findSpansByIndex(editor, currentIndexState.get()), 'mce-match-marker-selected');
270
+ var spans = findSpansByIndex(editor, testIndex);
271
+ if (spans.length) {
272
+ dom.addClass(findSpansByIndex(editor, testIndex), 'mce-match-marker-selected');
273
+ editor.selection.scrollIntoView(spans[0]);
274
+ return testIndex;
275
+ }
276
+ return -1;
277
+ };
278
+ var removeNode = function (dom, node) {
279
+ var parent = node.parentNode;
280
+ dom.remove(node);
281
+ if (dom.isEmpty(parent)) {
282
+ dom.remove(parent);
283
+ }
284
+ };
285
+ var find = function (editor, currentIndexState, text, matchCase, wholeWord) {
286
+ text = text.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, '\\$&');
287
+ text = text.replace(/\s/g, '\\s');
288
+ text = wholeWord ? '\\b' + text + '\\b' : text;
289
+ var count = markAllMatches(editor, currentIndexState, new RegExp(text, matchCase ? 'g' : 'gi'));
290
+ if (count) {
291
+ currentIndexState.set(-1);
292
+ currentIndexState.set(moveSelection(editor, currentIndexState, true));
293
+ }
294
+ return count;
295
+ };
296
+ var next = function (editor, currentIndexState) {
297
+ var index = moveSelection(editor, currentIndexState, true);
298
+ if (index !== -1) {
299
+ currentIndexState.set(index);
300
+ }
301
+ };
302
+ var prev = function (editor, currentIndexState) {
303
+ var index = moveSelection(editor, currentIndexState, false);
304
+ if (index !== -1) {
305
+ currentIndexState.set(index);
306
+ }
307
+ };
308
+ var isMatchSpan = function (node) {
309
+ var matchIndex = getElmIndex(node);
310
+ return matchIndex !== null && matchIndex.length > 0;
311
+ };
312
+ var replace = function (editor, currentIndexState, text, forward, all) {
313
+ var i, nodes, node, matchIndex, currentMatchIndex, nextIndex = currentIndexState.get(), hasMore;
314
+ forward = forward !== false;
315
+ node = editor.getBody();
316
+ nodes = global$1.grep(global$1.toArray(node.getElementsByTagName('span')), isMatchSpan);
317
+ for (i = 0; i < nodes.length; i++) {
318
+ var nodeIndex = getElmIndex(nodes[i]);
319
+ matchIndex = currentMatchIndex = parseInt(nodeIndex, 10);
320
+ if (all || matchIndex === currentIndexState.get()) {
321
+ if (text.length) {
322
+ nodes[i].firstChild.nodeValue = text;
323
+ unwrap(nodes[i]);
324
+ } else {
325
+ removeNode(editor.dom, nodes[i]);
326
+ }
327
+ while (nodes[++i]) {
328
+ matchIndex = parseInt(getElmIndex(nodes[i]), 10);
329
+ if (matchIndex === currentMatchIndex) {
595
330
  removeNode(editor.dom, nodes[i]);
331
+ } else {
332
+ i--;
333
+ break;
596
334
  }
597
-
598
- while (nodes[++i]) {
599
- matchIndex = parseInt(getElmIndex(nodes[i]), 10);
600
-
601
- if (matchIndex === currentMatchIndex) {
602
- removeNode(editor.dom, nodes[i]);
603
- } else {
604
- i--;
605
- break;
606
- }
607
- }
608
-
609
- if (forward) {
610
- nextIndex--;
611
- }
612
- } else if (currentMatchIndex > currentIndexState.get()) {
613
- nodes[i].setAttribute('data-mce-index', currentMatchIndex - 1);
614
335
  }
336
+ if (forward) {
337
+ nextIndex--;
338
+ }
339
+ } else if (currentMatchIndex > currentIndexState.get()) {
340
+ nodes[i].setAttribute('data-mce-index', currentMatchIndex - 1);
615
341
  }
616
-
617
- currentIndexState.set(nextIndex);
618
-
619
- if (forward) {
620
- hasMore = hasNext(editor, currentIndexState);
621
- next(editor, currentIndexState);
622
- } else {
623
- hasMore = hasPrev(editor, currentIndexState);
624
- prev(editor, currentIndexState);
625
- }
626
-
627
- return !all && hasMore;
628
- };
629
-
630
- var done = function (editor, currentIndexState, keepEditorSelection) {
631
- var i, nodes, startContainer, endContainer;
632
-
633
- nodes = Tools.toArray(editor.getBody().getElementsByTagName('span'));
634
- for (i = 0; i < nodes.length; i++) {
635
- var nodeIndex = getElmIndex(nodes[i]);
636
-
637
- if (nodeIndex !== null && nodeIndex.length) {
638
- if (nodeIndex === currentIndexState.get().toString()) {
639
- if (!startContainer) {
640
- startContainer = nodes[i].firstChild;
641
- }
642
-
643
- endContainer = nodes[i].firstChild;
342
+ }
343
+ currentIndexState.set(nextIndex);
344
+ if (forward) {
345
+ hasMore = hasNext(editor, currentIndexState);
346
+ next(editor, currentIndexState);
347
+ } else {
348
+ hasMore = hasPrev(editor, currentIndexState);
349
+ prev(editor, currentIndexState);
350
+ }
351
+ return !all && hasMore;
352
+ };
353
+ var done = function (editor, currentIndexState, keepEditorSelection) {
354
+ var i, nodes, startContainer, endContainer;
355
+ nodes = global$1.toArray(editor.getBody().getElementsByTagName('span'));
356
+ for (i = 0; i < nodes.length; i++) {
357
+ var nodeIndex = getElmIndex(nodes[i]);
358
+ if (nodeIndex !== null && nodeIndex.length) {
359
+ if (nodeIndex === currentIndexState.get().toString()) {
360
+ if (!startContainer) {
361
+ startContainer = nodes[i].firstChild;
644
362
  }
645
-
646
- unwrap(nodes[i]);
363
+ endContainer = nodes[i].firstChild;
647
364
  }
365
+ unwrap(nodes[i]);
648
366
  }
649
-
650
- if (startContainer && endContainer) {
651
- var rng = editor.dom.createRng();
652
- rng.setStart(startContainer, 0);
653
- rng.setEnd(endContainer, endContainer.data.length);
654
-
655
- if (keepEditorSelection !== false) {
656
- editor.selection.setRng(rng);
657
- }
658
-
659
- return rng;
367
+ }
368
+ if (startContainer && endContainer) {
369
+ var rng = editor.dom.createRng();
370
+ rng.setStart(startContainer, 0);
371
+ rng.setEnd(endContainer, endContainer.data.length);
372
+ if (keepEditorSelection !== false) {
373
+ editor.selection.setRng(rng);
660
374
  }
661
- };
375
+ return rng;
376
+ }
377
+ };
378
+ var hasNext = function (editor, currentIndexState) {
379
+ return findSpansByIndex(editor, currentIndexState.get() + 1).length > 0;
380
+ };
381
+ var hasPrev = function (editor, currentIndexState) {
382
+ return findSpansByIndex(editor, currentIndexState.get() - 1).length > 0;
383
+ };
384
+ var $_czmqpkjyjm0ofzvi = {
385
+ done: done,
386
+ find: find,
387
+ next: next,
388
+ prev: prev,
389
+ replace: replace,
390
+ hasNext: hasNext,
391
+ hasPrev: hasPrev
392
+ };
662
393
 
663
- var hasNext = function (editor, currentIndexState) {
664
- return findSpansByIndex(editor, currentIndexState.get() + 1).length > 0;
394
+ var get = function (editor, currentIndexState) {
395
+ var done = function (keepEditorSelection) {
396
+ return $_czmqpkjyjm0ofzvi.done(editor, currentIndexState, keepEditorSelection);
665
397
  };
666
-
667
- var hasPrev = function (editor, currentIndexState) {
668
- return findSpansByIndex(editor, currentIndexState.get() - 1).length > 0;
398
+ var find = function (text, matchCase, wholeWord) {
399
+ return $_czmqpkjyjm0ofzvi.find(editor, currentIndexState, text, matchCase, wholeWord);
400
+ };
401
+ var next = function () {
402
+ return $_czmqpkjyjm0ofzvi.next(editor, currentIndexState);
403
+ };
404
+ var prev = function () {
405
+ return $_czmqpkjyjm0ofzvi.prev(editor, currentIndexState);
406
+ };
407
+ var replace = function (text, forward, all) {
408
+ return $_czmqpkjyjm0ofzvi.replace(editor, currentIndexState, text, forward, all);
669
409
  };
670
-
671
410
  return {
672
411
  done: done,
673
412
  find: find,
674
413
  next: next,
675
414
  prev: prev,
676
- replace: replace,
677
- hasNext: hasNext,
678
- hasPrev: hasPrev
679
- };
680
- }
681
- );
682
- /**
683
- * Api.js
684
- *
685
- * Released under LGPL License.
686
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
687
- *
688
- * License: http://www.tinymce.com/license
689
- * Contributing: http://www.tinymce.com/contributing
690
- */
691
-
692
- define(
693
- 'tinymce.plugins.searchreplace.api.Api',
694
- [
695
- 'tinymce.plugins.searchreplace.core.Actions'
696
- ],
697
- function (Actions) {
698
- var get = function (editor, currentIndexState) {
699
- var done = function (keepEditorSelection) {
700
- return Actions.done(editor, currentIndexState, keepEditorSelection);
701
- };
702
-
703
- var find = function (text, matchCase, wholeWord) {
704
- return Actions.find(editor, currentIndexState, text, matchCase, wholeWord);
705
- };
706
-
707
- var next = function () {
708
- return Actions.next(editor, currentIndexState);
709
- };
710
-
711
- var prev = function () {
712
- return Actions.prev(editor, currentIndexState);
713
- };
714
-
715
- var replace = function (text, forward, all) {
716
- return Actions.replace(editor, currentIndexState, text, forward, all);
717
- };
718
-
719
- return {
720
- done: done,
721
- find: find,
722
- next: next,
723
- prev: prev,
724
- replace: replace
725
- };
415
+ replace: replace
726
416
  };
727
-
728
- return {
729
- get: get
730
- };
731
- }
732
- );
733
- /**
734
- * Dialog.js
735
- *
736
- * Released under LGPL License.
737
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
738
- *
739
- * License: http://www.tinymce.com/license
740
- * Contributing: http://www.tinymce.com/contributing
741
- */
742
-
743
- define(
744
- 'tinymce.plugins.searchreplace.ui.Dialog',
745
- [
746
- 'tinymce.core.util.Tools',
747
- 'tinymce.plugins.searchreplace.core.Actions'
748
- ],
749
- function (Tools, Actions) {
750
- var open = function (editor, currentIndexState) {
751
- var last = {}, selectedText;
752
- editor.undoManager.add();
753
-
754
- selectedText = Tools.trim(editor.selection.getContent({ format: 'text' }));
755
-
756
- function updateButtonStates() {
757
- win.statusbar.find('#next').disabled(Actions.hasNext(editor, currentIndexState) === false);
758
- win.statusbar.find('#prev').disabled(Actions.hasPrev(editor, currentIndexState) === false);
759
- }
760
-
761
- function notFoundAlert() {
762
- editor.windowManager.alert('Could not find the specified string.', function () {
763
- win.find('#find')[0].focus();
764
- });
765
- }
766
-
767
- var win = editor.windowManager.open({
768
- layout: "flex",
769
- pack: "center",
770
- align: "center",
771
- onClose: function () {
772
- editor.focus();
773
- Actions.done(editor, currentIndexState);
774
- editor.undoManager.add();
775
- },
776
- onSubmit: function (e) {
777
- var count, caseState, text, wholeWord;
778
-
779
- e.preventDefault();
780
-
781
- caseState = win.find('#case').checked();
782
- wholeWord = win.find('#words').checked();
783
-
784
- text = win.find('#find').value();
785
- if (!text.length) {
786
- Actions.done(editor, currentIndexState, false);
787
- win.statusbar.items().slice(1).disabled(true);
417
+ };
418
+ var $_nqujjxjm0ofzvg = { get: get };
419
+
420
+ var open = function (editor, currentIndexState) {
421
+ var last = {}, selectedText;
422
+ editor.undoManager.add();
423
+ selectedText = global$1.trim(editor.selection.getContent({ format: 'text' }));
424
+ function updateButtonStates() {
425
+ win.statusbar.find('#next').disabled($_czmqpkjyjm0ofzvi.hasNext(editor, currentIndexState) === false);
426
+ win.statusbar.find('#prev').disabled($_czmqpkjyjm0ofzvi.hasPrev(editor, currentIndexState) === false);
427
+ }
428
+ function notFoundAlert() {
429
+ editor.windowManager.alert('Could not find the specified string.', function () {
430
+ win.find('#find')[0].focus();
431
+ });
432
+ }
433
+ var win = editor.windowManager.open({
434
+ layout: 'flex',
435
+ pack: 'center',
436
+ align: 'center',
437
+ onClose: function () {
438
+ editor.focus();
439
+ $_czmqpkjyjm0ofzvi.done(editor, currentIndexState);
440
+ editor.undoManager.add();
441
+ },
442
+ onSubmit: function (e) {
443
+ var count, caseState, text, wholeWord;
444
+ e.preventDefault();
445
+ caseState = win.find('#case').checked();
446
+ wholeWord = win.find('#words').checked();
447
+ text = win.find('#find').value();
448
+ if (!text.length) {
449
+ $_czmqpkjyjm0ofzvi.done(editor, currentIndexState, false);
450
+ win.statusbar.items().slice(1).disabled(true);
451
+ return;
452
+ }
453
+ if (last.text === text && last.caseState === caseState && last.wholeWord === wholeWord) {
454
+ if (!$_czmqpkjyjm0ofzvi.hasNext(editor, currentIndexState)) {
455
+ notFoundAlert();
788
456
  return;
789
457
  }
790
-
791
- if (last.text === text && last.caseState === caseState && last.wholeWord === wholeWord) {
792
- if (!Actions.hasNext(editor, currentIndexState)) {
793
- notFoundAlert();
794
- return;
458
+ $_czmqpkjyjm0ofzvi.next(editor, currentIndexState);
459
+ updateButtonStates();
460
+ return;
461
+ }
462
+ count = $_czmqpkjyjm0ofzvi.find(editor, currentIndexState, text, caseState, wholeWord);
463
+ if (!count) {
464
+ notFoundAlert();
465
+ }
466
+ win.statusbar.items().slice(1).disabled(count === 0);
467
+ updateButtonStates();
468
+ last = {
469
+ text: text,
470
+ caseState: caseState,
471
+ wholeWord: wholeWord
472
+ };
473
+ },
474
+ buttons: [
475
+ {
476
+ text: 'Find',
477
+ subtype: 'primary',
478
+ onclick: function () {
479
+ win.submit();
480
+ }
481
+ },
482
+ {
483
+ text: 'Replace',
484
+ disabled: true,
485
+ onclick: function () {
486
+ if (!$_czmqpkjyjm0ofzvi.replace(editor, currentIndexState, win.find('#replace').value())) {
487
+ win.statusbar.items().slice(1).disabled(true);
488
+ currentIndexState.set(-1);
489
+ last = {};
795
490
  }
796
-
797
- Actions.next(editor, currentIndexState);
798
- updateButtonStates();
799
- return;
800
491
  }
801
-
802
- count = Actions.find(editor, currentIndexState, text, caseState, wholeWord);
803
- if (!count) {
804
- notFoundAlert();
492
+ },
493
+ {
494
+ text: 'Replace all',
495
+ disabled: true,
496
+ onclick: function () {
497
+ $_czmqpkjyjm0ofzvi.replace(editor, currentIndexState, win.find('#replace').value(), true, true);
498
+ win.statusbar.items().slice(1).disabled(true);
499
+ last = {};
805
500
  }
806
-
807
- win.statusbar.items().slice(1).disabled(count === 0);
808
- updateButtonStates();
809
-
810
- last = {
811
- text: text,
812
- caseState: caseState,
813
- wholeWord: wholeWord
814
- };
815
501
  },
816
- buttons: [
817
- {
818
- text: "Find", subtype: 'primary', onclick: function () {
819
- win.submit();
820
- }
821
- },
502
+ {
503
+ type: 'spacer',
504
+ flex: 1
505
+ },
506
+ {
507
+ text: 'Prev',
508
+ name: 'prev',
509
+ disabled: true,
510
+ onclick: function () {
511
+ $_czmqpkjyjm0ofzvi.prev(editor, currentIndexState);
512
+ updateButtonStates();
513
+ }
514
+ },
515
+ {
516
+ text: 'Next',
517
+ name: 'next',
518
+ disabled: true,
519
+ onclick: function () {
520
+ $_czmqpkjyjm0ofzvi.next(editor, currentIndexState);
521
+ updateButtonStates();
522
+ }
523
+ }
524
+ ],
525
+ title: 'Find and replace',
526
+ items: {
527
+ type: 'form',
528
+ padding: 20,
529
+ labelGap: 30,
530
+ spacing: 10,
531
+ items: [
822
532
  {
823
- text: "Replace", disabled: true, onclick: function () {
824
- if (!Actions.replace(editor, currentIndexState, win.find('#replace').value())) {
825
- win.statusbar.items().slice(1).disabled(true);
826
- currentIndexState.set(-1);
827
- last = {};
828
- }
829
- }
533
+ type: 'textbox',
534
+ name: 'find',
535
+ size: 40,
536
+ label: 'Find',
537
+ value: selectedText
830
538
  },
831
539
  {
832
- text: "Replace all", disabled: true, onclick: function () {
833
- Actions.replace(editor, currentIndexState, win.find('#replace').value(), true, true);
834
- win.statusbar.items().slice(1).disabled(true);
835
- last = {};
836
- }
540
+ type: 'textbox',
541
+ name: 'replace',
542
+ size: 40,
543
+ label: 'Replace with'
837
544
  },
838
- { type: "spacer", flex: 1 },
839
545
  {
840
- text: "Prev", name: 'prev', disabled: true, onclick: function () {
841
- Actions.prev(editor, currentIndexState);
842
- updateButtonStates();
843
- }
546
+ type: 'checkbox',
547
+ name: 'case',
548
+ text: 'Match case',
549
+ label: ' '
844
550
  },
845
551
  {
846
- text: "Next", name: 'next', disabled: true, onclick: function () {
847
- Actions.next(editor, currentIndexState);
848
- updateButtonStates();
849
- }
552
+ type: 'checkbox',
553
+ name: 'words',
554
+ text: 'Whole words',
555
+ label: ' '
850
556
  }
851
- ],
852
- title: "Find and replace",
853
- items: {
854
- type: "form",
855
- padding: 20,
856
- labelGap: 30,
857
- spacing: 10,
858
- items: [
859
- { type: 'textbox', name: 'find', size: 40, label: 'Find', value: selectedText },
860
- { type: 'textbox', name: 'replace', size: 40, label: 'Replace with' },
861
- { type: 'checkbox', name: 'case', text: 'Match case', label: ' ' },
862
- { type: 'checkbox', name: 'words', text: 'Whole words', label: ' ' }
863
- ]
864
- }
865
- });
866
- };
867
-
868
- return {
869
- open: open
870
- };
871
- }
872
- );
873
- /**
874
- * Commands.js
875
- *
876
- * Released under LGPL License.
877
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
878
- *
879
- * License: http://www.tinymce.com/license
880
- * Contributing: http://www.tinymce.com/contributing
881
- */
882
-
883
- define(
884
- 'tinymce.plugins.searchreplace.api.Commands',
885
- [
886
- 'tinymce.plugins.searchreplace.ui.Dialog'
887
- ],
888
- function (Dialog) {
889
- var register = function (editor, currentIndexState) {
890
- editor.addCommand('SearchReplace', function () {
891
- Dialog.open(editor, currentIndexState);
892
- });
893
- };
894
-
895
- return {
896
- register: register
897
- };
898
- }
899
- );
900
- /**
901
- * Buttons.js
902
- *
903
- * Released under LGPL License.
904
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
905
- *
906
- * License: http://www.tinymce.com/license
907
- * Contributing: http://www.tinymce.com/contributing
908
- */
909
-
910
- define(
911
- 'tinymce.plugins.searchreplace.ui.Buttons',
912
- [
913
- 'tinymce.plugins.searchreplace.ui.Dialog'
914
- ],
915
- function (Dialog) {
916
- var showDialog = function (editor, currentIndexState) {
917
- return function () {
918
- Dialog.open(editor, currentIndexState);
919
- };
920
- };
921
-
922
- var register = function (editor, currentIndexState) {
923
- editor.addMenuItem('searchreplace', {
924
- text: 'Find and replace',
925
- shortcut: 'Meta+F',
926
- onclick: showDialog(editor, currentIndexState),
927
- separator: 'before',
928
- context: 'edit'
929
- });
930
-
931
- editor.addButton('searchreplace', {
932
- tooltip: 'Find and replace',
933
- onclick: showDialog(editor, currentIndexState)
934
- });
557
+ ]
558
+ }
559
+ });
560
+ };
561
+ var $_aq7glrk2jm0ofzvv = { open: open };
935
562
 
936
- editor.shortcuts.add('Meta+F', '', showDialog(editor, currentIndexState));
937
- };
563
+ var register = function (editor, currentIndexState) {
564
+ editor.addCommand('SearchReplace', function () {
565
+ $_aq7glrk2jm0ofzvv.open(editor, currentIndexState);
566
+ });
567
+ };
568
+ var $_624vfk1jm0ofzvt = { register: register };
938
569
 
939
- return {
940
- register: register
570
+ var showDialog = function (editor, currentIndexState) {
571
+ return function () {
572
+ $_aq7glrk2jm0ofzvv.open(editor, currentIndexState);
941
573
  };
574
+ };
575
+ var register$1 = function (editor, currentIndexState) {
576
+ editor.addMenuItem('searchreplace', {
577
+ text: 'Find and replace',
578
+ shortcut: 'Meta+F',
579
+ onclick: showDialog(editor, currentIndexState),
580
+ separator: 'before',
581
+ context: 'edit'
582
+ });
583
+ editor.addButton('searchreplace', {
584
+ tooltip: 'Find and replace',
585
+ onclick: showDialog(editor, currentIndexState)
586
+ });
587
+ editor.shortcuts.add('Meta+F', '', showDialog(editor, currentIndexState));
588
+ };
589
+ var $_d1nvw7k3jm0ofzvz = { register: register$1 };
590
+
591
+ global.add('searchreplace', function (editor) {
592
+ var currentIndexState = Cell(-1);
593
+ $_624vfk1jm0ofzvt.register(editor, currentIndexState);
594
+ $_d1nvw7k3jm0ofzvz.register(editor, currentIndexState);
595
+ return $_nqujjxjm0ofzvg.get(editor, currentIndexState);
596
+ });
597
+ function Plugin () {
942
598
  }
943
- );
944
- /**
945
- * Plugin.js
946
- *
947
- * Released under LGPL License.
948
- * Copyright (c) 1999-2017 Ephox Corp. All rights reserved
949
- *
950
- * License: http://www.tinymce.com/license
951
- * Contributing: http://www.tinymce.com/contributing
952
- */
953
-
954
- define(
955
- 'tinymce.plugins.searchreplace.Plugin',
956
- [
957
- 'ephox.katamari.api.Cell',
958
- 'tinymce.core.PluginManager',
959
- 'tinymce.plugins.searchreplace.api.Api',
960
- 'tinymce.plugins.searchreplace.api.Commands',
961
- 'tinymce.plugins.searchreplace.ui.Buttons'
962
- ],
963
- function (Cell, PluginManager, Api, Commands, Buttons) {
964
- PluginManager.add('searchreplace', function (editor) {
965
- var currentIndexState = Cell(-1);
966
599
 
967
- Commands.register(editor, currentIndexState);
968
- Buttons.register(editor, currentIndexState);
600
+ return Plugin;
969
601
 
970
- return Api.get(editor, currentIndexState);
971
- });
972
-
973
- return function () { };
974
- }
975
- );
976
- dem('tinymce.plugins.searchreplace.Plugin')();
602
+ }());
977
603
  })();