codemirror-rails 4.7 → 4.8

Sign up to get free protection for your applications and to get access to all the features.
Files changed (26) hide show
  1. checksums.yaml +4 -4
  2. data/lib/codemirror/rails/version.rb +2 -2
  3. data/vendor/assets/javascripts/codemirror.js +229 -137
  4. data/vendor/assets/javascripts/codemirror/addons/edit/closebrackets.js +1 -1
  5. data/vendor/assets/javascripts/codemirror/addons/hint/javascript-hint.js +9 -9
  6. data/vendor/assets/javascripts/codemirror/addons/hint/xml-hint.js +9 -1
  7. data/vendor/assets/javascripts/codemirror/addons/mode/loadmode.js +19 -16
  8. data/vendor/assets/javascripts/codemirror/addons/mode/overlay.js +3 -3
  9. data/vendor/assets/javascripts/codemirror/keymaps/emacs.js +19 -28
  10. data/vendor/assets/javascripts/codemirror/keymaps/sublime.js +14 -15
  11. data/vendor/assets/javascripts/codemirror/keymaps/vim.js +694 -752
  12. data/vendor/assets/javascripts/codemirror/modes/clike.js +15 -0
  13. data/vendor/assets/javascripts/codemirror/modes/css.js +1 -1
  14. data/vendor/assets/javascripts/codemirror/modes/dockerfile.js +80 -0
  15. data/vendor/assets/javascripts/codemirror/modes/gfm.js +2 -1
  16. data/vendor/assets/javascripts/codemirror/modes/htmlmixed.js +2 -2
  17. data/vendor/assets/javascripts/codemirror/modes/idl.js +290 -0
  18. data/vendor/assets/javascripts/codemirror/modes/markdown.js +62 -55
  19. data/vendor/assets/javascripts/codemirror/modes/sparql.js +19 -5
  20. data/vendor/assets/javascripts/codemirror/modes/sql.js +0 -2
  21. data/vendor/assets/javascripts/codemirror/modes/stex.js +184 -193
  22. data/vendor/assets/javascripts/codemirror/modes/yaml.js +6 -1
  23. data/vendor/assets/stylesheets/codemirror.css +11 -2
  24. data/vendor/assets/stylesheets/codemirror/themes/3024-day.css +1 -1
  25. data/vendor/assets/stylesheets/codemirror/themes/solarized.css +0 -5
  26. metadata +3 -1
@@ -23,8 +23,13 @@ CodeMirror.defineMode("yaml", function() {
23
23
  state.escaped = false;
24
24
  /* comments */
25
25
  if (ch == "#" && (stream.pos == 0 || /\s/.test(stream.string.charAt(stream.pos - 1)))) {
26
- stream.skipToEnd(); return "comment";
26
+ stream.skipToEnd();
27
+ return "comment";
27
28
  }
29
+
30
+ if (stream.match(/^('([^']|\\.)*'?|"([^"]|\\.)*"?)/))
31
+ return "string";
32
+
28
33
  if (state.literal && stream.indentation() > state.keyCol) {
29
34
  stream.skipToEnd(); return "string";
30
35
  } else if (state.literal) { state.literal = false; }
@@ -52,12 +52,12 @@
52
52
  .CodeMirror div.CodeMirror-secondarycursor {
53
53
  border-left: 1px solid silver;
54
54
  }
55
- .CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursor {
55
+ .CodeMirror.cm-fat-cursor div.CodeMirror-cursor {
56
56
  width: auto;
57
57
  border: 0;
58
58
  background: #7e7;
59
59
  }
60
- .CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursors {
60
+ .CodeMirror.cm-fat-cursor div.CodeMirror-cursors {
61
61
  z-index: 1;
62
62
  }
63
63
 
@@ -125,6 +125,7 @@ div.CodeMirror-overwrite div.CodeMirror-cursor {}
125
125
  .cm-header, .cm-strong {font-weight: bold;}
126
126
  .cm-em {font-style: italic;}
127
127
  .cm-link {text-decoration: underline;}
128
+ .cm-strikethrough {text-decoration: line-through;}
128
129
 
129
130
  .cm-s-default .cm-error {color: #f00;}
130
131
  .cm-invalidchar {color: #f00;}
@@ -209,6 +210,11 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #f22;}
209
210
  *zoom:1;
210
211
  *display:inline;
211
212
  }
213
+ .CodeMirror-gutter-wrapper {
214
+ position: absolute;
215
+ z-index: 4;
216
+ height: 100%;
217
+ }
212
218
  .CodeMirror-gutter-elt {
213
219
  position: absolute;
214
220
  cursor: default;
@@ -305,5 +311,8 @@ div.CodeMirror-cursors {
305
311
  }
306
312
  }
307
313
 
314
+ /* See issue #2901 */
315
+ .cm-tab-wrap-hack:after { content: ''; }
316
+
308
317
  /* Help users use markselection to safely style text background */
309
318
  span.CodeMirror-selectedtext { background: none; }
@@ -35,4 +35,4 @@
35
35
  .cm-s-3024-day span.cm-error {background: #db2d20; color: #5c5855;}
36
36
 
37
37
  .cm-s-3024-day .CodeMirror-activeline-background {background: #e8f2ff !important;}
38
- .cm-s-3024-day .CodeMirror-matchingbracket { text-decoration: underline; color: white !important;}
38
+ .cm-s-3024-day .CodeMirror-matchingbracket { text-decoration: underline; color: #a16a94 !important;}
@@ -88,11 +88,6 @@ http://ethanschoonover.com/solarized/img/solarized-palette.png
88
88
  text-decoration-style: dotted;
89
89
  }
90
90
  .cm-s-solarized .cm-strong { color: #eee; }
91
- .cm-s-solarized .cm-tab:before {
92
- content: "➤"; /*visualize tab character*/
93
- color: #586e75;
94
- position:absolute;
95
- }
96
91
  .cm-s-solarized .cm-error,
97
92
  .cm-s-solarized .cm-invalidchar {
98
93
  color: #586e75;
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: codemirror-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: '4.7'
4
+ version: '4.8'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Fixler
@@ -275,6 +275,7 @@ files:
275
275
  - vendor/assets/javascripts/codemirror/modes/d.js
276
276
  - vendor/assets/javascripts/codemirror/modes/diff.js
277
277
  - vendor/assets/javascripts/codemirror/modes/django.js
278
+ - vendor/assets/javascripts/codemirror/modes/dockerfile.js
278
279
  - vendor/assets/javascripts/codemirror/modes/dtd.js
279
280
  - vendor/assets/javascripts/codemirror/modes/dylan.js
280
281
  - vendor/assets/javascripts/codemirror/modes/ecl.js
@@ -292,6 +293,7 @@ files:
292
293
  - vendor/assets/javascripts/codemirror/modes/htmlembedded.js
293
294
  - vendor/assets/javascripts/codemirror/modes/htmlmixed.js
294
295
  - vendor/assets/javascripts/codemirror/modes/http.js
296
+ - vendor/assets/javascripts/codemirror/modes/idl.js
295
297
  - vendor/assets/javascripts/codemirror/modes/jade.js
296
298
  - vendor/assets/javascripts/codemirror/modes/javascript.js
297
299
  - vendor/assets/javascripts/codemirror/modes/jinja2.js