Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
143 changes: 73 additions & 70 deletions src/pages/Home/components/HomeConnect/HomeConnect.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,80 +22,83 @@ const styles = {
howToConnectContentCards: 'how-to-connect-content-cards grid grid-cols-1 items-stretch justify-center lg:grid-cols-3 gap-2 lg:gap-6'
} satisfies Record<string, string>;

const walletAddress = getNetworkConfig().network.walletAddress;
const detectedBrowser = getDetectedBrowser();
const isFirefox = detectedBrowser === BrowserEnum.Firefox;
export const HomeConnect = () => {
const walletAddress = getNetworkConfig().network.walletAddress;

const connectCards = [
{
icon: MetamaskIcon,
title: 'Metamask Snap',
description:
'Explore the entire MultiversX ecosystem with Metamask! Securely manage, swap and transfer your assets.',
linkTitle: 'Get Metamask',
linkDownloadAddress: isFirefox
? FIREFOX_METAMASK_ADDON_LINK
: CHROME_METAMASK_EXTENSION_LINK
},
// {
// icon: PasskeyIcon,
// title: 'Passkey',
// description:
// 'Passkeys offer a more secure and user-friendly way to authenticate and sign transactions.',
// linkTitle: 'Get Passkey',
// linkDownloadAddress: walletAddress
// },
{
icon: XPortalIcon,
title: 'xPortal Wallet',
description:
'The easiest way to invest, spend globally with a crypto card and earn yield across DeFi and stablecoins.',
linkTitle: 'Get xPortal',
linkDownloadAddress: GET_XPORTAL
},
{
icon: LedgerIcon,
title: 'Ledger',
description:
'You can safely store your EGLD by installing the MultiversX EGLD app on your Ledger Nano S or Ledger Nano X device',
linkTitle: 'Get Started',
linkDownloadAddress: GET_LEDGER
},
{
icon: WebWalletIcon,
title: 'MultiversX Web Wallet',
description:
'Store, swap, and transfer tokens or NFTs. Connect to Web3 apps on MultiversX blockchain.',
linkTitle: 'Get MultiversX Wallet',
linkDownloadAddress: walletAddress
}
];
const detectedBrowser = getDetectedBrowser();
const isFirefox = detectedBrowser === BrowserEnum.Firefox;

export const HomeConnect = () => (
<div className={styles.howToConnectContainer}>
<div className={styles.howToConnectHeader}>
<h1 className={styles.howToConnectTitle}>How can you connect</h1>
const connectCards = [
{
icon: MetamaskIcon,
title: 'Metamask Snap',
description:
'Explore the entire MultiversX ecosystem with Metamask! Securely manage, swap and transfer your assets.',
linkTitle: 'Get Metamask',
linkDownloadAddress: isFirefox
? FIREFOX_METAMASK_ADDON_LINK
: CHROME_METAMASK_EXTENSION_LINK
},
// {
// icon: PasskeyIcon,
// title: 'Passkey',
// description:
// 'Passkeys offer a more secure and user-friendly way to authenticate and sign transactions.',
// linkTitle: 'Get Passkey',
// linkDownloadAddress: walletAddress
// },
{
icon: XPortalIcon,
title: 'xPortal Wallet',
description:
'The easiest way to invest, spend globally with a crypto card and earn yield across DeFi and stablecoins.',
linkTitle: 'Get xPortal',
linkDownloadAddress: GET_XPORTAL
},
{
icon: LedgerIcon,
title: 'Ledger',
description:
'You can safely store your EGLD by installing the MultiversX EGLD app on your Ledger Nano S or Ledger Nano X device',
linkTitle: 'Get Started',
linkDownloadAddress: GET_LEDGER
},
{
icon: WebWalletIcon,
title: 'MultiversX Web Wallet',
description:
'Store, swap, and transfer tokens or NFTs. Connect to Web3 apps on MultiversX blockchain.',
linkTitle: 'Get MultiversX Wallet',
linkDownloadAddress: walletAddress
}
];

<p className={styles.howToConnectDescription}>
Choose your path, you must.
</p>
</div>
return (
<div className={styles.howToConnectContainer}>
<div className={styles.howToConnectHeader}>
<h1 className={styles.howToConnectTitle}>How can you connect</h1>

<p className={styles.howToConnectDescription}>
Choose your path, you must.
</p>
</div>

<div className={styles.howToConnectContent}>
<ExtensionConnect />
<div className={styles.howToConnectContent}>
<ExtensionConnect />

<div className={styles.howToConnectContentCards}>
{connectCards.map((card, index) => (
<ConnectCard
key={index}
icon={card.icon}
title={card.title}
description={card.description}
linkTitle={card.linkTitle}
linkDownloadAddress={card.linkDownloadAddress}
/>
))}
<div className={styles.howToConnectContentCards}>
{connectCards.map((card, index) => (
<ConnectCard
key={index}
icon={card.icon}
title={card.title}
description={card.description}
linkTitle={card.linkTitle}
linkDownloadAddress={card.linkDownloadAddress}
/>
))}
</div>
</div>
</div>
</div>
);
);
};
Loading