fix: minor fix

pull/89/head
Pierre-Louis Guhur 1 year ago
parent 4045b4bbe5
commit 4ebdd59493

@ -1,6 +1,6 @@
import { useTranslation } from 'next-i18next';
import Image from 'next/image';
import { Row, Col } from 'reactstrap';
import { Row, Col, Container } from 'reactstrap';
import ballotBox from '../public/urne.svg';
import email from '../public/email.svg';
import respect from '../public/respect.svg';
@ -28,6 +28,7 @@ const AdvantagesRow = () => {
},
];
return (
<Container>
<Row>
{resources.map((item, i) => (
<Col key={i} className="my-5 col-md-4 col-12">
@ -42,6 +43,7 @@ const AdvantagesRow = () => {
</Col>
))}
</Row>
</Container>
);
};

@ -12,11 +12,12 @@ const Experiencediv = () => {
<div className="pt-5">
<div
className="w-100 justify-content-end d-flex d-md-none"
style={{ marginTop: '-150px' }}
style={{ marginTop: '-200px' }}
>
<Image src={vote} alt={t('home.alt-icon-ballot')} />
</div>
<Container>
<h3 className="text-center">{t('home.experience-name')}</h3>
<div className="d-flex">
<Row className="px-5 my-5 flex-fill justify-content-end align-items-center gap-lg-5 d-flex">
@ -53,6 +54,7 @@ const Experiencediv = () => {
</Button>
</a>
</div>
</Container>
</div>
);
};

@ -1,4 +1,5 @@
import Image from 'next/image';
import Link from 'next/link';
import { useTranslation } from 'next-i18next';
import { getUrl, RouteTypes } from '@services/routes';
import logoWithText from '../public/logos/logo.svg';
@ -15,9 +16,9 @@ const Logo = ({ title = true, ...props }: LogoProps) => {
const router = useRouter();
const src = title ? logoWithText : logo;
return (
<a href={getUrl(RouteTypes.HOME, router).toString()}>
<Link href={getUrl(RouteTypes.HOME, router).toString()}>
<Image src={src} alt={t('logo.alt')} className="d-block" {...props} />
</a>
</Link>
);
};

@ -48,6 +48,7 @@ const CandidateModal = ({ isOpen, position, toggle }) => {
return;
}
if (names.includes(state.name)) {
alert('foo');
dispatchApp({
type: AppTypes.TOAST_ADD,
status: 'error',
@ -137,7 +138,7 @@ const CandidateModal = ({ isOpen, position, toggle }) => {
</div>
</div>
</div>
<div className="mb-3">
<div className="my-3">
<Label className="fw-bold">{t('common.name')} </Label>
<input
className="form-control"
@ -175,9 +176,12 @@ const CandidateModal = ({ isOpen, position, toggle }) => {
>
{t('common.cancel')}
</Button>
{
// Since we disabled the button, the onCLick is supported by another component
}
<div onClick={save}>
<Button
color={disabled ? 'light' : 'primary'}
onClick={save}
position="right"
disabled={disabled}
icon={faPlus}
@ -185,6 +189,7 @@ const CandidateModal = ({ isOpen, position, toggle }) => {
{t('common.save')}
</Button>
</div>
</div>
</Form>
</Col>
</ModalBody>

@ -12,6 +12,7 @@ function Application({ Component, pageProps }) {
typeof window !== 'undefined' && window.location.origin
? window.location.origin
: 'http://localhost';
return (
<>
<Head>

@ -157,7 +157,7 @@
"admin.confirm-question": "Question of your vote",
"admin.confirm-candidates": "Candidates",
"admin.confirm-submit": "Start the vote",
"admin.confirm-title": "Confirmer votre vote",
"admin.confirm-title": "Check your vote is correct",
"admin.confirm-edit": "Save your modifications",
"admin.success-election": "The vote has successfully been created!",
"admin.success-emails": "The voting link has been sent by emails to the participants.",

Loading…
Cancel
Save