Update vendors
This commit is contained in:
parent
c4af63237c
commit
53d130a179
|
@ -7,7 +7,7 @@
|
|||
"author": "Stylus Team",
|
||||
"devDependencies": {
|
||||
"archiver": "^3.0.0",
|
||||
"codemirror": "^5.41.0",
|
||||
"codemirror": "^5.42.0",
|
||||
"dropbox": "^4.0.13",
|
||||
"endent": "^1.2.0",
|
||||
"eslint": "^5.9.0",
|
||||
|
@ -19,8 +19,8 @@
|
|||
"semver-bundle": "^0.1.1",
|
||||
"stylelint-bundle": "^8.0.0",
|
||||
"stylus-lang-bundle": "^0.54.5",
|
||||
"updates": "^5.1.2",
|
||||
"usercss-meta": "^0.8.4",
|
||||
"updates": "^5.4.2",
|
||||
"usercss-meta": "^0.9.0",
|
||||
"web-ext": "^2.9.2",
|
||||
"webext-tx-fix": "^0.3.1",
|
||||
"zipjs-browserify": "^1.0.1"
|
||||
|
|
2
vendor/codemirror/README.md
vendored
2
vendor/codemirror/README.md
vendored
|
@ -1,3 +1,3 @@
|
|||
## CodeMirror v5.41.0
|
||||
## CodeMirror v5.42.0
|
||||
|
||||
Only files & folders that exist in the `vendor/codemirror` folder are copied from the `node_modules/codemirror` folder. Except all theme files are copied, in case new themes have been added.
|
||||
|
|
16
vendor/codemirror/addon/hint/show-hint.js
vendored
16
vendor/codemirror/addon/hint/show-hint.js
vendored
|
@ -198,20 +198,22 @@
|
|||
this.data = data;
|
||||
this.picked = false;
|
||||
var widget = this, cm = completion.cm;
|
||||
var ownerDocument = cm.getInputField().ownerDocument;
|
||||
var parentWindow = ownerDocument.defaultView || ownerDocument.parentWindow;
|
||||
|
||||
var hints = this.hints = document.createElement("ul");
|
||||
var hints = this.hints = ownerDocument.createElement("ul");
|
||||
var theme = completion.cm.options.theme;
|
||||
hints.className = "CodeMirror-hints " + theme;
|
||||
this.selectedHint = data.selectedHint || 0;
|
||||
|
||||
var completions = data.list;
|
||||
for (var i = 0; i < completions.length; ++i) {
|
||||
var elt = hints.appendChild(document.createElement("li")), cur = completions[i];
|
||||
var elt = hints.appendChild(ownerDocument.createElement("li")), cur = completions[i];
|
||||
var className = HINT_ELEMENT_CLASS + (i != this.selectedHint ? "" : " " + ACTIVE_HINT_ELEMENT_CLASS);
|
||||
if (cur.className != null) className = cur.className + " " + className;
|
||||
elt.className = className;
|
||||
if (cur.render) cur.render(elt, data, cur);
|
||||
else elt.appendChild(document.createTextNode(cur.displayText || getText(cur)));
|
||||
else elt.appendChild(ownerDocument.createTextNode(cur.displayText || getText(cur)));
|
||||
elt.hintId = i;
|
||||
}
|
||||
|
||||
|
@ -220,9 +222,9 @@
|
|||
hints.style.left = left + "px";
|
||||
hints.style.top = top + "px";
|
||||
// If we're at the edge of the screen, then we want the menu to appear on the left of the cursor.
|
||||
var winW = window.innerWidth || Math.max(document.body.offsetWidth, document.documentElement.offsetWidth);
|
||||
var winH = window.innerHeight || Math.max(document.body.offsetHeight, document.documentElement.offsetHeight);
|
||||
(completion.options.container || document.body).appendChild(hints);
|
||||
var winW = parentWindow.innerWidth || Math.max(ownerDocument.body.offsetWidth, ownerDocument.documentElement.offsetWidth);
|
||||
var winH = parentWindow.innerHeight || Math.max(ownerDocument.body.offsetHeight, ownerDocument.documentElement.offsetHeight);
|
||||
(completion.options.container || ownerDocument.body).appendChild(hints);
|
||||
var box = hints.getBoundingClientRect(), overlapY = box.bottom - winH;
|
||||
var scrolls = hints.scrollHeight > hints.clientHeight + 1
|
||||
var startScroll = cm.getScrollInfo();
|
||||
|
@ -273,7 +275,7 @@
|
|||
cm.on("scroll", this.onScroll = function() {
|
||||
var curScroll = cm.getScrollInfo(), editor = cm.getWrapperElement().getBoundingClientRect();
|
||||
var newTop = top + startScroll.top - curScroll.top;
|
||||
var point = newTop - (window.pageYOffset || (document.documentElement || document.body).scrollTop);
|
||||
var point = newTop - (parentWindow.pageYOffset || (ownerDocument.documentElement || ownerDocument.body).scrollTop);
|
||||
if (!below) point += hints.offsetHeight;
|
||||
if (point <= editor.top || point >= editor.bottom) return completion.close();
|
||||
hints.style.top = newTop + "px";
|
||||
|
|
5
vendor/codemirror/keymap/vim.js
vendored
5
vendor/codemirror/keymap/vim.js
vendored
|
@ -132,6 +132,7 @@
|
|||
{ keys: 'd', type: 'operator', operator: 'delete' },
|
||||
{ keys: 'y', type: 'operator', operator: 'yank' },
|
||||
{ keys: 'c', type: 'operator', operator: 'change' },
|
||||
{ keys: '=', type: 'operator', operator: 'indentAuto' },
|
||||
{ keys: '>', type: 'operator', operator: 'indent', operatorArgs: { indentRight: true }},
|
||||
{ keys: '<', type: 'operator', operator: 'indent', operatorArgs: { indentRight: false }},
|
||||
{ keys: 'g~', type: 'operator', operator: 'changeCase' },
|
||||
|
@ -2188,6 +2189,10 @@
|
|||
}
|
||||
return motions.moveToFirstNonWhiteSpaceCharacter(cm, ranges[0].anchor);
|
||||
},
|
||||
indentAuto: function(cm, _args, ranges) {
|
||||
cm.execCommand("indentAuto");
|
||||
return motions.moveToFirstNonWhiteSpaceCharacter(cm, ranges[0].anchor);
|
||||
},
|
||||
changeCase: function(cm, args, ranges, oldAnchor, newHead) {
|
||||
var selections = cm.getSelections();
|
||||
var swapped = [];
|
||||
|
|
55
vendor/codemirror/lib/codemirror.js
vendored
55
vendor/codemirror/lib/codemirror.js
vendored
|
@ -1878,7 +1878,7 @@
|
|||
|
||||
// Build up the DOM representation for a single token, and add it to
|
||||
// the line map. Takes care to render special characters separately.
|
||||
function buildToken(builder, text, style, startStyle, endStyle, title, css) {
|
||||
function buildToken(builder, text, style, startStyle, endStyle, css, attributes) {
|
||||
if (!text) { return }
|
||||
var displayText = builder.splitSpaces ? splitSpaces(text, builder.trailingSpace) : text;
|
||||
var special = builder.cm.state.specialChars, mustWrap = false;
|
||||
|
@ -1934,7 +1934,10 @@
|
|||
if (startStyle) { fullStyle += startStyle; }
|
||||
if (endStyle) { fullStyle += endStyle; }
|
||||
var token = elt("span", [content], fullStyle, css);
|
||||
if (title) { token.title = title; }
|
||||
if (attributes) {
|
||||
for (var attr in attributes) { if (attributes.hasOwnProperty(attr) && attr != "style" && attr != "class")
|
||||
{ token.setAttribute(attr, attributes[attr]); } }
|
||||
}
|
||||
return builder.content.appendChild(token)
|
||||
}
|
||||
builder.content.appendChild(content);
|
||||
|
@ -1958,7 +1961,7 @@
|
|||
// Work around nonsense dimensions being reported for stretches of
|
||||
// right-to-left text.
|
||||
function buildTokenBadBidi(inner, order) {
|
||||
return function (builder, text, style, startStyle, endStyle, title, css) {
|
||||
return function (builder, text, style, startStyle, endStyle, css, attributes) {
|
||||
style = style ? style + " cm-force-border" : "cm-force-border";
|
||||
var start = builder.pos, end = start + text.length;
|
||||
for (;;) {
|
||||
|
@ -1968,8 +1971,8 @@
|
|||
part = order[i];
|
||||
if (part.to > start && part.from <= start) { break }
|
||||
}
|
||||
if (part.to >= end) { return inner(builder, text, style, startStyle, endStyle, title, css) }
|
||||
inner(builder, text.slice(0, part.to - start), style, startStyle, null, title, css);
|
||||
if (part.to >= end) { return inner(builder, text, style, startStyle, endStyle, css, attributes) }
|
||||
inner(builder, text.slice(0, part.to - start), style, startStyle, null, css, attributes);
|
||||
startStyle = null;
|
||||
text = text.slice(part.to - start);
|
||||
start = part.to;
|
||||
|
@ -2004,10 +2007,11 @@
|
|||
}
|
||||
|
||||
var len = allText.length, pos = 0, i = 1, text = "", style, css;
|
||||
var nextChange = 0, spanStyle, spanEndStyle, spanStartStyle, title, collapsed;
|
||||
var nextChange = 0, spanStyle, spanEndStyle, spanStartStyle, collapsed, attributes;
|
||||
for (;;) {
|
||||
if (nextChange == pos) { // Update current marker set
|
||||
spanStyle = spanEndStyle = spanStartStyle = title = css = "";
|
||||
spanStyle = spanEndStyle = spanStartStyle = css = "";
|
||||
attributes = null;
|
||||
collapsed = null; nextChange = Infinity;
|
||||
var foundBookmarks = [], endStyles = (void 0);
|
||||
for (var j = 0; j < spans.length; ++j) {
|
||||
|
@ -2023,7 +2027,13 @@
|
|||
if (m.css) { css = (css ? css + ";" : "") + m.css; }
|
||||
if (m.startStyle && sp.from == pos) { spanStartStyle += " " + m.startStyle; }
|
||||
if (m.endStyle && sp.to == nextChange) { (endStyles || (endStyles = [])).push(m.endStyle, sp.to); }
|
||||
if (m.title && !title) { title = m.title; }
|
||||
// support for the old title property
|
||||
// https://github.com/codemirror/CodeMirror/pull/5673
|
||||
if (m.title) { (attributes || (attributes = {})).title = m.title; }
|
||||
if (m.attributes) {
|
||||
for (var attr in m.attributes)
|
||||
{ (attributes || (attributes = {}))[attr] = m.attributes[attr]; }
|
||||
}
|
||||
if (m.collapsed && (!collapsed || compareCollapsedMarkers(collapsed.marker, m) < 0))
|
||||
{ collapsed = sp; }
|
||||
} else if (sp.from > pos && nextChange > sp.from) {
|
||||
|
@ -2051,7 +2061,7 @@
|
|||
if (!collapsed) {
|
||||
var tokenText = end > upto ? text.slice(0, upto - pos) : text;
|
||||
builder.addToken(builder, tokenText, style ? style + spanStyle : spanStyle,
|
||||
spanStartStyle, pos + tokenText.length == nextChange ? spanEndStyle : "", title, css);
|
||||
spanStartStyle, pos + tokenText.length == nextChange ? spanEndStyle : "", css, attributes);
|
||||
}
|
||||
if (end >= upto) {text = text.slice(upto - pos); pos = upto; break}
|
||||
pos = end;
|
||||
|
@ -3260,7 +3270,8 @@
|
|||
var display = cm.display;
|
||||
var prevBottom = display.lineDiv.offsetTop;
|
||||
for (var i = 0; i < display.view.length; i++) {
|
||||
var cur = display.view[i], height = (void 0);
|
||||
var cur = display.view[i], wrapping = cm.options.lineWrapping;
|
||||
var height = (void 0), width = 0;
|
||||
if (cur.hidden) { continue }
|
||||
if (ie && ie_version < 8) {
|
||||
var bot = cur.node.offsetTop + cur.node.offsetHeight;
|
||||
|
@ -3269,6 +3280,10 @@
|
|||
} else {
|
||||
var box = cur.node.getBoundingClientRect();
|
||||
height = box.bottom - box.top;
|
||||
// Check that lines don't extend past the right of the current
|
||||
// editor width
|
||||
if (!wrapping && cur.text.firstChild)
|
||||
{ width = cur.text.firstChild.getBoundingClientRect().right - box.left - 1; }
|
||||
}
|
||||
var diff = cur.line.height - height;
|
||||
if (height < 2) { height = textHeight(display); }
|
||||
|
@ -3278,6 +3293,14 @@
|
|||
if (cur.rest) { for (var j = 0; j < cur.rest.length; j++)
|
||||
{ updateWidgetHeight(cur.rest[j]); } }
|
||||
}
|
||||
if (width > cm.display.sizerWidth) {
|
||||
var chWidth = Math.ceil(width / charWidth(cm.display));
|
||||
if (chWidth > cm.display.maxLineLength) {
|
||||
cm.display.maxLineLength = chWidth;
|
||||
cm.display.maxLine = cur.line;
|
||||
cm.display.maxLineChanged = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -5944,7 +5967,8 @@
|
|||
if (updateMaxLine) { cm.curOp.updateMaxLine = true; }
|
||||
if (marker.collapsed)
|
||||
{ regChange(cm, from.line, to.line + 1); }
|
||||
else if (marker.className || marker.title || marker.startStyle || marker.endStyle || marker.css)
|
||||
else if (marker.className || marker.startStyle || marker.endStyle || marker.css ||
|
||||
marker.attributes || marker.title)
|
||||
{ for (var i = from.line; i <= to.line; i++) { regLineChange(cm, i, "text"); } }
|
||||
if (marker.atomic) { reCheckSelection(cm.doc); }
|
||||
signalLater(cm, "markerAdded", cm, marker);
|
||||
|
@ -6562,11 +6586,14 @@
|
|||
|
||||
function forEachCodeMirror(f) {
|
||||
if (!document.getElementsByClassName) { return }
|
||||
var byClass = document.getElementsByClassName("CodeMirror");
|
||||
var byClass = document.getElementsByClassName("CodeMirror"), editors = [];
|
||||
for (var i = 0; i < byClass.length; i++) {
|
||||
var cm = byClass[i].CodeMirror;
|
||||
if (cm) { f(cm); }
|
||||
if (cm) { editors.push(cm); }
|
||||
}
|
||||
if (editors.length) { editors[0].operation(function () {
|
||||
for (var i = 0; i < editors.length; i++) { f(editors[i]); }
|
||||
}); }
|
||||
}
|
||||
|
||||
var globalsRegistered = false;
|
||||
|
@ -9691,7 +9718,7 @@
|
|||
|
||||
addLegacyProps(CodeMirror);
|
||||
|
||||
CodeMirror.version = "5.41.0";
|
||||
CodeMirror.version = "5.42.0";
|
||||
|
||||
return CodeMirror;
|
||||
|
||||
|
|
|
@ -655,6 +655,7 @@ CodeMirror.defineMode("javascript", function(config, parserConfig) {
|
|||
if (type == "variable") cx.marked = "property";
|
||||
if (type == "spread") return cont(pattern);
|
||||
if (type == "}") return pass();
|
||||
if (type == "[") return cont(expression, expect(']'), expect(':'), proppattern);
|
||||
return cont(expect(":"), pattern, maybeAssign);
|
||||
}
|
||||
function eltpattern() {
|
||||
|
|
51
vendor/codemirror/theme/darcula.css
vendored
51
vendor/codemirror/theme/darcula.css
vendored
|
@ -1,46 +1,51 @@
|
|||
/**
|
||||
Name: IntelliJ IDEA darcula theme
|
||||
Name: IntelliJ IDEA darcula theme
|
||||
From IntelliJ IDEA by JetBrains
|
||||
*/
|
||||
|
||||
.cm-s-darcula { font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif;}
|
||||
.cm-s-darcula.CodeMirror { background: #2B2B2B; color: #A9B7C6; }
|
||||
|
||||
.cm-s-darcula span.cm-meta { color: #BBB529; }
|
||||
.cm-s-darcula span.cm-number { color: #6897BB; }
|
||||
.cm-s-darcula span.cm-keyword { line-height: 1em; font-weight: bold; color: #CC7832; }
|
||||
.cm-s-darcula span.cm-def { color: #FFC66D; }
|
||||
.cm-s-darcula span.cm-keyword { color: #CC7832; line-height: 1em; font-weight: bold; }
|
||||
.cm-s-darcula span.cm-def { color: #A9B7C6; font-style: italic; }
|
||||
.cm-s-darcula span.cm-variable { color: #A9B7C6; }
|
||||
.cm-s-darcula span.cm-variable-2 { color: #A9B7C6; }
|
||||
.cm-s-darcula span.cm-variable-3, .cm-s-darcula span.cm-type { color: #A9B7C6; }
|
||||
.cm-s-darcula span.cm-property { color: #A9B7C6; }
|
||||
.cm-s-darcula span.cm-variable-3 { color: #9876AA; }
|
||||
.cm-s-darcula span.cm-type { color: #AABBCC; font-weight: bold; }
|
||||
.cm-s-darcula span.cm-property { color: #FFC66D; }
|
||||
.cm-s-darcula span.cm-operator { color: #A9B7C6; }
|
||||
.cm-s-darcula span.cm-string { color: #6A8759; }
|
||||
.cm-s-darcula span.cm-string-2 { color: #6A8759; }
|
||||
.cm-s-darcula span.cm-comment { color: #808080; }
|
||||
.cm-s-darcula span.cm-link { color: #287BDE; }
|
||||
.cm-s-darcula span.cm-atom { font-weight: bold; color: #CC7832; }
|
||||
.cm-s-darcula span.cm-comment { color: #61A151; font-style: italic; }
|
||||
.cm-s-darcula span.cm-link { color: #CC7832; }
|
||||
.cm-s-darcula span.cm-atom { color: #CC7832; }
|
||||
.cm-s-darcula span.cm-error { color: #BC3F3C; }
|
||||
.cm-s-darcula span.cm-tag { color: #CC7832; }
|
||||
.cm-s-darcula span.cm-attribute { color: #6A8759; }
|
||||
.cm-s-darcula span.cm-tag { color: #629755; font-weight: bold; font-style: italic; text-decoration: underline; }
|
||||
.cm-s-darcula span.cm-attribute { color: #6897bb; }
|
||||
.cm-s-darcula span.cm-qualifier { color: #6A8759; }
|
||||
.cm-s-darcula span.cm-bracket { color: #A9B7C6; }
|
||||
.cm-s-darcula.CodeMirror { background: #2B2B2B; color: #A9B7C6; }
|
||||
.cm-s-darcula span.cm-builtin { color: #FF9E59; }
|
||||
.cm-s-darcula span.cm-special { color: #FF9E59; }
|
||||
|
||||
.cm-s-darcula .CodeMirror-cursor { border-left: 1px solid #A9B7C6; }
|
||||
.cm-s-darcula .CodeMirror-activeline-background { background: #323232; }
|
||||
.cm-s-darcula .CodeMirror-gutters { background: #313335; border-right: 1px solid #313335; }
|
||||
.cm-s-darcula .CodeMirror-guttermarker { color: #FFEE80; }
|
||||
.cm-s-darcula .CodeMirror-guttermarker-subtle { color: #D0D0D0; }
|
||||
.cm-s-darcula .CodeMirrir-linenumber { color: #606366; }
|
||||
.cm-s-darcula .CodeMirror-matchingbracket { background-color: #3B514D; color: #FFEF28 !important; font-weight: bold; }
|
||||
|
||||
.cm-s-darcula .CodeMirror-cursor { border-left: 1px solid #dddddd; }
|
||||
.cm-s-darcula .CodeMirror-activeline-background { background: #3A3A3A; }
|
||||
.cm-s-darcula div.CodeMirror-selected { background: #085a9c; }
|
||||
.cm-s-darcula .CodeMirror-gutters { background: rgb(72, 72, 72); border-right: 1px solid grey; color: #606366 }
|
||||
|
||||
.cm-s-darcula span.cm-builtin { color: #A9B7C6; }
|
||||
.cm-s-darcula { font-family: Consolas, Menlo, Monaco, Lucida Console, Liberation Mono, DejaVu Sans Mono, Bitstream Vera Sans Mono, Courier New, monospace, serif;}
|
||||
.cm-s-darcula .CodeMirror-matchingbracket { background-color: #3b514d; color: yellow !important; }
|
||||
.cm-s-darcula div.CodeMirror-selected { background: #214283; }
|
||||
|
||||
.CodeMirror-hints.darcula {
|
||||
font-family: Menlo, Monaco, Consolas, 'Courier New', monospace;
|
||||
color: #9c9e9e;
|
||||
background-color: #3b3e3f !important;
|
||||
color: #9C9E9E;
|
||||
background-color: #3B3E3F !important;
|
||||
}
|
||||
|
||||
.CodeMirror-hints.darcula .CodeMirror-hint-active {
|
||||
background-color: #494d4e !important;
|
||||
color: #9c9e9e !important;
|
||||
background-color: #494D4E !important;
|
||||
color: #9C9E9E !important;
|
||||
}
|
||||
|
|
4
vendor/usercss-meta/README.md
vendored
4
vendor/usercss-meta/README.md
vendored
|
@ -1,5 +1,5 @@
|
|||
## usercss-meta v0.8.4
|
||||
## usercss-meta v0.9.0
|
||||
|
||||
usercss-meta installed via npm - source repo:
|
||||
|
||||
https://unpkg.com/usercss-meta@0.8.4/dist/usercss-meta.min.js
|
||||
https://unpkg.com/usercss-meta@0.9.0/dist/usercss-meta.min.js
|
||||
|
|
2
vendor/usercss-meta/usercss-meta.min.js
vendored
2
vendor/usercss-meta/usercss-meta.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user