diff --git a/TypeScript.YAML-tmLanguage b/TypeScript.YAML-tmLanguage
index a0ddfe1..40aaf7a 100644
--- a/TypeScript.YAML-tmLanguage
+++ b/TypeScript.YAML-tmLanguage
@@ -703,12 +703,12 @@ repository:
patterns:
- include: '#expression-operator'
- include: '#type'
- - include: '#string'
- include: '#comment'
type:
name: meta.type.ts
patterns:
+ - include: '#string'
- include: '#type-primitive'
- include: '#type-parameters'
- include: '#type-tuple'
diff --git a/TypeScript.tmLanguage b/TypeScript.tmLanguage
index 259b4e0..7f35f4e 100644
--- a/TypeScript.tmLanguage
+++ b/TypeScript.tmLanguage
@@ -3396,6 +3396,10 @@
meta.type.ts
patterns
+
+ include
+ #string
+
include
#type-primitive
@@ -3448,10 +3452,6 @@
include
#type
-
- include
- #string
-
include
#comment
diff --git a/TypeScriptReact.YAML-tmLanguage b/TypeScriptReact.YAML-tmLanguage
index 8c547d3..3f800a0 100644
--- a/TypeScriptReact.YAML-tmLanguage
+++ b/TypeScriptReact.YAML-tmLanguage
@@ -707,12 +707,12 @@ repository:
patterns:
- include: '#expression-operator'
- include: '#type'
- - include: '#string'
- include: '#comment'
type:
name: meta.type.tsx
patterns:
+ - include: '#string'
- include: '#type-primitive'
- include: '#type-parameters'
- include: '#type-tuple'
diff --git a/TypeScriptReact.tmLanguage b/TypeScriptReact.tmLanguage
index 4e65071..e4f9db2 100644
--- a/TypeScriptReact.tmLanguage
+++ b/TypeScriptReact.tmLanguage
@@ -3786,6 +3786,10 @@
meta.type.tsx
patterns
+
+ include
+ #string
+
include
#type-primitive
@@ -3838,10 +3842,6 @@
include
#type
-
- include
- #string
-
include
#comment
diff --git a/tests/baselines/Issue114.baseline.txt b/tests/baselines/Issue114.baseline.txt
new file mode 100644
index 0000000..9c927ba
--- /dev/null
+++ b/tests/baselines/Issue114.baseline.txt
@@ -0,0 +1,148 @@
+original file
+-----------------------------------
+export type BreakpointType = 'line' | 'call' | 'return' | 'exception' | 'conditional' | 'watch'
+interface Test {
+ type: 'line' | 'call' | 'return';
+}
+-----------------------------------
+
+>export type BreakpointType = 'line' | 'call' | 'return' | 'exception' | 'conditional' | 'watch'
+ ^^^^^^
+ source.ts meta.type.declaration.ts keyword.control.export.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^^^^
+ source.ts meta.type.declaration.ts storage.type.type.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^^^^^^^^^^^^^^
+ source.ts meta.type.declaration.ts entity.name.type.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^^
+ source.ts meta.type.declaration.ts keyword.operator.assignment.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^
+ source.ts meta.type.declaration.ts string.quoted.single.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts keyword.operator.type.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^
+ source.ts meta.type.declaration.ts string.quoted.single.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts keyword.operator.type.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^^^
+ source.ts meta.type.declaration.ts string.quoted.single.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts keyword.operator.type.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^^^^^^
+ source.ts meta.type.declaration.ts string.quoted.single.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts keyword.operator.type.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^^^^^^^^
+ source.ts meta.type.declaration.ts string.quoted.single.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts keyword.operator.type.ts
+ ^
+ source.ts meta.type.declaration.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^^
+ source.ts meta.type.declaration.ts string.quoted.single.ts
+ ^
+ source.ts meta.type.declaration.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^
+ source.ts meta.type.declaration.ts
+>interface Test {
+ ^^^^^^^^^
+ source.ts meta.declaration.object.ts storage.type.interface.ts
+ ^
+ source.ts meta.declaration.object.ts
+ ^^^^
+ source.ts meta.declaration.object.ts meta.object.name.ts entity.name.class.ts
+ ^
+ source.ts meta.declaration.object.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts punctuation.definition.block.ts
+ ^^
+ source.ts meta.declaration.object.ts meta.object.body.ts
+> type: 'line' | 'call' | 'return';
+ ^^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts
+ ^^^^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts variable.object.property.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts keyword.operator.type.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts keyword.operator.type.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts punctuation.definition.string.begin.ts
+ ^^^^^^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts meta.field.declaration.ts meta.type.annotation.ts string.quoted.single.ts punctuation.definition.string.end.ts
+ ^^^
+ source.ts meta.declaration.object.ts meta.object.body.ts
+>}
+ ^
+ source.ts meta.declaration.object.ts meta.object.body.ts punctuation.definition.block.ts
\ No newline at end of file
diff --git a/tests/cases/Issue114.ts b/tests/cases/Issue114.ts
new file mode 100644
index 0000000..6d0c380
--- /dev/null
+++ b/tests/cases/Issue114.ts
@@ -0,0 +1,4 @@
+export type BreakpointType = 'line' | 'call' | 'return' | 'exception' | 'conditional' | 'watch'
+interface Test {
+ type: 'line' | 'call' | 'return';
+}
\ No newline at end of file