@opensumi/sumi 2.12.1-next-079c1930 → 2.13.3
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/manifest.json +114 -106
- package/package.json +4 -3
- package/sumi-browser.d.ts +131 -25
- package/sumi-worker/sumi-worker.d.ts +186 -206
- package/sumi-worker/worker.command.d.ts +18 -14
- package/sumi-worker/worker.comments.d.ts +1 -1
- package/sumi-worker/worker.doc.d.ts +6 -9
- package/sumi-worker/worker.editor.d.ts +5 -16
- package/sumi-worker/worker.extensions.d.ts +0 -1
- package/sumi-worker/worker.language.d.ts +222 -138
- package/sumi-worker/worker.window.d.ts +185 -180
- package/sumi.d.ts +112 -108
- package/vscode/typings/vscode.d.ts +21 -33
- package/vscode/typings/vscode.debug.d.ts +35 -22
- package/vscode/typings/vscode.env.d.ts +13 -2
- package/vscode/typings/vscode.tasks.d.ts +11 -0
- package/vscode/typings/vscode.tests.d.ts +899 -0
- package/vscode/typings-pending/vscode.d.ts +2 -4
- package/vscode/typings-pending/vscode.proposed.d.ts +1 -3
- package/vscode.d.ts +1 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/* eslint-disable @typescript-eslint/no-empty-interface */
|
|
2
2
|
/**
|
|
3
3
|
* @deprecated `kaitian-worker` was deprecated, Please use `sumi-worker` instead.
|
|
4
4
|
*/
|
|
@@ -235,7 +235,6 @@ declare module 'sumi-worker' {
|
|
|
235
235
|
* The clipboard provides read and write access to the system's clipboard.
|
|
236
236
|
*/
|
|
237
237
|
export interface Clipboard {
|
|
238
|
-
|
|
239
238
|
/**
|
|
240
239
|
* Read the current clipboard contents as text.
|
|
241
240
|
* @returns A thenable that resolves to a string.
|
|
@@ -254,7 +253,6 @@ declare module 'sumi-worker' {
|
|
|
254
253
|
* may have a parent selection range that contains it.
|
|
255
254
|
*/
|
|
256
255
|
export class SelectionRange {
|
|
257
|
-
|
|
258
256
|
/**
|
|
259
257
|
* The [range](#Range) of this selection range.
|
|
260
258
|
*/
|
|
@@ -284,7 +282,6 @@ declare module 'sumi-worker' {
|
|
|
284
282
|
* the [symbol search](https://code.visualstudio.com/docs/editor/editingevolved#_open-symbol-by-name)-feature.
|
|
285
283
|
*/
|
|
286
284
|
export interface WorkspaceSymbolProvider {
|
|
287
|
-
|
|
288
285
|
/**
|
|
289
286
|
* Project-wide search for a symbol matching the given query string.
|
|
290
287
|
*
|
|
@@ -323,7 +320,6 @@ declare module 'sumi-worker' {
|
|
|
323
320
|
* Describes how comments for a language work.
|
|
324
321
|
*/
|
|
325
322
|
export interface CommentRule {
|
|
326
|
-
|
|
327
323
|
/**
|
|
328
324
|
* The line comment token, like `// this is a comment`
|
|
329
325
|
*/
|
|
@@ -380,7 +376,6 @@ declare module 'sumi-worker' {
|
|
|
380
376
|
* are equal which means there is no notion of an active or master workspace folder.
|
|
381
377
|
*/
|
|
382
378
|
export interface WorkspaceFolder {
|
|
383
|
-
|
|
384
379
|
/**
|
|
385
380
|
* The associated uri for this workspace folder.
|
|
386
381
|
*
|
|
@@ -404,7 +399,6 @@ declare module 'sumi-worker' {
|
|
|
404
399
|
* Represents reasons why a text document is saved.
|
|
405
400
|
*/
|
|
406
401
|
export enum TextDocumentSaveReason {
|
|
407
|
-
|
|
408
402
|
/**
|
|
409
403
|
* Manually triggered, e.g. by the user pressing save, by starting debugging,
|
|
410
404
|
* or by an API call.
|
|
@@ -426,7 +420,6 @@ declare module 'sumi-worker' {
|
|
|
426
420
|
* Represents the state of a window.
|
|
427
421
|
*/
|
|
428
422
|
export interface WindowState {
|
|
429
|
-
|
|
430
423
|
/**
|
|
431
424
|
* Whether the current window is focused.
|
|
432
425
|
*/
|
|
@@ -438,7 +431,6 @@ declare module 'sumi-worker' {
|
|
|
438
431
|
* have a label and a doc-comment.
|
|
439
432
|
*/
|
|
440
433
|
export class ParameterInformation {
|
|
441
|
-
|
|
442
434
|
/**
|
|
443
435
|
* The label of this signature.
|
|
444
436
|
*
|
|
@@ -523,7 +515,6 @@ declare module 'sumi-worker' {
|
|
|
523
515
|
* the [parameter hints](https://code.visualstudio.com/docs/editor/intellisense)-feature.
|
|
524
516
|
*/
|
|
525
517
|
export interface SignatureHelpProvider {
|
|
526
|
-
|
|
527
518
|
/**
|
|
528
519
|
* Provide help for the signature at the given position and document.
|
|
529
520
|
*
|
|
@@ -535,7 +526,12 @@ declare module 'sumi-worker' {
|
|
|
535
526
|
* @return Signature help or a thenable that resolves to such. The lack of a result can be
|
|
536
527
|
* signaled by returning `undefined` or `null`.
|
|
537
528
|
*/
|
|
538
|
-
provideSignatureHelp(
|
|
529
|
+
provideSignatureHelp(
|
|
530
|
+
document: TextDocument,
|
|
531
|
+
position: Position,
|
|
532
|
+
token: CancellationToken,
|
|
533
|
+
context: SignatureHelpContext,
|
|
534
|
+
): ProviderResult<SignatureHelp>;
|
|
539
535
|
}
|
|
540
536
|
|
|
541
537
|
/**
|
|
@@ -562,7 +558,6 @@ declare module 'sumi-worker' {
|
|
|
562
558
|
* a set of parameters.
|
|
563
559
|
*/
|
|
564
560
|
export class SignatureInformation {
|
|
565
|
-
|
|
566
561
|
/**
|
|
567
562
|
* The label of this signature. Will be shown in
|
|
568
563
|
* the UI.
|
|
@@ -602,7 +597,6 @@ declare module 'sumi-worker' {
|
|
|
602
597
|
* active and only one active parameter.
|
|
603
598
|
*/
|
|
604
599
|
export class SignatureHelp {
|
|
605
|
-
|
|
606
600
|
/**
|
|
607
601
|
* One or more signatures.
|
|
608
602
|
*/
|
|
@@ -623,7 +617,6 @@ declare module 'sumi-worker' {
|
|
|
623
617
|
* Symbol tags are extra annotations that tweak the rendering of a symbol.
|
|
624
618
|
*/
|
|
625
619
|
export enum SymbolTag {
|
|
626
|
-
|
|
627
620
|
/**
|
|
628
621
|
* Render a symbol as obsolete, usually using a strike-out.
|
|
629
622
|
*/
|
|
@@ -635,7 +628,6 @@ declare module 'sumi-worker' {
|
|
|
635
628
|
* interfaces etc.
|
|
636
629
|
*/
|
|
637
630
|
export class SymbolInformation {
|
|
638
|
-
|
|
639
631
|
/**
|
|
640
632
|
* The name of this symbol.
|
|
641
633
|
*/
|
|
@@ -726,7 +718,6 @@ declare module 'sumi-worker' {
|
|
|
726
718
|
* runs where the UI (window) runs or if an extension runs remotely.
|
|
727
719
|
*/
|
|
728
720
|
export enum ExtensionKind {
|
|
729
|
-
|
|
730
721
|
/**
|
|
731
722
|
* Extension runs where the UI runs.
|
|
732
723
|
*/
|
|
@@ -752,7 +743,11 @@ declare module 'sumi-worker' {
|
|
|
752
743
|
* @return Selection ranges or a thenable that resolves to such. The lack of a result can be
|
|
753
744
|
* signaled by returning `undefined` or `null`.
|
|
754
745
|
*/
|
|
755
|
-
provideSelectionRanges(
|
|
746
|
+
provideSelectionRanges(
|
|
747
|
+
document: TextDocument,
|
|
748
|
+
positions: Position[],
|
|
749
|
+
token: CancellationToken,
|
|
750
|
+
): ProviderResult<SelectionRange[]>;
|
|
756
751
|
}
|
|
757
752
|
/**
|
|
758
753
|
* Contains additional information about the context in which
|
|
@@ -830,7 +825,6 @@ declare module 'sumi-worker' {
|
|
|
830
825
|
* Use the [applyEdit](#workspace.applyEdit)-function to apply a workspace edit.
|
|
831
826
|
*/
|
|
832
827
|
export class WorkspaceEdit {
|
|
833
|
-
|
|
834
828
|
/**
|
|
835
829
|
* The number of affected resources of textual or resource changes.
|
|
836
830
|
*/
|
|
@@ -893,14 +887,14 @@ declare module 'sumi-worker' {
|
|
|
893
887
|
* @param options Defines if an existing file should be overwritten or be
|
|
894
888
|
* ignored. When overwrite and ignoreIfExists are both set overwrite wins.
|
|
895
889
|
*/
|
|
896
|
-
createFile(uri: Uri, options?: { overwrite?: boolean
|
|
890
|
+
createFile(uri: Uri, options?: { overwrite?: boolean; ignoreIfExists?: boolean }): void;
|
|
897
891
|
|
|
898
892
|
/**
|
|
899
893
|
* Delete a file or folder.
|
|
900
894
|
*
|
|
901
895
|
* @param uri The uri of the file that is to be deleted.
|
|
902
896
|
*/
|
|
903
|
-
deleteFile(uri: Uri, options?: { recursive?: boolean
|
|
897
|
+
deleteFile(uri: Uri, options?: { recursive?: boolean; ignoreIfNotExists?: boolean }): void;
|
|
904
898
|
|
|
905
899
|
/**
|
|
906
900
|
* Rename a file or folder.
|
|
@@ -910,7 +904,7 @@ declare module 'sumi-worker' {
|
|
|
910
904
|
* @param options Defines if existing files should be overwritten or be
|
|
911
905
|
* ignored. When overwrite and ignoreIfExists are both set overwrite wins.
|
|
912
906
|
*/
|
|
913
|
-
renameFile(oldUri: Uri, newUri: Uri, options?: { overwrite?: boolean
|
|
907
|
+
renameFile(oldUri: Uri, newUri: Uri, options?: { overwrite?: boolean; ignoreIfExists?: boolean }): void;
|
|
914
908
|
|
|
915
909
|
/**
|
|
916
910
|
* Get all text edits grouped by resource.
|
|
@@ -924,7 +918,6 @@ declare module 'sumi-worker' {
|
|
|
924
918
|
* Options for creating a [TreeView](#TreeView)
|
|
925
919
|
*/
|
|
926
920
|
export interface TreeViewOptions<T> {
|
|
927
|
-
|
|
928
921
|
/**
|
|
929
922
|
* A data provider that provides tree data.
|
|
930
923
|
*/
|
|
@@ -947,43 +940,36 @@ declare module 'sumi-worker' {
|
|
|
947
940
|
* The event that is fired when an element in the [TreeView](#TreeView) is expanded or collapsed
|
|
948
941
|
*/
|
|
949
942
|
export interface TreeViewExpansionEvent<T> {
|
|
950
|
-
|
|
951
943
|
/**
|
|
952
944
|
* Element that is expanded or collapsed.
|
|
953
945
|
*/
|
|
954
946
|
readonly element: T;
|
|
955
|
-
|
|
956
947
|
}
|
|
957
948
|
|
|
958
949
|
/**
|
|
959
950
|
* The event that is fired when there is a change in [tree view's selection](#TreeView.selection)
|
|
960
951
|
*/
|
|
961
952
|
export interface TreeViewSelectionChangeEvent<T> {
|
|
962
|
-
|
|
963
953
|
/**
|
|
964
954
|
* Selected elements.
|
|
965
955
|
*/
|
|
966
956
|
readonly selection: T[];
|
|
967
|
-
|
|
968
957
|
}
|
|
969
958
|
|
|
970
959
|
/**
|
|
971
960
|
* The event that is fired when there is a change in [tree view's visibility](#TreeView.visible)
|
|
972
961
|
*/
|
|
973
962
|
export interface TreeViewVisibilityChangeEvent {
|
|
974
|
-
|
|
975
963
|
/**
|
|
976
964
|
* `true` if the [tree view](#TreeView) is visible otherwise `false`.
|
|
977
965
|
*/
|
|
978
966
|
readonly visible: boolean;
|
|
979
|
-
|
|
980
967
|
}
|
|
981
968
|
|
|
982
969
|
/**
|
|
983
970
|
* Represents a Tree view
|
|
984
971
|
*/
|
|
985
972
|
export interface TreeView<T> extends Disposable {
|
|
986
|
-
|
|
987
973
|
/**
|
|
988
974
|
* Event that is fired when an element is expanded
|
|
989
975
|
*/
|
|
@@ -1026,7 +1012,7 @@ declare module 'sumi-worker' {
|
|
|
1026
1012
|
*
|
|
1027
1013
|
* **NOTE:** [TreeDataProvider](#TreeDataProvider) is required to implement [getParent](#TreeDataProvider.getParent) method to access this API.
|
|
1028
1014
|
*/
|
|
1029
|
-
reveal(element: T, options?: { select?: boolean
|
|
1015
|
+
reveal(element: T, options?: { select?: boolean; focus?: boolean; expand?: boolean | number }): Thenable<void>;
|
|
1030
1016
|
}
|
|
1031
1017
|
|
|
1032
1018
|
/**
|
|
@@ -1051,7 +1037,6 @@ declare module 'sumi-worker' {
|
|
|
1051
1037
|
* Label describing the [Tree item](#TreeItem)
|
|
1052
1038
|
*/
|
|
1053
1039
|
export interface TreeItemLabel {
|
|
1054
|
-
|
|
1055
1040
|
/**
|
|
1056
1041
|
* A human-readable string describing the [Tree item](#TreeItem).
|
|
1057
1042
|
*/
|
|
@@ -1062,7 +1047,6 @@ declare module 'sumi-worker' {
|
|
|
1062
1047
|
* first is the inclusive start index and the second the exclusive end index
|
|
1063
1048
|
*/
|
|
1064
1049
|
highlights?: [number, number][];
|
|
1065
|
-
|
|
1066
1050
|
}
|
|
1067
1051
|
|
|
1068
1052
|
/**
|
|
@@ -1213,7 +1197,7 @@ declare module 'sumi-worker' {
|
|
|
1213
1197
|
* @param resourceUri The {@link Uri} of the resource representing this item.
|
|
1214
1198
|
* @param collapsibleState {@link TreeItemCollapsibleState} of the tree item. Default is {@link TreeItemCollapsibleState.None}
|
|
1215
1199
|
*/
|
|
1216
|
-
//
|
|
1200
|
+
// eslint-disable-next-line @typescript-eslint/unified-signatures
|
|
1217
1201
|
constructor(resourceUri: Uri, collapsibleState?: TreeItemCollapsibleState);
|
|
1218
1202
|
}
|
|
1219
1203
|
/**
|
|
@@ -1223,7 +1207,6 @@ declare module 'sumi-worker' {
|
|
|
1223
1207
|
* previously retrieved lines will not represent the latest state.
|
|
1224
1208
|
*/
|
|
1225
1209
|
export interface TextLine {
|
|
1226
|
-
|
|
1227
1210
|
/**
|
|
1228
1211
|
* The zero-based line number.
|
|
1229
1212
|
*/
|
|
@@ -1261,7 +1244,6 @@ declare module 'sumi-worker' {
|
|
|
1261
1244
|
* [lines](#TextLine) and knowledge about an underlying resource like a file.
|
|
1262
1245
|
*/
|
|
1263
1246
|
export interface TextDocument {
|
|
1264
|
-
|
|
1265
1247
|
/**
|
|
1266
1248
|
* The associated uri for this document.
|
|
1267
1249
|
*
|
|
@@ -1409,7 +1391,6 @@ declare module 'sumi-worker' {
|
|
|
1409
1391
|
* Represents a text selection in an editor.
|
|
1410
1392
|
*/
|
|
1411
1393
|
export class Selection extends Range {
|
|
1412
|
-
|
|
1413
1394
|
/**
|
|
1414
1395
|
* The position at which the selection starts.
|
|
1415
1396
|
* This position might be before or after [active](#Selection.active).
|
|
@@ -1458,7 +1439,6 @@ declare module 'sumi-worker' {
|
|
|
1458
1439
|
* or another resource, like untitled resources.
|
|
1459
1440
|
*/
|
|
1460
1441
|
export class Uri {
|
|
1461
|
-
|
|
1462
1442
|
/**
|
|
1463
1443
|
* Create an URI from a string, e.g. `http://www.msft.com/some/path`,
|
|
1464
1444
|
* `file:///usr/home`, or `scheme:with/path`.
|
|
@@ -1584,8 +1564,8 @@ declare module 'sumi-worker' {
|
|
|
1584
1564
|
*
|
|
1585
1565
|
* @param skipEncoding Do not percentage-encode the result, defaults to `false`. Note that
|
|
1586
1566
|
* the `#` and `?` characters occurring in the path will always be encoded.
|
|
1587
|
-
|
|
1588
|
-
|
|
1567
|
+
* @returns A string representation of this Uri.
|
|
1568
|
+
*/
|
|
1589
1569
|
toString(skipEncoding?: boolean): string;
|
|
1590
1570
|
|
|
1591
1571
|
/**
|
|
@@ -1615,7 +1595,6 @@ declare module 'sumi-worker' {
|
|
|
1615
1595
|
* API to other extensions.
|
|
1616
1596
|
*/
|
|
1617
1597
|
export class EventEmitter<T> {
|
|
1618
|
-
|
|
1619
1598
|
/**
|
|
1620
1599
|
* The event listeners can subscribe to.
|
|
1621
1600
|
*/
|
|
@@ -1644,7 +1623,6 @@ declare module 'sumi-worker' {
|
|
|
1644
1623
|
* [CancellationTokenSource](#CancellationTokenSource).
|
|
1645
1624
|
*/
|
|
1646
1625
|
export interface CancellationToken {
|
|
1647
|
-
|
|
1648
1626
|
/**
|
|
1649
1627
|
* Is `true` when the token has been cancelled, `false` otherwise.
|
|
1650
1628
|
*/
|
|
@@ -1662,7 +1640,6 @@ declare module 'sumi-worker' {
|
|
|
1662
1640
|
*
|
|
1663
1641
|
*/
|
|
1664
1642
|
export class CancellationTokenSource {
|
|
1665
|
-
|
|
1666
1643
|
/**
|
|
1667
1644
|
* The cancellation token of this source.
|
|
1668
1645
|
*/
|
|
@@ -1679,11 +1656,18 @@ declare module 'sumi-worker' {
|
|
|
1679
1656
|
dispose(): void;
|
|
1680
1657
|
}
|
|
1681
1658
|
|
|
1659
|
+
export enum TextDocumentChangeReason {
|
|
1660
|
+
/** The text change is caused by an undo operation. */
|
|
1661
|
+
Undo = 1,
|
|
1662
|
+
|
|
1663
|
+
/** The text change is caused by an redo operation. */
|
|
1664
|
+
Redo = 2,
|
|
1665
|
+
}
|
|
1666
|
+
|
|
1682
1667
|
/**
|
|
1683
1668
|
* An event describing a transactional [document](#TextDocument) change.
|
|
1684
1669
|
*/
|
|
1685
1670
|
export interface TextDocumentChangeEvent {
|
|
1686
|
-
|
|
1687
1671
|
/**
|
|
1688
1672
|
* The affected document.
|
|
1689
1673
|
*/
|
|
@@ -1693,6 +1677,12 @@ declare module 'sumi-worker' {
|
|
|
1693
1677
|
* An array of content changes.
|
|
1694
1678
|
*/
|
|
1695
1679
|
readonly contentChanges: ReadonlyArray<TextDocumentContentChangeEvent>;
|
|
1680
|
+
|
|
1681
|
+
/**
|
|
1682
|
+
* The reason why the document was changed.
|
|
1683
|
+
* Is `undefined` if the reason is not known.
|
|
1684
|
+
*/
|
|
1685
|
+
readonly reason: TextDocumentChangeReason | undefined;
|
|
1696
1686
|
}
|
|
1697
1687
|
|
|
1698
1688
|
/**
|
|
@@ -1702,7 +1692,6 @@ declare module 'sumi-worker' {
|
|
|
1702
1692
|
* @寻壑
|
|
1703
1693
|
*/
|
|
1704
1694
|
export class DiagnosticRelatedInformation {
|
|
1705
|
-
|
|
1706
1695
|
/**
|
|
1707
1696
|
* The location of this related diagnostic information.
|
|
1708
1697
|
*/
|
|
@@ -1744,7 +1733,6 @@ declare module 'sumi-worker' {
|
|
|
1744
1733
|
* Represents the severity of diagnostics.
|
|
1745
1734
|
*/
|
|
1746
1735
|
export enum DiagnosticSeverity {
|
|
1747
|
-
|
|
1748
1736
|
/**
|
|
1749
1737
|
* Something not allowed by the rules of a language or other means.
|
|
1750
1738
|
*/
|
|
@@ -1773,7 +1761,6 @@ declare module 'sumi-worker' {
|
|
|
1773
1761
|
* @寻壑
|
|
1774
1762
|
*/
|
|
1775
1763
|
export class Diagnostic {
|
|
1776
|
-
|
|
1777
1764
|
/**
|
|
1778
1765
|
* The range to which this diagnostic applies.
|
|
1779
1766
|
*/
|
|
@@ -1826,7 +1813,6 @@ declare module 'sumi-worker' {
|
|
|
1826
1813
|
* as event listening or a timer.
|
|
1827
1814
|
*/
|
|
1828
1815
|
export class Disposable {
|
|
1829
|
-
|
|
1830
1816
|
/**
|
|
1831
1817
|
* Combine many disposable-likes into one. Use this method
|
|
1832
1818
|
* when having objects with a dispose function which are not
|
|
@@ -1857,7 +1843,6 @@ declare module 'sumi-worker' {
|
|
|
1857
1843
|
* To get an instance of an `Extension` use [getExtension](#extensions.getExtension).
|
|
1858
1844
|
*/
|
|
1859
1845
|
export interface Extension<T> {
|
|
1860
|
-
|
|
1861
1846
|
/**
|
|
1862
1847
|
* The canonical extension identifier in the form of: `publisher.name`.
|
|
1863
1848
|
*/
|
|
@@ -1906,7 +1891,6 @@ declare module 'sumi-worker' {
|
|
|
1906
1891
|
* values.
|
|
1907
1892
|
*/
|
|
1908
1893
|
export interface Memento {
|
|
1909
|
-
|
|
1910
1894
|
/**
|
|
1911
1895
|
* Return a value.
|
|
1912
1896
|
*
|
|
@@ -1932,10 +1916,17 @@ declare module 'sumi-worker' {
|
|
|
1932
1916
|
* @param value A value. MUST not contain cyclic references.
|
|
1933
1917
|
*/
|
|
1934
1918
|
update(key: string, value: any): Thenable<void>;
|
|
1919
|
+
|
|
1920
|
+
/**
|
|
1921
|
+
* VS Code Proposal API, maybe remove on latest version.
|
|
1922
|
+
* #region https://github.com/microsoft/vscode/issues/87110
|
|
1923
|
+
*
|
|
1924
|
+
* The stored keys.
|
|
1925
|
+
*/
|
|
1926
|
+
readonly keys: readonly string[];
|
|
1935
1927
|
}
|
|
1936
1928
|
|
|
1937
1929
|
export interface Terminal {
|
|
1938
|
-
|
|
1939
1930
|
/**
|
|
1940
1931
|
* The name of the terminal.
|
|
1941
1932
|
*/
|
|
@@ -1975,15 +1966,13 @@ declare module 'sumi-worker' {
|
|
|
1975
1966
|
dispose(): void;
|
|
1976
1967
|
}
|
|
1977
1968
|
|
|
1978
|
-
|
|
1979
|
-
export interface env { }
|
|
1969
|
+
export interface env {}
|
|
1980
1970
|
|
|
1981
1971
|
/**
|
|
1982
1972
|
* A memento represents a storage utility. It can store and retrieve
|
|
1983
1973
|
* values.
|
|
1984
1974
|
*/
|
|
1985
1975
|
export interface Memento {
|
|
1986
|
-
|
|
1987
1976
|
/**
|
|
1988
1977
|
* Return a value.
|
|
1989
1978
|
*
|
|
@@ -2019,7 +2008,6 @@ declare module 'sumi-worker' {
|
|
|
2019
2008
|
* [createFileSystemWatcher](#workspace.createFileSystemWatcher).
|
|
2020
2009
|
*/
|
|
2021
2010
|
export interface FileSystemWatcher extends Disposable {
|
|
2022
|
-
|
|
2023
2011
|
/**
|
|
2024
2012
|
* true if this file system watcher has been created such that
|
|
2025
2013
|
* it ignores creation file system events.
|
|
@@ -2109,7 +2097,6 @@ declare module 'sumi-worker' {
|
|
|
2109
2097
|
* @墨蛰
|
|
2110
2098
|
*/
|
|
2111
2099
|
export class FileSystemError extends Error {
|
|
2112
|
-
|
|
2113
2100
|
/**
|
|
2114
2101
|
* Create an error to signal that a file or folder wasn't found.
|
|
2115
2102
|
* @param messageOrUri Message or uri.
|
|
@@ -2160,7 +2147,6 @@ declare module 'sumi-worker' {
|
|
|
2160
2147
|
* Enumeration of file change types.
|
|
2161
2148
|
*/
|
|
2162
2149
|
export enum FileChangeType {
|
|
2163
|
-
|
|
2164
2150
|
/**
|
|
2165
2151
|
* The contents or metadata of a file have changed.
|
|
2166
2152
|
*/
|
|
@@ -2181,7 +2167,6 @@ declare module 'sumi-worker' {
|
|
|
2181
2167
|
* The event filesystem providers must use to signal a file change.
|
|
2182
2168
|
*/
|
|
2183
2169
|
export interface FileChangeEvent {
|
|
2184
|
-
|
|
2185
2170
|
/**
|
|
2186
2171
|
* The type of change.
|
|
2187
2172
|
*/
|
|
@@ -2206,7 +2191,6 @@ declare module 'sumi-worker' {
|
|
|
2206
2191
|
* folders, symbolic links, and regular files.
|
|
2207
2192
|
*/
|
|
2208
2193
|
export interface FileSystemProvider {
|
|
2209
|
-
|
|
2210
2194
|
/**
|
|
2211
2195
|
* An event to signal that a resource has been created, changed, or deleted. This
|
|
2212
2196
|
* event should fire for resources that are being [watched](#FileSystemProvider.watch)
|
|
@@ -2279,7 +2263,7 @@ declare module 'sumi-worker' {
|
|
|
2279
2263
|
* @throws [`FileExists`](#FileSystemError.FileExists) when `uri` already exists, `create` is set but `overwrite` is not set.
|
|
2280
2264
|
* @throws [`NoPermissions`](#FileSystemError.NoPermissions) when permissions aren't sufficient.
|
|
2281
2265
|
*/
|
|
2282
|
-
writeFile(uri: Uri, content: Uint8Array, options: { create: boolean
|
|
2266
|
+
writeFile(uri: Uri, content: Uint8Array, options: { create: boolean; overwrite: boolean }): void | Thenable<void>;
|
|
2283
2267
|
|
|
2284
2268
|
/**
|
|
2285
2269
|
* Delete a file.
|
|
@@ -2324,7 +2308,7 @@ declare module 'sumi-worker' {
|
|
|
2324
2308
|
readDirectory(uri: Uri): Thenable<[string, FileType][]>;
|
|
2325
2309
|
createDirectory(uri: Uri): Thenable<void>;
|
|
2326
2310
|
readFile(uri: Uri): Thenable<Uint8Array>;
|
|
2327
|
-
writeFile(uri: Uri, content: Uint8Array, options?: { create: boolean
|
|
2311
|
+
writeFile(uri: Uri, content: Uint8Array, options?: { create: boolean; overwrite: boolean }): Thenable<void>;
|
|
2328
2312
|
delete(uri: Uri, options?: { recursive: boolean }): Thenable<void>;
|
|
2329
2313
|
rename(source: Uri, target: Uri, options?: { overwrite: boolean }): Thenable<void>;
|
|
2330
2314
|
copy(source: Uri, target: Uri, options?: { overwrite: boolean }): Thenable<void>;
|
|
@@ -2369,7 +2353,6 @@ declare module 'sumi-worker' {
|
|
|
2369
2353
|
* Defines a generalized way of reporting progress updates.
|
|
2370
2354
|
*/
|
|
2371
2355
|
export interface Progress<T> {
|
|
2372
|
-
|
|
2373
2356
|
/**
|
|
2374
2357
|
* Report a progress update.
|
|
2375
2358
|
* @param value A progress item, like a message and/or an
|
|
@@ -2383,7 +2366,6 @@ declare module 'sumi-worker' {
|
|
|
2383
2366
|
* location how progress is visually represented.
|
|
2384
2367
|
*/
|
|
2385
2368
|
export enum ProgressLocation {
|
|
2386
|
-
|
|
2387
2369
|
/**
|
|
2388
2370
|
* Show progress for the source control viewlet, as overlay for the icon and as progress bar
|
|
2389
2371
|
* inside the viewlet (when visible). Neither supports cancellation nor discrete progress.
|
|
@@ -2405,7 +2387,6 @@ declare module 'sumi-worker' {
|
|
|
2405
2387
|
* Value-object describing where and how progress should show.
|
|
2406
2388
|
*/
|
|
2407
2389
|
export interface ProgressOptions {
|
|
2408
|
-
|
|
2409
2390
|
/**
|
|
2410
2391
|
* The location at which progress should show.
|
|
2411
2392
|
*/
|
|
@@ -2431,7 +2412,6 @@ declare module 'sumi-worker' {
|
|
|
2431
2412
|
* Using a theme color is preferred over a custom color as it gives theme authors and users the possibility to change the color.
|
|
2432
2413
|
*/
|
|
2433
2414
|
export class ThemeColor {
|
|
2434
|
-
|
|
2435
2415
|
/**
|
|
2436
2416
|
* Creates a reference to a theme color.
|
|
2437
2417
|
* @param id of the color. The available colors are listed in https://code.visualstudio.com/docs/getstarted/theme-color-reference.
|
|
@@ -2510,279 +2490,279 @@ declare module 'sumi-worker' {
|
|
|
2510
2490
|
outlineWidth?: string;
|
|
2511
2491
|
|
|
2512
2492
|
/**
|
|
2513
|
-
|
|
2514
|
-
|
|
2493
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2494
|
+
*/
|
|
2515
2495
|
border?: string;
|
|
2516
2496
|
|
|
2517
2497
|
/**
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2498
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2499
|
+
* Better use 'border' for setting one or more of the individual border properties.
|
|
2500
|
+
*/
|
|
2521
2501
|
borderColor?: string | ThemeColor;
|
|
2522
2502
|
|
|
2523
2503
|
/**
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2504
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2505
|
+
* Better use 'border' for setting one or more of the individual border properties.
|
|
2506
|
+
*/
|
|
2527
2507
|
borderRadius?: string;
|
|
2528
2508
|
|
|
2529
2509
|
/**
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2510
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2511
|
+
* Better use 'border' for setting one or more of the individual border properties.
|
|
2512
|
+
*/
|
|
2533
2513
|
borderSpacing?: string;
|
|
2534
2514
|
|
|
2535
2515
|
/**
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2516
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2517
|
+
* Better use 'border' for setting one or more of the individual border properties.
|
|
2518
|
+
*/
|
|
2539
2519
|
borderStyle?: string;
|
|
2540
2520
|
|
|
2541
2521
|
/**
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
|
|
2522
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2523
|
+
* Better use 'border' for setting one or more of the individual border properties.
|
|
2524
|
+
*/
|
|
2545
2525
|
borderWidth?: string;
|
|
2546
2526
|
|
|
2547
2527
|
/**
|
|
2548
|
-
|
|
2549
|
-
|
|
2528
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2529
|
+
*/
|
|
2550
2530
|
fontStyle?: string;
|
|
2551
2531
|
|
|
2552
2532
|
/**
|
|
2553
|
-
|
|
2554
|
-
|
|
2533
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2534
|
+
*/
|
|
2555
2535
|
fontWeight?: string;
|
|
2556
2536
|
|
|
2557
2537
|
/**
|
|
2558
|
-
|
|
2559
|
-
|
|
2538
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2539
|
+
*/
|
|
2560
2540
|
textDecoration?: string;
|
|
2561
2541
|
|
|
2562
2542
|
/**
|
|
2563
|
-
|
|
2564
|
-
|
|
2543
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2544
|
+
*/
|
|
2565
2545
|
cursor?: string;
|
|
2566
2546
|
|
|
2567
2547
|
/**
|
|
2568
|
-
|
|
2569
|
-
|
|
2548
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2549
|
+
*/
|
|
2570
2550
|
color?: string | ThemeColor;
|
|
2571
2551
|
|
|
2572
2552
|
/**
|
|
2573
|
-
|
|
2574
|
-
|
|
2553
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2554
|
+
*/
|
|
2575
2555
|
opacity?: string;
|
|
2576
2556
|
|
|
2577
2557
|
/**
|
|
2578
|
-
|
|
2579
|
-
|
|
2558
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2559
|
+
*/
|
|
2580
2560
|
letterSpacing?: string;
|
|
2581
2561
|
|
|
2582
2562
|
/**
|
|
2583
|
-
|
|
2584
|
-
|
|
2563
|
+
* An **absolute path** or an URI to an image to be rendered in the gutter.
|
|
2564
|
+
*/
|
|
2585
2565
|
gutterIconPath?: string | Uri;
|
|
2586
2566
|
|
|
2587
2567
|
/**
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
|
|
2568
|
+
* Specifies the size of the gutter icon.
|
|
2569
|
+
* Available values are 'auto', 'contain', 'cover' and any percentage value.
|
|
2570
|
+
* For further information: https://msdn.microsoft.com/en-us/library/jj127316(v=vs.85).aspx
|
|
2571
|
+
*/
|
|
2592
2572
|
gutterIconSize?: string;
|
|
2593
2573
|
|
|
2594
2574
|
/**
|
|
2595
|
-
|
|
2596
|
-
|
|
2575
|
+
* The color of the decoration in the overview ruler. Use rgba() and define transparent colors to play well with other decorations.
|
|
2576
|
+
*/
|
|
2597
2577
|
overviewRulerColor?: string | ThemeColor;
|
|
2598
2578
|
|
|
2599
2579
|
/**
|
|
2600
|
-
|
|
2601
|
-
|
|
2580
|
+
* Defines the rendering options of the attachment that is inserted before the decorated text.
|
|
2581
|
+
*/
|
|
2602
2582
|
before?: ThemableDecorationAttachmentRenderOptions;
|
|
2603
2583
|
|
|
2604
2584
|
/**
|
|
2605
|
-
|
|
2606
|
-
|
|
2585
|
+
* Defines the rendering options of the attachment that is inserted after the decorated text.
|
|
2586
|
+
*/
|
|
2607
2587
|
after?: ThemableDecorationAttachmentRenderOptions;
|
|
2608
2588
|
}
|
|
2609
2589
|
|
|
2610
2590
|
export interface ThemableDecorationAttachmentRenderOptions {
|
|
2611
2591
|
/**
|
|
2612
|
-
|
|
2613
|
-
|
|
2592
|
+
* Defines a text content that is shown in the attachment. Either an icon or a text can be shown, but not both.
|
|
2593
|
+
*/
|
|
2614
2594
|
contentText?: string;
|
|
2615
2595
|
/**
|
|
2616
|
-
|
|
2617
|
-
|
|
2618
|
-
|
|
2596
|
+
* An **absolute path** or an URI to an image to be rendered in the attachment. Either an icon
|
|
2597
|
+
* or a text can be shown, but not both.
|
|
2598
|
+
*/
|
|
2619
2599
|
contentIconPath?: string | Uri;
|
|
2620
2600
|
/**
|
|
2621
|
-
|
|
2622
|
-
|
|
2601
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2602
|
+
*/
|
|
2623
2603
|
border?: string;
|
|
2624
2604
|
/**
|
|
2625
|
-
|
|
2626
|
-
|
|
2605
|
+
* CSS styling property that will be applied to text enclosed by a decoration.
|
|
2606
|
+
*/
|
|
2627
2607
|
borderColor?: string | ThemeColor;
|
|
2628
2608
|
/**
|
|
2629
|
-
|
|
2630
|
-
|
|
2609
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2610
|
+
*/
|
|
2631
2611
|
fontStyle?: string;
|
|
2632
2612
|
/**
|
|
2633
|
-
|
|
2634
|
-
|
|
2613
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2614
|
+
*/
|
|
2635
2615
|
fontWeight?: string;
|
|
2636
2616
|
/**
|
|
2637
|
-
|
|
2638
|
-
|
|
2617
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2618
|
+
*/
|
|
2639
2619
|
textDecoration?: string;
|
|
2640
2620
|
/**
|
|
2641
|
-
|
|
2642
|
-
|
|
2621
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2622
|
+
*/
|
|
2643
2623
|
color?: string | ThemeColor;
|
|
2644
2624
|
/**
|
|
2645
|
-
|
|
2646
|
-
|
|
2625
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2626
|
+
*/
|
|
2647
2627
|
backgroundColor?: string | ThemeColor;
|
|
2648
2628
|
/**
|
|
2649
|
-
|
|
2650
|
-
|
|
2629
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2630
|
+
*/
|
|
2651
2631
|
margin?: string;
|
|
2652
2632
|
/**
|
|
2653
|
-
|
|
2654
|
-
|
|
2633
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2634
|
+
*/
|
|
2655
2635
|
width?: string;
|
|
2656
2636
|
/**
|
|
2657
|
-
|
|
2658
|
-
|
|
2637
|
+
* CSS styling property that will be applied to the decoration attachment.
|
|
2638
|
+
*/
|
|
2659
2639
|
height?: string;
|
|
2660
2640
|
}
|
|
2661
2641
|
|
|
2662
2642
|
/**
|
|
2663
|
-
|
|
2664
|
-
|
|
2643
|
+
* Represents a color in RGBA space.
|
|
2644
|
+
*/
|
|
2665
2645
|
export class Color {
|
|
2666
|
-
|
|
2667
2646
|
/**
|
|
2668
|
-
|
|
2669
|
-
|
|
2647
|
+
* The red component of this color in the range [0-1].
|
|
2648
|
+
*/
|
|
2670
2649
|
readonly red: number;
|
|
2671
2650
|
|
|
2672
2651
|
/**
|
|
2673
|
-
|
|
2674
|
-
|
|
2652
|
+
* The green component of this color in the range [0-1].
|
|
2653
|
+
*/
|
|
2675
2654
|
readonly green: number;
|
|
2676
2655
|
|
|
2677
2656
|
/**
|
|
2678
|
-
|
|
2679
|
-
|
|
2657
|
+
* The blue component of this color in the range [0-1].
|
|
2658
|
+
*/
|
|
2680
2659
|
readonly blue: number;
|
|
2681
2660
|
|
|
2682
2661
|
/**
|
|
2683
|
-
|
|
2684
|
-
|
|
2662
|
+
* The alpha component of this color in the range [0-1].
|
|
2663
|
+
*/
|
|
2685
2664
|
readonly alpha: number;
|
|
2686
2665
|
|
|
2687
2666
|
/**
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2667
|
+
* Creates a new color instance.
|
|
2668
|
+
*
|
|
2669
|
+
* @param red The red component.
|
|
2670
|
+
* @param green The green component.
|
|
2671
|
+
* @param blue The blue component.
|
|
2672
|
+
* @param alpha The alpha component.
|
|
2673
|
+
*/
|
|
2695
2674
|
constructor(red: number, green: number, blue: number, alpha: number);
|
|
2696
2675
|
}
|
|
2697
2676
|
|
|
2698
2677
|
/**
|
|
2699
|
-
|
|
2700
|
-
|
|
2678
|
+
* Represents a color range from a document.
|
|
2679
|
+
*/
|
|
2701
2680
|
export class ColorInformation {
|
|
2702
|
-
|
|
2703
2681
|
/**
|
|
2704
|
-
|
|
2705
|
-
|
|
2682
|
+
* The range in the document where this color appears.
|
|
2683
|
+
*/
|
|
2706
2684
|
range: Range;
|
|
2707
2685
|
|
|
2708
2686
|
/**
|
|
2709
|
-
|
|
2710
|
-
|
|
2687
|
+
* The actual color value for this color range.
|
|
2688
|
+
*/
|
|
2711
2689
|
color: Color;
|
|
2712
2690
|
|
|
2713
2691
|
/**
|
|
2714
|
-
|
|
2715
|
-
|
|
2716
|
-
|
|
2717
|
-
|
|
2718
|
-
|
|
2719
|
-
|
|
2692
|
+
* Creates a new color range.
|
|
2693
|
+
*
|
|
2694
|
+
* @param range The range the color appears in. Must not be empty.
|
|
2695
|
+
* @param color The value of the color.
|
|
2696
|
+
* @param format The format in which this color is currently formatted.
|
|
2697
|
+
*/
|
|
2720
2698
|
constructor(range: Range, color: Color);
|
|
2721
2699
|
}
|
|
2722
2700
|
|
|
2723
2701
|
/**
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2702
|
+
* A color presentation object describes how a [`color`](#Color) should be represented as text and what
|
|
2703
|
+
* edits are required to refer to it from source code.
|
|
2704
|
+
*
|
|
2705
|
+
* For some languages one color can have multiple presentations, e.g. css can represent the color red with
|
|
2706
|
+
* the constant `Red`, the hex-value `#ff0000`, or in rgba and hsla forms. In csharp other representations
|
|
2707
|
+
* apply, e.g. `System.Drawing.Color.Red`.
|
|
2708
|
+
*/
|
|
2731
2709
|
export class ColorPresentation {
|
|
2732
|
-
|
|
2733
2710
|
/**
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2711
|
+
* The label of this color presentation. It will be shown on the color
|
|
2712
|
+
* picker header. By default this is also the text that is inserted when selecting
|
|
2713
|
+
* this color presentation.
|
|
2714
|
+
*/
|
|
2738
2715
|
label: string;
|
|
2739
2716
|
|
|
2740
2717
|
/**
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2718
|
+
* An [edit](#TextEdit) which is applied to a document when selecting
|
|
2719
|
+
* this presentation for the color. When `falsy` the [label](#ColorPresentation.label)
|
|
2720
|
+
* is used.
|
|
2721
|
+
*/
|
|
2745
2722
|
textEdit?: TextEdit;
|
|
2746
2723
|
|
|
2747
2724
|
/**
|
|
2748
|
-
|
|
2749
|
-
|
|
2750
|
-
|
|
2725
|
+
* An optional array of additional [text edits](#TextEdit) that are applied when
|
|
2726
|
+
* selecting this color presentation. Edits must not overlap with the main [edit](#ColorPresentation.textEdit) nor with themselves.
|
|
2727
|
+
*/
|
|
2751
2728
|
additionalTextEdits?: TextEdit[];
|
|
2752
2729
|
|
|
2753
2730
|
/**
|
|
2754
|
-
|
|
2755
|
-
|
|
2756
|
-
|
|
2757
|
-
|
|
2731
|
+
* Creates a new color presentation.
|
|
2732
|
+
*
|
|
2733
|
+
* @param label The label of this color presentation.
|
|
2734
|
+
*/
|
|
2758
2735
|
constructor(label: string);
|
|
2759
2736
|
}
|
|
2760
2737
|
|
|
2761
2738
|
/**
|
|
2762
|
-
|
|
2763
|
-
|
|
2764
|
-
|
|
2739
|
+
* The document color provider defines the contract between extensions and feature of
|
|
2740
|
+
* picking and modifying colors in the editor.
|
|
2741
|
+
*/
|
|
2765
2742
|
export interface DocumentColorProvider {
|
|
2766
|
-
|
|
2767
2743
|
/**
|
|
2768
|
-
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2744
|
+
* Provide colors for the given document.
|
|
2745
|
+
*
|
|
2746
|
+
* @param document The document in which the command was invoked.
|
|
2747
|
+
* @param token A cancellation token.
|
|
2748
|
+
* @return An array of [color information](#ColorInformation) or a thenable that resolves to such. The lack of a result
|
|
2749
|
+
* can be signaled by returning `undefined`, `null`, or an empty array.
|
|
2750
|
+
*/
|
|
2775
2751
|
provideDocumentColors(document: TextDocument, token: CancellationToken): ProviderResult<ColorInformation[]>;
|
|
2776
2752
|
|
|
2777
2753
|
/**
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
provideColorPresentations(
|
|
2754
|
+
* Provide [representations](#ColorPresentation) for a color.
|
|
2755
|
+
*
|
|
2756
|
+
* @param color The color to show and insert.
|
|
2757
|
+
* @param context A context object with additional information
|
|
2758
|
+
* @param token A cancellation token.
|
|
2759
|
+
* @return An array of color presentations or a thenable that resolves to such. The lack of a result
|
|
2760
|
+
* can be signaled by returning `undefined`, `null`, or an empty array.
|
|
2761
|
+
*/
|
|
2762
|
+
provideColorPresentations(
|
|
2763
|
+
color: Color,
|
|
2764
|
+
context: { document: TextDocument; range: Range },
|
|
2765
|
+
token: CancellationToken,
|
|
2766
|
+
): ProviderResult<ColorPresentation[]>;
|
|
2787
2767
|
}
|
|
2788
2768
|
}
|