typescript 4.7.0-dev.20220330 → 4.7.0-dev.20220402
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/es/diagnosticMessages.generated.json +1 -0
- package/lib/fr/diagnosticMessages.generated.json +1 -0
- package/lib/it/diagnosticMessages.generated.json +1 -0
- package/lib/ja/diagnosticMessages.generated.json +1 -0
- package/lib/ko/diagnosticMessages.generated.json +1 -0
- package/lib/pl/diagnosticMessages.generated.json +1 -0
- package/lib/protocol.d.ts +23 -0
- package/lib/pt-br/diagnosticMessages.generated.json +1 -0
- package/lib/ru/diagnosticMessages.generated.json +1 -0
- package/lib/tsc.js +38 -6
- package/lib/tsserver.js +183 -93
- package/lib/tsserverlibrary.d.ts +31 -1
- package/lib/tsserverlibrary.js +183 -93
- package/lib/typescript.d.ts +8 -1
- package/lib/typescript.js +165 -91
- package/lib/typescriptServices.d.ts +8 -1
- package/lib/typescriptServices.js +165 -91
- package/lib/typingsInstaller.js +43 -7
- package/lib/zh-cn/diagnosticMessages.generated.json +1 -0
- package/lib/zh-tw/diagnosticMessages.generated.json +1 -0
- package/package.json +1 -1
package/lib/tsserverlibrary.d.ts
CHANGED
|
@@ -2977,6 +2977,7 @@ declare namespace ts {
|
|
|
2977
2977
|
maxNodeModuleJsDepth?: number;
|
|
2978
2978
|
module?: ModuleKind;
|
|
2979
2979
|
moduleResolution?: ModuleResolutionKind;
|
|
2980
|
+
moduleSuffixes?: string[];
|
|
2980
2981
|
moduleDetection?: ModuleDetectionKind;
|
|
2981
2982
|
newLine?: NewLineKind;
|
|
2982
2983
|
noEmit?: boolean;
|
|
@@ -3163,7 +3164,7 @@ declare namespace ts {
|
|
|
3163
3164
|
realpath?(path: string): string;
|
|
3164
3165
|
getCurrentDirectory?(): string;
|
|
3165
3166
|
getDirectories?(path: string): string[];
|
|
3166
|
-
useCaseSensitiveFileNames?: boolean | (() => boolean);
|
|
3167
|
+
useCaseSensitiveFileNames?: boolean | (() => boolean) | undefined;
|
|
3167
3168
|
}
|
|
3168
3169
|
/**
|
|
3169
3170
|
* Used by services to specify the minimum host area required to set up source files under any compilation settings
|
|
@@ -4100,6 +4101,7 @@ declare namespace ts {
|
|
|
4100
4101
|
readonly includeCompletionsWithInsertText?: boolean;
|
|
4101
4102
|
readonly includeCompletionsWithClassMemberSnippets?: boolean;
|
|
4102
4103
|
readonly includeCompletionsWithObjectLiteralMethodSnippets?: boolean;
|
|
4104
|
+
readonly useLabelDetailsInCompletionEntries?: boolean;
|
|
4103
4105
|
readonly allowIncompleteCompletions?: boolean;
|
|
4104
4106
|
readonly importModuleSpecifierPreference?: "shortest" | "project-relative" | "relative" | "non-relative";
|
|
4105
4107
|
/** Determines whether we import `foo/index.ts` as "foo", "foo/index", or "foo/index.js" */
|
|
@@ -6485,6 +6487,7 @@ declare namespace ts {
|
|
|
6485
6487
|
hasAction?: true;
|
|
6486
6488
|
source?: string;
|
|
6487
6489
|
sourceDisplay?: SymbolDisplayPart[];
|
|
6490
|
+
labelDetails?: CompletionEntryLabelDetails;
|
|
6488
6491
|
isRecommended?: true;
|
|
6489
6492
|
isFromUncheckedFile?: true;
|
|
6490
6493
|
isPackageJsonImport?: true;
|
|
@@ -6499,6 +6502,10 @@ declare namespace ts {
|
|
|
6499
6502
|
*/
|
|
6500
6503
|
data?: CompletionEntryData;
|
|
6501
6504
|
}
|
|
6505
|
+
interface CompletionEntryLabelDetails {
|
|
6506
|
+
detail?: string;
|
|
6507
|
+
description?: string;
|
|
6508
|
+
}
|
|
6502
6509
|
interface CompletionEntryDetails {
|
|
6503
6510
|
name: string;
|
|
6504
6511
|
kind: ScriptElementKind;
|
|
@@ -8708,6 +8715,10 @@ declare namespace ts.server.protocol {
|
|
|
8708
8715
|
* Human-readable description of the `source`.
|
|
8709
8716
|
*/
|
|
8710
8717
|
sourceDisplay?: SymbolDisplayPart[];
|
|
8718
|
+
/**
|
|
8719
|
+
* Additional details for the label.
|
|
8720
|
+
*/
|
|
8721
|
+
labelDetails?: CompletionEntryLabelDetails;
|
|
8711
8722
|
/**
|
|
8712
8723
|
* If true, this completion should be highlighted as recommended. There will only be one of these.
|
|
8713
8724
|
* This will be set when we know the user should write an expression with a certain type and that type is an enum or constructable class.
|
|
@@ -8736,6 +8747,20 @@ declare namespace ts.server.protocol {
|
|
|
8736
8747
|
*/
|
|
8737
8748
|
data?: unknown;
|
|
8738
8749
|
}
|
|
8750
|
+
interface CompletionEntryLabelDetails {
|
|
8751
|
+
/**
|
|
8752
|
+
* An optional string which is rendered less prominently directly after
|
|
8753
|
+
* {@link CompletionEntry.name name}, without any spacing. Should be
|
|
8754
|
+
* used for function signatures or type annotations.
|
|
8755
|
+
*/
|
|
8756
|
+
detail?: string;
|
|
8757
|
+
/**
|
|
8758
|
+
* An optional string which is rendered less prominently after
|
|
8759
|
+
* {@link CompletionEntryLabelDetails.detail}. Should be used for fully qualified
|
|
8760
|
+
* names or file path.
|
|
8761
|
+
*/
|
|
8762
|
+
description?: string;
|
|
8763
|
+
}
|
|
8739
8764
|
/**
|
|
8740
8765
|
* Additional completion entry details, available on demand
|
|
8741
8766
|
*/
|
|
@@ -9636,6 +9661,11 @@ declare namespace ts.server.protocol {
|
|
|
9636
9661
|
* in addition to `const objectLiteral: T = { foo }`.
|
|
9637
9662
|
*/
|
|
9638
9663
|
readonly includeCompletionsWithObjectLiteralMethodSnippets?: boolean;
|
|
9664
|
+
/**
|
|
9665
|
+
* Indicates whether {@link CompletionEntry.labelDetails completion entry label details} are supported.
|
|
9666
|
+
* If not, contents of `labelDetails` may be included in the {@link CompletionEntry.name} property.
|
|
9667
|
+
*/
|
|
9668
|
+
readonly useLabelDetailsInCompletionEntries?: boolean;
|
|
9639
9669
|
readonly allowIncompleteCompletions?: boolean;
|
|
9640
9670
|
readonly importModuleSpecifierPreference?: "shortest" | "project-relative" | "relative" | "non-relative";
|
|
9641
9671
|
/** Determines whether we import `foo/index.ts` as "foo", "foo/index", or "foo/index.js" */
|