add delete user label for modal

This commit is contained in:
Francis Cao 2023-04-13 17:20:42 -07:00
parent 887b3abb29
commit aa418e0bed
3 changed files with 6 additions and 2 deletions

View File

@ -10,6 +10,7 @@ export const labels = defineMessages({
leave: { id: 'label.leave', defaultMessage: 'Leave' },
users: { id: 'label.users', defaultMessage: 'Users' },
createUser: { id: 'label.create-user', defaultMessage: 'Create user' },
deleteUser: { id: 'label.delete-users', defaultMessage: 'Delete user' },
username: { id: 'label.username', defaultMessage: 'Username' },
password: { id: 'label.password', defaultMessage: 'Password' },
role: { id: 'label.role', defaultMessage: 'Role' },

View File

@ -52,7 +52,7 @@ export default function UsersTable({ data = [], onDelete }) {
</Icon>
<Text>{formatMessage(labels.delete)}</Text>
</Button>
<Modal>
<Modal title={formatMessage(labels.deleteUser)}>
{close => (
<UserDeleteForm
userId={row.id}

View File

@ -29,7 +29,10 @@ export default function WebsiteDeleteForm({ websiteId, onSave, onClose }) {
return (
<Form onSubmit={handleSubmit} error={error}>
<p>
<FormattedMessage {...messages.deleteWebsite} values={{ confirmation: CONFIRM_VALUE }} />
<FormattedMessage
{...messages.deleteWebsite}
values={{ confirmation: <b>{CONFIRM_VALUE}</b> }}
/>
</p>
<FormRow label={formatMessage(labels.confirm)}>
<FormInput name="confirmation" rules={{ validate: value => value === CONFIRM_VALUE }}>