-
Notifications
You must be signed in to change notification settings - Fork 145
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 #127 from BrunoAmbricca/feat/form-page-enhancements
Form Page Enhancements
- Loading branch information
Showing
7 changed files
with
183 additions
and
22 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import React, { useEffect, useState } from 'react'; | ||
import { ReactComponent as ETH } from '../assets/icons/ethereum.svg'; | ||
import { ReactComponent as USDC } from '../assets/icons/borrow_usdc.svg'; | ||
import { ReactComponent as STRK } from '../assets/icons/strk.svg'; | ||
import { ReactComponent as DAI } from '../assets/icons/dai.svg'; | ||
import { getBalances } from '../utils/wallet'; | ||
|
||
const BalanceCards = ({ walletId }) => { | ||
const [balances, setBalances] = useState([ | ||
{ icon: <ETH />, title: 'ETH', balance: '0.00' }, | ||
{ icon: <USDC />, title: 'USDC', balance: '0.00' }, | ||
{ icon: <STRK />, title: 'STRK', balance: '0.00' }, | ||
{ icon: <DAI />, title: 'DAI', balance: '0.00' }, | ||
]); | ||
|
||
useEffect(() => { | ||
getBalances(walletId, setBalances); | ||
}, [walletId]); | ||
|
||
|
||
return ( | ||
<div className="balance-container"> | ||
{balances.map((balance) => ( | ||
<div className={"balance-item"} key={balance.title}> | ||
<label htmlFor={balance.title} className={"balance-title"}> | ||
{balance.icon}{balance.title} Balance: | ||
</label> | ||
<label htmlFor={balance.title}> | ||
{balance.balance} | ||
</label> | ||
</div> | ||
))} | ||
</div> | ||
) | ||
}; | ||
|
||
export default BalanceCards; |
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,8 @@ | ||
const CardGradients = ({ additionalClassName }) => ( | ||
<div className={`card-gradients ${additionalClassName}`}> | ||
<div className="card-gradient"></div> | ||
<div className="card-gradient"></div> | ||
</div> | ||
); | ||
|
||
export default CardGradients; |
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,15 @@ | ||
import { ReactComponent as Star } from "../assets/particles/star.svg"; | ||
|
||
const StarMaker = ({ starData }) => ( | ||
starData.map((star, index) => ( | ||
<Star key={index} style={{ | ||
position: 'absolute', | ||
top: `${star.top}%`, | ||
left: `${star.left}%`, | ||
width: `${star.size}%`, | ||
height: `${star.size}%` | ||
}}/> | ||
)) | ||
); | ||
|
||
export default StarMaker; |
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