diff --git a/data/fixtures/scopes/javascript.core/type.class.scope b/data/fixtures/scopes/javascript.core/type.class.scope deleted file mode 100644 index 696dd5c641..0000000000 --- a/data/fixtures/scopes/javascript.core/type.class.scope +++ /dev/null @@ -1,10 +0,0 @@ -class MyClass { } ---- - -[Content] = -[Removal] = -[Domain] = 0:0-0:17 - >-----------------< -0| class MyClass { } - -[Insertion delimiter] = " " diff --git a/data/fixtures/scopes/typescript.core/type/type.class.scope b/data/fixtures/scopes/typescript.core/type/type.class.scope index 2d8fb78b2f..79c274ccc6 100644 --- a/data/fixtures/scopes/typescript.core/type/type.class.scope +++ b/data/fixtures/scopes/typescript.core/type/type.class.scope @@ -1,10 +1,10 @@ -abstract class Foo { } +class Foo {} --- [Content] = [Removal] = -[Domain] = 0:0-0:22 - >----------------------< -0| abstract class Foo { } +[Domain] = 0:0-0:12 + >------------< +0| class Foo {} [Insertion delimiter] = " " diff --git a/data/fixtures/scopes/typescript.core/type/type.class2.scope b/data/fixtures/scopes/typescript.core/type/type.class2.scope new file mode 100644 index 0000000000..c917ac4ee4 --- /dev/null +++ b/data/fixtures/scopes/typescript.core/type/type.class2.scope @@ -0,0 +1,10 @@ +abstract class Foo {} +--- + +[Content] = +[Removal] = +[Domain] = 0:0-0:21 + >---------------------< +0| abstract class Foo {} + +[Insertion delimiter] = " " diff --git a/packages/common/src/scopeSupportFacets/javascript.ts b/packages/common/src/scopeSupportFacets/javascript.ts index 874663c5ef..b3fe83df3d 100644 --- a/packages/common/src/scopeSupportFacets/javascript.ts +++ b/packages/common/src/scopeSupportFacets/javascript.ts @@ -168,10 +168,6 @@ export const javascriptCoreScopeSupport: LanguageScopeSupportFacetMap = { "value.iteration.class": supported, "value.iteration.document": supported, - // JS doesn't have types, but for muscle memory sake we will treat classes the - // same in JS and TS. - "type.class": supported, - "interior.class": supported, "interior.function": supported, "interior.constructor": supported, @@ -272,6 +268,7 @@ export const javascriptScopeSupport: LanguageScopeSupportFacetMap = { "type.argument.catch": notApplicable, "type.alias": notApplicable, "type.cast": notApplicable, + "type.class": notApplicable, "type.field.class": notApplicable, "type.field.interface": notApplicable, "type.foreach": notApplicable, diff --git a/packages/common/src/scopeSupportFacets/typescript.ts b/packages/common/src/scopeSupportFacets/typescript.ts index 0324051934..c3af56028d 100644 --- a/packages/common/src/scopeSupportFacets/typescript.ts +++ b/packages/common/src/scopeSupportFacets/typescript.ts @@ -16,6 +16,7 @@ export const typescriptScopeSupport: LanguageScopeSupportFacetMap = { "type.argument.catch": supported, "type.alias": supported, "type.cast": supported, + "type.class": supported, "type.field.class": supported, "type.field.interface": supported, "type.interface": supported,