github-linguist 6.0.1 → 6.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/grammars/annotation.liquidhaskell.haskell.json +13 -4
- data/grammars/hint.haskell.json +13 -4
- data/grammars/hint.message.haskell.json +13 -4
- data/grammars/hint.type.haskell.json +13 -4
- data/grammars/source.angelscript.json +1 -1
- data/grammars/source.ballerina.json +25 -2
- data/grammars/source.batchfile.json +69 -38
- data/grammars/source.c.json +1 -1
- data/grammars/source.clarion.json +4 -4
- data/grammars/source.cs.json +3952 -780
- data/grammars/source.elixir.json +7 -7
- data/grammars/source.fortran.json +38 -35
- data/grammars/source.fortran.modern.json +6 -6
- data/grammars/source.graphql.json +55 -2
- data/grammars/source.haskell.json +13 -4
- data/grammars/source.hsig.json +13 -4
- data/grammars/source.hx.json +2309 -0
- data/grammars/source.hxml.json +37 -5
- data/grammars/source.isabelle.theory.json +7 -7
- data/grammars/source.js.json +39 -54
- data/grammars/source.js.regexp.json +11 -5
- data/grammars/source.julia.json +16 -5
- data/grammars/{source.Kotlin.json → source.kotlin.json} +118 -33
- data/grammars/source.mathematica.json +0 -1
- data/grammars/source.meson.json +4 -0
- data/grammars/source.mupad.json +36 -12
- data/grammars/source.netlinx.erb.json +1 -2
- data/grammars/source.netlinx.json +0 -3
- data/grammars/source.nextflow.json +7 -7
- data/grammars/source.perl.json +1 -1
- data/grammars/source.renpy.json +436 -648
- data/grammars/source.scala.json +133 -87
- data/grammars/source.sed.json +1520 -0
- data/grammars/source.shell.json +17 -17
- data/grammars/source.solidity.json +1 -1
- data/grammars/source.swift.json +1 -1
- data/grammars/source.terraform.json +1 -1
- data/grammars/source.ts.json +493 -122
- data/grammars/source.tsx.json +568 -191
- data/grammars/source.x86.json +295 -0
- data/grammars/source.yaml.json +41 -21
- data/grammars/source.yara.json +1 -1
- data/grammars/text.haml.json +15 -0
- data/grammars/text.html.creole.json +1 -1
- data/grammars/text.html.php.blade.json +2 -2
- data/grammars/text.html.php.json +55 -134
- data/grammars/text.html.smarty.json +25 -1
- data/grammars/text.html.vue.json +0 -6
- data/grammars/text.restructuredtext.json +110 -17
- data/grammars/text.tex.latex.haskell.json +13 -4
- data/lib/linguist/documentation.yml +1 -0
- data/lib/linguist/generated.rb +9 -1
- data/lib/linguist/heuristics.rb +2 -0
- data/lib/linguist/language.rb +0 -8
- data/lib/linguist/languages.json +1 -1
- data/lib/linguist/languages.yml +103 -7
- data/lib/linguist/linguist.bundle +0 -0
- data/lib/linguist/samples.json +1221 -262
- data/lib/linguist/shebang.rb +7 -4
- data/lib/linguist/strategy/extension.rb +15 -2
- data/lib/linguist/strategy/filename.rb +15 -2
- data/lib/linguist/vendor.yml +7 -0
- data/lib/linguist/version.rb +1 -1
- metadata +17 -19
- data/grammars/source.erazor.json +0 -118
- data/grammars/source.haxe.2.json +0 -1267
- data/grammars/source.hss.1.json +0 -442
- data/grammars/source.nmml.json +0 -81
- data/grammars/source.sbt.json +0 -39
data/grammars/source.tsx.json
CHANGED
@@ -25,7 +25,7 @@
|
|
25
25
|
},
|
26
26
|
"after-operator-block-as-object-literal": {
|
27
27
|
"name": "meta.objectliteral.tsx",
|
28
|
-
"begin": "(?\u003c=[
|
28
|
+
"begin": "(?\u003c!\\+\\+|--)(?\u003c=[:=(,\\[?+!]|^await|[^\\._$[:alnum:]]await|^return|[^\\._$[:alnum:]]return|^yield|[^\\._$[:alnum:]]yield|^throw|[^\\._$[:alnum:]]throw|^in|[^\\._$[:alnum:]]in|^of|[^\\._$[:alnum:]]of|^typeof|[^\\._$[:alnum:]]typeof|\u0026\u0026|\\|\\||\\*)\\s*(\\{)",
|
29
29
|
"end": "\\}",
|
30
30
|
"patterns": [
|
31
31
|
{
|
@@ -107,7 +107,7 @@
|
|
107
107
|
},
|
108
108
|
{
|
109
109
|
"name": "meta.arrow.tsx",
|
110
|
-
"begin": "(?x) (?:\n (?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(\\basync)\n)? ((?\u003c![})!\\]])\\s*\n (?=\n # sure shot arrow functions even if =\u003e is on new line\n(\n [(]\\s*\n (\n ([)]\\s*:) |
|
110
|
+
"begin": "(?x) (?:\n (?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(\\basync)\n)? ((?\u003c![})!\\]])\\s*\n (?=\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n )\n)",
|
111
111
|
"end": "(?==\u003e|\\{|(^\\s*(export|function|class|interface|let|var|const|import|enum|namespace|module|type|abstract|declare)\\s+))",
|
112
112
|
"patterns": [
|
113
113
|
{
|
@@ -153,6 +153,18 @@
|
|
153
153
|
"name": "meta.return.type.arrow.tsx",
|
154
154
|
"begin": "(?\u003c=\\))\\s*(:)",
|
155
155
|
"end": "(?==\u003e|\\{|(^\\s*(export|function|class|interface|let|var|const|import|enum|namespace|module|type|abstract|declare)\\s+))",
|
156
|
+
"patterns": [
|
157
|
+
{
|
158
|
+
"include": "#arrow-return-type-body"
|
159
|
+
}
|
160
|
+
],
|
161
|
+
"beginCaptures": {
|
162
|
+
"1": {
|
163
|
+
"name": "keyword.operator.type.annotation.tsx"
|
164
|
+
}
|
165
|
+
}
|
166
|
+
},
|
167
|
+
"arrow-return-type-body": {
|
156
168
|
"patterns": [
|
157
169
|
{
|
158
170
|
"begin": "(?\u003c=[:])(?=\\s*\\{)",
|
@@ -169,12 +181,11 @@
|
|
169
181
|
{
|
170
182
|
"include": "#type"
|
171
183
|
}
|
172
|
-
]
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
}
|
184
|
+
]
|
185
|
+
},
|
186
|
+
"async-modifier": {
|
187
|
+
"name": "storage.modifier.async.tsx",
|
188
|
+
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(async)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))"
|
178
189
|
},
|
179
190
|
"binding-element": {
|
180
191
|
"patterns": [
|
@@ -330,6 +341,9 @@
|
|
330
341
|
{
|
331
342
|
"include": "#property-accessor"
|
332
343
|
},
|
344
|
+
{
|
345
|
+
"include": "#async-modifier"
|
346
|
+
},
|
333
347
|
{
|
334
348
|
"include": "#after-operator-block-as-object-literal"
|
335
349
|
},
|
@@ -1157,7 +1171,7 @@
|
|
1157
1171
|
{
|
1158
1172
|
"name": "meta.export.default.tsx",
|
1159
1173
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(export)(?:(?:\\s*(=))|(?:\\s+(default)(?=\\s+)))",
|
1160
|
-
"end": "(
|
1174
|
+
"end": "(?=$|;|\\babstract\\b|\\basync\\b|\\bclass\\b|\\bconst\\b|\\bdeclare\\b|\\benum\\b|\\bexport\\b|\\bfunction\\b|\\bimport\\b|\\binterface\\b|\\blet\\b|\\bmodule\\b|\\bnamespace\\b|\\breturn\\b|\\btype\\b|\\bvar\\b)",
|
1161
1175
|
"patterns": [
|
1162
1176
|
{
|
1163
1177
|
"include": "#expression"
|
@@ -1178,7 +1192,7 @@
|
|
1178
1192
|
{
|
1179
1193
|
"name": "meta.export.tsx",
|
1180
1194
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(export)(?!\\s*:)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))",
|
1181
|
-
"end": "(
|
1195
|
+
"end": "(?=$|;|\\babstract\\b|\\basync\\b|\\bclass\\b|\\bconst\\b|\\bdeclare\\b|\\benum\\b|\\bexport\\b|\\bfunction\\b|\\bimport\\b|\\binterface\\b|\\blet\\b|\\bmodule\\b|\\bnamespace\\b|\\breturn\\b|\\btype\\b|\\bvar\\b)",
|
1182
1196
|
"patterns": [
|
1183
1197
|
{
|
1184
1198
|
"include": "#import-export-declaration"
|
@@ -1205,12 +1219,47 @@
|
|
1205
1219
|
}
|
1206
1220
|
]
|
1207
1221
|
},
|
1222
|
+
"expression-inside-possibly-arrow-parens": {
|
1223
|
+
"patterns": [
|
1224
|
+
{
|
1225
|
+
"include": "#expressionWithoutIdentifiers"
|
1226
|
+
},
|
1227
|
+
{
|
1228
|
+
"include": "#function-parameters-body"
|
1229
|
+
},
|
1230
|
+
{
|
1231
|
+
"include": "#identifiers"
|
1232
|
+
},
|
1233
|
+
{
|
1234
|
+
"include": "#expressionPunctuations"
|
1235
|
+
}
|
1236
|
+
]
|
1237
|
+
},
|
1208
1238
|
"expression-operators": {
|
1209
1239
|
"patterns": [
|
1210
1240
|
{
|
1211
1241
|
"name": "keyword.control.flow.tsx",
|
1212
1242
|
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(await)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))"
|
1213
1243
|
},
|
1244
|
+
{
|
1245
|
+
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(yield)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))(?=\\s*\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*\\*)",
|
1246
|
+
"end": "\\*",
|
1247
|
+
"patterns": [
|
1248
|
+
{
|
1249
|
+
"include": "#comment"
|
1250
|
+
}
|
1251
|
+
],
|
1252
|
+
"beginCaptures": {
|
1253
|
+
"1": {
|
1254
|
+
"name": "keyword.control.flow.tsx"
|
1255
|
+
}
|
1256
|
+
},
|
1257
|
+
"endCaptures": {
|
1258
|
+
"0": {
|
1259
|
+
"name": "keyword.generator.asterisk.tsx"
|
1260
|
+
}
|
1261
|
+
}
|
1262
|
+
},
|
1214
1263
|
{
|
1215
1264
|
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(yield)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))(?:\\s*(\\*))?",
|
1216
1265
|
"captures": {
|
@@ -1312,7 +1361,7 @@
|
|
1312
1361
|
"match": "%|\\*|/|-|\\+"
|
1313
1362
|
},
|
1314
1363
|
{
|
1315
|
-
"match": "(?\u003c=[_$[:alnum:])])\\s*(/)(?![/*])",
|
1364
|
+
"match": "(?\u003c=[_$[:alnum:])\\]])\\s*(/)(?![/*])",
|
1316
1365
|
"captures": {
|
1317
1366
|
"1": {
|
1318
1367
|
"name": "keyword.operator.arithmetic.tsx"
|
@@ -1357,6 +1406,9 @@
|
|
1357
1406
|
{
|
1358
1407
|
"include": "#arrow-function"
|
1359
1408
|
},
|
1409
|
+
{
|
1410
|
+
"include": "#paren-expression-possibly-arrow"
|
1411
|
+
},
|
1360
1412
|
{
|
1361
1413
|
"include": "#cast"
|
1362
1414
|
},
|
@@ -1366,6 +1418,9 @@
|
|
1366
1418
|
{
|
1367
1419
|
"include": "#new-expr"
|
1368
1420
|
},
|
1421
|
+
{
|
1422
|
+
"include": "#instanceof-expr"
|
1423
|
+
},
|
1369
1424
|
{
|
1370
1425
|
"include": "#object-literal"
|
1371
1426
|
},
|
@@ -1411,8 +1466,15 @@
|
|
1411
1466
|
"include": "#comment"
|
1412
1467
|
},
|
1413
1468
|
{
|
1414
|
-
"
|
1415
|
-
"
|
1469
|
+
"match": "(?x)([_$[:alpha:]][_$[:alnum:]]*)(\\?)?(?=(\\?\\s*)?\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ([\\(]\\s*$) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ([\\(]\\s*$) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
|
1470
|
+
"captures": {
|
1471
|
+
"1": {
|
1472
|
+
"name": "meta.definition.property.tsx entity.name.function.tsx"
|
1473
|
+
},
|
1474
|
+
"2": {
|
1475
|
+
"name": "keyword.operator.optional.tsx"
|
1476
|
+
}
|
1477
|
+
}
|
1416
1478
|
},
|
1417
1479
|
{
|
1418
1480
|
"name": "meta.definition.property.tsx variable.object.property.tsx",
|
@@ -1432,33 +1494,45 @@
|
|
1432
1494
|
}
|
1433
1495
|
},
|
1434
1496
|
"for-loop": {
|
1435
|
-
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))
|
1436
|
-
"end": "
|
1497
|
+
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))for(?=((\\s+|(\\s*\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*))await)?\\s*(\\/\\*([^\\*]|(\\*[^\\/]))*\\*\\/\\s*)?(\\())",
|
1498
|
+
"end": "(?\u003c=\\))",
|
1437
1499
|
"patterns": [
|
1438
1500
|
{
|
1439
|
-
"include": "#
|
1501
|
+
"include": "#comment"
|
1440
1502
|
},
|
1441
1503
|
{
|
1442
|
-
"
|
1504
|
+
"name": "keyword.control.loop.tsx",
|
1505
|
+
"match": "await"
|
1443
1506
|
},
|
1444
1507
|
{
|
1445
|
-
"
|
1508
|
+
"begin": "\\(",
|
1509
|
+
"end": "\\)",
|
1510
|
+
"patterns": [
|
1511
|
+
{
|
1512
|
+
"include": "#var-expr"
|
1513
|
+
},
|
1514
|
+
{
|
1515
|
+
"include": "#expression"
|
1516
|
+
},
|
1517
|
+
{
|
1518
|
+
"include": "#punctuation-semicolon"
|
1519
|
+
}
|
1520
|
+
],
|
1521
|
+
"beginCaptures": {
|
1522
|
+
"0": {
|
1523
|
+
"name": "meta.brace.round.tsx"
|
1524
|
+
}
|
1525
|
+
},
|
1526
|
+
"endCaptures": {
|
1527
|
+
"0": {
|
1528
|
+
"name": "meta.brace.round.tsx"
|
1529
|
+
}
|
1530
|
+
}
|
1446
1531
|
}
|
1447
1532
|
],
|
1448
1533
|
"beginCaptures": {
|
1449
|
-
"1": {
|
1450
|
-
"name": "keyword.control.loop.tsx"
|
1451
|
-
},
|
1452
|
-
"2": {
|
1453
|
-
"name": "keyword.control.loop.tsx"
|
1454
|
-
},
|
1455
|
-
"3": {
|
1456
|
-
"name": "meta.brace.round.tsx"
|
1457
|
-
}
|
1458
|
-
},
|
1459
|
-
"endCaptures": {
|
1460
1534
|
"0": {
|
1461
|
-
"name": "
|
1535
|
+
"name": "keyword.control.loop.tsx"
|
1462
1536
|
}
|
1463
1537
|
}
|
1464
1538
|
},
|
@@ -1478,17 +1552,21 @@
|
|
1478
1552
|
},
|
1479
1553
|
{
|
1480
1554
|
"include": "#decl-block"
|
1555
|
+
},
|
1556
|
+
{
|
1557
|
+
"name": "keyword.generator.asterisk.tsx",
|
1558
|
+
"match": "\\*"
|
1481
1559
|
}
|
1482
1560
|
]
|
1483
1561
|
},
|
1484
1562
|
"function-call": {
|
1485
|
-
"begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*\\s*\\??\\.\\s*)*|(\\??\\.\\s*)?)([_$[:alpha:]][_$[:alnum:]]*)\\s*(\\?\\.\\s*)?(\u003c\\s*(([_$[:alpha:]]|(\\{[^\\{\\}]*\\})|(\\([^\\(\\)]*\\))|(\\[[^\\[\\]]*\\]))|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))([^\u003c\u003e\\(]|(\\([^\\(\\)]*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(([_$[:alpha:]]|(\\{[^\\{\\}]*\\})|(\\([^\\(\\)]*\\))|(\\[[^\\[\\]]*\\]))|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))([^\u003c\u003e\\(]|(\\([^\\(\\)]*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e\\s*)?\\()",
|
1486
|
-
"end": "(?\u003c=\\))(?!(([_$[:alpha:]][_$[:alnum:]]*\\s*\\??\\.\\s*)*|(\\??\\.\\s*)?)([_$[:alpha:]][_$[:alnum:]]*)\\s*(\\?\\.\\s*)?(\u003c\\s*(([_$[:alpha:]]|(\\{[^\\{\\}]*\\})|(\\([^\\(\\)]*\\))|(\\[[^\\[\\]]*\\]))|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))([^\u003c\u003e\\(]|(\\([^\\(\\)]*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(([_$[:alpha:]]|(\\{[^\\{\\}]*\\})|(\\([^\\(\\)]*\\))|(\\[[^\\[\\]]*\\]))|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))([^\u003c\u003e\\(]|(\\([^\\(\\)]*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e\\s*)?\\()",
|
1563
|
+
"begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*\\s*\\??\\.\\s*)*|(\\??\\.\\s*)?)([_$[:alpha:]][_$[:alnum:]]*)\\s*(\\?\\.\\s*)?(\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e\\s*)?\\()",
|
1564
|
+
"end": "(?\u003c=\\))(?!(([_$[:alpha:]][_$[:alnum:]]*\\s*\\??\\.\\s*)*|(\\??\\.\\s*)?)([_$[:alpha:]][_$[:alnum:]]*)\\s*(\\?\\.\\s*)?(\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e\\s*)?\\()",
|
1487
1565
|
"patterns": [
|
1488
1566
|
{
|
1489
1567
|
"name": "meta.function-call.tsx",
|
1490
1568
|
"begin": "(?=(([_$[:alpha:]][_$[:alnum:]]*\\s*\\??\\.\\s*)*|(\\??\\.\\s*)?)([_$[:alpha:]][_$[:alnum:]]*))",
|
1491
|
-
"end": "(?=\\s*(\\?\\.\\s*)?(\u003c\\s*(([_$[:alpha:]]|(\\{[^\\{\\}]*\\})|(\\([^\\(\\)]*\\))|(\\[[^\\[\\]]*\\]))|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))([^\u003c\u003e\\(]|(\\([^\\(\\)]*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(([_$[:alpha:]]|(\\{[^\\{\\}]*\\})|(\\([^\\(\\)]*\\))|(\\[[^\\[\\]]*\\]))|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))([^\u003c\u003e\\(]|(\\([^\\(\\)]*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e\\s*)?\\()",
|
1569
|
+
"end": "(?=\\s*(\\?\\.\\s*)?(\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e\\s*)?\\()",
|
1492
1570
|
"patterns": [
|
1493
1571
|
{
|
1494
1572
|
"include": "#literal"
|
@@ -1520,27 +1598,7 @@
|
|
1520
1598
|
"match": "\\?\\."
|
1521
1599
|
},
|
1522
1600
|
{
|
1523
|
-
"
|
1524
|
-
"begin": "\\\u003c",
|
1525
|
-
"end": "\\\u003e",
|
1526
|
-
"patterns": [
|
1527
|
-
{
|
1528
|
-
"include": "#type"
|
1529
|
-
},
|
1530
|
-
{
|
1531
|
-
"include": "#punctuation-comma"
|
1532
|
-
}
|
1533
|
-
],
|
1534
|
-
"beginCaptures": {
|
1535
|
-
"0": {
|
1536
|
-
"name": "punctuation.definition.typeparameters.begin.tsx"
|
1537
|
-
}
|
1538
|
-
},
|
1539
|
-
"endCaptures": {
|
1540
|
-
"0": {
|
1541
|
-
"name": "punctuation.definition.typeparameters.end.tsx"
|
1542
|
-
}
|
1543
|
-
}
|
1601
|
+
"include": "#type-arguments"
|
1544
1602
|
},
|
1545
1603
|
{
|
1546
1604
|
"include": "#paren-expression"
|
@@ -1552,6 +1610,9 @@
|
|
1552
1610
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(export)\\s+)?(?:(async)\\s+)?(function\\b)(?:\\s*(\\*))?(?:(?:\\s+|(?\u003c=\\*))([_$[:alpha:]][_$[:alnum:]]*))?\\s*",
|
1553
1611
|
"end": "(?=$|^|;)|(?\u003c=\\})",
|
1554
1612
|
"patterns": [
|
1613
|
+
{
|
1614
|
+
"include": "#function-name"
|
1615
|
+
},
|
1555
1616
|
{
|
1556
1617
|
"include": "#function-body"
|
1557
1618
|
}
|
@@ -1579,6 +1640,9 @@
|
|
1579
1640
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(async)\\s+)?(function\\b)(?:\\s*(\\*))?(?:(?:\\s+|(?\u003c=\\*))([_$[:alpha:]][_$[:alnum:]]*))?\\s*",
|
1580
1641
|
"end": "(?\u003c=\\})",
|
1581
1642
|
"patterns": [
|
1643
|
+
{
|
1644
|
+
"include": "#function-name"
|
1645
|
+
},
|
1582
1646
|
{
|
1583
1647
|
"include": "#function-body"
|
1584
1648
|
}
|
@@ -1598,10 +1662,31 @@
|
|
1598
1662
|
}
|
1599
1663
|
}
|
1600
1664
|
},
|
1665
|
+
"function-name": {
|
1666
|
+
"name": "meta.definition.function.tsx entity.name.function.tsx",
|
1667
|
+
"match": "[_$[:alpha:]][_$[:alnum:]]*"
|
1668
|
+
},
|
1601
1669
|
"function-parameters": {
|
1602
1670
|
"name": "meta.parameters.tsx",
|
1603
1671
|
"begin": "\\(",
|
1604
1672
|
"end": "\\)",
|
1673
|
+
"patterns": [
|
1674
|
+
{
|
1675
|
+
"include": "#function-parameters-body"
|
1676
|
+
}
|
1677
|
+
],
|
1678
|
+
"beginCaptures": {
|
1679
|
+
"0": {
|
1680
|
+
"name": "punctuation.definition.parameters.begin.tsx"
|
1681
|
+
}
|
1682
|
+
},
|
1683
|
+
"endCaptures": {
|
1684
|
+
"0": {
|
1685
|
+
"name": "punctuation.definition.parameters.end.tsx"
|
1686
|
+
}
|
1687
|
+
}
|
1688
|
+
},
|
1689
|
+
"function-parameters-body": {
|
1605
1690
|
"patterns": [
|
1606
1691
|
{
|
1607
1692
|
"include": "#comment"
|
@@ -1625,17 +1710,7 @@
|
|
1625
1710
|
"name": "punctuation.separator.parameter.tsx",
|
1626
1711
|
"match": ","
|
1627
1712
|
}
|
1628
|
-
]
|
1629
|
-
"beginCaptures": {
|
1630
|
-
"0": {
|
1631
|
-
"name": "punctuation.definition.parameters.begin.tsx"
|
1632
|
-
}
|
1633
|
-
},
|
1634
|
-
"endCaptures": {
|
1635
|
-
"0": {
|
1636
|
-
"name": "punctuation.definition.parameters.end.tsx"
|
1637
|
-
}
|
1638
|
-
}
|
1713
|
+
]
|
1639
1714
|
},
|
1640
1715
|
"identifiers": {
|
1641
1716
|
"patterns": [
|
@@ -1643,7 +1718,7 @@
|
|
1643
1718
|
"include": "#object-identifiers"
|
1644
1719
|
},
|
1645
1720
|
{
|
1646
|
-
"match": "(?x)(?:(?:(\\.)|(\\?\\.(?!\\s*[[:digit:]])))\\s*)?([_$[:alpha:]][_$[:alnum:]]*)(?=\\s*=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n # sure shot arrow functions even if =\u003e is on new line\n(\n [(]\\s*\n (\n ([)]\\s*:) |
|
1721
|
+
"match": "(?x)(?:(?:(\\.)|(\\?\\.(?!\\s*[[:digit:]])))\\s*)?([_$[:alpha:]][_$[:alnum:]]*)(?=\\s*=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ([\\(]\\s*$) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n))",
|
1647
1722
|
"captures": {
|
1648
1723
|
"1": {
|
1649
1724
|
"name": "punctuation.accessor.tsx"
|
@@ -1699,6 +1774,26 @@
|
|
1699
1774
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(\\bexport)\\s+)?\\b(import)(?!\\s*[:\\(])(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))",
|
1700
1775
|
"end": "(?=;|$|^)",
|
1701
1776
|
"patterns": [
|
1777
|
+
{
|
1778
|
+
"include": "#comment"
|
1779
|
+
},
|
1780
|
+
{
|
1781
|
+
"include": "#string"
|
1782
|
+
},
|
1783
|
+
{
|
1784
|
+
"begin": "(?\u003c=^import|[^\\._$[:alnum:]]import)(?!\\s*[\"'])",
|
1785
|
+
"end": "\\bfrom\\b",
|
1786
|
+
"patterns": [
|
1787
|
+
{
|
1788
|
+
"include": "#import-export-declaration"
|
1789
|
+
}
|
1790
|
+
],
|
1791
|
+
"endCaptures": {
|
1792
|
+
"0": {
|
1793
|
+
"name": "keyword.control.from.tsx"
|
1794
|
+
}
|
1795
|
+
}
|
1796
|
+
},
|
1702
1797
|
{
|
1703
1798
|
"include": "#import-export-declaration"
|
1704
1799
|
}
|
@@ -1822,7 +1917,7 @@
|
|
1822
1917
|
"include": "#comment"
|
1823
1918
|
},
|
1824
1919
|
{
|
1825
|
-
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(\\bdefault)|(\\*)|(\\b[_$[:alpha:]][_$[:alnum:]]*))\\s+(as)\\s+(\\b[_$[:alpha:]][_$[:alnum:]]*)",
|
1920
|
+
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(\\bdefault)|(\\*)|(\\b[_$[:alpha:]][_$[:alnum:]]*))\\s+(as)\\s+(?:(\\bdefault(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.)))|(\\b[_$[:alpha:]][_$[:alnum:]]*))",
|
1826
1921
|
"captures": {
|
1827
1922
|
"1": {
|
1828
1923
|
"name": "keyword.control.default.tsx"
|
@@ -1837,6 +1932,9 @@
|
|
1837
1932
|
"name": "keyword.control.as.tsx"
|
1838
1933
|
},
|
1839
1934
|
"5": {
|
1935
|
+
"name": "keyword.control.default.tsx"
|
1936
|
+
},
|
1937
|
+
"6": {
|
1840
1938
|
"name": "variable.other.readwrite.alias.tsx"
|
1841
1939
|
}
|
1842
1940
|
}
|
@@ -1909,8 +2007,8 @@
|
|
1909
2007
|
},
|
1910
2008
|
"indexer-mapped-type-declaration": {
|
1911
2009
|
"name": "meta.indexer.mappedtype.declaration.tsx",
|
1912
|
-
"begin": "(?:(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(readonly)\\s*)?(\\[)\\s*([_$[:alpha:]][_$[:alnum:]]*)\\s+(in)\\s+",
|
1913
|
-
"end": "(\\])
|
2010
|
+
"begin": "(?:(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))([+-])?(readonly)\\s*)?(\\[)\\s*([_$[:alpha:]][_$[:alnum:]]*)\\s+(in)\\s+",
|
2011
|
+
"end": "(\\])([+-])?\\s*(\\?\\s*)?|$",
|
1914
2012
|
"patterns": [
|
1915
2013
|
{
|
1916
2014
|
"include": "#type"
|
@@ -1918,15 +2016,18 @@
|
|
1918
2016
|
],
|
1919
2017
|
"beginCaptures": {
|
1920
2018
|
"1": {
|
1921
|
-
"name": "
|
2019
|
+
"name": "keyword.operator.type.modifier.tsx"
|
1922
2020
|
},
|
1923
2021
|
"2": {
|
1924
|
-
"name": "
|
2022
|
+
"name": "storage.modifier.tsx"
|
1925
2023
|
},
|
1926
2024
|
"3": {
|
1927
|
-
"name": "
|
2025
|
+
"name": "meta.brace.square.tsx"
|
1928
2026
|
},
|
1929
2027
|
"4": {
|
2028
|
+
"name": "entity.name.type.tsx"
|
2029
|
+
},
|
2030
|
+
"5": {
|
1930
2031
|
"name": "keyword.operator.expression.in.tsx"
|
1931
2032
|
}
|
1932
2033
|
},
|
@@ -1935,6 +2036,9 @@
|
|
1935
2036
|
"name": "meta.brace.square.tsx"
|
1936
2037
|
},
|
1937
2038
|
"2": {
|
2039
|
+
"name": "keyword.operator.type.modifier.tsx"
|
2040
|
+
},
|
2041
|
+
"3": {
|
1938
2042
|
"name": "keyword.operator.optional.tsx"
|
1939
2043
|
}
|
1940
2044
|
}
|
@@ -2000,6 +2104,20 @@
|
|
2000
2104
|
}
|
2001
2105
|
]
|
2002
2106
|
},
|
2107
|
+
"instanceof-expr": {
|
2108
|
+
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(instanceof)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))",
|
2109
|
+
"end": "(?\u003c=\\))|(?=[;),}\\]:?]|\\|\\||\\\u0026\\\u0026|$|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))function((\\s+[_$[:alpha:]][_$[:alnum:]]*)|(\\s*[\\(]))))",
|
2110
|
+
"patterns": [
|
2111
|
+
{
|
2112
|
+
"include": "#type"
|
2113
|
+
}
|
2114
|
+
],
|
2115
|
+
"beginCaptures": {
|
2116
|
+
"1": {
|
2117
|
+
"name": "keyword.operator.expression.instanceof.tsx"
|
2118
|
+
}
|
2119
|
+
}
|
2120
|
+
},
|
2003
2121
|
"interface-declaration": {
|
2004
2122
|
"name": "meta.interface.tsx",
|
2005
2123
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(export)\\s+)?\\b(?:(abstract)\\s+)?\\b(interface)\\b(?=\\s+|/[/*])",
|
@@ -2082,42 +2200,13 @@
|
|
2082
2200
|
}
|
2083
2201
|
]
|
2084
2202
|
},
|
2085
|
-
"jsx-child-tag": {
|
2086
|
-
"begin": "(?x)\n (?=(\u003c)\\s*\n ([_$a-zA-Z][-$\\w.]*(?\u003c!\\.|-))\n (?=\\s+(?!\\?)|/?\u003e))",
|
2087
|
-
"end": "(/\u003e)|(?:(\u003c/)\\s*((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))\\s*(\u003e))",
|
2088
|
-
"patterns": [
|
2089
|
-
{
|
2090
|
-
"include": "#jsx-tag"
|
2091
|
-
}
|
2092
|
-
],
|
2093
|
-
"endCaptures": {
|
2094
|
-
"0": {
|
2095
|
-
"name": "meta.tag.tsx"
|
2096
|
-
},
|
2097
|
-
"1": {
|
2098
|
-
"name": "punctuation.definition.tag.end.tsx"
|
2099
|
-
},
|
2100
|
-
"2": {
|
2101
|
-
"name": "punctuation.definition.tag.begin.tsx"
|
2102
|
-
},
|
2103
|
-
"3": {
|
2104
|
-
"name": "entity.name.tag.tsx"
|
2105
|
-
},
|
2106
|
-
"4": {
|
2107
|
-
"name": "support.class.component.tsx"
|
2108
|
-
},
|
2109
|
-
"5": {
|
2110
|
-
"name": "punctuation.definition.tag.end.tsx"
|
2111
|
-
}
|
2112
|
-
}
|
2113
|
-
},
|
2114
2203
|
"jsx-children": {
|
2115
2204
|
"patterns": [
|
2116
2205
|
{
|
2117
2206
|
"include": "#jsx-tag-without-attributes"
|
2118
2207
|
},
|
2119
2208
|
{
|
2120
|
-
"include": "#jsx-
|
2209
|
+
"include": "#jsx-tag"
|
2121
2210
|
},
|
2122
2211
|
{
|
2123
2212
|
"include": "#jsx-evaluated-code"
|
@@ -2209,22 +2298,21 @@
|
|
2209
2298
|
},
|
2210
2299
|
"jsx-tag": {
|
2211
2300
|
"name": "meta.tag.tsx",
|
2212
|
-
"begin": "(
|
2213
|
-
"end": "(
|
2301
|
+
"begin": "(?=(\u003c)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))(?=(\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e)?\\s+(?!\\?)|\\/?\u003e))",
|
2302
|
+
"end": "(/\u003e)|(?:(\u003c/)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))?\\s*(\u003e))",
|
2214
2303
|
"patterns": [
|
2215
2304
|
{
|
2216
|
-
"
|
2217
|
-
"begin": "(?x)\n (\u003c)\\s*\n ((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))\n (?=\\s+(?!\\?)|/?\u003e)",
|
2305
|
+
"begin": "(\u003c)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))(?=(\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e)?\\s+(?!\\?)|\\/?\u003e)",
|
2218
2306
|
"end": "(?=[/]?\u003e)",
|
2219
2307
|
"patterns": [
|
2220
2308
|
{
|
2221
2309
|
"include": "#comment"
|
2222
2310
|
},
|
2223
2311
|
{
|
2224
|
-
"include": "#
|
2312
|
+
"include": "#type-arguments"
|
2225
2313
|
},
|
2226
2314
|
{
|
2227
|
-
"include": "#jsx-tag-attributes
|
2315
|
+
"include": "#jsx-tag-attributes"
|
2228
2316
|
}
|
2229
2317
|
],
|
2230
2318
|
"beginCaptures": {
|
@@ -2232,9 +2320,15 @@
|
|
2232
2320
|
"name": "punctuation.definition.tag.begin.tsx"
|
2233
2321
|
},
|
2234
2322
|
"2": {
|
2235
|
-
"name": "entity.name.tag.tsx"
|
2323
|
+
"name": "entity.name.tag.namespace.tsx"
|
2236
2324
|
},
|
2237
2325
|
"3": {
|
2326
|
+
"name": "punctuation.separator.namespace.tsx"
|
2327
|
+
},
|
2328
|
+
"4": {
|
2329
|
+
"name": "entity.name.tag.tsx"
|
2330
|
+
},
|
2331
|
+
"5": {
|
2238
2332
|
"name": "support.class.component.tsx"
|
2239
2333
|
}
|
2240
2334
|
}
|
@@ -2254,22 +2348,57 @@
|
|
2254
2348
|
}
|
2255
2349
|
}
|
2256
2350
|
}
|
2257
|
-
]
|
2351
|
+
],
|
2352
|
+
"endCaptures": {
|
2353
|
+
"1": {
|
2354
|
+
"name": "punctuation.definition.tag.end.tsx"
|
2355
|
+
},
|
2356
|
+
"2": {
|
2357
|
+
"name": "punctuation.definition.tag.begin.tsx"
|
2358
|
+
},
|
2359
|
+
"3": {
|
2360
|
+
"name": "entity.name.tag.namespace.tsx"
|
2361
|
+
},
|
2362
|
+
"4": {
|
2363
|
+
"name": "punctuation.separator.namespace.tsx"
|
2364
|
+
},
|
2365
|
+
"5": {
|
2366
|
+
"name": "entity.name.tag.tsx"
|
2367
|
+
},
|
2368
|
+
"6": {
|
2369
|
+
"name": "support.class.component.tsx"
|
2370
|
+
},
|
2371
|
+
"7": {
|
2372
|
+
"name": "punctuation.definition.tag.end.tsx"
|
2373
|
+
}
|
2374
|
+
}
|
2258
2375
|
},
|
2259
2376
|
"jsx-tag-attribute-assignment": {
|
2260
2377
|
"name": "keyword.operator.assignment.tsx",
|
2261
2378
|
"match": "=(?=\\s*(?:'|\"|{|/\\*|//|\\n))"
|
2262
2379
|
},
|
2263
2380
|
"jsx-tag-attribute-name": {
|
2264
|
-
"match": "(?x)\n \\s*\n ([_$a-zA-Z][-$\\w]*)\n (?=\\s|=|/?\u003e|/\\*|//)",
|
2381
|
+
"match": "(?x)\n \\s*\n (?:([_$a-zA-Z][-$\\w.]*)(:))?\n ([_$a-zA-Z][-$\\w]*)\n (?=\\s|=|/?\u003e|/\\*|//)",
|
2265
2382
|
"captures": {
|
2266
2383
|
"1": {
|
2384
|
+
"name": "entity.other.attribute-name.namespace.tsx"
|
2385
|
+
},
|
2386
|
+
"2": {
|
2387
|
+
"name": "punctuation.separator.namespace.tsx"
|
2388
|
+
},
|
2389
|
+
"3": {
|
2267
2390
|
"name": "entity.other.attribute-name.tsx"
|
2268
2391
|
}
|
2269
2392
|
}
|
2270
2393
|
},
|
2271
2394
|
"jsx-tag-attributes": {
|
2395
|
+
"name": "meta.tag.attributes.tsx",
|
2396
|
+
"begin": "\\s+",
|
2397
|
+
"end": "(?=[/]?\u003e)",
|
2272
2398
|
"patterns": [
|
2399
|
+
{
|
2400
|
+
"include": "#comment"
|
2401
|
+
},
|
2273
2402
|
{
|
2274
2403
|
"include": "#jsx-tag-attribute-name"
|
2275
2404
|
},
|
@@ -2284,6 +2413,9 @@
|
|
2284
2413
|
},
|
2285
2414
|
{
|
2286
2415
|
"include": "#jsx-evaluated-code"
|
2416
|
+
},
|
2417
|
+
{
|
2418
|
+
"include": "#jsx-tag-attributes-illegal"
|
2287
2419
|
}
|
2288
2420
|
]
|
2289
2421
|
},
|
@@ -2292,39 +2424,19 @@
|
|
2292
2424
|
"match": "\\S+"
|
2293
2425
|
},
|
2294
2426
|
"jsx-tag-in-expression": {
|
2295
|
-
"begin": "(?x)\n (?\u003c=[({\\[,?=\u003e:*]|\u0026\u0026|\\|\\||\\?|^return|[^\\._$[:alnum:]]return|^default|[^\\._$[:alnum:]]default|^)\\s*\n (?!\u003c\\s*[_$[:alpha:]][_$[:alnum:]]*((\\s+extends\\s+[^=\u003e])|,)) # look ahead is not type parameter of arrow\n (?=(\u003c)\\s
|
2296
|
-
"end": "(
|
2427
|
+
"begin": "(?x)\n (?\u003c!\\+\\+|--)(?\u003c=[({\\[,?=\u003e:*]|\u0026\u0026|\\|\\||\\?|^return|[^\\._$[:alnum:]]return|^default|[^\\._$[:alnum:]]default|^)\\s*\n (?!\u003c\\s*[_$[:alpha:]][_$[:alnum:]]*((\\s+extends\\s+[^=\u003e])|,)) # look ahead is not type parameter of arrow\n (?=(\u003c)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))(?=(\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e)?\\s+(?!\\?)|\\/?\u003e))",
|
2428
|
+
"end": "(?!(\u003c)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))(?=(\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e)?\\s+(?!\\?)|\\/?\u003e))",
|
2297
2429
|
"patterns": [
|
2298
2430
|
{
|
2299
2431
|
"include": "#jsx-tag"
|
2300
2432
|
}
|
2301
|
-
]
|
2302
|
-
"endCaptures": {
|
2303
|
-
"0": {
|
2304
|
-
"name": "meta.tag.tsx"
|
2305
|
-
},
|
2306
|
-
"1": {
|
2307
|
-
"name": "punctuation.definition.tag.end.tsx"
|
2308
|
-
},
|
2309
|
-
"2": {
|
2310
|
-
"name": "punctuation.definition.tag.begin.tsx"
|
2311
|
-
},
|
2312
|
-
"3": {
|
2313
|
-
"name": "entity.name.tag.tsx"
|
2314
|
-
},
|
2315
|
-
"4": {
|
2316
|
-
"name": "support.class.component.tsx"
|
2317
|
-
},
|
2318
|
-
"5": {
|
2319
|
-
"name": "punctuation.definition.tag.end.tsx"
|
2320
|
-
}
|
2321
|
-
}
|
2433
|
+
]
|
2322
2434
|
},
|
2323
2435
|
"jsx-tag-without-attributes": {
|
2324
2436
|
"name": "meta.tag.without-attributes.tsx",
|
2325
2437
|
"contentName": "meta.jsx.children.tsx",
|
2326
|
-
"begin": "(\u003c)\\s*((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))?\\s*(\u003e)",
|
2327
|
-
"end": "(\u003c/)\\s*((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))?\\s*(\u003e)",
|
2438
|
+
"begin": "(\u003c)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))?\\s*(\u003e)",
|
2439
|
+
"end": "(\u003c/)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))?\\s*(\u003e)",
|
2328
2440
|
"patterns": [
|
2329
2441
|
{
|
2330
2442
|
"include": "#jsx-children"
|
@@ -2335,12 +2447,18 @@
|
|
2335
2447
|
"name": "punctuation.definition.tag.begin.tsx"
|
2336
2448
|
},
|
2337
2449
|
"2": {
|
2338
|
-
"name": "entity.name.tag.tsx"
|
2450
|
+
"name": "entity.name.tag.namespace.tsx"
|
2339
2451
|
},
|
2340
2452
|
"3": {
|
2341
|
-
"name": "
|
2453
|
+
"name": "punctuation.separator.namespace.tsx"
|
2342
2454
|
},
|
2343
2455
|
"4": {
|
2456
|
+
"name": "entity.name.tag.tsx"
|
2457
|
+
},
|
2458
|
+
"5": {
|
2459
|
+
"name": "support.class.component.tsx"
|
2460
|
+
},
|
2461
|
+
"6": {
|
2344
2462
|
"name": "punctuation.definition.tag.end.tsx"
|
2345
2463
|
}
|
2346
2464
|
},
|
@@ -2349,19 +2467,25 @@
|
|
2349
2467
|
"name": "punctuation.definition.tag.begin.tsx"
|
2350
2468
|
},
|
2351
2469
|
"2": {
|
2352
|
-
"name": "entity.name.tag.tsx"
|
2470
|
+
"name": "entity.name.tag.namespace.tsx"
|
2353
2471
|
},
|
2354
2472
|
"3": {
|
2355
|
-
"name": "
|
2473
|
+
"name": "punctuation.separator.namespace.tsx"
|
2356
2474
|
},
|
2357
2475
|
"4": {
|
2476
|
+
"name": "entity.name.tag.tsx"
|
2477
|
+
},
|
2478
|
+
"5": {
|
2479
|
+
"name": "support.class.component.tsx"
|
2480
|
+
},
|
2481
|
+
"6": {
|
2358
2482
|
"name": "punctuation.definition.tag.end.tsx"
|
2359
2483
|
}
|
2360
2484
|
}
|
2361
2485
|
},
|
2362
2486
|
"jsx-tag-without-attributes-in-expression": {
|
2363
|
-
"begin": "(
|
2364
|
-
"end": "(
|
2487
|
+
"begin": "(?\u003c!\\+\\+|--)(?\u003c=[({\\[,?=\u003e:*]|\u0026\u0026|\\|\\||\\?|^return|[^\\._$[:alnum:]]return|^default|[^\\._$[:alnum:]]default|^)\\s*(?=(\u003c)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))?\\s*(\u003e))",
|
2488
|
+
"end": "(?!(\u003c)\\s*(?:([_$a-zA-Z][-$\\w.]*)(?\u003c!\\.|-)(:))?((?:[a-z][a-z0-9]*|([_$a-zA-Z][-$\\w.]*))(?\u003c!\\.|-))?\\s*(\u003e))",
|
2365
2489
|
"patterns": [
|
2366
2490
|
{
|
2367
2491
|
"include": "#jsx-tag-without-attributes"
|
@@ -2486,7 +2610,7 @@
|
|
2486
2610
|
"namespace-declaration": {
|
2487
2611
|
"name": "meta.namespace.declaration.tsx",
|
2488
2612
|
"begin": "(?:(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(\\bexport)\\s+)?\\b(namespace|module)\\s+(?=[_$[:alpha:]\"'`]))",
|
2489
|
-
"end": "(?\u003c=\\})|(?=;|\\babstract\\b|\\basync\\b|\\bclass\\b|\\bconst\\b|\\bdeclare\\b|\\benum\\b|\\bexport\\b|\\bfunction\\b|\\bimport\\b|\\binterface\\b|\\blet\\b|\\bmodule\\b|\\bnamespace\\b|\\btype\\b|\\bvar\\b)",
|
2613
|
+
"end": "(?\u003c=\\})|(?=;|\\babstract\\b|\\basync\\b|\\bclass\\b|\\bconst\\b|\\bdeclare\\b|\\benum\\b|\\bexport\\b|\\bfunction\\b|\\bimport\\b|\\binterface\\b|\\blet\\b|\\bmodule\\b|\\bnamespace\\b|\\breturn\\b|\\btype\\b|\\bvar\\b)",
|
2490
2614
|
"patterns": [
|
2491
2615
|
{
|
2492
2616
|
"include": "#comment"
|
@@ -2517,7 +2641,7 @@
|
|
2517
2641
|
"new-expr": {
|
2518
2642
|
"name": "new.expr.tsx",
|
2519
2643
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(new)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))",
|
2520
|
-
"end": "(?\u003c=\\))|(?=[;),}\\]]|$|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))new(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.)))|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))function((\\s+[_$[:alpha:]][_$[:alnum:]]*)|(\\s*[\\(]))))",
|
2644
|
+
"end": "(?\u003c=\\))|(?=[;),}\\]:]|\\|\\||\\\u0026\\\u0026|$|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))new(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.)))|((?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))function((\\s+[_$[:alpha:]][_$[:alnum:]]*)|(\\s*[\\(]))))",
|
2521
2645
|
"patterns": [
|
2522
2646
|
{
|
2523
2647
|
"include": "#paren-expression"
|
@@ -2543,18 +2667,18 @@
|
|
2543
2667
|
"patterns": [
|
2544
2668
|
{
|
2545
2669
|
"name": "constant.numeric.hex.tsx",
|
2546
|
-
"match": "\\b(?\u003c!\\$)0(x|X)[0-9a-fA-F]
|
2670
|
+
"match": "\\b(?\u003c!\\$)0(x|X)[0-9a-fA-F][0-9a-fA-F_]*\\b(?!\\$)"
|
2547
2671
|
},
|
2548
2672
|
{
|
2549
2673
|
"name": "constant.numeric.binary.tsx",
|
2550
|
-
"match": "\\b(?\u003c!\\$)0(b|B)[01]
|
2674
|
+
"match": "\\b(?\u003c!\\$)0(b|B)[01][01_]*\\b(?!\\$)"
|
2551
2675
|
},
|
2552
2676
|
{
|
2553
2677
|
"name": "constant.numeric.octal.tsx",
|
2554
|
-
"match": "\\b(?\u003c!\\$)0(o|O)?[0-7]
|
2678
|
+
"match": "\\b(?\u003c!\\$)0(o|O)?[0-7][0-7_]*\\b(?!\\$)"
|
2555
2679
|
},
|
2556
2680
|
{
|
2557
|
-
"match": "(?x)\n(?\u003c!\\$)(?:\n (?:\\b[0-9]
|
2681
|
+
"match": "(?x)\n(?\u003c!\\$)(?:\n (?:\\b[0-9][0-9_]*(\\.)[0-9][0-9_]*[eE][+-]?[0-9][0-9_]*\\b)| # 1.1E+3\n (?:\\b[0-9][0-9_]*(\\.)[eE][+-]?[0-9][0-9_]*\\b)| # 1.E+3\n (?:\\B(\\.)[0-9][0-9_]*[eE][+-]?[0-9][0-9_]*\\b)| # .1E+3\n (?:\\b[0-9][0-9_]*[eE][+-]?[0-9][0-9_]*\\b)| # 1E+3\n (?:\\b[0-9][0-9_]*(\\.)[0-9][0-9_]*\\b)| # 1.1\n (?:\\b[0-9][0-9_]*(\\.)\\B)| # 1.\n (?:\\B(\\.)[0-9][0-9_]*\\b)| # .1\n (?:\\b[0-9][0-9_]*\\b(?!\\.)) # 1\n)(?!\\$)",
|
2558
2682
|
"captures": {
|
2559
2683
|
"0": {
|
2560
2684
|
"name": "constant.numeric.decimal.tsx"
|
@@ -2778,7 +2902,7 @@
|
|
2778
2902
|
{
|
2779
2903
|
"name": "meta.object.member.tsx meta.object-literal.key.tsx",
|
2780
2904
|
"begin": "(?=\\[)",
|
2781
|
-
"end": "(?=:)",
|
2905
|
+
"end": "(?=:)|((?\u003c=[\\]])(?=\\s*[\\(\\\u003c]))",
|
2782
2906
|
"patterns": [
|
2783
2907
|
{
|
2784
2908
|
"include": "#array-literal"
|
@@ -2788,13 +2912,23 @@
|
|
2788
2912
|
{
|
2789
2913
|
"name": "meta.object.member.tsx meta.object-literal.key.tsx",
|
2790
2914
|
"begin": "(?=[\\'\\\"])",
|
2791
|
-
"end": "(?=:)",
|
2915
|
+
"end": "(?=:)|((?\u003c=[\\'\\\"])(?=\\s*[\\(\\\u003c]))",
|
2792
2916
|
"patterns": [
|
2793
2917
|
{
|
2794
2918
|
"include": "#string"
|
2795
2919
|
}
|
2796
2920
|
]
|
2797
2921
|
},
|
2922
|
+
{
|
2923
|
+
"name": "meta.method.declaration.tsx",
|
2924
|
+
"begin": "(?\u003c=[\\]\\'\\\"])(?=\\s*[\\(\\\u003c])",
|
2925
|
+
"end": "(?=\\}|;|,)|(?\u003c=\\})",
|
2926
|
+
"patterns": [
|
2927
|
+
{
|
2928
|
+
"include": "#function-body"
|
2929
|
+
}
|
2930
|
+
]
|
2931
|
+
},
|
2798
2932
|
{
|
2799
2933
|
"name": "meta.object.member.tsx",
|
2800
2934
|
"match": "(?![_$[:alpha:]])([[:digit:]]+)\\s*(?=:)",
|
@@ -2809,7 +2943,7 @@
|
|
2809
2943
|
},
|
2810
2944
|
{
|
2811
2945
|
"name": "meta.object.member.tsx",
|
2812
|
-
"match": "(?x)(?:([_$[:alpha:]][_$[:alnum:]]*)\\s*(?=:\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n # sure shot arrow functions even if =\u003e is on new line\n(\n [(]\\s*\n (\n ([)]\\s*:) |
|
2946
|
+
"match": "(?x)(?:([_$[:alpha:]][_$[:alnum:]]*)\\s*(?=:\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ([\\(]\\s*$) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
|
2813
2947
|
"captures": {
|
2814
2948
|
"0": {
|
2815
2949
|
"name": "meta.object-literal.key.tsx"
|
@@ -2867,6 +3001,61 @@
|
|
2867
3001
|
"begin": ":",
|
2868
3002
|
"end": "(?=,|\\})",
|
2869
3003
|
"patterns": [
|
3004
|
+
{
|
3005
|
+
"begin": "(?\u003c=:)\\s*(async)?(?=\\s*(\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)\\(\\s*$)",
|
3006
|
+
"end": "(?\u003c=\\))",
|
3007
|
+
"patterns": [
|
3008
|
+
{
|
3009
|
+
"include": "#type-parameters"
|
3010
|
+
},
|
3011
|
+
{
|
3012
|
+
"begin": "\\(",
|
3013
|
+
"end": "\\)",
|
3014
|
+
"patterns": [
|
3015
|
+
{
|
3016
|
+
"include": "#expression-inside-possibly-arrow-parens"
|
3017
|
+
}
|
3018
|
+
],
|
3019
|
+
"beginCaptures": {
|
3020
|
+
"0": {
|
3021
|
+
"name": "meta.brace.round.tsx"
|
3022
|
+
}
|
3023
|
+
},
|
3024
|
+
"endCaptures": {
|
3025
|
+
"0": {
|
3026
|
+
"name": "meta.brace.round.tsx"
|
3027
|
+
}
|
3028
|
+
}
|
3029
|
+
}
|
3030
|
+
],
|
3031
|
+
"beginCaptures": {
|
3032
|
+
"1": {
|
3033
|
+
"name": "storage.modifier.async.tsx"
|
3034
|
+
}
|
3035
|
+
}
|
3036
|
+
},
|
3037
|
+
{
|
3038
|
+
"begin": "(?\u003c=:)\\s*(async)?\\s*(\\()(?=\\s*$)",
|
3039
|
+
"end": "\\)",
|
3040
|
+
"patterns": [
|
3041
|
+
{
|
3042
|
+
"include": "#expression-inside-possibly-arrow-parens"
|
3043
|
+
}
|
3044
|
+
],
|
3045
|
+
"beginCaptures": {
|
3046
|
+
"1": {
|
3047
|
+
"name": "storage.modifier.async.tsx"
|
3048
|
+
},
|
3049
|
+
"2": {
|
3050
|
+
"name": "meta.brace.round.tsx"
|
3051
|
+
}
|
3052
|
+
},
|
3053
|
+
"endCaptures": {
|
3054
|
+
"0": {
|
3055
|
+
"name": "meta.brace.round.tsx"
|
3056
|
+
}
|
3057
|
+
}
|
3058
|
+
},
|
2870
3059
|
{
|
2871
3060
|
"include": "#expression"
|
2872
3061
|
}
|
@@ -2937,7 +3126,7 @@
|
|
2937
3126
|
}
|
2938
3127
|
},
|
2939
3128
|
{
|
2940
|
-
"match": "(?x)(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?\u003c!=|:)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(this)|([_$[:alpha:]][_$[:alnum:]]*))(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))\\s*(\\??)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n # sure shot arrow functions even if =\u003e is on new line\n(\n [(]\\s*\n (\n ([)]\\s*:) |
|
3129
|
+
"match": "(?x)(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?\u003c!=|:)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(this)|([_$[:alpha:]][_$[:alnum:]]*))(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))\\s*(\\??)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ([\\(]\\s*$) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ([\\(]\\s*$) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
|
2941
3130
|
"captures": {
|
2942
3131
|
"1": {
|
2943
3132
|
"name": "storage.modifier.tsx"
|
@@ -3037,9 +3226,6 @@
|
|
3037
3226
|
"patterns": [
|
3038
3227
|
{
|
3039
3228
|
"include": "#expression"
|
3040
|
-
},
|
3041
|
-
{
|
3042
|
-
"include": "#punctuation-comma"
|
3043
3229
|
}
|
3044
3230
|
],
|
3045
3231
|
"beginCaptures": {
|
@@ -3053,6 +3239,83 @@
|
|
3053
3239
|
}
|
3054
3240
|
}
|
3055
3241
|
},
|
3242
|
+
"paren-expression-possibly-arrow": {
|
3243
|
+
"patterns": [
|
3244
|
+
{
|
3245
|
+
"begin": "(?\u003c=[(=,]|=\u003e)\\s*(async)?(?=\\s*(\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)\\(\\s*$)",
|
3246
|
+
"end": "(?\u003c=\\))",
|
3247
|
+
"patterns": [
|
3248
|
+
{
|
3249
|
+
"include": "#type-parameters"
|
3250
|
+
},
|
3251
|
+
{
|
3252
|
+
"begin": "\\(",
|
3253
|
+
"end": "\\)",
|
3254
|
+
"patterns": [
|
3255
|
+
{
|
3256
|
+
"include": "#expression-inside-possibly-arrow-parens"
|
3257
|
+
}
|
3258
|
+
],
|
3259
|
+
"beginCaptures": {
|
3260
|
+
"0": {
|
3261
|
+
"name": "meta.brace.round.tsx"
|
3262
|
+
}
|
3263
|
+
},
|
3264
|
+
"endCaptures": {
|
3265
|
+
"0": {
|
3266
|
+
"name": "meta.brace.round.tsx"
|
3267
|
+
}
|
3268
|
+
}
|
3269
|
+
}
|
3270
|
+
],
|
3271
|
+
"beginCaptures": {
|
3272
|
+
"1": {
|
3273
|
+
"name": "storage.modifier.async.tsx"
|
3274
|
+
}
|
3275
|
+
}
|
3276
|
+
},
|
3277
|
+
{
|
3278
|
+
"begin": "(?\u003c=[(=,]|=\u003e)\\s*(async)?\\s*(\\()(?=\\s*$)",
|
3279
|
+
"end": "\\)",
|
3280
|
+
"patterns": [
|
3281
|
+
{
|
3282
|
+
"include": "#expression-inside-possibly-arrow-parens"
|
3283
|
+
}
|
3284
|
+
],
|
3285
|
+
"beginCaptures": {
|
3286
|
+
"1": {
|
3287
|
+
"name": "storage.modifier.async.tsx"
|
3288
|
+
},
|
3289
|
+
"2": {
|
3290
|
+
"name": "meta.brace.round.tsx"
|
3291
|
+
}
|
3292
|
+
},
|
3293
|
+
"endCaptures": {
|
3294
|
+
"0": {
|
3295
|
+
"name": "meta.brace.round.tsx"
|
3296
|
+
}
|
3297
|
+
}
|
3298
|
+
},
|
3299
|
+
{
|
3300
|
+
"include": "#possibly-arrow-return-type"
|
3301
|
+
}
|
3302
|
+
]
|
3303
|
+
},
|
3304
|
+
"possibly-arrow-return-type": {
|
3305
|
+
"contentName": "meta.arrow.tsx meta.return.type.arrow.tsx",
|
3306
|
+
"begin": "(?\u003c=\\))\\s*(:)(?=\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+\\s*=\u003e)",
|
3307
|
+
"end": "(?==\u003e|\\{|(^\\s*(export|function|class|interface|let|var|const|import|enum|namespace|module|type|abstract|declare)\\s+))",
|
3308
|
+
"patterns": [
|
3309
|
+
{
|
3310
|
+
"include": "#arrow-return-type-body"
|
3311
|
+
}
|
3312
|
+
],
|
3313
|
+
"beginCaptures": {
|
3314
|
+
"1": {
|
3315
|
+
"name": "meta.arrow.tsx meta.return.type.arrow.tsx keyword.operator.type.annotation.tsx"
|
3316
|
+
}
|
3317
|
+
}
|
3318
|
+
},
|
3056
3319
|
"property-accessor": {
|
3057
3320
|
"name": "storage.type.property.tsx",
|
3058
3321
|
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(get|set)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))"
|
@@ -3126,8 +3389,8 @@
|
|
3126
3389
|
"patterns": [
|
3127
3390
|
{
|
3128
3391
|
"name": "string.regexp.tsx",
|
3129
|
-
"begin": "(?\u003c=[=(:,\\[?+!]|^return|[^\\._$[:alnum:]]return|^case|[^\\._$[:alnum:]]case|=\u003e|\u0026\u0026|\\|\\||\\*\\/)\\s*(\\/)(?![\\/*])(?=(?:[^\\/\\\\\\[]|\\\\.|\\[([^\\]\\\\]|\\\\.)+\\])+\\/(?![\\/*])[
|
3130
|
-
"end": "(/)([
|
3392
|
+
"begin": "(?\u003c!\\+\\+|--)(?\u003c=[=(:,\\[?+!]|^return|[^\\._$[:alnum:]]return|^case|[^\\._$[:alnum:]]case|=\u003e|\u0026\u0026|\\|\\||\\*\\/)\\s*(\\/)(?![\\/*])(?=(?:[^\\/\\\\\\[]|\\\\.|\\[([^\\]\\\\]|\\\\.)+\\])+\\/(?![\\/*])[gimsuy]*(?!\\s*[a-zA-Z0-9_$]))",
|
3393
|
+
"end": "(/)([gimsuy]*)",
|
3131
3394
|
"patterns": [
|
3132
3395
|
{
|
3133
3396
|
"include": "#regexp"
|
@@ -3149,8 +3412,8 @@
|
|
3149
3412
|
},
|
3150
3413
|
{
|
3151
3414
|
"name": "string.regexp.tsx",
|
3152
|
-
"begin": "(?\u003c![_$[:alnum:])])\\/(?![\\/*])(?=(?:[^\\/\\\\\\[]|\\\\.|\\[([^\\]\\\\]|\\\\.)+\\])+\\/(?![\\/*])[
|
3153
|
-
"end": "(/)([
|
3415
|
+
"begin": "(?\u003c![_$[:alnum:])\\]]|\\+\\+|--)\\/(?![\\/*])(?=(?:[^\\/\\\\\\[]|\\\\.|\\[([^\\]\\\\]|\\\\.)+\\])+\\/(?![\\/*])[gimsuy]*(?!\\s*[a-zA-Z0-9_$]))",
|
3416
|
+
"end": "(/)([gimsuy]*)",
|
3154
3417
|
"patterns": [
|
3155
3418
|
{
|
3156
3419
|
"include": "#regexp"
|
@@ -3199,8 +3462,15 @@
|
|
3199
3462
|
"match": "\\\\[bB]|\\^|\\$"
|
3200
3463
|
},
|
3201
3464
|
{
|
3202
|
-
"
|
3203
|
-
"
|
3465
|
+
"match": "\\\\[1-9]\\d*|\\\\k\u003c([a-zA-Z_$][\\w$]*)\u003e",
|
3466
|
+
"captures": {
|
3467
|
+
"0": {
|
3468
|
+
"name": "keyword.other.back-reference.regexp"
|
3469
|
+
},
|
3470
|
+
"1": {
|
3471
|
+
"name": "variable.other.regexp"
|
3472
|
+
}
|
3473
|
+
}
|
3204
3474
|
},
|
3205
3475
|
{
|
3206
3476
|
"name": "keyword.operator.quantifier.regexp",
|
@@ -3212,7 +3482,7 @@
|
|
3212
3482
|
},
|
3213
3483
|
{
|
3214
3484
|
"name": "meta.group.assertion.regexp",
|
3215
|
-
"begin": "(\\()((\\?=)|(\\?!))",
|
3485
|
+
"begin": "(\\()((\\?=)|(\\?!)|(\\?\u003c=)|(\\?\u003c!))",
|
3216
3486
|
"end": "(\\))",
|
3217
3487
|
"patterns": [
|
3218
3488
|
{
|
@@ -3231,6 +3501,12 @@
|
|
3231
3501
|
},
|
3232
3502
|
"4": {
|
3233
3503
|
"name": "meta.assertion.negative-look-ahead.regexp"
|
3504
|
+
},
|
3505
|
+
"5": {
|
3506
|
+
"name": "meta.assertion.look-behind.regexp"
|
3507
|
+
},
|
3508
|
+
"6": {
|
3509
|
+
"name": "meta.assertion.negative-look-behind.regexp"
|
3234
3510
|
}
|
3235
3511
|
},
|
3236
3512
|
"endCaptures": {
|
@@ -3241,7 +3517,7 @@
|
|
3241
3517
|
},
|
3242
3518
|
{
|
3243
3519
|
"name": "meta.group.regexp",
|
3244
|
-
"begin": "\\((\\?:)?",
|
3520
|
+
"begin": "\\((?:(\\?:)|(?:\\?\u003c([a-zA-Z_$][\\w$]*)\u003e))?",
|
3245
3521
|
"end": "\\)",
|
3246
3522
|
"patterns": [
|
3247
3523
|
{
|
@@ -3254,6 +3530,9 @@
|
|
3254
3530
|
},
|
3255
3531
|
"1": {
|
3256
3532
|
"name": "punctuation.definition.group.no-capture.regexp"
|
3533
|
+
},
|
3534
|
+
"2": {
|
3535
|
+
"name": "variable.other.regexp"
|
3257
3536
|
}
|
3258
3537
|
},
|
3259
3538
|
"endCaptures": {
|
@@ -3427,12 +3706,16 @@
|
|
3427
3706
|
},
|
3428
3707
|
{
|
3429
3708
|
"name": "support.class.builtin.tsx",
|
3430
|
-
"match": "(?x)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(Array|ArrayBuffer|Atomics|Boolean|DataView|Date|Float32Array|Float64Array|Function|Generator\n |GeneratorFunction|Int8Array|Int16Array|Int32Array|Intl|Map|Number|Object|
|
3709
|
+
"match": "(?x)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(Array|ArrayBuffer|Atomics|Boolean|DataView|Date|Float32Array|Float64Array|Function|Generator\n |GeneratorFunction|Int8Array|Int16Array|Int32Array|Intl|Map|Number|Object|Proxy\n |Reflect|RegExp|Set|SharedArrayBuffer|SIMD|String|Symbol|TypedArray\n |Uint8Array|Uint16Array|Uint32Array|Uint8ClampedArray|WeakMap|WeakSet)\\b(?!\\$)"
|
3431
3710
|
},
|
3432
3711
|
{
|
3433
3712
|
"name": "support.class.error.tsx",
|
3434
3713
|
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))((Eval|Internal|Range|Reference|Syntax|Type|URI)?Error)\\b(?!\\$)"
|
3435
3714
|
},
|
3715
|
+
{
|
3716
|
+
"name": "support.class.promise.tsx",
|
3717
|
+
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(Promise)\\b(?!\\$)"
|
3718
|
+
},
|
3436
3719
|
{
|
3437
3720
|
"name": "support.function.tsx",
|
3438
3721
|
"match": "(?x)(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(clear(Interval|Timeout)|decodeURI|decodeURIComponent|encodeURI|encodeURIComponent|escape|eval|\n isFinite|isNaN|parseFloat|parseInt|require|set(Interval|Timeout)|super|unescape|uneval)(?=\\s*\\()"
|
@@ -3520,7 +3803,7 @@
|
|
3520
3803
|
}
|
3521
3804
|
},
|
3522
3805
|
{
|
3523
|
-
"match": "(?x) (?:(\\.)|(\\?\\.(?!\\s*[[:digit:]]))) \\s* (?:\n (ATTRIBUTE_NODE|CDATA_SECTION_NODE|COMMENT_NODE|DOCUMENT_FRAGMENT_NODE|DOCUMENT_NODE|DOCUMENT_TYPE_NODE\n |DOMSTRING_SIZE_ERR|ELEMENT_NODE|ENTITY_NODE|ENTITY_REFERENCE_NODE|HIERARCHY_REQUEST_ERR|INDEX_SIZE_ERR\n |INUSE_ATTRIBUTE_ERR|INVALID_CHARACTER_ERR|NO_DATA_ALLOWED_ERR|NO_MODIFICATION_ALLOWED_ERR|NOT_FOUND_ERR\n |NOT_SUPPORTED_ERR|NOTATION_NODE|PROCESSING_INSTRUCTION_NODE|TEXT_NODE|WRONG_DOCUMENT_ERR)\n |\n (_content|[xyz]|abbr|above|accept|acceptCharset|accessKey|action|align|[av]Link(?:color)?|all|alt|anchors|appCodeName\n |appCore|applets|appMinorVersion|appName|appVersion|archive|areas|arguments|attributes|availHeight|availLeft|availTop\n |availWidth|axis|background|backgroundColor|backgroundImage|below|bgColor|body|border|borderBottomWidth|borderColor\n |borderLeftWidth|borderRightWidth|borderStyle|borderTopWidth|borderWidth|bottom|bufferDepth|callee|caller|caption\n |cellPadding|cells|cellSpacing|ch|characterSet|charset|checked|childNodes|chOff|cite|classes|className|clear\n |clientInformation|clip|clipBoardData|closed|code|codeBase|codeType|color|colorDepth|cols|colSpan|compact|complete\n |components|content|controllers|cookie|cookieEnabled|cords|cpuClass|crypto|current|data|dateTime|declare|defaultCharset\n |defaultChecked|defaultSelected|defaultStatus|defaultValue|defaultView|defer|description|dialogArguments|dialogHeight\n |dialogLeft|dialogTop|dialogWidth|dir|directories|disabled|display|docmain|doctype|documentElement|elements|embeds\n |enabledPlugin|encoding|enctype|entities|event|expando|external|face|fgColor|filename|firstChild|fontFamily|fontSize\n |fontWeight|form|formName|forms|frame|frameBorder|frameElement|frames|hasFocus|hash|headers|height|history|host\n |hostname|href|hreflang|hspace|htmlFor|httpEquiv|id|ids|ignoreCase|images|implementation|index|innerHeight|innerWidth\n |input|isMap|label|lang|language|lastChild|lastIndex|lastMatch|lastModified|lastParen|layer[sXY]|left|leftContext\n |lineHeight|link|linkColor|links|listStyleType|localName|location|locationbar|longDesc|lowsrc|lowSrc|marginBottom\n |marginHeight|marginLeft|marginRight|marginTop|marginWidth|maxLength|media|menubar|method|mimeTypes|multiline|multiple\n |name|nameProp|namespaces|namespaceURI|next|nextSibling|nodeName|nodeType|nodeValue|noHref|noResize|noShade|notationName\n |notations|noWrap|object|offscreenBuffering|onLine|onreadystatechange|opener|opsProfile|options|oscpu|outerHeight\n |outerWidth|ownerDocument|paddingBottom|paddingLeft|paddingRight|paddingTop|page[XY]|page[XY]Offset|parent|parentLayer\n |parentNode|parentWindow|pathname|personalbar|pixelDepth|pkcs11|platform|plugins|port|prefix|previous|previousDibling\n |product|productSub|profile|profileend|prompt|prompter|protocol|publicId|readOnly|readyState|referrer|rel|responseText\n |responseXML|rev|right|rightContext|rowIndex|rows|rowSpan|rules|scheme|scope|screen[XY]|screenLeft|screenTop|scripts\n |scrollbars|scrolling|sectionRowIndex|security|securityPolicy|selected|selectedIndex|selection|self|shape|siblingAbove\n |siblingBelow|size|source|specified|standby|start|status|statusbar|statusText|style|styleSheets|suffixes|summary\n |systemId|systemLanguage|tagName|tags|target|tBodies|text|textAlign|textDecoration|textIndent|textTransform|tFoot|tHead\n |title|toolbar|top|type|undefined|uniqueID|updateInterval|URL|URLUnencoded|useMap|userAgent|userLanguage|userProfile\n |vAlign|value|valueType|vendor|vendorSub|version|visibility|vspace|whiteSpace|width|X[MS]LDocument|zIndex))\\b(?!\\$|\\s*(\u003c\\s*([_$[:alpha:]]|(\\{[^\\{\\}]*\\})|(\\([^\\(\\)]*\\))|(\\[[^\\[\\]]*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{[^\\{\\}]*\\})|(\\([^\\(\\)]*\\))|(\\[[^\\[\\]]*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\\()",
|
3806
|
+
"match": "(?x) (?:(\\.)|(\\?\\.(?!\\s*[[:digit:]]))) \\s* (?:\n (ATTRIBUTE_NODE|CDATA_SECTION_NODE|COMMENT_NODE|DOCUMENT_FRAGMENT_NODE|DOCUMENT_NODE|DOCUMENT_TYPE_NODE\n |DOMSTRING_SIZE_ERR|ELEMENT_NODE|ENTITY_NODE|ENTITY_REFERENCE_NODE|HIERARCHY_REQUEST_ERR|INDEX_SIZE_ERR\n |INUSE_ATTRIBUTE_ERR|INVALID_CHARACTER_ERR|NO_DATA_ALLOWED_ERR|NO_MODIFICATION_ALLOWED_ERR|NOT_FOUND_ERR\n |NOT_SUPPORTED_ERR|NOTATION_NODE|PROCESSING_INSTRUCTION_NODE|TEXT_NODE|WRONG_DOCUMENT_ERR)\n |\n (_content|[xyz]|abbr|above|accept|acceptCharset|accessKey|action|align|[av]Link(?:color)?|all|alt|anchors|appCodeName\n |appCore|applets|appMinorVersion|appName|appVersion|archive|areas|arguments|attributes|availHeight|availLeft|availTop\n |availWidth|axis|background|backgroundColor|backgroundImage|below|bgColor|body|border|borderBottomWidth|borderColor\n |borderLeftWidth|borderRightWidth|borderStyle|borderTopWidth|borderWidth|bottom|bufferDepth|callee|caller|caption\n |cellPadding|cells|cellSpacing|ch|characterSet|charset|checked|childNodes|chOff|cite|classes|className|clear\n |clientInformation|clip|clipBoardData|closed|code|codeBase|codeType|color|colorDepth|cols|colSpan|compact|complete\n |components|content|controllers|cookie|cookieEnabled|cords|cpuClass|crypto|current|data|dateTime|declare|defaultCharset\n |defaultChecked|defaultSelected|defaultStatus|defaultValue|defaultView|defer|description|dialogArguments|dialogHeight\n |dialogLeft|dialogTop|dialogWidth|dir|directories|disabled|display|docmain|doctype|documentElement|elements|embeds\n |enabledPlugin|encoding|enctype|entities|event|expando|external|face|fgColor|filename|firstChild|fontFamily|fontSize\n |fontWeight|form|formName|forms|frame|frameBorder|frameElement|frames|hasFocus|hash|headers|height|history|host\n |hostname|href|hreflang|hspace|htmlFor|httpEquiv|id|ids|ignoreCase|images|implementation|index|innerHeight|innerWidth\n |input|isMap|label|lang|language|lastChild|lastIndex|lastMatch|lastModified|lastParen|layer[sXY]|left|leftContext\n |lineHeight|link|linkColor|links|listStyleType|localName|location|locationbar|longDesc|lowsrc|lowSrc|marginBottom\n |marginHeight|marginLeft|marginRight|marginTop|marginWidth|maxLength|media|menubar|method|mimeTypes|multiline|multiple\n |name|nameProp|namespaces|namespaceURI|next|nextSibling|nodeName|nodeType|nodeValue|noHref|noResize|noShade|notationName\n |notations|noWrap|object|offscreenBuffering|onLine|onreadystatechange|opener|opsProfile|options|oscpu|outerHeight\n |outerWidth|ownerDocument|paddingBottom|paddingLeft|paddingRight|paddingTop|page[XY]|page[XY]Offset|parent|parentLayer\n |parentNode|parentWindow|pathname|personalbar|pixelDepth|pkcs11|platform|plugins|port|prefix|previous|previousDibling\n |product|productSub|profile|profileend|prompt|prompter|protocol|publicId|readOnly|readyState|referrer|rel|responseText\n |responseXML|rev|right|rightContext|rowIndex|rows|rowSpan|rules|scheme|scope|screen[XY]|screenLeft|screenTop|scripts\n |scrollbars|scrolling|sectionRowIndex|security|securityPolicy|selected|selectedIndex|selection|self|shape|siblingAbove\n |siblingBelow|size|source|specified|standby|start|status|statusbar|statusText|style|styleSheets|suffixes|summary\n |systemId|systemLanguage|tagName|tags|target|tBodies|text|textAlign|textDecoration|textIndent|textTransform|tFoot|tHead\n |title|toolbar|top|type|undefined|uniqueID|updateInterval|URL|URLUnencoded|useMap|userAgent|userLanguage|userProfile\n |vAlign|value|valueType|vendor|vendorSub|version|visibility|vspace|whiteSpace|width|X[MS]LDocument|zIndex))\\b(?!\\$|\\s*(\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\\()",
|
3524
3807
|
"captures": {
|
3525
3808
|
"1": {
|
3526
3809
|
"name": "punctuation.accessor.tsx"
|
@@ -3585,7 +3868,7 @@
|
|
3585
3868
|
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(global|GLOBAL|root|__dirname|__filename)\\b(?!\\$)"
|
3586
3869
|
},
|
3587
3870
|
{
|
3588
|
-
"match": "(?x) (?:(\\.)|(\\?\\.(?!\\s*[[:digit:]]))) \\s*\n(?:\n (on(?:Rowsinserted|Rowsdelete|Rowenter|Rowexit|Resize|Resizestart|Resizeend|Reset|\n Readystatechange|Mouseout|Mouseover|Mousedown|Mouseup|Mousemove|\n Before(?:cut|deactivate|unload|update|paste|print|editfocus|activate)|\n Blur|Scrolltop|Submit|Select|Selectstart|Selectionchange|Hover|Help|\n Change|Contextmenu|Controlselect|Cut|Cellchange|Clock|Close|Deactivate|\n Datasetchanged|Datasetcomplete|Dataavailable|Drop|Drag|Dragstart|Dragover|\n Dragdrop|Dragenter|Dragend|Dragleave|Dblclick|Unload|Paste|Propertychange|Error|\n Errorupdate|Keydown|Keyup|Keypress|Focus|Load|Activate|Afterupdate|Afterprint|Abort)\n ) |\n (shift|showModelessDialog|showModalDialog|showHelp|scroll|scrollX|scrollByPages|\n scrollByLines|scrollY|scrollTo|stop|strike|sizeToContent|sidebar|signText|sort|\n sup|sub|substr|substring|splice|split|send|set(?:Milliseconds|Seconds|Minutes|Hours|\n Month|Year|FullYear|Date|UTC(?:Milliseconds|Seconds|Minutes|Hours|Month|FullYear|Date)|\n Time|Hotkeys|Cursor|ZOptions|Active|Resizable|RequestHeader)|search|slice|\n savePreferences|small|home|handleEvent|navigate|char|charCodeAt|charAt|concat|\n contextual|confirm|compile|clear|captureEvents|call|createStyleSheet|createPopup|\n createEventObject|to(?:GMTString|UTCString|String|Source|UpperCase|LowerCase|LocaleString)|\n test|taint|taintEnabled|indexOf|italics|disableExternalCapture|dump|detachEvent|unshift|\n untaint|unwatch|updateCommands|join|javaEnabled|pop|push|plugins.refresh|paddings|parse|\n print|prompt|preference|enableExternalCapture|exec|execScript|valueOf|UTC|find|file|\n fileModifiedDate|fileSize|fileCreatedDate|fileUpdatedDate|fixed|fontsize|fontcolor|\n forward|fromCharCode|watch|link|load|lastIndexOf|anchor|attachEvent|atob|apply|alert|\n abort|routeEvents|resize|resizeBy|resizeTo|recalc|returnValue|replace|reverse|reload|\n releaseCapture|releaseEvents|go|get(?:Milliseconds|Seconds|Minutes|Hours|Month|Day|Year|FullYear|\n Time|Date|TimezoneOffset|UTC(?:Milliseconds|Seconds|Minutes|Hours|Day|Month|FullYear|Date)|\n Attention|Selection|ResponseHeader|AllResponseHeaders)|moveBy|moveBelow|moveTo|\n moveToAbsolute|moveAbove|mergeAttributes|match|margins|btoa|big|bold|borderWidths|blink|back\n ) |\n (acceptNode|add|addEventListener|addTextTrack|adoptNode|after|animate|append|\n appendChild|appendData|before|blur|canPlayType|captureStream|\n caretPositionFromPoint|caretRangeFromPoint|checkValidity|clear|click|\n cloneContents|cloneNode|cloneRange|close|closest|collapse|\n compareBoundaryPoints|compareDocumentPosition|comparePoint|contains|\n convertPointFromNode|convertQuadFromNode|convertRectFromNode|createAttribute|\n createAttributeNS|createCaption|createCDATASection|createComment|\n createContextualFragment|createDocument|createDocumentFragment|\n createDocumentType|createElement|createElementNS|createEntityReference|\n createEvent|createExpression|createHTMLDocument|createNodeIterator|\n createNSResolver|createProcessingInstruction|createRange|createShadowRoot|\n createTBody|createTextNode|createTFoot|createTHead|createTreeWalker|delete|\n deleteCaption|deleteCell|deleteContents|deleteData|deleteRow|deleteTFoot|\n deleteTHead|detach|disconnect|dispatchEvent|elementFromPoint|elementsFromPoint|\n enableStyleSheetsForSet|entries|evaluate|execCommand|exitFullscreen|\n exitPointerLock|expand|extractContents|fastSeek|firstChild|focus|forEach|get|\n getAll|getAnimations|getAttribute|getAttributeNames|getAttributeNode|\n getAttributeNodeNS|getAttributeNS|getBoundingClientRect|getBoxQuads|\n getClientRects|getContext|getDestinationInsertionPoints|getElementById|\n getElementsByClassName|getElementsByName|getElementsByTagName|\n getElementsByTagNameNS|getItem|getNamedItem|getSelection|getStartDate|\n getVideoPlaybackQuality|has|hasAttribute|hasAttributeNS|hasAttributes|\n hasChildNodes|hasFeature|hasFocus|importNode|initEvent|insertAdjacentElement|\n insertAdjacentHTML|insertAdjacentText|insertBefore|insertCell|insertData|\n insertNode|insertRow|intersectsNode|isDefaultNamespace|isEqualNode|\n isPointInRange|isSameNode|item|key|keys|lastChild|load|lookupNamespaceURI|\n lookupPrefix|matches|move|moveAttribute|moveAttributeNode|moveChild|\n moveNamedItem|namedItem|nextNode|nextSibling|normalize|observe|open|\n parentNode|pause|play|postMessage|prepend|preventDefault|previousNode|\n previousSibling|probablySupportsContext|queryCommandEnabled|\n queryCommandIndeterm|queryCommandState|queryCommandSupported|queryCommandValue|\n querySelector|querySelectorAll|registerContentHandler|registerElement|\n registerProtocolHandler|releaseCapture|releaseEvents|remove|removeAttribute|\n removeAttributeNode|removeAttributeNS|removeChild|removeEventListener|\n removeItem|replace|replaceChild|replaceData|replaceWith|reportValidity|\n requestFullscreen|requestPointerLock|reset|scroll|scrollBy|scrollIntoView|\n scrollTo|seekToNextFrame|select|selectNode|selectNodeContents|set|setAttribute|\n setAttributeNode|setAttributeNodeNS|setAttributeNS|setCapture|\n setCustomValidity|setEnd|setEndAfter|setEndBefore|setItem|setNamedItem|\n setRangeText|setSelectionRange|setSinkId|setStart|setStartAfter|setStartBefore|\n slice|splitText|stepDown|stepUp|stopImmediatePropagation|stopPropagation|\n submit|substringData|supports|surroundContents|takeRecords|terminate|toBlob|\n toDataURL|toggle|toString|values|write|writeln\n )\n)(?=\\s*\\()",
|
3871
|
+
"match": "(?x) (?:(\\.)|(\\?\\.(?!\\s*[[:digit:]]))) \\s*\n(?:\n (on(?:Rowsinserted|Rowsdelete|Rowenter|Rowexit|Resize|Resizestart|Resizeend|Reset|\n Readystatechange|Mouseout|Mouseover|Mousedown|Mouseup|Mousemove|\n Before(?:cut|deactivate|unload|update|paste|print|editfocus|activate)|\n Blur|Scrolltop|Submit|Select|Selectstart|Selectionchange|Hover|Help|\n Change|Contextmenu|Controlselect|Cut|Cellchange|Clock|Close|Deactivate|\n Datasetchanged|Datasetcomplete|Dataavailable|Drop|Drag|Dragstart|Dragover|\n Dragdrop|Dragenter|Dragend|Dragleave|Dblclick|Unload|Paste|Propertychange|Error|\n Errorupdate|Keydown|Keyup|Keypress|Focus|Load|Activate|Afterupdate|Afterprint|Abort)\n ) |\n (shift|showModelessDialog|showModalDialog|showHelp|scroll|scrollX|scrollByPages|\n scrollByLines|scrollY|scrollTo|stop|strike|sizeToContent|sidebar|signText|sort|\n sup|sub|substr|substring|splice|split|send|set(?:Milliseconds|Seconds|Minutes|Hours|\n Month|Year|FullYear|Date|UTC(?:Milliseconds|Seconds|Minutes|Hours|Month|FullYear|Date)|\n Time|Hotkeys|Cursor|ZOptions|Active|Resizable|RequestHeader)|search|slice|\n savePreferences|small|home|handleEvent|navigate|char|charCodeAt|charAt|concat|\n contextual|confirm|compile|clear|captureEvents|call|createStyleSheet|createPopup|\n createEventObject|to(?:GMTString|UTCString|String|Source|UpperCase|LowerCase|LocaleString)|\n test|taint|taintEnabled|indexOf|italics|disableExternalCapture|dump|detachEvent|unshift|\n untaint|unwatch|updateCommands|join|javaEnabled|pop|push|plugins.refresh|paddings|parse|\n print|prompt|preference|enableExternalCapture|exec|execScript|valueOf|UTC|find|file|\n fileModifiedDate|fileSize|fileCreatedDate|fileUpdatedDate|fixed|fontsize|fontcolor|\n forward|fromCharCode|watch|link|load|lastIndexOf|anchor|attachEvent|atob|apply|alert|\n abort|routeEvents|resize|resizeBy|resizeTo|recalc|returnValue|replace|reverse|reload|\n releaseCapture|releaseEvents|go|get(?:Milliseconds|Seconds|Minutes|Hours|Month|Day|Year|FullYear|\n Time|Date|TimezoneOffset|UTC(?:Milliseconds|Seconds|Minutes|Hours|Day|Month|FullYear|Date)|\n Attention|Selection|ResponseHeader|AllResponseHeaders)|moveBy|moveBelow|moveTo|\n moveToAbsolute|moveAbove|mergeAttributes|match|margins|btoa|big|bold|borderWidths|blink|back\n ) |\n (acceptNode|add|addEventListener|addTextTrack|adoptNode|after|animate|append|\n appendChild|appendData|before|blur|canPlayType|captureStream|\n caretPositionFromPoint|caretRangeFromPoint|checkValidity|clear|click|\n cloneContents|cloneNode|cloneRange|close|closest|collapse|\n compareBoundaryPoints|compareDocumentPosition|comparePoint|contains|\n convertPointFromNode|convertQuadFromNode|convertRectFromNode|createAttribute|\n createAttributeNS|createCaption|createCDATASection|createComment|\n createContextualFragment|createDocument|createDocumentFragment|\n createDocumentType|createElement|createElementNS|createEntityReference|\n createEvent|createExpression|createHTMLDocument|createNodeIterator|\n createNSResolver|createProcessingInstruction|createRange|createShadowRoot|\n createTBody|createTextNode|createTFoot|createTHead|createTreeWalker|delete|\n deleteCaption|deleteCell|deleteContents|deleteData|deleteRow|deleteTFoot|\n deleteTHead|detach|disconnect|dispatchEvent|elementFromPoint|elementsFromPoint|\n enableStyleSheetsForSet|entries|evaluate|execCommand|exitFullscreen|\n exitPointerLock|expand|extractContents|fastSeek|firstChild|focus|forEach|get|\n getAll|getAnimations|getAttribute|getAttributeNames|getAttributeNode|\n getAttributeNodeNS|getAttributeNS|getBoundingClientRect|getBoxQuads|\n getClientRects|getContext|getDestinationInsertionPoints|getElementById|\n getElementsByClassName|getElementsByName|getElementsByTagName|\n getElementsByTagNameNS|getItem|getNamedItem|getSelection|getStartDate|\n getVideoPlaybackQuality|has|hasAttribute|hasAttributeNS|hasAttributes|\n hasChildNodes|hasFeature|hasFocus|importNode|initEvent|insertAdjacentElement|\n insertAdjacentHTML|insertAdjacentText|insertBefore|insertCell|insertData|\n insertNode|insertRow|intersectsNode|isDefaultNamespace|isEqualNode|\n isPointInRange|isSameNode|item|key|keys|lastChild|load|lookupNamespaceURI|\n lookupPrefix|matches|move|moveAttribute|moveAttributeNode|moveChild|\n moveNamedItem|namedItem|nextNode|nextSibling|normalize|observe|open|\n parentNode|pause|play|postMessage|prepend|preventDefault|previousNode|\n previousSibling|probablySupportsContext|queryCommandEnabled|\n queryCommandIndeterm|queryCommandState|queryCommandSupported|queryCommandValue|\n querySelector|querySelectorAll|registerContentHandler|registerElement|\n registerProtocolHandler|releaseCapture|releaseEvents|remove|removeAttribute|\n removeAttributeNode|removeAttributeNS|removeChild|removeEventListener|\n removeItem|replace|replaceChild|replaceData|replaceWith|reportValidity|\n requestFullscreen|requestPointerLock|reset|scroll|scrollBy|scrollIntoView|\n scrollTo|seekToNextFrame|select|selectNode|selectNodeContents|set|setAttribute|\n setAttributeNode|setAttributeNodeNS|setAttributeNS|setCapture|\n setCustomValidity|setEnd|setEndAfter|setEndBefore|setItem|setNamedItem|\n setRangeText|setSelectionRange|setSinkId|setStart|setStartAfter|setStartBefore|\n slice|splitText|stepDown|stepUp|stopImmediatePropagation|stopPropagation|\n submit|substringData|supports|surroundContents|takeRecords|terminate|toBlob|\n toDataURL|toggle|toString|values|write|writeln\n ) |\n (all|catch|finally|race|reject|resolve|then\n )\n)(?=\\s*\\()",
|
3589
3872
|
"captures": {
|
3590
3873
|
"1": {
|
3591
3874
|
"name": "punctuation.accessor.tsx"
|
@@ -3601,6 +3884,9 @@
|
|
3601
3884
|
},
|
3602
3885
|
"5": {
|
3603
3886
|
"name": "support.function.dom.tsx"
|
3887
|
+
},
|
3888
|
+
"6": {
|
3889
|
+
"name": "support.function.promise.tsx"
|
3604
3890
|
}
|
3605
3891
|
}
|
3606
3892
|
}
|
@@ -3642,7 +3928,7 @@
|
|
3642
3928
|
{
|
3643
3929
|
"name": "case-clause.expr.tsx",
|
3644
3930
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(case|default(?=:))(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))",
|
3645
|
-
"end": "
|
3931
|
+
"end": "(?=:)",
|
3646
3932
|
"patterns": [
|
3647
3933
|
{
|
3648
3934
|
"include": "#expression"
|
@@ -3652,10 +3938,36 @@
|
|
3652
3938
|
"1": {
|
3653
3939
|
"name": "keyword.control.switch.tsx"
|
3654
3940
|
}
|
3941
|
+
}
|
3942
|
+
},
|
3943
|
+
{
|
3944
|
+
"contentName": "meta.block.tsx",
|
3945
|
+
"begin": "(:)\\s*(\\{)",
|
3946
|
+
"end": "\\}",
|
3947
|
+
"patterns": [
|
3948
|
+
{
|
3949
|
+
"include": "#statements"
|
3950
|
+
}
|
3951
|
+
],
|
3952
|
+
"beginCaptures": {
|
3953
|
+
"1": {
|
3954
|
+
"name": "case-clause.expr.tsx punctuation.definition.section.case-statement.tsx"
|
3955
|
+
},
|
3956
|
+
"2": {
|
3957
|
+
"name": "meta.block.tsx punctuation.definition.block.tsx"
|
3958
|
+
}
|
3655
3959
|
},
|
3656
3960
|
"endCaptures": {
|
3657
3961
|
"0": {
|
3658
|
-
"name": "punctuation.definition.
|
3962
|
+
"name": "meta.block.tsx punctuation.definition.block.tsx"
|
3963
|
+
}
|
3964
|
+
}
|
3965
|
+
},
|
3966
|
+
{
|
3967
|
+
"match": "(:)",
|
3968
|
+
"captures": {
|
3969
|
+
"0": {
|
3970
|
+
"name": "case-clause.expr.tsx punctuation.definition.section.case-statement.tsx"
|
3659
3971
|
}
|
3660
3972
|
}
|
3661
3973
|
},
|
@@ -3677,30 +3989,49 @@
|
|
3677
3989
|
}
|
3678
3990
|
},
|
3679
3991
|
"template": {
|
3680
|
-
"name": "string.template.tsx",
|
3681
|
-
"begin": "([_$[:alpha:]][_$[:alnum:]]*)?(`)",
|
3682
|
-
"end": "`",
|
3683
3992
|
"patterns": [
|
3684
3993
|
{
|
3685
|
-
"
|
3994
|
+
"name": "string.template.tsx",
|
3995
|
+
"begin": "([_$[:alpha:]][_$[:alnum:]]*)\\s*(?=(\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e|\\\u003c\\s*(((keyof|infer)\\s+)|(([_$[:alpha:]][_$[:alnum:]]*|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\])|(\\'[^\\']*\\')|(\\\"[^\\\"]*\\\")|(\\`[^\\`]*\\`))(?=\\s*([\\\u003c\\\u003e\\,\\.\\[]|=\u003e|\u0026(?!\u0026)|\\|(?!\\|)))))([^\u003c\u003e\\(]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(?\u003c==)\\\u003e)*(?!=)\\\u003e)*(?!=)\u003e\\s*)`)",
|
3996
|
+
"end": "(?=`)",
|
3997
|
+
"patterns": [
|
3998
|
+
{
|
3999
|
+
"include": "#type-parameters"
|
4000
|
+
}
|
4001
|
+
],
|
4002
|
+
"beginCaptures": {
|
4003
|
+
"1": {
|
4004
|
+
"name": "entity.name.function.tagged-template.tsx"
|
4005
|
+
}
|
4006
|
+
}
|
3686
4007
|
},
|
3687
4008
|
{
|
3688
|
-
"
|
3689
|
-
|
3690
|
-
|
3691
|
-
|
3692
|
-
|
3693
|
-
|
3694
|
-
|
3695
|
-
|
3696
|
-
|
3697
|
-
|
3698
|
-
|
3699
|
-
|
3700
|
-
|
3701
|
-
|
4009
|
+
"name": "string.template.tsx",
|
4010
|
+
"begin": "([_$[:alpha:]][_$[:alnum:]]*)?(`)",
|
4011
|
+
"end": "`",
|
4012
|
+
"patterns": [
|
4013
|
+
{
|
4014
|
+
"include": "#template-substitution-element"
|
4015
|
+
},
|
4016
|
+
{
|
4017
|
+
"include": "#string-character-escape"
|
4018
|
+
}
|
4019
|
+
],
|
4020
|
+
"beginCaptures": {
|
4021
|
+
"1": {
|
4022
|
+
"name": "entity.name.function.tagged-template.tsx"
|
4023
|
+
},
|
4024
|
+
"2": {
|
4025
|
+
"name": "punctuation.definition.string.template.begin.tsx"
|
4026
|
+
}
|
4027
|
+
},
|
4028
|
+
"endCaptures": {
|
4029
|
+
"0": {
|
4030
|
+
"name": "punctuation.definition.string.template.end.tsx"
|
4031
|
+
}
|
4032
|
+
}
|
3702
4033
|
}
|
3703
|
-
|
4034
|
+
]
|
3704
4035
|
},
|
3705
4036
|
"template-substitution-element": {
|
3706
4037
|
"name": "meta.template.expression.tsx",
|
@@ -3725,7 +4056,7 @@
|
|
3725
4056
|
},
|
3726
4057
|
"ternary-expression": {
|
3727
4058
|
"begin": "(?!\\?\\.\\s*[^[:digit:]])(\\?)",
|
3728
|
-
"end": "(:)",
|
4059
|
+
"end": "\\s*(:)",
|
3729
4060
|
"patterns": [
|
3730
4061
|
{
|
3731
4062
|
"include": "#expression"
|
@@ -3737,7 +4068,7 @@
|
|
3737
4068
|
}
|
3738
4069
|
},
|
3739
4070
|
"endCaptures": {
|
3740
|
-
"
|
4071
|
+
"1": {
|
3741
4072
|
"name": "keyword.operator.ternary.tsx"
|
3742
4073
|
}
|
3743
4074
|
}
|
@@ -3772,6 +4103,9 @@
|
|
3772
4103
|
{
|
3773
4104
|
"include": "#type-object"
|
3774
4105
|
},
|
4106
|
+
{
|
4107
|
+
"include": "#type-conditional"
|
4108
|
+
},
|
3775
4109
|
{
|
3776
4110
|
"include": "#type-operators"
|
3777
4111
|
},
|
@@ -3792,7 +4126,7 @@
|
|
3792
4126
|
"type-alias-declaration": {
|
3793
4127
|
"name": "meta.type.declaration.tsx",
|
3794
4128
|
"begin": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(?:(\\bexport)\\s+)?\\b(type)\\b\\s+([_$[:alpha:]][_$[:alnum:]]*)\\s*",
|
3795
|
-
"end": "(
|
4129
|
+
"end": "(?=\\}|;|\\babstract\\b|\\basync\\b|\\bclass\\b|\\bconst\\b|\\bdeclare\\b|\\benum\\b|\\bexport\\b|\\bfunction\\b|\\bimport\\b|\\binterface\\b|\\blet\\b|\\bmodule\\b|\\bnamespace\\b|\\breturn\\b|\\btype\\b|\\bvar\\b)",
|
3796
4130
|
"patterns": [
|
3797
4131
|
{
|
3798
4132
|
"include": "#comment"
|
@@ -3858,10 +4192,41 @@
|
|
3858
4192
|
}
|
3859
4193
|
]
|
3860
4194
|
},
|
4195
|
+
"type-arguments": {
|
4196
|
+
"name": "meta.type.parameters.tsx",
|
4197
|
+
"begin": "\\\u003c",
|
4198
|
+
"end": "\\\u003e",
|
4199
|
+
"patterns": [
|
4200
|
+
{
|
4201
|
+
"include": "#type"
|
4202
|
+
},
|
4203
|
+
{
|
4204
|
+
"include": "#punctuation-comma"
|
4205
|
+
}
|
4206
|
+
],
|
4207
|
+
"beginCaptures": {
|
4208
|
+
"0": {
|
4209
|
+
"name": "punctuation.definition.typeparameters.begin.tsx"
|
4210
|
+
}
|
4211
|
+
},
|
4212
|
+
"endCaptures": {
|
4213
|
+
"0": {
|
4214
|
+
"name": "punctuation.definition.typeparameters.end.tsx"
|
4215
|
+
}
|
4216
|
+
}
|
4217
|
+
},
|
3861
4218
|
"type-builtin-literals": {
|
3862
4219
|
"name": "support.type.builtin.tsx",
|
3863
4220
|
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(this|true|false|undefined|null|object)(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))"
|
3864
4221
|
},
|
4222
|
+
"type-conditional": {
|
4223
|
+
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))(extends)\\s+",
|
4224
|
+
"captures": {
|
4225
|
+
"1": {
|
4226
|
+
"name": "storage.modifier.tsx"
|
4227
|
+
}
|
4228
|
+
}
|
4229
|
+
},
|
3865
4230
|
"type-fn-type-parameters": {
|
3866
4231
|
"patterns": [
|
3867
4232
|
{
|
@@ -4067,6 +4432,18 @@
|
|
4067
4432
|
{
|
4068
4433
|
"name": "keyword.operator.expression.keyof.tsx",
|
4069
4434
|
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))keyof(?![_$[:alnum:]])(?:(?=\\.\\.\\.)|(?!\\.))"
|
4435
|
+
},
|
4436
|
+
{
|
4437
|
+
"name": "keyword.operator.ternary.tsx",
|
4438
|
+
"match": "(\\?|\\:)"
|
4439
|
+
},
|
4440
|
+
{
|
4441
|
+
"name": "keyword.operator.expression.infer.tsx",
|
4442
|
+
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))infer(?=\\s+[_$[:alpha:]])"
|
4443
|
+
},
|
4444
|
+
{
|
4445
|
+
"name": "keyword.operator.expression.import.tsx",
|
4446
|
+
"match": "(?\u003c![_$[:alnum:]])(?:(?\u003c=\\.\\.\\.)|(?\u003c!\\.))import(?=\\s*\\()"
|
4070
4447
|
}
|
4071
4448
|
]
|
4072
4449
|
},
|
@@ -4223,7 +4600,7 @@
|
|
4223
4600
|
"patterns": [
|
4224
4601
|
{
|
4225
4602
|
"name": "meta.var-single-variable.expr.tsx",
|
4226
|
-
"begin": "(?x)([_$[:alpha:]][_$[:alnum:]]*)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n # sure shot arrow functions even if =\u003e is on new line\n(\n [(]\\s*\n (\n ([)]\\s*:) |
|
4603
|
+
"begin": "(?x)([_$[:alpha:]][_$[:alnum:]]*)(?=\\s*\n# function assignment |\n(=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ([\\(]\\s*$) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)) |\n# typeannotation is fn type: \u003c | () | (... | (param: | (param, | (param? | (param= | (param) =\u003e\n(:\\s*(\n (\u003c) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=\u003e)\n ))\n ))\n)) |\n(:\\s*(=\u003e|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\u003c[^\u003c\u003e]*\u003e)|[^\u003c\u003e(),=])+=\\s*(\n ((async\\s+)?(\n (function\\s*[(\u003c*]) |\n (function\\s+) |\n ([_$[:alpha:]][_$[:alnum:]]*\\s*=\u003e)\n )) |\n ((async\\s*)?(\n ([\\(]\\s*$) |\n # sure shot arrow functions even if =\u003e is on new line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)?\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n) |\n(\n [\u003c]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=\u003e] # \u003c typeparam extends\n) |\n# arrow function possible to detect only with =\u003e on same line\n(\n (\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c]|\\\u003c\\s*([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\))|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^=\u003c\u003e]|=[^\u003c])*\\\u003e)*\u003e\\s*)? # typeparameters\n \\(\\s*(([_$[:alpha:]]|(\\{([^\\{\\}]|(\\{[^\\{\\}]*\\}))*\\})|(\\[([^\\[\\]]|(\\[[^\\[\\]]*\\]))*\\]))([^()]|(\\(([^\\(\\)]|(\\([^\\(\\)]*\\)))*\\)))*)?\\) # parameters\n (\\s*:\\s*([^\u003c\u003e\\(\\)]|\\\u003c[^\u003c\u003e]+\\\u003e|\\([^\\(\\)]+\\))+)? # return type\n \\s*=\u003e # arrow operator\n)\n ))\n)))",
|
4227
4604
|
"end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))",
|
4228
4605
|
"patterns": [
|
4229
4606
|
{
|