-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'development' of github.com:multiversx/mx-explorer-dapp …
…into battlenet-setup
- Loading branch information
Showing
54 changed files
with
1,072 additions
and
452 deletions.
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
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,47 @@ | ||
import BigNumber from 'bignumber.js'; | ||
import classNames from 'classnames'; | ||
import { WithClassnameType } from 'types'; | ||
|
||
interface ExpandRowUIType extends WithClassnameType { | ||
onClick: () => void; | ||
count?: number; | ||
text?: string; | ||
linkText?: string; | ||
colSpan?: number; | ||
} | ||
|
||
export const ExpandRow = ({ | ||
count, | ||
text, | ||
onClick, | ||
colSpan, | ||
linkText = 'View All', | ||
className | ||
}: ExpandRowUIType) => { | ||
return ( | ||
<tr className={classNames('expand-row', className)}> | ||
<td colSpan={colSpan}> | ||
<div className='content-wrapper text-neutral-400 d-flex align-items-start font-headings-regular gap-3'> | ||
<span> | ||
{count && text && ( | ||
<> | ||
.. {new BigNumber(count).toFormat()} {text} | ||
</> | ||
)} | ||
</span> | ||
<button | ||
type='button' | ||
className='btn btn-link-unstyled text-primary font-weight-600' | ||
onClick={onClick} | ||
> | ||
{linkText} | ||
</button> | ||
</div> | ||
<div className='trapezoid'></div> | ||
<div className='trapezoid reverse'></div> | ||
<div className='trapezoid'></div> | ||
<div className='trapezoid reverse'></div> | ||
</td> | ||
</tr> | ||
); | ||
}; |
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,38 @@ | ||
.expand-row { | ||
td { | ||
position: relative; | ||
padding: 0 !important; | ||
border-bottom-width: 0; | ||
} | ||
.trapezoid { | ||
background-color: var(--table-bg); | ||
transform: perspective(10rem) rotateX(-10deg); | ||
border-width: 1px; | ||
border-style: solid; | ||
border-color: var(--table-border-color); | ||
height: 1rem; | ||
margin-left: 5px; | ||
margin-right: 5px; | ||
border-top-width: 0; | ||
&.reverse { | ||
margin-top: -1px; | ||
transform: perspective(10rem) rotateX(10deg); | ||
} | ||
} | ||
.content-wrapper { | ||
position: absolute; | ||
z-index: 1; | ||
background-color: var(--neutral-950); | ||
padding: 0.25rem 1rem; | ||
top: 0; | ||
bottom: 0; | ||
left: 0; | ||
right: 0; | ||
width: fit-content; | ||
height: fit-content; | ||
margin: auto; | ||
button { | ||
line-height: 1.4; | ||
} | ||
} | ||
} |
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 @@ | ||
export * from './ExpandRow'; |
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
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
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.