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.
- checksums.yaml +4 -4
- data/README.md +1 -5
- data/assets/_vendor/ace/ace.js +21635 -0
- data/assets/_vendor/ace/ext-beautify.js +318 -0
- data/assets/_vendor/ace/ext-elastic_tabstops_lite.js +277 -0
- data/assets/_vendor/ace/ext-emmet.js +1226 -0
- data/assets/_vendor/ace/ext-error_marker.js +10 -0
- data/assets/_vendor/ace/ext-keybinding_menu.js +189 -0
- data/assets/_vendor/ace/ext-language_tools.js +1997 -0
- data/assets/_vendor/ace/ext-linking.js +65 -0
- data/assets/_vendor/ace/ext-modelist.js +228 -0
- data/assets/_vendor/ace/ext-options.js +750 -0
- data/assets/_vendor/ace/ext-rtl.js +110 -0
- data/assets/_vendor/ace/ext-searchbox.js +512 -0
- data/assets/_vendor/ace/ext-settings_menu.js +771 -0
- data/assets/_vendor/ace/ext-spellcheck.js +75 -0
- data/assets/_vendor/ace/ext-split.js +208 -0
- data/assets/_vendor/ace/ext-static_highlight.js +226 -0
- data/assets/_vendor/ace/ext-statusbar.js +57 -0
- data/assets/_vendor/ace/ext-textarea.js +567 -0
- data/assets/_vendor/ace/ext-themelist.js +67 -0
- data/assets/_vendor/ace/ext-whitespace.js +210 -0
- data/assets/_vendor/ace/keybinding-emacs.js +1165 -0
- data/assets/_vendor/ace/keybinding-vim.js +5673 -0
- data/assets/_vendor/ace/mode-abap.js +222 -0
- data/assets/_vendor/ace/mode-abc.js +267 -0
- data/assets/_vendor/ace/mode-actionscript.js +274 -0
- data/assets/_vendor/ace/mode-ada.js +138 -0
- data/assets/_vendor/ace/mode-apache_conf.js +363 -0
- data/assets/_vendor/ace/mode-applescript.js +279 -0
- data/assets/_vendor/ace/mode-asciidoc.js +349 -0
- data/assets/_vendor/ace/mode-asl.js +422 -0
- data/assets/_vendor/ace/mode-assembly_x86.js +193 -0
- data/assets/_vendor/ace/mode-autohotkey.js +243 -0
- data/assets/_vendor/ace/mode-batchfile.js +230 -0
- data/assets/_vendor/ace/mode-bro.js +334 -0
- data/assets/_vendor/ace/mode-c9search.js +294 -0
- data/assets/_vendor/ace/mode-c_cpp.js +502 -0
- data/assets/_vendor/ace/mode-cirru.js +211 -0
- data/assets/_vendor/ace/mode-clojure.js +314 -0
- data/assets/_vendor/ace/mode-cobol.js +102 -0
- data/assets/_vendor/ace/mode-coffee.js +400 -0
- data/assets/_vendor/ace/mode-coldfusion.js +2596 -0
- data/assets/_vendor/ace/mode-csharp.js +502 -0
- data/assets/_vendor/ace/mode-csound_document.js +3749 -0
- data/assets/_vendor/ace/mode-csound_orchestra.js +2687 -0
- data/assets/_vendor/ace/mode-csound_score.js +454 -0
- data/assets/_vendor/ace/mode-csp.js +60 -0
- data/assets/_vendor/ace/mode-css.js +723 -0
- data/assets/_vendor/ace/mode-curly.js +2564 -0
- data/assets/_vendor/ace/mode-d.js +520 -0
- data/assets/_vendor/ace/mode-dart.js +703 -0
- data/assets/_vendor/ace/mode-diff.js +146 -0
- data/assets/_vendor/ace/mode-django.js +2594 -0
- data/assets/_vendor/ace/mode-dockerfile.js +498 -0
- data/assets/_vendor/ace/mode-dot.js +418 -0
- data/assets/_vendor/ace/mode-drools.js +496 -0
- data/assets/_vendor/ace/mode-edifact.js +165 -0
- data/assets/_vendor/ace/mode-eiffel.js +136 -0
- data/assets/_vendor/ace/mode-ejs.js +3026 -0
- data/assets/_vendor/ace/mode-elixir.js +501 -0
- data/assets/_vendor/ace/mode-elm.js +307 -0
- data/assets/_vendor/ace/mode-erlang.js +1009 -0
- data/assets/_vendor/ace/mode-forth.js +297 -0
- data/assets/_vendor/ace/mode-fortran.js +431 -0
- data/assets/_vendor/ace/mode-fsharp.js +314 -0
- data/assets/_vendor/ace/mode-ftl.js +1192 -0
- data/assets/_vendor/ace/mode-gcode.js +94 -0
- data/assets/_vendor/ace/mode-gherkin.js +172 -0
- data/assets/_vendor/ace/mode-gitignore.js +60 -0
- data/assets/_vendor/ace/mode-glsl.js +579 -0
- data/assets/_vendor/ace/mode-gobstones.js +929 -0
- data/assets/_vendor/ace/mode-golang.js +414 -0
- data/assets/_vendor/ace/mode-graphqlschema.js +214 -0
- data/assets/_vendor/ace/mode-groovy.js +986 -0
- data/assets/_vendor/ace/mode-haml.js +1555 -0
- data/assets/_vendor/ace/mode-handlebars.js +2622 -0
- data/assets/_vendor/ace/mode-haskell.js +379 -0
- data/assets/_vendor/ace/mode-haskell_cabal.js +142 -0
- data/assets/_vendor/ace/mode-haxe.js +386 -0
- data/assets/_vendor/ace/mode-hjson.js +353 -0
- data/assets/_vendor/ace/mode-html.js +2509 -0
- data/assets/_vendor/ace/mode-html_elixir.js +3087 -0
- data/assets/_vendor/ace/mode-html_ruby.js +3043 -0
- data/assets/_vendor/ace/mode-ini.js +163 -0
- data/assets/_vendor/ace/mode-io.js +253 -0
- data/assets/_vendor/ace/mode-jack.js +347 -0
- data/assets/_vendor/ace/mode-jade.js +2126 -0
- data/assets/_vendor/ace/mode-java.js +975 -0
- data/assets/_vendor/ace/mode-javascript.js +797 -0
- data/assets/_vendor/ace/mode-json.js +327 -0
- data/assets/_vendor/ace/mode-jsoniq.js +4940 -0
- data/assets/_vendor/ace/mode-jsp.js +1430 -0
- data/assets/_vendor/ace/mode-jssm.js +325 -0
- data/assets/_vendor/ace/mode-jsx.js +412 -0
- data/assets/_vendor/ace/mode-julia.js +303 -0
- data/assets/_vendor/ace/mode-kotlin.js +795 -0
- data/assets/_vendor/ace/mode-latex.js +297 -0
- data/assets/_vendor/ace/mode-less.js +841 -0
- data/assets/_vendor/ace/mode-liquid.js +1193 -0
- data/assets/_vendor/ace/mode-lisp.js +112 -0
- data/assets/_vendor/ace/mode-livescript.js +280 -0
- data/assets/_vendor/ace/mode-logiql.js +317 -0
- data/assets/_vendor/ace/mode-lsl.js +343 -0
- data/assets/_vendor/ace/mode-lua.js +432 -0
- data/assets/_vendor/ace/mode-luapage.js +3007 -0
- data/assets/_vendor/ace/mode-lucene.js +87 -0
- data/assets/_vendor/ace/mode-makefile.js +410 -0
- data/assets/_vendor/ace/mode-markdown.js +3189 -0
- data/assets/_vendor/ace/mode-mask.js +1802 -0
- data/assets/_vendor/ace/mode-matlab.js +264 -0
- data/assets/_vendor/ace/mode-maze.js +291 -0
- data/assets/_vendor/ace/mode-mel.js +263 -0
- data/assets/_vendor/ace/mode-mixal.js +123 -0
- data/assets/_vendor/ace/mode-mushcode.js +681 -0
- data/assets/_vendor/ace/mode-mysql.js +168 -0
- data/assets/_vendor/ace/mode-nix.js +646 -0
- data/assets/_vendor/ace/mode-nsis.js +312 -0
- data/assets/_vendor/ace/mode-objectivec.js +739 -0
- data/assets/_vendor/ace/mode-ocaml.js +422 -0
- data/assets/_vendor/ace/mode-pascal.js +205 -0
- data/assets/_vendor/ace/mode-perl.js +380 -0
- data/assets/_vendor/ace/mode-pgsql.js +1508 -0
- data/assets/_vendor/ace/mode-php.js +13088 -0
- data/assets/_vendor/ace/mode-php_laravel_blade.js +13289 -0
- data/assets/_vendor/ace/mode-pig.js +310 -0
- data/assets/_vendor/ace/mode-plain_text.js +33 -0
- data/assets/_vendor/ace/mode-powershell.js +418 -0
- data/assets/_vendor/ace/mode-praat.js +478 -0
- data/assets/_vendor/ace/mode-prolog.js +371 -0
- data/assets/_vendor/ace/mode-properties.js +81 -0
- data/assets/_vendor/ace/mode-protobuf.js +592 -0
- data/assets/_vendor/ace/mode-puppet.js +370 -0
- data/assets/_vendor/ace/mode-python.js +273 -0
- data/assets/_vendor/ace/mode-r.js +310 -0
- data/assets/_vendor/ace/mode-razor.js +2869 -0
- data/assets/_vendor/ace/mode-rdoc.js +243 -0
- data/assets/_vendor/ace/mode-red.js +450 -0
- data/assets/_vendor/ace/mode-redshift.js +361 -0
- data/assets/_vendor/ace/mode-rhtml.js +2806 -0
- data/assets/_vendor/ace/mode-rst.js +257 -0
- data/assets/_vendor/ace/mode-ruby.js +497 -0
- data/assets/_vendor/ace/mode-rust.js +279 -0
- data/assets/_vendor/ace/mode-sass.js +441 -0
- data/assets/_vendor/ace/mode-scad.js +414 -0
- data/assets/_vendor/ace/mode-scala.js +982 -0
- data/assets/_vendor/ace/mode-scheme.js +232 -0
- data/assets/_vendor/ace/mode-scss.js +606 -0
- data/assets/_vendor/ace/mode-sh.js +447 -0
- data/assets/_vendor/ace/mode-sjs.js +1014 -0
- data/assets/_vendor/ace/mode-slim.js +4736 -0
- data/assets/_vendor/ace/mode-smarty.js +2635 -0
- data/assets/_vendor/ace/mode-snippets.js +207 -0
- data/assets/_vendor/ace/mode-soy_template.js +2847 -0
- data/assets/_vendor/ace/mode-space.js +168 -0
- data/assets/_vendor/ace/mode-sparql.js +320 -0
- data/assets/_vendor/ace/mode-sql.js +111 -0
- data/assets/_vendor/ace/mode-sqlserver.js +444 -0
- data/assets/_vendor/ace/mode-stylus.js +471 -0
- data/assets/_vendor/ace/mode-svg.js +1581 -0
- data/assets/_vendor/ace/mode-swift.js +390 -0
- data/assets/_vendor/ace/mode-tcl.js +383 -0
- data/assets/_vendor/ace/mode-terraform.js +398 -0
- data/assets/_vendor/ace/mode-tex.js +159 -0
- data/assets/_vendor/ace/mode-text.js +10 -0
- data/assets/_vendor/ace/mode-textile.js +150 -0
- data/assets/_vendor/ace/mode-toml.js +154 -0
- data/assets/_vendor/ace/mode-tsx.js +887 -0
- data/assets/_vendor/ace/mode-turtle.js +296 -0
- data/assets/_vendor/ace/mode-twig.js +2693 -0
- data/assets/_vendor/ace/mode-typescript.js +868 -0
- data/assets/_vendor/ace/mode-vala.js +676 -0
- data/assets/_vendor/ace/mode-vbscript.js +207 -0
- data/assets/_vendor/ace/mode-velocity.js +2790 -0
- data/assets/_vendor/ace/mode-verilog.js +119 -0
- data/assets/_vendor/ace/mode-vhdl.js +118 -0
- data/assets/_vendor/ace/mode-wollok.js +911 -0
- data/assets/_vendor/ace/mode-xml.js +677 -0
- data/assets/_vendor/ace/mode-xquery.js +4922 -0
- data/assets/_vendor/ace/mode-yaml.js +300 -0
- data/assets/_vendor/ace/snippets/abap.js +15 -0
- data/assets/_vendor/ace/snippets/abc.js +46 -0
- data/assets/_vendor/ace/snippets/actionscript.js +172 -0
- data/assets/_vendor/ace/snippets/ada.js +15 -0
- data/assets/_vendor/ace/snippets/apache_conf.js +15 -0
- data/assets/_vendor/ace/snippets/applescript.js +15 -0
- data/assets/_vendor/ace/snippets/asciidoc.js +15 -0
- data/assets/_vendor/ace/snippets/asl.js +14 -0
- data/assets/_vendor/ace/snippets/assembly_x86.js +15 -0
- data/assets/_vendor/ace/snippets/autohotkey.js +15 -0
- data/assets/_vendor/ace/snippets/batchfile.js +15 -0
- data/assets/_vendor/ace/snippets/bro.js +15 -0
- data/assets/_vendor/ace/snippets/c9search.js +15 -0
- data/assets/_vendor/ace/snippets/c_cpp.js +146 -0
- data/assets/_vendor/ace/snippets/cirru.js +15 -0
- data/assets/_vendor/ace/snippets/clojure.js +105 -0
- data/assets/_vendor/ace/snippets/cobol.js +15 -0
- data/assets/_vendor/ace/snippets/coffee.js +110 -0
- data/assets/_vendor/ace/snippets/coldfusion.js +15 -0
- data/assets/_vendor/ace/snippets/csharp.js +15 -0
- data/assets/_vendor/ace/snippets/csound_document.js +25 -0
- data/assets/_vendor/ace/snippets/csound_orchestra.js +62 -0
- data/assets/_vendor/ace/snippets/csound_score.js +15 -0
- data/assets/_vendor/ace/snippets/csp.js +15 -0
- data/assets/_vendor/ace/snippets/css.js +982 -0
- data/assets/_vendor/ace/snippets/curly.js +15 -0
- data/assets/_vendor/ace/snippets/d.js +15 -0
- data/assets/_vendor/ace/snippets/dart.js +98 -0
- data/assets/_vendor/ace/snippets/diff.js +26 -0
- data/assets/_vendor/ace/snippets/django.js +123 -0
- data/assets/_vendor/ace/snippets/dockerfile.js +15 -0
- data/assets/_vendor/ace/snippets/dot.js +15 -0
- data/assets/_vendor/ace/snippets/drools.js +34 -0
- data/assets/_vendor/ace/snippets/edifact.js +255 -0
- data/assets/_vendor/ace/snippets/eiffel.js +15 -0
- data/assets/_vendor/ace/snippets/ejs.js +15 -0
- data/assets/_vendor/ace/snippets/elixir.js +15 -0
- data/assets/_vendor/ace/snippets/elm.js +15 -0
- data/assets/_vendor/ace/snippets/erlang.js +175 -0
- data/assets/_vendor/ace/snippets/forth.js +15 -0
- data/assets/_vendor/ace/snippets/fortran.js +15 -0
- data/assets/_vendor/ace/snippets/fsharp.js +15 -0
- data/assets/_vendor/ace/snippets/ftl.js +15 -0
- data/assets/_vendor/ace/snippets/gcode.js +15 -0
- data/assets/_vendor/ace/snippets/gherkin.js +15 -0
- data/assets/_vendor/ace/snippets/gitignore.js +15 -0
- data/assets/_vendor/ace/snippets/glsl.js +15 -0
- data/assets/_vendor/ace/snippets/gobstones.js +49 -0
- data/assets/_vendor/ace/snippets/golang.js +15 -0
- data/assets/_vendor/ace/snippets/graphqlschema.js +47 -0
- data/assets/_vendor/ace/snippets/groovy.js +15 -0
- data/assets/_vendor/ace/snippets/haml.js +35 -0
- data/assets/_vendor/ace/snippets/handlebars.js +15 -0
- data/assets/_vendor/ace/snippets/haskell.js +97 -0
- data/assets/_vendor/ace/snippets/haskell_cabal.js +15 -0
- data/assets/_vendor/ace/snippets/haxe.js +15 -0
- data/assets/_vendor/ace/snippets/hjson.js +15 -0
- data/assets/_vendor/ace/snippets/html.js +870 -0
- data/assets/_vendor/ace/snippets/html_elixir.js +15 -0
- data/assets/_vendor/ace/snippets/html_ruby.js +15 -0
- data/assets/_vendor/ace/snippets/ini.js +15 -0
- data/assets/_vendor/ace/snippets/io.js +77 -0
- data/assets/_vendor/ace/snippets/jack.js +15 -0
- data/assets/_vendor/ace/snippets/jade.js +15 -0
- data/assets/_vendor/ace/snippets/java.js +255 -0
- data/assets/_vendor/ace/snippets/javascript.js +210 -0
- data/assets/_vendor/ace/snippets/json.js +15 -0
- data/assets/_vendor/ace/snippets/jsoniq.js +76 -0
- data/assets/_vendor/ace/snippets/jsp.js +114 -0
- data/assets/_vendor/ace/snippets/jssm.js +15 -0
- data/assets/_vendor/ace/snippets/jsx.js +15 -0
- data/assets/_vendor/ace/snippets/julia.js +15 -0
- data/assets/_vendor/ace/snippets/kotlin.js +15 -0
- data/assets/_vendor/ace/snippets/latex.js +15 -0
- data/assets/_vendor/ace/snippets/less.js +15 -0
- data/assets/_vendor/ace/snippets/liquid.js +15 -0
- data/assets/_vendor/ace/snippets/lisp.js +15 -0
- data/assets/_vendor/ace/snippets/livescript.js +15 -0
- data/assets/_vendor/ace/snippets/logiql.js +15 -0
- data/assets/_vendor/ace/snippets/lsl.js +1247 -0
- data/assets/_vendor/ace/snippets/lua.js +36 -0
- data/assets/_vendor/ace/snippets/luapage.js +15 -0
- data/assets/_vendor/ace/snippets/lucene.js +15 -0
- data/assets/_vendor/ace/snippets/makefile.js +19 -0
- data/assets/_vendor/ace/snippets/markdown.js +103 -0
- data/assets/_vendor/ace/snippets/mask.js +15 -0
- data/assets/_vendor/ace/snippets/matlab.js +15 -0
- data/assets/_vendor/ace/snippets/maze.js +24 -0
- data/assets/_vendor/ace/snippets/mel.js +15 -0
- data/assets/_vendor/ace/snippets/mixal.js +15 -0
- data/assets/_vendor/ace/snippets/mushcode.js +15 -0
- data/assets/_vendor/ace/snippets/mysql.js +15 -0
- data/assets/_vendor/ace/snippets/nix.js +15 -0
- data/assets/_vendor/ace/snippets/nsis.js +15 -0
- data/assets/_vendor/ace/snippets/objectivec.js +15 -0
- data/assets/_vendor/ace/snippets/ocaml.js +15 -0
- data/assets/_vendor/ace/snippets/pascal.js +15 -0
- data/assets/_vendor/ace/snippets/perl.js +362 -0
- data/assets/_vendor/ace/snippets/pgsql.js +15 -0
- data/assets/_vendor/ace/snippets/php.js +398 -0
- data/assets/_vendor/ace/snippets/php_laravel_blade.js +15 -0
- data/assets/_vendor/ace/snippets/pig.js +15 -0
- data/assets/_vendor/ace/snippets/plain_text.js +15 -0
- data/assets/_vendor/ace/snippets/powershell.js +15 -0
- data/assets/_vendor/ace/snippets/praat.js +15 -0
- data/assets/_vendor/ace/snippets/prolog.js +15 -0
- data/assets/_vendor/ace/snippets/properties.js +15 -0
- data/assets/_vendor/ace/snippets/protobuf.js +15 -0
- data/assets/_vendor/ace/snippets/puppet.js +15 -0
- data/assets/_vendor/ace/snippets/python.js +173 -0
- data/assets/_vendor/ace/snippets/r.js +136 -0
- data/assets/_vendor/ace/snippets/razor.js +18 -0
- data/assets/_vendor/ace/snippets/rdoc.js +15 -0
- data/assets/_vendor/ace/snippets/red.js +15 -0
- data/assets/_vendor/ace/snippets/redshift.js +15 -0
- data/assets/_vendor/ace/snippets/rhtml.js +15 -0
- data/assets/_vendor/ace/snippets/rst.js +37 -0
- data/assets/_vendor/ace/snippets/ruby.js +943 -0
- data/assets/_vendor/ace/snippets/rust.js +15 -0
- data/assets/_vendor/ace/snippets/sass.js +15 -0
- data/assets/_vendor/ace/snippets/scad.js +15 -0
- data/assets/_vendor/ace/snippets/scala.js +15 -0
- data/assets/_vendor/ace/snippets/scheme.js +15 -0
- data/assets/_vendor/ace/snippets/scss.js +15 -0
- data/assets/_vendor/ace/snippets/sh.js +98 -0
- data/assets/_vendor/ace/snippets/sjs.js +15 -0
- data/assets/_vendor/ace/snippets/slim.js +15 -0
- data/assets/_vendor/ace/snippets/smarty.js +15 -0
- data/assets/_vendor/ace/snippets/snippets.js +24 -0
- data/assets/_vendor/ace/snippets/soy_template.js +15 -0
- data/assets/_vendor/ace/snippets/space.js +15 -0
- data/assets/_vendor/ace/snippets/sparql.js +15 -0
- data/assets/_vendor/ace/snippets/sql.js +41 -0
- data/assets/_vendor/ace/snippets/sqlserver.js +84 -0
- data/assets/_vendor/ace/snippets/stylus.js +15 -0
- data/assets/_vendor/ace/snippets/svg.js +15 -0
- data/assets/_vendor/ace/snippets/swift.js +15 -0
- data/assets/_vendor/ace/snippets/tcl.js +107 -0
- data/assets/_vendor/ace/snippets/terraform.js +15 -0
- data/assets/_vendor/ace/snippets/tex.js +205 -0
- data/assets/_vendor/ace/snippets/text.js +15 -0
- data/assets/_vendor/ace/snippets/textile.js +45 -0
- data/assets/_vendor/ace/snippets/toml.js +15 -0
- data/assets/_vendor/ace/snippets/tsx.js +15 -0
- data/assets/_vendor/ace/snippets/turtle.js +15 -0
- data/assets/_vendor/ace/snippets/twig.js +15 -0
- data/assets/_vendor/ace/snippets/typescript.js +15 -0
- data/assets/_vendor/ace/snippets/vala.js +201 -0
- data/assets/_vendor/ace/snippets/vbscript.js +15 -0
- data/assets/_vendor/ace/snippets/velocity.js +44 -0
- data/assets/_vendor/ace/snippets/verilog.js +15 -0
- data/assets/_vendor/ace/snippets/vhdl.js +15 -0
- data/assets/_vendor/ace/snippets/wollok.js +99 -0
- data/assets/_vendor/ace/snippets/xml.js +15 -0
- data/assets/_vendor/ace/snippets/xquery.js +76 -0
- data/assets/_vendor/ace/snippets/yaml.js +15 -0
- data/assets/_vendor/ace/theme-ambiance.js +185 -0
- data/assets/_vendor/ace/theme-chaos.js +164 -0
- data/assets/_vendor/ace/theme-chrome.js +136 -0
- data/assets/_vendor/ace/theme-clouds.js +103 -0
- data/assets/_vendor/ace/theme-clouds_midnight.js +104 -0
- data/assets/_vendor/ace/theme-cobalt.js +121 -0
- data/assets/_vendor/ace/theme-crimson_editor.js +126 -0
- data/assets/_vendor/ace/theme-dawn.js +116 -0
- data/assets/_vendor/ace/theme-dracula.js +136 -0
- data/assets/_vendor/ace/theme-dreamweaver.js +149 -0
- data/assets/_vendor/ace/theme-eclipse.js +106 -0
- data/assets/_vendor/ace/theme-github.js +110 -0
- data/assets/_vendor/ace/theme-gob.js +120 -0
- data/assets/_vendor/ace/theme-gruvbox.js +90 -0
- data/assets/_vendor/ace/theme-idle_fingers.js +104 -0
- data/assets/_vendor/ace/theme-iplastic.js +129 -0
- data/assets/_vendor/ace/theme-katzenmilch.js +129 -0
- data/assets/_vendor/ace/theme-kr_theme.js +112 -0
- data/assets/_vendor/ace/theme-kuroir.js +69 -0
- data/assets/_vendor/ace/theme-merbivore.js +103 -0
- data/assets/_vendor/ace/theme-merbivore_soft.js +104 -0
- data/assets/_vendor/ace/theme-mono_industrial.js +115 -0
- data/assets/_vendor/ace/theme-monokai.js +113 -0
- data/assets/_vendor/ace/theme-pastel_on_dark.js +116 -0
- data/assets/_vendor/ace/theme-solarized_dark.js +96 -0
- data/assets/_vendor/ace/theme-solarized_light.js +99 -0
- data/assets/_vendor/ace/theme-sqlserver.js +146 -0
- data/assets/_vendor/ace/theme-terminal.js +122 -0
- data/assets/_vendor/ace/theme-textmate.js +138 -0
- data/assets/_vendor/ace/theme-tomorrow.js +116 -0
- data/assets/_vendor/ace/theme-tomorrow_night.js +116 -0
- data/assets/_vendor/ace/theme-tomorrow_night_blue.js +114 -0
- data/assets/_vendor/ace/theme-tomorrow_night_bright.js +129 -0
- data/assets/_vendor/ace/theme-tomorrow_night_eighties.js +116 -0
- data/assets/_vendor/ace/theme-twilight.js +117 -0
- data/assets/_vendor/ace/theme-vibrant_ink.js +102 -0
- data/assets/_vendor/ace/theme-xcode.js +96 -0
- data/assets/_vendor/ace/worker-coffee.js +2165 -0
- data/assets/_vendor/ace/worker-css.js +8764 -0
- data/assets/_vendor/ace/worker-html.js +11614 -0
- data/assets/_vendor/ace/worker-javascript.js +12491 -0
- data/assets/_vendor/ace/worker-json.js +2396 -0
- data/assets/_vendor/ace/worker-lua.js +3637 -0
- data/assets/_vendor/ace/worker-php.js +4313 -0
- data/assets/_vendor/ace/worker-xml.js +3899 -0
- data/assets/_vendor/ace/worker-xquery.js +70688 -0
- data/assets/_vendor/motion-ui/_settings.scss +1 -0
- data/assets/_vendor/motion-ui/effects/_fade.scss +1 -4
- data/assets/_vendor/motion-ui/effects/_hinge.scss +4 -3
- data/assets/_vendor/motion-ui/effects/_shake.scss +1 -1
- data/assets/_vendor/motion-ui/effects/_slide.scss +4 -3
- data/assets/_vendor/motion-ui/effects/_spin.scss +4 -3
- data/assets/_vendor/motion-ui/effects/_wiggle.scss +1 -1
- data/assets/_vendor/motion-ui/effects/_zoom.scss +2 -2
- data/assets/_vendor/motion-ui/motion-ui.scss +2 -0
- data/assets/_vendor/motion-ui/transitions/_fade.scss +6 -4
- data/assets/_vendor/motion-ui/transitions/_hinge.scss +3 -2
- data/assets/_vendor/motion-ui/transitions/_slide.scss +3 -2
- data/assets/_vendor/motion-ui/transitions/_spin.scss +2 -1
- data/assets/_vendor/motion-ui/transitions/_zoom.scss +6 -4
- data/assets/_vendor/motion-ui/util/_animation.scss +1 -1
- data/assets/_vendor/motion-ui/util/_args.scss +2 -2
- data/assets/_vendor/motion-ui/util/_function.scss +94 -0
- data/assets/_vendor/motion-ui/util/_keyframe.scss +5 -5
- data/assets/_vendor/motion-ui/util/_series.scss +20 -17
- data/assets/_vendor/motion-ui/util/_string.scss +36 -0
- data/assets/_vendor/tinymce/plugins/advlist/plugin.js +136 -404
- data/assets/_vendor/tinymce/plugins/advlist/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/anchor/plugin.js +103 -323
- data/assets/_vendor/tinymce/plugins/anchor/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/autolink/plugin.js +153 -377
- data/assets/_vendor/tinymce/plugins/autolink/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/autoresize/plugin.js +145 -427
- data/assets/_vendor/tinymce/plugins/autoresize/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/autosave/plugin.js +197 -579
- data/assets/_vendor/tinymce/plugins/autosave/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/bbcode/plugin.js +88 -251
- data/assets/_vendor/tinymce/plugins/bbcode/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/charmap/plugin.js +1243 -818
- data/assets/_vendor/tinymce/plugins/charmap/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/code/plugin.js +82 -326
- data/assets/_vendor/tinymce/plugins/code/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/codesample/plugin.js +829 -1444
- data/assets/_vendor/tinymce/plugins/codesample/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/colorpicker/plugin.js +111 -257
- data/assets/_vendor/tinymce/plugins/colorpicker/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/contextmenu/plugin.js +141 -469
- data/assets/_vendor/tinymce/plugins/contextmenu/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/directionality/plugin.js +57 -261
- data/assets/_vendor/tinymce/plugins/directionality/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/emoticons/plugin.js +78 -247
- data/assets/_vendor/tinymce/plugins/emoticons/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/fullpage/plugin.js +463 -906
- data/assets/_vendor/tinymce/plugins/fullpage/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/fullscreen/plugin.js +149 -427
- data/assets/_vendor/tinymce/plugins/fullscreen/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/help/plugin.js +634 -1434
- data/assets/_vendor/tinymce/plugins/help/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/hr/plugin.js +29 -185
- data/assets/_vendor/tinymce/plugins/hr/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/image/plugin.js +1147 -1508
- data/assets/_vendor/tinymce/plugins/image/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/imagetools/plugin.js +3319 -4079
- data/assets/_vendor/tinymce/plugins/imagetools/plugin.min.js +1 -2
- data/assets/_vendor/tinymce/plugins/importcss/plugin.js +230 -543
- data/assets/_vendor/tinymce/plugins/importcss/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/insertdatetime/plugin.js +151 -460
- data/assets/_vendor/tinymce/plugins/insertdatetime/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/legacyoutput/plugin.js +204 -379
- data/assets/_vendor/tinymce/plugins/legacyoutput/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/link/plugin.js +644 -1162
- data/assets/_vendor/tinymce/plugins/link/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/lists/plugin.js +1005 -1875
- data/assets/_vendor/tinymce/plugins/lists/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/media/plugin.js +1066 -1926
- data/assets/_vendor/tinymce/plugins/media/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/nonbreaking/plugin.js +70 -298
- data/assets/_vendor/tinymce/plugins/nonbreaking/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/noneditable/plugin.js +96 -294
- data/assets/_vendor/tinymce/plugins/noneditable/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/pagebreak/plugin.js +92 -337
- data/assets/_vendor/tinymce/plugins/pagebreak/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/paste/plugin.js +1363 -2801
- data/assets/_vendor/tinymce/plugins/paste/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/preview/plugin.js +106 -393
- data/assets/_vendor/tinymce/plugins/preview/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/print/plugin.js +29 -185
- data/assets/_vendor/tinymce/plugins/print/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/save/plugin.js +100 -350
- data/assets/_vendor/tinymce/plugins/save/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/searchreplace/plugin.js +491 -865
- data/assets/_vendor/tinymce/plugins/searchreplace/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/spellchecker/plugin.js +630 -1292
- data/assets/_vendor/tinymce/plugins/spellchecker/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/tabfocus/plugin.js +96 -391
- data/assets/_vendor/tinymce/plugins/tabfocus/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/table/plugin.js +9537 -14920
- data/assets/_vendor/tinymce/plugins/table/plugin.min.js +1 -5
- data/assets/_vendor/tinymce/plugins/template/plugin.js +309 -771
- data/assets/_vendor/tinymce/plugins/template/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/textcolor/plugin.js +319 -592
- data/assets/_vendor/tinymce/plugins/textcolor/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/textpattern/plugin.js +326 -674
- data/assets/_vendor/tinymce/plugins/textpattern/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/toc/plugin.js +199 -530
- data/assets/_vendor/tinymce/plugins/toc/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/visualblocks/plugin.js +112 -436
- data/assets/_vendor/tinymce/plugins/visualblocks/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/visualchars/plugin.js +428 -1248
- data/assets/_vendor/tinymce/plugins/visualchars/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/wordcount/plugin.js +307 -699
- data/assets/_vendor/tinymce/plugins/wordcount/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/skins/lightgray/content.inline.min.css +1 -1
- data/assets/_vendor/tinymce/skins/lightgray/content.min.css +1 -1
- data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.eot +0 -0
- data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.svg +1 -1
- data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.ttf +0 -0
- data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.woff +0 -0
- data/assets/_vendor/tinymce/skins/lightgray/skin.min.css +1 -1
- data/assets/_vendor/tinymce/skins/lightgray/skin.mobile.min.css +1 -1
- data/assets/_vendor/tinymce/themes/inlite/theme.js +9693 -18245
- data/assets/_vendor/tinymce/themes/inlite/theme.min.js +1 -5
- data/assets/_vendor/tinymce/themes/mobile/theme.js +12629 -22467
- data/assets/_vendor/tinymce/themes/mobile/theme.min.js +1 -8
- data/assets/_vendor/tinymce/themes/modern/theme.js +9510 -17780
- data/assets/_vendor/tinymce/themes/modern/theme.min.js +1 -5
- data/assets/_vendor/tinymce/tinymce.js +25087 -42606
- data/assets/_vendor/yoastseo/css/_icons.scss +7 -7
- data/assets/_vendor/yoastseo/css/_snippet-editor.scss +1 -1
- data/assets/bedrock/js/bedrock.js +1 -71697
- data/assets/bedrock/scss/_bedrock-components.scss +20 -0
- data/assets/bedrock/scss/_bedrock-settings.scss +12 -4
- data/assets/bedrock/scss/_foundation-settings.scss +4 -2
- data/assets/bedrock/scss/components/ace-editor.scss +21 -0
- data/assets/bedrock/scss/components/attachments-grid.scss +18 -15
- data/assets/bedrock/scss/components/date-picker.scss +146 -0
- data/assets/bedrock/scss/components/dropzone-upload.scss +7 -0
- data/assets/bedrock/scss/components/file-input.scss +7 -0
- data/assets/bedrock/scss/components/file-preview.scss +36 -0
- data/assets/bedrock/scss/components/frame-embed.scss +23 -0
- data/assets/bedrock/scss/components/global.scss +27 -0
- data/assets/bedrock/scss/components/helper-classes.scss +1 -0
- data/assets/bedrock/scss/components/icon-box.scss +38 -0
- data/assets/bedrock/scss/components/item-list.scss +66 -0
- data/assets/bedrock/scss/components/lists.scss +58 -0
- data/assets/bedrock/scss/components/off-canvas-menu.scss +27 -15
- data/assets/bedrock/scss/components/place-autocomplete.scss +90 -0
- data/assets/bedrock/scss/components/rrule-generator.scss +102 -0
- data/assets/bedrock/scss/components/rrule-reveal.scss +14 -0
- data/assets/bedrock/scss/components/select-box.scss +1 -0
- data/assets/bedrock/scss/components/seo-analysis.scss +5 -0
- data/assets/bedrock/scss/components/textarea.scss +14 -2
- data/assets/bedrock/scss/components/tiny-mce-editor.scss +5 -16
- data/lib/bedrock_sass.rb +5 -0
- data/lib/bedrock_sass/version.rb +1 -1
- data/lib/tasks/before_assets_precompile.rake +1 -0
- metadata +395 -4
- data/CODE_OF_CONDUCT.md +0 -74
@@ -1 +1 @@
|
|
1
|
-
!function(){
|
1
|
+
!function(){"use strict";var o=function(e){var t=e,n=function(){return t};return{get:n,set:function(e){t=e},clone:function(){return o(n())}}},e=tinymce.util.Tools.resolve("tinymce.PluginManager"),i=function(e,t){e.fire("VisualBlocks",{state:t})},s=function(e){return e.getParam("visualblocks_default_state",!1)},c=function(e){return e.settings.visualblocks_content_css},l=tinymce.util.Tools.resolve("tinymce.dom.DOMUtils"),u=tinymce.util.Tools.resolve("tinymce.util.Tools"),a=l.DOM.uniqueId(),r=function(e,t){var n=u.toArray(e.getElementsByTagName("link"));if(0===u.grep(n,function(e){return e.id===a}).length){var o=l.DOM.create("link",{id:a,rel:"stylesheet",href:t});e.getElementsByTagName("head")[0].appendChild(o)}},m=function(e,t,n){var o=e.dom,s=c(e);r(e.getDoc(),s||t+"/css/visualblocks.css"),o.toggleClass(e.getBody(),"mce-visualblocks"),n.set(!n.get()),i(e,n.get())},f=function(e,t,n){e.addCommand("mceVisualBlocks",function(){m(e,t,n)})},d=function(t,e,n){t.on("PreviewFormats AfterPreviewFormats",function(e){n.get()&&t.dom.toggleClass(t.getBody(),"mce-visualblocks","afterpreviewformats"===e.type)}),t.on("init",function(){s(t)&&m(t,e,n)}),t.on("remove",function(){t.dom.removeClass(t.getBody(),"mce-visualblocks")})},n=function(n,o){return function(e){var t=e.control;t.active(o.get()),n.on("VisualBlocks",function(e){t.active(e.state)})}},v=function(e,t){e.addButton("visualblocks",{active:!1,title:"Show blocks",cmd:"mceVisualBlocks",onPostRender:n(e,t)}),e.addMenuItem("visualblocks",{text:"Show blocks",cmd:"mceVisualBlocks",onPostRender:n(e,t),selectable:!0,context:"view",prependToContext:!0})};e.add("visualblocks",function(e,t){var n=o(!1);f(e,t,n),v(e,n),d(e,t,n)})}();
|
@@ -1,1325 +1,505 @@
|
|
1
1
|
(function () {
|
2
|
+
var visualchars = (function () {
|
3
|
+
'use strict';
|
2
4
|
|
3
|
-
var
|
4
|
-
|
5
|
-
|
6
|
-
|
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.visualchars.Plugin","ephox.katamari.api.Cell","tinymce.core.PluginManager","tinymce.plugins.visualchars.api.Api","tinymce.plugins.visualchars.api.Commands","tinymce.plugins.visualchars.core.Keyboard","tinymce.plugins.visualchars.ui.Buttons","global!tinymce.util.Tools.resolve","tinymce.plugins.visualchars.core.Actions","tinymce.core.util.Delay","tinymce.plugins.visualchars.core.VisualChars","tinymce.plugins.visualchars.api.Events","tinymce.plugins.visualchars.core.Data","tinymce.plugins.visualchars.core.Nodes","ephox.katamari.api.Arr","ephox.sugar.api.node.Element","ephox.sugar.api.node.Node","ephox.katamari.api.Option","global!Array","global!Error","global!String","ephox.katamari.api.Fun","global!console","global!document","ephox.sugar.api.node.NodeTypes","tinymce.plugins.visualchars.core.Html","global!Object"]
|
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
|
-
};
|
113
|
-
};
|
114
|
-
|
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
|
-
);
|
139
|
-
|
140
|
-
/**
|
141
|
-
* Api.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
|
-
*/
|
149
|
-
|
150
|
-
define(
|
151
|
-
'tinymce.plugins.visualchars.api.Api',
|
152
|
-
[
|
153
|
-
],
|
154
|
-
function () {
|
155
|
-
var get = function (toggleState) {
|
156
|
-
var isEnabled = function () {
|
157
|
-
return toggleState.get();
|
158
|
-
};
|
159
|
-
|
160
|
-
return {
|
161
|
-
isEnabled: isEnabled
|
162
|
-
};
|
5
|
+
var Cell = function (initial) {
|
6
|
+
var value = initial;
|
7
|
+
var get = function () {
|
8
|
+
return value;
|
163
9
|
};
|
164
|
-
|
165
|
-
|
166
|
-
get: get
|
10
|
+
var set = function (v) {
|
11
|
+
value = v;
|
167
12
|
};
|
168
|
-
|
169
|
-
);
|
170
|
-
/**
|
171
|
-
* Events.js
|
172
|
-
*
|
173
|
-
* Released under LGPL License.
|
174
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
175
|
-
*
|
176
|
-
* License: http://www.tinymce.com/license
|
177
|
-
* Contributing: http://www.tinymce.com/contributing
|
178
|
-
*/
|
179
|
-
|
180
|
-
define(
|
181
|
-
'tinymce.plugins.visualchars.api.Events',
|
182
|
-
[
|
183
|
-
],
|
184
|
-
function () {
|
185
|
-
var fireVisualChars = function (editor, state) {
|
186
|
-
return editor.fire('VisualChars', { state: state });
|
13
|
+
var clone = function () {
|
14
|
+
return Cell(get());
|
187
15
|
};
|
188
|
-
|
189
16
|
return {
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
);
|
194
|
-
/**
|
195
|
-
* Data.js
|
196
|
-
*
|
197
|
-
* Released under LGPL License.
|
198
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
199
|
-
*
|
200
|
-
* License: http://www.tinymce.com/license
|
201
|
-
* Contributing: http://www.tinymce.com/contributing
|
202
|
-
*/
|
203
|
-
|
204
|
-
define(
|
205
|
-
'tinymce.plugins.visualchars.core.Data',
|
206
|
-
[
|
207
|
-
],
|
208
|
-
function () {
|
209
|
-
var charMap = {
|
210
|
-
'\u00a0': 'nbsp',
|
211
|
-
'\u00ad': 'shy'
|
17
|
+
get: get,
|
18
|
+
set: set,
|
19
|
+
clone: clone
|
212
20
|
};
|
21
|
+
};
|
213
22
|
|
214
|
-
|
215
|
-
var key, regExp = '';
|
216
|
-
|
217
|
-
for (key in charMap) {
|
218
|
-
regExp += key;
|
219
|
-
}
|
23
|
+
var global = tinymce.util.Tools.resolve('tinymce.PluginManager');
|
220
24
|
|
221
|
-
|
25
|
+
var get = function (toggleState) {
|
26
|
+
var isEnabled = function () {
|
27
|
+
return toggleState.get();
|
222
28
|
};
|
29
|
+
return { isEnabled: isEnabled };
|
30
|
+
};
|
31
|
+
var $_91givrssjm0og28e = { get: get };
|
223
32
|
|
224
|
-
|
225
|
-
|
33
|
+
var fireVisualChars = function (editor, state) {
|
34
|
+
return editor.fire('VisualChars', { state: state });
|
35
|
+
};
|
36
|
+
var $_bdr3mcsvjm0og28h = { fireVisualChars: fireVisualChars };
|
226
37
|
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
|
38
|
+
var charMap = {
|
39
|
+
'\xA0': 'nbsp',
|
40
|
+
'\xAD': 'shy'
|
41
|
+
};
|
42
|
+
var charMapToRegExp = function (charMap, global) {
|
43
|
+
var key, regExp = '';
|
44
|
+
for (key in charMap) {
|
45
|
+
regExp += key;
|
46
|
+
}
|
47
|
+
return new RegExp('[' + regExp + ']', global ? 'g' : '');
|
48
|
+
};
|
49
|
+
var charMapToSelector = function (charMap) {
|
50
|
+
var key, selector = '';
|
51
|
+
for (key in charMap) {
|
52
|
+
if (selector) {
|
53
|
+
selector += ',';
|
232
54
|
}
|
55
|
+
selector += 'span.mce-' + charMap[key];
|
56
|
+
}
|
57
|
+
return selector;
|
58
|
+
};
|
59
|
+
var $_aa0v31sxjm0og28p = {
|
60
|
+
charMap: charMap,
|
61
|
+
regExp: charMapToRegExp(charMap),
|
62
|
+
regExpGlobal: charMapToRegExp(charMap, true),
|
63
|
+
selector: charMapToSelector(charMap),
|
64
|
+
charMapToRegExp: charMapToRegExp,
|
65
|
+
charMapToSelector: charMapToSelector
|
66
|
+
};
|
233
67
|
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
return {
|
238
|
-
charMap: charMap,
|
239
|
-
regExp: charMapToRegExp(charMap),
|
240
|
-
regExpGlobal: charMapToRegExp(charMap, true),
|
241
|
-
selector: charMapToSelector(charMap),
|
242
|
-
charMapToRegExp: charMapToRegExp,
|
243
|
-
charMapToSelector: charMapToSelector
|
244
|
-
};
|
245
|
-
}
|
246
|
-
);
|
247
|
-
defineGlobal("global!Array", Array);
|
248
|
-
defineGlobal("global!Error", Error);
|
249
|
-
define(
|
250
|
-
'ephox.katamari.api.Fun',
|
251
|
-
|
252
|
-
[
|
253
|
-
'global!Array',
|
254
|
-
'global!Error'
|
255
|
-
],
|
256
|
-
|
257
|
-
function (Array, Error) {
|
258
|
-
|
259
|
-
var noop = function () { };
|
260
|
-
|
261
|
-
var noarg = function (f) {
|
262
|
-
return function () {
|
263
|
-
return f();
|
264
|
-
};
|
265
|
-
};
|
266
|
-
|
267
|
-
var compose = function (fa, fb) {
|
268
|
-
return function () {
|
269
|
-
return fa(fb.apply(null, arguments));
|
270
|
-
};
|
271
|
-
};
|
272
|
-
|
273
|
-
var constant = function (value) {
|
274
|
-
return function () {
|
275
|
-
return value;
|
276
|
-
};
|
277
|
-
};
|
278
|
-
|
279
|
-
var identity = function (x) {
|
280
|
-
return x;
|
281
|
-
};
|
282
|
-
|
283
|
-
var tripleEquals = function(a, b) {
|
284
|
-
return a === b;
|
285
|
-
};
|
286
|
-
|
287
|
-
// Don't use array slice(arguments), makes the whole function unoptimisable on Chrome
|
288
|
-
var curry = function (f) {
|
289
|
-
// equivalent to arguments.slice(1)
|
290
|
-
// starting at 1 because 0 is the f, makes things tricky.
|
291
|
-
// Pay attention to what variable is where, and the -1 magic.
|
292
|
-
// thankfully, we have tests for this.
|
293
|
-
var args = new Array(arguments.length - 1);
|
294
|
-
for (var i = 1; i < arguments.length; i++) args[i-1] = arguments[i];
|
295
|
-
|
296
|
-
return function () {
|
297
|
-
var newArgs = new Array(arguments.length);
|
298
|
-
for (var j = 0; j < newArgs.length; j++) newArgs[j] = arguments[j];
|
299
|
-
|
300
|
-
var all = args.concat(newArgs);
|
301
|
-
return f.apply(null, all);
|
302
|
-
};
|
303
|
-
};
|
304
|
-
|
305
|
-
var not = function (f) {
|
306
|
-
return function () {
|
307
|
-
return !f.apply(null, arguments);
|
308
|
-
};
|
309
|
-
};
|
310
|
-
|
311
|
-
var die = function (msg) {
|
312
|
-
return function () {
|
313
|
-
throw new Error(msg);
|
314
|
-
};
|
315
|
-
};
|
316
|
-
|
317
|
-
var apply = function (f) {
|
318
|
-
return f();
|
319
|
-
};
|
320
|
-
|
321
|
-
var call = function(f) {
|
322
|
-
f();
|
323
|
-
};
|
324
|
-
|
325
|
-
var never = constant(false);
|
326
|
-
var always = constant(true);
|
327
|
-
|
328
|
-
|
329
|
-
return {
|
330
|
-
noop: noop,
|
331
|
-
noarg: noarg,
|
332
|
-
compose: compose,
|
333
|
-
constant: constant,
|
334
|
-
identity: identity,
|
335
|
-
tripleEquals: tripleEquals,
|
336
|
-
curry: curry,
|
337
|
-
not: not,
|
338
|
-
die: die,
|
339
|
-
apply: apply,
|
340
|
-
call: call,
|
341
|
-
never: never,
|
342
|
-
always: always
|
343
|
-
};
|
344
|
-
}
|
345
|
-
);
|
346
|
-
|
347
|
-
defineGlobal("global!Object", Object);
|
348
|
-
define(
|
349
|
-
'ephox.katamari.api.Option',
|
350
|
-
|
351
|
-
[
|
352
|
-
'ephox.katamari.api.Fun',
|
353
|
-
'global!Object'
|
354
|
-
],
|
355
|
-
|
356
|
-
function (Fun, Object) {
|
357
|
-
|
358
|
-
var never = Fun.never;
|
359
|
-
var always = Fun.always;
|
360
|
-
|
361
|
-
/**
|
362
|
-
Option objects support the following methods:
|
363
|
-
|
364
|
-
fold :: this Option a -> ((() -> b, a -> b)) -> Option b
|
365
|
-
|
366
|
-
is :: this Option a -> a -> Boolean
|
367
|
-
|
368
|
-
isSome :: this Option a -> () -> Boolean
|
369
|
-
|
370
|
-
isNone :: this Option a -> () -> Boolean
|
371
|
-
|
372
|
-
getOr :: this Option a -> a -> a
|
373
|
-
|
374
|
-
getOrThunk :: this Option a -> (() -> a) -> a
|
375
|
-
|
376
|
-
getOrDie :: this Option a -> String -> a
|
377
|
-
|
378
|
-
or :: this Option a -> Option a -> Option a
|
379
|
-
- if some: return self
|
380
|
-
- if none: return opt
|
381
|
-
|
382
|
-
orThunk :: this Option a -> (() -> Option a) -> Option a
|
383
|
-
- Same as "or", but uses a thunk instead of a value
|
384
|
-
|
385
|
-
map :: this Option a -> (a -> b) -> Option b
|
386
|
-
- "fmap" operation on the Option Functor.
|
387
|
-
- same as 'each'
|
388
|
-
|
389
|
-
ap :: this Option a -> Option (a -> b) -> Option b
|
390
|
-
- "apply" operation on the Option Apply/Applicative.
|
391
|
-
- Equivalent to <*> in Haskell/PureScript.
|
392
|
-
|
393
|
-
each :: this Option a -> (a -> b) -> undefined
|
394
|
-
- similar to 'map', but doesn't return a value.
|
395
|
-
- intended for clarity when performing side effects.
|
396
|
-
|
397
|
-
bind :: this Option a -> (a -> Option b) -> Option b
|
398
|
-
- "bind"/"flatMap" operation on the Option Bind/Monad.
|
399
|
-
- Equivalent to >>= in Haskell/PureScript; flatMap in Scala.
|
400
|
-
|
401
|
-
flatten :: {this Option (Option a))} -> () -> Option a
|
402
|
-
- "flatten"/"join" operation on the Option Monad.
|
403
|
-
|
404
|
-
exists :: this Option a -> (a -> Boolean) -> Boolean
|
405
|
-
|
406
|
-
forall :: this Option a -> (a -> Boolean) -> Boolean
|
407
|
-
|
408
|
-
filter :: this Option a -> (a -> Boolean) -> Option a
|
409
|
-
|
410
|
-
equals :: this Option a -> Option a -> Boolean
|
411
|
-
|
412
|
-
equals_ :: this Option a -> (Option a, a -> Boolean) -> Boolean
|
413
|
-
|
414
|
-
toArray :: this Option a -> () -> [a]
|
415
|
-
|
416
|
-
*/
|
417
|
-
|
418
|
-
var none = function () { return NONE; };
|
419
|
-
|
420
|
-
var NONE = (function () {
|
421
|
-
var eq = function (o) {
|
422
|
-
return o.isNone();
|
423
|
-
};
|
424
|
-
|
425
|
-
// inlined from peanut, maybe a micro-optimisation?
|
426
|
-
var call = function (thunk) { return thunk(); };
|
427
|
-
var id = function (n) { return n; };
|
428
|
-
var noop = function () { };
|
429
|
-
|
430
|
-
var me = {
|
431
|
-
fold: function (n, s) { return n(); },
|
432
|
-
is: never,
|
433
|
-
isSome: never,
|
434
|
-
isNone: always,
|
435
|
-
getOr: id,
|
436
|
-
getOrThunk: call,
|
437
|
-
getOrDie: function (msg) {
|
438
|
-
throw new Error(msg || 'error: getOrDie called on none.');
|
439
|
-
},
|
440
|
-
or: id,
|
441
|
-
orThunk: call,
|
442
|
-
map: none,
|
443
|
-
ap: none,
|
444
|
-
each: noop,
|
445
|
-
bind: none,
|
446
|
-
flatten: none,
|
447
|
-
exists: never,
|
448
|
-
forall: always,
|
449
|
-
filter: none,
|
450
|
-
equals: eq,
|
451
|
-
equals_: eq,
|
452
|
-
toArray: function () { return []; },
|
453
|
-
toString: Fun.constant("none()")
|
454
|
-
};
|
455
|
-
if (Object.freeze) Object.freeze(me);
|
456
|
-
return me;
|
457
|
-
})();
|
458
|
-
|
459
|
-
|
460
|
-
/** some :: a -> Option a */
|
461
|
-
var some = function (a) {
|
462
|
-
|
463
|
-
// inlined from peanut, maybe a micro-optimisation?
|
464
|
-
var constant_a = function () { return a; };
|
465
|
-
|
466
|
-
var self = function () {
|
467
|
-
// can't Fun.constant this one
|
468
|
-
return me;
|
469
|
-
};
|
470
|
-
|
471
|
-
var map = function (f) {
|
472
|
-
return some(f(a));
|
473
|
-
};
|
474
|
-
|
475
|
-
var bind = function (f) {
|
476
|
-
return f(a);
|
477
|
-
};
|
478
|
-
|
479
|
-
var me = {
|
480
|
-
fold: function (n, s) { return s(a); },
|
481
|
-
is: function (v) { return a === v; },
|
482
|
-
isSome: always,
|
483
|
-
isNone: never,
|
484
|
-
getOr: constant_a,
|
485
|
-
getOrThunk: constant_a,
|
486
|
-
getOrDie: constant_a,
|
487
|
-
or: self,
|
488
|
-
orThunk: self,
|
489
|
-
map: map,
|
490
|
-
ap: function (optfab) {
|
491
|
-
return optfab.fold(none, function(fab) {
|
492
|
-
return some(fab(a));
|
493
|
-
});
|
494
|
-
},
|
495
|
-
each: function (f) {
|
496
|
-
f(a);
|
497
|
-
},
|
498
|
-
bind: bind,
|
499
|
-
flatten: constant_a,
|
500
|
-
exists: bind,
|
501
|
-
forall: bind,
|
502
|
-
filter: function (f) {
|
503
|
-
return f(a) ? me : NONE;
|
504
|
-
},
|
505
|
-
equals: function (o) {
|
506
|
-
return o.is(a);
|
507
|
-
},
|
508
|
-
equals_: function (o, elementEq) {
|
509
|
-
return o.fold(
|
510
|
-
never,
|
511
|
-
function (b) { return elementEq(a, b); }
|
512
|
-
);
|
513
|
-
},
|
514
|
-
toArray: function () {
|
515
|
-
return [a];
|
516
|
-
},
|
517
|
-
toString: function () {
|
518
|
-
return 'some(' + a + ')';
|
519
|
-
}
|
520
|
-
};
|
521
|
-
return me;
|
522
|
-
};
|
523
|
-
|
524
|
-
/** from :: undefined|null|a -> Option a */
|
525
|
-
var from = function (value) {
|
526
|
-
return value === null || value === undefined ? NONE : some(value);
|
527
|
-
};
|
528
|
-
|
529
|
-
return {
|
530
|
-
some: some,
|
531
|
-
none: none,
|
532
|
-
from: from
|
533
|
-
};
|
534
|
-
}
|
535
|
-
);
|
536
|
-
|
537
|
-
defineGlobal("global!String", String);
|
538
|
-
define(
|
539
|
-
'ephox.katamari.api.Arr',
|
540
|
-
|
541
|
-
[
|
542
|
-
'ephox.katamari.api.Option',
|
543
|
-
'global!Array',
|
544
|
-
'global!Error',
|
545
|
-
'global!String'
|
546
|
-
],
|
547
|
-
|
548
|
-
function (Option, Array, Error, String) {
|
549
|
-
// Use the native Array.indexOf if it is available (IE9+) otherwise fall back to manual iteration
|
550
|
-
// https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Array/indexOf
|
551
|
-
var rawIndexOf = (function () {
|
552
|
-
var pIndexOf = Array.prototype.indexOf;
|
553
|
-
|
554
|
-
var fastIndex = function (xs, x) { return pIndexOf.call(xs, x); };
|
555
|
-
|
556
|
-
var slowIndex = function(xs, x) { return slowIndexOf(xs, x); };
|
557
|
-
|
558
|
-
return pIndexOf === undefined ? slowIndex : fastIndex;
|
559
|
-
})();
|
560
|
-
|
561
|
-
var indexOf = function (xs, x) {
|
562
|
-
// The rawIndexOf method does not wrap up in an option. This is for performance reasons.
|
563
|
-
var r = rawIndexOf(xs, x);
|
564
|
-
return r === -1 ? Option.none() : Option.some(r);
|
565
|
-
};
|
566
|
-
|
567
|
-
var contains = function (xs, x) {
|
568
|
-
return rawIndexOf(xs, x) > -1;
|
569
|
-
};
|
570
|
-
|
571
|
-
// Using findIndex is likely less optimal in Chrome (dynamic return type instead of bool)
|
572
|
-
// but if we need that micro-optimisation we can inline it later.
|
573
|
-
var exists = function (xs, pred) {
|
574
|
-
return findIndex(xs, pred).isSome();
|
575
|
-
};
|
576
|
-
|
577
|
-
var range = function (num, f) {
|
578
|
-
var r = [];
|
579
|
-
for (var i = 0; i < num; i++) {
|
580
|
-
r.push(f(i));
|
581
|
-
}
|
582
|
-
return r;
|
68
|
+
var constant = function (value) {
|
69
|
+
return function () {
|
70
|
+
return value;
|
583
71
|
};
|
72
|
+
};
|
584
73
|
|
585
|
-
// It's a total micro optimisation, but these do make some difference.
|
586
|
-
// Particularly for browsers other than Chrome.
|
587
|
-
// - length caching
|
588
|
-
// http://jsperf.com/browser-diet-jquery-each-vs-for-loop/69
|
589
|
-
// - not using push
|
590
|
-
// http://jsperf.com/array-direct-assignment-vs-push/2
|
591
74
|
|
592
|
-
var chunk = function (array, size) {
|
593
|
-
var r = [];
|
594
|
-
for (var i = 0; i < array.length; i += size) {
|
595
|
-
var s = array.slice(i, i + size);
|
596
|
-
r.push(s);
|
597
|
-
}
|
598
|
-
return r;
|
599
|
-
};
|
600
75
|
|
601
|
-
var map = function(xs, f) {
|
602
|
-
// pre-allocating array size when it's guaranteed to be known
|
603
|
-
// http://jsperf.com/push-allocated-vs-dynamic/22
|
604
|
-
var len = xs.length;
|
605
|
-
var r = new Array(len);
|
606
|
-
for (var i = 0; i < len; i++) {
|
607
|
-
var x = xs[i];
|
608
|
-
r[i] = f(x, i, xs);
|
609
|
-
}
|
610
|
-
return r;
|
611
|
-
};
|
612
76
|
|
613
|
-
// Unwound implementing other functions in terms of each.
|
614
|
-
// The code size is roughly the same, and it should allow for better optimisation.
|
615
|
-
var each = function(xs, f) {
|
616
|
-
for (var i = 0, len = xs.length; i < len; i++) {
|
617
|
-
var x = xs[i];
|
618
|
-
f(x, i, xs);
|
619
|
-
}
|
620
|
-
};
|
621
77
|
|
622
|
-
var eachr = function (xs, f) {
|
623
|
-
for (var i = xs.length - 1; i >= 0; i--) {
|
624
|
-
var x = xs[i];
|
625
|
-
f(x, i, xs);
|
626
|
-
}
|
627
|
-
};
|
628
78
|
|
629
|
-
var partition = function(xs, pred) {
|
630
|
-
var pass = [];
|
631
|
-
var fail = [];
|
632
|
-
for (var i = 0, len = xs.length; i < len; i++) {
|
633
|
-
var x = xs[i];
|
634
|
-
var arr = pred(x, i, xs) ? pass : fail;
|
635
|
-
arr.push(x);
|
636
|
-
}
|
637
|
-
return { pass: pass, fail: fail };
|
638
|
-
};
|
639
79
|
|
640
|
-
|
641
|
-
|
642
|
-
for (var i = 0, len = xs.length; i < len; i++) {
|
643
|
-
var x = xs[i];
|
644
|
-
if (pred(x, i, xs)) {
|
645
|
-
r.push(x);
|
646
|
-
}
|
647
|
-
}
|
648
|
-
return r;
|
649
|
-
};
|
80
|
+
var never = constant(false);
|
81
|
+
var always = constant(true);
|
650
82
|
|
651
|
-
|
652
|
-
|
653
|
-
|
654
|
-
|
655
|
-
|
656
|
-
|
657
|
-
|
658
|
-
|
659
|
-
|
660
|
-
|
661
|
-
|
662
|
-
|
663
|
-
|
83
|
+
var never$1 = never;
|
84
|
+
var always$1 = always;
|
85
|
+
var none = function () {
|
86
|
+
return NONE;
|
87
|
+
};
|
88
|
+
var NONE = function () {
|
89
|
+
var eq = function (o) {
|
90
|
+
return o.isNone();
|
91
|
+
};
|
92
|
+
var call$$1 = function (thunk) {
|
93
|
+
return thunk();
|
94
|
+
};
|
95
|
+
var id = function (n) {
|
96
|
+
return n;
|
97
|
+
};
|
98
|
+
var noop$$1 = function () {
|
99
|
+
};
|
100
|
+
var nul = function () {
|
101
|
+
return null;
|
102
|
+
};
|
103
|
+
var undef = function () {
|
104
|
+
return undefined;
|
105
|
+
};
|
106
|
+
var me = {
|
107
|
+
fold: function (n, s) {
|
108
|
+
return n();
|
109
|
+
},
|
110
|
+
is: never$1,
|
111
|
+
isSome: never$1,
|
112
|
+
isNone: always$1,
|
113
|
+
getOr: id,
|
114
|
+
getOrThunk: call$$1,
|
115
|
+
getOrDie: function (msg) {
|
116
|
+
throw new Error(msg || 'error: getOrDie called on none.');
|
117
|
+
},
|
118
|
+
getOrNull: nul,
|
119
|
+
getOrUndefined: undef,
|
120
|
+
or: id,
|
121
|
+
orThunk: call$$1,
|
122
|
+
map: none,
|
123
|
+
ap: none,
|
124
|
+
each: noop$$1,
|
125
|
+
bind: none,
|
126
|
+
flatten: none,
|
127
|
+
exists: never$1,
|
128
|
+
forall: always$1,
|
129
|
+
filter: none,
|
130
|
+
equals: eq,
|
131
|
+
equals_: eq,
|
132
|
+
toArray: function () {
|
664
133
|
return [];
|
665
|
-
}
|
666
|
-
|
667
|
-
|
668
|
-
|
669
|
-
|
670
|
-
|
671
|
-
|
672
|
-
|
673
|
-
|
674
|
-
|
675
|
-
|
676
|
-
|
677
|
-
|
678
|
-
group.push(x);
|
679
|
-
}
|
680
|
-
if (group.length !== 0) {
|
681
|
-
r.push(group);
|
682
|
-
}
|
683
|
-
return r;
|
684
|
-
}
|
685
|
-
};
|
686
|
-
|
687
|
-
var foldr = function (xs, f, acc) {
|
688
|
-
eachr(xs, function (x) {
|
689
|
-
acc = f(acc, x);
|
690
|
-
});
|
691
|
-
return acc;
|
692
|
-
};
|
693
|
-
|
694
|
-
var foldl = function (xs, f, acc) {
|
695
|
-
each(xs, function (x) {
|
696
|
-
acc = f(acc, x);
|
697
|
-
});
|
698
|
-
return acc;
|
699
|
-
};
|
700
|
-
|
701
|
-
var find = function (xs, pred) {
|
702
|
-
for (var i = 0, len = xs.length; i < len; i++) {
|
703
|
-
var x = xs[i];
|
704
|
-
if (pred(x, i, xs)) {
|
705
|
-
return Option.some(x);
|
706
|
-
}
|
707
|
-
}
|
708
|
-
return Option.none();
|
709
|
-
};
|
710
|
-
|
711
|
-
var findIndex = function (xs, pred) {
|
712
|
-
for (var i = 0, len = xs.length; i < len; i++) {
|
713
|
-
var x = xs[i];
|
714
|
-
if (pred(x, i, xs)) {
|
715
|
-
return Option.some(i);
|
716
|
-
}
|
717
|
-
}
|
718
|
-
|
719
|
-
return Option.none();
|
720
|
-
};
|
721
|
-
|
722
|
-
var slowIndexOf = function (xs, x) {
|
723
|
-
for (var i = 0, len = xs.length; i < len; ++i) {
|
724
|
-
if (xs[i] === x) {
|
725
|
-
return i;
|
726
|
-
}
|
727
|
-
}
|
728
|
-
|
729
|
-
return -1;
|
730
|
-
};
|
731
|
-
|
732
|
-
var push = Array.prototype.push;
|
733
|
-
var flatten = function (xs) {
|
734
|
-
// Note, this is possible because push supports multiple arguments:
|
735
|
-
// http://jsperf.com/concat-push/6
|
736
|
-
// Note that in the past, concat() would silently work (very slowly) for array-like objects.
|
737
|
-
// With this change it will throw an error.
|
738
|
-
var r = [];
|
739
|
-
for (var i = 0, len = xs.length; i < len; ++i) {
|
740
|
-
// Ensure that each value is an array itself
|
741
|
-
if (! Array.prototype.isPrototypeOf(xs[i])) throw new Error('Arr.flatten item ' + i + ' was not an array, input: ' + xs);
|
742
|
-
push.apply(r, xs[i]);
|
743
|
-
}
|
744
|
-
return r;
|
745
|
-
};
|
746
|
-
|
747
|
-
var bind = function (xs, f) {
|
748
|
-
var output = map(xs, f);
|
749
|
-
return flatten(output);
|
750
|
-
};
|
751
|
-
|
752
|
-
var forall = function (xs, pred) {
|
753
|
-
for (var i = 0, len = xs.length; i < len; ++i) {
|
754
|
-
var x = xs[i];
|
755
|
-
if (pred(x, i, xs) !== true) {
|
756
|
-
return false;
|
757
|
-
}
|
758
|
-
}
|
759
|
-
return true;
|
760
|
-
};
|
761
|
-
|
762
|
-
var equal = function (a1, a2) {
|
763
|
-
return a1.length === a2.length && forall(a1, function (x, i) {
|
764
|
-
return x === a2[i];
|
765
|
-
});
|
766
|
-
};
|
767
|
-
|
768
|
-
var slice = Array.prototype.slice;
|
769
|
-
var reverse = function (xs) {
|
770
|
-
var r = slice.call(xs, 0);
|
771
|
-
r.reverse();
|
772
|
-
return r;
|
773
|
-
};
|
774
|
-
|
775
|
-
var difference = function (a1, a2) {
|
776
|
-
return filter(a1, function (x) {
|
777
|
-
return !contains(a2, x);
|
778
|
-
});
|
779
|
-
};
|
780
|
-
|
781
|
-
var mapToObject = function(xs, f) {
|
782
|
-
var r = {};
|
783
|
-
for (var i = 0, len = xs.length; i < len; i++) {
|
784
|
-
var x = xs[i];
|
785
|
-
r[String(x)] = f(x, i);
|
786
|
-
}
|
787
|
-
return r;
|
788
|
-
};
|
789
|
-
|
790
|
-
var pure = function(x) {
|
791
|
-
return [x];
|
792
|
-
};
|
793
|
-
|
794
|
-
var sort = function (xs, comparator) {
|
795
|
-
var copy = slice.call(xs, 0);
|
796
|
-
copy.sort(comparator);
|
797
|
-
return copy;
|
798
|
-
};
|
799
|
-
|
800
|
-
var head = function (xs) {
|
801
|
-
return xs.length === 0 ? Option.none() : Option.some(xs[0]);
|
802
|
-
};
|
803
|
-
|
804
|
-
var last = function (xs) {
|
805
|
-
return xs.length === 0 ? Option.none() : Option.some(xs[xs.length - 1]);
|
134
|
+
},
|
135
|
+
toString: constant('none()')
|
136
|
+
};
|
137
|
+
if (Object.freeze)
|
138
|
+
Object.freeze(me);
|
139
|
+
return me;
|
140
|
+
}();
|
141
|
+
var some = function (a) {
|
142
|
+
var constant_a = function () {
|
143
|
+
return a;
|
144
|
+
};
|
145
|
+
var self = function () {
|
146
|
+
return me;
|
806
147
|
};
|
807
|
-
|
808
|
-
|
148
|
+
var map = function (f) {
|
149
|
+
return some(f(a));
|
150
|
+
};
|
151
|
+
var bind = function (f) {
|
152
|
+
return f(a);
|
153
|
+
};
|
154
|
+
var me = {
|
155
|
+
fold: function (n, s) {
|
156
|
+
return s(a);
|
157
|
+
},
|
158
|
+
is: function (v) {
|
159
|
+
return a === v;
|
160
|
+
},
|
161
|
+
isSome: always$1,
|
162
|
+
isNone: never$1,
|
163
|
+
getOr: constant_a,
|
164
|
+
getOrThunk: constant_a,
|
165
|
+
getOrDie: constant_a,
|
166
|
+
getOrNull: constant_a,
|
167
|
+
getOrUndefined: constant_a,
|
168
|
+
or: self,
|
169
|
+
orThunk: self,
|
809
170
|
map: map,
|
810
|
-
|
811
|
-
|
812
|
-
|
813
|
-
|
814
|
-
|
815
|
-
|
816
|
-
|
817
|
-
|
818
|
-
find: find,
|
819
|
-
findIndex: findIndex,
|
820
|
-
flatten: flatten,
|
171
|
+
ap: function (optfab) {
|
172
|
+
return optfab.fold(none, function (fab) {
|
173
|
+
return some(fab(a));
|
174
|
+
});
|
175
|
+
},
|
176
|
+
each: function (f) {
|
177
|
+
f(a);
|
178
|
+
},
|
821
179
|
bind: bind,
|
822
|
-
|
823
|
-
exists:
|
824
|
-
|
825
|
-
|
826
|
-
|
827
|
-
|
828
|
-
|
829
|
-
|
830
|
-
|
831
|
-
|
832
|
-
|
833
|
-
|
834
|
-
|
835
|
-
|
836
|
-
|
837
|
-
|
838
|
-
|
839
|
-
|
840
|
-
|
841
|
-
'ephox.sugar.api.node.Element',
|
842
|
-
|
843
|
-
[
|
844
|
-
'ephox.katamari.api.Fun',
|
845
|
-
'ephox.katamari.api.Option',
|
846
|
-
'global!Error',
|
847
|
-
'global!console',
|
848
|
-
'global!document'
|
849
|
-
],
|
850
|
-
|
851
|
-
function (Fun, Option, Error, console, document) {
|
852
|
-
var fromHtml = function (html, scope) {
|
853
|
-
var doc = scope || document;
|
854
|
-
var div = doc.createElement('div');
|
855
|
-
div.innerHTML = html;
|
856
|
-
if (!div.hasChildNodes() || div.childNodes.length > 1) {
|
857
|
-
console.error('HTML does not have a single root node', html);
|
858
|
-
throw 'HTML must have a single root node';
|
180
|
+
flatten: constant_a,
|
181
|
+
exists: bind,
|
182
|
+
forall: bind,
|
183
|
+
filter: function (f) {
|
184
|
+
return f(a) ? me : NONE;
|
185
|
+
},
|
186
|
+
equals: function (o) {
|
187
|
+
return o.is(a);
|
188
|
+
},
|
189
|
+
equals_: function (o, elementEq) {
|
190
|
+
return o.fold(never$1, function (b) {
|
191
|
+
return elementEq(a, b);
|
192
|
+
});
|
193
|
+
},
|
194
|
+
toArray: function () {
|
195
|
+
return [a];
|
196
|
+
},
|
197
|
+
toString: function () {
|
198
|
+
return 'some(' + a + ')';
|
859
199
|
}
|
860
|
-
return fromDom(div.childNodes[0]);
|
861
200
|
};
|
201
|
+
return me;
|
202
|
+
};
|
203
|
+
var from = function (value) {
|
204
|
+
return value === null || value === undefined ? NONE : some(value);
|
205
|
+
};
|
206
|
+
var Option = {
|
207
|
+
some: some,
|
208
|
+
none: none,
|
209
|
+
from: from
|
210
|
+
};
|
862
211
|
|
863
|
-
|
864
|
-
|
865
|
-
|
866
|
-
|
867
|
-
|
868
|
-
|
869
|
-
|
870
|
-
|
871
|
-
|
872
|
-
|
873
|
-
|
874
|
-
|
875
|
-
|
876
|
-
if (node === null || node === undefined) throw new Error('Node cannot be null or undefined');
|
877
|
-
return {
|
878
|
-
dom: Fun.constant(node)
|
879
|
-
};
|
880
|
-
};
|
881
|
-
|
882
|
-
var fromPoint = function (doc, x, y) {
|
883
|
-
return Option.from(doc.dom().elementFromPoint(x, y)).map(fromDom);
|
884
|
-
};
|
885
|
-
|
886
|
-
return {
|
887
|
-
fromHtml: fromHtml,
|
888
|
-
fromTag: fromTag,
|
889
|
-
fromText: fromText,
|
890
|
-
fromDom: fromDom,
|
891
|
-
fromPoint: fromPoint
|
892
|
-
};
|
893
|
-
}
|
894
|
-
);
|
895
|
-
|
896
|
-
define(
|
897
|
-
'ephox.sugar.api.node.NodeTypes',
|
898
|
-
|
899
|
-
[
|
900
|
-
|
901
|
-
],
|
902
|
-
|
903
|
-
function () {
|
904
|
-
return {
|
905
|
-
ATTRIBUTE: 2,
|
906
|
-
CDATA_SECTION: 4,
|
907
|
-
COMMENT: 8,
|
908
|
-
DOCUMENT: 9,
|
909
|
-
DOCUMENT_TYPE: 10,
|
910
|
-
DOCUMENT_FRAGMENT: 11,
|
911
|
-
ELEMENT: 1,
|
912
|
-
TEXT: 3,
|
913
|
-
PROCESSING_INSTRUCTION: 7,
|
914
|
-
ENTITY_REFERENCE: 5,
|
915
|
-
ENTITY: 6,
|
916
|
-
NOTATION: 12
|
212
|
+
var typeOf = function (x) {
|
213
|
+
if (x === null)
|
214
|
+
return 'null';
|
215
|
+
var t = typeof x;
|
216
|
+
if (t === 'object' && Array.prototype.isPrototypeOf(x))
|
217
|
+
return 'array';
|
218
|
+
if (t === 'object' && String.prototype.isPrototypeOf(x))
|
219
|
+
return 'string';
|
220
|
+
return t;
|
221
|
+
};
|
222
|
+
var isType = function (type) {
|
223
|
+
return function (value) {
|
224
|
+
return typeOf(value) === type;
|
917
225
|
};
|
918
|
-
}
|
919
|
-
);
|
920
|
-
define(
|
921
|
-
'ephox.sugar.api.node.Node',
|
226
|
+
};
|
922
227
|
|
923
|
-
[
|
924
|
-
'ephox.sugar.api.node.NodeTypes'
|
925
|
-
],
|
926
228
|
|
927
|
-
function (NodeTypes) {
|
928
|
-
var name = function (element) {
|
929
|
-
var r = element.dom().nodeName;
|
930
|
-
return r.toLowerCase();
|
931
|
-
};
|
932
229
|
|
933
|
-
var type = function (element) {
|
934
|
-
return element.dom().nodeType;
|
935
|
-
};
|
936
230
|
|
937
|
-
var value = function (element) {
|
938
|
-
return element.dom().nodeValue;
|
939
|
-
};
|
940
231
|
|
941
|
-
var isType = function (t) {
|
942
|
-
return function (element) {
|
943
|
-
return type(element) === t;
|
944
|
-
};
|
945
|
-
};
|
946
232
|
|
947
|
-
|
948
|
-
return type(element) === NodeTypes.COMMENT || name(element) === '#comment';
|
949
|
-
};
|
233
|
+
var isFunction = isType('function');
|
950
234
|
|
951
|
-
|
952
|
-
var
|
953
|
-
var
|
235
|
+
var map = function (xs, f) {
|
236
|
+
var len = xs.length;
|
237
|
+
var r = new Array(len);
|
238
|
+
for (var i = 0; i < len; i++) {
|
239
|
+
var x = xs[i];
|
240
|
+
r[i] = f(x, i, xs);
|
241
|
+
}
|
242
|
+
return r;
|
243
|
+
};
|
244
|
+
var each = function (xs, f) {
|
245
|
+
for (var i = 0, len = xs.length; i < len; i++) {
|
246
|
+
var x = xs[i];
|
247
|
+
f(x, i, xs);
|
248
|
+
}
|
249
|
+
};
|
954
250
|
|
955
|
-
return {
|
956
|
-
name: name,
|
957
|
-
type: type,
|
958
|
-
value: value,
|
959
|
-
isElement: isElement,
|
960
|
-
isText: isText,
|
961
|
-
isDocument: isDocument,
|
962
|
-
isComment: isComment
|
963
|
-
};
|
964
|
-
}
|
965
|
-
);
|
966
251
|
|
967
|
-
/**
|
968
|
-
* Html.js
|
969
|
-
*
|
970
|
-
* Released under LGPL License.
|
971
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
972
|
-
*
|
973
|
-
* License: http://www.tinymce.com/license
|
974
|
-
* Contributing: http://www.tinymce.com/contributing
|
975
|
-
*/
|
976
252
|
|
977
|
-
define(
|
978
|
-
'tinymce.plugins.visualchars.core.Html',
|
979
|
-
[
|
980
|
-
'tinymce.plugins.visualchars.core.Data'
|
981
|
-
],
|
982
|
-
function (Data) {
|
983
|
-
var wrapCharWithSpan = function (value) {
|
984
|
-
return '<span data-mce-bogus="1" class="mce-' + Data.charMap[value] + '">' + value + '</span>';
|
985
|
-
};
|
986
253
|
|
987
|
-
return {
|
988
|
-
wrapCharWithSpan: wrapCharWithSpan
|
989
|
-
};
|
990
|
-
}
|
991
|
-
);
|
992
254
|
|
993
|
-
/**
|
994
|
-
* Nodes.js
|
995
|
-
*
|
996
|
-
* Released under LGPL License.
|
997
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
998
|
-
*
|
999
|
-
* License: http://www.tinymce.com/license
|
1000
|
-
* Contributing: http://www.tinymce.com/contributing
|
1001
|
-
*/
|
1002
255
|
|
1003
|
-
define(
|
1004
|
-
'tinymce.plugins.visualchars.core.Nodes',
|
1005
|
-
[
|
1006
|
-
'ephox.katamari.api.Arr',
|
1007
|
-
'ephox.sugar.api.node.Element',
|
1008
|
-
'ephox.sugar.api.node.Node',
|
1009
|
-
'tinymce.plugins.visualchars.core.Data',
|
1010
|
-
'tinymce.plugins.visualchars.core.Html'
|
1011
|
-
],
|
1012
|
-
function (Arr, Element, Node, Data, Html) {
|
1013
|
-
var isMatch = function (n) {
|
1014
|
-
return Node.isText(n) &&
|
1015
|
-
Node.value(n) !== undefined &&
|
1016
|
-
Data.regExp.test(Node.value(n));
|
1017
|
-
};
|
1018
256
|
|
1019
|
-
// inlined sugars PredicateFilter.descendants for file size
|
1020
|
-
var filterDescendants = function (scope, predicate) {
|
1021
|
-
var result = [];
|
1022
|
-
var dom = scope.dom();
|
1023
|
-
var children = Arr.map(dom.childNodes, Element.fromDom);
|
1024
257
|
|
1025
|
-
Arr.each(children, function (x) {
|
1026
|
-
if (predicate(x)) {
|
1027
|
-
result = result.concat([ x ]);
|
1028
|
-
}
|
1029
|
-
result = result.concat(filterDescendants(x, predicate));
|
1030
|
-
});
|
1031
|
-
return result;
|
1032
|
-
};
|
1033
258
|
|
1034
|
-
var findParentElm = function (elm, rootElm) {
|
1035
|
-
while (elm.parentNode) {
|
1036
|
-
if (elm.parentNode === rootElm) {
|
1037
|
-
return elm;
|
1038
|
-
}
|
1039
|
-
elm = elm.parentNode;
|
1040
|
-
}
|
1041
|
-
};
|
1042
259
|
|
1043
|
-
var replaceWithSpans = function (html) {
|
1044
|
-
return html.replace(Data.regExpGlobal, Html.wrapCharWithSpan);
|
1045
|
-
};
|
1046
260
|
|
1047
|
-
return {
|
1048
|
-
isMatch: isMatch,
|
1049
|
-
filterDescendants: filterDescendants,
|
1050
|
-
findParentElm: findParentElm,
|
1051
|
-
replaceWithSpans: replaceWithSpans
|
1052
|
-
};
|
1053
|
-
}
|
1054
|
-
);
|
1055
|
-
/**
|
1056
|
-
* VisualChars.js
|
1057
|
-
*
|
1058
|
-
* Released under LGPL License.
|
1059
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
1060
|
-
*
|
1061
|
-
* License: http://www.tinymce.com/license
|
1062
|
-
* Contributing: http://www.tinymce.com/contributing
|
1063
|
-
*/
|
1064
261
|
|
1065
|
-
|
1066
|
-
'tinymce.plugins.visualchars.core.VisualChars',
|
1067
|
-
[
|
1068
|
-
'tinymce.plugins.visualchars.core.Data',
|
1069
|
-
'tinymce.plugins.visualchars.core.Nodes',
|
1070
|
-
'ephox.katamari.api.Arr',
|
1071
|
-
'ephox.sugar.api.node.Element',
|
1072
|
-
'ephox.sugar.api.node.Node'
|
1073
|
-
],
|
1074
|
-
function (Data, Nodes, Arr, Element, Node) {
|
1075
|
-
var show = function (editor, rootElm) {
|
1076
|
-
var node, div;
|
1077
|
-
var nodeList = Nodes.filterDescendants(Element.fromDom(rootElm), Nodes.isMatch);
|
262
|
+
var slice = Array.prototype.slice;
|
1078
263
|
|
1079
|
-
Arr.each(nodeList, function (n) {
|
1080
|
-
var withSpans = Nodes.replaceWithSpans(Node.value(n));
|
1081
264
|
|
1082
|
-
div = editor.dom.create('div', null, withSpans);
|
1083
|
-
while ((node = div.lastChild)) {
|
1084
|
-
editor.dom.insertAfter(node, n.dom());
|
1085
|
-
}
|
1086
265
|
|
1087
|
-
editor.dom.remove(n.dom());
|
1088
|
-
});
|
1089
|
-
};
|
1090
266
|
|
1091
|
-
var hide = function (editor, body) {
|
1092
|
-
var nodeList = editor.dom.select(Data.selector, body);
|
1093
267
|
|
1094
|
-
Arr.each(nodeList, function (node) {
|
1095
|
-
editor.dom.remove(node, 1);
|
1096
|
-
});
|
1097
|
-
};
|
1098
268
|
|
1099
|
-
var toggle = function (editor) {
|
1100
|
-
var body = editor.getBody();
|
1101
|
-
var bookmark = editor.selection.getBookmark();
|
1102
|
-
var parentNode = Nodes.findParentElm(editor.selection.getNode(), body);
|
1103
269
|
|
1104
|
-
|
1105
|
-
|
270
|
+
var from$1 = isFunction(Array.from) ? Array.from : function (x) {
|
271
|
+
return slice.call(x);
|
272
|
+
};
|
1106
273
|
|
1107
|
-
|
1108
|
-
|
274
|
+
var fromHtml = function (html, scope) {
|
275
|
+
var doc = scope || document;
|
276
|
+
var div = doc.createElement('div');
|
277
|
+
div.innerHTML = html;
|
278
|
+
if (!div.hasChildNodes() || div.childNodes.length > 1) {
|
279
|
+
console.error('HTML does not have a single root node', html);
|
280
|
+
throw 'HTML must have a single root node';
|
281
|
+
}
|
282
|
+
return fromDom(div.childNodes[0]);
|
283
|
+
};
|
284
|
+
var fromTag = function (tag, scope) {
|
285
|
+
var doc = scope || document;
|
286
|
+
var node = doc.createElement(tag);
|
287
|
+
return fromDom(node);
|
288
|
+
};
|
289
|
+
var fromText = function (text, scope) {
|
290
|
+
var doc = scope || document;
|
291
|
+
var node = doc.createTextNode(text);
|
292
|
+
return fromDom(node);
|
293
|
+
};
|
294
|
+
var fromDom = function (node) {
|
295
|
+
if (node === null || node === undefined)
|
296
|
+
throw new Error('Node cannot be null or undefined');
|
297
|
+
return { dom: constant(node) };
|
298
|
+
};
|
299
|
+
var fromPoint = function (docElm, x, y) {
|
300
|
+
var doc = docElm.dom();
|
301
|
+
return Option.from(doc.elementFromPoint(x, y)).map(fromDom);
|
302
|
+
};
|
303
|
+
var Element$$1 = {
|
304
|
+
fromHtml: fromHtml,
|
305
|
+
fromTag: fromTag,
|
306
|
+
fromText: fromText,
|
307
|
+
fromDom: fromDom,
|
308
|
+
fromPoint: fromPoint
|
309
|
+
};
|
1109
310
|
|
1110
|
-
|
1111
|
-
|
311
|
+
var $_5ao1w8t6jm0og29y = {
|
312
|
+
ATTRIBUTE: Node.ATTRIBUTE_NODE,
|
313
|
+
CDATA_SECTION: Node.CDATA_SECTION_NODE,
|
314
|
+
COMMENT: Node.COMMENT_NODE,
|
315
|
+
DOCUMENT: Node.DOCUMENT_NODE,
|
316
|
+
DOCUMENT_TYPE: Node.DOCUMENT_TYPE_NODE,
|
317
|
+
DOCUMENT_FRAGMENT: Node.DOCUMENT_FRAGMENT_NODE,
|
318
|
+
ELEMENT: Node.ELEMENT_NODE,
|
319
|
+
TEXT: Node.TEXT_NODE,
|
320
|
+
PROCESSING_INSTRUCTION: Node.PROCESSING_INSTRUCTION_NODE,
|
321
|
+
ENTITY_REFERENCE: Node.ENTITY_REFERENCE_NODE,
|
322
|
+
ENTITY: Node.ENTITY_NODE,
|
323
|
+
NOTATION: Node.NOTATION_NODE
|
324
|
+
};
|
1112
325
|
|
1113
|
-
|
1114
|
-
|
1115
|
-
|
1116
|
-
|
326
|
+
var name = function (element) {
|
327
|
+
var r = element.dom().nodeName;
|
328
|
+
return r.toLowerCase();
|
329
|
+
};
|
330
|
+
var type = function (element) {
|
331
|
+
return element.dom().nodeType;
|
332
|
+
};
|
333
|
+
var value = function (element) {
|
334
|
+
return element.dom().nodeValue;
|
335
|
+
};
|
336
|
+
var isType$1 = function (t) {
|
337
|
+
return function (element) {
|
338
|
+
return type(element) === t;
|
1117
339
|
};
|
1118
|
-
}
|
1119
|
-
)
|
1120
|
-
|
1121
|
-
|
1122
|
-
|
1123
|
-
|
1124
|
-
|
1125
|
-
|
1126
|
-
|
1127
|
-
|
1128
|
-
|
1129
|
-
|
1130
|
-
|
1131
|
-
|
1132
|
-
|
1133
|
-
|
1134
|
-
'tinymce.plugins.visualchars.core.VisualChars'
|
1135
|
-
],
|
1136
|
-
function (Events, VisualChars) {
|
1137
|
-
var toggleVisualChars = function (editor, toggleState) {
|
1138
|
-
var body = editor.getBody(), selection = editor.selection, bookmark;
|
1139
|
-
|
1140
|
-
toggleState.set(!toggleState.get());
|
1141
|
-
Events.fireVisualChars(editor, toggleState.get());
|
340
|
+
};
|
341
|
+
var isComment = function (element) {
|
342
|
+
return type(element) === $_5ao1w8t6jm0og29y.COMMENT || name(element) === '#comment';
|
343
|
+
};
|
344
|
+
var isElement = isType$1($_5ao1w8t6jm0og29y.ELEMENT);
|
345
|
+
var isText = isType$1($_5ao1w8t6jm0og29y.TEXT);
|
346
|
+
var isDocument = isType$1($_5ao1w8t6jm0og29y.DOCUMENT);
|
347
|
+
var $_6qboq0t5jm0og29x = {
|
348
|
+
name: name,
|
349
|
+
type: type,
|
350
|
+
value: value,
|
351
|
+
isElement: isElement,
|
352
|
+
isText: isText,
|
353
|
+
isDocument: isDocument,
|
354
|
+
isComment: isComment
|
355
|
+
};
|
1142
356
|
|
1143
|
-
|
357
|
+
var wrapCharWithSpan = function (value) {
|
358
|
+
return '<span data-mce-bogus="1" class="mce-' + $_aa0v31sxjm0og28p.charMap[value] + '">' + value + '</span>';
|
359
|
+
};
|
360
|
+
var $_724dsdt7jm0og2a0 = { wrapCharWithSpan: wrapCharWithSpan };
|
1144
361
|
|
1145
|
-
|
1146
|
-
|
1147
|
-
|
1148
|
-
|
362
|
+
var isMatch = function (n) {
|
363
|
+
return $_6qboq0t5jm0og29x.isText(n) && $_6qboq0t5jm0og29x.value(n) !== undefined && $_aa0v31sxjm0og28p.regExp.test($_6qboq0t5jm0og29x.value(n));
|
364
|
+
};
|
365
|
+
var filterDescendants = function (scope, predicate) {
|
366
|
+
var result = [];
|
367
|
+
var dom = scope.dom();
|
368
|
+
var children = map(dom.childNodes, Element$$1.fromDom);
|
369
|
+
each(children, function (x) {
|
370
|
+
if (predicate(x)) {
|
371
|
+
result = result.concat([x]);
|
1149
372
|
}
|
1150
|
-
|
1151
|
-
|
1152
|
-
|
1153
|
-
|
1154
|
-
|
1155
|
-
|
1156
|
-
|
1157
|
-
|
1158
|
-
);
|
1159
|
-
/**
|
1160
|
-
* Commands.js
|
1161
|
-
*
|
1162
|
-
* Released under LGPL License.
|
1163
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
1164
|
-
*
|
1165
|
-
* License: http://www.tinymce.com/license
|
1166
|
-
* Contributing: http://www.tinymce.com/contributing
|
1167
|
-
*/
|
1168
|
-
|
1169
|
-
define(
|
1170
|
-
'tinymce.plugins.visualchars.api.Commands',
|
1171
|
-
[
|
1172
|
-
'tinymce.plugins.visualchars.core.Actions'
|
1173
|
-
],
|
1174
|
-
function (Actions) {
|
1175
|
-
var register = function (editor, toggleState) {
|
1176
|
-
editor.addCommand('mceVisualChars', function () {
|
1177
|
-
Actions.toggleVisualChars(editor, toggleState);
|
1178
|
-
});
|
1179
|
-
};
|
1180
|
-
|
1181
|
-
return {
|
1182
|
-
register: register
|
1183
|
-
};
|
1184
|
-
}
|
1185
|
-
);
|
1186
|
-
/**
|
1187
|
-
* ResolveGlobal.js
|
1188
|
-
*
|
1189
|
-
* Released under LGPL License.
|
1190
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
1191
|
-
*
|
1192
|
-
* License: http://www.tinymce.com/license
|
1193
|
-
* Contributing: http://www.tinymce.com/contributing
|
1194
|
-
*/
|
1195
|
-
|
1196
|
-
define(
|
1197
|
-
'tinymce.core.util.Delay',
|
1198
|
-
[
|
1199
|
-
'global!tinymce.util.Tools.resolve'
|
1200
|
-
],
|
1201
|
-
function (resolve) {
|
1202
|
-
return resolve('tinymce.util.Delay');
|
1203
|
-
}
|
1204
|
-
);
|
1205
|
-
|
1206
|
-
/**
|
1207
|
-
* Keyboard.js
|
1208
|
-
*
|
1209
|
-
* Released under LGPL License.
|
1210
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
1211
|
-
*
|
1212
|
-
* License: http://www.tinymce.com/license
|
1213
|
-
* Contributing: http://www.tinymce.com/contributing
|
1214
|
-
*/
|
1215
|
-
|
1216
|
-
define(
|
1217
|
-
'tinymce.plugins.visualchars.core.Keyboard',
|
1218
|
-
[
|
1219
|
-
'tinymce.core.util.Delay',
|
1220
|
-
'tinymce.plugins.visualchars.core.VisualChars'
|
1221
|
-
],
|
1222
|
-
function (Delay, VisualChars) {
|
1223
|
-
var setup = function (editor, toggleState) {
|
1224
|
-
var debouncedToggle = Delay.debounce(function () {
|
1225
|
-
VisualChars.toggle(editor);
|
1226
|
-
}, 300);
|
1227
|
-
|
1228
|
-
if (editor.settings.forced_root_block !== false) {
|
1229
|
-
editor.on('keydown', function (e) {
|
1230
|
-
if (toggleState.get() === true) {
|
1231
|
-
e.keyCode === 13 ? VisualChars.toggle(editor) : debouncedToggle();
|
1232
|
-
}
|
1233
|
-
});
|
373
|
+
result = result.concat(filterDescendants(x, predicate));
|
374
|
+
});
|
375
|
+
return result;
|
376
|
+
};
|
377
|
+
var findParentElm = function (elm, rootElm) {
|
378
|
+
while (elm.parentNode) {
|
379
|
+
if (elm.parentNode === rootElm) {
|
380
|
+
return elm;
|
1234
381
|
}
|
1235
|
-
|
1236
|
-
|
1237
|
-
|
1238
|
-
|
1239
|
-
|
1240
|
-
}
|
1241
|
-
|
1242
|
-
|
1243
|
-
|
1244
|
-
|
1245
|
-
|
1246
|
-
|
1247
|
-
*
|
1248
|
-
* License: http://www.tinymce.com/license
|
1249
|
-
* Contributing: http://www.tinymce.com/contributing
|
1250
|
-
*/
|
382
|
+
elm = elm.parentNode;
|
383
|
+
}
|
384
|
+
};
|
385
|
+
var replaceWithSpans = function (html) {
|
386
|
+
return html.replace($_aa0v31sxjm0og28p.regExpGlobal, $_724dsdt7jm0og2a0.wrapCharWithSpan);
|
387
|
+
};
|
388
|
+
var $_4qefmtsyjm0og28r = {
|
389
|
+
isMatch: isMatch,
|
390
|
+
filterDescendants: filterDescendants,
|
391
|
+
findParentElm: findParentElm,
|
392
|
+
replaceWithSpans: replaceWithSpans
|
393
|
+
};
|
1251
394
|
|
1252
|
-
|
1253
|
-
|
1254
|
-
|
1255
|
-
|
1256
|
-
|
1257
|
-
|
1258
|
-
|
1259
|
-
|
395
|
+
var show = function (editor, rootElm) {
|
396
|
+
var node, div;
|
397
|
+
var nodeList = $_4qefmtsyjm0og28r.filterDescendants(Element$$1.fromDom(rootElm), $_4qefmtsyjm0og28r.isMatch);
|
398
|
+
each(nodeList, function (n) {
|
399
|
+
var withSpans = $_4qefmtsyjm0og28r.replaceWithSpans($_6qboq0t5jm0og29x.value(n));
|
400
|
+
div = editor.dom.create('div', null, withSpans);
|
401
|
+
while (node = div.lastChild) {
|
402
|
+
editor.dom.insertAfter(node, n.dom());
|
403
|
+
}
|
404
|
+
editor.dom.remove(n.dom());
|
405
|
+
});
|
406
|
+
};
|
407
|
+
var hide = function (editor, body) {
|
408
|
+
var nodeList = editor.dom.select($_aa0v31sxjm0og28p.selector, body);
|
409
|
+
each(nodeList, function (node) {
|
410
|
+
editor.dom.remove(node, 1);
|
411
|
+
});
|
412
|
+
};
|
413
|
+
var toggle = function (editor) {
|
414
|
+
var body = editor.getBody();
|
415
|
+
var bookmark = editor.selection.getBookmark();
|
416
|
+
var parentNode = $_4qefmtsyjm0og28r.findParentElm(editor.selection.getNode(), body);
|
417
|
+
parentNode = parentNode !== undefined ? parentNode : body;
|
418
|
+
hide(editor, parentNode);
|
419
|
+
show(editor, parentNode);
|
420
|
+
editor.selection.moveToBookmark(bookmark);
|
421
|
+
};
|
422
|
+
var $_d6h2shswjm0og28i = {
|
423
|
+
show: show,
|
424
|
+
hide: hide,
|
425
|
+
toggle: toggle
|
426
|
+
};
|
1260
427
|
|
1261
|
-
|
1262
|
-
|
1263
|
-
|
1264
|
-
|
1265
|
-
|
428
|
+
var toggleVisualChars = function (editor, toggleState) {
|
429
|
+
var body = editor.getBody();
|
430
|
+
var selection = editor.selection;
|
431
|
+
var bookmark;
|
432
|
+
toggleState.set(!toggleState.get());
|
433
|
+
$_bdr3mcsvjm0og28h.fireVisualChars(editor, toggleState.get());
|
434
|
+
bookmark = selection.getBookmark();
|
435
|
+
if (toggleState.get() === true) {
|
436
|
+
$_d6h2shswjm0og28i.show(editor, body);
|
437
|
+
} else {
|
438
|
+
$_d6h2shswjm0og28i.hide(editor, body);
|
439
|
+
}
|
440
|
+
selection.moveToBookmark(bookmark);
|
441
|
+
};
|
442
|
+
var $_9adayusujm0og28g = { toggleVisualChars: toggleVisualChars };
|
1266
443
|
|
1267
|
-
|
1268
|
-
|
1269
|
-
|
1270
|
-
|
1271
|
-
|
1272
|
-
|
444
|
+
var register = function (editor, toggleState) {
|
445
|
+
editor.addCommand('mceVisualChars', function () {
|
446
|
+
$_9adayusujm0og28g.toggleVisualChars(editor, toggleState);
|
447
|
+
});
|
448
|
+
};
|
449
|
+
var $_77bhnbstjm0og28f = { register: register };
|
450
|
+
|
451
|
+
var global$1 = tinymce.util.Tools.resolve('tinymce.util.Delay');
|
452
|
+
|
453
|
+
var setup = function (editor, toggleState) {
|
454
|
+
var debouncedToggle = global$1.debounce(function () {
|
455
|
+
$_d6h2shswjm0og28i.toggle(editor);
|
456
|
+
}, 300);
|
457
|
+
if (editor.settings.forced_root_block !== false) {
|
458
|
+
editor.on('keydown', function (e) {
|
459
|
+
if (toggleState.get() === true) {
|
460
|
+
e.keyCode === 13 ? $_d6h2shswjm0og28i.toggle(editor) : debouncedToggle();
|
461
|
+
}
|
1273
462
|
});
|
463
|
+
}
|
464
|
+
};
|
465
|
+
var $_n2t3xt8jm0og2a9 = { setup: setup };
|
1274
466
|
|
1275
|
-
|
1276
|
-
|
1277
|
-
|
1278
|
-
|
1279
|
-
|
1280
|
-
context: 'view',
|
1281
|
-
prependToContext: true
|
467
|
+
var toggleActiveState = function (editor) {
|
468
|
+
return function (e) {
|
469
|
+
var ctrl = e.control;
|
470
|
+
editor.on('VisualChars', function (e) {
|
471
|
+
ctrl.active(e.state);
|
1282
472
|
});
|
1283
473
|
};
|
474
|
+
};
|
475
|
+
var register$1 = function (editor) {
|
476
|
+
editor.addButton('visualchars', {
|
477
|
+
active: false,
|
478
|
+
title: 'Show invisible characters',
|
479
|
+
cmd: 'mceVisualChars',
|
480
|
+
onPostRender: toggleActiveState(editor)
|
481
|
+
});
|
482
|
+
editor.addMenuItem('visualchars', {
|
483
|
+
text: 'Show invisible characters',
|
484
|
+
cmd: 'mceVisualChars',
|
485
|
+
onPostRender: toggleActiveState(editor),
|
486
|
+
selectable: true,
|
487
|
+
context: 'view',
|
488
|
+
prependToContext: true
|
489
|
+
});
|
490
|
+
};
|
1284
491
|
|
1285
|
-
|
1286
|
-
|
1287
|
-
|
492
|
+
global.add('visualchars', function (editor) {
|
493
|
+
var toggleState = Cell(false);
|
494
|
+
$_77bhnbstjm0og28f.register(editor, toggleState);
|
495
|
+
register$1(editor);
|
496
|
+
$_n2t3xt8jm0og2a9.setup(editor, toggleState);
|
497
|
+
return $_91givrssjm0og28e.get(toggleState);
|
498
|
+
});
|
499
|
+
function Plugin () {
|
1288
500
|
}
|
1289
|
-
);
|
1290
|
-
/**
|
1291
|
-
* Plugin.js
|
1292
|
-
*
|
1293
|
-
* Released under LGPL License.
|
1294
|
-
* Copyright (c) 1999-2017 Ephox Corp. All rights reserved
|
1295
|
-
*
|
1296
|
-
* License: http://www.tinymce.com/license
|
1297
|
-
* Contributing: http://www.tinymce.com/contributing
|
1298
|
-
*/
|
1299
|
-
|
1300
|
-
define(
|
1301
|
-
'tinymce.plugins.visualchars.Plugin',
|
1302
|
-
[
|
1303
|
-
'ephox.katamari.api.Cell',
|
1304
|
-
'tinymce.core.PluginManager',
|
1305
|
-
'tinymce.plugins.visualchars.api.Api',
|
1306
|
-
'tinymce.plugins.visualchars.api.Commands',
|
1307
|
-
'tinymce.plugins.visualchars.core.Keyboard',
|
1308
|
-
'tinymce.plugins.visualchars.ui.Buttons'
|
1309
|
-
],
|
1310
|
-
function (Cell, PluginManager, Api, Commands, Keyboard, Buttons) {
|
1311
|
-
PluginManager.add('visualchars', function (editor) {
|
1312
|
-
var toggleState = Cell(false);
|
1313
501
|
|
1314
|
-
|
1315
|
-
Buttons.register(editor);
|
1316
|
-
Keyboard.setup(editor, toggleState);
|
502
|
+
return Plugin;
|
1317
503
|
|
1318
|
-
|
1319
|
-
});
|
1320
|
-
|
1321
|
-
return function () {};
|
1322
|
-
}
|
1323
|
-
);
|
1324
|
-
dem('tinymce.plugins.visualchars.Plugin')();
|
504
|
+
}());
|
1325
505
|
})();
|