-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #485 from zer0-os/develop
Release 0.14.0
- Loading branch information
Showing
99 changed files
with
63,091 additions
and
31,506 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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,45 @@ | ||
.Container { | ||
cursor: pointer; | ||
min-width: 280px; | ||
border-radius: var(--box-radius); | ||
overflow: hidden; | ||
background-color: var(--color-background-alt); | ||
|
||
@media only screen and (max-width: 414px) { | ||
min-width: unset; | ||
} | ||
|
||
.Header { | ||
margin-bottom: 1px; | ||
color: white; | ||
font-size: 18px; | ||
font-weight: 700; | ||
} | ||
|
||
.Subheader { | ||
color: #bfbfbf; | ||
} | ||
|
||
.Body { | ||
position: relative; | ||
padding-top: 100%; | ||
} | ||
|
||
.Image { | ||
position: absolute; | ||
top: 0; | ||
left: 0; | ||
bottom: 0; | ||
right: 0; | ||
border-radius: var(--box-radius) var(--box-radius) 0 0; | ||
|
||
img, | ||
video { | ||
width: 100%; | ||
} | ||
} | ||
|
||
.Footer { | ||
padding: 16px; | ||
} | ||
} |
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,54 @@ | ||
import styles from './ImageCard.module.scss'; | ||
import { Image, NFTMedia } from 'components'; | ||
import classNames from 'classnames/bind'; | ||
|
||
const cx = classNames.bind(styles); | ||
|
||
type ImageCardProps = { | ||
children: React.ReactNode; | ||
imageUri?: string; | ||
header?: string; | ||
onClick?: () => void; | ||
subHeader?: string; | ||
className?: string; | ||
shouldUseCloudinary?: boolean; | ||
}; | ||
|
||
const ImageCard = ({ | ||
children, | ||
header, | ||
imageUri, | ||
onClick, | ||
subHeader, | ||
className, | ||
shouldUseCloudinary, | ||
}: ImageCardProps) => { | ||
return ( | ||
<div className={cx(styles.Container, className)} onClick={onClick}> | ||
<div className={styles.Body}> | ||
<div className={styles.Image}> | ||
{shouldUseCloudinary ? ( | ||
<NFTMedia | ||
disableLightbox | ||
style={{ | ||
zIndex: 2, | ||
}} | ||
size="medium" | ||
alt="NFT Preview" | ||
ipfsUrl={imageUri ?? ''} | ||
/> | ||
) : ( | ||
<Image src={imageUri} /> | ||
)} | ||
</div> | ||
</div> | ||
<div className={styles.Footer}> | ||
<h5 className={styles.Header}>{header ?? ''}</h5> | ||
<span className={styles.Subheader}>{subHeader ?? ''}</span> | ||
{children} | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default ImageCard; |
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
Oops, something went wrong.