replacing rematch with zustand (#180)

* replacing rematch with zustand

* upgrading dependencies

* next release version
This commit is contained in:
Christian Kellner
2025-09-18 20:09:11 +02:00
committed by GitHub
parent 28e885f6c7
commit 4f79c5cba2
21 changed files with 226 additions and 322 deletions

View File

@@ -4,14 +4,14 @@ import cityBackground from '../../assets/city_background.jpg';
import Logo from '../../components/logo/Logo';
import { xhrPost } from '../../services/xhr';
import { useNavigate } from 'react-router-dom';
import { useDispatch, useSelector } from 'react-redux';
import { useActions, useSelector } from '../../services/state/store';
import { Input, Button, Banner, Toast } from '@douyinfe/semi-ui';
import './login.less';
import { IconUser, IconLock } from '@douyinfe/semi-icons';
export default function Login() {
const dispatch = useDispatch();
const actions = useActions();
const [username, setUserName] = React.useState('');
const [password, setPassword] = React.useState('');
const [error, setError] = React.useState(null);
@@ -20,7 +20,7 @@ export default function Login() {
useEffect(() => {
async function init() {
await dispatch.demoMode.getDemoMode();
await actions.demoMode.getDemoMode();
}
init();
@@ -46,7 +46,7 @@ export default function Login() {
Toast.success('Login successful!');
await dispatch.user.getCurrentUser();
await actions.user.getCurrentUser();
navigate('/jobs');
};