From 7811024330a297b5aacf2c2770ab3c9be222b302 Mon Sep 17 00:00:00 2001 From: IsaccoSordo Date: Fri, 10 Jan 2025 16:16:33 +0100 Subject: [PATCH] fix: wallets rendering --- .../src/components/wallets/index.tsx | 54 +++++++++++-------- 1 file changed, 33 insertions(+), 21 deletions(-) diff --git a/packages/beacon-ui/src/components/wallets/index.tsx b/packages/beacon-ui/src/components/wallets/index.tsx index d1d517ce4..c51793582 100644 --- a/packages/beacon-ui/src/components/wallets/index.tsx +++ b/packages/beacon-ui/src/components/wallets/index.tsx @@ -13,28 +13,40 @@ interface WalletProps { } const Wallets: React.FC = (props: WalletProps) => { + const wallets = props.wallets.map((wallet) => ( + { + props.onClickWallet(wallet.id) + }} + /> + )) + const groupedElements = [] + + for (let i = 0; i < wallets.length; i += 4) { + groupedElements.push(wallets.slice(i, i + 4)) + } + return ( - - {props.wallets.map((wallet) => ( - { - props.onClickWallet(wallet.id) - }} - /> - ))} -