mirror of
https://github.com/umami-software/umami.git
synced 2026-02-09 07:07:17 +01:00
More refactoring, cleaned up icons, nav buttons, add messages.
This commit is contained in:
parent
4b1013c8c6
commit
5f15ad0807
68 changed files with 391 additions and 790 deletions
|
|
@ -1,7 +1,7 @@
|
|||
import { useMutation } from '@tanstack/react-query';
|
||||
import useApi from 'hooks/useApi';
|
||||
import { Button, Form, FormButtons, SubmitButton } from 'react-basics';
|
||||
import { useIntl } from 'react-intl';
|
||||
import { useIntl, FormattedMessage } from 'react-intl';
|
||||
import { labels, messages } from 'components/messages';
|
||||
|
||||
export default function UserDeleteForm({ userId, username, onSave, onClose }) {
|
||||
|
|
@ -20,9 +20,14 @@ export default function UserDeleteForm({ userId, username, onSave, onClose }) {
|
|||
|
||||
return (
|
||||
<Form onSubmit={handleSubmit} error={error}>
|
||||
<p>{formatMessage(messages.deleteUserWarning, { username })}</p>
|
||||
<p>
|
||||
<FormattedMessage
|
||||
{...messages.deleteUserWarning}
|
||||
values={{ username: <b>{username}</b> }}
|
||||
/>
|
||||
</p>
|
||||
<FormButtons flex>
|
||||
<SubmitButton variant="primary" disabled={isLoading}>
|
||||
<SubmitButton variant="danger" disabled={isLoading}>
|
||||
{formatMessage(labels.delete)}
|
||||
</SubmitButton>
|
||||
<Button disabled={isLoading} onClick={onClose}>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue