moved icon profile on up
This commit is contained in:
@@ -14,7 +14,7 @@ import {
|
||||
} from "./ProfileFormFields";
|
||||
|
||||
export default function ProfileModal({ onClose, initialData = {} }) {
|
||||
const { user, updateUser } = useAuthContext();
|
||||
const { user, updateUser, logout } = useAuthContext();
|
||||
const { updateProfile, loading: saving, error: saveError } = useUpdateProfile();
|
||||
const [form, setForm] = useState(initializeFormState(initialData));
|
||||
const [errors, setErrors] = useState({});
|
||||
@@ -105,6 +105,14 @@ export default function ProfileModal({ onClose, initialData = {} }) {
|
||||
{saveError && <p className="f-err-msg" style={{ marginBottom: 10 }}>{saveError}</p>}
|
||||
|
||||
<SubmitButton loading={compressing || saving} onSubmit={handleSubmit} />
|
||||
|
||||
<button
|
||||
type="button"
|
||||
className="f-modal-logout"
|
||||
onClick={() => { logout(); onClose(); }}
|
||||
>
|
||||
Выйти
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user