Refactor kube-object-status exports

Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>
This commit is contained in:
Lauri Nevala committed 2020-11-05 14:18:49 +02:00
1 parent d833587bbb
commit edeaeabe3f
4 files changed
+16 -17

No files matched your search

+1 -1
View File
@@ -7,4 +7,4 @@ export * from "./status-bar-registry"
export * from "./kube-object-detail-registry";
export * from "./kube-object-menu-registry";
export * from "./cluster-feature-registry"
export { kubeObjectStatusRegistry, KubeObjectStatusRegistration } from "./kube-object-status-registry"
export * from "./kube-object-status-registry"
@@ -1,19 +1,6 @@
import { KubeObject } from "../renderer-api/k8s-api";
import { KubeObject, KubeObjectStatus } from "../renderer-api/k8s-api";
import { BaseRegistry } from "./base-registry";
export enum KubeObjectStatusLevel {
INFO = 1,
WARNING = 2,
CRITICAL = 3
}
export type KubeObjectStatus = {
level: number;
text: string;
timestamp?: string;
}
export interface KubeObjectStatusRegistration {
kind: string;
apiVersions: string[];
+12 -1
View File
@@ -30,4 +30,15 @@ export { Role, roleApi } from "../../renderer/api/endpoints";
export { RoleBinding, roleBindingApi } from "../../renderer/api/endpoints";
export { ClusterRole, clusterRoleApi } from "../../renderer/api/endpoints";
export { ClusterRoleBinding, clusterRoleBindingApi } from "../../renderer/api/endpoints";
export { KubeObjectStatus, KubeObjectStatusLevel } from "../registries/kube-object-status-registry"
export type KubeObjectStatus = {
level: KubeObjectStatusLevel;
text: string;
timestamp?: string;
}
export enum KubeObjectStatusLevel {
INFO = 1,
WARNING = 2,
CRITICAL = 3
}
@@ -4,7 +4,8 @@ import React from "react";
import { Icon } from "../icon";
import { KubeObject } from "../../api/kube-object";
import { cssNames, formatDuration } from "../../utils";
import { KubeObjectStatusRegistration, KubeObjectStatus, KubeObjectStatusLevel, kubeObjectStatusRegistry } from "../../../extensions/registries/kube-object-status-registry"
import { KubeObjectStatusRegistration, kubeObjectStatusRegistry } from "../../../extensions/registries/kube-object-status-registry"
import { KubeObjectStatus, KubeObjectStatusLevel } from "../../..//extensions/renderer-api/k8s-api";
import { computed } from "mobx";
interface Props {