Update ACE Editor to version 1.2.9
The new ACE editor introduces full support for emojis (and, thereby, UTF-16 characters with high- and low-surrogates). Hence, we can remove our custom fix. Further, this update will allow emojis to be used in pair programming sessions.
This commit is contained in:
22
vendor/assets/javascripts/ace/mode-elm.js
vendored
22
vendor/assets/javascripts/ace/mode-elm.js
vendored
@@ -15,7 +15,7 @@ var ElmHighlightRules = function() {
|
||||
|
||||
var smallRe = /[a-z_]/.source;
|
||||
var largeRe = /[A-Z]/.source;
|
||||
var idRe = /[a-z_A-Z0-9\']/.source;
|
||||
var idRe = /[a-z_A-Z0-9']/.source;
|
||||
|
||||
this.$rules = {
|
||||
start: [{
|
||||
@@ -28,9 +28,12 @@ var ElmHighlightRules = function() {
|
||||
}, {
|
||||
regex: /0(?:[xX][0-9A-Fa-f]+|[oO][0-7]+)|\d+(\.\d+)?([eE][-+]?\d*)?/,
|
||||
token: "constant.numeric"
|
||||
}, {
|
||||
token: "comment",
|
||||
regex: "--.*"
|
||||
}, {
|
||||
token : "keyword",
|
||||
regex : /\.\.|\||:|=|\\|\"|->|<-|\u2192/
|
||||
regex : /\.\.|\||:|=|\\|"|->|<-|\u2192/
|
||||
}, {
|
||||
token : "keyword.operator",
|
||||
regex : /[-!#$%&*+.\/<=>?@\\^|~:\u03BB\u2192]+/
|
||||
@@ -69,7 +72,7 @@ var ElmHighlightRules = function() {
|
||||
}, {
|
||||
token: "paren.rparen",
|
||||
regex: /[\])}]/
|
||||
}, ],
|
||||
} ],
|
||||
markdown: [{
|
||||
regex: /\|\]/,
|
||||
next: "start"
|
||||
@@ -100,7 +103,7 @@ var ElmHighlightRules = function() {
|
||||
}],
|
||||
string: [{
|
||||
token: "constant.language.escape",
|
||||
regex: escapeRe,
|
||||
regex: escapeRe
|
||||
}, {
|
||||
token: "text",
|
||||
regex: /\\(\s|$)/,
|
||||
@@ -109,6 +112,8 @@ var ElmHighlightRules = function() {
|
||||
token: "string.end",
|
||||
regex: '"',
|
||||
next: "start"
|
||||
}, {
|
||||
defaultToken: "string"
|
||||
}],
|
||||
stringGap: [{
|
||||
token: "text",
|
||||
@@ -118,7 +123,7 @@ var ElmHighlightRules = function() {
|
||||
token: "error",
|
||||
regex: "",
|
||||
next: "start"
|
||||
}],
|
||||
}]
|
||||
};
|
||||
|
||||
this.normalizeRules();
|
||||
@@ -150,8 +155,8 @@ oop.inherits(FoldMode, BaseFoldMode);
|
||||
|
||||
(function() {
|
||||
|
||||
this.foldingStartMarker = /(\{|\[)[^\}\]]*$|^\s*(\/\*)/;
|
||||
this.foldingStopMarker = /^[^\[\{]*(\}|\])|^[\s\*]*(\*\/)/;
|
||||
this.foldingStartMarker = /([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/;
|
||||
this.foldingStopMarker = /^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/;
|
||||
this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
|
||||
this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
|
||||
this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
|
||||
@@ -280,12 +285,13 @@ var FoldMode = require("./folding/cstyle").FoldMode;
|
||||
var Mode = function() {
|
||||
this.HighlightRules = HighlightRules;
|
||||
this.foldingRules = new FoldMode();
|
||||
this.$behaviour = this.$defaultBehaviour;
|
||||
};
|
||||
oop.inherits(Mode, TextMode);
|
||||
|
||||
(function() {
|
||||
this.lineCommentStart = "--";
|
||||
this.blockComment = {start: "{-", end: "-}"};
|
||||
this.blockComment = {start: "{-", end: "-}", nestable: true};
|
||||
this.$id = "ace/mode/elm";
|
||||
}).call(Mode.prototype);
|
||||
|
||||
|
Reference in New Issue
Block a user