added cancel to login
Some checks failed
CI/CD Pipeline / deploy (push) Failing after 28s
CI/CD Pipeline / promote_stable (push) Has been skipped

This commit is contained in:
2026-02-23 12:11:44 +01:00
parent 50e3ff6ded
commit 496b50ed12
4 changed files with 26 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
import { useState } from 'react'
import { Button, Card, Container, Form } from 'react-bootstrap'
import { useNavigate } from 'react-router-dom'
import { Link, useNavigate } from 'react-router-dom'
import { useAuth } from '../context/AuthContext'
import { useTranslation } from 'react-i18next'
@@ -53,10 +53,18 @@ export default function Login() {
onChange={(event) => setPassword(event.target.value)}
required
/>
<div className="mt-2 text-end">
<Link to="/reset-password">{t('auth.forgot_password')}</Link>
</div>
</Form.Group>
<Button type="submit" variant="dark" disabled={loading}>
{loading ? t('form.signing_in') : t('form.sign_in')}
</Button>
<div className="d-flex gap-2">
<Button as={Link} to="/" type="button" variant="outline-secondary" disabled={loading}>
{t('acp.cancel')}
</Button>
<Button type="submit" variant="dark" disabled={loading}>
{loading ? t('form.signing_in') : t('form.sign_in')}
</Button>
</div>
</Form>
</Card.Body>
</Card>