Consume new VS Code Proposal API (#2166)
* Use new proposal api * Update vscode engine
This commit is contained in:
Родитель
994f65297c
Коммит
aee2408bdf
|
@ -7,7 +7,7 @@
|
|||
"icon": "resources/WebApp.png",
|
||||
"aiKey": "AIF-d9b70cd4-b9f9-4d70-929b-a071c400b217",
|
||||
"engines": {
|
||||
"vscode": "^1.60.0"
|
||||
"vscode": "^1.63.0"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
@ -824,5 +824,7 @@
|
|||
"ms-vscode.azure-account",
|
||||
"ms-azuretools.vscode-azureresourcegroups"
|
||||
],
|
||||
"enableProposedApi": true
|
||||
"enabledApiProposals": [
|
||||
"terminalDataWriteEvent"
|
||||
]
|
||||
}
|
||||
|
|
|
@ -1,42 +0,0 @@
|
|||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
/**
|
||||
* This is the place for API experiments and proposals.
|
||||
* These API are NOT stable and subject to change. They are only available in the Insiders
|
||||
* distribution and CANNOT be used in published extensions.
|
||||
*
|
||||
* To test these API in local environment:
|
||||
* - Use Insiders release of 'VS Code'.
|
||||
* - Add `"enableProposedApi": true` to your package.json.
|
||||
* - Copy this file to your project.
|
||||
*/
|
||||
|
||||
declare module 'vscode' {
|
||||
|
||||
//#region Terminal data write event https://github.com/microsoft/vscode/issues/78502
|
||||
|
||||
export interface TerminalDataWriteEvent {
|
||||
/**
|
||||
* The {@link Terminal} for which the data was written.
|
||||
*/
|
||||
readonly terminal: Terminal;
|
||||
/**
|
||||
* The data being written.
|
||||
*/
|
||||
readonly data: string;
|
||||
}
|
||||
|
||||
namespace window {
|
||||
/**
|
||||
* An event which fires when the terminal's child pseudo-device is written to (the shell).
|
||||
* In other words, this provides access to the raw data stream from the process running
|
||||
* within the terminal, including VT sequences.
|
||||
*/
|
||||
export const onDidWriteTerminalData: Event<TerminalDataWriteEvent>;
|
||||
}
|
||||
|
||||
//#endregion
|
||||
}
|
|
@ -0,0 +1,29 @@
|
|||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
declare module 'vscode' {
|
||||
|
||||
// https://github.com/microsoft/vscode/issues/78502
|
||||
|
||||
export interface TerminalDataWriteEvent {
|
||||
/**
|
||||
* The {@link Terminal} for which the data was written.
|
||||
*/
|
||||
readonly terminal: Terminal;
|
||||
/**
|
||||
* The data being written.
|
||||
*/
|
||||
readonly data: string;
|
||||
}
|
||||
|
||||
namespace window {
|
||||
/**
|
||||
* An event which fires when the terminal's child pseudo-device is written to (the shell).
|
||||
* In other words, this provides access to the raw data stream from the process running
|
||||
* within the terminal, including VT sequences.
|
||||
*/
|
||||
export const onDidWriteTerminalData: Event<TerminalDataWriteEvent>;
|
||||
}
|
||||
}
|
Загрузка…
Ссылка в новой задаче