mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Enforce some naming conventions (#4813)
This commit is contained in:
1 parent
dc6615f98f
commit
0b32775d40
197 files changed
+630
-634
No files matched your search
@@ -21,14 +21,14 @@ import { ClusterRoleBindingDialog } from "./dialog";
|
||||
import { clusterRoleBindingsStore } from "./store";
|
||||
import { hashClusterRoleBindingSubject } from "./hashers";
|
||||
|
||||
interface Props extends KubeObjectDetailsProps<ClusterRoleBinding> {
|
||||
export interface ClusterRoleBindingDetailsProps extends KubeObjectDetailsProps<ClusterRoleBinding> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class ClusterRoleBindingDetails extends React.Component<Props> {
|
||||
export class ClusterRoleBindingDetails extends React.Component<ClusterRoleBindingDetailsProps> {
|
||||
selectedSubjects = new ObservableHashSet<ClusterRoleBindingSubject>([], hashClusterRoleBindingSubject);
|
||||
|
||||
constructor(props: Props) {
|
||||
constructor(props: ClusterRoleBindingDetailsProps) {
|
||||
super(props);
|
||||
autoBind(this);
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ import { ObservableHashSet, nFircate } from "../../../utils";
|
||||
import { Input } from "../../input";
|
||||
import { TooltipPosition } from "../../tooltip";
|
||||
|
||||
interface Props extends Partial<DialogProps> {
|
||||
export interface ClusterRoleBindingDialogProps extends Partial<DialogProps> {
|
||||
}
|
||||
|
||||
interface DialogState {
|
||||
@@ -34,12 +34,12 @@ interface DialogState {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class ClusterRoleBindingDialog extends React.Component<Props> {
|
||||
export class ClusterRoleBindingDialog extends React.Component<ClusterRoleBindingDialogProps> {
|
||||
static state = observable.object<DialogState>({
|
||||
isOpen: false,
|
||||
});
|
||||
|
||||
constructor(props: Props) {
|
||||
constructor(props: ClusterRoleBindingDialogProps) {
|
||||
super(props);
|
||||
makeObservable(this);
|
||||
}
|
||||
|
||||
@@ -23,11 +23,11 @@ enum columnId {
|
||||
age = "age",
|
||||
}
|
||||
|
||||
interface Props extends RouteComponentProps<ClusterRoleBindingsRouteParams> {
|
||||
export interface ClusterRoleBindingsProps extends RouteComponentProps<ClusterRoleBindingsRouteParams> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class ClusterRoleBindings extends React.Component<Props> {
|
||||
export class ClusterRoleBindings extends React.Component<ClusterRoleBindingsProps> {
|
||||
render() {
|
||||
return (
|
||||
<>
|
||||
|
||||
@@ -16,16 +16,16 @@ import { Notifications } from "../../notifications";
|
||||
import { Wizard, WizardStep } from "../../wizard";
|
||||
import { clusterRolesStore } from "./store";
|
||||
|
||||
interface Props extends Partial<DialogProps> {
|
||||
export interface AddClusterRoleDialogProps extends Partial<DialogProps> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class AddClusterRoleDialog extends React.Component<Props> {
|
||||
export class AddClusterRoleDialog extends React.Component<AddClusterRoleDialogProps> {
|
||||
static isOpen = observable.box(false);
|
||||
|
||||
@observable clusterRoleName = "";
|
||||
|
||||
constructor(props: Props) {
|
||||
constructor(props: AddClusterRoleDialogProps) {
|
||||
super(props);
|
||||
makeObservable(this);
|
||||
}
|
||||
|
||||
@@ -13,11 +13,11 @@ import type { KubeObjectDetailsProps } from "../../kube-object-details";
|
||||
import { KubeObjectMeta } from "../../kube-object-meta";
|
||||
import type { ClusterRole } from "../../../../common/k8s-api/endpoints";
|
||||
|
||||
interface Props extends KubeObjectDetailsProps<ClusterRole> {
|
||||
export interface ClusterRoleDetailsProps extends KubeObjectDetailsProps<ClusterRole> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class ClusterRoleDetails extends React.Component<Props> {
|
||||
export class ClusterRoleDetails extends React.Component<ClusterRoleDetailsProps> {
|
||||
render() {
|
||||
const { object: clusterRole } = this.props;
|
||||
|
||||
|
||||
@@ -20,11 +20,11 @@ enum columnId {
|
||||
age = "age",
|
||||
}
|
||||
|
||||
interface Props extends RouteComponentProps<ClusterRolesRouteParams> {
|
||||
export interface ClusterRolesProps extends RouteComponentProps<ClusterRolesRouteParams> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class ClusterRoles extends React.Component<Props> {
|
||||
export class ClusterRoles extends React.Component<ClusterRolesProps> {
|
||||
render() {
|
||||
return (
|
||||
<>
|
||||
|
||||
@@ -21,11 +21,11 @@ import { roleBindingsStore } from "./store";
|
||||
import { ObservableHashSet } from "../../../../common/utils/hash-set";
|
||||
import { hashRoleBindingSubject } from "./hashers";
|
||||
|
||||
interface Props extends KubeObjectDetailsProps<RoleBinding> {
|
||||
export interface RoleBindingDetailsProps extends KubeObjectDetailsProps<RoleBinding> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class RoleBindingDetails extends React.Component<Props> {
|
||||
export class RoleBindingDetails extends React.Component<RoleBindingDetailsProps> {
|
||||
selectedSubjects = new ObservableHashSet<RoleBindingSubject>([], hashRoleBindingSubject);
|
||||
|
||||
async componentDidMount() {
|
||||
|
||||
@@ -26,7 +26,7 @@ import { clusterRolesStore } from "../+cluster-roles/store";
|
||||
import { Input } from "../../input";
|
||||
import { ObservableHashSet, nFircate } from "../../../utils";
|
||||
|
||||
interface Props extends Partial<DialogProps> {
|
||||
export interface RoleBindingDialogProps extends Partial<DialogProps> {
|
||||
}
|
||||
|
||||
interface DialogState {
|
||||
@@ -35,12 +35,12 @@ interface DialogState {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class RoleBindingDialog extends React.Component<Props> {
|
||||
export class RoleBindingDialog extends React.Component<RoleBindingDialogProps> {
|
||||
static state = observable.object<DialogState>({
|
||||
isOpen: false,
|
||||
});
|
||||
|
||||
constructor(props: Props) {
|
||||
constructor(props: RoleBindingDialogProps) {
|
||||
super(props);
|
||||
makeObservable(this);
|
||||
}
|
||||
|
||||
@@ -23,11 +23,11 @@ enum columnId {
|
||||
age = "age",
|
||||
}
|
||||
|
||||
interface Props extends RouteComponentProps<RoleBindingsRouteParams> {
|
||||
export interface RoleBindingsProps extends RouteComponentProps<RoleBindingsRouteParams> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class RoleBindings extends React.Component<Props> {
|
||||
export class RoleBindings extends React.Component<RoleBindingsProps> {
|
||||
render() {
|
||||
return (
|
||||
<>
|
||||
|
||||
@@ -18,17 +18,17 @@ import { Notifications } from "../../notifications";
|
||||
import { Wizard, WizardStep } from "../../wizard";
|
||||
import { rolesStore } from "./store";
|
||||
|
||||
interface Props extends Partial<DialogProps> {
|
||||
export interface AddRoleDialogProps extends Partial<DialogProps> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class AddRoleDialog extends React.Component<Props> {
|
||||
export class AddRoleDialog extends React.Component<AddRoleDialogProps> {
|
||||
static isOpen = observable.box(false);
|
||||
|
||||
@observable roleName = "";
|
||||
@observable namespace = "";
|
||||
|
||||
constructor(props: Props) {
|
||||
constructor(props: AddRoleDialogProps) {
|
||||
super(props);
|
||||
makeObservable(this);
|
||||
}
|
||||
|
||||
@@ -13,11 +13,11 @@ import { DrawerTitle } from "../../drawer";
|
||||
import type { KubeObjectDetailsProps } from "../../kube-object-details";
|
||||
import { KubeObjectMeta } from "../../kube-object-meta";
|
||||
|
||||
interface Props extends KubeObjectDetailsProps<Role> {
|
||||
export interface RoleDetailsProps extends KubeObjectDetailsProps<Role> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class RoleDetails extends React.Component<Props> {
|
||||
export class RoleDetails extends React.Component<RoleDetailsProps> {
|
||||
render() {
|
||||
const { object: role } = this.props;
|
||||
|
||||
|
||||
@@ -20,11 +20,11 @@ enum columnId {
|
||||
age = "age",
|
||||
}
|
||||
|
||||
interface Props extends RouteComponentProps<RolesRouteParams> {
|
||||
export interface RolesProps extends RouteComponentProps<RolesRouteParams> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class Roles extends React.Component<Props> {
|
||||
export class Roles extends React.Component<RolesProps> {
|
||||
render() {
|
||||
return (
|
||||
<>
|
||||
|
||||
@@ -19,17 +19,17 @@ import { Notifications } from "../../notifications";
|
||||
import { Wizard, WizardStep } from "../../wizard";
|
||||
import { serviceAccountsStore } from "./store";
|
||||
|
||||
interface Props extends Partial<DialogProps> {
|
||||
export interface CreateServiceAccountDialogProps extends Partial<DialogProps> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class CreateServiceAccountDialog extends React.Component<Props> {
|
||||
export class CreateServiceAccountDialog extends React.Component<CreateServiceAccountDialogProps> {
|
||||
static isOpen = observable.box(false);
|
||||
|
||||
@observable name = "";
|
||||
@observable namespace = "default";
|
||||
|
||||
constructor(props: Props) {
|
||||
constructor(props: CreateServiceAccountDialogProps) {
|
||||
super(props);
|
||||
makeObservable(this);
|
||||
}
|
||||
|
||||
@@ -20,11 +20,11 @@ import { Spinner } from "../../spinner";
|
||||
import { ServiceAccountsSecret } from "./secret";
|
||||
import { getDetailsUrl } from "../../kube-detail-params";
|
||||
|
||||
interface Props extends KubeObjectDetailsProps<ServiceAccount> {
|
||||
export interface ServiceAccountsDetailsProps extends KubeObjectDetailsProps<ServiceAccount> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class ServiceAccountsDetails extends React.Component<Props> {
|
||||
export class ServiceAccountsDetails extends React.Component<ServiceAccountsDetailsProps> {
|
||||
@observable secrets: Secret[];
|
||||
@observable imagePullSecrets: Secret[];
|
||||
|
||||
@@ -53,7 +53,7 @@ export class ServiceAccountsDetails extends React.Component<Props> {
|
||||
]);
|
||||
}
|
||||
|
||||
constructor(props: Props) {
|
||||
constructor(props: ServiceAccountsDetailsProps) {
|
||||
super(props);
|
||||
makeObservable(this);
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@ import type { Secret } from "../../../../common/k8s-api/endpoints/secret.api";
|
||||
import { prevDefault } from "../../../utils";
|
||||
import { Icon } from "../../icon";
|
||||
|
||||
interface Props {
|
||||
export interface ServiceAccountsSecretProps {
|
||||
secret: Secret;
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ interface State {
|
||||
showToken: boolean;
|
||||
}
|
||||
|
||||
export class ServiceAccountsSecret extends React.Component<Props, State> {
|
||||
export class ServiceAccountsSecret extends React.Component<ServiceAccountsSecretProps, State> {
|
||||
public state: State = {
|
||||
showToken: false,
|
||||
};
|
||||
|
||||
@@ -20,11 +20,11 @@ enum columnId {
|
||||
age = "age",
|
||||
}
|
||||
|
||||
interface Props extends RouteComponentProps<ServiceAccountsRouteParams> {
|
||||
export interface ServiceAccountsProps extends RouteComponentProps<ServiceAccountsRouteParams> {
|
||||
}
|
||||
|
||||
@observer
|
||||
export class ServiceAccounts extends React.Component<Props> {
|
||||
export class ServiceAccounts extends React.Component<ServiceAccountsProps> {
|
||||
render() {
|
||||
return (
|
||||
<>
|
||||
|
||||
Reference in new issue
Block a user