mirror of
https://github.com/IRBorisov/ConceptPortal.git
synced 2025-06-26 13:00:39 +03:00
Fix build
This commit is contained in:
parent
cffcfc88b8
commit
01fe367845
|
@ -16,8 +16,6 @@ export function ChangePassword() {
|
|||
const [password_equal, setPasswordEqual] = useState(true);
|
||||
const navigate = useNavigate();
|
||||
|
||||
const input_class: string = `flex-grow max-w-xl px-3 py-2 border center min-w-full ${password_equal ? "" : "text-red-500"}`
|
||||
|
||||
function handleSubmit(event: React.FormEvent<HTMLFormElement>) {
|
||||
event.preventDefault();
|
||||
if (new_password !== new_password_repeat) {
|
||||
|
@ -40,19 +38,25 @@ export function ChangePassword() {
|
|||
type='password'
|
||||
label='Введите старый пароль:'
|
||||
value={old_password}
|
||||
onChange={event => (setOldPassword(event.target.value))}
|
||||
onChange={event => setOldPassword(event.target.value)}
|
||||
/>
|
||||
<TextInput id='new_password'
|
||||
//className={input_class}
|
||||
colorClass={`${password_equal ? "" : "text-red-500"}`}
|
||||
label="Введите новый пароль:"
|
||||
value={new_password}
|
||||
onChange={event => (setNewPassword(event.target.value), setPasswordEqual(true))}
|
||||
onChange={event => {
|
||||
setNewPassword(event.target.value);
|
||||
setPasswordEqual(true);
|
||||
}}
|
||||
/>
|
||||
<TextInput id='new_password'
|
||||
//className={input_class}
|
||||
colorClass={`${password_equal ? "" : "text-red-500"}`}
|
||||
label="Повторите новый пароль:"
|
||||
value={new_password_repeat}
|
||||
onChange={event => (setNewPasswordRepeat(event.target.value), setPasswordEqual(true))}
|
||||
onChange={event => {
|
||||
setNewPasswordRepeat(event.target.value);
|
||||
setPasswordEqual(true);
|
||||
}}
|
||||
/>
|
||||
<div className='relative flex justify-center my-4 border'>
|
||||
<button
|
||||
|
|
|
@ -8,7 +8,7 @@ import { ChangePassword } from './ChangePassword';
|
|||
|
||||
|
||||
export function UserProfile() {
|
||||
const { updateUser, user, processing, error } = useUserProfile();
|
||||
const { updateUser, user, processing } = useUserProfile();
|
||||
|
||||
const [username, setUsername] = useState('');
|
||||
const [email, setEmail] = useState('');
|
||||
|
|
Loading…
Reference in New Issue
Block a user