-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: declare content in wallet.json
- Loading branch information
1 parent
6db7d08
commit 9866499
Showing
6 changed files
with
101 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import { Container, Grid } from '@mui/material' | ||
import type { BaseBlock } from '@/components/Home/types' | ||
import layoutCss from '@/components/common/styles.module.css' | ||
import getComponentByName from '@/lib/getComponentByName' | ||
|
||
const BigCardsGrid = ({ items }: { items: Array<BaseBlock['items'] & { component: string }> }) => ( | ||
<Container className={layoutCss.containerShort}> | ||
<Grid container spacing={{ xs: '30px', xl: '50px' }}> | ||
{items?.map((item, index) => { | ||
const { component } = item | ||
|
||
const CardComponent = getComponentByName(`${component}`, () => <></>) | ||
|
||
return ( | ||
<Grid key={index} item xs={12} md={6}> | ||
<CardComponent {...item} /> | ||
</Grid> | ||
) | ||
})} | ||
</Grid> | ||
</Container> | ||
) | ||
|
||
export default BigCardsGrid |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import { Typography } from '@mui/material' | ||
import type { BaseBlock } from '@/components/Home/types' | ||
import css from './styles.module.css' | ||
|
||
const BigImageCard = ({ caption, title, text, image }: BaseBlock) => ( | ||
<div className={css.card}> | ||
<Typography variant="caption">{caption}</Typography> | ||
|
||
<img {...image} className={css.image} /> | ||
|
||
<Typography variant="h4" className={css.title}> | ||
{title} | ||
</Typography> | ||
|
||
{text ? <Typography color="primary.light">{text}</Typography> : null} | ||
</div> | ||
) | ||
|
||
export default BigImageCard |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
.card { | ||
outline: 1px solid var(--mui-palette-border-light); | ||
border-radius: 16px; | ||
padding: 16px; | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
justify-content: flex-start; | ||
text-align: center; | ||
height: 100%; | ||
} | ||
|
||
.image { | ||
width: 240px; | ||
} | ||
|
||
.title { | ||
width: 80%; | ||
margin-bottom: 24px; | ||
} | ||
|
||
@media (min-width: 600px) { | ||
.card { | ||
padding: 32px; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import type { NextPage } from 'next' | ||
import { Wallet } from '@/components/Wallet' | ||
|
||
const WalletPage: NextPage = () => <Wallet /> | ||
|
||
export default WalletPage |