codemirror-rails 3.17 → 3.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: fcaf99c9b9c190aac2de9f68cf058ec3e82d265e
4
- data.tar.gz: ba0b7668f1502e7e13b6de64a35abf984d910070
3
+ metadata.gz: cfb792b0da3816a44ec84933d0e66151ac99385d
4
+ data.tar.gz: 8caa95433b98eb880163d9526e1d164323723c27
5
5
  SHA512:
6
- metadata.gz: 6eb46499bbe5f971c6349a02248de371288b69be40f59a7d2e591d32b2288b864542152cc3aa55ccdd87e16f299fb4a4e1554299a714a73d9361be56e99a0476
7
- data.tar.gz: 225e6fe1d5a6ef50d703323bd19c15f36ab22ad7f5574745e2b960908938eb74a5065fa2d2c88c302d6d24350c9b037dfd3f1a6956d0f2493e60c07c476a1bb6
6
+ metadata.gz: 870029fa185381657331c3e262fd0e106f75675c039caf72be59ee00788aca72fcc2cd7e79ab961b1850cf504f6cc24e1cc9c0d2cb017e7139c9c1dba6658a87
7
+ data.tar.gz: d460615e4a5a40e3a7ef4505bc4a5a398ac1a00b217c5cb5271b9b1efa0cd1774a9623b52d5158063b0e2fe165be60615262d1fc886a3224c4ed55f7622fe3e9
@@ -1,6 +1,6 @@
1
1
  module Codemirror
2
2
  module Rails
3
- VERSION = '3.17'
4
- CODEMIRROR_VERSION = '3.17'
3
+ VERSION = '3.18'
4
+ CODEMIRROR_VERSION = '3.18'
5
5
  end
6
6
  end
@@ -309,7 +309,7 @@ window.CodeMirror = (function() {
309
309
  options.gutters = options.gutters.concat(["CodeMirror-linenumbers"]);
310
310
  } else if (found > -1 && !options.lineNumbers) {
311
311
  options.gutters = options.gutters.slice(0);
312
- options.gutters.splice(i, 1);
312
+ options.gutters.splice(found, 1);
313
313
  }
314
314
  }
315
315
 
@@ -5879,7 +5879,7 @@ window.CodeMirror = (function() {
5879
5879
 
5880
5880
  // THE END
5881
5881
 
5882
- CodeMirror.version = "3.17.0";
5882
+ CodeMirror.version = "3.18.0";
5883
5883
 
5884
5884
  return CodeMirror;
5885
5885
  })();
@@ -1,4 +1,6 @@
1
1
  (function () {
2
+ "use strict";
3
+
2
4
  function forEach(arr, f) {
3
5
  for (var i = 0, e = arr.length; i < e; ++i) f(arr[i]);
4
6
  }
@@ -45,7 +47,7 @@
45
47
  return scriptHint(editor, pigKeywordsU, function (e, cur) {return e.getTokenAt(cur);});
46
48
  }
47
49
  CodeMirror.pigHint = pigHint; // deprecated
48
- CodeMirror.registerHelper("hint", "pig", hinter);
50
+ CodeMirror.registerHelper("hint", "pig", pigHint);
49
51
 
50
52
  var pigKeywords = "VOID IMPORT RETURNS DEFINE LOAD FILTER FOREACH ORDER CUBE DISTINCT COGROUP "
51
53
  + "JOIN CROSS UNION SPLIT INTO IF OTHERWISE ALL AS BY USING INNER OUTER ONSCHEMA PARALLEL "
@@ -1,5 +1,7 @@
1
1
  // Depends on coffeelint.js from http://www.coffeelint.org/js/coffeelint.js
2
2
 
3
+ // declare global: coffeelint
4
+
3
5
  CodeMirror.registerHelper("lint", "coffeescript", function(text) {
4
6
  var found = [];
5
7
  var parseError = function(err) {
@@ -1,5 +1,7 @@
1
1
  // Depends on csslint.js from https://github.com/stubbornella/csslint
2
2
 
3
+ // declare global: CSSLint
4
+
3
5
  CodeMirror.registerHelper("lint", "css", function(text) {
4
6
  var found = [];
5
7
  var results = CSSLint.verify(text), messages = results.messages, message = null;
@@ -1,4 +1,6 @@
1
1
  (function() {
2
+ "use strict";
3
+ // declare global: JSHINT
2
4
 
3
5
  var bogus = [ "Dangerous comment" ];
4
6
 
@@ -1,5 +1,7 @@
1
1
  // Depends on jsonlint.js from https://github.com/zaach/jsonlint
2
2
 
3
+ // declare global: jsonlint
4
+
3
5
  CodeMirror.registerHelper("lint", "json", function(text) {
4
6
  var found = [];
5
7
  jsonlint.parseError = function(str, hash) {
@@ -1,5 +1,6 @@
1
1
  (function() {
2
2
  "use strict";
3
+ // declare global: diff_match_patch, DIFF_INSERT, DIFF_DELETE, DIFF_EQUAL
3
4
 
4
5
  var Pos = CodeMirror.Pos;
5
6
  var svgNS = "http://www.w3.org/2000/svg";
@@ -2,6 +2,9 @@
2
2
 
3
3
  window.CodeMirror = {};
4
4
 
5
+ (function() {
6
+ "use strict";
7
+
5
8
  function splitLines(string){ return string.split(/\r?\n|\r/); };
6
9
 
7
10
  function StringStream(string) {
@@ -130,3 +133,4 @@ CodeMirror.runMode = function (string, modespec, callback, options) {
130
133
  }
131
134
  }
132
135
  };
136
+ })();
@@ -42,6 +42,7 @@
42
42
 
43
43
  (function() {
44
44
  "use strict";
45
+ // declare global: tern
45
46
 
46
47
  CodeMirror.TernServer = function(options) {
47
48
  var self = this;
@@ -609,7 +610,7 @@
609
610
  worker.onmessage = function(e) {
610
611
  var data = e.data;
611
612
  if (data.type == "getFile") {
612
- getFile(ts, name, function(err, text) {
613
+ getFile(ts, data.name, function(err, text) {
613
614
  send({type: "getFile", err: String(err), text: text, id: data.id});
614
615
  });
615
616
  } else if (data.type == "debug") {
@@ -1,3 +1,5 @@
1
+ // declare global: tern, server
2
+
1
3
  var server;
2
4
 
3
5
  this.onmessage = function(e) {
@@ -353,7 +353,7 @@
353
353
  },
354
354
 
355
355
  "Ctrl-S": "save", "Ctrl-W": "save", "S": "saveAll", "F": "open", "U": repeated("undo"), "K": "close",
356
- "Delete": function(cm) { kill(cm, cm.getCursor(), sentenceEnd(cm, 1), true); },
356
+ "Delete": function(cm) { kill(cm, cm.getCursor(), bySentence(cm, cm.getCursor(), 1), true); },
357
357
  auto: "emacs", nofallthrough: true, disableInput: true
358
358
  };
359
359
 
@@ -297,7 +297,7 @@ CodeMirror.defineMode("haxe", function(config, parserConfig) {
297
297
  function metadef(type) {
298
298
  if(type == ":") return cont(metadef);
299
299
  if(type == "variable") return cont(metadef);
300
- if(type == "(") return cont(pushlex(")"), comasep(metaargs, ")"), poplex, statement);
300
+ if(type == "(") return cont(pushlex(")"), commasep(metaargs, ")"), poplex, statement);
301
301
  }
302
302
  function metaargs(type) {
303
303
  if(type == "variable") return cont();
@@ -355,12 +355,14 @@ CodeMirror.defineMode("python", function(conf, parserConf) {
355
355
 
356
356
  CodeMirror.defineMIME("text/x-python", "python");
357
357
 
358
- var words = function(str){return str.split(' ');};
359
-
360
-
361
- CodeMirror.defineMIME("text/x-cython", {
362
- name: "python",
363
- extra_keywords: words("by cdef cimport cpdef ctypedef enum except"+
364
- "extern gil include nogil property public"+
365
- "readonly struct union DEF IF ELIF ELSE")
366
- });
358
+ (function() {
359
+ "use strict";
360
+ var words = function(str){return str.split(' ');};
361
+
362
+ CodeMirror.defineMIME("text/x-cython", {
363
+ name: "python",
364
+ extra_keywords: words("by cdef cimport cpdef ctypedef enum except"+
365
+ "extern gil include nogil property public"+
366
+ "readonly struct union DEF IF ELIF ELSE")
367
+ });
368
+ })();
@@ -1,25 +1,3 @@
1
- /*
2
- Copyright (C) 2011 by MarkLogic Corporation
3
- Author: Mike Brevoort <mike@brevoort.com>
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in
13
- all copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
- THE SOFTWARE.
22
- */
23
1
  CodeMirror.defineMode("xquery", function() {
24
2
 
25
3
  // The keywords object is set to the result of this self executing
@@ -348,7 +326,7 @@ CodeMirror.defineMode("xquery", function() {
348
326
  return chain(stream, state, tokenString(ch, tokenAttribute));
349
327
 
350
328
  if(!isInXmlAttributeBlock(state))
351
- pushStateStack(state, { type: "attribute", name: name, tokenize: tokenAttribute});
329
+ pushStateStack(state, { type: "attribute", tokenize: tokenAttribute});
352
330
 
353
331
  stream.eat(/[a-zA-Z_:]/);
354
332
  stream.eatWhile(/[-a-zA-Z0-9_:.]/);
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: '3.17'
4
+ version: '3.18'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Fixler