From 87fa38182edc61e4a2322636dfef39c4f8cc7a93 Mon Sep 17 00:00:00 2001
From: Berkeley Martinez
Date: Tue, 10 Nov 2015 18:27:58 -0800
Subject: [PATCH 01/28] bundle vendor files
---
bower.json | 6 +-
client/commonFramework.js | 8 +-
gulpfile.js | 74 +-
package.json | 7 +
public/js/lib/bootstrap.min.js | 6 -
public/js/lib/chai/chai-jquery.js | 231 -
public/js/lib/chai/chai.js | 4800 --
.../js/lib/codemirror-accessible/.gitignore | 1 -
public/js/lib/codemirror-accessible/README.md | 3 -
.../lib/codemirror-accessible/accessible.js | 80 -
.../codemirror-accessible.js | 5828 ---
.../codemirror-accessible2.js | 5848 ---
.../codemirror-original.js | 5799 ---
.../lib/codemirror-accessible/codemirror.css | 258 -
.../js/lib/codemirror-accessible/index.html | 9941 ----
.../lib/codemirror-accessible/javascript.js | 482 -
.../js/lib/codemirror-accessible/stress.html | 749 -
public/js/lib/codemirror/.gitattributes | 8 -
public/js/lib/codemirror/.gitignore | 8 -
public/js/lib/codemirror/.travis.yml | 3 -
public/js/lib/codemirror/AUTHORS | 423 -
public/js/lib/codemirror/CONTRIBUTING.md | 76 -
public/js/lib/codemirror/LICENSE | 19 -
public/js/lib/codemirror/README.md | 11 -
.../lib/codemirror/addon/comment/comment.js | 183 -
.../addon/comment/continuecomment.js | 85 -
.../js/lib/codemirror/addon/dialog/dialog.css | 32 -
.../js/lib/codemirror/addon/dialog/dialog.js | 155 -
.../codemirror/addon/display/fullscreen.css | 6 -
.../codemirror/addon/display/fullscreen.js | 41 -
.../js/lib/codemirror/addon/display/panel.js | 94 -
.../codemirror/addon/display/placeholder.js | 58 -
.../js/lib/codemirror/addon/display/rulers.js | 64 -
.../codemirror/addon/edit/closebrackets.js | 159 -
.../js/lib/codemirror/addon/edit/closetag.js | 159 -
.../lib/codemirror/addon/edit/continuelist.js | 51 -
.../codemirror/addon/edit/matchbrackets.js | 120 -
.../js/lib/codemirror/addon/edit/matchtags.js | 66 -
.../codemirror/addon/edit/trailingspace.js | 27 -
public/js/lib/codemirror/addon/emmet/emmet.js | 43080 ----------------
.../lib/codemirror/addon/fold/brace-fold.js | 105 -
.../lib/codemirror/addon/fold/comment-fold.js | 57 -
.../js/lib/codemirror/addon/fold/foldcode.js | 145 -
.../lib/codemirror/addon/fold/foldgutter.css | 20 -
.../lib/codemirror/addon/fold/foldgutter.js | 134 -
.../lib/codemirror/addon/fold/indent-fold.js | 44 -
.../codemirror/addon/fold/markdown-fold.js | 49 -
.../js/lib/codemirror/addon/fold/xml-fold.js | 182 -
.../lib/codemirror/addon/hint/anyword-hint.js | 41 -
.../js/lib/codemirror/addon/hint/css-hint.js | 56 -
.../js/lib/codemirror/addon/hint/html-hint.js | 348 -
.../codemirror/addon/hint/javascript-hint.js | 146 -
.../lib/codemirror/addon/hint/show-hint.css | 38 -
.../js/lib/codemirror/addon/hint/show-hint.js | 389 -
.../js/lib/codemirror/addon/hint/sql-hint.js | 197 -
.../js/lib/codemirror/addon/hint/xml-hint.js | 110 -
.../addon/lint/coffeescript-lint.js | 41 -
.../js/lib/codemirror/addon/lint/css-lint.js | 35 -
.../codemirror/addon/lint/javascript-lint.js | 136 -
.../js/lib/codemirror/addon/lint/json-lint.js | 31 -
public/js/lib/codemirror/addon/lint/lint.css | 73 -
public/js/lib/codemirror/addon/lint/lint.js | 204 -
.../js/lib/codemirror/addon/lint/yaml-lint.js | 28 -
.../js/lib/codemirror/addon/merge/merge.css | 112 -
public/js/lib/codemirror/addon/merge/merge.js | 643 -
.../js/lib/codemirror/addon/mode/loadmode.js | 64 -
.../js/lib/codemirror/addon/mode/multiplex.js | 118 -
.../codemirror/addon/mode/multiplex_test.js | 33 -
.../js/lib/codemirror/addon/mode/overlay.js | 85 -
public/js/lib/codemirror/addon/mode/simple.js | 213 -
.../lib/codemirror/addon/runmode/colorize.js | 40 -
.../addon/runmode/runmode-standalone.js | 157 -
.../lib/codemirror/addon/runmode/runmode.js | 72 -
.../codemirror/addon/runmode/runmode.node.js | 120 -
.../addon/scroll/annotatescrollbar.js | 76 -
.../codemirror/addon/scroll/scrollpastend.js | 46 -
.../addon/scroll/simplescrollbars.css | 66 -
.../addon/scroll/simplescrollbars.js | 139 -
.../addon/search/match-highlighter.js | 128 -
.../addon/search/matchesonscrollbar.css | 8 -
.../addon/search/matchesonscrollbar.js | 90 -
.../js/lib/codemirror/addon/search/search.js | 164 -
.../codemirror/addon/search/searchcursor.js | 189 -
.../codemirror/addon/selection/active-line.js | 71 -
.../addon/selection/mark-selection.js | 118 -
public/js/lib/codemirror/addon/tern/tern.css | 86 -
public/js/lib/codemirror/addon/tern/tern.js | 670 -
public/js/lib/codemirror/addon/tern/worker.js | 44 -
.../js/lib/codemirror/addon/wrap/hardwrap.js | 139 -
public/js/lib/codemirror/bin/authors.sh | 6 -
public/js/lib/codemirror/bin/compress | 92 -
public/js/lib/codemirror/bin/lint | 16 -
public/js/lib/codemirror/bin/release | 46 -
public/js/lib/codemirror/bin/source-highlight | 51 -
public/js/lib/codemirror/bower.json | 16 -
public/js/lib/codemirror/index.html | 200 -
public/js/lib/codemirror/keymap/emacs.js | 411 -
public/js/lib/codemirror/keymap/sublime.js | 540 -
public/js/lib/codemirror/keymap/vim.js | 4901 --
public/js/lib/codemirror/lib/codemirror.css | 311 -
public/js/lib/codemirror/lib/codemirror.js | 8029 ---
public/js/lib/codemirror/mode/css/css.js | 717 -
public/js/lib/codemirror/mode/css/index.html | 75 -
public/js/lib/codemirror/mode/css/less.html | 152 -
.../js/lib/codemirror/mode/css/less_test.js | 51 -
public/js/lib/codemirror/mode/css/scss.html | 157 -
.../js/lib/codemirror/mode/css/scss_test.js | 110 -
public/js/lib/codemirror/mode/css/test.js | 135 -
.../mode/htmlembedded/htmlembedded.js | 86 -
.../codemirror/mode/htmlembedded/index.html | 58 -
.../codemirror/mode/htmlmixed/htmlmixed.js | 121 -
.../lib/codemirror/mode/htmlmixed/index.html | 85 -
public/js/lib/codemirror/mode/jade/index.html | 70 -
public/js/lib/codemirror/mode/jade/jade.js | 590 -
.../lib/codemirror/mode/javascript/index.html | 114 -
.../codemirror/mode/javascript/javascript.js | 686 -
.../codemirror/mode/javascript/json-ld.html | 72 -
.../js/lib/codemirror/mode/javascript/test.js | 200 -
.../mode/javascript/typescript.html | 61 -
.../lib/codemirror/mode/markdown/index.html | 359 -
.../lib/codemirror/mode/markdown/markdown.js | 765 -
.../js/lib/codemirror/mode/markdown/test.js | 754 -
public/js/lib/codemirror/mode/meta.js | 165 -
public/js/lib/codemirror/mode/xml/index.html | 57 -
public/js/lib/codemirror/mode/xml/test.js | 51 -
public/js/lib/codemirror/mode/xml/xml.js | 384 -
public/js/lib/codemirror/mode/yaml/index.html | 80 -
public/js/lib/codemirror/mode/yaml/yaml.js | 117 -
public/js/lib/codemirror/package.json | 20 -
public/js/lib/codemirror/test/comment_test.js | 100 -
public/js/lib/codemirror/test/doc_test.js | 371 -
public/js/lib/codemirror/test/driver.js | 138 -
public/js/lib/codemirror/test/emacs_test.js | 141 -
public/js/lib/codemirror/test/index.html | 236 -
public/js/lib/codemirror/test/lint/acorn.js | 1782 -
public/js/lib/codemirror/test/lint/lint.js | 166 -
public/js/lib/codemirror/test/lint/walk.js | 313 -
public/js/lib/codemirror/test/mode_test.css | 23 -
public/js/lib/codemirror/test/mode_test.js | 192 -
public/js/lib/codemirror/test/multi_test.js | 285 -
.../js/lib/codemirror/test/phantom_driver.js | 31 -
public/js/lib/codemirror/test/run.js | 38 -
public/js/lib/codemirror/test/scroll_test.js | 105 -
public/js/lib/codemirror/test/search_test.js | 62 -
public/js/lib/codemirror/test/sublime_test.js | 303 -
public/js/lib/codemirror/test/test.js | 2101 -
public/js/lib/codemirror/test/vim_test.js | 3768 --
public/js/lib/codemirror/theme/3024-day.css | 38 -
public/js/lib/codemirror/theme/3024-night.css | 37 -
.../lib/codemirror/theme/ambiance-mobile.css | 5 -
public/js/lib/codemirror/theme/ambiance.css | 77 -
.../js/lib/codemirror/theme/base16-dark.css | 36 -
.../js/lib/codemirror/theme/base16-light.css | 36 -
public/js/lib/codemirror/theme/blackboard.css | 30 -
public/js/lib/codemirror/theme/cobalt.css | 23 -
public/js/lib/codemirror/theme/eclipse.css | 23 -
public/js/lib/codemirror/theme/elegant.css | 13 -
.../js/lib/codemirror/theme/erlang-dark.css | 32 -
.../js/lib/codemirror/theme/lesser-dark.css | 45 -
public/js/lib/codemirror/theme/mbo.css | 35 -
public/js/lib/codemirror/theme/mdn-like.css | 44 -
public/js/lib/codemirror/theme/midnight.css | 45 -
public/js/lib/codemirror/theme/monokai.css | 31 -
public/js/lib/codemirror/theme/neat.css | 12 -
public/js/lib/codemirror/theme/neo.css | 43 -
public/js/lib/codemirror/theme/night.css | 26 -
.../js/lib/codemirror/theme/paraiso-dark.css | 36 -
.../js/lib/codemirror/theme/paraiso-light.css | 36 -
.../lib/codemirror/theme/pastel-on-dark.css | 50 -
public/js/lib/codemirror/theme/rubyblue.css | 23 -
public/js/lib/codemirror/theme/solarized.css | 165 -
public/js/lib/codemirror/theme/the-matrix.css | 28 -
.../theme/tomorrow-night-bright.css | 35 -
.../theme/tomorrow-night-eighties.css | 36 -
public/js/lib/codemirror/theme/twilight.css | 30 -
.../js/lib/codemirror/theme/vibrant-ink.css | 32 -
public/js/lib/codemirror/theme/xq-dark.css | 51 -
public/js/lib/codemirror/theme/xq-light.css | 43 -
public/js/lib/codemirror/theme/zenburn.css | 37 -
public/js/lib/jquery-2.1.1.min.js | 4 -
public/js/lib/ramda/ramda.js | 4 -
public/js/lib/ramda/ramda.min.js | 6 -
server/views/coursewares/showBonfire.jade | 10 -
server/views/coursewares/showHTML.jade | 14 -
server/views/coursewares/showJS.jade | 9 -
server/views/coursewares/showStep.jade | 2 +-
.../coursewares/showZiplineOrBasejump.jade | 2 -
server/views/partials/challenge-footer.jade | 2 +
server/views/partials/scripts.jade | 29 +-
189 files changed, 91 insertions(+), 117639 deletions(-)
delete mode 100644 public/js/lib/bootstrap.min.js
delete mode 100644 public/js/lib/chai/chai-jquery.js
delete mode 100644 public/js/lib/chai/chai.js
delete mode 100755 public/js/lib/codemirror-accessible/.gitignore
delete mode 100755 public/js/lib/codemirror-accessible/README.md
delete mode 100755 public/js/lib/codemirror-accessible/accessible.js
delete mode 100755 public/js/lib/codemirror-accessible/codemirror-accessible.js
delete mode 100755 public/js/lib/codemirror-accessible/codemirror-accessible2.js
delete mode 100755 public/js/lib/codemirror-accessible/codemirror-original.js
delete mode 100755 public/js/lib/codemirror-accessible/codemirror.css
delete mode 100755 public/js/lib/codemirror-accessible/index.html
delete mode 100755 public/js/lib/codemirror-accessible/javascript.js
delete mode 100755 public/js/lib/codemirror-accessible/stress.html
delete mode 100644 public/js/lib/codemirror/.gitattributes
delete mode 100644 public/js/lib/codemirror/.gitignore
delete mode 100644 public/js/lib/codemirror/.travis.yml
delete mode 100644 public/js/lib/codemirror/AUTHORS
delete mode 100644 public/js/lib/codemirror/CONTRIBUTING.md
delete mode 100644 public/js/lib/codemirror/LICENSE
delete mode 100644 public/js/lib/codemirror/README.md
delete mode 100644 public/js/lib/codemirror/addon/comment/comment.js
delete mode 100644 public/js/lib/codemirror/addon/comment/continuecomment.js
delete mode 100644 public/js/lib/codemirror/addon/dialog/dialog.css
delete mode 100644 public/js/lib/codemirror/addon/dialog/dialog.js
delete mode 100644 public/js/lib/codemirror/addon/display/fullscreen.css
delete mode 100644 public/js/lib/codemirror/addon/display/fullscreen.js
delete mode 100644 public/js/lib/codemirror/addon/display/panel.js
delete mode 100644 public/js/lib/codemirror/addon/display/placeholder.js
delete mode 100644 public/js/lib/codemirror/addon/display/rulers.js
delete mode 100644 public/js/lib/codemirror/addon/edit/closebrackets.js
delete mode 100644 public/js/lib/codemirror/addon/edit/closetag.js
delete mode 100644 public/js/lib/codemirror/addon/edit/continuelist.js
delete mode 100644 public/js/lib/codemirror/addon/edit/matchbrackets.js
delete mode 100644 public/js/lib/codemirror/addon/edit/matchtags.js
delete mode 100644 public/js/lib/codemirror/addon/edit/trailingspace.js
delete mode 100644 public/js/lib/codemirror/addon/emmet/emmet.js
delete mode 100644 public/js/lib/codemirror/addon/fold/brace-fold.js
delete mode 100644 public/js/lib/codemirror/addon/fold/comment-fold.js
delete mode 100644 public/js/lib/codemirror/addon/fold/foldcode.js
delete mode 100644 public/js/lib/codemirror/addon/fold/foldgutter.css
delete mode 100644 public/js/lib/codemirror/addon/fold/foldgutter.js
delete mode 100644 public/js/lib/codemirror/addon/fold/indent-fold.js
delete mode 100644 public/js/lib/codemirror/addon/fold/markdown-fold.js
delete mode 100644 public/js/lib/codemirror/addon/fold/xml-fold.js
delete mode 100644 public/js/lib/codemirror/addon/hint/anyword-hint.js
delete mode 100644 public/js/lib/codemirror/addon/hint/css-hint.js
delete mode 100644 public/js/lib/codemirror/addon/hint/html-hint.js
delete mode 100644 public/js/lib/codemirror/addon/hint/javascript-hint.js
delete mode 100644 public/js/lib/codemirror/addon/hint/show-hint.css
delete mode 100644 public/js/lib/codemirror/addon/hint/show-hint.js
delete mode 100644 public/js/lib/codemirror/addon/hint/sql-hint.js
delete mode 100644 public/js/lib/codemirror/addon/hint/xml-hint.js
delete mode 100644 public/js/lib/codemirror/addon/lint/coffeescript-lint.js
delete mode 100644 public/js/lib/codemirror/addon/lint/css-lint.js
delete mode 100644 public/js/lib/codemirror/addon/lint/javascript-lint.js
delete mode 100644 public/js/lib/codemirror/addon/lint/json-lint.js
delete mode 100644 public/js/lib/codemirror/addon/lint/lint.css
delete mode 100644 public/js/lib/codemirror/addon/lint/lint.js
delete mode 100644 public/js/lib/codemirror/addon/lint/yaml-lint.js
delete mode 100644 public/js/lib/codemirror/addon/merge/merge.css
delete mode 100644 public/js/lib/codemirror/addon/merge/merge.js
delete mode 100644 public/js/lib/codemirror/addon/mode/loadmode.js
delete mode 100644 public/js/lib/codemirror/addon/mode/multiplex.js
delete mode 100644 public/js/lib/codemirror/addon/mode/multiplex_test.js
delete mode 100644 public/js/lib/codemirror/addon/mode/overlay.js
delete mode 100644 public/js/lib/codemirror/addon/mode/simple.js
delete mode 100644 public/js/lib/codemirror/addon/runmode/colorize.js
delete mode 100644 public/js/lib/codemirror/addon/runmode/runmode-standalone.js
delete mode 100644 public/js/lib/codemirror/addon/runmode/runmode.js
delete mode 100644 public/js/lib/codemirror/addon/runmode/runmode.node.js
delete mode 100644 public/js/lib/codemirror/addon/scroll/annotatescrollbar.js
delete mode 100644 public/js/lib/codemirror/addon/scroll/scrollpastend.js
delete mode 100644 public/js/lib/codemirror/addon/scroll/simplescrollbars.css
delete mode 100644 public/js/lib/codemirror/addon/scroll/simplescrollbars.js
delete mode 100644 public/js/lib/codemirror/addon/search/match-highlighter.js
delete mode 100644 public/js/lib/codemirror/addon/search/matchesonscrollbar.css
delete mode 100644 public/js/lib/codemirror/addon/search/matchesonscrollbar.js
delete mode 100644 public/js/lib/codemirror/addon/search/search.js
delete mode 100644 public/js/lib/codemirror/addon/search/searchcursor.js
delete mode 100644 public/js/lib/codemirror/addon/selection/active-line.js
delete mode 100644 public/js/lib/codemirror/addon/selection/mark-selection.js
delete mode 100644 public/js/lib/codemirror/addon/tern/tern.css
delete mode 100644 public/js/lib/codemirror/addon/tern/tern.js
delete mode 100644 public/js/lib/codemirror/addon/tern/worker.js
delete mode 100644 public/js/lib/codemirror/addon/wrap/hardwrap.js
delete mode 100755 public/js/lib/codemirror/bin/authors.sh
delete mode 100755 public/js/lib/codemirror/bin/compress
delete mode 100755 public/js/lib/codemirror/bin/lint
delete mode 100755 public/js/lib/codemirror/bin/release
delete mode 100755 public/js/lib/codemirror/bin/source-highlight
delete mode 100644 public/js/lib/codemirror/bower.json
delete mode 100644 public/js/lib/codemirror/index.html
delete mode 100644 public/js/lib/codemirror/keymap/emacs.js
delete mode 100644 public/js/lib/codemirror/keymap/sublime.js
delete mode 100644 public/js/lib/codemirror/keymap/vim.js
delete mode 100644 public/js/lib/codemirror/lib/codemirror.css
delete mode 100644 public/js/lib/codemirror/lib/codemirror.js
delete mode 100644 public/js/lib/codemirror/mode/css/css.js
delete mode 100644 public/js/lib/codemirror/mode/css/index.html
delete mode 100644 public/js/lib/codemirror/mode/css/less.html
delete mode 100644 public/js/lib/codemirror/mode/css/less_test.js
delete mode 100644 public/js/lib/codemirror/mode/css/scss.html
delete mode 100644 public/js/lib/codemirror/mode/css/scss_test.js
delete mode 100644 public/js/lib/codemirror/mode/css/test.js
delete mode 100644 public/js/lib/codemirror/mode/htmlembedded/htmlembedded.js
delete mode 100644 public/js/lib/codemirror/mode/htmlembedded/index.html
delete mode 100644 public/js/lib/codemirror/mode/htmlmixed/htmlmixed.js
delete mode 100644 public/js/lib/codemirror/mode/htmlmixed/index.html
delete mode 100644 public/js/lib/codemirror/mode/jade/index.html
delete mode 100644 public/js/lib/codemirror/mode/jade/jade.js
delete mode 100644 public/js/lib/codemirror/mode/javascript/index.html
delete mode 100644 public/js/lib/codemirror/mode/javascript/javascript.js
delete mode 100644 public/js/lib/codemirror/mode/javascript/json-ld.html
delete mode 100644 public/js/lib/codemirror/mode/javascript/test.js
delete mode 100644 public/js/lib/codemirror/mode/javascript/typescript.html
delete mode 100644 public/js/lib/codemirror/mode/markdown/index.html
delete mode 100644 public/js/lib/codemirror/mode/markdown/markdown.js
delete mode 100644 public/js/lib/codemirror/mode/markdown/test.js
delete mode 100644 public/js/lib/codemirror/mode/meta.js
delete mode 100644 public/js/lib/codemirror/mode/xml/index.html
delete mode 100644 public/js/lib/codemirror/mode/xml/test.js
delete mode 100644 public/js/lib/codemirror/mode/xml/xml.js
delete mode 100644 public/js/lib/codemirror/mode/yaml/index.html
delete mode 100644 public/js/lib/codemirror/mode/yaml/yaml.js
delete mode 100644 public/js/lib/codemirror/package.json
delete mode 100644 public/js/lib/codemirror/test/comment_test.js
delete mode 100644 public/js/lib/codemirror/test/doc_test.js
delete mode 100644 public/js/lib/codemirror/test/driver.js
delete mode 100644 public/js/lib/codemirror/test/emacs_test.js
delete mode 100644 public/js/lib/codemirror/test/index.html
delete mode 100644 public/js/lib/codemirror/test/lint/acorn.js
delete mode 100644 public/js/lib/codemirror/test/lint/lint.js
delete mode 100644 public/js/lib/codemirror/test/lint/walk.js
delete mode 100644 public/js/lib/codemirror/test/mode_test.css
delete mode 100644 public/js/lib/codemirror/test/mode_test.js
delete mode 100644 public/js/lib/codemirror/test/multi_test.js
delete mode 100644 public/js/lib/codemirror/test/phantom_driver.js
delete mode 100755 public/js/lib/codemirror/test/run.js
delete mode 100644 public/js/lib/codemirror/test/scroll_test.js
delete mode 100644 public/js/lib/codemirror/test/search_test.js
delete mode 100644 public/js/lib/codemirror/test/sublime_test.js
delete mode 100644 public/js/lib/codemirror/test/test.js
delete mode 100644 public/js/lib/codemirror/test/vim_test.js
delete mode 100644 public/js/lib/codemirror/theme/3024-day.css
delete mode 100644 public/js/lib/codemirror/theme/3024-night.css
delete mode 100644 public/js/lib/codemirror/theme/ambiance-mobile.css
delete mode 100644 public/js/lib/codemirror/theme/ambiance.css
delete mode 100644 public/js/lib/codemirror/theme/base16-dark.css
delete mode 100644 public/js/lib/codemirror/theme/base16-light.css
delete mode 100644 public/js/lib/codemirror/theme/blackboard.css
delete mode 100644 public/js/lib/codemirror/theme/cobalt.css
delete mode 100644 public/js/lib/codemirror/theme/eclipse.css
delete mode 100644 public/js/lib/codemirror/theme/elegant.css
delete mode 100644 public/js/lib/codemirror/theme/erlang-dark.css
delete mode 100644 public/js/lib/codemirror/theme/lesser-dark.css
delete mode 100644 public/js/lib/codemirror/theme/mbo.css
delete mode 100644 public/js/lib/codemirror/theme/mdn-like.css
delete mode 100644 public/js/lib/codemirror/theme/midnight.css
delete mode 100644 public/js/lib/codemirror/theme/monokai.css
delete mode 100644 public/js/lib/codemirror/theme/neat.css
delete mode 100644 public/js/lib/codemirror/theme/neo.css
delete mode 100644 public/js/lib/codemirror/theme/night.css
delete mode 100644 public/js/lib/codemirror/theme/paraiso-dark.css
delete mode 100644 public/js/lib/codemirror/theme/paraiso-light.css
delete mode 100644 public/js/lib/codemirror/theme/pastel-on-dark.css
delete mode 100644 public/js/lib/codemirror/theme/rubyblue.css
delete mode 100644 public/js/lib/codemirror/theme/solarized.css
delete mode 100644 public/js/lib/codemirror/theme/the-matrix.css
delete mode 100644 public/js/lib/codemirror/theme/tomorrow-night-bright.css
delete mode 100644 public/js/lib/codemirror/theme/tomorrow-night-eighties.css
delete mode 100644 public/js/lib/codemirror/theme/twilight.css
delete mode 100644 public/js/lib/codemirror/theme/vibrant-ink.css
delete mode 100644 public/js/lib/codemirror/theme/xq-dark.css
delete mode 100644 public/js/lib/codemirror/theme/xq-light.css
delete mode 100644 public/js/lib/codemirror/theme/zenburn.css
delete mode 100644 public/js/lib/jquery-2.1.1.min.js
delete mode 100644 public/js/lib/ramda/ramda.js
delete mode 100644 public/js/lib/ramda/ramda.min.js
diff --git a/bower.json b/bower.json
index 1f833167fcc..fe3c9c6a302 100644
--- a/bower.json
+++ b/bower.json
@@ -25,8 +25,10 @@
"font-awesome": "~4.3.0",
"moment": "~2.10.2",
"angular-bootstrap": "~0.13.0",
- "ramda": "~0.13.0",
"jshint": "~2.7.0",
- "lightbox2": "~2.8.1"
+ "lightbox2": "~2.8.1",
+ "rxjs": "~4.0.6",
+ "CodeMirror": "~5.8.0",
+ "chai": "~3.4.1"
}
}
diff --git a/client/commonFramework.js b/client/commonFramework.js
index 1138975570c..b5a80bc2f09 100644
--- a/client/commonFramework.js
+++ b/client/commonFramework.js
@@ -268,7 +268,7 @@ common.codeOutput = (function(CodeMirror, document, challengeType) {
return codeOutput;
}(window.CodeMirror, window.document, common.challengeType || 0));
-var sandBox = (function(jailed, codeOutput) {
+common.sandBox = (function(jailed, codeOutput) {
if (!jailed) {
return {};
}
@@ -818,7 +818,7 @@ function safeHTMLRun(test) {
' return this;' +
'};' + s;
- sandBox.submit(scopejQuery(s), function(cls, message) {
+ common.sandBox.submit(scopejQuery(s), function(cls, message) {
if (cls) {
console.log(message.error);
workerError(message.error);
@@ -1398,7 +1398,7 @@ function bonfireExecute(shouldTest) {
if (userJavaScript.match(/function/gi)) {
if (userJavaScript.match(/function\s*?\(|function\s+\w+\s*?\(/gi)) {
- sandBox.submit(userJavaScript, function(cls, message) {
+ common.sandBox.submit(userJavaScript, function(cls, message) {
if (failedCommentTest) {
editor.setValue(editor.getValue() + '*/');
console.log('Caught Unfinished Comment');
@@ -1422,7 +1422,7 @@ function bonfireExecute(shouldTest) {
codeOutput.setValue('Unsafe or unfinished function declaration');
}
} else {
- sandBox.submit(userJavaScript, function(cls, message) {
+ common.sandBox.submit(userJavaScript, function(cls, message) {
if (failedCommentTest) {
editor.setValue(editor.getValue() + '*/');
diff --git a/gulpfile.js b/gulpfile.js
index f37b963a687..52187054bee 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -14,7 +14,9 @@ var Rx = require('rx'),
sortKeys = require('sort-keys'),
debug = require('debug')('freecc:gulp'),
yargs = require('yargs'),
+ concat = require('gulp-concat'),
uglify = require('gulp-uglify'),
+ merge = require('merge-stream'),
// react app
webpack = require('gulp-webpack'),
@@ -70,6 +72,33 @@ var paths = {
dest: 'public/js'
},
+ vendorChallenges: [
+ 'public/bower_components/jshint/dist/jshint.js',
+ 'public/bower_components/chai/chai.js',
+ 'public/bower_components/CodeMirror/lib/codemirror.js',
+ 'public/bower_components/CodeMirror/addon/edit/closebrackets.js',
+ 'public/bower_components/CodeMirror/addon/edit/matchbrackets.js',
+ 'public/bower_components/CodeMirror/addon/lint/lint.js',
+ 'public/bower_components/CodeMirror/addon/lint/javascript-lint.js',
+ 'public/bower_components/CodeMirror/mode/javascript/javascript.js',
+ 'public/bower_components/CodeMirror/mode/xml/xml.js',
+ 'public/bower_components/CodeMirror/mode/css/css.js',
+ 'public/bower_components/CodeMirror/mode/htmlmixed/htmlmixed.js',
+ 'public/bower_components/CodeMirror/addon/emmet/emmet.js'
+ ],
+
+ vendorMain: [
+ 'public/bower_components/jquery/dist/jquery.min.js',
+ 'public/bower_components/bootstrap/dist/js/bootstrap.min.js',
+ 'public/bower_components/angular/angular.min.js',
+ 'public/bower_components/angular-bootstrap/ui-bootstrap.min.js',
+ 'public/bower_components/angular-bootstrap/ui-bootstrap-tpls.min.js',
+ 'public/bower_components/d3/d3.min.js',
+ 'public/bower_components/moment/min/moment.min.js',
+ 'public/bower_components/lightbox2/dist/js/lightbox.min.js',
+ 'public/bower_components/rxjs/dist/rx.all.min.js'
+ ],
+
js: [
'client/main.js',
'client/iFrameScripts.js',
@@ -297,7 +326,7 @@ gulp.task('less', function() {
var dest = paths.css;
return gulp.src(paths.less)
.pipe(plumber({ errorHandler: errorHandler }))
- // copile
+ // compile
.pipe(less({
paths: [ path.join(__dirname, 'less', 'includes') ]
}))
@@ -315,12 +344,52 @@ gulp.task('less', function() {
.pipe(gulp.dest(paths.manifest));
});
+function getFilesGlob(files) {
+ if (!__DEV__) {
+ return files;
+ }
+ return files.map(function(file) {
+ return file
+ .replace('.min.', '.')
+ // moment breaks the pattern
+ .replace('/min/', '/');
+ });
+}
+
+gulp.task('vendor', ['js'], function() {
+ var manifestName = 'js-manifest.json';
+ var dest = paths.publicJs;
+
+ var vendorFiles = merge(
+ gulp.src(getFilesGlob(paths.vendorMain))
+ .pipe(concat('vendor-main.js')),
+ gulp.src(paths.vendorChallenges)
+ .pipe(__DEV__ ? gutil.noop() : uglify())
+ .pipe(concat('vendor-challenges.js'))
+ );
+
+ return vendorFiles.pipe(gulp.dest(dest))
+ // create registry file
+ .pipe(rev())
+ // copy revisioned assets to dest
+ .pipe(gulp.dest(dest))
+ // create manifest file
+ .pipe(rev.manifest(manifestName))
+ .pipe(delRev(
+ dest,
+ manifestName
+ ))
+ // copy manifest file to dest
+ .pipe(gulp.dest(paths.manifest));
+});
+
gulp.task('js', function() {
var manifestName = 'js-manifest.json';
var dest = paths.publicJs;
return gulp.src(paths.js)
.pipe(plumber({ errorHandler: errorHandler }))
+ .pipe(__DEV__ ? gutil.noop() : uglify())
.pipe(gulp.dest(dest))
// create registry file
.pipe(rev())
@@ -348,6 +417,7 @@ gulp.task('dependents', ['js'], function() {
return gulp.src(paths.dependents)
.pipe(plumber({ errorHandler: errorHandler }))
+ .pipe(__DEV__ ? gutil.noop() : uglify())
.pipe(revReplace({ manifest: manifest }))
.pipe(gulp.dest(dest))
.pipe(rev())
@@ -374,7 +444,7 @@ function buildManifest() {
.pipe(gulp.dest('server/'));
}
-var buildDependents = ['less', 'js', 'dependents'];
+var buildDependents = ['less', 'js', 'dependents', 'vendor'];
gulp.task('build-manifest', buildDependents, function() {
return buildManifest();
diff --git a/package.json b/package.json
index a9e5b0a664d..21138d128cb 100644
--- a/package.json
+++ b/package.json
@@ -57,6 +57,7 @@
"forever": "~0.15.1",
"frameguard": "~0.2.2",
"gulp": "^3.9.0",
+ "gulp-concat": "^2.6.0",
"gulp-eslint": "^1.1.0",
"gulp-inject": "^3.0.0",
"gulp-jsonlint": "^1.1.0",
@@ -64,6 +65,7 @@
"gulp-minify-css": "^1.2.1",
"gulp-nodemon": "^2.0.3",
"gulp-notify": "^2.2.0",
+ "gulp-order": "^1.1.1",
"gulp-plumber": "^1.0.1",
"gulp-reduce-file": "0.0.1",
"gulp-rev": "^6.0.1",
@@ -82,6 +84,7 @@
"loopback-boot": "^2.13.0",
"loopback-component-passport": "^1.6.0",
"loopback-connector-mongodb": "^1.10.0",
+ "merge-stream": "^1.0.0",
"method-override": "^2.3.0",
"moment": "^2.10.2",
"mongodb": "^2.0.33",
@@ -120,7 +123,11 @@
"validator": "^4.2.1",
"webpack": "^1.9.12",
"xss-filters": "^1.2.6",
+<<<<<<< HEAD
"yargs": "^3.30.0"
+=======
+ "yargs": "^3.29.0"
+>>>>>>> bundle vendor files
},
"devDependencies": {
"blessed": "~0.1.81",
diff --git a/public/js/lib/bootstrap.min.js b/public/js/lib/bootstrap.min.js
deleted file mode 100644
index 1d4a4ed3701..00000000000
--- a/public/js/lib/bootstrap.min.js
+++ /dev/null
@@ -1,6 +0,0 @@
-/*!
- * Bootstrap v3.1.0 (http://getbootstrap.com)
- * Copyright 2011-2014 Twitter, Inc.
- * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
- */
-if("undefined"==typeof jQuery)throw new Error("Bootstrap requires jQuery");+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one(a.support.transition.end,function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b()})}(jQuery),+function(a){"use strict";var b='[data-dismiss="alert"]',c=function(c){a(c).on("click",b,this.close)};c.prototype.close=function(b){function c(){f.trigger("closed.bs.alert").remove()}var d=a(this),e=d.attr("data-target");e||(e=d.attr("href"),e=e&&e.replace(/.*(?=#[^\s]*$)/,""));var f=a(e);b&&b.preventDefault(),f.length||(f=d.hasClass("alert")?d:d.parent()),f.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(f.removeClass("in"),a.support.transition&&f.hasClass("fade")?f.one(a.support.transition.end,c).emulateTransitionEnd(150):c())};var d=a.fn.alert;a.fn.alert=function(b){return this.each(function(){var d=a(this),e=d.data("bs.alert");e||d.data("bs.alert",e=new c(this)),"string"==typeof b&&e[b].call(d)})},a.fn.alert.Constructor=c,a.fn.alert.noConflict=function(){return a.fn.alert=d,this},a(document).on("click.bs.alert.data-api",b,c.prototype.close)}(jQuery),+function(a){"use strict";var b=function(c,d){this.$element=a(c),this.options=a.extend({},b.DEFAULTS,d),this.isLoading=!1};b.DEFAULTS={loadingText:"loading..."},b.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",f.resetText||d.data("resetText",d[e]()),d[e](f[b]||this.options[b]),setTimeout(a.proxy(function(){"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c))},this),0)},b.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")&&(c.prop("checked")&&this.$element.hasClass("active")?a=!1:b.find(".active").removeClass("active")),a&&c.prop("checked",!this.$element.hasClass("active")).trigger("change")}a&&this.$element.toggleClass("active")};var c=a.fn.button;a.fn.button=function(c){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof c&&c;e||d.data("bs.button",e=new b(this,f)),"toggle"==c?e.toggle():c&&e.setState(c)})},a.fn.button.Constructor=b,a.fn.button.noConflict=function(){return a.fn.button=c,this},a(document).on("click.bs.button.data-api","[data-toggle^=button]",function(b){var c=a(b.target);c.hasClass("btn")||(c=c.closest(".btn")),c.button("toggle"),b.preventDefault()})}(jQuery),+function(a){"use strict";var b=function(b,c){this.$element=a(b),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=this.sliding=this.interval=this.$active=this.$items=null,"hover"==this.options.pause&&this.$element.on("mouseenter",a.proxy(this.pause,this)).on("mouseleave",a.proxy(this.cycle,this))};b.DEFAULTS={interval:5e3,pause:"hover",wrap:!0},b.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},b.prototype.getActiveIndex=function(){return this.$active=this.$element.find(".item.active"),this.$items=this.$active.parent().children(),this.$items.index(this.$active)},b.prototype.to=function(b){var c=this,d=this.getActiveIndex();return b>this.$items.length-1||0>b?void 0:this.sliding?this.$element.one("slid.bs.carousel",function(){c.to(b)}):d==b?this.pause().cycle():this.slide(b>d?"next":"prev",a(this.$items[b]))},b.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},b.prototype.next=function(){return this.sliding?void 0:this.slide("next")},b.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},b.prototype.slide=function(b,c){var d=this.$element.find(".item.active"),e=c||d[b](),f=this.interval,g="next"==b?"left":"right",h="next"==b?"first":"last",i=this;if(!e.length){if(!this.options.wrap)return;e=this.$element.find(".item")[h]()}if(e.hasClass("active"))return this.sliding=!1;var j=a.Event("slide.bs.carousel",{relatedTarget:e[0],direction:g});return this.$element.trigger(j),j.isDefaultPrevented()?void 0:(this.sliding=!0,f&&this.pause(),this.$indicators.length&&(this.$indicators.find(".active").removeClass("active"),this.$element.one("slid.bs.carousel",function(){var b=a(i.$indicators.children()[i.getActiveIndex()]);b&&b.addClass("active")})),a.support.transition&&this.$element.hasClass("slide")?(e.addClass(b),e[0].offsetWidth,d.addClass(g),e.addClass(g),d.one(a.support.transition.end,function(){e.removeClass([b,g].join(" ")).addClass("active"),d.removeClass(["active",g].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger("slid.bs.carousel")},0)}).emulateTransitionEnd(1e3*d.css("transition-duration").slice(0,-1))):(d.removeClass("active"),e.addClass("active"),this.sliding=!1,this.$element.trigger("slid.bs.carousel")),f&&this.cycle(),this)};var c=a.fn.carousel;a.fn.carousel=function(c){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},b.DEFAULTS,d.data(),"object"==typeof c&&c),g="string"==typeof c?c:f.slide;e||d.data("bs.carousel",e=new b(this,f)),"number"==typeof c?e.to(c):g?e[g]():f.interval&&e.pause().cycle()})},a.fn.carousel.Constructor=b,a.fn.carousel.noConflict=function(){return a.fn.carousel=c,this},a(document).on("click.bs.carousel.data-api","[data-slide], [data-slide-to]",function(b){var c,d=a(this),e=a(d.attr("data-target")||(c=d.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,"")),f=a.extend({},e.data(),d.data()),g=d.attr("data-slide-to");g&&(f.interval=!1),e.carousel(f),(g=d.attr("data-slide-to"))&&e.data("bs.carousel").to(g),b.preventDefault()}),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var b=a(this);b.carousel(b.data())})})}(jQuery),+function(a){"use strict";var b=function(c,d){this.$element=a(c),this.options=a.extend({},b.DEFAULTS,d),this.transitioning=null,this.options.parent&&(this.$parent=a(this.options.parent)),this.options.toggle&&this.toggle()};b.DEFAULTS={toggle:!0},b.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},b.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var b=a.Event("show.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.$parent&&this.$parent.find("> .panel > .in");if(c&&c.length){var d=c.data("bs.collapse");if(d&&d.transitioning)return;c.collapse("hide"),d||c.data("bs.collapse",null)}var e=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[e](0),this.transitioning=1;var f=function(){this.$element.removeClass("collapsing").addClass("collapse in")[e]("auto"),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return f.call(this);var g=a.camelCase(["scroll",e].join("-"));this.$element.one(a.support.transition.end,a.proxy(f,this)).emulateTransitionEnd(350)[e](this.$element[0][g])}}},b.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse").removeClass("in"),this.transitioning=1;var d=function(){this.transitioning=0,this.$element.trigger("hidden.bs.collapse").removeClass("collapsing").addClass("collapse")};return a.support.transition?void this.$element[c](0).one(a.support.transition.end,a.proxy(d,this)).emulateTransitionEnd(350):d.call(this)}}},b.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()};var c=a.fn.collapse;a.fn.collapse=function(c){return this.each(function(){var d=a(this),e=d.data("bs.collapse"),f=a.extend({},b.DEFAULTS,d.data(),"object"==typeof c&&c);!e&&f.toggle&&"show"==c&&(c=!c),e||d.data("bs.collapse",e=new b(this,f)),"string"==typeof c&&e[c]()})},a.fn.collapse.Constructor=b,a.fn.collapse.noConflict=function(){return a.fn.collapse=c,this},a(document).on("click.bs.collapse.data-api","[data-toggle=collapse]",function(b){var c,d=a(this),e=d.attr("data-target")||b.preventDefault()||(c=d.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,""),f=a(e),g=f.data("bs.collapse"),h=g?"toggle":d.data(),i=d.attr("data-parent"),j=i&&a(i);g&&g.transitioning||(j&&j.find('[data-toggle=collapse][data-parent="'+i+'"]').not(d).addClass("collapsed"),d[f.hasClass("in")?"addClass":"removeClass"]("collapsed")),f.collapse(h)})}(jQuery),+function(a){"use strict";function b(b){a(d).remove(),a(e).each(function(){var d=c(a(this)),e={relatedTarget:this};d.hasClass("open")&&(d.trigger(b=a.Event("hide.bs.dropdown",e)),b.isDefaultPrevented()||d.removeClass("open").trigger("hidden.bs.dropdown",e))})}function c(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}var d=".dropdown-backdrop",e="[data-toggle=dropdown]",f=function(b){a(b).on("click.bs.dropdown",this.toggle)};f.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=c(e),g=f.hasClass("open");if(b(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a('
').insertAfter(a(this)).on("click",b);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;f.toggleClass("open").trigger("shown.bs.dropdown",h),e.focus()}return!1}},f.prototype.keydown=function(b){if(/(38|40|27)/.test(b.keyCode)){var d=a(this);if(b.preventDefault(),b.stopPropagation(),!d.is(".disabled, :disabled")){var f=c(d),g=f.hasClass("open");if(!g||g&&27==b.keyCode)return 27==b.which&&f.find(e).focus(),d.click();var h=" li:not(.divider):visible a",i=f.find("[role=menu]"+h+", [role=listbox]"+h);if(i.length){var j=i.index(i.filter(":focus"));38==b.keyCode&&j>0&&j--,40==b.keyCode&&j ').appendTo(document.body),this.$element.on("click.dismiss.bs.modal",a.proxy(function(a){a.target===a.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus.call(this.$element[0]):this.hide.call(this))},this)),d&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!b)return;d?this.$backdrop.one(a.support.transition.end,b).emulateTransitionEnd(150):b()}else!this.isShown&&this.$backdrop?(this.$backdrop.removeClass("in"),a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one(a.support.transition.end,b).emulateTransitionEnd(150):b()):b&&b()};var c=a.fn.modal;a.fn.modal=function(c,d){return this.each(function(){var e=a(this),f=e.data("bs.modal"),g=a.extend({},b.DEFAULTS,e.data(),"object"==typeof c&&c);f||e.data("bs.modal",f=new b(this,g)),"string"==typeof c?f[c](d):g.show&&f.show(d)})},a.fn.modal.Constructor=b,a.fn.modal.noConflict=function(){return a.fn.modal=c,this},a(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(b){var c=a(this),d=c.attr("href"),e=a(c.attr("data-target")||d&&d.replace(/.*(?=#[^\s]+$)/,"")),f=e.data("bs.modal")?"toggle":a.extend({remote:!/#/.test(d)&&d},e.data(),c.data());c.is("a")&&b.preventDefault(),e.modal(f,this).one("hide",function(){c.is(":visible")&&c.focus()})}),a(document).on("show.bs.modal",".modal",function(){a(document.body).addClass("modal-open")}).on("hidden.bs.modal",".modal",function(){a(document.body).removeClass("modal-open")})}(jQuery),+function(a){"use strict";var b=function(a,b){this.type=this.options=this.enabled=this.timeout=this.hoverState=this.$element=null,this.init("tooltip",a,b)};b.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'',trigger:"hover focus",title:"",delay:0,html:!1,container:!1},b.prototype.init=function(b,c,d){this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d);for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},b.prototype.getDefaults=function(){return b.DEFAULTS},b.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},b.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},b.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget)[this.type](this.getDelegateOptions()).data("bs."+this.type);return clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show()},b.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget)[this.type](this.getDelegateOptions()).data("bs."+this.type);return clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide()},b.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){if(this.$element.trigger(b),b.isDefaultPrevented())return;var c=this,d=this.tip();this.setContent(),this.options.animation&&d.addClass("fade");var e="function"==typeof this.options.placement?this.options.placement.call(this,d[0],this.$element[0]):this.options.placement,f=/\s?auto?\s?/i,g=f.test(e);g&&(e=e.replace(f,"")||"top"),d.detach().css({top:0,left:0,display:"block"}).addClass(e),this.options.container?d.appendTo(this.options.container):d.insertAfter(this.$element);var h=this.getPosition(),i=d[0].offsetWidth,j=d[0].offsetHeight;if(g){var k=this.$element.parent(),l=e,m=document.documentElement.scrollTop||document.body.scrollTop,n="body"==this.options.container?window.innerWidth:k.outerWidth(),o="body"==this.options.container?window.innerHeight:k.outerHeight(),p="body"==this.options.container?0:k.offset().left;e="bottom"==e&&h.top+h.height+j-m>o?"top":"top"==e&&h.top-m-j<0?"bottom":"right"==e&&h.right+i>n?"left":"left"==e&&h.left-i
'}),b.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),b.prototype.constructor=b,b.prototype.getDefaults=function(){return b.DEFAULTS},b.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content")[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},b.prototype.hasContent=function(){return this.getTitle()||this.getContent()},b.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},b.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")},b.prototype.tip=function(){return this.$tip||(this.$tip=a(this.options.template)),this.$tip};var c=a.fn.popover;a.fn.popover=function(c){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof c&&c;(e||"destroy"!=c)&&(e||d.data("bs.popover",e=new b(this,f)),"string"==typeof c&&e[c]())})},a.fn.popover.Constructor=b,a.fn.popover.noConflict=function(){return a.fn.popover=c,this}}(jQuery),+function(a){"use strict";function b(c,d){var e,f=a.proxy(this.process,this);this.$element=a(a(c).is("body")?window:c),this.$body=a("body"),this.$scrollElement=this.$element.on("scroll.bs.scroll-spy.data-api",f),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||(e=a(c).attr("href"))&&e.replace(/.*(?=#[^\s]+$)/,"")||"")+" .nav li > a",this.offsets=a([]),this.targets=a([]),this.activeTarget=null,this.refresh(),this.process()}b.DEFAULTS={offset:10},b.prototype.refresh=function(){var b=this.$element[0]==window?"offset":"position";this.offsets=a([]),this.targets=a([]);{var c=this;this.$body.find(this.selector).map(function(){var d=a(this),e=d.data("target")||d.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[b]().top+(!a.isWindow(c.$scrollElement.get(0))&&c.$scrollElement.scrollTop()),e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){c.offsets.push(this[0]),c.targets.push(this[1])})}},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.$scrollElement[0].scrollHeight||this.$body[0].scrollHeight,d=c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(b>=d)return g!=(a=f.last()[0])&&this.activate(a);if(g&&b<=e[0])return g!=(a=f[0])&&this.activate(a);for(a=e.length;a--;)g!=f[a]&&b>=e[a]&&(!e[a+1]||b<=e[a+1])&&this.activate(f[a])},b.prototype.activate=function(b){this.activeTarget=b,a(this.selector).parentsUntil(this.options.target,".active").removeClass("active");var c=this.selector+'[data-target="'+b+'"],'+this.selector+'[href="'+b+'"]',d=a(c).parents("li").addClass("active");d.parent(".dropdown-menu").length&&(d=d.closest("li.dropdown").addClass("active")),d.trigger("activate.bs.scrollspy")};var c=a.fn.scrollspy;a.fn.scrollspy=function(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})},a.fn.scrollspy.Constructor=b,a.fn.scrollspy.noConflict=function(){return a.fn.scrollspy=c,this},a(window).on("load",function(){a('[data-spy="scroll"]').each(function(){var b=a(this);b.scrollspy(b.data())})})}(jQuery),+function(a){"use strict";var b=function(b){this.element=a(b)};b.prototype.show=function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.data("target");if(d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),!b.parent("li").hasClass("active")){var e=c.find(".active:last a")[0],f=a.Event("show.bs.tab",{relatedTarget:e});if(b.trigger(f),!f.isDefaultPrevented()){var g=a(d);this.activate(b.parent("li"),c),this.activate(g,g.parent(),function(){b.trigger({type:"shown.bs.tab",relatedTarget:e})})}}},b.prototype.activate=function(b,c,d){function e(){f.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),b.addClass("active"),g?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu")&&b.closest("li.dropdown").addClass("active"),d&&d()}var f=c.find("> .active"),g=d&&a.support.transition&&f.hasClass("fade");g?f.one(a.support.transition.end,e).emulateTransitionEnd(150):e(),f.removeClass("in")};var c=a.fn.tab;a.fn.tab=function(c){return this.each(function(){var d=a(this),e=d.data("bs.tab");e||d.data("bs.tab",e=new b(this)),"string"==typeof c&&e[c]()})},a.fn.tab.Constructor=b,a.fn.tab.noConflict=function(){return a.fn.tab=c,this},a(document).on("click.bs.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(b){b.preventDefault(),a(this).tab("show")})}(jQuery),+function(a){"use strict";var b=function(c,d){this.options=a.extend({},b.DEFAULTS,d),this.$window=a(window).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(c),this.affixed=this.unpin=this.pinnedOffset=null,this.checkPosition()};b.RESET="affix affix-top affix-bottom",b.DEFAULTS={offset:0},b.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(b.RESET).addClass("affix");var a=this.$window.scrollTop(),c=this.$element.offset();return this.pinnedOffset=c.top-a},b.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},b.prototype.checkPosition=function(){if(this.$element.is(":visible")){var c=a(document).height(),d=this.$window.scrollTop(),e=this.$element.offset(),f=this.options.offset,g=f.top,h=f.bottom;"top"==this.affixed&&(e.top+=d),"object"!=typeof f&&(h=g=f),"function"==typeof g&&(g=f.top(this.$element)),"function"==typeof h&&(h=f.bottom(this.$element));var i=null!=this.unpin&&d+this.unpin<=e.top?!1:null!=h&&e.top+this.$element.height()>=c-h?"bottom":null!=g&&g>=d?"top":!1;if(this.affixed!==i){this.unpin&&this.$element.css("top","");var j="affix"+(i?"-"+i:""),k=a.Event(j+".bs.affix");this.$element.trigger(k),k.isDefaultPrevented()||(this.affixed=i,this.unpin="bottom"==i?this.getPinnedOffset():null,this.$element.removeClass(b.RESET).addClass(j).trigger(a.Event(j.replace("affix","affixed"))),"bottom"==i&&this.$element.offset({top:c-h-this.$element.height()}))}}};var c=a.fn.affix;a.fn.affix=function(c){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof c&&c;e||d.data("bs.affix",e=new b(this,f)),"string"==typeof c&&e[c]()})},a.fn.affix.Constructor=b,a.fn.affix.noConflict=function(){return a.fn.affix=c,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var b=a(this),c=b.data();c.offset=c.offset||{},c.offsetBottom&&(c.offset.bottom=c.offsetBottom),c.offsetTop&&(c.offset.top=c.offsetTop),b.affix(c)})})}(jQuery);
\ No newline at end of file
diff --git a/public/js/lib/chai/chai-jquery.js b/public/js/lib/chai/chai-jquery.js
deleted file mode 100644
index 52d8a722827..00000000000
--- a/public/js/lib/chai/chai-jquery.js
+++ /dev/null
@@ -1,231 +0,0 @@
-(function (chaiJquery) {
- // Module systems magic dance.
- if (typeof require === "function" && typeof exports === "object" && typeof module === "object") {
- // NodeJS
- module.exports = chaiJquery;
- } else if (typeof define === "function" && define.amd) {
- // AMD
- define(['jquery'], function ($) {
- return function (chai, utils) {
- return chaiJquery(chai, utils, $);
- };
- });
- } else {
- // Other environment (usually
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- CodeMirror does not currently fully support screen reader software. Since CodeMirror does not use contentEditable internally, an extra effort must be made to provide this accessibility.
-
-
-Analysis of Current Functionality
-
- CodeMirror uses a hidden textarea to accept input events, track user selections, provide copy/paste, etc. This has the benefit of some native input working correctly, but since the textarea is not a mirror of the content being entered, other things do not work.
-
-
- Using NVDA , a screen reader for Windows, this is the behavior seen today with version 3.15 downloaded from http://codemirror.net/ :
-
-
- Text based input works , as the input is being added directly into the hidden textarea
- Selection works some of the time , as it populates the textarea with the current selection. It fails when the selection is over 100 lines or 1000 characters. In this case it replaces the character with a - and marks cm.display.inaccurateSelection for cleanup later
- Cursor movement does not work . This is because the textarea is usually left empty, cleared out on regular intervals
-
- Entering / exiting the editor does not work . Although you can generally tab into the editor without a mouse, leaving the editor is tricky and I've had to resort to mouse usage to do this. Compare the following behavior with the normal textarea at the bottom of the page.
-
- The tab button's behavior is overriden as you would expect with a code editor, which makes it hard to leave the field. Perhaps a key like escape could be used to blur the editor?
-
- Here are some recommendataions from WAI-ARIA 1.0 Authoring Practices - Expected keyboard interaction with a rich text editor :
-
-
-Optionally, if the developer wishes to provide the ability to insert a tab into the document, it is recommended one of the following methods be used.
-
-Provide indent and outdent buttons in the menu. Keyboard shortcuts to the buttons should be Control+M for indent and Control+Shift+M for outdent.
-Provide a button in the menu to toggle the use of Tab between the two modes. If this button is used, then Control+M is recommended as a keyboard shortcut to toggle the button.
-
-
- Please comment with suggestions on how to deal with this. Send me a message at bgrinstead@mozilla.com or @bgrins if you have any ideas.
-
-
-
-Possible Solution
-
- A solution involves resetting the input value to the current line when the cursor location moves with an empty selection. Then, by calling input.setSelectionRange(from.ch, to.ch) the actual selection location is being moved, and NVDA is able to detect the changes. This value must stay in the textarea long enough for the screenreader to detect the change, but has to be cleared out quick enough for the next cursor movement to be read properly. The quick clearing out could be made unnecessary by setting the value of the textarea to CodeMirror.getValue(), however this causes some major performance bottlenecks (see below).
-
-
- In addition, we do not clip the selection at any maximum limit to ensure that the selection is always consistent in the actual textarea.
-
-
- Still not fixed: Entering / exiting the editor is still buggy.
-
-
-
-Implementation Considerations
-
- I had hoped that this could be structured as a plugin, and could avoid touching the CodeMirror internals, but that proved to not be possible. That said, it avoids large modifications to the readInput and resetInput functions, and could easily be hidden behind a property. View the changes in codemirror-accessible.js .
-
-
- This still needs to be tested with more advanced CodeMirror features, like atomic markers and linked documents , and with other screen readers. Please let me know if you'd be able to help with testing these features or can give feedback with different screen readers.
-
-
-Performance Considerations
-
- The downside is that this could potentially slow things down. The selection was intentionally clipped with a low limit, and every time the selection changes, we need to set the textarea value to the current line of the CodeMirror. Performance on very long lines with CodeMirror are a known issue, and copying / selecting this data into a textarea is an extra step (though probably not significant compared to text measuring).
-
-
- Originally, I was setting the textarea's value to the entire content (which seems to be best for the screenreader), but there is a major impact is caused by the computation of the selectionRange in this case. Textareas setSelectionRange method takes an absolute start and end value, while CodeMirror operates on individual lines. So we need to count from 0 to currently selected line and add the length of each line to arrive there.
-
-
-Demos
-
- This is working in the demo below. Compare the first CodeMirror (with the fix applied), the second CodeMirror (using the original version), and a normal textarea (at the bottom).
-
-
- You can also see a video of the three options here:
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-Toggle CodeMirror Internal Textarea Visibility makes it easier to debug and see what is going on
-
-
-
-
-CodeMirror With Accessibility Fix direct link
-