@opensumi/sumi 2.12.1-next-079c1930
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/README.md +1 -0
- package/build.ts +18 -0
- package/index.d.ts +5 -0
- package/manifest.json +414 -0
- package/package.json +18 -0
- package/sumi-browser.d.ts +273 -0
- package/sumi-worker/sumi-worker.d.ts +2788 -0
- package/sumi-worker/worker.command.d.ts +86 -0
- package/sumi-worker/worker.comments.d.ts +273 -0
- package/sumi-worker/worker.doc.d.ts +356 -0
- package/sumi-worker/worker.editor.d.ts +725 -0
- package/sumi-worker/worker.extensions.d.ts +63 -0
- package/sumi-worker/worker.language.d.ts +2220 -0
- package/sumi-worker/worker.window.d.ts +318 -0
- package/sumi-worker.d.ts +7 -0
- package/sumi.d.ts +822 -0
- package/vscode/typings/vscode.authentication.d.ts +231 -0
- package/vscode/typings/vscode.command.d.ts +86 -0
- package/vscode/typings/vscode.comments.d.ts +292 -0
- package/vscode/typings/vscode.d.ts +3789 -0
- package/vscode/typings/vscode.debug.d.ts +684 -0
- package/vscode/typings/vscode.doc.d.ts +272 -0
- package/vscode/typings/vscode.editor.d.ts +1017 -0
- package/vscode/typings/vscode.env.d.ts +153 -0
- package/vscode/typings/vscode.extension.d.ts +67 -0
- package/vscode/typings/vscode.language.d.ts +2630 -0
- package/vscode/typings/vscode.message.d.ts +195 -0
- package/vscode/typings/vscode.proposed.d.ts +662 -0
- package/vscode/typings/vscode.quickpick.d.ts +491 -0
- package/vscode/typings/vscode.scm.d.ts +254 -0
- package/vscode/typings/vscode.tasks.d.ts +676 -0
- package/vscode/typings/vscode.theme.d.ts +370 -0
- package/vscode/typings/vscode.window.d.ts +870 -0
- package/vscode/typings/vscode.workspace.d.ts +664 -0
- package/vscode/typings-pending/vscode.d.ts +27 -0
- package/vscode/typings-pending/vscode.proposed.d.ts +3 -0
- package/vscode.d.ts +23 -0
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
declare module 'sumi-worker' {
|
|
2
|
+
/**
|
|
3
|
+
* Namespace for dealing with installed extensions. Extensions are represented
|
|
4
|
+
* by an [extension](#Extension)-interface which enables reflection on them.
|
|
5
|
+
*
|
|
6
|
+
* Extension writers can provide APIs to other extensions by returning their API public
|
|
7
|
+
* surface from the `activate`-call.
|
|
8
|
+
*
|
|
9
|
+
* ```javascript
|
|
10
|
+
* export function activate(context: vscode.ExtensionContext) {
|
|
11
|
+
* let api = {
|
|
12
|
+
* sum(a, b) {
|
|
13
|
+
* return a + b;
|
|
14
|
+
* },
|
|
15
|
+
* mul(a, b) {
|
|
16
|
+
* return a * b;
|
|
17
|
+
* }
|
|
18
|
+
* };
|
|
19
|
+
* // 'export' public api-surface
|
|
20
|
+
* return api;
|
|
21
|
+
* }
|
|
22
|
+
* ```
|
|
23
|
+
* When depending on the API of another extension add an `extensionDependency`-entry
|
|
24
|
+
* to `package.json`, and use the [getExtension](#extensions.getExtension)-function
|
|
25
|
+
* and the [exports](#Extension.exports)-property, like below:
|
|
26
|
+
*
|
|
27
|
+
* ```javascript
|
|
28
|
+
* let mathExt = extensions.getExtension('genius.math');
|
|
29
|
+
* let importedApi = mathExt.exports;
|
|
30
|
+
*
|
|
31
|
+
* console.log(importedApi.mul(42, 1));
|
|
32
|
+
* ```
|
|
33
|
+
*/
|
|
34
|
+
export namespace extensions {
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Get an extension by its full identifier in the form of: `publisher.name`.
|
|
38
|
+
*
|
|
39
|
+
* @param extensionId An extension identifier.
|
|
40
|
+
* @return An extension or `undefined`.
|
|
41
|
+
*/
|
|
42
|
+
export function getExtension(extensionId: string): Extension<any> | undefined;
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* Get an extension its full identifier in the form of: `publisher.name`.
|
|
46
|
+
*
|
|
47
|
+
* @param extensionId An extension identifier.
|
|
48
|
+
* @return An extension or `undefined`.
|
|
49
|
+
*/
|
|
50
|
+
export function getExtension<T>(extensionId: string): Extension<T> | undefined;
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* All extensions currently known to the system.
|
|
54
|
+
*/
|
|
55
|
+
export const all: ReadonlyArray<Extension<any>>;
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* An event which fires when `extensions.all` changes. This can happen when extensions are
|
|
59
|
+
* installed, uninstalled, enabled or disabled.
|
|
60
|
+
*/
|
|
61
|
+
export const onDidChange: Event<void>;
|
|
62
|
+
}
|
|
63
|
+
}
|