Skip to content
This repository was archived by the owner on Dec 25, 2023. It is now read-only.

Commit c5bcfce

Browse files
Bump typescript from 4.7.4 to 4.9.4 (#445)
* Bump typescript from 4.7.4 to 4.9.4 Bumps [typescript](https://github.com/Microsoft/TypeScript) from 4.7.4 to 4.9.4. - [Release notes](https://github.com/Microsoft/TypeScript/releases) - [Commits](microsoft/TypeScript@v4.7.4...v4.9.4) --- updated-dependencies: - dependency-name: typescript dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> * Add new typescript configuration options Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Cameron Little <[email protected]>
1 parent 3a7085a commit c5bcfce

File tree

6 files changed

+198
-9
lines changed

6 files changed

+198
-9
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
"rollup": "^2.79.1",
4545
"rollup-plugin-typescript2": "^0.34.1",
4646
"ts-jest": "^26.5.6",
47-
"typescript": "^4.7.4",
47+
"typescript": "^4.9.4",
4848
"vscode-languageserver-protocol": "^3.17.2",
4949
"vscode-languageserver-types": "^3.17.1"
5050
}

src/tsUserPreferences.test.ts

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ describe("tsUserPreferences", () => {
2828

2929
setupUserPreferences();
3030

31-
expect(nova.config.onDidChange).toBeCalledTimes(29);
32-
expect(nova.workspace.config.onDidChange).toBeCalledTimes(29);
31+
expect(nova.config.onDidChange).toBeCalledTimes(32);
32+
expect(nova.workspace.config.onDidChange).toBeCalledTimes(32);
3333

3434
const globalConfigKeys = (
3535
nova.config.onDidChange as jest.Mock
@@ -43,6 +43,8 @@ describe("tsUserPreferences", () => {
4343
"apexskier.typescript.config.userPreferences.allowIncompleteCompletions",
4444
"apexskier.typescript.config.userPreferences.allowRenameOfImportPath",
4545
"apexskier.typescript.config.userPreferences.allowTextChangesInNewFiles",
46+
"apexskier.typescript.config.userPreferences.autoImportFileExcludePatterns",
47+
"apexskier.typescript.config.userPreferences.disableLineTextInReferences",
4648
"apexskier.typescript.config.userPreferences.disableSuggestions",
4749
"apexskier.typescript.config.userPreferences.displayPartsForJSDoc",
4850
"apexskier.typescript.config.userPreferences.generateReturnInDocTemplate",
@@ -62,6 +64,7 @@ describe("tsUserPreferences", () => {
6264
"apexskier.typescript.config.userPreferences.includeInlayParameterNameHintsWhenArgumentMatchesName",
6365
"apexskier.typescript.config.userPreferences.includeInlayPropertyDeclarationTypeHints",
6466
"apexskier.typescript.config.userPreferences.includeInlayVariableTypeHints",
67+
"apexskier.typescript.config.userPreferences.includeInlayVariableTypeHintsWhenTypeMatchesName",
6568
"apexskier.typescript.config.userPreferences.includePackageJsonAutoImports",
6669
"apexskier.typescript.config.userPreferences.jsxAttributeCompletionStyle",
6770
"apexskier.typescript.config.userPreferences.lazyConfiguredProjectsFromExternalProject",
@@ -107,6 +110,8 @@ describe("tsUserPreferences", () => {
107110
"allowIncompleteCompletions": "global apexskier.typescript.config.userPreferences.allowIncompleteCompletions boolean",
108111
"allowRenameOfImportPath": "global apexskier.typescript.config.userPreferences.allowRenameOfImportPath boolean",
109112
"allowTextChangesInNewFiles": "global apexskier.typescript.config.userPreferences.allowTextChangesInNewFiles boolean",
113+
"autoImportFileExcludePatterns": "global apexskier.typescript.config.userPreferences.autoImportFileExcludePatterns stringArray",
114+
"disableLineTextInReferences": "global apexskier.typescript.config.userPreferences.disableLineTextInReferences boolean",
110115
"disableSuggestions": "global apexskier.typescript.config.userPreferences.disableSuggestions boolean",
111116
"displayPartsForJSDoc": "global apexskier.typescript.config.userPreferences.displayPartsForJSDoc boolean",
112117
"generateReturnInDocTemplate": "global apexskier.typescript.config.userPreferences.generateReturnInDocTemplate boolean",
@@ -126,6 +131,7 @@ describe("tsUserPreferences", () => {
126131
"includeInlayParameterNameHintsWhenArgumentMatchesName": "global apexskier.typescript.config.userPreferences.includeInlayParameterNameHintsWhenArgumentMatchesName boolean",
127132
"includeInlayPropertyDeclarationTypeHints": "global apexskier.typescript.config.userPreferences.includeInlayPropertyDeclarationTypeHints boolean",
128133
"includeInlayVariableTypeHints": "global apexskier.typescript.config.userPreferences.includeInlayVariableTypeHints boolean",
134+
"includeInlayVariableTypeHintsWhenTypeMatchesName": "global apexskier.typescript.config.userPreferences.includeInlayVariableTypeHintsWhenTypeMatchesName boolean",
129135
"includePackageJsonAutoImports": "global apexskier.typescript.config.userPreferences.includePackageJsonAutoImports string",
130136
"jsxAttributeCompletionStyle": "global apexskier.typescript.config.userPreferences.jsxAttributeCompletionStyle string",
131137
"lazyConfiguredProjectsFromExternalProject": "global apexskier.typescript.config.userPreferences.lazyConfiguredProjectsFromExternalProject boolean",
@@ -149,6 +155,8 @@ describe("tsUserPreferences", () => {
149155
"allowIncompleteCompletions": "workspace apexskier.typescript.config.userPreferences.allowIncompleteCompletions boolean",
150156
"allowRenameOfImportPath": "workspace apexskier.typescript.config.userPreferences.allowRenameOfImportPath boolean",
151157
"allowTextChangesInNewFiles": "workspace apexskier.typescript.config.userPreferences.allowTextChangesInNewFiles boolean",
158+
"autoImportFileExcludePatterns": "workspace apexskier.typescript.config.userPreferences.autoImportFileExcludePatterns stringArray",
159+
"disableLineTextInReferences": "workspace apexskier.typescript.config.userPreferences.disableLineTextInReferences boolean",
152160
"disableSuggestions": "workspace apexskier.typescript.config.userPreferences.disableSuggestions boolean",
153161
"displayPartsForJSDoc": "workspace apexskier.typescript.config.userPreferences.displayPartsForJSDoc boolean",
154162
"generateReturnInDocTemplate": "workspace apexskier.typescript.config.userPreferences.generateReturnInDocTemplate boolean",
@@ -168,6 +176,7 @@ describe("tsUserPreferences", () => {
168176
"includeInlayParameterNameHintsWhenArgumentMatchesName": "workspace apexskier.typescript.config.userPreferences.includeInlayParameterNameHintsWhenArgumentMatchesName boolean",
169177
"includeInlayPropertyDeclarationTypeHints": "workspace apexskier.typescript.config.userPreferences.includeInlayPropertyDeclarationTypeHints boolean",
170178
"includeInlayVariableTypeHints": "workspace apexskier.typescript.config.userPreferences.includeInlayVariableTypeHints boolean",
179+
"includeInlayVariableTypeHintsWhenTypeMatchesName": "workspace apexskier.typescript.config.userPreferences.includeInlayVariableTypeHintsWhenTypeMatchesName boolean",
171180
"includePackageJsonAutoImports": "workspace apexskier.typescript.config.userPreferences.includePackageJsonAutoImports string",
172181
"jsxAttributeCompletionStyle": "workspace apexskier.typescript.config.userPreferences.jsxAttributeCompletionStyle string",
173182
"lazyConfiguredProjectsFromExternalProject": "workspace apexskier.typescript.config.userPreferences.lazyConfiguredProjectsFromExternalProject boolean",

src/tsUserPreferences.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,15 @@ const keys: {
1212
? "boolean"
1313
: UserPreferences[key] extends string | undefined
1414
? "string"
15+
: UserPreferences[key] extends string[] | undefined
16+
? "stringArray"
1517
: never;
1618
} & Record<keyof UserPreferences, string> = {
1719
allowIncompleteCompletions: "boolean",
1820
allowRenameOfImportPath: "boolean",
1921
allowTextChangesInNewFiles: "boolean",
22+
autoImportFileExcludePatterns: "stringArray",
23+
disableLineTextInReferences: "boolean",
2024
disableSuggestions: "boolean",
2125
displayPartsForJSDoc: "boolean",
2226
generateReturnInDocTemplate: "boolean",
@@ -36,6 +40,7 @@ const keys: {
3640
includeInlayParameterNameHintsWhenArgumentMatchesName: "boolean",
3741
includeInlayPropertyDeclarationTypeHints: "boolean",
3842
includeInlayVariableTypeHints: "boolean",
43+
includeInlayVariableTypeHintsWhenTypeMatchesName: "boolean",
3944
includePackageJsonAutoImports: "string",
4045
jsxAttributeCompletionStyle: "string",
4146
lazyConfiguredProjectsFromExternalProject: "boolean",

typescript.novaextension/extension.json

Lines changed: 176 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,28 @@
111111
"description": "Unless this option is `false`, or `includeCompletionsWithInsertText` is not enabled, member completion lists triggered with `.` will include entries on potentially-null and potentially-undefined values, with insertion text to replace preceding `.` tokens with `?.`.",
112112
"type": "boolean"
113113
},
114+
{
115+
"key": "apexskier.typescript.config.userPreferences.includeCompletionsWithClassMemberSnippets",
116+
"title": "Include completions with class member snippets",
117+
"description": "If enabled, completions for class members (e.g. methods and properties) will include a whole declaration for the member. E.g., `class A { f| }` could be completed to `class A { foo(): number {} }`, instead of `class A { foo }`.",
118+
"type": "boolean"
119+
},
120+
{
121+
"key": "apexskier.typescript.config.userPreferences.includeCompletionsWithObjectLiteralMethodSnippets",
122+
"title": "Include completions with class member snippets",
123+
"description": "If enabled, object literal methods will have a method declaration completion entry in addition to the regular completion entry containing just the method name. E.g., `const objectLiteral: T = { f| }` could be completed to `const objectLiteral: T = { foo(): void {} }`, in addition to `const objectLiteral: T = { foo }`.",
124+
"type": "boolean"
125+
},
126+
{
127+
"key": "apexskier.typescript.config.userPreferences.useLabelDetailsInCompletionEntries",
128+
"title": "Use label details in completion entries",
129+
"type": "boolean"
130+
},
131+
{
132+
"key": "apexskier.typescript.config.userPreferences.allowIncompleteCompletions",
133+
"title": "Allow incomplete completions",
134+
"type": "boolean"
135+
},
114136
{
115137
"key": "apexskier.typescript.config.userPreferences.importModuleSpecifierPreference",
116138
"title": "Import module specifier",
@@ -144,7 +166,7 @@
144166
},
145167
{
146168
"key": "apexskier.typescript.config.userPreferences.lazyConfiguredProjectsFromExternalProject",
147-
"title": "Lazy configured projects from external projects",
169+
"title": "Lazy configured projects from external project",
148170
"type": "boolean"
149171
},
150172
{
@@ -173,6 +195,17 @@
173195
],
174196
"default": "auto"
175197
},
198+
{
199+
"key": "apexskier.typescript.config.userPreferences.jsxAttributeCompletionStyle",
200+
"title": "jsx attribute completion style",
201+
"type": "enum",
202+
"values": [
203+
["auto", "Automatic"],
204+
["braces", "Braces"],
205+
["none", "None"]
206+
],
207+
"default": "auto"
208+
},
176209
{
177210
"key": "apexskier.typescript.config.userPreferences.displayPartsForJSDoc",
178211
"title": "Display parts for JSDoc",
@@ -182,6 +215,63 @@
182215
"key": "apexskier.typescript.config.userPreferences.generateReturnInDocTemplate",
183216
"title": "Generate return in documentation templates",
184217
"type": "boolean"
218+
},
219+
{
220+
"key": "apexskier.typescript.config.userPreferences.includeInlayParameterNameHints",
221+
"title": "Include inlay parameter name hints",
222+
"type": "enum",
223+
"values": [
224+
["none", "None"],
225+
["literals", "Literals"],
226+
["all", "All"]
227+
],
228+
"default": "none"
229+
},
230+
{
231+
"key": "apexskier.typescript.config.userPreferences.includeInlayParameterNameHintsWhenArgumentMatchesName",
232+
"title": "Include inlay parameter name hints when argument matches name",
233+
"type": "boolean"
234+
},
235+
{
236+
"key": "apexskier.typescript.config.userPreferences.includeInlayFunctionParameterTypeHints",
237+
"title": "Include inlay function parameter type hints",
238+
"type": "boolean"
239+
},
240+
{
241+
"key": "apexskier.typescript.config.userPreferences.includeInlayVariableTypeHints",
242+
"title": "Include inlay variable type hints",
243+
"type": "boolean"
244+
},
245+
{
246+
"key": "apexskier.typescript.config.userPreferences.includeInlayVariableTypeHintsWhenTypeMatchesName",
247+
"title": "Include inlay variable type hints when type matches name",
248+
"type": "boolean"
249+
},
250+
{
251+
"key": "apexskier.typescript.config.userPreferences.includeInlayPropertyDeclarationTypeHints",
252+
"title": "Include inlay property declaration type hints",
253+
"type": "boolean"
254+
},
255+
{
256+
"key": "apexskier.typescript.config.userPreferences.includeInlayFunctionLikeReturnTypeHints",
257+
"title": "Include inlay function like return type hints",
258+
"type": "boolean"
259+
},
260+
{
261+
"key": "apexskier.typescript.config.userPreferences.includeInlayEnumMemberValueHints",
262+
"title": "Include inlay enum member value hints",
263+
"type": "boolean"
264+
},
265+
{
266+
"key": "apexskier.typescript.config.userPreferences.autoImportFileExcludePatterns",
267+
"title": "Auto import file exclude patterns",
268+
"type": "stringArray"
269+
},
270+
{
271+
"key": "apexskier.typescript.config.userPreferences.disableLineTextInReferences",
272+
"title": "Disable line text in references",
273+
"description": "Indicates whether ReferenceResponseItem.lineText is supported.",
274+
"type": "boolean"
185275
}
186276
]
187277
},
@@ -313,6 +403,22 @@
313403
"description": "Unless this option is `false`, or `includeCompletionsWithInsertText` is not enabled, member completion lists triggered with `.` will include entries on potentially-null and potentially-undefined values, with insertion text to replace preceding `.` tokens with `?.`.",
314404
"type": "boolean"
315405
},
406+
{
407+
"key": "apexskier.typescript.config.userPreferences.includeCompletionsWithObjectLiteralMethodSnippets",
408+
"title": "Include completions with class member snippets",
409+
"description": "If enabled, object literal methods will have a method declaration completion entry in addition to the regular completion entry containing just the method name. E.g., `const objectLiteral: T = { f| }` could be completed to `const objectLiteral: T = { foo(): void {} }`, in addition to `const objectLiteral: T = { foo }`.",
410+
"type": "boolean"
411+
},
412+
{
413+
"key": "apexskier.typescript.config.userPreferences.useLabelDetailsInCompletionEntries",
414+
"title": "Use label details in completion entries",
415+
"type": "boolean"
416+
},
417+
{
418+
"key": "apexskier.typescript.config.userPreferences.allowIncompleteCompletions",
419+
"title": "Allow incomplete completions",
420+
"type": "boolean"
421+
},
316422
{
317423
"key": "apexskier.typescript.config.userPreferences.importModuleSpecifierPreference",
318424
"title": "Import module specifier",
@@ -346,7 +452,7 @@
346452
},
347453
{
348454
"key": "apexskier.typescript.config.userPreferences.lazyConfiguredProjectsFromExternalProject",
349-
"title": "Lazy configured projects from external projects",
455+
"title": "Lazy configured projects from external project",
350456
"type": "boolean"
351457
},
352458
{
@@ -375,6 +481,17 @@
375481
],
376482
"default": "auto"
377483
},
484+
{
485+
"key": "apexskier.typescript.config.userPreferences.jsxAttributeCompletionStyle",
486+
"title": "jsx attribute completion style",
487+
"type": "enum",
488+
"values": [
489+
["auto", "Automatic"],
490+
["braces", "Braces"],
491+
["none", "None"]
492+
],
493+
"default": "auto"
494+
},
378495
{
379496
"key": "apexskier.typescript.config.userPreferences.displayPartsForJSDoc",
380497
"title": "Display parts for JSDoc",
@@ -384,6 +501,63 @@
384501
"key": "apexskier.typescript.config.userPreferences.generateReturnInDocTemplate",
385502
"title": "Generate return in documentation templates",
386503
"type": "boolean"
504+
},
505+
{
506+
"key": "apexskier.typescript.config.userPreferences.includeInlayParameterNameHints",
507+
"title": "Include inlay parameter name hints",
508+
"type": "enum",
509+
"values": [
510+
["none", "None"],
511+
["literals", "Literals"],
512+
["all", "All"]
513+
],
514+
"default": "none"
515+
},
516+
{
517+
"key": "apexskier.typescript.config.userPreferences.includeInlayParameterNameHintsWhenArgumentMatchesName",
518+
"title": "Include inlay parameter name hints when argument matches name",
519+
"type": "boolean"
520+
},
521+
{
522+
"key": "apexskier.typescript.config.userPreferences.includeInlayFunctionParameterTypeHints",
523+
"title": "Include inlay function parameter type hints",
524+
"type": "boolean"
525+
},
526+
{
527+
"key": "apexskier.typescript.config.userPreferences.includeInlayVariableTypeHints",
528+
"title": "Include inlay variable type hints",
529+
"type": "boolean"
530+
},
531+
{
532+
"key": "apexskier.typescript.config.userPreferences.includeInlayVariableTypeHintsWhenTypeMatchesName",
533+
"title": "Include inlay variable type hints when type matches name",
534+
"type": "boolean"
535+
},
536+
{
537+
"key": "apexskier.typescript.config.userPreferences.includeInlayPropertyDeclarationTypeHints",
538+
"title": "Include inlay property declaration type hints",
539+
"type": "boolean"
540+
},
541+
{
542+
"key": "apexskier.typescript.config.userPreferences.includeInlayFunctionLikeReturnTypeHints",
543+
"title": "Include inlay function like return type hints",
544+
"type": "boolean"
545+
},
546+
{
547+
"key": "apexskier.typescript.config.userPreferences.includeInlayEnumMemberValueHints",
548+
"title": "Include inlay enum member value hints",
549+
"type": "boolean"
550+
},
551+
{
552+
"key": "apexskier.typescript.config.userPreferences.autoImportFileExcludePatterns",
553+
"title": "Auto import file exclude patterns",
554+
"type": "stringArray"
555+
},
556+
{
557+
"key": "apexskier.typescript.config.userPreferences.disableLineTextInReferences",
558+
"title": "Disable line text in references",
559+
"description": "Indicates whether ReferenceResponseItem.lineText is supported.",
560+
"type": "boolean"
387561
}
388562
]
389563
}

typescript.novaextension/run.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#!/usr/bin/env bash
22

33
# note: any output from this script will be used by nova's language server, so it'll break functionality
4+
# to get logging in the extension console, pipe to stderr by prefixing with `>&2 `
45

56
cd "$WORKSPACE_DIR"
67

yarn.lock

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4157,10 +4157,10 @@ typedarray-to-buffer@^3.1.5:
41574157
dependencies:
41584158
is-typedarray "^1.0.0"
41594159

4160-
typescript@^4.7.4:
4161-
version "4.7.4"
4162-
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.7.4.tgz#1a88596d1cf47d59507a1bcdfb5b9dfe4d488235"
4163-
integrity sha512-C0WQT0gezHuw6AdY1M2jxUO83Rjf0HP7Sk1DtXj6j1EwkQNZrHAg2XPWlq62oqEhYvONq5pkC2Y9oPljWToLmQ==
4160+
typescript@^4.9.4:
4161+
version "4.9.4"
4162+
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.9.4.tgz#a2a3d2756c079abda241d75f149df9d561091e78"
4163+
integrity sha512-Uz+dTXYzxXXbsFpM86Wh3dKCxrQqUcVMxwU54orwlJjOpO3ao8L7j5lH+dWfTwgCwIuM9GQ2kvVotzYJMXTBZg==
41644164

41654165
union-value@^1.0.0:
41664166
version "1.0.1"

0 commit comments

Comments
 (0)