feat: render validator requests by validator count
This commit is contained in:
parent
9c7e65a210
commit
314c4238ab
|
@ -16,11 +16,6 @@ const Deposit = () => {
|
||||||
const [isInfoBoxVisible, setIsInfoBoxVisible] = useState(true)
|
const [isInfoBoxVisible, setIsInfoBoxVisible] = useState(true)
|
||||||
const [validatorCount, setValidatorCount] = useState(0)
|
const [validatorCount, setValidatorCount] = useState(0)
|
||||||
const { isWalletConnected } = useSelector((state: RootState) => state.deposit)
|
const { isWalletConnected } = useSelector((state: RootState) => state.deposit)
|
||||||
|
|
||||||
const validatorRequests = [
|
|
||||||
{ name: '1', address: 'zQ3asdf9d4Gs0' },
|
|
||||||
{ name: '2', address: 'zQ3asdf9d4Gs0' },
|
|
||||||
]
|
|
||||||
const isTransactionConfirmation = false
|
const isTransactionConfirmation = false
|
||||||
|
|
||||||
const addValidatorHandler = () => {
|
const addValidatorHandler = () => {
|
||||||
|
@ -54,8 +49,8 @@ const Deposit = () => {
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
<DividerLine />
|
<DividerLine />
|
||||||
{validatorRequests.map((validator, index) => (
|
{Array.from({ length: validatorCount }).map((_, index) => (
|
||||||
<ValidatorRequest validator={validator} key={index} />
|
<ValidatorRequest key={index} number={index + 1} />
|
||||||
))}
|
))}
|
||||||
{isInfoBoxVisible && (
|
{isInfoBoxVisible && (
|
||||||
<InformationBox
|
<InformationBox
|
||||||
|
|
Loading…
Reference in New Issue