bedrock_sass 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/assets/_vendor/ace/ace.js +255 -589
- data/assets/_vendor/ace/ext-beautify.js +1 -2
- data/assets/_vendor/ace/ext-elastic_tabstops_lite.js +2 -2
- data/assets/_vendor/ace/ext-emmet.js +4 -4
- data/assets/_vendor/ace/ext-error_marker.js +1 -2
- data/assets/_vendor/ace/ext-keybinding_menu.js +1 -2
- data/assets/_vendor/ace/ext-language_tools.js +5 -9
- data/assets/_vendor/ace/ext-linking.js +1 -2
- data/assets/_vendor/ace/ext-modelist.js +9 -5
- data/assets/_vendor/ace/ext-options.js +10 -7
- data/assets/_vendor/ace/ext-rtl.js +1 -2
- data/assets/_vendor/ace/ext-searchbox.js +8 -4
- data/assets/_vendor/ace/ext-settings_menu.js +10 -7
- data/assets/_vendor/ace/ext-spellcheck.js +1 -2
- data/assets/_vendor/ace/ext-split.js +1 -2
- data/assets/_vendor/ace/ext-static_highlight.js +11 -8
- data/assets/_vendor/ace/ext-statusbar.js +1 -2
- data/assets/_vendor/ace/ext-textarea.js +1 -5
- data/assets/_vendor/ace/ext-themelist.js +2 -4
- data/assets/_vendor/ace/ext-whitespace.js +1 -2
- data/assets/_vendor/ace/keybinding-emacs.js +6 -2
- data/assets/_vendor/ace/keybinding-vim.js +13 -25
- data/assets/_vendor/ace/mode-abap.js +2 -3
- data/assets/_vendor/ace/mode-abc.js +3 -2
- data/assets/_vendor/ace/mode-actionscript.js +2 -2
- data/assets/_vendor/ace/mode-ada.js +1 -2
- data/assets/_vendor/ace/mode-apache_conf.js +2 -2
- data/assets/_vendor/ace/mode-apex.js +457 -0
- data/assets/_vendor/ace/mode-applescript.js +1 -2
- data/assets/_vendor/ace/mode-asciidoc.js +2 -2
- data/assets/_vendor/ace/mode-asl.js +1 -2
- data/assets/_vendor/ace/mode-assembly_x86.js +2 -2
- data/assets/_vendor/ace/mode-autohotkey.js +1 -2
- data/assets/_vendor/ace/mode-batchfile.js +2 -2
- data/assets/_vendor/ace/mode-bro.js +2 -2
- data/assets/_vendor/ace/mode-c9search.js +1 -2
- data/assets/_vendor/ace/mode-c_cpp.js +2 -2
- data/assets/_vendor/ace/mode-cirru.js +1 -2
- data/assets/_vendor/ace/mode-clojure.js +2 -2
- data/assets/_vendor/ace/mode-cobol.js +1 -2
- data/assets/_vendor/ace/mode-coffee.js +1 -2
- data/assets/_vendor/ace/mode-coldfusion.js +3 -2
- data/assets/_vendor/ace/mode-csharp.js +3 -3
- data/assets/_vendor/ace/mode-csound_document.js +319 -80
- data/assets/_vendor/ace/mode-csound_orchestra.js +323 -86
- data/assets/_vendor/ace/mode-csound_score.js +1 -2
- data/assets/_vendor/ace/mode-csp.js +1 -2
- data/assets/_vendor/ace/mode-css.js +2 -2
- data/assets/_vendor/ace/mode-curly.js +3 -2
- data/assets/_vendor/ace/mode-d.js +2 -2
- data/assets/_vendor/ace/mode-dart.js +24 -14
- data/assets/_vendor/ace/mode-diff.js +4 -4
- data/assets/_vendor/ace/mode-django.js +3 -2
- data/assets/_vendor/ace/mode-dockerfile.js +3 -2
- data/assets/_vendor/ace/mode-dot.js +1 -2
- data/assets/_vendor/ace/mode-drools.js +3 -2
- data/assets/_vendor/ace/mode-edifact.js +2 -2
- data/assets/_vendor/ace/mode-eiffel.js +1 -2
- data/assets/_vendor/ace/mode-ejs.js +5 -2
- data/assets/_vendor/ace/mode-elixir.js +2 -2
- data/assets/_vendor/ace/mode-elm.js +1 -2
- data/assets/_vendor/ace/mode-erlang.js +2 -2
- data/assets/_vendor/ace/mode-forth.js +2 -2
- data/assets/_vendor/ace/mode-fortran.js +1 -2
- data/assets/_vendor/ace/mode-fsharp.js +1 -2
- data/assets/_vendor/ace/mode-fsl.js +258 -0
- data/assets/_vendor/ace/mode-ftl.js +3 -2
- data/assets/_vendor/ace/mode-gcode.js +1 -2
- data/assets/_vendor/ace/mode-gherkin.js +2 -4
- data/assets/_vendor/ace/mode-gitignore.js +1 -2
- data/assets/_vendor/ace/mode-glsl.js +2 -2
- data/assets/_vendor/ace/mode-gobstones.js +3 -2
- data/assets/_vendor/ace/mode-golang.js +1 -2
- data/assets/_vendor/ace/mode-graphqlschema.js +1 -2
- data/assets/_vendor/ace/mode-groovy.js +4 -2
- data/assets/_vendor/ace/mode-haml.js +5 -2
- data/assets/_vendor/ace/mode-handlebars.js +3 -2
- data/assets/_vendor/ace/mode-haskell.js +2 -2
- data/assets/_vendor/ace/mode-haskell_cabal.js +1 -2
- data/assets/_vendor/ace/mode-haxe.js +2 -2
- data/assets/_vendor/ace/mode-hjson.js +2 -2
- data/assets/_vendor/ace/mode-html.js +3 -2
- data/assets/_vendor/ace/mode-html_elixir.js +4 -2
- data/assets/_vendor/ace/mode-html_ruby.js +5 -2
- data/assets/_vendor/ace/mode-ini.js +1 -2
- data/assets/_vendor/ace/mode-io.js +2 -2
- data/assets/_vendor/ace/mode-jack.js +1 -2
- data/assets/_vendor/ace/mode-jade.js +14 -115
- data/assets/_vendor/ace/mode-java.js +64 -3
- data/assets/_vendor/ace/mode-javascript.js +2 -2
- data/assets/_vendor/ace/mode-json.js +1 -2
- data/assets/_vendor/ace/mode-jsoniq.js +8 -2317
- data/assets/_vendor/ace/mode-jsp.js +4 -2
- data/assets/_vendor/ace/mode-jssm.js +2 -2
- data/assets/_vendor/ace/mode-jsx.js +1 -2
- data/assets/_vendor/ace/mode-julia.js +2 -2
- data/assets/_vendor/ace/mode-kotlin.js +2 -2
- data/assets/_vendor/ace/mode-latex.js +1 -2
- data/assets/_vendor/ace/mode-less.js +4 -2
- data/assets/_vendor/ace/mode-liquid.js +2026 -477
- data/assets/_vendor/ace/mode-lisp.js +2 -2
- data/assets/_vendor/ace/mode-livescript.js +1 -2
- data/assets/_vendor/ace/mode-logiql.js +2 -2
- data/assets/_vendor/ace/mode-logtalk.js +352 -0
- data/assets/_vendor/ace/mode-lsl.js +1 -2
- data/assets/_vendor/ace/mode-lua.js +1 -2
- data/assets/_vendor/ace/mode-luapage.js +3 -2
- data/assets/_vendor/ace/mode-lucene.js +2 -3
- data/assets/_vendor/ace/mode-makefile.js +3 -2
- data/assets/_vendor/ace/mode-markdown.js +5 -2
- data/assets/_vendor/ace/mode-mask.js +3 -2
- data/assets/_vendor/ace/mode-matlab.js +1 -2
- data/assets/_vendor/ace/mode-maze.js +2 -2
- data/assets/_vendor/ace/mode-mel.js +2 -2
- data/assets/_vendor/ace/mode-mixal.js +1 -2
- data/assets/_vendor/ace/mode-mushcode.js +2 -2
- data/assets/_vendor/ace/mode-mysql.js +3 -4
- data/assets/_vendor/ace/mode-nix.js +2 -2
- data/assets/_vendor/ace/mode-nsis.js +2 -2
- data/assets/_vendor/ace/mode-objectivec.js +3 -2
- data/assets/_vendor/ace/mode-ocaml.js +1 -2
- data/assets/_vendor/ace/mode-pascal.js +2 -2
- data/assets/_vendor/ace/mode-perl.js +2 -2
- data/assets/_vendor/ace/mode-perl6.js +593 -0
- data/assets/_vendor/ace/mode-pgsql.js +304 -69
- data/assets/_vendor/ace/mode-php.js +844 -1029
- data/assets/_vendor/ace/mode-php_laravel_blade.js +844 -1029
- data/assets/_vendor/ace/mode-pig.js +2 -2
- data/assets/_vendor/ace/mode-plain_text.js +1 -2
- data/assets/_vendor/ace/mode-powershell.js +2 -2
- data/assets/_vendor/ace/mode-praat.js +2 -2
- data/assets/_vendor/ace/mode-prolog.js +2 -2
- data/assets/_vendor/ace/mode-properties.js +1 -2
- data/assets/_vendor/ace/mode-protobuf.js +2 -2
- data/assets/_vendor/ace/mode-puppet.js +1 -2
- data/assets/_vendor/ace/mode-python.js +297 -63
- data/assets/_vendor/ace/mode-r.js +3 -2
- data/assets/_vendor/ace/mode-razor.js +9 -3
- data/assets/_vendor/ace/mode-rdoc.js +2 -2
- data/assets/_vendor/ace/mode-red.js +2 -2
- data/assets/_vendor/ace/mode-redshift.js +1 -2
- data/assets/_vendor/ace/mode-rhtml.js +5 -2
- data/assets/_vendor/ace/mode-rst.js +1 -2
- data/assets/_vendor/ace/mode-ruby.js +3 -2
- data/assets/_vendor/ace/mode-rust.js +2 -2
- data/assets/_vendor/ace/mode-sass.js +205 -117
- data/assets/_vendor/ace/mode-scad.js +2 -2
- data/assets/_vendor/ace/mode-scala.js +3 -2
- data/assets/_vendor/ace/mode-scheme.js +2 -2
- data/assets/_vendor/ace/mode-scss.js +204 -115
- data/assets/_vendor/ace/mode-sh.js +3 -2
- data/assets/_vendor/ace/mode-sjs.js +2 -2
- data/assets/_vendor/ace/mode-slim.js +18 -117
- data/assets/_vendor/ace/mode-smarty.js +3 -2
- data/assets/_vendor/ace/mode-snippets.js +1 -2
- data/assets/_vendor/ace/mode-soy_template.js +4 -2
- data/assets/_vendor/ace/mode-space.js +1 -2
- data/assets/_vendor/ace/mode-sparql.js +2 -2
- data/assets/_vendor/ace/mode-sql.js +2 -3
- data/assets/_vendor/ace/mode-sqlserver.js +2 -2
- data/assets/_vendor/ace/mode-stylus.js +3 -2
- data/assets/_vendor/ace/mode-svg.js +2 -2
- data/assets/_vendor/ace/mode-swift.js +1 -2
- data/assets/_vendor/ace/mode-tcl.js +2 -2
- data/assets/_vendor/ace/mode-terraform.js +1 -2
- data/assets/_vendor/ace/mode-tex.js +2 -2
- data/assets/_vendor/ace/mode-text.js +1 -2
- data/assets/_vendor/ace/mode-textile.js +1 -2
- data/assets/_vendor/ace/mode-toml.js +1 -2
- data/assets/_vendor/ace/mode-tsx.js +2 -2
- data/assets/_vendor/ace/mode-turtle.js +2 -2
- data/assets/_vendor/ace/mode-twig.js +3 -2
- data/assets/_vendor/ace/mode-typescript.js +2 -2
- data/assets/_vendor/ace/mode-vala.js +2 -2
- data/assets/_vendor/ace/mode-vbscript.js +1 -2
- data/assets/_vendor/ace/mode-velocity.js +4 -2
- data/assets/_vendor/ace/mode-verilog.js +1 -2
- data/assets/_vendor/ace/mode-vhdl.js +1 -2
- data/assets/_vendor/ace/mode-visualforce.js +2641 -0
- data/assets/_vendor/ace/mode-wollok.js +3 -2
- data/assets/_vendor/ace/mode-xml.js +1 -2
- data/assets/_vendor/ace/mode-xquery.js +8 -2287
- data/assets/_vendor/ace/mode-yaml.js +1 -2
- data/assets/_vendor/ace/snippets/abap.js +2 -3
- data/assets/_vendor/ace/snippets/abc.js +1 -2
- data/assets/_vendor/ace/snippets/actionscript.js +1 -2
- data/assets/_vendor/ace/snippets/ada.js +2 -3
- data/assets/_vendor/ace/snippets/apache_conf.js +2 -3
- data/assets/_vendor/ace/snippets/apex.js +14 -0
- data/assets/_vendor/ace/snippets/applescript.js +2 -3
- data/assets/_vendor/ace/snippets/asciidoc.js +2 -3
- data/assets/_vendor/ace/snippets/asl.js +2 -3
- data/assets/_vendor/ace/snippets/assembly_x86.js +2 -3
- data/assets/_vendor/ace/snippets/autohotkey.js +2 -3
- data/assets/_vendor/ace/snippets/batchfile.js +2 -3
- data/assets/_vendor/ace/snippets/bro.js +1 -2
- data/assets/_vendor/ace/snippets/c9search.js +2 -3
- data/assets/_vendor/ace/snippets/c_cpp.js +1 -2
- data/assets/_vendor/ace/snippets/cirru.js +2 -3
- data/assets/_vendor/ace/snippets/clojure.js +1 -2
- data/assets/_vendor/ace/snippets/cobol.js +2 -3
- data/assets/_vendor/ace/snippets/coffee.js +1 -2
- data/assets/_vendor/ace/snippets/coldfusion.js +2 -3
- data/assets/_vendor/ace/snippets/csharp.js +2 -3
- data/assets/_vendor/ace/snippets/csound_document.js +1 -2
- data/assets/_vendor/ace/snippets/csound_orchestra.js +1 -2
- data/assets/_vendor/ace/snippets/csound_score.js +2 -3
- data/assets/_vendor/ace/snippets/csp.js +1 -2
- data/assets/_vendor/ace/snippets/css.js +1 -2
- data/assets/_vendor/ace/snippets/curly.js +2 -3
- data/assets/_vendor/ace/snippets/d.js +2 -3
- data/assets/_vendor/ace/snippets/dart.js +1 -2
- data/assets/_vendor/ace/snippets/diff.js +1 -2
- data/assets/_vendor/ace/snippets/django.js +1 -2
- data/assets/_vendor/ace/snippets/dockerfile.js +2 -3
- data/assets/_vendor/ace/snippets/dot.js +2 -3
- data/assets/_vendor/ace/snippets/drools.js +1 -2
- data/assets/_vendor/ace/snippets/edifact.js +1 -2
- data/assets/_vendor/ace/snippets/eiffel.js +2 -3
- data/assets/_vendor/ace/snippets/ejs.js +2 -3
- data/assets/_vendor/ace/snippets/elixir.js +1 -2
- data/assets/_vendor/ace/snippets/elm.js +2 -3
- data/assets/_vendor/ace/snippets/erlang.js +1 -2
- data/assets/_vendor/ace/snippets/forth.js +2 -3
- data/assets/_vendor/ace/snippets/fortran.js +2 -3
- data/assets/_vendor/ace/snippets/fsharp.js +2 -3
- data/assets/_vendor/ace/snippets/fsl.js +14 -0
- data/assets/_vendor/ace/snippets/ftl.js +2 -3
- data/assets/_vendor/ace/snippets/gcode.js +2 -3
- data/assets/_vendor/ace/snippets/gherkin.js +2 -3
- data/assets/_vendor/ace/snippets/gitignore.js +2 -3
- data/assets/_vendor/ace/snippets/glsl.js +2 -3
- data/assets/_vendor/ace/snippets/gobstones.js +1 -2
- data/assets/_vendor/ace/snippets/golang.js +2 -3
- data/assets/_vendor/ace/snippets/graphqlschema.js +1 -2
- data/assets/_vendor/ace/snippets/groovy.js +2 -3
- data/assets/_vendor/ace/snippets/haml.js +1 -2
- data/assets/_vendor/ace/snippets/handlebars.js +2 -3
- data/assets/_vendor/ace/snippets/haskell.js +1 -2
- data/assets/_vendor/ace/snippets/haskell_cabal.js +2 -3
- data/assets/_vendor/ace/snippets/haxe.js +2 -3
- data/assets/_vendor/ace/snippets/hjson.js +1 -2
- data/assets/_vendor/ace/snippets/html.js +1 -2
- data/assets/_vendor/ace/snippets/html_elixir.js +2 -3
- data/assets/_vendor/ace/snippets/html_ruby.js +2 -3
- data/assets/_vendor/ace/snippets/ini.js +2 -3
- data/assets/_vendor/ace/snippets/io.js +1 -2
- data/assets/_vendor/ace/snippets/jack.js +2 -3
- data/assets/_vendor/ace/snippets/jade.js +2 -3
- data/assets/_vendor/ace/snippets/java.js +1 -2
- data/assets/_vendor/ace/snippets/javascript.js +1 -2
- data/assets/_vendor/ace/snippets/json.js +2 -3
- data/assets/_vendor/ace/snippets/jsoniq.js +1 -2
- data/assets/_vendor/ace/snippets/jsp.js +1 -2
- data/assets/_vendor/ace/snippets/jssm.js +1 -2
- data/assets/_vendor/ace/snippets/jsx.js +2 -3
- data/assets/_vendor/ace/snippets/julia.js +2 -3
- data/assets/_vendor/ace/snippets/kotlin.js +1 -2
- data/assets/_vendor/ace/snippets/latex.js +2 -3
- data/assets/_vendor/ace/snippets/less.js +2 -3
- data/assets/_vendor/ace/snippets/liquid.js +883 -3
- data/assets/_vendor/ace/snippets/lisp.js +2 -3
- data/assets/_vendor/ace/snippets/livescript.js +2 -3
- data/assets/_vendor/ace/snippets/logiql.js +2 -3
- data/assets/_vendor/ace/snippets/logtalk.js +14 -0
- data/assets/_vendor/ace/snippets/lsl.js +1 -2
- data/assets/_vendor/ace/snippets/lua.js +1 -2
- data/assets/_vendor/ace/snippets/luapage.js +2 -3
- data/assets/_vendor/ace/snippets/lucene.js +2 -3
- data/assets/_vendor/ace/snippets/makefile.js +1 -2
- data/assets/_vendor/ace/snippets/markdown.js +1 -2
- data/assets/_vendor/ace/snippets/mask.js +2 -3
- data/assets/_vendor/ace/snippets/matlab.js +2 -3
- data/assets/_vendor/ace/snippets/maze.js +1 -2
- data/assets/_vendor/ace/snippets/mel.js +2 -3
- data/assets/_vendor/ace/snippets/mixal.js +2 -3
- data/assets/_vendor/ace/snippets/mushcode.js +2 -3
- data/assets/_vendor/ace/snippets/mysql.js +2 -3
- data/assets/_vendor/ace/snippets/nix.js +2 -3
- data/assets/_vendor/ace/snippets/nsis.js +1 -2
- data/assets/_vendor/ace/snippets/objectivec.js +2 -3
- data/assets/_vendor/ace/snippets/ocaml.js +2 -3
- data/assets/_vendor/ace/snippets/pascal.js +2 -3
- data/assets/_vendor/ace/snippets/perl.js +1 -2
- data/assets/_vendor/ace/snippets/perl6.js +14 -0
- data/assets/_vendor/ace/snippets/pgsql.js +2 -3
- data/assets/_vendor/ace/snippets/php.js +1 -2
- data/assets/_vendor/ace/snippets/php_laravel_blade.js +2 -3
- data/assets/_vendor/ace/snippets/pig.js +2 -3
- data/assets/_vendor/ace/snippets/plain_text.js +2 -3
- data/assets/_vendor/ace/snippets/powershell.js +2 -3
- data/assets/_vendor/ace/snippets/praat.js +2 -3
- data/assets/_vendor/ace/snippets/prolog.js +2 -3
- data/assets/_vendor/ace/snippets/properties.js +2 -3
- data/assets/_vendor/ace/snippets/protobuf.js +1 -2
- data/assets/_vendor/ace/snippets/puppet.js +2 -3
- data/assets/_vendor/ace/snippets/python.js +1 -2
- data/assets/_vendor/ace/snippets/r.js +1 -2
- data/assets/_vendor/ace/snippets/razor.js +1 -2
- data/assets/_vendor/ace/snippets/rdoc.js +2 -3
- data/assets/_vendor/ace/snippets/red.js +1 -2
- data/assets/_vendor/ace/snippets/redshift.js +2 -3
- data/assets/_vendor/ace/snippets/rhtml.js +2 -3
- data/assets/_vendor/ace/snippets/rst.js +1 -2
- data/assets/_vendor/ace/snippets/ruby.js +1 -2
- data/assets/_vendor/ace/snippets/rust.js +2 -3
- data/assets/_vendor/ace/snippets/sass.js +2 -3
- data/assets/_vendor/ace/snippets/scad.js +2 -3
- data/assets/_vendor/ace/snippets/scala.js +2 -3
- data/assets/_vendor/ace/snippets/scheme.js +2 -3
- data/assets/_vendor/ace/snippets/scss.js +2 -3
- data/assets/_vendor/ace/snippets/sh.js +1 -2
- data/assets/_vendor/ace/snippets/sjs.js +2 -3
- data/assets/_vendor/ace/snippets/slim.js +2 -3
- data/assets/_vendor/ace/snippets/smarty.js +2 -3
- data/assets/_vendor/ace/snippets/snippets.js +1 -2
- data/assets/_vendor/ace/snippets/soy_template.js +2 -3
- data/assets/_vendor/ace/snippets/space.js +2 -3
- data/assets/_vendor/ace/snippets/sparql.js +1 -2
- data/assets/_vendor/ace/snippets/sql.js +1 -2
- data/assets/_vendor/ace/snippets/sqlserver.js +1 -2
- data/assets/_vendor/ace/snippets/stylus.js +2 -3
- data/assets/_vendor/ace/snippets/svg.js +2 -3
- data/assets/_vendor/ace/snippets/swift.js +2 -3
- data/assets/_vendor/ace/snippets/tcl.js +1 -2
- data/assets/_vendor/ace/snippets/terraform.js +2 -3
- data/assets/_vendor/ace/snippets/tex.js +1 -2
- data/assets/_vendor/ace/snippets/text.js +2 -3
- data/assets/_vendor/ace/snippets/textile.js +1 -2
- data/assets/_vendor/ace/snippets/toml.js +2 -3
- data/assets/_vendor/ace/snippets/tsx.js +2 -3
- data/assets/_vendor/ace/snippets/turtle.js +1 -2
- data/assets/_vendor/ace/snippets/twig.js +2 -3
- data/assets/_vendor/ace/snippets/typescript.js +2 -3
- data/assets/_vendor/ace/snippets/vala.js +1 -2
- data/assets/_vendor/ace/snippets/vbscript.js +2 -3
- data/assets/_vendor/ace/snippets/velocity.js +1 -2
- data/assets/_vendor/ace/snippets/verilog.js +2 -3
- data/assets/_vendor/ace/snippets/vhdl.js +2 -3
- data/assets/_vendor/ace/snippets/visualforce.js +14 -0
- data/assets/_vendor/ace/snippets/wollok.js +1 -2
- data/assets/_vendor/ace/snippets/xml.js +2 -3
- data/assets/_vendor/ace/snippets/xquery.js +1 -2
- data/assets/_vendor/ace/snippets/yaml.js +2 -3
- data/assets/_vendor/ace/theme-ambiance.js +1 -2
- data/assets/_vendor/ace/theme-chaos.js +1 -2
- data/assets/_vendor/ace/theme-chrome.js +1 -2
- data/assets/_vendor/ace/theme-clouds.js +1 -2
- data/assets/_vendor/ace/theme-clouds_midnight.js +1 -2
- data/assets/_vendor/ace/theme-cobalt.js +1 -2
- data/assets/_vendor/ace/theme-crimson_editor.js +1 -2
- data/assets/_vendor/ace/theme-dawn.js +1 -2
- data/assets/_vendor/ace/theme-dracula.js +1 -2
- data/assets/_vendor/ace/theme-dreamweaver.js +1 -2
- data/assets/_vendor/ace/theme-eclipse.js +1 -2
- data/assets/_vendor/ace/theme-github.js +3 -3
- data/assets/_vendor/ace/theme-gob.js +1 -2
- data/assets/_vendor/ace/theme-gruvbox.js +1 -2
- data/assets/_vendor/ace/theme-idle_fingers.js +1 -2
- data/assets/_vendor/ace/theme-iplastic.js +1 -2
- data/assets/_vendor/ace/theme-katzenmilch.js +1 -2
- data/assets/_vendor/ace/theme-kr_theme.js +1 -2
- data/assets/_vendor/ace/theme-kuroir.js +1 -2
- data/assets/_vendor/ace/theme-merbivore.js +1 -2
- data/assets/_vendor/ace/theme-merbivore_soft.js +1 -2
- data/assets/_vendor/ace/theme-mono_industrial.js +1 -2
- data/assets/_vendor/ace/theme-monokai.js +1 -2
- data/assets/_vendor/ace/theme-pastel_on_dark.js +1 -2
- data/assets/_vendor/ace/theme-solarized_dark.js +1 -2
- data/assets/_vendor/ace/theme-solarized_light.js +1 -2
- data/assets/_vendor/ace/theme-sqlserver.js +1 -2
- data/assets/_vendor/ace/theme-terminal.js +1 -2
- data/assets/_vendor/ace/theme-textmate.js +1 -2
- data/assets/_vendor/ace/theme-tomorrow.js +1 -2
- data/assets/_vendor/ace/theme-tomorrow_night.js +1 -2
- data/assets/_vendor/ace/theme-tomorrow_night_blue.js +1 -2
- data/assets/_vendor/ace/theme-tomorrow_night_bright.js +1 -2
- data/assets/_vendor/ace/theme-tomorrow_night_eighties.js +1 -2
- data/assets/_vendor/ace/theme-twilight.js +1 -2
- data/assets/_vendor/ace/theme-vibrant_ink.js +1 -2
- data/assets/_vendor/ace/theme-xcode.js +1 -2
- data/assets/_vendor/ace/worker-coffee.js +11 -20
- data/assets/_vendor/ace/worker-css.js +23 -20
- data/assets/_vendor/ace/worker-html.js +25 -31
- data/assets/_vendor/ace/worker-javascript.js +76 -36
- data/assets/_vendor/ace/worker-json.js +25 -20
- data/assets/_vendor/ace/worker-lua.js +68 -69
- data/assets/_vendor/ace/worker-php.js +12 -20
- data/assets/_vendor/ace/worker-xml.js +12 -22
- data/assets/_vendor/ace/worker-xquery.js +44 -12378
- data/assets/_vendor/tinymce/plugins/advlist/plugin.js +137 -137
- data/assets/_vendor/tinymce/plugins/anchor/plugin.js +102 -102
- data/assets/_vendor/tinymce/plugins/autolink/plugin.js +154 -154
- data/assets/_vendor/tinymce/plugins/autoresize/plugin.js +145 -145
- data/assets/_vendor/tinymce/plugins/autosave/plugin.js +207 -217
- data/assets/_vendor/tinymce/plugins/autosave/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/bbcode/plugin.js +89 -89
- data/assets/_vendor/tinymce/plugins/charmap/plugin.js +1246 -1246
- data/assets/_vendor/tinymce/plugins/code/plugin.js +80 -80
- data/assets/_vendor/tinymce/plugins/codesample/plugin.js +852 -852
- data/assets/_vendor/tinymce/plugins/colorpicker/plugin.js +109 -109
- data/assets/_vendor/tinymce/plugins/contextmenu/plugin.js +144 -144
- data/assets/_vendor/tinymce/plugins/directionality/plugin.js +53 -53
- data/assets/_vendor/tinymce/plugins/emoticons/plugin.js +74 -74
- data/assets/_vendor/tinymce/plugins/fullpage/plugin.js +464 -464
- data/assets/_vendor/tinymce/plugins/fullscreen/plugin.js +152 -152
- data/assets/_vendor/tinymce/plugins/help/plugin.js +639 -678
- data/assets/_vendor/tinymce/plugins/help/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/hr/plugin.js +29 -29
- data/assets/_vendor/tinymce/plugins/image/plugin.js +1119 -1126
- data/assets/_vendor/tinymce/plugins/image/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/imagetools/plugin.js +3414 -3445
- data/assets/_vendor/tinymce/plugins/imagetools/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/importcss/plugin.js +230 -230
- data/assets/_vendor/tinymce/plugins/insertdatetime/plugin.js +152 -152
- data/assets/_vendor/tinymce/plugins/legacyoutput/plugin.js +193 -193
- data/assets/_vendor/tinymce/plugins/link/plugin.js +646 -646
- data/assets/_vendor/tinymce/plugins/lists/plugin.js +2103 -1037
- data/assets/_vendor/tinymce/plugins/lists/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/media/plugin.js +1050 -1050
- data/assets/_vendor/tinymce/plugins/nonbreaking/plugin.js +69 -69
- data/assets/_vendor/tinymce/plugins/noneditable/plugin.js +98 -98
- data/assets/_vendor/tinymce/plugins/pagebreak/plugin.js +91 -91
- data/assets/_vendor/tinymce/plugins/paste/plugin.js +1725 -1364
- data/assets/_vendor/tinymce/plugins/paste/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/preview/plugin.js +107 -107
- data/assets/_vendor/tinymce/plugins/print/plugin.js +28 -28
- data/assets/_vendor/tinymce/plugins/save/plugin.js +101 -101
- data/assets/_vendor/tinymce/plugins/searchreplace/plugin.js +535 -537
- data/assets/_vendor/tinymce/plugins/searchreplace/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/spellchecker/plugin.js +683 -681
- data/assets/_vendor/tinymce/plugins/spellchecker/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/tabfocus/plugin.js +95 -95
- data/assets/_vendor/tinymce/plugins/table/plugin.js +8927 -9805
- data/assets/_vendor/tinymce/plugins/table/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/template/plugin.js +305 -311
- data/assets/_vendor/tinymce/plugins/template/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/textcolor/plugin.js +317 -317
- data/assets/_vendor/tinymce/plugins/textpattern/plugin.js +575 -329
- data/assets/_vendor/tinymce/plugins/textpattern/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/toc/plugin.js +201 -201
- data/assets/_vendor/tinymce/plugins/visualblocks/plugin.js +113 -113
- data/assets/_vendor/tinymce/plugins/visualchars/plugin.js +419 -471
- data/assets/_vendor/tinymce/plugins/visualchars/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/plugins/wordcount/plugin.js +371 -308
- data/assets/_vendor/tinymce/plugins/wordcount/plugin.min.js +1 -1
- data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.eot +0 -0
- data/assets/_vendor/tinymce/skins/lightgray/fonts/tinymce.svg +1 -0
- 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/themes/inlite/theme.js +9272 -9686
- data/assets/_vendor/tinymce/themes/inlite/theme.min.js +1 -1
- data/assets/_vendor/tinymce/themes/mobile/theme.js +12130 -13042
- data/assets/_vendor/tinymce/themes/mobile/theme.min.js +1 -1
- data/assets/_vendor/tinymce/themes/modern/theme.js +9090 -9504
- data/assets/_vendor/tinymce/themes/modern/theme.min.js +1 -1
- data/assets/_vendor/tinymce/tinymce.js +24914 -25218
- data/assets/bedrock/js/bedrock.js +1 -1
- data/assets/bedrock/scss/components/no-content.scss +5 -0
- data/assets/bedrock/scss/components/select-box.scss +1 -1
- data/lib/bedrock_sass.rb +51 -16
- data/lib/bedrock_sass/engine.rb +3 -2
- data/lib/bedrock_sass/version.rb +1 -1
- metadata +17 -7
@@ -1,66 +1,66 @@
|
|
1
1
|
(function () {
|
2
2
|
var directionality = (function () {
|
3
|
-
|
3
|
+
'use strict';
|
4
4
|
|
5
|
-
|
5
|
+
var global = tinymce.util.Tools.resolve('tinymce.PluginManager');
|
6
6
|
|
7
|
-
|
7
|
+
var global$1 = tinymce.util.Tools.resolve('tinymce.util.Tools');
|
8
8
|
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
9
|
+
var setDir = function (editor, dir) {
|
10
|
+
var dom = editor.dom;
|
11
|
+
var curDir;
|
12
|
+
var blocks = editor.selection.getSelectedBlocks();
|
13
|
+
if (blocks.length) {
|
14
|
+
curDir = dom.getAttrib(blocks[0], 'dir');
|
15
|
+
global$1.each(blocks, function (block) {
|
16
|
+
if (!dom.getParent(block.parentNode, '*[dir="' + dir + '"]', dom.getRoot())) {
|
17
|
+
dom.setAttrib(block, 'dir', curDir !== dir ? dir : null);
|
18
|
+
}
|
19
|
+
});
|
20
|
+
editor.nodeChanged();
|
21
|
+
}
|
22
|
+
};
|
23
|
+
var Direction = { setDir: setDir };
|
24
|
+
|
25
|
+
var register = function (editor) {
|
26
|
+
editor.addCommand('mceDirectionLTR', function () {
|
27
|
+
Direction.setDir(editor, 'ltr');
|
19
28
|
});
|
20
|
-
editor.
|
21
|
-
|
22
|
-
|
23
|
-
|
29
|
+
editor.addCommand('mceDirectionRTL', function () {
|
30
|
+
Direction.setDir(editor, 'rtl');
|
31
|
+
});
|
32
|
+
};
|
33
|
+
var Commands = { register: register };
|
24
34
|
|
25
|
-
|
26
|
-
|
27
|
-
$
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
}
|
32
|
-
|
33
|
-
|
35
|
+
var generateSelector = function (dir) {
|
36
|
+
var selector = [];
|
37
|
+
global$1.each('h1 h2 h3 h4 h5 h6 div p'.split(' '), function (name) {
|
38
|
+
selector.push(name + '[dir=' + dir + ']');
|
39
|
+
});
|
40
|
+
return selector.join(',');
|
41
|
+
};
|
42
|
+
var register$1 = function (editor) {
|
43
|
+
editor.addButton('ltr', {
|
44
|
+
title: 'Left to right',
|
45
|
+
cmd: 'mceDirectionLTR',
|
46
|
+
stateSelector: generateSelector('ltr')
|
47
|
+
});
|
48
|
+
editor.addButton('rtl', {
|
49
|
+
title: 'Right to left',
|
50
|
+
cmd: 'mceDirectionRTL',
|
51
|
+
stateSelector: generateSelector('rtl')
|
52
|
+
});
|
53
|
+
};
|
54
|
+
var Buttons = { register: register$1 };
|
34
55
|
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
selector.push(name + '[dir=' + dir + ']');
|
39
|
-
});
|
40
|
-
return selector.join(',');
|
41
|
-
};
|
42
|
-
var register$1 = function (editor) {
|
43
|
-
editor.addButton('ltr', {
|
44
|
-
title: 'Left to right',
|
45
|
-
cmd: 'mceDirectionLTR',
|
46
|
-
stateSelector: generateSelector('ltr')
|
56
|
+
global.add('directionality', function (editor) {
|
57
|
+
Commands.register(editor);
|
58
|
+
Buttons.register(editor);
|
47
59
|
});
|
48
|
-
|
49
|
-
|
50
|
-
cmd: 'mceDirectionRTL',
|
51
|
-
stateSelector: generateSelector('rtl')
|
52
|
-
});
|
53
|
-
};
|
54
|
-
var $_dnu9wqb5jm0ofycc = { register: register$1 };
|
55
|
-
|
56
|
-
global.add('directionality', function (editor) {
|
57
|
-
$_a21zaib2jm0ofyc9.register(editor);
|
58
|
-
$_dnu9wqb5jm0ofycc.register(editor);
|
59
|
-
});
|
60
|
-
function Plugin () {
|
61
|
-
}
|
60
|
+
function Plugin () {
|
61
|
+
}
|
62
62
|
|
63
|
-
|
63
|
+
return Plugin;
|
64
64
|
|
65
65
|
}());
|
66
66
|
})();
|
@@ -1,87 +1,87 @@
|
|
1
1
|
(function () {
|
2
2
|
var emoticons = (function () {
|
3
|
-
|
3
|
+
'use strict';
|
4
4
|
|
5
|
-
|
5
|
+
var global = tinymce.util.Tools.resolve('tinymce.PluginManager');
|
6
6
|
|
7
|
-
|
7
|
+
var global$1 = tinymce.util.Tools.resolve('tinymce.util.Tools');
|
8
8
|
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
9
|
+
var emoticons = [
|
10
|
+
[
|
11
|
+
'cool',
|
12
|
+
'cry',
|
13
|
+
'embarassed',
|
14
|
+
'foot-in-mouth'
|
15
|
+
],
|
16
|
+
[
|
17
|
+
'frown',
|
18
|
+
'innocent',
|
19
|
+
'kiss',
|
20
|
+
'laughing'
|
21
|
+
],
|
22
|
+
[
|
23
|
+
'money-mouth',
|
24
|
+
'sealed',
|
25
|
+
'smile',
|
26
|
+
'surprised'
|
27
|
+
],
|
28
|
+
[
|
29
|
+
'tongue-out',
|
30
|
+
'undecided',
|
31
|
+
'wink',
|
32
|
+
'yell'
|
33
|
+
]
|
34
|
+
];
|
35
|
+
var getHtml = function (pluginUrl) {
|
36
|
+
var emoticonsHtml;
|
37
|
+
emoticonsHtml = '<table role="list" class="mce-grid">';
|
38
|
+
global$1.each(emoticons, function (row) {
|
39
|
+
emoticonsHtml += '<tr>';
|
40
|
+
global$1.each(row, function (icon) {
|
41
|
+
var emoticonUrl = pluginUrl + '/img/smiley-' + icon + '.gif';
|
42
|
+
emoticonsHtml += '<td><a href="#" data-mce-url="' + emoticonUrl + '" data-mce-alt="' + icon + '" tabindex="-1" ' + 'role="option" aria-label="' + icon + '"><img src="' + emoticonUrl + '" style="width: 18px; height: 18px" role="presentation" /></a></td>';
|
43
|
+
});
|
44
|
+
emoticonsHtml += '</tr>';
|
43
45
|
});
|
44
|
-
emoticonsHtml += '</
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
};
|
49
|
-
var $_68b84bb9jm0ofycn = { getHtml: getHtml };
|
46
|
+
emoticonsHtml += '</table>';
|
47
|
+
return emoticonsHtml;
|
48
|
+
};
|
49
|
+
var PanelHtml = { getHtml: getHtml };
|
50
50
|
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
51
|
+
var insertEmoticon = function (editor, src, alt) {
|
52
|
+
editor.insertContent(editor.dom.createHTML('img', {
|
53
|
+
src: src,
|
54
|
+
alt: alt
|
55
|
+
}));
|
56
|
+
};
|
57
|
+
var register = function (editor, pluginUrl) {
|
58
|
+
var panelHtml = PanelHtml.getHtml(pluginUrl);
|
59
|
+
editor.addButton('emoticons', {
|
60
|
+
type: 'panelbutton',
|
61
|
+
panel: {
|
62
|
+
role: 'application',
|
63
|
+
autohide: true,
|
64
|
+
html: panelHtml,
|
65
|
+
onclick: function (e) {
|
66
|
+
var linkElm = editor.dom.getParent(e.target, 'a');
|
67
|
+
if (linkElm) {
|
68
|
+
insertEmoticon(editor, linkElm.getAttribute('data-mce-url'), linkElm.getAttribute('data-mce-alt'));
|
69
|
+
this.hide();
|
70
|
+
}
|
70
71
|
}
|
71
|
-
}
|
72
|
-
|
73
|
-
|
74
|
-
}
|
75
|
-
|
76
|
-
var $_3oxa7pb8jm0ofycm = { register: register };
|
72
|
+
},
|
73
|
+
tooltip: 'Emoticons'
|
74
|
+
});
|
75
|
+
};
|
76
|
+
var Buttons = { register: register };
|
77
77
|
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
78
|
+
global.add('emoticons', function (editor, pluginUrl) {
|
79
|
+
Buttons.register(editor, pluginUrl);
|
80
|
+
});
|
81
|
+
function Plugin () {
|
82
|
+
}
|
83
83
|
|
84
|
-
|
84
|
+
return Plugin;
|
85
85
|
|
86
86
|
}());
|
87
87
|
})();
|
@@ -1,519 +1,519 @@
|
|
1
1
|
(function () {
|
2
2
|
var fullpage = (function () {
|
3
|
-
|
3
|
+
'use strict';
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
5
|
+
var Cell = function (initial) {
|
6
|
+
var value = initial;
|
7
|
+
var get = function () {
|
8
|
+
return value;
|
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
|
+
};
|
9
21
|
};
|
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
|
-
};
|
22
22
|
|
23
|
-
|
23
|
+
var global = tinymce.util.Tools.resolve('tinymce.PluginManager');
|
24
24
|
|
25
|
-
|
25
|
+
var global$1 = tinymce.util.Tools.resolve('tinymce.util.Tools');
|
26
26
|
|
27
|
-
|
27
|
+
var global$2 = tinymce.util.Tools.resolve('tinymce.html.DomParser');
|
28
28
|
|
29
|
-
|
29
|
+
var global$3 = tinymce.util.Tools.resolve('tinymce.html.Node');
|
30
30
|
|
31
|
-
|
31
|
+
var global$4 = tinymce.util.Tools.resolve('tinymce.html.Serializer');
|
32
32
|
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
33
|
+
var shouldHideInSourceView = function (editor) {
|
34
|
+
return editor.getParam('fullpage_hide_in_source_view');
|
35
|
+
};
|
36
|
+
var getDefaultXmlPi = function (editor) {
|
37
|
+
return editor.getParam('fullpage_default_xml_pi');
|
38
|
+
};
|
39
|
+
var getDefaultEncoding = function (editor) {
|
40
|
+
return editor.getParam('fullpage_default_encoding');
|
41
|
+
};
|
42
|
+
var getDefaultFontFamily = function (editor) {
|
43
|
+
return editor.getParam('fullpage_default_font_family');
|
44
|
+
};
|
45
|
+
var getDefaultFontSize = function (editor) {
|
46
|
+
return editor.getParam('fullpage_default_font_size');
|
47
|
+
};
|
48
|
+
var getDefaultTextColor = function (editor) {
|
49
|
+
return editor.getParam('fullpage_default_text_color');
|
50
|
+
};
|
51
|
+
var getDefaultTitle = function (editor) {
|
52
|
+
return editor.getParam('fullpage_default_title');
|
53
|
+
};
|
54
|
+
var getDefaultDocType = function (editor) {
|
55
|
+
return editor.getParam('fullpage_default_doctype', '<!DOCTYPE html>');
|
56
|
+
};
|
57
|
+
var Settings = {
|
58
|
+
shouldHideInSourceView: shouldHideInSourceView,
|
59
|
+
getDefaultXmlPi: getDefaultXmlPi,
|
60
|
+
getDefaultEncoding: getDefaultEncoding,
|
61
|
+
getDefaultFontFamily: getDefaultFontFamily,
|
62
|
+
getDefaultFontSize: getDefaultFontSize,
|
63
|
+
getDefaultTextColor: getDefaultTextColor,
|
64
|
+
getDefaultTitle: getDefaultTitle,
|
65
|
+
getDefaultDocType: getDefaultDocType
|
66
|
+
};
|
67
67
|
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
}
|
82
|
-
data.fontface = $_62m00kc6jm0ofygy.getDefaultFontFamily(editor);
|
83
|
-
data.fontsize = $_62m00kc6jm0ofygy.getDefaultFontSize(editor);
|
84
|
-
elm = headerFragment.firstChild;
|
85
|
-
if (elm.type === 7) {
|
86
|
-
data.xml_pi = true;
|
87
|
-
matches = /encoding="([^"]+)"/.exec(elm.value);
|
88
|
-
if (matches) {
|
89
|
-
data.docencoding = matches[1];
|
68
|
+
var parseHeader = function (head) {
|
69
|
+
return global$2({
|
70
|
+
validate: false,
|
71
|
+
root_name: '#document'
|
72
|
+
}).parse(head);
|
73
|
+
};
|
74
|
+
var htmlToData = function (editor, head) {
|
75
|
+
var headerFragment = parseHeader(head);
|
76
|
+
var data = {};
|
77
|
+
var elm, matches;
|
78
|
+
function getAttr(elm, name) {
|
79
|
+
var value = elm.attr(name);
|
80
|
+
return value || '';
|
90
81
|
}
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
if (elm && elm.firstChild) {
|
98
|
-
data.title = elm.firstChild.value;
|
99
|
-
}
|
100
|
-
global$1.each(headerFragment.getAll('meta'), function (meta) {
|
101
|
-
var name = meta.attr('name');
|
102
|
-
var httpEquiv = meta.attr('http-equiv');
|
103
|
-
var matches;
|
104
|
-
if (name) {
|
105
|
-
data[name.toLowerCase()] = meta.attr('content');
|
106
|
-
} else if (httpEquiv === 'Content-Type') {
|
107
|
-
matches = /charset\s*=\s*(.*)\s*/gi.exec(meta.attr('content'));
|
82
|
+
data.fontface = Settings.getDefaultFontFamily(editor);
|
83
|
+
data.fontsize = Settings.getDefaultFontSize(editor);
|
84
|
+
elm = headerFragment.firstChild;
|
85
|
+
if (elm.type === 7) {
|
86
|
+
data.xml_pi = true;
|
87
|
+
matches = /encoding="([^"]+)"/.exec(elm.value);
|
108
88
|
if (matches) {
|
109
89
|
data.docencoding = matches[1];
|
110
90
|
}
|
111
91
|
}
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
data.langcode = getAttr(elm, 'lang') || getAttr(elm, 'xml:lang');
|
116
|
-
}
|
117
|
-
data.stylesheets = [];
|
118
|
-
global$1.each(headerFragment.getAll('link'), function (link) {
|
119
|
-
if (link.attr('rel') === 'stylesheet') {
|
120
|
-
data.stylesheets.push(link.attr('href'));
|
92
|
+
elm = headerFragment.getAll('#doctype')[0];
|
93
|
+
if (elm) {
|
94
|
+
data.doctype = '<!DOCTYPE' + elm.value + '>';
|
121
95
|
}
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
data.langdir = getAttr(elm, 'dir');
|
126
|
-
data.style = getAttr(elm, 'style');
|
127
|
-
data.visited_color = getAttr(elm, 'vlink');
|
128
|
-
data.link_color = getAttr(elm, 'link');
|
129
|
-
data.active_color = getAttr(elm, 'alink');
|
130
|
-
}
|
131
|
-
return data;
|
132
|
-
};
|
133
|
-
var dataToHtml = function (editor, data, head) {
|
134
|
-
var headerFragment, headElement, html, elm, value;
|
135
|
-
var dom = editor.dom;
|
136
|
-
function setAttr(elm, name, value) {
|
137
|
-
elm.attr(name, value ? value : undefined);
|
138
|
-
}
|
139
|
-
function addHeadNode(node) {
|
140
|
-
if (headElement.firstChild) {
|
141
|
-
headElement.insert(node, headElement.firstChild);
|
142
|
-
} else {
|
143
|
-
headElement.append(node);
|
96
|
+
elm = headerFragment.getAll('title')[0];
|
97
|
+
if (elm && elm.firstChild) {
|
98
|
+
data.title = elm.firstChild.value;
|
144
99
|
}
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
100
|
+
global$1.each(headerFragment.getAll('meta'), function (meta) {
|
101
|
+
var name = meta.attr('name');
|
102
|
+
var httpEquiv = meta.attr('http-equiv');
|
103
|
+
var matches;
|
104
|
+
if (name) {
|
105
|
+
data[name.toLowerCase()] = meta.attr('content');
|
106
|
+
} else if (httpEquiv === 'Content-Type') {
|
107
|
+
matches = /charset\s*=\s*(.*)\s*/gi.exec(meta.attr('content'));
|
108
|
+
if (matches) {
|
109
|
+
data.docencoding = matches[1];
|
110
|
+
}
|
111
|
+
}
|
112
|
+
});
|
149
113
|
elm = headerFragment.getAll('html')[0];
|
150
|
-
|
151
|
-
|
152
|
-
elm.insert(headElement, elm.firstChild, true);
|
153
|
-
} else {
|
154
|
-
elm.append(headElement);
|
114
|
+
if (elm) {
|
115
|
+
data.langcode = getAttr(elm, 'lang') || getAttr(elm, 'xml:lang');
|
155
116
|
}
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
117
|
+
data.stylesheets = [];
|
118
|
+
global$1.each(headerFragment.getAll('link'), function (link) {
|
119
|
+
if (link.attr('rel') === 'stylesheet') {
|
120
|
+
data.stylesheets.push(link.attr('href'));
|
121
|
+
}
|
122
|
+
});
|
123
|
+
elm = headerFragment.getAll('body')[0];
|
124
|
+
if (elm) {
|
125
|
+
data.langdir = getAttr(elm, 'dir');
|
126
|
+
data.style = getAttr(elm, 'style');
|
127
|
+
data.visited_color = getAttr(elm, 'vlink');
|
128
|
+
data.link_color = getAttr(elm, 'link');
|
129
|
+
data.active_color = getAttr(elm, 'alink');
|
162
130
|
}
|
163
|
-
|
164
|
-
|
165
|
-
|
131
|
+
return data;
|
132
|
+
};
|
133
|
+
var dataToHtml = function (editor, data, head) {
|
134
|
+
var headerFragment, headElement, html, elm, value;
|
135
|
+
var dom = editor.dom;
|
136
|
+
function setAttr(elm, name, value) {
|
137
|
+
elm.attr(name, value ? value : undefined);
|
166
138
|
}
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
}
|
171
|
-
elm = headerFragment.getAll('#doctype')[0];
|
172
|
-
if (data.doctype) {
|
173
|
-
if (!elm) {
|
174
|
-
elm = new global$3('#doctype', 10);
|
175
|
-
if (data.xml_pi) {
|
176
|
-
headerFragment.insert(elm, headerFragment.firstChild);
|
139
|
+
function addHeadNode(node) {
|
140
|
+
if (headElement.firstChild) {
|
141
|
+
headElement.insert(node, headElement.firstChild);
|
177
142
|
} else {
|
178
|
-
|
143
|
+
headElement.append(node);
|
179
144
|
}
|
180
145
|
}
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
if (data.docencoding) {
|
192
|
-
if (!elm) {
|
193
|
-
elm = new global$3('meta', 1);
|
194
|
-
elm.attr('http-equiv', 'Content-Type');
|
195
|
-
elm.shortEnded = true;
|
196
|
-
addHeadNode(elm);
|
146
|
+
headerFragment = parseHeader(head);
|
147
|
+
headElement = headerFragment.getAll('head')[0];
|
148
|
+
if (!headElement) {
|
149
|
+
elm = headerFragment.getAll('html')[0];
|
150
|
+
headElement = new global$3('head', 1);
|
151
|
+
if (elm.firstChild) {
|
152
|
+
elm.insert(headElement, elm.firstChild, true);
|
153
|
+
} else {
|
154
|
+
elm.append(headElement);
|
155
|
+
}
|
197
156
|
}
|
198
|
-
elm
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
elm.
|
157
|
+
elm = headerFragment.firstChild;
|
158
|
+
if (data.xml_pi) {
|
159
|
+
value = 'version="1.0"';
|
160
|
+
if (data.docencoding) {
|
161
|
+
value += ' encoding="' + data.docencoding + '"';
|
162
|
+
}
|
163
|
+
if (elm.type !== 7) {
|
164
|
+
elm = new global$3('xml', 7);
|
165
|
+
headerFragment.insert(elm, headerFragment.firstChild, true);
|
166
|
+
}
|
167
|
+
elm.value = value;
|
168
|
+
} else if (elm && elm.type === 7) {
|
169
|
+
elm.remove();
|
209
170
|
}
|
210
|
-
elm.
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
var i, meta;
|
217
|
-
var value = data[name];
|
218
|
-
for (i = 0; i < nodes.length; i++) {
|
219
|
-
meta = nodes[i];
|
220
|
-
if (meta.attr('name') === name) {
|
221
|
-
if (value) {
|
222
|
-
meta.attr('content', value);
|
171
|
+
elm = headerFragment.getAll('#doctype')[0];
|
172
|
+
if (data.doctype) {
|
173
|
+
if (!elm) {
|
174
|
+
elm = new global$3('#doctype', 10);
|
175
|
+
if (data.xml_pi) {
|
176
|
+
headerFragment.insert(elm, headerFragment.firstChild);
|
223
177
|
} else {
|
224
|
-
|
178
|
+
addHeadNode(elm);
|
225
179
|
}
|
226
|
-
return;
|
227
180
|
}
|
181
|
+
elm.value = data.doctype.substring(9, data.doctype.length - 1);
|
182
|
+
} else if (elm) {
|
183
|
+
elm.remove();
|
228
184
|
}
|
229
|
-
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
185
|
+
elm = null;
|
186
|
+
global$1.each(headerFragment.getAll('meta'), function (meta) {
|
187
|
+
if (meta.attr('http-equiv') === 'Content-Type') {
|
188
|
+
elm = meta;
|
189
|
+
}
|
190
|
+
});
|
191
|
+
if (data.docencoding) {
|
192
|
+
if (!elm) {
|
193
|
+
elm = new global$3('meta', 1);
|
194
|
+
elm.attr('http-equiv', 'Content-Type');
|
195
|
+
elm.shortEnded = true;
|
196
|
+
addHeadNode(elm);
|
197
|
+
}
|
198
|
+
elm.attr('content', 'text/html; charset=' + data.docencoding);
|
199
|
+
} else if (elm) {
|
200
|
+
elm.remove();
|
235
201
|
}
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
|
202
|
+
elm = headerFragment.getAll('title')[0];
|
203
|
+
if (data.title) {
|
204
|
+
if (!elm) {
|
205
|
+
elm = new global$3('title', 1);
|
206
|
+
addHeadNode(elm);
|
207
|
+
} else {
|
208
|
+
elm.empty();
|
209
|
+
}
|
210
|
+
elm.append(new global$3('#text', 3)).value = data.title;
|
211
|
+
} else if (elm) {
|
212
|
+
elm.remove();
|
241
213
|
}
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
214
|
+
global$1.each('keywords,description,author,copyright,robots'.split(','), function (name) {
|
215
|
+
var nodes = headerFragment.getAll('meta');
|
216
|
+
var i, meta;
|
217
|
+
var value = data[name];
|
218
|
+
for (i = 0; i < nodes.length; i++) {
|
219
|
+
meta = nodes[i];
|
220
|
+
if (meta.attr('name') === name) {
|
221
|
+
if (value) {
|
222
|
+
meta.attr('content', value);
|
223
|
+
} else {
|
224
|
+
meta.remove();
|
225
|
+
}
|
226
|
+
return;
|
227
|
+
}
|
228
|
+
}
|
229
|
+
if (value) {
|
230
|
+
elm = new global$3('meta', 1);
|
231
|
+
elm.attr('name', name);
|
232
|
+
elm.attr('content', value);
|
233
|
+
elm.shortEnded = true;
|
234
|
+
addHeadNode(elm);
|
235
|
+
}
|
236
|
+
});
|
237
|
+
var currentStyleSheetsMap = {};
|
238
|
+
global$1.each(headerFragment.getAll('link'), function (stylesheet) {
|
239
|
+
if (stylesheet.attr('rel') === 'stylesheet') {
|
240
|
+
currentStyleSheetsMap[stylesheet.attr('href')] = stylesheet;
|
241
|
+
}
|
242
|
+
});
|
243
|
+
global$1.each(data.stylesheets, function (stylesheet) {
|
244
|
+
if (!currentStyleSheetsMap[stylesheet]) {
|
245
|
+
elm = new global$3('link', 1);
|
246
|
+
elm.attr({
|
247
|
+
rel: 'stylesheet',
|
248
|
+
text: 'text/css',
|
249
|
+
href: stylesheet
|
250
|
+
});
|
251
|
+
elm.shortEnded = true;
|
252
|
+
addHeadNode(elm);
|
253
|
+
}
|
254
|
+
delete currentStyleSheetsMap[stylesheet];
|
255
|
+
});
|
256
|
+
global$1.each(currentStyleSheetsMap, function (stylesheet) {
|
257
|
+
stylesheet.remove();
|
258
|
+
});
|
259
|
+
elm = headerFragment.getAll('body')[0];
|
260
|
+
if (elm) {
|
261
|
+
setAttr(elm, 'dir', data.langdir);
|
262
|
+
setAttr(elm, 'style', data.style);
|
263
|
+
setAttr(elm, 'vlink', data.visited_color);
|
264
|
+
setAttr(elm, 'link', data.link_color);
|
265
|
+
setAttr(elm, 'alink', data.active_color);
|
266
|
+
dom.setAttribs(editor.getBody(), {
|
267
|
+
style: data.style,
|
268
|
+
dir: data.dir,
|
269
|
+
vLink: data.visited_color,
|
270
|
+
link: data.link_color,
|
271
|
+
aLink: data.active_color
|
250
272
|
});
|
251
|
-
elm.shortEnded = true;
|
252
|
-
addHeadNode(elm);
|
253
273
|
}
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
setAttr(elm, 'lang', data.langcode);
|
277
|
-
setAttr(elm, 'xml:lang', data.langcode);
|
278
|
-
}
|
279
|
-
if (!headElement.firstChild) {
|
280
|
-
headElement.remove();
|
281
|
-
}
|
282
|
-
html = global$4({
|
283
|
-
validate: false,
|
284
|
-
indent: true,
|
285
|
-
apply_source_formatting: true,
|
286
|
-
indent_before: 'head,html,body,meta,title,script,link,style',
|
287
|
-
indent_after: 'head,html,body,meta,title,script,link,style'
|
288
|
-
}).serialize(headerFragment);
|
289
|
-
return html.substring(0, html.indexOf('</body>'));
|
290
|
-
};
|
291
|
-
var $_6vv02yc2jm0ofygr = {
|
292
|
-
parseHeader: parseHeader,
|
293
|
-
htmlToData: htmlToData,
|
294
|
-
dataToHtml: dataToHtml
|
295
|
-
};
|
274
|
+
elm = headerFragment.getAll('html')[0];
|
275
|
+
if (elm) {
|
276
|
+
setAttr(elm, 'lang', data.langcode);
|
277
|
+
setAttr(elm, 'xml:lang', data.langcode);
|
278
|
+
}
|
279
|
+
if (!headElement.firstChild) {
|
280
|
+
headElement.remove();
|
281
|
+
}
|
282
|
+
html = global$4({
|
283
|
+
validate: false,
|
284
|
+
indent: true,
|
285
|
+
apply_source_formatting: true,
|
286
|
+
indent_before: 'head,html,body,meta,title,script,link,style',
|
287
|
+
indent_after: 'head,html,body,meta,title,script,link,style'
|
288
|
+
}).serialize(headerFragment);
|
289
|
+
return html.substring(0, html.indexOf('</body>'));
|
290
|
+
};
|
291
|
+
var Parser = {
|
292
|
+
parseHeader: parseHeader,
|
293
|
+
htmlToData: htmlToData,
|
294
|
+
dataToHtml: dataToHtml
|
295
|
+
};
|
296
296
|
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
},
|
306
|
-
body: [
|
307
|
-
{
|
308
|
-
name: 'title',
|
309
|
-
label: 'Title'
|
310
|
-
},
|
311
|
-
{
|
312
|
-
name: 'keywords',
|
313
|
-
label: 'Keywords'
|
314
|
-
},
|
315
|
-
{
|
316
|
-
name: 'description',
|
317
|
-
label: 'Description'
|
318
|
-
},
|
319
|
-
{
|
320
|
-
name: 'robots',
|
321
|
-
label: 'Robots'
|
322
|
-
},
|
323
|
-
{
|
324
|
-
name: 'author',
|
325
|
-
label: 'Author'
|
297
|
+
var open = function (editor, headState) {
|
298
|
+
var data = Parser.htmlToData(editor, headState.get());
|
299
|
+
editor.windowManager.open({
|
300
|
+
title: 'Document properties',
|
301
|
+
data: data,
|
302
|
+
defaults: {
|
303
|
+
type: 'textbox',
|
304
|
+
size: 40
|
326
305
|
},
|
327
|
-
|
328
|
-
|
329
|
-
|
306
|
+
body: [
|
307
|
+
{
|
308
|
+
name: 'title',
|
309
|
+
label: 'Title'
|
310
|
+
},
|
311
|
+
{
|
312
|
+
name: 'keywords',
|
313
|
+
label: 'Keywords'
|
314
|
+
},
|
315
|
+
{
|
316
|
+
name: 'description',
|
317
|
+
label: 'Description'
|
318
|
+
},
|
319
|
+
{
|
320
|
+
name: 'robots',
|
321
|
+
label: 'Robots'
|
322
|
+
},
|
323
|
+
{
|
324
|
+
name: 'author',
|
325
|
+
label: 'Author'
|
326
|
+
},
|
327
|
+
{
|
328
|
+
name: 'docencoding',
|
329
|
+
label: 'Encoding'
|
330
|
+
}
|
331
|
+
],
|
332
|
+
onSubmit: function (e) {
|
333
|
+
var headHtml = Parser.dataToHtml(editor, global$1.extend(data, e.data), headState.get());
|
334
|
+
headState.set(headHtml);
|
330
335
|
}
|
331
|
-
|
332
|
-
|
333
|
-
|
334
|
-
headState.set(headHtml);
|
335
|
-
}
|
336
|
-
});
|
337
|
-
};
|
338
|
-
var $_9bctdhc0jm0ofygo = { open: open };
|
336
|
+
});
|
337
|
+
};
|
338
|
+
var Dialog = { open: open };
|
339
339
|
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
340
|
+
var register = function (editor, headState) {
|
341
|
+
editor.addCommand('mceFullPageProperties', function () {
|
342
|
+
Dialog.open(editor, headState);
|
343
|
+
});
|
344
|
+
};
|
345
|
+
var Commands = { register: register };
|
346
346
|
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
347
|
+
var protectHtml = function (protect, html) {
|
348
|
+
global$1.each(protect, function (pattern) {
|
349
|
+
html = html.replace(pattern, function (str) {
|
350
|
+
return '<!--mce:protected ' + escape(str) + '-->';
|
351
|
+
});
|
351
352
|
});
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
}
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
};
|
353
|
+
return html;
|
354
|
+
};
|
355
|
+
var unprotectHtml = function (html) {
|
356
|
+
return html.replace(/<!--mce:protected ([\s\S]*?)-->/g, function (a, m) {
|
357
|
+
return unescape(m);
|
358
|
+
});
|
359
|
+
};
|
360
|
+
var Protect = {
|
361
|
+
protectHtml: protectHtml,
|
362
|
+
unprotectHtml: unprotectHtml
|
363
|
+
};
|
364
364
|
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
}
|
378
|
-
content = $_37ey1pc8jm0ofyh7.protectHtml(editor.settings.protect, evt.content);
|
379
|
-
if (evt.format === 'raw' && headState.get()) {
|
380
|
-
return;
|
381
|
-
}
|
382
|
-
if (evt.source_view && $_62m00kc6jm0ofygy.shouldHideInSourceView(editor)) {
|
383
|
-
return;
|
384
|
-
}
|
385
|
-
if (content.length === 0 && !evt.source_view) {
|
386
|
-
content = global$1.trim(headState.get()) + '\n' + global$1.trim(content) + '\n' + global$1.trim(footState.get());
|
387
|
-
}
|
388
|
-
content = content.replace(/<(\/?)BODY/gi, '<$1body');
|
389
|
-
startPos = content.indexOf('<body');
|
390
|
-
if (startPos !== -1) {
|
391
|
-
startPos = content.indexOf('>', startPos);
|
392
|
-
headState.set(low(content.substring(0, startPos + 1)));
|
393
|
-
endPos = content.indexOf('</body', startPos);
|
394
|
-
if (endPos === -1) {
|
395
|
-
endPos = content.length;
|
365
|
+
var each = global$1.each;
|
366
|
+
var low = function (s) {
|
367
|
+
return s.replace(/<\/?[A-Z]+/g, function (a) {
|
368
|
+
return a.toLowerCase();
|
369
|
+
});
|
370
|
+
};
|
371
|
+
var handleSetContent = function (editor, headState, footState, evt) {
|
372
|
+
var startPos, endPos, content, headerFragment, styles = '';
|
373
|
+
var dom = editor.dom;
|
374
|
+
var elm;
|
375
|
+
if (evt.selection) {
|
376
|
+
return;
|
396
377
|
}
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
headState.set(getDefaultHeader(editor));
|
401
|
-
footState.set('\n</body>\n</html>');
|
402
|
-
}
|
403
|
-
headerFragment = $_6vv02yc2jm0ofygr.parseHeader(headState.get());
|
404
|
-
each(headerFragment.getAll('style'), function (node) {
|
405
|
-
if (node.firstChild) {
|
406
|
-
styles += node.firstChild.value;
|
378
|
+
content = Protect.protectHtml(editor.settings.protect, evt.content);
|
379
|
+
if (evt.format === 'raw' && headState.get()) {
|
380
|
+
return;
|
407
381
|
}
|
408
|
-
|
409
|
-
|
410
|
-
if (elm) {
|
411
|
-
dom.setAttribs(editor.getBody(), {
|
412
|
-
style: elm.attr('style') || '',
|
413
|
-
dir: elm.attr('dir') || '',
|
414
|
-
vLink: elm.attr('vlink') || '',
|
415
|
-
link: elm.attr('link') || '',
|
416
|
-
aLink: elm.attr('alink') || ''
|
417
|
-
});
|
418
|
-
}
|
419
|
-
dom.remove('fullpage_styles');
|
420
|
-
var headElm = editor.getDoc().getElementsByTagName('head')[0];
|
421
|
-
if (styles) {
|
422
|
-
dom.add(headElm, 'style', { id: 'fullpage_styles' }, styles);
|
423
|
-
elm = dom.get('fullpage_styles');
|
424
|
-
if (elm.styleSheet) {
|
425
|
-
elm.styleSheet.cssText = styles;
|
382
|
+
if (evt.source_view && Settings.shouldHideInSourceView(editor)) {
|
383
|
+
return;
|
426
384
|
}
|
427
|
-
|
428
|
-
|
429
|
-
global$1.each(headElm.getElementsByTagName('link'), function (stylesheet) {
|
430
|
-
if (stylesheet.rel === 'stylesheet' && stylesheet.getAttribute('data-mce-fullpage')) {
|
431
|
-
currentStyleSheetsMap[stylesheet.href] = stylesheet;
|
385
|
+
if (content.length === 0 && !evt.source_view) {
|
386
|
+
content = global$1.trim(headState.get()) + '\n' + global$1.trim(content) + '\n' + global$1.trim(footState.get());
|
432
387
|
}
|
433
|
-
|
434
|
-
|
435
|
-
|
436
|
-
|
437
|
-
|
388
|
+
content = content.replace(/<(\/?)BODY/gi, '<$1body');
|
389
|
+
startPos = content.indexOf('<body');
|
390
|
+
if (startPos !== -1) {
|
391
|
+
startPos = content.indexOf('>', startPos);
|
392
|
+
headState.set(low(content.substring(0, startPos + 1)));
|
393
|
+
endPos = content.indexOf('</body', startPos);
|
394
|
+
if (endPos === -1) {
|
395
|
+
endPos = content.length;
|
396
|
+
}
|
397
|
+
evt.content = global$1.trim(content.substring(startPos + 1, endPos));
|
398
|
+
footState.set(low(content.substring(endPos)));
|
399
|
+
} else {
|
400
|
+
headState.set(getDefaultHeader(editor));
|
401
|
+
footState.set('\n</body>\n</html>');
|
438
402
|
}
|
439
|
-
|
440
|
-
|
441
|
-
|
442
|
-
|
443
|
-
|
444
|
-
|
403
|
+
headerFragment = Parser.parseHeader(headState.get());
|
404
|
+
each(headerFragment.getAll('style'), function (node) {
|
405
|
+
if (node.firstChild) {
|
406
|
+
styles += node.firstChild.value;
|
407
|
+
}
|
408
|
+
});
|
409
|
+
elm = headerFragment.getAll('body')[0];
|
410
|
+
if (elm) {
|
411
|
+
dom.setAttribs(editor.getBody(), {
|
412
|
+
style: elm.attr('style') || '',
|
413
|
+
dir: elm.attr('dir') || '',
|
414
|
+
vLink: elm.attr('vlink') || '',
|
415
|
+
link: elm.attr('link') || '',
|
416
|
+
aLink: elm.attr('alink') || ''
|
445
417
|
});
|
446
418
|
}
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
var
|
457
|
-
|
458
|
-
|
459
|
-
|
460
|
-
|
461
|
-
|
462
|
-
|
463
|
-
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
|
484
|
-
|
485
|
-
|
486
|
-
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
|
419
|
+
dom.remove('fullpage_styles');
|
420
|
+
var headElm = editor.getDoc().getElementsByTagName('head')[0];
|
421
|
+
if (styles) {
|
422
|
+
dom.add(headElm, 'style', { id: 'fullpage_styles' }, styles);
|
423
|
+
elm = dom.get('fullpage_styles');
|
424
|
+
if (elm.styleSheet) {
|
425
|
+
elm.styleSheet.cssText = styles;
|
426
|
+
}
|
427
|
+
}
|
428
|
+
var currentStyleSheetsMap = {};
|
429
|
+
global$1.each(headElm.getElementsByTagName('link'), function (stylesheet) {
|
430
|
+
if (stylesheet.rel === 'stylesheet' && stylesheet.getAttribute('data-mce-fullpage')) {
|
431
|
+
currentStyleSheetsMap[stylesheet.href] = stylesheet;
|
432
|
+
}
|
433
|
+
});
|
434
|
+
global$1.each(headerFragment.getAll('link'), function (stylesheet) {
|
435
|
+
var href = stylesheet.attr('href');
|
436
|
+
if (!href) {
|
437
|
+
return true;
|
438
|
+
}
|
439
|
+
if (!currentStyleSheetsMap[href] && stylesheet.attr('rel') === 'stylesheet') {
|
440
|
+
dom.add(headElm, 'link', {
|
441
|
+
'rel': 'stylesheet',
|
442
|
+
'text': 'text/css',
|
443
|
+
'href': href,
|
444
|
+
'data-mce-fullpage': '1'
|
445
|
+
});
|
446
|
+
}
|
447
|
+
delete currentStyleSheetsMap[href];
|
448
|
+
});
|
449
|
+
global$1.each(currentStyleSheetsMap, function (stylesheet) {
|
450
|
+
stylesheet.parentNode.removeChild(stylesheet);
|
451
|
+
});
|
452
|
+
};
|
453
|
+
var getDefaultHeader = function (editor) {
|
454
|
+
var header = '', value, styles = '';
|
455
|
+
if (Settings.getDefaultXmlPi(editor)) {
|
456
|
+
var piEncoding = Settings.getDefaultEncoding(editor);
|
457
|
+
header += '<?xml version="1.0" encoding="' + (piEncoding ? piEncoding : 'ISO-8859-1') + '" ?>\n';
|
458
|
+
}
|
459
|
+
header += Settings.getDefaultDocType(editor);
|
460
|
+
header += '\n<html>\n<head>\n';
|
461
|
+
if (value = Settings.getDefaultTitle(editor)) {
|
462
|
+
header += '<title>' + value + '</title>\n';
|
463
|
+
}
|
464
|
+
if (value = Settings.getDefaultEncoding(editor)) {
|
465
|
+
header += '<meta http-equiv="Content-Type" content="text/html; charset=' + value + '" />\n';
|
466
|
+
}
|
467
|
+
if (value = Settings.getDefaultFontFamily(editor)) {
|
468
|
+
styles += 'font-family: ' + value + ';';
|
469
|
+
}
|
470
|
+
if (value = Settings.getDefaultFontSize(editor)) {
|
471
|
+
styles += 'font-size: ' + value + ';';
|
472
|
+
}
|
473
|
+
if (value = Settings.getDefaultTextColor(editor)) {
|
474
|
+
styles += 'color: ' + value + ';';
|
475
|
+
}
|
476
|
+
header += '</head>\n<body' + (styles ? ' style="' + styles + '"' : '') + '>\n';
|
477
|
+
return header;
|
478
|
+
};
|
479
|
+
var handleGetContent = function (editor, head, foot, evt) {
|
480
|
+
if (!evt.selection && (!evt.source_view || !Settings.shouldHideInSourceView(editor))) {
|
481
|
+
evt.content = Protect.unprotectHtml(global$1.trim(head) + '\n' + global$1.trim(evt.content) + '\n' + global$1.trim(foot));
|
482
|
+
}
|
483
|
+
};
|
484
|
+
var setup = function (editor, headState, footState) {
|
485
|
+
editor.on('BeforeSetContent', function (evt) {
|
486
|
+
handleSetContent(editor, headState, footState, evt);
|
487
|
+
});
|
488
|
+
editor.on('GetContent', function (evt) {
|
489
|
+
handleGetContent(editor, headState.get(), footState.get(), evt);
|
490
|
+
});
|
491
|
+
};
|
492
|
+
var FilterContent = { setup: setup };
|
493
493
|
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
|
500
|
-
|
501
|
-
|
502
|
-
|
503
|
-
|
504
|
-
|
505
|
-
|
494
|
+
var register$1 = function (editor) {
|
495
|
+
editor.addButton('fullpage', {
|
496
|
+
title: 'Document properties',
|
497
|
+
cmd: 'mceFullPageProperties'
|
498
|
+
});
|
499
|
+
editor.addMenuItem('fullpage', {
|
500
|
+
text: 'Document properties',
|
501
|
+
cmd: 'mceFullPageProperties',
|
502
|
+
context: 'file'
|
503
|
+
});
|
504
|
+
};
|
505
|
+
var Buttons = { register: register$1 };
|
506
506
|
|
507
|
-
|
508
|
-
|
509
|
-
|
510
|
-
|
511
|
-
|
512
|
-
|
513
|
-
|
514
|
-
|
507
|
+
global.add('fullpage', function (editor) {
|
508
|
+
var headState = Cell(''), footState = Cell('');
|
509
|
+
Commands.register(editor, headState);
|
510
|
+
Buttons.register(editor);
|
511
|
+
FilterContent.setup(editor, headState, footState);
|
512
|
+
});
|
513
|
+
function Plugin () {
|
514
|
+
}
|
515
515
|
|
516
|
-
|
516
|
+
return Plugin;
|
517
517
|
|
518
518
|
}());
|
519
519
|
})();
|