mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
more review comment addressing, added overview to workspace command palette
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com>
This commit is contained in:
parent
5e7379f187
commit
b756eb3323
@ -46,7 +46,7 @@ export class WorkspaceClusterStore extends ItemStore<ClusterItem> {
|
||||
|
||||
const clusterId = cluster.id;
|
||||
|
||||
return super.removeItem(clusterItem, async () => clusterStore.removeById(clusterId));
|
||||
return super.removeItem(clusterItem, () => clusterStore.removeById(clusterId));
|
||||
}
|
||||
|
||||
async removeSelectedItems() {
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
.WorkspaceOverview {
|
||||
background-color: var(--mainBackground);
|
||||
|
||||
.TableCell {
|
||||
display: flex;
|
||||
align-items: left;
|
||||
|
||||
@ -14,6 +14,7 @@ import { clusterViewURL } from "../cluster-manager/cluster-view.route";
|
||||
|
||||
@observer
|
||||
export class ChooseWorkspace extends React.Component {
|
||||
private static overviewActionId = "__overview__";
|
||||
private static addActionId = "__add__";
|
||||
private static removeActionId = "__remove__";
|
||||
private static editActionId = "__edit__";
|
||||
@ -23,6 +24,8 @@ export class ChooseWorkspace extends React.Component {
|
||||
return { value: workspace.id, label: workspace.name };
|
||||
});
|
||||
|
||||
options.push({ value: ChooseWorkspace.overviewActionId, label: "Workspace: Overview" });
|
||||
|
||||
options.push({ value: ChooseWorkspace.addActionId, label: "Add workspace ..." });
|
||||
|
||||
if (options.length > 1) {
|
||||
@ -37,6 +40,13 @@ export class ChooseWorkspace extends React.Component {
|
||||
}
|
||||
|
||||
onChange(id: string) {
|
||||
if (id === ChooseWorkspace.overviewActionId) {
|
||||
navigate(landingURL()); // overview of active workspace. TODO: change name from landing
|
||||
CommandOverlay.close();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (id === ChooseWorkspace.addActionId) {
|
||||
CommandOverlay.open(<AddWorkspace />);
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user