From ee1947ac4dca32c2d4f37fa092d8dc44a09963b8 Mon Sep 17 00:00:00 2001 From: Gao Sun Date: Thu, 29 Aug 2024 16:08:00 +0800 Subject: [PATCH] refactor(console): support entering name while creating a user (#6523) --- .changeset/dry-candles-design.md | 5 +++++ .../src/pages/Users/components/CreateForm/index.tsx | 11 +++++++++++ 2 files changed, 16 insertions(+) create mode 100644 .changeset/dry-candles-design.md diff --git a/.changeset/dry-candles-design.md b/.changeset/dry-candles-design.md new file mode 100644 index 000000000..3ab1c907c --- /dev/null +++ b/.changeset/dry-candles-design.md @@ -0,0 +1,5 @@ +--- +"@logto/console": patch +--- + +support entering name while creating a user diff --git a/packages/console/src/pages/Users/components/CreateForm/index.tsx b/packages/console/src/pages/Users/components/CreateForm/index.tsx index 75218f8c2..ee0f4f3c8 100644 --- a/packages/console/src/pages/Users/components/CreateForm/index.tsx +++ b/packages/console/src/pages/Users/components/CreateForm/index.tsx @@ -191,6 +191,17 @@ function CreateForm({ onClose, onCreate }: Props) { error={errors.username?.message ?? Boolean(missingIdentifierError)} /> + + { + revalidateForm(); + }, + })} + placeholder={t('users.placeholder_name')} + error={errors.name?.message ?? Boolean(missingIdentifierError)} + /> + {missingIdentifierError &&
{missingIdentifierError}
}