You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ga...@apache.org on 2013/10/29 16:40:36 UTC
[51/51] [partial] git commit: updated refs/heads/1911-ace-editor to
9abd128
working replacement
Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/9abd128c
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/9abd128c
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/9abd128c
Branch: refs/heads/1911-ace-editor
Commit: 9abd128cb548a43535ff5e3f32f6c588e9ab2d06
Parents: b7c5531
Author: Garren Smith <ga...@gmail.com>
Authored: Tue Oct 29 17:27:51 2013 +0200
Committer: Garren Smith <ga...@gmail.com>
Committed: Tue Oct 29 17:27:51 2013 +0200
----------------------------------------------------------------------
src/fauxton/app/config.js | 3 +-
src/fauxton/app/modules/documents/views.js | 82 +-
src/fauxton/app/modules/fauxton/components.js | 68 +-
src/fauxton/app/templates/documents/doc.html | 2 +-
.../app/templates/documents/view_editor.html | 8 +-
src/fauxton/assets/js/libs/ace/ace.js | 117 +
src/fauxton/assets/js/libs/ace/anchor.js | 242 +
src/fauxton/assets/js/libs/ace/anchor_test.js | 188 +
src/fauxton/assets/js/libs/ace/autocomplete.js | 350 +
.../assets/js/libs/ace/autocomplete/popup.js | 316 +
.../js/libs/ace/autocomplete/text_completer.js | 78 +
.../assets/js/libs/ace/autocomplete/util.js | 74 +
.../assets/js/libs/ace/background_tokenizer.js | 255 +
.../js/libs/ace/background_tokenizer_test.js | 85 +
.../js/libs/ace/commands/command_manager.js | 112 +
.../libs/ace/commands/command_manager_test.js | 199 +
.../js/libs/ace/commands/default_commands.js | 490 +
.../ace/commands/incremental_search_commands.js | 180 +
.../libs/ace/commands/multi_select_commands.js | 97 +
.../js/libs/ace/commands/occur_commands.js | 110 +
src/fauxton/assets/js/libs/ace/config.js | 295 +
src/fauxton/assets/js/libs/ace/config_test.js | 128 +
.../ace/css/codefolding-fold-button-states.png | Bin 0 -> 759 bytes
src/fauxton/assets/js/libs/ace/css/editor.css | 447 +
.../assets/js/libs/ace/css/expand-marker.png | Bin 0 -> 290 bytes
src/fauxton/assets/js/libs/ace/document.js | 642 +
src/fauxton/assets/js/libs/ace/document_test.js | 306 +
src/fauxton/assets/js/libs/ace/edit_session.js | 2505 ++
.../js/libs/ace/edit_session/bracket_match.js | 219 +
.../assets/js/libs/ace/edit_session/fold.js | 140 +
.../js/libs/ace/edit_session/fold_line.js | 268 +
.../assets/js/libs/ace/edit_session/folding.js | 799 +
.../assets/js/libs/ace/edit_session_test.js | 1075 +
src/fauxton/assets/js/libs/ace/editor.js | 2423 ++
.../js/libs/ace/editor_change_document_test.js | 188 +
.../ace/editor_highlight_selected_word_test.js | 223 +
.../js/libs/ace/editor_navigation_test.js | 164 +
.../assets/js/libs/ace/editor_text_edit_test.js | 557 +
src/fauxton/assets/js/libs/ace/ext/chromevox.js | 980 +
.../js/libs/ace/ext/elastic_tabstops_lite.js | 319 +
src/fauxton/assets/js/libs/ace/ext/emmet.js | 415 +
.../assets/js/libs/ace/ext/keybinding_menu.js | 86 +
.../assets/js/libs/ace/ext/language_tools.js | 129 +
.../ext/menu_tools/add_editor_menu_options.js | 103 +
.../ace/ext/menu_tools/element_generator.js | 148 +
.../ext/menu_tools/generate_settings_menu.js | 258 +
.../menu_tools/get_editor_keyboard_shortcuts.js | 100 +
.../ace/ext/menu_tools/get_set_functions.js | 141 +
.../js/libs/ace/ext/menu_tools/overlay_page.js | 116 +
.../libs/ace/ext/menu_tools/settings_menu.css | 48 +
src/fauxton/assets/js/libs/ace/ext/modelist.js | 174 +
src/fauxton/assets/js/libs/ace/ext/old_ie.js | 108 +
.../assets/js/libs/ace/ext/old_ie_test.js | 77 +
.../assets/js/libs/ace/ext/searchbox.css | 157 +
src/fauxton/assets/js/libs/ace/ext/searchbox.js | 286 +
.../assets/js/libs/ace/ext/settings_menu.js | 76 +
.../assets/js/libs/ace/ext/spellcheck.js | 69 +
src/fauxton/assets/js/libs/ace/ext/split.js | 40 +
src/fauxton/assets/js/libs/ace/ext/static.css | 23 +
.../assets/js/libs/ace/ext/static_highlight.js | 180 +
.../js/libs/ace/ext/static_highlight_test.js | 89 +
src/fauxton/assets/js/libs/ace/ext/statusbar.js | 49 +
src/fauxton/assets/js/libs/ace/ext/textarea.js | 547 +
src/fauxton/assets/js/libs/ace/ext/themelist.js | 79 +
.../js/libs/ace/ext/themelist_utils/themes.js | 36 +
.../assets/js/libs/ace/ext/whitespace.js | 212 +
.../assets/js/libs/ace/incremental_search.js | 259 +
.../js/libs/ace/incremental_search_test.js | 208 +
.../assets/js/libs/ace/keyboard/emacs.js | 599 +
.../assets/js/libs/ace/keyboard/emacs_test.js | 73 +
.../assets/js/libs/ace/keyboard/hash_handler.js | 195 +
.../assets/js/libs/ace/keyboard/keybinding.js | 136 +
.../js/libs/ace/keyboard/keybinding_test.js | 69 +
.../js/libs/ace/keyboard/state_handler.js | 249 +
.../assets/js/libs/ace/keyboard/textinput.js | 503 +
src/fauxton/assets/js/libs/ace/keyboard/vim.js | 195 +
.../assets/js/libs/ace/keyboard/vim/commands.js | 613 +
.../js/libs/ace/keyboard/vim/maps/aliases.js | 94 +
.../js/libs/ace/keyboard/vim/maps/motions.js | 664 +
.../js/libs/ace/keyboard/vim/maps/operators.js | 195 +
.../js/libs/ace/keyboard/vim/maps/util.js | 134 +
.../js/libs/ace/keyboard/vim/registers.js | 42 +
src/fauxton/assets/js/libs/ace/layer/cursor.js | 217 +
src/fauxton/assets/js/libs/ace/layer/gutter.js | 265 +
src/fauxton/assets/js/libs/ace/layer/marker.js | 218 +
src/fauxton/assets/js/libs/ace/layer/text.js | 661 +
.../assets/js/libs/ace/layer/text_test.js | 126 +
src/fauxton/assets/js/libs/ace/lib/dom.js | 283 +
src/fauxton/assets/js/libs/ace/lib/es5-shim.js | 1062 +
src/fauxton/assets/js/libs/ace/lib/event.js | 353 +
.../assets/js/libs/ace/lib/event_emitter.js | 155 +
.../js/libs/ace/lib/event_emitter_test.js | 65 +
.../assets/js/libs/ace/lib/fixoldbrowsers.js | 19 +
src/fauxton/assets/js/libs/ace/lib/keys.js | 138 +
src/fauxton/assets/js/libs/ace/lib/lang.js | 212 +
src/fauxton/assets/js/libs/ace/lib/net.js | 41 +
src/fauxton/assets/js/libs/ace/lib/oop.js | 55 +
src/fauxton/assets/js/libs/ace/lib/regexp.js | 113 +
src/fauxton/assets/js/libs/ace/lib/useragent.js | 103 +
.../assets/js/libs/ace/mode/_test/Readme.md | 9 +
.../libs/ace/mode/_test/highlight_rules_test.js | 152 +
.../assets/js/libs/ace/mode/_test/package.json | 8 +
.../js/libs/ace/mode/_test/text_asciidoc.txt | 111 +
.../js/libs/ace/mode/_test/text_coffee.txt | 56 +
.../js/libs/ace/mode/_test/text_curly.txt | 9 +
.../assets/js/libs/ace/mode/_test/text_html.txt | 8 +
.../js/libs/ace/mode/_test/text_javascript.txt | 86 +
.../js/libs/ace/mode/_test/text_livescript.txt | 1 +
.../js/libs/ace/mode/_test/text_lucene.txt | 16 +
.../js/libs/ace/mode/_test/text_markdown.txt | 22 +
.../assets/js/libs/ace/mode/_test/text_ruby.txt | 34 +
.../assets/js/libs/ace/mode/_test/text_xml.txt | 7 +
.../js/libs/ace/mode/_test/tokens_abap.json | 189 +
.../ace/mode/_test/tokens_actionscript.json | 263 +
.../js/libs/ace/mode/_test/tokens_asciidoc.json | 422 +
.../ace/mode/_test/tokens_assembly_x86.json | 114 +
.../libs/ace/mode/_test/tokens_autohotkey.json | 261 +
.../libs/ace/mode/_test/tokens_batchfile.json | 70 +
.../js/libs/ace/mode/_test/tokens_c9search.json | 104 +
.../js/libs/ace/mode/_test/tokens_c_cpp.json | 185 +
.../js/libs/ace/mode/_test/tokens_clojure.json | 162 +
.../js/libs/ace/mode/_test/tokens_coffee.json | 528 +
.../libs/ace/mode/_test/tokens_coldfusion.json | 26 +
.../js/libs/ace/mode/_test/tokens_csharp.json | 31 +
.../js/libs/ace/mode/_test/tokens_css.json | 148 +
.../js/libs/ace/mode/_test/tokens_curly.json | 56 +
.../js/libs/ace/mode/_test/tokens_dart.json | 368 +
.../js/libs/ace/mode/_test/tokens_diff.json | 398 +
.../js/libs/ace/mode/_test/tokens_dot.json | 2254 ++
.../js/libs/ace/mode/_test/tokens_erlang.json | 166 +
.../js/libs/ace/mode/_test/tokens_forth.json | 219 +
.../js/libs/ace/mode/_test/tokens_ftl.json | 341 +
.../js/libs/ace/mode/_test/tokens_glsl.json | 127 +
.../js/libs/ace/mode/_test/tokens_golang.json | 256 +
.../js/libs/ace/mode/_test/tokens_groovy.json | 410 +
.../js/libs/ace/mode/_test/tokens_haml.json | 174 +
.../js/libs/ace/mode/_test/tokens_haskell.json | 156 +
.../js/libs/ace/mode/_test/tokens_haxe.json | 143 +
.../js/libs/ace/mode/_test/tokens_html.json | 51 +
.../libs/ace/mode/_test/tokens_html_ruby.json | 247 +
.../js/libs/ace/mode/_test/tokens_jade.json | 188 +
.../js/libs/ace/mode/_test/tokens_java.json | 95 +
.../libs/ace/mode/_test/tokens_javascript.json | 592 +
.../js/libs/ace/mode/_test/tokens_json.json | 412 +
.../js/libs/ace/mode/_test/tokens_jsp.json | 435 +
.../js/libs/ace/mode/_test/tokens_jsx.json | 51 +
.../js/libs/ace/mode/_test/tokens_julia.json | 105 +
.../js/libs/ace/mode/_test/tokens_latex.json | 127 +
.../js/libs/ace/mode/_test/tokens_less.json | 204 +
.../js/libs/ace/mode/_test/tokens_liquid.json | 551 +
.../js/libs/ace/mode/_test/tokens_lisp.json | 248 +
.../libs/ace/mode/_test/tokens_livescript.json | 6 +
.../js/libs/ace/mode/_test/tokens_logiql.json | 190 +
.../js/libs/ace/mode/_test/tokens_lsl.json | 495 +
.../js/libs/ace/mode/_test/tokens_lua.json | 348 +
.../js/libs/ace/mode/_test/tokens_luapage.json | 633 +
.../js/libs/ace/mode/_test/tokens_lucene.json | 92 +
.../js/libs/ace/mode/_test/tokens_markdown.json | 114 +
.../js/libs/ace/mode/_test/tokens_mushcode.json | 790 +
.../libs/ace/mode/_test/tokens_objectivec.json | 792 +
.../js/libs/ace/mode/_test/tokens_ocaml.json | 200 +
.../js/libs/ace/mode/_test/tokens_pascal.json | 297 +
.../js/libs/ace/mode/_test/tokens_perl.json | 227 +
.../js/libs/ace/mode/_test/tokens_pgsql.json | 735 +
.../js/libs/ace/mode/_test/tokens_php.json | 134 +
.../libs/ace/mode/_test/tokens_powershell.json | 184 +
.../js/libs/ace/mode/_test/tokens_prolog.json | 265 +
.../libs/ace/mode/_test/tokens_properties.json | 68 +
.../js/libs/ace/mode/_test/tokens_python.json | 152 +
.../assets/js/libs/ace/mode/_test/tokens_r.json | 235 +
.../js/libs/ace/mode/_test/tokens_rdoc.json | 441 +
.../js/libs/ace/mode/_test/tokens_rhtml.json | 106 +
.../js/libs/ace/mode/_test/tokens_ruby.json | 232 +
.../js/libs/ace/mode/_test/tokens_rust.json | 136 +
.../js/libs/ace/mode/_test/tokens_sass.json | 229 +
.../js/libs/ace/mode/_test/tokens_scad.json | 194 +
.../js/libs/ace/mode/_test/tokens_scala.json | 542 +
.../js/libs/ace/mode/_test/tokens_scheme.json | 216 +
.../js/libs/ace/mode/_test/tokens_scss.json | 123 +
.../js/libs/ace/mode/_test/tokens_sh.json | 334 +
.../js/libs/ace/mode/_test/tokens_snippets.json | 159 +
.../js/libs/ace/mode/_test/tokens_sql.json | 54 +
.../js/libs/ace/mode/_test/tokens_stylus.json | 271 +
.../js/libs/ace/mode/_test/tokens_svg.json | 684 +
.../js/libs/ace/mode/_test/tokens_tcl.json | 385 +
.../js/libs/ace/mode/_test/tokens_tex.json | 130 +
.../js/libs/ace/mode/_test/tokens_text.json | 29 +
.../js/libs/ace/mode/_test/tokens_textile.json | 113 +
.../js/libs/ace/mode/_test/tokens_toml.json | 131 +
.../js/libs/ace/mode/_test/tokens_twig.json | 288 +
.../libs/ace/mode/_test/tokens_typescript.json | 559 +
.../js/libs/ace/mode/_test/tokens_vbscript.json | 249 +
.../js/libs/ace/mode/_test/tokens_velocity.json | 281 +
.../js/libs/ace/mode/_test/tokens_xml.json | 43 +
.../js/libs/ace/mode/_test/tokens_xquery.json | 44 +
.../js/libs/ace/mode/_test/tokens_yaml.json | 150 +
src/fauxton/assets/js/libs/ace/mode/abap.js | 77 +
.../js/libs/ace/mode/abap_highlight_rules.js | 134 +
.../assets/js/libs/ace/mode/actionscript.js | 62 +
.../ace/mode/actionscript_highlight_rules.js | 141 +
src/fauxton/assets/js/libs/ace/mode/ada.js | 54 +
.../js/libs/ace/mode/ada_highlight_rules.js | 93 +
src/fauxton/assets/js/libs/ace/mode/asciidoc.js | 64 +
.../libs/ace/mode/asciidoc_highlight_rules.js | 234 +
.../assets/js/libs/ace/mode/assembly_x86.js | 56 +
.../ace/mode/assembly_x86_highlight_rules.js | 114 +
.../assets/js/libs/ace/mode/autohotkey.js | 62 +
.../libs/ace/mode/autohotkey_highlight_rules.js | 107 +
.../assets/js/libs/ace/mode/batchfile.js | 61 +
.../libs/ace/mode/batchfile_highlight_rules.js | 97 +
.../assets/js/libs/ace/mode/behaviour.js | 90 +
.../assets/js/libs/ace/mode/behaviour/css.js | 108 +
.../assets/js/libs/ace/mode/behaviour/cstyle.js | 365 +
.../assets/js/libs/ace/mode/behaviour/html.js | 88 +
.../assets/js/libs/ace/mode/behaviour/xml.js | 103 +
.../assets/js/libs/ace/mode/behaviour/xquery.js | 92 +
src/fauxton/assets/js/libs/ace/mode/c9search.js | 67 +
.../libs/ace/mode/c9search_highlight_rules.js | 59 +
src/fauxton/assets/js/libs/ace/mode/c_cpp.js | 101 +
.../js/libs/ace/mode/c_cpp_highlight_rules.js | 183 +
src/fauxton/assets/js/libs/ace/mode/clojure.js | 86 +
.../js/libs/ace/mode/clojure_highlight_rules.js | 200 +
src/fauxton/assets/js/libs/ace/mode/cobol.js | 53 +
.../js/libs/ace/mode/cobol_highlight_rules.js | 100 +
src/fauxton/assets/js/libs/ace/mode/coffee.js | 114 +
.../js/libs/ace/mode/coffee/coffee-script.js | 62 +
.../assets/js/libs/ace/mode/coffee/helpers.js | 271 +
.../assets/js/libs/ace/mode/coffee/lexer.js | 929 +
.../assets/js/libs/ace/mode/coffee/nodes.js | 3080 ++
.../assets/js/libs/ace/mode/coffee/parser.js | 724 +
.../js/libs/ace/mode/coffee/parser_test.js | 88 +
.../assets/js/libs/ace/mode/coffee/rewriter.js | 513 +
.../assets/js/libs/ace/mode/coffee/scope.js | 174 +
.../js/libs/ace/mode/coffee_highlight_rules.js | 233 +
.../assets/js/libs/ace/mode/coffee_worker.js | 74 +
.../assets/js/libs/ace/mode/coldfusion.js | 62 +
.../libs/ace/mode/coldfusion_highlight_rules.js | 49 +
.../assets/js/libs/ace/mode/coldfusion_test.js | 67 +
src/fauxton/assets/js/libs/ace/mode/csharp.js | 61 +
.../js/libs/ace/mode/csharp_highlight_rules.js | 96 +
src/fauxton/assets/js/libs/ace/mode/css.js | 100 +
.../assets/js/libs/ace/mode/css/csslint.js | 9206 +++++
.../js/libs/ace/mode/css_highlight_rules.js | 179 +
src/fauxton/assets/js/libs/ace/mode/css_test.js | 78 +
.../assets/js/libs/ace/mode/css_worker.js | 95 +
.../assets/js/libs/ace/mode/css_worker_test.js | 68 +
src/fauxton/assets/js/libs/ace/mode/curly.js | 63 +
.../js/libs/ace/mode/curly_highlight_rules.js | 66 +
src/fauxton/assets/js/libs/ace/mode/d.js | 56 +
.../js/libs/ace/mode/d_highlight_rules.js | 318 +
src/fauxton/assets/js/libs/ace/mode/dart.js | 62 +
.../js/libs/ace/mode/dart_highlight_rules.js | 182 +
src/fauxton/assets/js/libs/ace/mode/diff.js | 52 +
.../js/libs/ace/mode/diff_highlight_rules.js | 108 +
src/fauxton/assets/js/libs/ace/mode/django.js | 116 +
.../ace/mode/doc_comment_highlight_rules.js | 73 +
src/fauxton/assets/js/libs/ace/mode/dot.js | 55 +
.../js/libs/ace/mode/dot_highlight_rules.js | 126 +
src/fauxton/assets/js/libs/ace/mode/ejs.js | 109 +
src/fauxton/assets/js/libs/ace/mode/erlang.js | 57 +
.../js/libs/ace/mode/erlang_highlight_rules.js | 876 +
.../assets/js/libs/ace/mode/folding/asciidoc.js | 142 +
.../assets/js/libs/ace/mode/folding/c9search.js | 77 +
.../assets/js/libs/ace/mode/folding/coffee.js | 120 +
.../js/libs/ace/mode/folding/coffee_test.js | 101 +
.../assets/js/libs/ace/mode/folding/csharp.js | 138 +
.../assets/js/libs/ace/mode/folding/cstyle.js | 83 +
.../js/libs/ace/mode/folding/cstyle_test.js | 85 +
.../assets/js/libs/ace/mode/folding/diff.js | 69 +
.../js/libs/ace/mode/folding/fold_mode.js | 120 +
.../assets/js/libs/ace/mode/folding/html.js | 79 +
.../js/libs/ace/mode/folding/html_test.js | 162 +
.../assets/js/libs/ace/mode/folding/ini.js | 80 +
.../assets/js/libs/ace/mode/folding/latex.js | 162 +
.../assets/js/libs/ace/mode/folding/lua.js | 163 +
.../assets/js/libs/ace/mode/folding/markdown.js | 125 +
.../assets/js/libs/ace/mode/folding/mixed.js | 83 +
.../assets/js/libs/ace/mode/folding/pythonic.js | 58 +
.../js/libs/ace/mode/folding/pythonic_test.js | 98 +
.../assets/js/libs/ace/mode/folding/velocity.js | 120 +
.../assets/js/libs/ace/mode/folding/xml.js | 254 +
.../assets/js/libs/ace/mode/folding/xml_test.js | 110 +
src/fauxton/assets/js/libs/ace/mode/forth.js | 62 +
.../js/libs/ace/mode/forth_highlight_rules.js | 164 +
src/fauxton/assets/js/libs/ace/mode/ftl.js | 49 +
.../js/libs/ace/mode/ftl_highlight_rules.js | 195 +
src/fauxton/assets/js/libs/ace/mode/glsl.js | 53 +
.../js/libs/ace/mode/glsl_highlight_rules.js | 81 +
src/fauxton/assets/js/libs/ace/mode/golang.js | 55 +
.../js/libs/ace/mode/golang_highlight_rules.js | 111 +
src/fauxton/assets/js/libs/ace/mode/groovy.js | 24 +
.../js/libs/ace/mode/groovy_highlight_rules.js | 173 +
src/fauxton/assets/js/libs/ace/mode/haml.js | 61 +
.../js/libs/ace/mode/haml_highlight_rules.js | 132 +
.../assets/js/libs/ace/mode/handlebars.js | 29 +
.../libs/ace/mode/handlebars_highlight_rules.js | 72 +
src/fauxton/assets/js/libs/ace/mode/haskell.js | 62 +
.../js/libs/ace/mode/haskell_highlight_rules.js | 246 +
src/fauxton/assets/js/libs/ace/mode/haxe.js | 56 +
.../js/libs/ace/mode/haxe_highlight_rules.js | 98 +
src/fauxton/assets/js/libs/ace/mode/html.js | 77 +
.../assets/js/libs/ace/mode/html_completions.js | 313 +
.../js/libs/ace/mode/html_highlight_rules.js | 123 +
.../assets/js/libs/ace/mode/html_ruby.js | 59 +
.../libs/ace/mode/html_ruby_highlight_rules.js | 84 +
.../assets/js/libs/ace/mode/html_test.js | 67 +
src/fauxton/assets/js/libs/ace/mode/ini.js | 53 +
.../js/libs/ace/mode/ini_highlight_rules.js | 112 +
src/fauxton/assets/js/libs/ace/mode/jack.js | 79 +
.../js/libs/ace/mode/jack_highlight_rules.js | 142 +
src/fauxton/assets/js/libs/ace/mode/jade.js | 57 +
.../js/libs/ace/mode/jade_highlight_rules.js | 341 +
src/fauxton/assets/js/libs/ace/mode/java.js | 24 +
.../js/libs/ace/mode/java_highlight_rules.js | 131 +
.../assets/js/libs/ace/mode/javascript.js | 116 +
.../js/libs/ace/mode/javascript/jshint.js | 9072 +++++
.../libs/ace/mode/javascript_highlight_rules.js | 362 +
.../assets/js/libs/ace/mode/javascript_test.js | 213 +
.../js/libs/ace/mode/javascript_worker.js | 187 +
.../js/libs/ace/mode/javascript_worker_test.js | 106 +
.../libs/ace/mode/js_regex_highlight_rules.js | 94 +
src/fauxton/assets/js/libs/ace/mode/json.js | 93 +
.../assets/js/libs/ace/mode/json/json_parse.js | 346 +
.../js/libs/ace/mode/json_highlight_rules.js | 100 +
.../assets/js/libs/ace/mode/json_worker.js | 67 +
.../assets/js/libs/ace/mode/json_worker_test.js | 101 +
src/fauxton/assets/js/libs/ace/mode/jsoniq.js | 106 +
src/fauxton/assets/js/libs/ace/mode/jsp.js | 55 +
.../js/libs/ace/mode/jsp_highlight_rules.js | 91 +
src/fauxton/assets/js/libs/ace/mode/jsx.js | 56 +
.../js/libs/ace/mode/jsx_highlight_rules.js | 120 +
src/fauxton/assets/js/libs/ace/mode/julia.js | 62 +
.../js/libs/ace/mode/julia_highlight_rules.js | 170 +
src/fauxton/assets/js/libs/ace/mode/latex.js | 24 +
.../js/libs/ace/mode/latex_highlight_rules.js | 38 +
src/fauxton/assets/js/libs/ace/mode/less.js | 84 +
.../js/libs/ace/mode/less_highlight_rules.js | 271 +
src/fauxton/assets/js/libs/ace/mode/liquid.js | 82 +
.../js/libs/ace/mode/liquid_highlight_rules.js | 131 +
src/fauxton/assets/js/libs/ace/mode/lisp.js | 56 +
.../js/libs/ace/mode/lisp_highlight_rules.js | 124 +
.../assets/js/libs/ace/mode/livescript.js | 248 +
src/fauxton/assets/js/libs/ace/mode/logiql.js | 139 +
.../js/libs/ace/mode/logiql_highlight_rules.js | 119 +
.../assets/js/libs/ace/mode/logiql_test.js | 99 +
src/fauxton/assets/js/libs/ace/mode/lsl.js | 92 +
.../js/libs/ace/mode/lsl_highlight_rules.js | 363 +
src/fauxton/assets/js/libs/ace/mode/lua.js | 168 +
.../assets/js/libs/ace/mode/lua/luaparse.js | 1989 +
.../js/libs/ace/mode/lua_highlight_rules.js | 193 +
.../assets/js/libs/ace/mode/lua_worker.js | 71 +
src/fauxton/assets/js/libs/ace/mode/luapage.js | 21 +
.../js/libs/ace/mode/luapage_highlight_rules.js | 49 +
src/fauxton/assets/js/libs/ace/mode/lucene.js | 16 +
.../js/libs/ace/mode/lucene_highlight_rules.js | 49 +
src/fauxton/assets/js/libs/ace/mode/makefile.js | 63 +
.../libs/ace/mode/makefile_highlight_rules.js | 75 +
src/fauxton/assets/js/libs/ace/mode/markdown.js | 76 +
.../libs/ace/mode/markdown_highlight_rules.js | 219 +
.../js/libs/ace/mode/matching_brace_outdent.js | 69 +
.../js/libs/ace/mode/matching_parens_outdent.js | 74 +
src/fauxton/assets/js/libs/ace/mode/matlab.js | 55 +
.../js/libs/ace/mode/matlab_highlight_rules.js | 204 +
src/fauxton/assets/js/libs/ace/mode/mushcode.js | 116 +
.../js/libs/ace/mode/mushcode_high_rules.js | 569 +
src/fauxton/assets/js/libs/ace/mode/mysql.js | 51 +
.../js/libs/ace/mode/mysql_highlight_rules.js | 122 +
src/fauxton/assets/js/libs/ace/mode/nix.js | 62 +
.../js/libs/ace/mode/nix_highlight_rules.js | 119 +
.../assets/js/libs/ace/mode/objectivec.js | 61 +
.../libs/ace/mode/objectivec_highlight_rules.js | 331 +
src/fauxton/assets/js/libs/ace/mode/ocaml.js | 97 +
.../js/libs/ace/mode/ocaml_highlight_rules.js | 337 +
src/fauxton/assets/js/libs/ace/mode/pascal.js | 67 +
.../js/libs/ace/mode/pascal_highlight_rules.js | 127 +
src/fauxton/assets/js/libs/ace/mode/perl.js | 90 +
.../js/libs/ace/mode/perl_highlight_rules.js | 165 +
src/fauxton/assets/js/libs/ace/mode/pgsql.js | 59 +
.../js/libs/ace/mode/pgsql_highlight_rules.js | 570 +
src/fauxton/assets/js/libs/ace/mode/php.js | 135 +
src/fauxton/assets/js/libs/ace/mode/php/php.js | 5003 +++
.../js/libs/ace/mode/php_highlight_rules.js | 1088 +
.../assets/js/libs/ace/mode/php_worker.js | 76 +
.../assets/js/libs/ace/mode/plain_text.js | 55 +
.../assets/js/libs/ace/mode/plain_text_test.js | 56 +
.../assets/js/libs/ace/mode/powershell.js | 61 +
.../libs/ace/mode/powershell_highlight_rules.js | 145 +
src/fauxton/assets/js/libs/ace/mode/prolog.js | 62 +
.../js/libs/ace/mode/prolog_highlight_rules.js | 238 +
.../assets/js/libs/ace/mode/properties.js | 45 +
.../libs/ace/mode/properties_highlight_rules.js | 86 +
src/fauxton/assets/js/libs/ace/mode/protobuf.js | 66 +
.../libs/ace/mode/protobuf_highlight_rules.js | 66 +
src/fauxton/assets/js/libs/ace/mode/python.js | 113 +
.../js/libs/ace/mode/python_highlight_rules.js | 191 +
.../assets/js/libs/ace/mode/python_test.js | 79 +
src/fauxton/assets/js/libs/ace/mode/r.js | 154 +
.../js/libs/ace/mode/r_highlight_rules.js | 188 +
src/fauxton/assets/js/libs/ace/mode/rdoc.js | 61 +
.../js/libs/ace/mode/rdoc_highlight_rules.js | 99 +
src/fauxton/assets/js/libs/ace/mode/rhtml.js | 86 +
.../js/libs/ace/mode/rhtml_highlight_rules.js | 46 +
src/fauxton/assets/js/libs/ace/mode/ruby.js | 91 +
.../js/libs/ace/mode/ruby_highlight_rules.js | 249 +
.../assets/js/libs/ace/mode/ruby_test.js | 78 +
src/fauxton/assets/js/libs/ace/mode/rust.js | 62 +
.../js/libs/ace/mode/rust_highlight_rules.js | 129 +
src/fauxton/assets/js/libs/ace/mode/sass.js | 52 +
.../js/libs/ace/mode/sass_highlight_rules.js | 79 +
src/fauxton/assets/js/libs/ace/mode/scad.js | 99 +
.../js/libs/ace/mode/scad_highlight_rules.js | 142 +
src/fauxton/assets/js/libs/ace/mode/scala.js | 25 +
.../js/libs/ace/mode/scala_highlight_rules.js | 160 +
src/fauxton/assets/js/libs/ace/mode/scheme.js | 56 +
.../js/libs/ace/mode/scheme_highlight_rules.js | 123 +
src/fauxton/assets/js/libs/ace/mode/scss.js | 84 +
.../js/libs/ace/mode/scss_highlight_rules.js | 296 +
src/fauxton/assets/js/libs/ace/mode/sh.js | 112 +
.../js/libs/ace/mode/sh_highlight_rules.js | 144 +
src/fauxton/assets/js/libs/ace/mode/sjs.js | 59 +
.../js/libs/ace/mode/sjs_highlight_rules.js | 233 +
src/fauxton/assets/js/libs/ace/mode/snippets.js | 112 +
.../assets/js/libs/ace/mode/soy_template.js | 60 +
.../ace/mode/soy_template_highlight_rules.js | 356 +
src/fauxton/assets/js/libs/ace/mode/space.js | 21 +
.../js/libs/ace/mode/space_highlight_rules.js | 56 +
src/fauxton/assets/js/libs/ace/mode/sql.js | 53 +
.../js/libs/ace/mode/sql_highlight_rules.js | 94 +
src/fauxton/assets/js/libs/ace/mode/stylus.js | 59 +
.../js/libs/ace/mode/stylus_highlight_rules.js | 165 +
src/fauxton/assets/js/libs/ace/mode/svg.js | 69 +
.../js/libs/ace/mode/svg_highlight_rules.js | 49 +
src/fauxton/assets/js/libs/ace/mode/tcl.js | 84 +
.../js/libs/ace/mode/tcl_highlight_rules.js | 172 +
src/fauxton/assets/js/libs/ace/mode/tex.js | 68 +
.../js/libs/ace/mode/tex_highlight_rules.js | 107 +
src/fauxton/assets/js/libs/ace/mode/text.js | 384 +
.../js/libs/ace/mode/text_highlight_rules.js | 234 +
.../assets/js/libs/ace/mode/text_test.js | 64 +
src/fauxton/assets/js/libs/ace/mode/textile.js | 66 +
.../js/libs/ace/mode/textile_highlight_rules.js | 93 +
src/fauxton/assets/js/libs/ace/mode/toml.js | 56 +
.../js/libs/ace/mode/toml_highlight_rules.js | 103 +
src/fauxton/assets/js/libs/ace/mode/twig.js | 92 +
.../js/libs/ace/mode/twig_highlight_rules.js | 166 +
.../assets/js/libs/ace/mode/typescript.js | 62 +
.../libs/ace/mode/typescript_highlight_rules.js | 98 +
src/fauxton/assets/js/libs/ace/mode/vbscript.js | 60 +
.../libs/ace/mode/vbscript_highlight_rules.js | 276 +
src/fauxton/assets/js/libs/ace/mode/velocity.js | 59 +
.../libs/ace/mode/velocity_highlight_rules.js | 177 +
src/fauxton/assets/js/libs/ace/mode/verilog.js | 54 +
.../js/libs/ace/mode/verilog_highlight_rules.js | 101 +
src/fauxton/assets/js/libs/ace/mode/vhdl.js | 52 +
.../js/libs/ace/mode/vhdl_highlight_rules.js | 115 +
src/fauxton/assets/js/libs/ace/mode/xml.js | 56 +
.../js/libs/ace/mode/xml_highlight_rules.js | 216 +
src/fauxton/assets/js/libs/ace/mode/xml_test.js | 75 +
src/fauxton/assets/js/libs/ace/mode/xml_util.js | 100 +
src/fauxton/assets/js/libs/ace/mode/xquery.js | 139 +
.../ace/mode/xquery/JSONParseTreeHandler.js | 178 +
.../js/libs/ace/mode/xquery/JSONiqLexer.js | 302 +
.../libs/ace/mode/xquery/JSONiqTokenizer.ebnf | 544 +
.../js/libs/ace/mode/xquery/JSONiqTokenizer.js | 4205 +++
.../assets/js/libs/ace/mode/xquery/Readme.md | 6 +
.../js/libs/ace/mode/xquery/XQueryLexer.js | 303 +
.../js/libs/ace/mode/xquery/XQueryParser.ebnf | 1180 +
.../js/libs/ace/mode/xquery/XQueryParser.js | 33487 +++++++++++++++++
.../libs/ace/mode/xquery/XQueryTokenizer.ebnf | 543 +
.../js/libs/ace/mode/xquery/XQueryTokenizer.js | 4205 +++
.../mode/xquery/visitors/SemanticHighlighter.js | 76 +
.../assets/js/libs/ace/mode/xquery_worker.js | 81 +
src/fauxton/assets/js/libs/ace/mode/yaml.js | 78 +
.../js/libs/ace/mode/yaml_highlight_rules.js | 116 +
src/fauxton/assets/js/libs/ace/model/editor.js | 62 +
.../js/libs/ace/mouse/default_gutter_handler.js | 161 +
.../js/libs/ace/mouse/default_handlers.js | 274 +
.../js/libs/ace/mouse/dragdrop_handler.js | 417 +
.../assets/js/libs/ace/mouse/fold_handler.js | 93 +
.../assets/js/libs/ace/mouse/mouse_event.js | 129 +
.../assets/js/libs/ace/mouse/mouse_handler.js | 155 +
.../js/libs/ace/mouse/multi_select_handler.js | 160 +
src/fauxton/assets/js/libs/ace/multi_select.js | 934 +
.../assets/js/libs/ace/multi_select_test.js | 205 +
src/fauxton/assets/js/libs/ace/occur.js | 190 +
src/fauxton/assets/js/libs/ace/occur_test.js | 154 +
src/fauxton/assets/js/libs/ace/placeholder.js | 269 +
.../assets/js/libs/ace/placeholder_test.js | 156 +
src/fauxton/assets/js/libs/ace/range.js | 549 +
src/fauxton/assets/js/libs/ace/range_list.js | 240 +
.../assets/js/libs/ace/range_list_test.js | 182 +
src/fauxton/assets/js/libs/ace/range_test.js | 191 +
src/fauxton/assets/js/libs/ace/renderloop.js | 75 +
.../assets/js/libs/ace/requirejs/text.js | 51 +
src/fauxton/assets/js/libs/ace/scrollbar.js | 204 +
src/fauxton/assets/js/libs/ace/search.js | 389 +
.../assets/js/libs/ace/search_highlight.js | 82 +
src/fauxton/assets/js/libs/ace/search_test.js | 461 +
src/fauxton/assets/js/libs/ace/selection.js | 915 +
.../assets/js/libs/ace/selection_test.js | 480 +
src/fauxton/assets/js/libs/ace/snippets.js | 844 +
.../assets/js/libs/ace/snippets/_.snippets | 240 +
src/fauxton/assets/js/libs/ace/snippets/abap.js | 7 +
.../assets/js/libs/ace/snippets/abap.snippets | 0
.../assets/js/libs/ace/snippets/actionscript.js | 7 +
.../js/libs/ace/snippets/actionscript.snippets | 157 +
src/fauxton/assets/js/libs/ace/snippets/ada.js | 7 +
.../assets/js/libs/ace/snippets/ada.snippets | 0
.../assets/js/libs/ace/snippets/apache.snippets | 35 +
.../assets/js/libs/ace/snippets/asciidoc.js | 7 +
.../js/libs/ace/snippets/asciidoc.snippets | 0
.../assets/js/libs/ace/snippets/assembly_x86.js | 7 +
.../js/libs/ace/snippets/assembly_x86.snippets | 0
.../assets/js/libs/ace/snippets/autohotkey.js | 7 +
.../js/libs/ace/snippets/autohotkey.snippets | 0
.../assets/js/libs/ace/snippets/autoit.snippets | 66 +
.../assets/js/libs/ace/snippets/batchfile.js | 7 +
.../js/libs/ace/snippets/batchfile.snippets | 0
.../assets/js/libs/ace/snippets/c.snippets | 235 +
.../assets/js/libs/ace/snippets/c9search.js | 7 +
.../js/libs/ace/snippets/c9search.snippets | 0
.../assets/js/libs/ace/snippets/c_cpp.js | 7 +
.../assets/js/libs/ace/snippets/c_cpp.snippets | 131 +
.../assets/js/libs/ace/snippets/chef.snippets | 204 +
.../assets/js/libs/ace/snippets/clojure.js | 7 +
.../js/libs/ace/snippets/clojure.snippets | 90 +
.../assets/js/libs/ace/snippets/cmake.snippets | 58 +
.../assets/js/libs/ace/snippets/cobol.js | 7 +
.../assets/js/libs/ace/snippets/cobol.snippets | 0
.../assets/js/libs/ace/snippets/coffee.js | 7 +
.../assets/js/libs/ace/snippets/coffee.snippets | 95 +
.../assets/js/libs/ace/snippets/coldfusion.js | 7 +
.../js/libs/ace/snippets/coldfusion.snippets | 0
.../assets/js/libs/ace/snippets/cs.snippets | 374 +
.../assets/js/libs/ace/snippets/csharp.js | 7 +
.../assets/js/libs/ace/snippets/csharp.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/css.js | 7 +
.../assets/js/libs/ace/snippets/css.snippets | 967 +
.../assets/js/libs/ace/snippets/curly.js | 7 +
.../assets/js/libs/ace/snippets/curly.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/d.js | 7 +
.../assets/js/libs/ace/snippets/d.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/dart.js | 7 +
.../assets/js/libs/ace/snippets/dart.snippets | 83 +
src/fauxton/assets/js/libs/ace/snippets/diff.js | 7 +
.../assets/js/libs/ace/snippets/diff.snippets | 11 +
.../assets/js/libs/ace/snippets/django.js | 7 +
.../assets/js/libs/ace/snippets/django.snippets | 108 +
src/fauxton/assets/js/libs/ace/snippets/dot.js | 7 +
.../assets/js/libs/ace/snippets/dot.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/ejs.js | 7 +
.../assets/js/libs/ace/snippets/ejs.snippets | 0
.../assets/js/libs/ace/snippets/erlang.js | 7 +
.../assets/js/libs/ace/snippets/erlang.snippets | 160 +
.../assets/js/libs/ace/snippets/eruby.snippets | 113 +
.../assets/js/libs/ace/snippets/falcon.snippets | 71 +
.../assets/js/libs/ace/snippets/forth.js | 7 +
.../assets/js/libs/ace/snippets/forth.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/ftl.js | 7 +
.../assets/js/libs/ace/snippets/ftl.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/glsl.js | 7 +
.../assets/js/libs/ace/snippets/glsl.snippets | 0
.../assets/js/libs/ace/snippets/go.snippets | 201 +
.../assets/js/libs/ace/snippets/golang.js | 7 +
.../assets/js/libs/ace/snippets/golang.snippets | 0
.../assets/js/libs/ace/snippets/groovy.js | 7 +
.../assets/js/libs/ace/snippets/groovy.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/haml.js | 7 +
.../assets/js/libs/ace/snippets/haml.snippets | 20 +
.../assets/js/libs/ace/snippets/handlebars.js | 7 +
.../js/libs/ace/snippets/handlebars.snippets | 0
.../assets/js/libs/ace/snippets/haskell.js | 7 +
.../js/libs/ace/snippets/haskell.snippets | 82 +
src/fauxton/assets/js/libs/ace/snippets/haxe.js | 7 +
.../assets/js/libs/ace/snippets/haxe.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/html.js | 7 +
.../assets/js/libs/ace/snippets/html.snippets | 828 +
.../assets/js/libs/ace/snippets/html_ruby.js | 7 +
.../js/libs/ace/snippets/html_ruby.snippets | 0
.../js/libs/ace/snippets/htmldjango.snippets | 136 +
.../js/libs/ace/snippets/htmltornado.snippets | 55 +
src/fauxton/assets/js/libs/ace/snippets/ini.js | 7 +
.../assets/js/libs/ace/snippets/ini.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/jade.js | 7 +
.../assets/js/libs/ace/snippets/jade.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/java.js | 7 +
.../assets/js/libs/ace/snippets/java.snippets | 240 +
.../ace/snippets/javascript-jquery.snippets | 589 +
.../assets/js/libs/ace/snippets/javascript.js | 7 +
.../js/libs/ace/snippets/javascript.snippets | 195 +
src/fauxton/assets/js/libs/ace/snippets/json.js | 7 +
.../assets/js/libs/ace/snippets/json.snippets | 0
.../assets/js/libs/ace/snippets/jsoniq.js | 7 +
.../assets/js/libs/ace/snippets/jsoniq.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/jsp.js | 7 +
.../assets/js/libs/ace/snippets/jsp.snippets | 99 +
src/fauxton/assets/js/libs/ace/snippets/jsx.js | 7 +
.../assets/js/libs/ace/snippets/jsx.snippets | 0
.../assets/js/libs/ace/snippets/julia.js | 7 +
.../assets/js/libs/ace/snippets/julia.snippets | 0
.../assets/js/libs/ace/snippets/latex.js | 7 +
.../assets/js/libs/ace/snippets/latex.snippets | 0
.../assets/js/libs/ace/snippets/ledger.snippets | 5 +
src/fauxton/assets/js/libs/ace/snippets/less.js | 7 +
.../assets/js/libs/ace/snippets/less.snippets | 0
.../assets/js/libs/ace/snippets/liquid.js | 7 +
.../assets/js/libs/ace/snippets/liquid.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/lisp.js | 7 +
.../assets/js/libs/ace/snippets/lisp.snippets | 0
.../assets/js/libs/ace/snippets/livescript.js | 7 +
.../js/libs/ace/snippets/livescript.snippets | 0
.../assets/js/libs/ace/snippets/logiql.js | 7 +
.../assets/js/libs/ace/snippets/logiql.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/lsl.js | 7 +
.../assets/js/libs/ace/snippets/lsl.snippets | 887 +
src/fauxton/assets/js/libs/ace/snippets/lua.js | 7 +
.../assets/js/libs/ace/snippets/lua.snippets | 21 +
.../assets/js/libs/ace/snippets/luapage.js | 7 +
.../js/libs/ace/snippets/luapage.snippets | 0
.../assets/js/libs/ace/snippets/lucene.js | 7 +
.../assets/js/libs/ace/snippets/lucene.snippets | 0
.../assets/js/libs/ace/snippets/makefile.js | 7 +
.../js/libs/ace/snippets/makefile.snippets | 4 +
.../assets/js/libs/ace/snippets/mako.snippets | 54 +
.../assets/js/libs/ace/snippets/markdown.js | 7 +
.../js/libs/ace/snippets/markdown.snippets | 88 +
.../assets/js/libs/ace/snippets/matlab.js | 7 +
.../assets/js/libs/ace/snippets/matlab.snippets | 0
.../assets/js/libs/ace/snippets/mushcode.js | 7 +
.../js/libs/ace/snippets/mushcode.snippets | 0
.../js/libs/ace/snippets/mushcode_high_rules.js | 7 +
.../ace/snippets/mushcode_high_rules.snippets | 0
.../assets/js/libs/ace/snippets/mysql.js | 7 +
.../assets/js/libs/ace/snippets/mysql.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/nix.js | 7 +
.../assets/js/libs/ace/snippets/nix.snippets | 0
.../assets/js/libs/ace/snippets/objc.snippets | 247 +
.../assets/js/libs/ace/snippets/objectivec.js | 7 +
.../js/libs/ace/snippets/objectivec.snippets | 0
.../assets/js/libs/ace/snippets/ocaml.js | 7 +
.../assets/js/libs/ace/snippets/ocaml.snippets | 0
.../assets/js/libs/ace/snippets/pascal.js | 7 +
.../assets/js/libs/ace/snippets/pascal.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/perl.js | 7 +
.../assets/js/libs/ace/snippets/perl.snippets | 347 +
.../assets/js/libs/ace/snippets/pgsql.js | 7 +
.../assets/js/libs/ace/snippets/pgsql.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/php.js | 7 +
.../assets/js/libs/ace/snippets/php.snippets | 377 +
.../assets/js/libs/ace/snippets/powershell.js | 7 +
.../js/libs/ace/snippets/powershell.snippets | 0
.../assets/js/libs/ace/snippets/prolog.js | 7 +
.../assets/js/libs/ace/snippets/prolog.snippets | 0
.../assets/js/libs/ace/snippets/properties.js | 7 +
.../js/libs/ace/snippets/properties.snippets | 0
.../assets/js/libs/ace/snippets/protobuf.js | 7 +
.../assets/js/libs/ace/snippets/python.js | 7 +
.../assets/js/libs/ace/snippets/python.snippets | 158 +
src/fauxton/assets/js/libs/ace/snippets/r.js | 7 +
.../assets/js/libs/ace/snippets/r.snippets | 121 +
src/fauxton/assets/js/libs/ace/snippets/rdoc.js | 7 +
.../assets/js/libs/ace/snippets/rdoc.snippets | 0
.../assets/js/libs/ace/snippets/rhtml.js | 7 +
.../assets/js/libs/ace/snippets/rhtml.snippets | 0
.../assets/js/libs/ace/snippets/rst.snippets | 22 +
src/fauxton/assets/js/libs/ace/snippets/ruby.js | 7 +
.../assets/js/libs/ace/snippets/ruby.snippets | 928 +
src/fauxton/assets/js/libs/ace/snippets/rust.js | 7 +
.../assets/js/libs/ace/snippets/rust.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/sass.js | 7 +
.../assets/js/libs/ace/snippets/sass.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/scad.js | 7 +
.../assets/js/libs/ace/snippets/scad.snippets | 0
.../assets/js/libs/ace/snippets/scala.js | 7 +
.../assets/js/libs/ace/snippets/scala.snippets | 0
.../assets/js/libs/ace/snippets/scheme.js | 7 +
.../assets/js/libs/ace/snippets/scheme.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/scss.js | 7 +
.../assets/js/libs/ace/snippets/scss.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/sh.js | 7 +
.../assets/js/libs/ace/snippets/sh.snippets | 83 +
.../assets/js/libs/ace/snippets/snippets.js | 7 +
.../js/libs/ace/snippets/snippets.snippets | 9 +
.../assets/js/libs/ace/snippets/soy_template.js | 7 +
.../js/libs/ace/snippets/soy_template.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/sql.js | 7 +
.../assets/js/libs/ace/snippets/sql.snippets | 26 +
.../assets/js/libs/ace/snippets/stylus.js | 7 +
.../assets/js/libs/ace/snippets/stylus.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/svg.js | 7 +
.../assets/js/libs/ace/snippets/svg.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/tcl.js | 7 +
.../assets/js/libs/ace/snippets/tcl.snippets | 92 +
src/fauxton/assets/js/libs/ace/snippets/tex.js | 7 +
.../assets/js/libs/ace/snippets/tex.snippets | 191 +
src/fauxton/assets/js/libs/ace/snippets/text.js | 7 +
.../assets/js/libs/ace/snippets/text.snippets | 0
.../assets/js/libs/ace/snippets/textile.js | 7 +
.../js/libs/ace/snippets/textile.snippets | 30 +
.../js/libs/ace/snippets/tmsnippet.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/toml.js | 7 +
.../assets/js/libs/ace/snippets/toml.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/twig.js | 7 +
.../assets/js/libs/ace/snippets/twig.snippets | 0
.../assets/js/libs/ace/snippets/typescript.js | 7 +
.../js/libs/ace/snippets/typescript.snippets | 0
.../assets/js/libs/ace/snippets/vbscript.js | 7 +
.../js/libs/ace/snippets/vbscript.snippets | 0
.../assets/js/libs/ace/snippets/velocity.js | 7 +
.../js/libs/ace/snippets/velocity.snippets | 0
.../assets/js/libs/ace/snippets/verilog.js | 7 +
.../js/libs/ace/snippets/verilog.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/vhdl.js | 7 +
.../assets/js/libs/ace/snippets/vhdl.snippets | 0
src/fauxton/assets/js/libs/ace/snippets/xml.js | 7 +
.../assets/js/libs/ace/snippets/xml.snippets | 0
.../assets/js/libs/ace/snippets/xquery.js | 7 +
.../assets/js/libs/ace/snippets/xquery.snippets | 0
.../assets/js/libs/ace/snippets/xslt.snippets | 97 +
src/fauxton/assets/js/libs/ace/snippets/yaml.js | 7 +
.../assets/js/libs/ace/snippets/yaml.snippets | 0
src/fauxton/assets/js/libs/ace/snippets_test.js | 131 +
src/fauxton/assets/js/libs/ace/split.js | 373 +
src/fauxton/assets/js/libs/ace/test/all.js | 35 +
.../assets/js/libs/ace/test/all_browser.js | 138 +
.../assets/js/libs/ace/test/assertions.js | 56 +
.../assets/js/libs/ace/test/asyncjs/assert.js | 313 +
.../assets/js/libs/ace/test/asyncjs/async.js | 529 +
.../assets/js/libs/ace/test/asyncjs/index.js | 13 +
.../assets/js/libs/ace/test/asyncjs/test.js | 195 +
.../assets/js/libs/ace/test/asyncjs/utils.js | 65 +
.../assets/js/libs/ace/test/benchmark.js | 78 +
src/fauxton/assets/js/libs/ace/test/mockdom.js | 10 +
.../assets/js/libs/ace/test/mockrenderer.js | 201 +
src/fauxton/assets/js/libs/ace/test/tests.html | 46 +
.../assets/js/libs/ace/theme/ambiance.css | 217 +
.../assets/js/libs/ace/theme/ambiance.js | 33 +
src/fauxton/assets/js/libs/ace/theme/chaos.css | 154 +
src/fauxton/assets/js/libs/ace/theme/chaos.js | 33 +
src/fauxton/assets/js/libs/ace/theme/chrome.css | 153 +
src/fauxton/assets/js/libs/ace/theme/chrome.js | 39 +
src/fauxton/assets/js/libs/ace/theme/clouds.css | 112 +
src/fauxton/assets/js/libs/ace/theme/clouds.js | 39 +
.../js/libs/ace/theme/clouds_midnight.css | 113 +
.../assets/js/libs/ace/theme/clouds_midnight.js | 39 +
src/fauxton/assets/js/libs/ace/theme/cobalt.css | 132 +
src/fauxton/assets/js/libs/ace/theme/cobalt.js | 39 +
.../assets/js/libs/ace/theme/crimson_editor.css | 143 +
.../assets/js/libs/ace/theme/crimson_editor.js | 39 +
src/fauxton/assets/js/libs/ace/theme/dawn.css | 125 +
src/fauxton/assets/js/libs/ace/theme/dawn.js | 39 +
.../assets/js/libs/ace/theme/dreamweaver.css | 171 +
.../assets/js/libs/ace/theme/dreamweaver.js | 38 +
.../assets/js/libs/ace/theme/eclipse.css | 108 +
src/fauxton/assets/js/libs/ace/theme/eclipse.js | 41 +
src/fauxton/assets/js/libs/ace/theme/github.css | 119 +
src/fauxton/assets/js/libs/ace/theme/github.js | 39 +
.../assets/js/libs/ace/theme/idle_fingers.css | 113 +
.../assets/js/libs/ace/theme/idle_fingers.js | 39 +
.../assets/js/libs/ace/theme/kr_theme.css | 123 +
.../assets/js/libs/ace/theme/kr_theme.js | 39 +
.../assets/js/libs/ace/theme/merbivore.css | 110 +
.../assets/js/libs/ace/theme/merbivore.js | 39 +
.../assets/js/libs/ace/theme/merbivore_soft.css | 111 +
.../assets/js/libs/ace/theme/merbivore_soft.js | 39 +
.../js/libs/ace/theme/mono_industrial.css | 126 +
.../assets/js/libs/ace/theme/mono_industrial.js | 39 +
.../assets/js/libs/ace/theme/monokai.css | 122 +
src/fauxton/assets/js/libs/ace/theme/monokai.js | 39 +
.../assets/js/libs/ace/theme/pastel_on_dark.css | 129 +
.../assets/js/libs/ace/theme/pastel_on_dark.js | 39 +
.../assets/js/libs/ace/theme/solarized_dark.css | 104 +
.../assets/js/libs/ace/theme/solarized_dark.js | 39 +
.../js/libs/ace/theme/solarized_light.css | 106 +
.../assets/js/libs/ace/theme/solarized_light.js | 39 +
.../assets/js/libs/ace/theme/terminal.css | 132 +
.../assets/js/libs/ace/theme/terminal.js | 39 +
.../assets/js/libs/ace/theme/textmate.css | 154 +
.../assets/js/libs/ace/theme/textmate.js | 40 +
.../assets/js/libs/ace/theme/tomorrow.css | 124 +
.../assets/js/libs/ace/theme/tomorrow.js | 39 +
.../assets/js/libs/ace/theme/tomorrow_night.css | 124 +
.../assets/js/libs/ace/theme/tomorrow_night.js | 39 +
.../js/libs/ace/theme/tomorrow_night_blue.css | 124 +
.../js/libs/ace/theme/tomorrow_night_blue.js | 39 +
.../js/libs/ace/theme/tomorrow_night_bright.css | 128 +
.../js/libs/ace/theme/tomorrow_night_bright.js | 39 +
.../libs/ace/theme/tomorrow_night_eighties.css | 127 +
.../libs/ace/theme/tomorrow_night_eighties.js | 39 +
.../assets/js/libs/ace/theme/twilight.css | 126 +
.../assets/js/libs/ace/theme/twilight.js | 39 +
.../assets/js/libs/ace/theme/vibrant_ink.css | 110 +
.../assets/js/libs/ace/theme/vibrant_ink.js | 39 +
src/fauxton/assets/js/libs/ace/theme/xcode.css | 103 +
src/fauxton/assets/js/libs/ace/theme/xcode.js | 39 +
.../assets/js/libs/ace/token_iterator.js | 150 +
.../assets/js/libs/ace/token_iterator_test.js | 212 +
src/fauxton/assets/js/libs/ace/tokenizer.js | 333 +
src/fauxton/assets/js/libs/ace/tokenizer_dev.js | 183 +
.../assets/js/libs/ace/tokenizer_test.js | 69 +
src/fauxton/assets/js/libs/ace/undomanager.js | 167 +
src/fauxton/assets/js/libs/ace/unicode.js | 107 +
.../assets/js/libs/ace/virtual_renderer.js | 1678 +
.../assets/js/libs/ace/virtual_renderer_test.js | 86 +
src/fauxton/assets/js/libs/ace/worker/mirror.js | 43 +
src/fauxton/assets/js/libs/ace/worker/worker.js | 178 +
.../assets/js/libs/ace/worker/worker_client.js | 226 +
.../assets/js/libs/ace/worker/worker_test.js | 125 +
src/fauxton/assets/less/fauxton.less | 14 +
809 files changed, 186579 insertions(+), 34 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9abd128c/src/fauxton/app/config.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/config.js b/src/fauxton/app/config.js
index 4edeba0..631308f 100644
--- a/src/fauxton/app/config.js
+++ b/src/fauxton/app/config.js
@@ -31,7 +31,8 @@ require.config({
jshint: "../assets/js/libs/jshint",
spin: "../assets/js/libs/spin.min",
d3: "../assets/js/libs/d3",
- "nv.d3": "../assets/js/libs/nv.d3"
+ "nv.d3": "../assets/js/libs/nv.d3",
+ "ace":"../assets/js/libs/ace"
},
baseUrl: '/',
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9abd128c/src/fauxton/app/modules/documents/views.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/modules/documents/views.js b/src/fauxton/app/modules/documents/views.js
index f822544..08825f8 100644
--- a/src/fauxton/app/modules/documents/views.js
+++ b/src/fauxton/app/modules/documents/views.js
@@ -708,6 +708,7 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
disableLoader: true,
initialize: function (options) {
this.database = options.database;
+ _.bindAll(this);
},
goback: function(){
window.history.back();
@@ -849,6 +850,7 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
}
json = JSON.parse(this.editor.getValue());
+
this.model.set(json, {validate: true});
if (this.model.validationError) {
return false;
@@ -858,10 +860,11 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
},
hasValidCode: function() {
- return JSHINT(this.editor.getValue()) !== false;
+ var errors = this.editor.getAnnotations();
+ return errors.length === 0;
},
- runJSHint: function() {
+ /*runJSHint: function() {
var json = this.editor.getValue();
var output = JSHint(json);
@@ -884,7 +887,7 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
}, 0);
}, this);
}
- },
+ },*/
serialize: function() {
return {
@@ -909,11 +912,24 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
},
afterRender: function() {
+ var saveDoc = this.saveDoc;
+
+ this.editor = new Components.Editor({
+ editorId: "editor-container",
+ commands: [{
+ name: 'save',
+ bindKey: {win: 'Ctrl-S', mac: 'Ctrl-S'},
+ exec: function(editor) {
+ saveDoc();
+ },
+ readOnly: true // false if this command should not apply in readOnly mode
+ }]
+ });
+ this.editor.render();
this.model.on("sync", this.updateValues, this);
- var that = this;
- if ($('.CodeMirror').length > 0){
- $('.CodeMirror').remove();
- }
+
+ /*var that = this;
+
this.editor = Codemirror.fromTextArea(this.$el.find("textarea.doc-code").get()[0], {
mode: "application/json",
json: false,
@@ -932,7 +948,7 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
"Ctrl-/": "undo"
}
});
- setTimeout(function(){that.editor.setSize(null,$('#dashboard').outerHeight()-295);},200);
+ */
}
});
@@ -1334,7 +1350,8 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
}
},
- updateView: function(event, paramInfo) {
+ // not sure where this is used
+ /*updateView: function(event, paramInfo) {
event.preventDefault();
if (this.newView) { return alert('Please save this new view before querying it.'); }
@@ -1368,7 +1385,7 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
FauxtonAPI.navigate(fragment, {trigger: false});
FauxtonAPI.triggerRouteEvent('updateAllDocs', {ddoc: this.ddocID, view: this.viewName});
- },
+ },*/
previewView: function(event, paramsInfo) {
var that = this,
@@ -1433,20 +1450,20 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
hasValidCode: function() {
return _.every(["mapEditor", "reduceEditor"], function(editorName) {
var editor = this[editorName];
- if (editorName == "reduceEditor" && ! this.isCustomReduceEnabled()) {
+ if (editorName === "reduceEditor" && ! this.isCustomReduceEnabled()) {
return true;
- } else if (JSHINT(editor.getValue()) !== false) {
- return true;
- } else {
- // By default CouchDB view functions don't pass lint
- return _.every(JSHINT.errors, function(error) {
- return FauxtonAPI.isIgnorableError(error.raw);
- });
- }
+ }
+
+ var errors = editor.getAnnotations();
+ // By default CouchDB view functions don't pass lint
+ return _.every(errors, function(error) {
+ console.log('err', error);
+ return FauxtonAPI.isIgnorableError(error.raw);
+ },this);
}, this);
},
- runJSHint: function(editorName) {
+ /*runJSHint: function(editorName) {
var editor = this[editorName];
var json = editor.getValue();
var output = JSHint(json);
@@ -1472,7 +1489,7 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
}, 0);
}, this);
}
- },
+ },*/
toggleIndexNav: function (event) {
var $index = this.$('#index'),
$targetId = this.$(event.target).attr('id');
@@ -1543,7 +1560,7 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
mapFun.val(this.langTemplates[this.defaultLang].map);
reduceFun.val(this.langTemplates[this.defaultLang].reduce);
} else {
- setTimeout(function(){this.$('#index').hide();}, 300);
+ this.$('#index').hide();
this.$('#index-nav').parent().removeClass('active');
}
@@ -1552,7 +1569,24 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
// When in grunt dev mode we load templates asynchronously
// and this can cause a double render which then gives us two
// mapeditors
- if (this.mapViewSet) { return;}
+
+ this.mapEditor = new Components.Editor({
+ editorId: "map-function",
+ mode: "javascript"
+ });
+ this.mapEditor.render();
+ // We can make this better
+ if (this.hasCustomReduce()) {
+ this.reduceEditor = new Components.Editor({
+ editorId: "reduce-function",
+ mode: "javascript"
+ });
+ this.reduceEditor.render();
+ } else {
+ $(".control-group.reduce-function").hide();
+ }
+
+ /*if (this.mapViewSet) { return;}
this.mapViewSet = true;
this.mapEditor = Codemirror.fromTextArea(mapFun.get()[0], {
@@ -1594,7 +1628,7 @@ function(app, FauxtonAPI, Components, Documents, pouchdb, Codemirror, JSHint, re
// So render it first, set the editor, then hide.
if ( ! this.hasCustomReduce()) {
$(".control-group.reduce-function").hide();
- }
+ }*/
if (this.params) {
this.advancedOptions.updateFromParams(this.params);
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9abd128c/src/fauxton/app/modules/fauxton/components.js
----------------------------------------------------------------------
diff --git a/src/fauxton/app/modules/fauxton/components.js b/src/fauxton/app/modules/fauxton/components.js
index 30a57d8..afed6c7 100644
--- a/src/fauxton/app/modules/fauxton/components.js
+++ b/src/fauxton/app/modules/fauxton/components.js
@@ -11,12 +11,13 @@
// the License.
define([
- "app",
- // Libs
- "api"
+ "app",
+ // Libs
+ "api",
+ "ace/ace"
],
-function(app, FauxtonAPI) {
+function(app, FauxtonAPI, ace) {
var Components = app.module();
Components.Pagination = FauxtonAPI.View.extend({
@@ -175,6 +176,65 @@ function(app, FauxtonAPI) {
}
});
+ Components.Editor = FauxtonAPI.View.extend({
+ initialize: function (options) {
+ this.editorId = options.editorId;
+ this.mode = options.mode || "json";
+ this.commands = options.commands;
+ },
+
+ afterRender: function () {
+ this.editor = ace.edit(this.editorId);
+ this.editor.setTheme("ace/theme/crimson_editor");
+ this.editor.getSession().setMode("ace/mode/" + this.mode);
+ this.editor.setShowPrintMargin(false);
+ this.editor.gotoLine(2);
+ this.addCommands();
+ this.removeIncorrectAnnotations();
+ },
+
+ addCommands: function () {
+ _.each(this.commands, function (command) {
+ var out = this.editor.commands.addCommand(command);
+ console.log(out, 'ou');
+ }, this);
+ },
+
+ removeIncorrectAnnotations: function () {
+ var editor = this.editor;
+
+ this.editor.getSession().on("changeAnnotation", function(){
+ var annotations = editor.getSession().getAnnotations();
+
+ var newAnnotations = _.reduce(annotations, function (annotations, error) {
+ console.log(error);
+ if (!FauxtonAPI.isIgnorableError(error.raw)) {
+ annotations.push(error);
+ }
+ return annotations;
+ }, []);
+
+ if (annotations.length !== newAnnotations.length) {
+ editor.getSession().setAnnotations(newAnnotations);
+ }
+ });
+ },
+
+ setValue: function (data, lineNumber) {
+ lineNumber = lineNumber ? lineNumber : -1;
+ this.editor.setValue(data, lineNumber);
+ },
+
+ getValue: function () {
+ return this.editor.getValue();
+ },
+
+ getAnnotations: function () {
+ return this.editor.getSession().getAnnotations();
+ }
+
+ });
+
return Components;
});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9abd128c/src/fauxton/app/templates/documents/doc.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/templates/documents/doc.html b/src/fauxton/app/templates/documents/doc.html
index 8c8fc7b..f83a1a9 100644
--- a/src/fauxton/app/templates/documents/doc.html
+++ b/src/fauxton/app/templates/documents/doc.html
@@ -41,7 +41,7 @@ the License.
<div id="duplicate-modal"> </div>
</div>
- <textarea class="doc-code"><%- JSON.stringify(doc.attributes, null, " ") %></textarea>
+ <div id="editor-container" class="doc-code"><%- JSON.stringify(doc.attributes, null, " ") %></div>
<br />
<p>
<button class="save-doc button green btn-success btn-large save fonticon-circle-check" type="button">Save</button>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9abd128c/src/fauxton/app/templates/documents/view_editor.html
----------------------------------------------------------------------
diff --git a/src/fauxton/app/templates/documents/view_editor.html b/src/fauxton/app/templates/documents/view_editor.html
index 76265e0..8fcd07a 100644
--- a/src/fauxton/app/templates/documents/view_editor.html
+++ b/src/fauxton/app/templates/documents/view_editor.html
@@ -36,9 +36,9 @@ the License.
<div class="control-group">
<label for="map-function">Map function <a href="<%=getDocUrl('map_functions')%>" target="_blank"><i class="icon-question-sign"></i></a></label>
<% if (newView) { %>
- <textarea class="js-editor" id="map-function"><%= langTemplates.map %></textarea>
+ <div class="js-editor" id="map-function"><%= langTemplates.map %></div>
<% } else { %>
- <textarea class="js-editor" id="map-function"><%= ddoc.get('views')[viewName].map %></textarea>
+ <div class="js-editor" id="map-function"><%= ddoc.get('views')[viewName].map %></div>
<% } %>
</div>
@@ -60,9 +60,9 @@ the License.
<div class="control-group reduce-function">
<label for="reduce-function">Custom Reduce</label>
<% if (newView) { %>
- <textarea class="js-editor" id="reduce-function"><%= langTemplates.reduce %></textarea>
+ <div class="js-editor" id="reduce-function"><%= langTemplates.reduce %></div>
<% } else { %>
- <textarea class="js-editor" id="reduce-function"><%= ddoc.get('views')[viewName].reduce %></textarea>
+ <div class="js-editor" id="reduce-function"><%= ddoc.get('views')[viewName].reduce %></div>
<% } %>
</div>
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9abd128c/src/fauxton/assets/js/libs/ace/ace.js
----------------------------------------------------------------------
diff --git a/src/fauxton/assets/js/libs/ace/ace.js b/src/fauxton/assets/js/libs/ace/ace.js
new file mode 100644
index 0000000..773f227
--- /dev/null
+++ b/src/fauxton/assets/js/libs/ace/ace.js
@@ -0,0 +1,117 @@
+/* ***** BEGIN LICENSE BLOCK *****
+ * Distributed under the BSD license:
+ *
+ * Copyright (c) 2010, Ajax.org B.V.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of Ajax.org B.V. nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+/**
+ * The main class required to set up an Ace instance in the browser.
+ *
+ * @class Ace
+ **/
+
+define(function(require, exports, module) {
+"use strict";
+
+require("./lib/fixoldbrowsers");
+
+var dom = require("./lib/dom");
+var event = require("./lib/event");
+
+var Editor = require("./editor").Editor;
+var EditSession = require("./edit_session").EditSession;
+var UndoManager = require("./undomanager").UndoManager;
+var Renderer = require("./virtual_renderer").VirtualRenderer;
+var MultiSelect = require("./multi_select").MultiSelect;
+
+// The following require()s are for inclusion in the built ace file
+require("./worker/worker_client");
+require("./keyboard/hash_handler");
+require("./placeholder");
+require("./mode/folding/fold_mode");
+require("./theme/textmate");
+
+exports.config = require("./config");
+
+/**
+ * Provides access to require in packed noconflict mode
+ * @param {String} moduleName
+ * @returns {Object}
+ *
+ **/
+exports.require = require;
+
+/**
+ * Embeds the Ace editor into the DOM, at the element provided by `el`.
+ * @param {String | DOMElement} el Either the id of an element, or the element itself
+ *
+ **/
+exports.edit = function(el) {
+ if (typeof(el) == "string") {
+ var _id = el;
+ var el = document.getElementById(_id);
+ if (!el)
+ throw new Error("ace.edit can't find div #" + _id);
+ }
+
+ if (el.env && el.env.editor instanceof Editor)
+ return el.env.editor;
+
+ var doc = exports.createEditSession(dom.getInnerText(el));
+ el.innerHTML = '';
+
+ var editor = new Editor(new Renderer(el));
+ new MultiSelect(editor);
+ editor.setSession(doc);
+
+ var env = {
+ document: doc,
+ editor: editor,
+ onResize: editor.resize.bind(editor, null)
+ };
+ event.addListener(window, "resize", env.onResize);
+ editor.on("destroy", function() {
+ event.removeListener(window, "resize", env.onResize);
+ });
+ el.env = editor.env = env;
+ return editor;
+};
+
+/**
+ * Creates a new [[EditSession]], and returns the associated [[Document]].
+ * @param {Document | String} text {:textParam}
+ * @param {TextMode} mode {:modeParam}
+ *
+ **/
+exports.createEditSession = function(text, mode) {
+ var doc = new EditSession(text, mode);
+ doc.setUndoManager(new UndoManager());
+ return doc;
+}
+exports.EditSession = EditSession;
+exports.UndoManager = UndoManager;
+});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9abd128c/src/fauxton/assets/js/libs/ace/anchor.js
----------------------------------------------------------------------
diff --git a/src/fauxton/assets/js/libs/ace/anchor.js b/src/fauxton/assets/js/libs/ace/anchor.js
new file mode 100644
index 0000000..3a62e63
--- /dev/null
+++ b/src/fauxton/assets/js/libs/ace/anchor.js
@@ -0,0 +1,242 @@
+/* ***** BEGIN LICENSE BLOCK *****
+ * Distributed under the BSD license:
+ *
+ * Copyright (c) 2010, Ajax.org B.V.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of Ajax.org B.V. nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+define(function(require, exports, module) {
+"use strict";
+
+var oop = require("./lib/oop");
+var EventEmitter = require("./lib/event_emitter").EventEmitter;
+
+/**
+ *
+ * Defines the floating pointer in the document. Whenever text is inserted or deleted before the cursor, the position of the cursor is updated.
+ *
+ * @class Anchor
+ **/
+
+/**
+ * Creates a new `Anchor` and associates it with a document.
+ *
+ * @param {Document} doc The document to associate with the anchor
+ * @param {Number} row The starting row position
+ * @param {Number} column The starting column position
+ *
+ * @constructor
+ **/
+
+var Anchor = exports.Anchor = function(doc, row, column) {
+ this.$onChange = this.onChange.bind(this);
+ this.attach(doc);
+
+ if (typeof column == "undefined")
+ this.setPosition(row.row, row.column);
+ else
+ this.setPosition(row, column);
+};
+
+(function() {
+
+ oop.implement(this, EventEmitter);
+
+ /**
+ * Returns an object identifying the `row` and `column` position of the current anchor.
+ * @returns {Object}
+ **/
+ this.getPosition = function() {
+ return this.$clipPositionToDocument(this.row, this.column);
+ };
+
+ /**
+ *
+ * Returns the current document.
+ * @returns {Document}
+ **/
+ this.getDocument = function() {
+ return this.document;
+ };
+
+ /**
+ * experimental: allows anchor to stick to the next on the left
+ */
+ this.$insertRight = false;
+ /**
+ * Fires whenever the anchor position changes.
+ *
+ * Both of these objects have a `row` and `column` property corresponding to the position.
+ *
+ * Events that can trigger this function include [[Anchor.setPosition `setPosition()`]].
+ *
+ * @event change
+ * @param {Object} e An object containing information about the anchor position. It has two properties:
+ * - `old`: An object describing the old Anchor position
+ * - `value`: An object describing the new Anchor position
+ *
+ **/
+ this.onChange = function(e) {
+ var delta = e.data;
+ var range = delta.range;
+
+ if (range.start.row == range.end.row && range.start.row != this.row)
+ return;
+
+ if (range.start.row > this.row)
+ return;
+
+ if (range.start.row == this.row && range.start.column > this.column)
+ return;
+
+ var row = this.row;
+ var column = this.column;
+ var start = range.start;
+ var end = range.end;
+
+ if (delta.action === "insertText") {
+ if (start.row === row && start.column <= column) {
+ if (start.column === column && this.$insertRight) {
+ // do nothing
+ } else if (start.row === end.row) {
+ column += end.column - start.column;
+ } else {
+ column -= start.column;
+ row += end.row - start.row;
+ }
+ } else if (start.row !== end.row && start.row < row) {
+ row += end.row - start.row;
+ }
+ } else if (delta.action === "insertLines") {
+ if (start.row <= row) {
+ row += end.row - start.row;
+ }
+ } else if (delta.action === "removeText") {
+ if (start.row === row && start.column < column) {
+ if (end.column >= column)
+ column = start.column;
+ else
+ column = Math.max(0, column - (end.column - start.column));
+
+ } else if (start.row !== end.row && start.row < row) {
+ if (end.row === row)
+ column = Math.max(0, column - end.column) + start.column;
+ row -= (end.row - start.row);
+ } else if (end.row === row) {
+ row -= end.row - start.row;
+ column = Math.max(0, column - end.column) + start.column;
+ }
+ } else if (delta.action == "removeLines") {
+ if (start.row <= row) {
+ if (end.row <= row)
+ row -= end.row - start.row;
+ else {
+ row = start.row;
+ column = 0;
+ }
+ }
+ }
+
+ this.setPosition(row, column, true);
+ };
+
+ /**
+ * Sets the anchor position to the specified row and column. If `noClip` is `true`, the position is not clipped.
+ * @param {Number} row The row index to move the anchor to
+ * @param {Number} column The column index to move the anchor to
+ * @param {Boolean} noClip Identifies if you want the position to be clipped
+ *
+ **/
+ this.setPosition = function(row, column, noClip) {
+ var pos;
+ if (noClip) {
+ pos = {
+ row: row,
+ column: column
+ };
+ } else {
+ pos = this.$clipPositionToDocument(row, column);
+ }
+
+ if (this.row == pos.row && this.column == pos.column)
+ return;
+
+ var old = {
+ row: this.row,
+ column: this.column
+ };
+
+ this.row = pos.row;
+ this.column = pos.column;
+ this._emit("change", {
+ old: old,
+ value: pos
+ });
+ };
+
+ /**
+ * When called, the `'change'` event listener is removed.
+ *
+ **/
+ this.detach = function() {
+ this.document.removeEventListener("change", this.$onChange);
+ };
+ this.attach = function(doc) {
+ this.document = doc || this.document;
+ this.document.on("change", this.$onChange);
+ };
+
+ /**
+ * Clips the anchor position to the specified row and column.
+ * @param {Number} row The row index to clip the anchor to
+ * @param {Number} column The column index to clip the anchor to
+ *
+ **/
+ this.$clipPositionToDocument = function(row, column) {
+ var pos = {};
+
+ if (row >= this.document.getLength()) {
+ pos.row = Math.max(0, this.document.getLength() - 1);
+ pos.column = this.document.getLine(pos.row).length;
+ }
+ else if (row < 0) {
+ pos.row = 0;
+ pos.column = 0;
+ }
+ else {
+ pos.row = row;
+ pos.column = Math.min(this.document.getLine(pos.row).length, Math.max(0, column));
+ }
+
+ if (column < 0)
+ pos.column = 0;
+
+ return pos;
+ };
+
+}).call(Anchor.prototype);
+
+});
http://git-wip-us.apache.org/repos/asf/couchdb/blob/9abd128c/src/fauxton/assets/js/libs/ace/anchor_test.js
----------------------------------------------------------------------
diff --git a/src/fauxton/assets/js/libs/ace/anchor_test.js b/src/fauxton/assets/js/libs/ace/anchor_test.js
new file mode 100644
index 0000000..2d7fcb6
--- /dev/null
+++ b/src/fauxton/assets/js/libs/ace/anchor_test.js
@@ -0,0 +1,188 @@
+/* ***** BEGIN LICENSE BLOCK *****
+ * Distributed under the BSD license:
+ *
+ * Copyright (c) 2010, Ajax.org B.V.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * * Neither the name of Ajax.org B.V. nor the
+ * names of its contributors may be used to endorse or promote products
+ * derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY
+ * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * ***** END LICENSE BLOCK ***** */
+
+if (typeof process !== "undefined") {
+ require("amd-loader");
+}
+
+define(function(require, exports, module) {
+"use strict";
+
+var Document = require("./document").Document;
+var Anchor = require("./anchor").Anchor;
+var Range = require("./range").Range;
+var assert = require("./test/assertions");
+
+module.exports = {
+
+ "test create anchor" : function() {
+ var doc = new Document("juhu");
+ var anchor = new Anchor(doc, 0, 0);
+
+ assert.position(anchor.getPosition(), 0, 0);
+ assert.equal(anchor.getDocument(), doc);
+ },
+
+ "test insert text in same row before cursor should move anchor column": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 1, 4);
+
+ doc.insert({row: 1, column: 1}, "123");
+ assert.position(anchor.getPosition(), 1, 7);
+ },
+
+ "test insert lines before cursor should move anchor row": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 1, 4);
+
+ doc.insertLines(1, ["123", "456"]);
+ assert.position(anchor.getPosition(), 3, 4);
+ },
+
+ "test insert new line before cursor should move anchor column": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 1, 4);
+
+ doc.insertNewLine({row: 0, column: 0});
+ assert.position(anchor.getPosition(), 2, 4);
+ },
+
+ "test insert new line in anchor line before anchor should move anchor column and row": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 1, 4);
+
+ doc.insertNewLine({row: 1, column: 2});
+ assert.position(anchor.getPosition(), 2, 2);
+ },
+
+ "test delete text in anchor line before anchor should move anchor column": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 1, 4);
+
+ doc.remove(new Range(1, 1, 1, 3));
+ assert.position(anchor.getPosition(), 1, 2);
+ },
+
+ "test remove range which contains the anchor should move the anchor to the start of the range": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 0, 3);
+
+ doc.remove(new Range(0, 1, 1, 3));
+ assert.position(anchor.getPosition(), 0, 1);
+ },
+
+ "test delete character before the anchor should have no effect": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 1, 4);
+
+ doc.remove(new Range(1, 4, 1, 5));
+ assert.position(anchor.getPosition(), 1, 4);
+ },
+
+ "test delete lines in anchor line before anchor should move anchor row": function() {
+ var doc = new Document("juhu\n1\n2\nkinners");
+ var anchor = new Anchor(doc, 3, 4);
+
+ doc.removeLines(1, 2);
+ assert.position(anchor.getPosition(), 1, 4);
+ },
+
+ "test remove new line before the cursor": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 1, 4);
+
+ doc.removeNewLine(0);
+ assert.position(anchor.getPosition(), 0, 8);
+ },
+
+ "test delete range which contains the anchor should move anchor to the end of the range": function() {
+ var doc = new Document("juhu\nkinners");
+ var anchor = new Anchor(doc, 1, 4);
+
+ doc.remove(new Range(0, 2, 1, 2));
+ assert.position(anchor.getPosition(), 0, 4);
+ },
+
+ "test delete line which contains the anchor should move anchor to the end of the range": function() {
+ var doc = new Document("juhu\nkinners\n123");
+ var anchor = new Anchor(doc, 1, 5);
+
+ doc.removeLines(1, 1);
+ assert.position(anchor.getPosition(), 1, 0);
+ },
+
+ "test remove after the anchor should have no effect": function() {
+ var doc = new Document("juhu\nkinners\n123");
+ var anchor = new Anchor(doc, 1, 2);
+
+ doc.remove(new Range(1, 4, 2, 2));
+ assert.position(anchor.getPosition(), 1, 2);
+ },
+
+ "test anchor changes triggered by document changes should emit change event": function(next) {
+ var doc = new Document("juhu\nkinners\n123");
+ var anchor = new Anchor(doc, 1, 5);
+
+ anchor.on("change", function(e) {
+ assert.position(anchor.getPosition(), 0, 0);
+ next();
+ });
+
+ doc.remove(new Range(0, 0, 2, 1));
+ },
+
+ "test only fire change event if position changes": function() {
+ var doc = new Document("juhu\nkinners\n123");
+ var anchor = new Anchor(doc, 1, 5);
+
+ anchor.on("change", function(e) {
+ assert.fail();
+ });
+
+ doc.remove(new Range(2, 0, 2, 1));
+ },
+
+ "test insert/remove lines at the end of the document": function() {
+ var doc = new Document("juhu\nkinners\n123");
+ var anchor = new Anchor(doc, 2, 4);
+
+ doc.removeLines(0, 3);
+ assert.position(anchor.getPosition(), 0, 0);
+ doc.insertLines(0, ["a", "b", "c"]);
+ assert.position(anchor.getPosition(), 3, 0);
+ assert.equal(doc.getValue(), "a\nb\nc\n");
+ }
+};
+
+});
+
+if (typeof module !== "undefined" && module === require.main) {
+ require("asyncjs").test.testcase(module.exports).exec()
+}