mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-20 02:08:47 +00:00
TypeScript restrict Comment onEnterRules inside comment body (#251692)
* TypeScript: Restrict Comment onEnterRules cursor inside comment body * TypeScript: Simply Comment onEnterRule * polish --------- Co-authored-by: Aiday Marlen Kyzy <amarlenkyzy@microsoft.com>
This commit is contained in:
@@ -230,12 +230,8 @@
|
||||
},
|
||||
// Add // when pressing enter from inside line comment
|
||||
{
|
||||
"beforeText": {
|
||||
"pattern": "(?<!\\\\)(?<!\\w:)\/\/.*"
|
||||
},
|
||||
"afterText": {
|
||||
"pattern": "^(?!\\s*$).+"
|
||||
},
|
||||
"beforeText": "(?<!\\\\|\\w:)\/\/\\s*\\S",
|
||||
"afterText": "^(?!\\s*$).+",
|
||||
"action": {
|
||||
"indent": "none",
|
||||
"appendText": "// "
|
||||
|
||||
@@ -248,12 +248,8 @@
|
||||
},
|
||||
// Add // when pressing enter from inside line comment
|
||||
{
|
||||
"beforeText": {
|
||||
"pattern": "(?<!\\\\)(?<!\\w:)\/\/.*"
|
||||
},
|
||||
"afterText": {
|
||||
"pattern": "^(?!\\s*$).+"
|
||||
},
|
||||
"beforeText": "(?<!\\\\|\\w:)\/\/\\s*\\S",
|
||||
"afterText": "^(?!\\s*$).+",
|
||||
"action": {
|
||||
"indent": "none",
|
||||
"appendText": "// "
|
||||
|
||||
Reference in New Issue
Block a user