mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Explicitly initialize registries
- Helps moves towards turning on banning CyclicImports Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
1 parent
c18df6bcae
commit
6d10f011e5
101 files changed
+1178
-1087
No files matched your search
@@ -24,7 +24,6 @@ import "./view.scss";
|
||||
import { observer } from "mobx-react";
|
||||
import React from "react";
|
||||
import type { RouteComponentProps } from "react-router";
|
||||
import { kubeObjectMenuRegistry } from "../../../../extensions/registries/kube-object-menu-registry";
|
||||
import type { ServiceAccount } from "../../../api/endpoints/service-accounts.api";
|
||||
import { Icon } from "../../icon";
|
||||
import { KubeObjectListLayout } from "../../kube-object";
|
||||
@@ -89,21 +88,13 @@ export class ServiceAccounts extends React.Component<Props> {
|
||||
}
|
||||
}
|
||||
|
||||
function ServiceAccountMenu(props: KubeObjectMenuProps<ServiceAccount>) {
|
||||
export function ServiceAccountMenu(props: KubeObjectMenuProps<ServiceAccount>) {
|
||||
const { object, toolbar } = props;
|
||||
|
||||
return (
|
||||
<MenuItem onClick={() => openServiceAccountKubeConfig(object)}>
|
||||
<Icon material="insert_drive_file" title="Kubeconfig File" interactive={toolbar}/>
|
||||
<Icon material="insert_drive_file" title="Kubeconfig File" interactive={toolbar} />
|
||||
<span className="title">Kubeconfig</span>
|
||||
</MenuItem>
|
||||
);
|
||||
}
|
||||
|
||||
kubeObjectMenuRegistry.add({
|
||||
kind: "ServiceAccount",
|
||||
apiVersions: ["v1"],
|
||||
components: {
|
||||
MenuItem: ServiceAccountMenu
|
||||
}
|
||||
});
|
||||
Reference in new issue
Block a user