Skip to content

Commit

Permalink
Complete home page
Browse files Browse the repository at this point in the history
  • Loading branch information
Szegoo committed Oct 2, 2024
1 parent b4ecc85 commit d6987ca
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 22 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"@polkadot/ui-keyring": "3.6.6",
"@polkadot/util": "12.6.2",
"@polkadot/util-crypto": "^12.6.2",
"@region-x/components": "^0.1.1",
"@region-x/components": "^0.1.4",
"@types/humanize-duration": "^3.27.3",
"@vercel/analytics": "^1.2.2",
"apexcharts": "^3.49.1",
Expand Down
2 changes: 1 addition & 1 deletion src/assets/chart.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/assets/config.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/assets/manage.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed src/assets/split.png
Binary file not shown.
2 changes: 1 addition & 1 deletion src/assets/trade.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
28 changes: 11 additions & 17 deletions src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ import WhatshotIcon from '@mui/icons-material/Whatshot';
import {
Backdrop,
Box,
Button,
Card,
CircularProgress,
Paper,
Stack,
Typography,
useTheme,
} from '@mui/material';
import { Button } from '@region-x/components';
import Image from 'next/image';
import { useRouter } from 'next/router';

Expand Down Expand Up @@ -249,27 +249,21 @@ const Home = () => {
))}
</Stack>
</Card>
<Stack direction='row' gap='1rem'>
<Stack
direction='row'
gap='1rem'
style={{ display: 'flex', justifyContent: 'space-between' }}
>
{buttons.map(({ label, image, url, dataCy }, index) => (
<Button
key={index}
sx={{
display: 'flex',
flexDirection: 'row',
alignItems: 'center',
gap: '0.5rem',
background: theme.palette.common.white,
color: theme.palette.common.black,
borderRadius: '0.75rem',
borderColor: theme.palette.grey[200],
py: '1.25rem',
flex: '1 0 0',
}}
variant='outlined'
onClick={() => push({ pathname: url, query })}
fullWidth
data-cy={dataCy}
rightIcon={<Image src={image} alt={label} width={32} />}
onClick={() => {
push({ pathname: url, query });
}}
>
<Image src={image} width={32} height={32} alt='' />
{label}
</Button>
))}
Expand Down

0 comments on commit d6987ca

Please sign in to comment.