mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-08 05:27:52 +00:00
feat(dynamic-secret): Add custom tags to AWS IAM dynamic secret
This commit is contained in:
@@ -0,0 +1,21 @@
|
|||||||
|
import { Knex } from "knex";
|
||||||
|
|
||||||
|
import { TableName } from "../schemas";
|
||||||
|
|
||||||
|
export async function up(knex: Knex): Promise<void> {
|
||||||
|
const hasCol = await knex.schema.hasColumn(TableName.DynamicSecret, "tags");
|
||||||
|
if (!hasCol) {
|
||||||
|
await knex.schema.alterTable(TableName.DynamicSecret, (t) => {
|
||||||
|
t.jsonb("tags").nullable();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export async function down(knex: Knex): Promise<void> {
|
||||||
|
const hasCol = await knex.schema.hasColumn(TableName.DynamicSecret, "tags");
|
||||||
|
if (hasCol) {
|
||||||
|
await knex.schema.alterTable(TableName.DynamicSecret, (t) => {
|
||||||
|
t.dropColumn("tags");
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -29,7 +29,8 @@ export const DynamicSecretsSchema = z.object({
|
|||||||
encryptedInput: zodBuffer,
|
encryptedInput: zodBuffer,
|
||||||
projectGatewayId: z.string().uuid().nullable().optional(),
|
projectGatewayId: z.string().uuid().nullable().optional(),
|
||||||
gatewayId: z.string().uuid().nullable().optional(),
|
gatewayId: z.string().uuid().nullable().optional(),
|
||||||
usernameTemplate: z.string().nullable().optional()
|
usernameTemplate: z.string().nullable().optional(),
|
||||||
|
tags: z.unknown().nullable().optional()
|
||||||
});
|
});
|
||||||
|
|
||||||
export type TDynamicSecrets = z.infer<typeof DynamicSecretsSchema>;
|
export type TDynamicSecrets = z.infer<typeof DynamicSecretsSchema>;
|
||||||
|
|||||||
@@ -80,6 +80,7 @@ export const registerDynamicSecretRouter = async (server: FastifyZodProvider) =>
|
|||||||
environmentSlug: z.string().describe(DYNAMIC_SECRETS.CREATE.environmentSlug).min(1),
|
environmentSlug: z.string().describe(DYNAMIC_SECRETS.CREATE.environmentSlug).min(1),
|
||||||
name: slugSchema({ min: 1, max: 64, field: "Name" }).describe(DYNAMIC_SECRETS.CREATE.name),
|
name: slugSchema({ min: 1, max: 64, field: "Name" }).describe(DYNAMIC_SECRETS.CREATE.name),
|
||||||
metadata: ResourceMetadataSchema.optional(),
|
metadata: ResourceMetadataSchema.optional(),
|
||||||
|
tags: ResourceMetadataSchema.optional(),
|
||||||
usernameTemplate: userTemplateSchema.optional()
|
usernameTemplate: userTemplateSchema.optional()
|
||||||
}),
|
}),
|
||||||
response: {
|
response: {
|
||||||
@@ -146,6 +147,7 @@ export const registerDynamicSecretRouter = async (server: FastifyZodProvider) =>
|
|||||||
.nullable(),
|
.nullable(),
|
||||||
newName: z.string().describe(DYNAMIC_SECRETS.UPDATE.newName).optional(),
|
newName: z.string().describe(DYNAMIC_SECRETS.UPDATE.newName).optional(),
|
||||||
metadata: ResourceMetadataSchema.optional(),
|
metadata: ResourceMetadataSchema.optional(),
|
||||||
|
tags: ResourceMetadataSchema.optional(),
|
||||||
usernameTemplate: userTemplateSchema.nullable().optional()
|
usernameTemplate: userTemplateSchema.nullable().optional()
|
||||||
})
|
})
|
||||||
}),
|
}),
|
||||||
|
|||||||
@@ -166,6 +166,7 @@ export const dynamicSecretLeaseServiceFactory = ({
|
|||||||
usernameTemplate: dynamicSecretCfg.usernameTemplate,
|
usernameTemplate: dynamicSecretCfg.usernameTemplate,
|
||||||
identity,
|
identity,
|
||||||
metadata: { projectId },
|
metadata: { projectId },
|
||||||
|
tags: dynamicSecretCfg.tags as Record<string, string>[] | undefined,
|
||||||
config
|
config
|
||||||
});
|
});
|
||||||
} catch (error: unknown) {
|
} catch (error: unknown) {
|
||||||
|
|||||||
@@ -79,6 +79,7 @@ export const dynamicSecretServiceFactory = ({
|
|||||||
defaultTTL,
|
defaultTTL,
|
||||||
actorAuthMethod,
|
actorAuthMethod,
|
||||||
metadata,
|
metadata,
|
||||||
|
tags,
|
||||||
usernameTemplate
|
usernameTemplate
|
||||||
}: TCreateDynamicSecretDTO) => {
|
}: TCreateDynamicSecretDTO) => {
|
||||||
const project = await projectDAL.findProjectBySlug(projectSlug, actorOrgId);
|
const project = await projectDAL.findProjectBySlug(projectSlug, actorOrgId);
|
||||||
@@ -165,7 +166,8 @@ export const dynamicSecretServiceFactory = ({
|
|||||||
folderId: folder.id,
|
folderId: folder.id,
|
||||||
name,
|
name,
|
||||||
gatewayId: selectedGatewayId,
|
gatewayId: selectedGatewayId,
|
||||||
usernameTemplate
|
usernameTemplate,
|
||||||
|
tags: JSON.stringify(tags)
|
||||||
},
|
},
|
||||||
tx
|
tx
|
||||||
);
|
);
|
||||||
@@ -202,6 +204,7 @@ export const dynamicSecretServiceFactory = ({
|
|||||||
actorOrgId,
|
actorOrgId,
|
||||||
actorAuthMethod,
|
actorAuthMethod,
|
||||||
metadata,
|
metadata,
|
||||||
|
tags,
|
||||||
usernameTemplate
|
usernameTemplate
|
||||||
}: TUpdateDynamicSecretDTO) => {
|
}: TUpdateDynamicSecretDTO) => {
|
||||||
const project = await projectDAL.findProjectBySlug(projectSlug, actorOrgId);
|
const project = await projectDAL.findProjectBySlug(projectSlug, actorOrgId);
|
||||||
@@ -315,7 +318,8 @@ export const dynamicSecretServiceFactory = ({
|
|||||||
name: newName ?? name,
|
name: newName ?? name,
|
||||||
status: null,
|
status: null,
|
||||||
gatewayId: selectedGatewayId,
|
gatewayId: selectedGatewayId,
|
||||||
usernameTemplate
|
usernameTemplate,
|
||||||
|
tags: JSON.stringify(tags)
|
||||||
},
|
},
|
||||||
tx
|
tx
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ export type TCreateDynamicSecretDTO = {
|
|||||||
projectSlug: string;
|
projectSlug: string;
|
||||||
metadata?: ResourceMetadataDTO;
|
metadata?: ResourceMetadataDTO;
|
||||||
usernameTemplate?: string | null;
|
usernameTemplate?: string | null;
|
||||||
|
tags?: ResourceMetadataDTO;
|
||||||
} & Omit<TProjectPermission, "projectId">;
|
} & Omit<TProjectPermission, "projectId">;
|
||||||
|
|
||||||
export type TUpdateDynamicSecretDTO = {
|
export type TUpdateDynamicSecretDTO = {
|
||||||
@@ -35,6 +36,7 @@ export type TUpdateDynamicSecretDTO = {
|
|||||||
inputs?: TProvider["inputs"];
|
inputs?: TProvider["inputs"];
|
||||||
projectSlug: string;
|
projectSlug: string;
|
||||||
metadata?: ResourceMetadataDTO;
|
metadata?: ResourceMetadataDTO;
|
||||||
|
tags?: ResourceMetadataDTO;
|
||||||
usernameTemplate?: string | null;
|
usernameTemplate?: string | null;
|
||||||
} & Omit<TProjectPermission, "projectId">;
|
} & Omit<TProjectPermission, "projectId">;
|
||||||
|
|
||||||
|
|||||||
@@ -119,20 +119,31 @@ export const AwsIamProvider = (): TDynamicProviderFns => {
|
|||||||
identity?: {
|
identity?: {
|
||||||
name: string;
|
name: string;
|
||||||
};
|
};
|
||||||
|
tags?: Record<string, string>[];
|
||||||
metadata: { projectId: string };
|
metadata: { projectId: string };
|
||||||
}) => {
|
}) => {
|
||||||
const { inputs, usernameTemplate, metadata, identity } = data;
|
const { inputs, usernameTemplate, metadata, identity, tags } = data;
|
||||||
|
|
||||||
const providerInputs = await validateProviderInputs(inputs);
|
const providerInputs = await validateProviderInputs(inputs);
|
||||||
const client = await $getClient(providerInputs, metadata.projectId);
|
const client = await $getClient(providerInputs, metadata.projectId);
|
||||||
|
|
||||||
const username = generateUsername(usernameTemplate, identity);
|
const username = generateUsername(usernameTemplate, identity);
|
||||||
const { policyArns, userGroups, policyDocument, awsPath, permissionBoundaryPolicyArn } = providerInputs;
|
const { policyArns, userGroups, policyDocument, awsPath, permissionBoundaryPolicyArn } = providerInputs;
|
||||||
|
const awsTags = [{ Key: "createdBy", Value: "infisical-dynamic-secret" }];
|
||||||
|
|
||||||
|
if (tags && Array.isArray(tags)) {
|
||||||
|
const additionalTags = tags.map((tag) => ({
|
||||||
|
Key: tag.key,
|
||||||
|
Value: tag.value
|
||||||
|
}));
|
||||||
|
awsTags.push(...additionalTags);
|
||||||
|
}
|
||||||
|
|
||||||
const createUserRes = await client.send(
|
const createUserRes = await client.send(
|
||||||
new CreateUserCommand({
|
new CreateUserCommand({
|
||||||
Path: awsPath,
|
Path: awsPath,
|
||||||
PermissionsBoundary: permissionBoundaryPolicyArn || undefined,
|
PermissionsBoundary: permissionBoundaryPolicyArn || undefined,
|
||||||
Tags: [{ Key: "createdBy", Value: "infisical-dynamic-secret" }],
|
Tags: awsTags,
|
||||||
UserName: username
|
UserName: username
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -525,6 +525,7 @@ export type TDynamicProviderFns = {
|
|||||||
name: string;
|
name: string;
|
||||||
};
|
};
|
||||||
metadata: { projectId: string };
|
metadata: { projectId: string };
|
||||||
|
tags?: Record<string, string>[];
|
||||||
config?: TDynamicSecretLeaseConfig;
|
config?: TDynamicSecretLeaseConfig;
|
||||||
}) => Promise<{ entityId: string; data: unknown }>;
|
}) => Promise<{ entityId: string; data: unknown }>;
|
||||||
validateConnection: (inputs: unknown, metadata: { projectId: string }) => Promise<boolean>;
|
validateConnection: (inputs: unknown, metadata: { projectId: string }) => Promise<boolean>;
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ export type TDynamicSecret = {
|
|||||||
maxTTL: string;
|
maxTTL: string;
|
||||||
usernameTemplate?: string | null;
|
usernameTemplate?: string | null;
|
||||||
metadata?: { key: string; value: string }[];
|
metadata?: { key: string; value: string }[];
|
||||||
|
tags?: { key: string; value: string }[];
|
||||||
};
|
};
|
||||||
|
|
||||||
export enum DynamicSecretProviders {
|
export enum DynamicSecretProviders {
|
||||||
@@ -89,6 +90,7 @@ export type TDynamicSecretProvider =
|
|||||||
}
|
}
|
||||||
| {
|
| {
|
||||||
type: DynamicSecretProviders.AwsIam;
|
type: DynamicSecretProviders.AwsIam;
|
||||||
|
tags?: { key: string; value: string }[];
|
||||||
inputs:
|
inputs:
|
||||||
| {
|
| {
|
||||||
method: DynamicSecretAwsIamAuth.AccessKey;
|
method: DynamicSecretAwsIamAuth.AccessKey;
|
||||||
@@ -345,6 +347,7 @@ export type TCreateDynamicSecretDTO = {
|
|||||||
name: string;
|
name: string;
|
||||||
metadata?: { key: string; value: string }[];
|
metadata?: { key: string; value: string }[];
|
||||||
usernameTemplate?: string;
|
usernameTemplate?: string;
|
||||||
|
tags?: { key: string; value: string }[];
|
||||||
};
|
};
|
||||||
|
|
||||||
export type TUpdateDynamicSecretDTO = {
|
export type TUpdateDynamicSecretDTO = {
|
||||||
@@ -359,6 +362,7 @@ export type TUpdateDynamicSecretDTO = {
|
|||||||
maxTTL?: string | null;
|
maxTTL?: string | null;
|
||||||
inputs?: unknown;
|
inputs?: unknown;
|
||||||
usernameTemplate?: string | null;
|
usernameTemplate?: string | null;
|
||||||
|
tags?: { key: string; value: string }[];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
+13
-4
@@ -21,6 +21,8 @@ import {
|
|||||||
} from "@app/hooks/api/dynamicSecret/types";
|
} from "@app/hooks/api/dynamicSecret/types";
|
||||||
import { WorkspaceEnv } from "@app/hooks/api/types";
|
import { WorkspaceEnv } from "@app/hooks/api/types";
|
||||||
|
|
||||||
|
import { MetadataForm } from "../../DynamicSecretListView/MetadataForm";
|
||||||
|
|
||||||
const formSchema = z.object({
|
const formSchema = z.object({
|
||||||
provider: z.discriminatedUnion("method", [
|
provider: z.discriminatedUnion("method", [
|
||||||
z.object({
|
z.object({
|
||||||
@@ -67,7 +69,10 @@ const formSchema = z.object({
|
|||||||
}),
|
}),
|
||||||
name: z.string().refine((val) => val.toLowerCase() === val, "Must be lowercase"),
|
name: z.string().refine((val) => val.toLowerCase() === val, "Must be lowercase"),
|
||||||
environment: z.object({ name: z.string(), slug: z.string() }),
|
environment: z.object({ name: z.string(), slug: z.string() }),
|
||||||
usernameTemplate: z.string().nullable().optional()
|
usernameTemplate: z.string().nullable().optional(),
|
||||||
|
tags: z
|
||||||
|
.array(z.object({ key: z.string().trim().min(1), value: z.string().trim().min(1) }))
|
||||||
|
.optional()
|
||||||
});
|
});
|
||||||
type TForm = z.infer<typeof formSchema>;
|
type TForm = z.infer<typeof formSchema>;
|
||||||
|
|
||||||
@@ -100,7 +105,8 @@ export const AwsIamInputForm = ({
|
|||||||
usernameTemplate: "{{randomUsername}}",
|
usernameTemplate: "{{randomUsername}}",
|
||||||
provider: {
|
provider: {
|
||||||
method: DynamicSecretAwsIamAuth.AssumeRole
|
method: DynamicSecretAwsIamAuth.AssumeRole
|
||||||
}
|
},
|
||||||
|
tags: []
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -113,7 +119,8 @@ export const AwsIamInputForm = ({
|
|||||||
provider,
|
provider,
|
||||||
defaultTTL,
|
defaultTTL,
|
||||||
environment,
|
environment,
|
||||||
usernameTemplate
|
usernameTemplate,
|
||||||
|
tags
|
||||||
}: TForm) => {
|
}: TForm) => {
|
||||||
// wait till previous request is finished
|
// wait till previous request is finished
|
||||||
if (createDynamicSecret.isPending) return;
|
if (createDynamicSecret.isPending) return;
|
||||||
@@ -129,7 +136,8 @@ export const AwsIamInputForm = ({
|
|||||||
projectSlug,
|
projectSlug,
|
||||||
environmentSlug: environment.slug,
|
environmentSlug: environment.slug,
|
||||||
usernameTemplate:
|
usernameTemplate:
|
||||||
!usernameTemplate || isDefaultUsernameTemplate ? undefined : usernameTemplate
|
!usernameTemplate || isDefaultUsernameTemplate ? undefined : usernameTemplate,
|
||||||
|
tags
|
||||||
});
|
});
|
||||||
onCompleted();
|
onCompleted();
|
||||||
} catch {
|
} catch {
|
||||||
@@ -398,6 +406,7 @@ export const AwsIamInputForm = ({
|
|||||||
</FormControl>
|
</FormControl>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
<MetadataForm control={control} name="tags" isValueRequired />
|
||||||
{!isSingleEnvironmentMode && (
|
{!isSingleEnvironmentMode && (
|
||||||
<Controller
|
<Controller
|
||||||
control={control}
|
control={control}
|
||||||
|
|||||||
+13
-3
@@ -10,6 +10,8 @@ import { useUpdateDynamicSecret } from "@app/hooks/api";
|
|||||||
import { DynamicSecretAwsIamAuth, TDynamicSecret } from "@app/hooks/api/dynamicSecret/types";
|
import { DynamicSecretAwsIamAuth, TDynamicSecret } from "@app/hooks/api/dynamicSecret/types";
|
||||||
import { slugSchema } from "@app/lib/schemas";
|
import { slugSchema } from "@app/lib/schemas";
|
||||||
|
|
||||||
|
import { MetadataForm } from "../MetadataForm";
|
||||||
|
|
||||||
const formSchema = z.object({
|
const formSchema = z.object({
|
||||||
inputs: z.discriminatedUnion("method", [
|
inputs: z.discriminatedUnion("method", [
|
||||||
z.object({
|
z.object({
|
||||||
@@ -56,6 +58,9 @@ const formSchema = z.object({
|
|||||||
})
|
})
|
||||||
.nullable(),
|
.nullable(),
|
||||||
newName: slugSchema().optional(),
|
newName: slugSchema().optional(),
|
||||||
|
tags: z
|
||||||
|
.array(z.object({ key: z.string().trim().min(1), value: z.string().trim().min(1) }))
|
||||||
|
.optional(),
|
||||||
usernameTemplate: z.string().trim().nullable().optional()
|
usernameTemplate: z.string().trim().nullable().optional()
|
||||||
});
|
});
|
||||||
type TForm = z.infer<typeof formSchema>;
|
type TForm = z.infer<typeof formSchema>;
|
||||||
@@ -89,7 +94,8 @@ export const EditDynamicSecretAwsIamForm = ({
|
|||||||
usernameTemplate: dynamicSecret?.usernameTemplate || "{{randomUsername}}",
|
usernameTemplate: dynamicSecret?.usernameTemplate || "{{randomUsername}}",
|
||||||
inputs: {
|
inputs: {
|
||||||
...(dynamicSecret.inputs as TForm["inputs"])
|
...(dynamicSecret.inputs as TForm["inputs"])
|
||||||
}
|
},
|
||||||
|
tags: dynamicSecret.tags
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
const isAccessKeyMethod = watch("inputs.method") === DynamicSecretAwsIamAuth.AccessKey;
|
const isAccessKeyMethod = watch("inputs.method") === DynamicSecretAwsIamAuth.AccessKey;
|
||||||
@@ -101,7 +107,8 @@ export const EditDynamicSecretAwsIamForm = ({
|
|||||||
maxTTL,
|
maxTTL,
|
||||||
defaultTTL,
|
defaultTTL,
|
||||||
newName,
|
newName,
|
||||||
usernameTemplate
|
usernameTemplate,
|
||||||
|
tags
|
||||||
}: TForm) => {
|
}: TForm) => {
|
||||||
// wait till previous request is finished
|
// wait till previous request is finished
|
||||||
if (updateDynamicSecret.isPending) return;
|
if (updateDynamicSecret.isPending) return;
|
||||||
@@ -117,7 +124,9 @@ export const EditDynamicSecretAwsIamForm = ({
|
|||||||
defaultTTL,
|
defaultTTL,
|
||||||
inputs,
|
inputs,
|
||||||
newName: newName === dynamicSecret.name ? undefined : newName,
|
newName: newName === dynamicSecret.name ? undefined : newName,
|
||||||
usernameTemplate: !usernameTemplate || isDefaultUsernameTemplate ? null : usernameTemplate
|
usernameTemplate:
|
||||||
|
!usernameTemplate || isDefaultUsernameTemplate ? null : usernameTemplate,
|
||||||
|
tags
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
onClose();
|
onClose();
|
||||||
@@ -380,6 +389,7 @@ export const EditDynamicSecretAwsIamForm = ({
|
|||||||
</FormControl>
|
</FormControl>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
<MetadataForm control={control} name="tags" isValueRequired />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="mt-4 flex items-center space-x-4">
|
<div className="mt-4 flex items-center space-x-4">
|
||||||
|
|||||||
+18
-6
@@ -4,14 +4,22 @@ import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
|||||||
|
|
||||||
import { FormControl, FormLabel, IconButton, Input } from "@app/components/v2";
|
import { FormControl, FormLabel, IconButton, Input } from "@app/components/v2";
|
||||||
|
|
||||||
export const MetadataForm = ({ control }: { control: Control<any> }) => {
|
export const MetadataForm = ({
|
||||||
|
control,
|
||||||
|
name = "metadata",
|
||||||
|
isValueRequired = false
|
||||||
|
}: {
|
||||||
|
control: Control<any>;
|
||||||
|
name?: string;
|
||||||
|
isValueRequired?: boolean;
|
||||||
|
}) => {
|
||||||
const metadataFormFields = useFieldArray({
|
const metadataFormFields = useFieldArray({
|
||||||
control,
|
control,
|
||||||
name: "metadata"
|
name
|
||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<FormControl label="Metadata">
|
<FormControl label={name.charAt(0).toUpperCase() + name.slice(1)}>
|
||||||
<div className="flex flex-col space-y-2">
|
<div className="flex flex-col space-y-2">
|
||||||
{metadataFormFields.fields.map(({ id: metadataFieldId }, i) => (
|
{metadataFormFields.fields.map(({ id: metadataFieldId }, i) => (
|
||||||
<div key={metadataFieldId} className="flex items-end space-x-2">
|
<div key={metadataFieldId} className="flex items-end space-x-2">
|
||||||
@@ -19,7 +27,7 @@ export const MetadataForm = ({ control }: { control: Control<any> }) => {
|
|||||||
{i === 0 && <span className="text-xs text-mineshaft-400">Key</span>}
|
{i === 0 && <span className="text-xs text-mineshaft-400">Key</span>}
|
||||||
<Controller
|
<Controller
|
||||||
control={control}
|
control={control}
|
||||||
name={`metadata.${i}.key`}
|
name={`${name}.${i}.key`}
|
||||||
render={({ field, fieldState: { error } }) => (
|
render={({ field, fieldState: { error } }) => (
|
||||||
<FormControl
|
<FormControl
|
||||||
isError={Boolean(error?.message)}
|
isError={Boolean(error?.message)}
|
||||||
@@ -33,11 +41,15 @@ export const MetadataForm = ({ control }: { control: Control<any> }) => {
|
|||||||
</div>
|
</div>
|
||||||
<div className="flex-grow">
|
<div className="flex-grow">
|
||||||
{i === 0 && (
|
{i === 0 && (
|
||||||
<FormLabel label="Value" className="text-xs text-mineshaft-400" isOptional />
|
<FormLabel
|
||||||
|
label="Value"
|
||||||
|
className="text-xs text-mineshaft-400"
|
||||||
|
isOptional={!isValueRequired}
|
||||||
|
/>
|
||||||
)}
|
)}
|
||||||
<Controller
|
<Controller
|
||||||
control={control}
|
control={control}
|
||||||
name={`metadata.${i}.value`}
|
name={`${name}.${i}.value`}
|
||||||
render={({ field, fieldState: { error } }) => (
|
render={({ field, fieldState: { error } }) => (
|
||||||
<FormControl
|
<FormControl
|
||||||
isError={Boolean(error?.message)}
|
isError={Boolean(error?.message)}
|
||||||
|
|||||||
Reference in New Issue
Block a user