forked from forgejo/forgejo
Update CodeMirror to version 5.49.0 (#8381)
* Update CodeMirror to version 5.49.0 * Update CodeMirror versions in librejs and VERSIONS
This commit is contained in:
parent
6fa14ac3c8
commit
1e9b330525
352 changed files with 14625 additions and 2451 deletions
|
@ -1,5 +1,5 @@
|
|||
// CodeMirror, copyright (c) by Marijn Haverbeke and others
|
||||
// Distributed under an MIT license: http://codemirror.net/LICENSE
|
||||
// Distributed under an MIT license: https://codemirror.net/LICENSE
|
||||
|
||||
(function(mod) {
|
||||
if (typeof exports == "object" && typeof module == "object") // CommonJS
|
||||
|
@ -12,8 +12,8 @@
|
|||
"use strict";
|
||||
|
||||
var keywords = ("this super static final const abstract class extends external factory " +
|
||||
"implements get native operator set typedef with enum throw rethrow " +
|
||||
"assert break case continue default in return new deferred async await " +
|
||||
"implements mixin get native set typedef with enum throw rethrow " +
|
||||
"assert break case continue default in return new deferred async await covariant " +
|
||||
"try catch finally do else for if switch while import library export " +
|
||||
"part of show hide is as").split(" ");
|
||||
var blockKeywords = "try catch finally do else for if switch while".split(" ");
|
||||
|
@ -78,6 +78,15 @@
|
|||
if (!stream.eat("*")) return false
|
||||
state.tokenize = tokenNestedComment(1)
|
||||
return state.tokenize(stream, state)
|
||||
},
|
||||
token: function(stream, _, style) {
|
||||
if (style == "variable") {
|
||||
// Assume uppercase symbols are classes using variable-2
|
||||
var isUpper = RegExp('^[_$]*[A-Z][a-zA-Z0-9_$]*$','g');
|
||||
if (isUpper.test(stream.current())) {
|
||||
return 'variable-2';
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<script src="dart.js"></script>
|
||||
<style>.CodeMirror {border: 1px solid #dee;}</style>
|
||||
<div id=nav>
|
||||
<a href="http://codemirror.net"><h1>CodeMirror</h1><img id=logo src="../../doc/logo.png"></a>
|
||||
<a href="https://codemirror.net"><h1>CodeMirror</h1><img id=logo src="../../doc/logo.png"></a>
|
||||
|
||||
<ul>
|
||||
<li><a href="../../index.html">Home</a>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue