mirror of
https://github.com/linuxserver/core.git
synced 2026-02-20 05:07:19 +08:00
fix quote pairing for "\n"
This commit is contained in:
parent
ad38f83962
commit
3962a9c04f
10
node_modules/ace/lib/ace/mode/behaviour/behaviour_test.js
generated
vendored
10
node_modules/ace/lib/ace/mode/behaviour/behaviour_test.js
generated
vendored
@ -144,6 +144,16 @@ module.exports = {
|
||||
exec("selectleft", 1);
|
||||
exec("insertstring", 1, '"');
|
||||
assert.equal(editor.getValue(), '("foo")');
|
||||
|
||||
editor.setValue("", 1);
|
||||
exec("selectleft", 1);
|
||||
exec("insertstring", 1, '"');
|
||||
assert.equal(editor.getValue(), '""');
|
||||
exec("insertstring", 1, '\\');
|
||||
exec("insertstring", 1, 'n');
|
||||
exec("insertstring", 1, '"');
|
||||
assert.equal(editor.getValue(), '"\\n"');
|
||||
|
||||
},
|
||||
"test: xml": function() {
|
||||
editor = new Editor(new MockRenderer());
|
||||
|
||||
4
node_modules/ace/lib/ace/mode/behaviour/cstyle.js
generated
vendored
4
node_modules/ace/lib/ace/mode/behaviour/cstyle.js
generated
vendored
@ -269,8 +269,8 @@ var CstyleBehaviour = function() {
|
||||
if (leftChar == "\\" && token && /escape/.test(token.type))
|
||||
return null;
|
||||
|
||||
var stringBefore = token && /string/.test(token.type);
|
||||
var stringAfter = !rightToken || /string/.test(rightToken.type);
|
||||
var stringBefore = token && /string|escape/.test(token.type);
|
||||
var stringAfter = !rightToken || /string|escape/.test(rightToken.type);
|
||||
|
||||
var pair;
|
||||
if (rightChar == quote) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user