@theia/plugin 1.65.0-next.6 → 1.65.1
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/package.json +3 -3
- package/src/theia.d.ts +254 -7
- package/src/theia.proposed.interactiveWindow.d.ts +43 -0
- package/src/theia.proposed.scmProviderOptions.d.ts +56 -0
- package/src/theia.proposed.terminalCompletionProvider.d.ts +15 -3
- package/src/theia.proposed.textEditorDiffInformation.d.ts +64 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theia/plugin",
|
|
3
|
-
"version": "1.65.
|
|
3
|
+
"version": "1.65.1",
|
|
4
4
|
"description": "Theia - Plugin API",
|
|
5
5
|
"types": "./src/theia.d.ts",
|
|
6
6
|
"publishConfig": {
|
|
@@ -27,10 +27,10 @@
|
|
|
27
27
|
"watch": "theiaext watch"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@theia/ext-scripts": "1.
|
|
30
|
+
"@theia/ext-scripts": "1.65.1"
|
|
31
31
|
},
|
|
32
32
|
"nyc": {
|
|
33
33
|
"extends": "../../configs/nyc.json"
|
|
34
34
|
},
|
|
35
|
-
"gitHead": "
|
|
35
|
+
"gitHead": "ed70d58fe5ef87606f903ea92fcb684e83f5354f"
|
|
36
36
|
}
|
package/src/theia.d.ts
CHANGED
|
@@ -31,6 +31,7 @@ import './theia.proposed.extensionsAny';
|
|
|
31
31
|
import './theia.proposed.externalUriOpener';
|
|
32
32
|
import './theia.proposed.findTextInFiles';
|
|
33
33
|
import './theia.proposed.fsChunks';
|
|
34
|
+
import './theia.proposed.interactiveWindow';
|
|
34
35
|
import './theia.proposed.mappedEditsProvider';
|
|
35
36
|
import './theia.proposed.multiDocumentHighlightProvider';
|
|
36
37
|
import './theia.proposed.notebookCellExecutionState';
|
|
@@ -39,10 +40,12 @@ import './theia.proposed.notebookMessaging';
|
|
|
39
40
|
import './theia.proposed.portsAttributes';
|
|
40
41
|
import './theia.proposed.profileContentHandlers';
|
|
41
42
|
import './theia.proposed.resolvers';
|
|
43
|
+
import './theia.proposed.scmProviderOptions';
|
|
42
44
|
import './theia.proposed.scmValidation';
|
|
43
45
|
import './theia.proposed.shareProvider';
|
|
44
46
|
import './theia.proposed.terminalCompletionProvider';
|
|
45
47
|
import './theia.proposed.terminalQuickFixProvider';
|
|
48
|
+
import './theia.proposed.textEditorDiffInformation';
|
|
46
49
|
import './theia.proposed.textSearchProvider';
|
|
47
50
|
import './theia.proposed.timeline';
|
|
48
51
|
|
|
@@ -3596,6 +3599,20 @@ export module '@theia/plugin' {
|
|
|
3596
3599
|
* recommended for the best contrast and consistency across themes.
|
|
3597
3600
|
*/
|
|
3598
3601
|
color?: ThemeColor;
|
|
3602
|
+
|
|
3603
|
+
/**
|
|
3604
|
+
* The nonce to use to verify shell integration sequences are coming from a trusted source.
|
|
3605
|
+
* An example impact of UX of this is if the command line is reported with a nonce, it will
|
|
3606
|
+
* not need to verify with the user that the command line is correct before rerunning it
|
|
3607
|
+
* via the [shell integration command decoration](https://code.visualstudio.com/docs/terminal/shell-integration#_command-decorations-and-the-overview-ruler).
|
|
3608
|
+
*
|
|
3609
|
+
* This should be used if the terminal includes [custom shell integration support](https://code.visualstudio.com/docs/terminal/shell-integration#_supported-escape-sequences).
|
|
3610
|
+
* It should be set to a random GUID which will then set the `VSCODE_NONCE` environment
|
|
3611
|
+
* variable. Inside the shell, this should then be removed from the environment so as to
|
|
3612
|
+
* protect it from general access. Once that is done it can be passed through in the
|
|
3613
|
+
* relevant sequences to make them trusted.
|
|
3614
|
+
*/
|
|
3615
|
+
shellIntegrationNonce?: string;
|
|
3599
3616
|
}
|
|
3600
3617
|
|
|
3601
3618
|
/**
|
|
@@ -3717,6 +3734,18 @@ export module '@theia/plugin' {
|
|
|
3717
3734
|
* @stubbed
|
|
3718
3735
|
*/
|
|
3719
3736
|
color?: ThemeColor;
|
|
3737
|
+
|
|
3738
|
+
/**
|
|
3739
|
+
* The nonce to use to verify shell integration sequences are coming from a trusted source.
|
|
3740
|
+
* An example impact of UX of this is if the command line is reported with a nonce, it will
|
|
3741
|
+
* not need to verify with the user that the command line is correct before rerunning it
|
|
3742
|
+
* via the [shell integration command decoration](https://code.visualstudio.com/docs/terminal/shell-integration#_command-decorations-and-the-overview-ruler).
|
|
3743
|
+
*
|
|
3744
|
+
* This should be used if the terminal includes [custom shell integration support](https://code.visualstudio.com/docs/terminal/shell-integration#_supported-escape-sequences).
|
|
3745
|
+
* It should be set to a random GUID. Inside the {@link Pseudoterminal} implementation, this value
|
|
3746
|
+
* can be passed through in the relevant sequences to make them trusted.
|
|
3747
|
+
*/
|
|
3748
|
+
shellIntegrationNonce?: string;
|
|
3720
3749
|
}
|
|
3721
3750
|
|
|
3722
3751
|
/**
|
|
@@ -12092,12 +12121,12 @@ export module '@theia/plugin' {
|
|
|
12092
12121
|
*/
|
|
12093
12122
|
export class EvaluatableExpression {
|
|
12094
12123
|
|
|
12095
|
-
|
|
12124
|
+
/**
|
|
12096
12125
|
* The range is used to extract the evaluatable expression from the underlying document and to highlight it.
|
|
12097
12126
|
*/
|
|
12098
12127
|
readonly range: Range;
|
|
12099
12128
|
|
|
12100
|
-
|
|
12129
|
+
/**
|
|
12101
12130
|
* If specified the expression overrides the extracted expression.
|
|
12102
12131
|
*/
|
|
12103
12132
|
readonly expression?: string | undefined;
|
|
@@ -17811,7 +17840,7 @@ export module '@theia/plugin' {
|
|
|
17811
17840
|
* Creates a {@link FileCoverage} instance with counts filled in from
|
|
17812
17841
|
* the coverage details.
|
|
17813
17842
|
* @param uri Covered file URI
|
|
17814
|
-
* @param
|
|
17843
|
+
* @param details Detailed coverage information
|
|
17815
17844
|
*/
|
|
17816
17845
|
static fromDetails(uri: Uri, details: readonly FileCoverageDetail[]): FileCoverage;
|
|
17817
17846
|
|
|
@@ -18592,7 +18621,7 @@ export module '@theia/plugin' {
|
|
|
18592
18621
|
* specific for some models.
|
|
18593
18622
|
* @stubbed
|
|
18594
18623
|
*/
|
|
18595
|
-
content: Array<
|
|
18624
|
+
content: Array<LanguageModelInputPart>;
|
|
18596
18625
|
|
|
18597
18626
|
/**
|
|
18598
18627
|
* The optional name of a user for this message.
|
|
@@ -18608,9 +18637,21 @@ export module '@theia/plugin' {
|
|
|
18608
18637
|
* @param content The content of the message.
|
|
18609
18638
|
* @param name The optional name of a user for the message.
|
|
18610
18639
|
*/
|
|
18611
|
-
constructor(role: LanguageModelChatMessageRole, content: string | Array<
|
|
18640
|
+
constructor(role: LanguageModelChatMessageRole, content: string | Array<LanguageModelInputPart>, name?: string);
|
|
18612
18641
|
}
|
|
18613
18642
|
|
|
18643
|
+
/**
|
|
18644
|
+
* The various message types which a {@linkcode LanguageModelChatProvider} can emit in the chat response stream
|
|
18645
|
+
* @stubbed
|
|
18646
|
+
*/
|
|
18647
|
+
export type LanguageModelResponsePart = LanguageModelTextPart | LanguageModelToolResultPart | LanguageModelToolCallPart;
|
|
18648
|
+
|
|
18649
|
+
/**
|
|
18650
|
+
* The various message types which can be sent via {@linkcode LanguageModelChat.sendRequest } and processed by a {@linkcode LanguageModelChatProvider}
|
|
18651
|
+
* @stubbed
|
|
18652
|
+
*/
|
|
18653
|
+
export type LanguageModelInputPart = LanguageModelTextPart | LanguageModelToolResultPart | LanguageModelToolCallPart;
|
|
18654
|
+
|
|
18614
18655
|
/**
|
|
18615
18656
|
* Represents a language model response.
|
|
18616
18657
|
*
|
|
@@ -18999,6 +19040,202 @@ export module '@theia/plugin' {
|
|
|
18999
19040
|
*/
|
|
19000
19041
|
resolveMcpServerDefinition?(server: T, token: CancellationToken): ProviderResult<T>;
|
|
19001
19042
|
}
|
|
19043
|
+
|
|
19044
|
+
/**
|
|
19045
|
+
* The provider version of {@linkcode LanguageModelChatRequestOptions}
|
|
19046
|
+
* @stubbed
|
|
19047
|
+
*/
|
|
19048
|
+
export interface ProvideLanguageModelChatResponseOptions {
|
|
19049
|
+
/**
|
|
19050
|
+
* A set of options that control the behavior of the language model. These options are specific to the language model.
|
|
19051
|
+
* @stubbed
|
|
19052
|
+
*/
|
|
19053
|
+
readonly modelOptions?: { readonly [name: string]: any };
|
|
19054
|
+
|
|
19055
|
+
/**
|
|
19056
|
+
* An optional list of tools that are available to the language model. These could be registered tools available via
|
|
19057
|
+
* {@link lm.tools}, or private tools that are just implemented within the calling extension.
|
|
19058
|
+
*
|
|
19059
|
+
* If the LLM requests to call one of these tools, it will return a {@link LanguageModelToolCallPart} in
|
|
19060
|
+
* {@link LanguageModelChatResponse.stream}. It's the caller's responsibility to invoke the tool. If it's a tool
|
|
19061
|
+
* registered in {@link lm.tools}, that means calling {@link lm.invokeTool}.
|
|
19062
|
+
*
|
|
19063
|
+
* Then, the tool result can be provided to the LLM by creating an Assistant-type {@link LanguageModelChatMessage} with a
|
|
19064
|
+
* {@link LanguageModelToolCallPart}, followed by a User-type message with a {@link LanguageModelToolResultPart}.
|
|
19065
|
+
* @stubbed
|
|
19066
|
+
*/
|
|
19067
|
+
readonly tools?: readonly LanguageModelChatTool[];
|
|
19068
|
+
|
|
19069
|
+
/**
|
|
19070
|
+
* The tool-selecting mode to use. The provider must implement respecting this.
|
|
19071
|
+
* @stubbed
|
|
19072
|
+
*/
|
|
19073
|
+
readonly toolMode: LanguageModelChatToolMode;
|
|
19074
|
+
}
|
|
19075
|
+
|
|
19076
|
+
/**
|
|
19077
|
+
* Represents a language model provided by a {@linkcode LanguageModelChatProvider}.
|
|
19078
|
+
* @stubbed
|
|
19079
|
+
*/
|
|
19080
|
+
export interface LanguageModelChatInformation {
|
|
19081
|
+
|
|
19082
|
+
/**
|
|
19083
|
+
* Unique identifier for the language model. Must be unique per provider, but not required to be globally unique.
|
|
19084
|
+
* @stubbed
|
|
19085
|
+
*/
|
|
19086
|
+
readonly id: string;
|
|
19087
|
+
|
|
19088
|
+
/**
|
|
19089
|
+
* Human-readable name of the language model.
|
|
19090
|
+
* @stubbed
|
|
19091
|
+
*/
|
|
19092
|
+
readonly name: string;
|
|
19093
|
+
|
|
19094
|
+
/**
|
|
19095
|
+
* Opaque family-name of the language model. Values might be `gpt-3.5-turbo`, `gpt4`, `phi2`, or `llama`
|
|
19096
|
+
* @stubbed
|
|
19097
|
+
*/
|
|
19098
|
+
readonly family: string;
|
|
19099
|
+
|
|
19100
|
+
/**
|
|
19101
|
+
* The tooltip to render when hovering the model. Used to provide more information about the model.
|
|
19102
|
+
* @stubbed
|
|
19103
|
+
*/
|
|
19104
|
+
readonly tooltip?: string;
|
|
19105
|
+
|
|
19106
|
+
/**
|
|
19107
|
+
* An optional, human-readable string which will be rendered alongside the model.
|
|
19108
|
+
* Useful for distinguishing models of the same name in the UI.
|
|
19109
|
+
* @stubbed
|
|
19110
|
+
*/
|
|
19111
|
+
readonly detail?: string;
|
|
19112
|
+
|
|
19113
|
+
/**
|
|
19114
|
+
* Opaque version string of the model.
|
|
19115
|
+
* This is used as a lookup value in {@linkcode LanguageModelChatSelector.version}
|
|
19116
|
+
* An example is how GPT 4o has multiple versions like 2024-11-20 and 2024-08-06
|
|
19117
|
+
* @stubbed
|
|
19118
|
+
*/
|
|
19119
|
+
readonly version: string;
|
|
19120
|
+
|
|
19121
|
+
/**
|
|
19122
|
+
* The maximum number of tokens the model can accept as input.
|
|
19123
|
+
* @stubbed
|
|
19124
|
+
*/
|
|
19125
|
+
readonly maxInputTokens: number;
|
|
19126
|
+
|
|
19127
|
+
/**
|
|
19128
|
+
* The maximum number of tokens the model is capable of producing.
|
|
19129
|
+
* @stubbed
|
|
19130
|
+
*/
|
|
19131
|
+
readonly maxOutputTokens: number;
|
|
19132
|
+
|
|
19133
|
+
/**
|
|
19134
|
+
* Various features that the model supports such as tool calling or image input.
|
|
19135
|
+
* @stubbed
|
|
19136
|
+
*/
|
|
19137
|
+
readonly capabilities: {
|
|
19138
|
+
|
|
19139
|
+
/**
|
|
19140
|
+
* Whether image input is supported by the model.
|
|
19141
|
+
* Common supported images are jpg and png, but each model will vary in supported mimetypes.
|
|
19142
|
+
* @stubbed
|
|
19143
|
+
*/
|
|
19144
|
+
readonly imageInput?: boolean;
|
|
19145
|
+
|
|
19146
|
+
/**
|
|
19147
|
+
* Whether tool calling is supported by the model.
|
|
19148
|
+
* If a number is provided, that is the maximum number of tools that can be provided in a request to the model.
|
|
19149
|
+
* @stubbed
|
|
19150
|
+
*/
|
|
19151
|
+
readonly toolCalling?: boolean | number;
|
|
19152
|
+
};
|
|
19153
|
+
}
|
|
19154
|
+
|
|
19155
|
+
/**
|
|
19156
|
+
* The provider version of {@linkcode LanguageModelChatMessage}.
|
|
19157
|
+
* @stubbed
|
|
19158
|
+
*/
|
|
19159
|
+
export interface LanguageModelChatRequestMessage {
|
|
19160
|
+
/**
|
|
19161
|
+
* The role of this message.
|
|
19162
|
+
* @stubbed
|
|
19163
|
+
*/
|
|
19164
|
+
readonly role: LanguageModelChatMessageRole;
|
|
19165
|
+
|
|
19166
|
+
/**
|
|
19167
|
+
* A heterogeneous array of things that a message can contain as content. Some parts may be message-type
|
|
19168
|
+
* specific for some models.
|
|
19169
|
+
* @stubbed
|
|
19170
|
+
*/
|
|
19171
|
+
readonly content: ReadonlyArray<LanguageModelInputPart | unknown>;
|
|
19172
|
+
|
|
19173
|
+
/**
|
|
19174
|
+
* The optional name of a user for this message.
|
|
19175
|
+
* @stubbed
|
|
19176
|
+
*/
|
|
19177
|
+
readonly name: string | undefined;
|
|
19178
|
+
}
|
|
19179
|
+
|
|
19180
|
+
/**
|
|
19181
|
+
* A LanguageModelChatProvider implements access to language models, which users can then use through the chat view, or through extension API by acquiring a LanguageModelChat.
|
|
19182
|
+
* An example of this would be an OpenAI provider that provides models like gpt-5, o3, etc.
|
|
19183
|
+
* @stubbed
|
|
19184
|
+
*/
|
|
19185
|
+
export interface LanguageModelChatProvider<T extends LanguageModelChatInformation = LanguageModelChatInformation> {
|
|
19186
|
+
|
|
19187
|
+
/**
|
|
19188
|
+
* An optional event fired when the available set of language models changes.
|
|
19189
|
+
* @stubbed
|
|
19190
|
+
*/
|
|
19191
|
+
readonly onDidChangeLanguageModelChatInformation?: Event<void>;
|
|
19192
|
+
|
|
19193
|
+
/**
|
|
19194
|
+
* Get the list of available language models provided by this provider
|
|
19195
|
+
* @param options Options which specify the calling context of this function
|
|
19196
|
+
* @param token A cancellation token
|
|
19197
|
+
* @returns The list of available language models
|
|
19198
|
+
* @stubbed
|
|
19199
|
+
*/
|
|
19200
|
+
provideLanguageModelChatInformation(options: PrepareLanguageModelChatModelOptions, token: CancellationToken): ProviderResult<T[]>;
|
|
19201
|
+
|
|
19202
|
+
/**
|
|
19203
|
+
* Returns the response for a chat request, passing the results to the progress callback.
|
|
19204
|
+
* The {@linkcode LanguageModelChatProvider} must emit the response parts to the progress callback as they are received from the language model.
|
|
19205
|
+
* @param model The language model to use
|
|
19206
|
+
* @param messages The messages to include in the request
|
|
19207
|
+
* @param options Options for the request
|
|
19208
|
+
* @param progress The progress to emit the streamed response chunks to
|
|
19209
|
+
* @param token A cancellation token
|
|
19210
|
+
* @returns A promise that resolves when the response is complete. Results are actually passed to the progress callback.
|
|
19211
|
+
* @stubbed
|
|
19212
|
+
*/
|
|
19213
|
+
provideLanguageModelChatResponse(model: T, messages: readonly LanguageModelChatRequestMessage[], options: ProvideLanguageModelChatResponseOptions, progress: Progress<LanguageModelResponsePart>, token: CancellationToken): Thenable<void>;
|
|
19214
|
+
|
|
19215
|
+
/**
|
|
19216
|
+
* Returns the number of tokens for a given text using the model-specific tokenizer logic
|
|
19217
|
+
* @param model The language model to use
|
|
19218
|
+
* @param text The text to count tokens for
|
|
19219
|
+
* @param token A cancellation token
|
|
19220
|
+
* @returns The number of tokens
|
|
19221
|
+
* @stubbed
|
|
19222
|
+
*/
|
|
19223
|
+
provideTokenCount(model: T, text: string | LanguageModelChatRequestMessage, token: CancellationToken): Thenable<number>;
|
|
19224
|
+
}
|
|
19225
|
+
|
|
19226
|
+
/**
|
|
19227
|
+
* The list of options passed into {@linkcode LanguageModelChatProvider.provideLanguageModelChatInformation}
|
|
19228
|
+
* @stubbed
|
|
19229
|
+
*/
|
|
19230
|
+
export interface PrepareLanguageModelChatModelOptions {
|
|
19231
|
+
/**
|
|
19232
|
+
* Whether or not the user should be prompted via some UI flow, or if models should be attempted to be resolved silently.
|
|
19233
|
+
* If silent is true, all models may not be resolved due to lack of info such as API keys.
|
|
19234
|
+
* @stubbed
|
|
19235
|
+
*/
|
|
19236
|
+
readonly silent: boolean;
|
|
19237
|
+
}
|
|
19238
|
+
|
|
19002
19239
|
/**
|
|
19003
19240
|
* Namespace for language model related functionality.
|
|
19004
19241
|
*/
|
|
@@ -19062,7 +19299,7 @@ export module '@theia/plugin' {
|
|
|
19062
19299
|
* any custom flow.
|
|
19063
19300
|
*
|
|
19064
19301
|
* In the former case, the caller shall pass the
|
|
19065
|
-
* {@link LanguageModelToolInvocationOptions.toolInvocationToken toolInvocationToken}, which comes
|
|
19302
|
+
* {@link LanguageModelToolInvocationOptions.toolInvocationToken toolInvocationToken}, which comes from a
|
|
19066
19303
|
* {@link ChatRequest.toolInvocationToken chat request}. This makes sure the chat UI shows the tool invocation for the
|
|
19067
19304
|
* correct conversation.
|
|
19068
19305
|
*
|
|
@@ -19110,6 +19347,16 @@ export module '@theia/plugin' {
|
|
|
19110
19347
|
* @returns A disposable that unregisters the provider when disposed.
|
|
19111
19348
|
*/
|
|
19112
19349
|
export function registerMcpServerDefinitionProvider(id: string, provider: McpServerDefinitionProvider): Disposable;
|
|
19350
|
+
|
|
19351
|
+
/**
|
|
19352
|
+
* Registers a {@linkcode LanguageModelChatProvider}
|
|
19353
|
+
* Note: You must also define the language model chat provider via the `languageModelChatProviders` contribution point in package.json
|
|
19354
|
+
* @param vendor The vendor for this provider. Must be globally unique. An example is `copilot` or `openai`.
|
|
19355
|
+
* @param provider The provider to register
|
|
19356
|
+
* @returns A disposable that unregisters the provider when disposed
|
|
19357
|
+
* @stubbed
|
|
19358
|
+
*/
|
|
19359
|
+
export function registerLanguageModelChatProvider(vendor: string, provider: LanguageModelChatProvider): Disposable;
|
|
19113
19360
|
}
|
|
19114
19361
|
|
|
19115
19362
|
/**
|
|
@@ -19275,7 +19522,7 @@ export module '@theia/plugin' {
|
|
|
19275
19522
|
|
|
19276
19523
|
/**
|
|
19277
19524
|
* Construct a prompt-tsx part with the given content.
|
|
19278
|
-
* @param value The value of the part, the result of `
|
|
19525
|
+
* @param value The value of the part, the result of `renderElementJSON` from `@vscode/prompt-tsx`.
|
|
19279
19526
|
* @stubbed
|
|
19280
19527
|
*/
|
|
19281
19528
|
constructor(value: unknown);
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2023 Typefox and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// This Source Code may also be made available under the following Secondary
|
|
9
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
// with the GNU Classpath Exception which is available at
|
|
12
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
//
|
|
14
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
|
+
// *****************************************************************************
|
|
16
|
+
|
|
17
|
+
/*---------------------------------------------------------------------------------------------
|
|
18
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
19
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
20
|
+
*--------------------------------------------------------------------------------------------*/
|
|
21
|
+
// code copied and modified from https://github.com/microsoft/vscode/blob/1.103.2/src/vscode-dts/vscode.proposed.interactiveWindow.d.ts
|
|
22
|
+
|
|
23
|
+
export module '@theia/plugin' {
|
|
24
|
+
/**
|
|
25
|
+
* The tab represents an interactive window.
|
|
26
|
+
*/
|
|
27
|
+
export class TabInputInteractiveWindow {
|
|
28
|
+
/**
|
|
29
|
+
* The uri of the history notebook in the interactive window.
|
|
30
|
+
*/
|
|
31
|
+
readonly uri: Uri;
|
|
32
|
+
/**
|
|
33
|
+
* The uri of the input box in the interactive window.
|
|
34
|
+
*/
|
|
35
|
+
readonly inputBoxUri: Uri;
|
|
36
|
+
private constructor(uri: Uri, inputBoxUri: Uri);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export interface Tab {
|
|
40
|
+
readonly input: TabInputText | TabInputTextDiff | TabInputCustom | TabInputWebview | TabInputNotebook
|
|
41
|
+
| TabInputNotebookDiff | TabInputTerminal | TabInputInteractiveWindow | unknown;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2025 STMicroelectronics and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// This Source Code may also be made available under the following Secondary
|
|
9
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
// with the GNU Classpath Exception which is available at
|
|
12
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
//
|
|
14
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
|
+
// *****************************************************************************
|
|
16
|
+
|
|
17
|
+
/*---------------------------------------------------------------------------------------------
|
|
18
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
19
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
20
|
+
*--------------------------------------------------------------------------------------------*/
|
|
21
|
+
// code copied and modified from https://github.com/microsoft/vscode/blob/1.103.2/src/vscode-dts/vscode.proposed.scmProviderOptions.d.ts
|
|
22
|
+
|
|
23
|
+
declare module '@theia/plugin' {
|
|
24
|
+
// https://github.com/microsoft/vscode/issues/254910
|
|
25
|
+
|
|
26
|
+
export interface SourceControl {
|
|
27
|
+
/**
|
|
28
|
+
* Context value of the source control. This can be used to contribute source control specific actions.
|
|
29
|
+
* For example, if a source control is given a context value of `repository`, when contributing actions to `scm/sourceControl/context`
|
|
30
|
+
* using `menus` extension point, you can specify context value for key `scmProviderContext` in `when` expressions, like `scmProviderContext == repository`.
|
|
31
|
+
* ```json
|
|
32
|
+
* "contributes": {
|
|
33
|
+
* "menus": {
|
|
34
|
+
* "scm/sourceControl/context": [
|
|
35
|
+
* {
|
|
36
|
+
* "command": "extension.gitAction",
|
|
37
|
+
* "when": "scmProviderContext == repository"
|
|
38
|
+
* }
|
|
39
|
+
* ]
|
|
40
|
+
* }
|
|
41
|
+
* }
|
|
42
|
+
* ```
|
|
43
|
+
* This will show action `extension.gitAction` only for source controls with `contextValue` equal to `repository`.
|
|
44
|
+
*/
|
|
45
|
+
contextValue?: string;
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Fired when the parent source control is disposed.
|
|
49
|
+
*/
|
|
50
|
+
readonly onDidDisposeParent: Event<void>;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export namespace scm {
|
|
54
|
+
export function createSourceControl(id: string, label: string, rootUri?: Uri, iconPath?: IconPath, parent?: SourceControl): SourceControl;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -69,9 +69,21 @@ declare module '@theia/plugin' {
|
|
|
69
69
|
export enum TerminalCompletionItemKind {
|
|
70
70
|
File = 0,
|
|
71
71
|
Folder = 1,
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
Argument = 4
|
|
72
|
+
Method = 2,
|
|
73
|
+
Alias = 3,
|
|
74
|
+
Argument = 4,
|
|
75
|
+
Option = 5,
|
|
76
|
+
OptionValue = 6,
|
|
77
|
+
Flag = 7,
|
|
78
|
+
SymbolicLinkFile = 8,
|
|
79
|
+
SymbolicLinkFolder = 9,
|
|
80
|
+
Commit = 10,
|
|
81
|
+
Branch = 11,
|
|
82
|
+
Tag = 12,
|
|
83
|
+
Stash = 13,
|
|
84
|
+
Remote = 14,
|
|
85
|
+
PullRequest = 15,
|
|
86
|
+
PullRequestDone = 16,
|
|
75
87
|
}
|
|
76
88
|
|
|
77
89
|
export interface TerminalCompletionContext {
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2025 STMicroelectronics and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// This Source Code may also be made available under the following Secondary
|
|
9
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
// with the GNU Classpath Exception which is available at
|
|
12
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
//
|
|
14
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
|
+
// *****************************************************************************
|
|
16
|
+
|
|
17
|
+
/*---------------------------------------------------------------------------------------------
|
|
18
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
19
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
20
|
+
*--------------------------------------------------------------------------------------------*/
|
|
21
|
+
// code copied and modified from https://github.com/microsoft/vscode/blob/1.103.2/src/vscode-dts/vscode.proposed.textEditorDiffInformation.d.ts
|
|
22
|
+
|
|
23
|
+
declare module '@theia/plugin' {
|
|
24
|
+
// https://github.com/microsoft/vscode/issues/84899
|
|
25
|
+
|
|
26
|
+
export enum TextEditorChangeKind {
|
|
27
|
+
Addition = 1,
|
|
28
|
+
Deletion = 2,
|
|
29
|
+
Modification = 3
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export interface TextEditorLineRange {
|
|
33
|
+
readonly startLineNumber: number;
|
|
34
|
+
readonly endLineNumberExclusive: number;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export interface TextEditorChange {
|
|
38
|
+
readonly original: TextEditorLineRange;
|
|
39
|
+
readonly modified: TextEditorLineRange;
|
|
40
|
+
readonly kind: TextEditorChangeKind;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export interface TextEditorDiffInformation {
|
|
44
|
+
readonly documentVersion: number;
|
|
45
|
+
readonly original: Uri | undefined;
|
|
46
|
+
readonly modified: Uri;
|
|
47
|
+
readonly changes: readonly TextEditorChange[];
|
|
48
|
+
readonly isStale: boolean;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export interface TextEditorDiffInformationChangeEvent {
|
|
52
|
+
readonly textEditor: TextEditor;
|
|
53
|
+
readonly diffInformation: TextEditorDiffInformation[] | undefined;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export interface TextEditor {
|
|
57
|
+
readonly diffInformation: TextEditorDiffInformation[] | undefined;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export namespace window {
|
|
61
|
+
export const onDidChangeTextEditorDiffInformation: Event<TextEditorDiffInformationChangeEvent>;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
}
|