all repos — caroster @ main

[Octree] Group carpool to your event https://caroster.io

frontend/containers/TravelColumns/AddTravel.tsx (view raw)

 1import React from 'react';
 2import Button from '@mui/material/Button';
 3import Container from '@mui/material/Container';
 4import {useTheme} from '@mui/material/styles';
 5import {useTranslation} from 'next-i18next';
 6
 7interface Props {
 8  toggle: () => void;
 9}
10
11const AddTravel = (props: Props) => {
12  const {toggle} = props;
13
14  const {t} = useTranslation();
15  const theme = useTheme();
16  return (
17    <Container
18      maxWidth="sm"
19      sx={{display: 'flex', justifyContent: 'center', padding: 0}}
20    >
21      <Button
22        sx={{
23          backgroundColor: theme.palette.background.paper,
24          color: theme.palette.text.primary,
25          '&:hover': {color: theme.palette.secondary.contrastText},
26        }}
27        fullWidth
28        variant="contained"
29        color="primary"
30        onClick={toggle}
31      >
32        {t('travel.creation.title')}
33      </Button>
34    </Container>
35  );
36};
37
38export default AddTravel;