@k8slens/extensions 5.3.1-git.58ea0dc822.0 → 5.3.1-git.58ffb8e3e4.0
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/dist/src/common/catalog-entities/kubernetes-cluster.d.ts +1 -2
- package/dist/src/common/catalog-entities/web-link.d.ts +0 -2
- package/dist/src/common/hotbar-store.d.ts +16 -11
- package/dist/src/common/hotbar-store.injectable.d.ts +4 -0
- package/dist/src/common/hotbar-types.d.ts +5 -2
- package/dist/src/common/ipc/index.d.ts +1 -0
- package/dist/src/common/k8s-api/endpoints/crd.api.d.ts +29 -28
- package/dist/src/common/vars.d.ts +1 -0
- package/dist/src/extensions/extension-api.js +357 -116
- package/dist/src/extensions/lens-main-extension.d.ts +2 -0
- package/dist/src/extensions/lens-renderer-extension.d.ts +2 -1
- package/dist/src/extensions/registries/base-registry.d.ts +1 -1
- package/dist/src/extensions/registries/entity-setting-registry.d.ts +1 -1
- package/dist/src/extensions/registries/index.d.ts +0 -1
- package/dist/src/main/routes/port-forward-route.d.ts +0 -1
- package/dist/src/main/tray/tray-menu-items.injectable.d.ts +3 -0
- package/dist/src/main/tray/tray-menu-items.test.d.ts +1 -0
- package/dist/src/main/{tray.d.ts → tray/tray.d.ts} +4 -2
- package/dist/src/renderer/api/__tests__/catalog-entity-registry.test.d.ts +1 -1
- package/dist/src/renderer/api/catalog-entity-registry.d.ts +4 -0
- package/dist/src/renderer/api/catalog-entity.d.ts +1 -5
- package/dist/src/{main/catalog-sources → renderer/api}/helpers/general-active-sync.d.ts +0 -0
- package/dist/src/renderer/components/+custom-resources/custom-resources.injectable.d.ts +23 -0
- package/dist/src/renderer/components/+network-port-forwards/port-forward-menu.d.ts +2 -0
- package/dist/src/renderer/components/+network-services/service-port-component.d.ts +1 -0
- package/dist/src/renderer/components/+workloads-pods/pod-container-port.d.ts +1 -0
- package/dist/src/renderer/components/activate-entity-command/activate-entity-command.d.ts +1 -9
- package/dist/src/renderer/components/catalog-entities/weblink-add-command.d.ts +1 -11
- package/dist/src/renderer/components/cluster-manager/active-hotbar-name.d.ts +2 -1
- package/dist/src/renderer/components/command-palette/command-container.d.ts +1 -7
- package/dist/src/renderer/components/command-palette/command-dialog.d.ts +1 -13
- package/dist/src/renderer/components/command-palette/command-overlay.injectable.d.ts +31 -0
- package/dist/src/renderer/components/command-palette/index.d.ts +1 -1
- package/dist/src/renderer/components/command-palette/registered-commands/internal-commands.injectable.d.ts +25 -0
- package/dist/src/renderer/components/command-palette/registered-commands/registered-commands.injectable.d.ts +25 -0
- package/dist/src/renderer/components/dock/terminal.d.ts +1 -1
- package/dist/src/renderer/components/hotbar/hotbar-add-command.d.ts +1 -6
- package/dist/src/renderer/components/hotbar/hotbar-menu.d.ts +1 -1
- package/dist/src/renderer/components/hotbar/hotbar-remove-command.d.ts +1 -9
- package/dist/src/renderer/components/hotbar/hotbar-rename-command.d.ts +1 -14
- package/dist/src/renderer/components/hotbar/hotbar-selector.d.ts +3 -3
- package/dist/src/renderer/components/hotbar/hotbar-switch-command.d.ts +1 -12
- package/dist/src/renderer/components/input/input.d.ts +1 -0
- package/dist/src/renderer/components/{command-palette/command-overlay.d.ts → input/validators/unique-hotbar-name.injectable.d.ts} +4 -8
- package/dist/src/renderer/components/kube-object-menu/dependencies/hide-details.injectable.d.ts +1 -1
- package/dist/src/renderer/components/menu/menu-actions.d.ts +1 -1
- package/dist/src/renderer/components/monaco-editor/monaco-editor.d.ts +1 -1
- package/dist/src/renderer/{components/getDi.d.ts → getDi.d.ts} +0 -0
- package/dist/src/renderer/{components/hotbar/hotbar-display-label.d.ts → getDiForUnitTesting.d.ts} +2 -2
- package/dist/src/renderer/initializers/catalog.d.ts +6 -1
- package/dist/src/renderer/initializers/index.d.ts +0 -1
- package/dist/src/renderer/navigation/helpers.d.ts +1 -1
- package/dist/src/renderer/port-forward/port-forward-dialog.d.ts +1 -1
- package/dist/src/renderer/port-forward/port-forward-item.d.ts +4 -4
- package/dist/src/renderer/port-forward/port-forward-notify.d.ts +1 -0
- package/dist/src/renderer/port-forward/port-forward.store.d.ts +56 -6
- package/dist/src/renderer/theme.store.d.ts +0 -1
- package/dist/src/renderer/window/event-listener.injectable.d.ts +25 -0
- package/package.json +1 -1
- package/dist/src/extensions/registries/command-registry.d.ts +0 -36
- package/dist/src/renderer/components/getDiForUnitTesting.d.ts +0 -22
- package/dist/src/renderer/initializers/command-registry.d.ts +0 -21
|
@@ -27,13 +27,63 @@ export declare class PortForwardStore extends ItemStore<PortForwardItem> {
|
|
|
27
27
|
private init;
|
|
28
28
|
watch(): import("../utils").ExtendableDisposer;
|
|
29
29
|
loadAll(): Promise<any>;
|
|
30
|
-
reset(): void;
|
|
31
30
|
removeSelectedItems(): Promise<void[]>;
|
|
32
31
|
getById(id: string): PortForwardItem;
|
|
33
32
|
}
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
33
|
+
/**
|
|
34
|
+
* start an existing port-forward
|
|
35
|
+
* @param portForward the port-forward to start. If the forwardPort field is 0 then an arbitrary port will be
|
|
36
|
+
* used
|
|
37
|
+
*
|
|
38
|
+
* @returns the port-forward with updated status ("Active" if successfully started, "Disabled" otherwise) and
|
|
39
|
+
* forwardPort
|
|
40
|
+
*
|
|
41
|
+
* @throws if the port-forward does not already exist in the store
|
|
42
|
+
*/
|
|
43
|
+
export declare const startPortForward: (portForward: ForwardedPort) => Promise<ForwardedPort>;
|
|
44
|
+
/**
|
|
45
|
+
* add a port-forward to the store and optionally start it
|
|
46
|
+
* @param portForward the port-forward to add. If the port-forward already exists in the store it will be
|
|
47
|
+
* returned with its current state. If the forwardPort field is 0 then an arbitrary port will be
|
|
48
|
+
* used. If the status field is "Active" or not present then an attempt is made to start the port-forward.
|
|
49
|
+
*
|
|
50
|
+
* @returns the port-forward with updated status ("Active" if successfully started, "Disabled" otherwise) and
|
|
51
|
+
* forwardPort
|
|
52
|
+
*/
|
|
53
|
+
export declare const addPortForward: (portForward: ForwardedPort) => Promise<ForwardedPort>;
|
|
54
|
+
/**
|
|
55
|
+
* get a port-forward from the store, with up-to-date status
|
|
56
|
+
* @param portForward the port-forward to get.
|
|
57
|
+
*
|
|
58
|
+
* @returns the port-forward with updated status ("Active" if running, "Disabled" if not) and
|
|
59
|
+
* forwardPort used.
|
|
60
|
+
*
|
|
61
|
+
* @throws if the port-forward does not exist in the store
|
|
62
|
+
*/
|
|
63
|
+
export declare function getPortForward(portForward: ForwardedPort): Promise<ForwardedPort>;
|
|
64
|
+
/**
|
|
65
|
+
* modifies a port-forward in the store, including the forwardPort and protocol
|
|
66
|
+
* @param portForward the port-forward to modify.
|
|
67
|
+
*
|
|
68
|
+
* @returns the port-forward after being modified.
|
|
69
|
+
*/
|
|
70
|
+
export declare const modifyPortForward: (portForward: ForwardedPort, desiredPort: number) => Promise<ForwardedPort>;
|
|
71
|
+
/**
|
|
72
|
+
* stop an existing port-forward. Its status is set to "Disabled" after successfully stopped.
|
|
73
|
+
* @param portForward the port-forward to stop.
|
|
74
|
+
*
|
|
75
|
+
* @throws if the port-forward could not be stopped. Its status is unchanged
|
|
76
|
+
*/
|
|
77
|
+
export declare const stopPortForward: (portForward: ForwardedPort) => Promise<void>;
|
|
78
|
+
/**
|
|
79
|
+
* remove and stop an existing port-forward.
|
|
80
|
+
* @param portForward the port-forward to remove.
|
|
81
|
+
*/
|
|
82
|
+
export declare const removePortForward: (portForward: ForwardedPort) => Promise<void>;
|
|
83
|
+
/**
|
|
84
|
+
* gets the list of port-forwards in the store
|
|
85
|
+
*
|
|
86
|
+
* @returns the port-forwards
|
|
87
|
+
*/
|
|
88
|
+
export declare function getPortForwards(): ForwardedPort[];
|
|
39
89
|
export declare const portForwardStore: PortForwardStore;
|
|
@@ -31,7 +31,6 @@ export interface Theme {
|
|
|
31
31
|
monacoTheme: MonacoEditorProps["theme"];
|
|
32
32
|
}
|
|
33
33
|
export declare class ThemeStore extends Singleton {
|
|
34
|
-
static readonly defaultTheme = "lens-dark";
|
|
35
34
|
protected styles: HTMLStyleElement;
|
|
36
35
|
private themes;
|
|
37
36
|
get activeThemeId(): string;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2021 OpenLens Authors
|
|
3
|
+
*
|
|
4
|
+
* Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
5
|
+
* this software and associated documentation files (the "Software"), to deal in
|
|
6
|
+
* the Software without restriction, including without limitation the rights to
|
|
7
|
+
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
8
|
+
* the Software, and to permit persons to whom the Software is furnished to do so,
|
|
9
|
+
* subject to the following conditions:
|
|
10
|
+
*
|
|
11
|
+
* The above copyright notice and this permission notice shall be included in all
|
|
12
|
+
* copies or substantial portions of the Software.
|
|
13
|
+
*
|
|
14
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
|
16
|
+
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
17
|
+
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
18
|
+
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
19
|
+
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
20
|
+
*/
|
|
21
|
+
/// <reference types="@ogre-tools/injectable" />
|
|
22
|
+
import type { Disposer } from "../utils";
|
|
23
|
+
declare function addWindowEventListener<K extends keyof WindowEventMap>(type: K, listener: (this: Window, ev: WindowEventMap[K]) => any, options?: boolean | AddEventListenerOptions): Disposer;
|
|
24
|
+
declare const windowAddEventListenerInjectable: import("@ogre-tools/injectable").Injectable<import("@ogre-tools/injectable").InjectionToken<typeof addWindowEventListener, unknown>, typeof addWindowEventListener, unknown>;
|
|
25
|
+
export default windowAddEventListenerInjectable;
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@k8slens/extensions",
|
|
3
3
|
"productName": "OpenLens extensions",
|
|
4
4
|
"description": "OpenLens - Open Source Kubernetes IDE: extensions",
|
|
5
|
-
"version": "5.3.1-git.
|
|
5
|
+
"version": "5.3.1-git.58ffb8e3e4.0",
|
|
6
6
|
"copyright": "© 2021 OpenLens Authors",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"main": "dist/src/extensions/extension-api.js",
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2021 OpenLens Authors
|
|
3
|
-
*
|
|
4
|
-
* Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
5
|
-
* this software and associated documentation files (the "Software"), to deal in
|
|
6
|
-
* the Software without restriction, including without limitation the rights to
|
|
7
|
-
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
8
|
-
* the Software, and to permit persons to whom the Software is furnished to do so,
|
|
9
|
-
* subject to the following conditions:
|
|
10
|
-
*
|
|
11
|
-
* The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
* copies or substantial portions of the Software.
|
|
13
|
-
*
|
|
14
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
|
16
|
-
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
17
|
-
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
18
|
-
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
19
|
-
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
20
|
-
*/
|
|
21
|
-
import { BaseRegistry } from "./base-registry";
|
|
22
|
-
import type { LensExtension } from "../lens-extension";
|
|
23
|
-
import type { CatalogEntity } from "../../common/catalog";
|
|
24
|
-
export interface CommandContext {
|
|
25
|
-
entity?: CatalogEntity;
|
|
26
|
-
}
|
|
27
|
-
export interface CommandRegistration {
|
|
28
|
-
id: string;
|
|
29
|
-
title: string;
|
|
30
|
-
scope: "entity" | "global";
|
|
31
|
-
action: (context: CommandContext) => void;
|
|
32
|
-
isActive?: (context: CommandContext) => boolean;
|
|
33
|
-
}
|
|
34
|
-
export declare class CommandRegistry extends BaseRegistry<CommandRegistration> {
|
|
35
|
-
add(items: CommandRegistration | CommandRegistration[], extension?: LensExtension): () => void;
|
|
36
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2021 OpenLens Authors
|
|
3
|
-
*
|
|
4
|
-
* Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
5
|
-
* this software and associated documentation files (the "Software"), to deal in
|
|
6
|
-
* the Software without restriction, including without limitation the rights to
|
|
7
|
-
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
8
|
-
* the Software, and to permit persons to whom the Software is furnished to do so,
|
|
9
|
-
* subject to the following conditions:
|
|
10
|
-
*
|
|
11
|
-
* The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
* copies or substantial portions of the Software.
|
|
13
|
-
*
|
|
14
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
|
16
|
-
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
17
|
-
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
18
|
-
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
19
|
-
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
20
|
-
*/
|
|
21
|
-
import { ConfigurableDependencyInjectionContainer } from "@ogre-tools/injectable";
|
|
22
|
-
export declare const getDiForUnitTesting: () => ConfigurableDependencyInjectionContainer;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2021 OpenLens Authors
|
|
3
|
-
*
|
|
4
|
-
* Permission is hereby granted, free of charge, to any person obtaining a copy of
|
|
5
|
-
* this software and associated documentation files (the "Software"), to deal in
|
|
6
|
-
* the Software without restriction, including without limitation the rights to
|
|
7
|
-
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
8
|
-
* the Software, and to permit persons to whom the Software is furnished to do so,
|
|
9
|
-
* subject to the following conditions:
|
|
10
|
-
*
|
|
11
|
-
* The above copyright notice and this permission notice shall be included in all
|
|
12
|
-
* copies or substantial portions of the Software.
|
|
13
|
-
*
|
|
14
|
-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
15
|
-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
|
16
|
-
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
|
17
|
-
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
|
18
|
-
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
|
19
|
-
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
20
|
-
*/
|
|
21
|
-
export declare function initCommandRegistry(): void;
|