WRAPCODERS

Crypto Wallet Hero

Heroes 14

About

Non-custodial crypto wallet hero block with brushed titanium card, interactive mobile wallet preview, inline SVG contact portraits, and multi-chain network strip.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Crypto Wallet Hero to your project and fits it to your theme.

Code

How Crypto Wallet Hero is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import { useEffect, useState } from "react";
import CryptoWalletHero, {
  defaultTransferUsers,
} from "@/components/ui/crypto-wallet-hero";

const PROFILE_REFERRAL_URL = "https://21st.dev/@wrapcoders?ref=mdruhulhasan";

const settings = {
  brandName: "Nexora",
  headline: "Your Crypto. Your Keys. Your Freedom.",
  balance: "$2,430.00",
  cardHolder: "NEXORA PREMIER",
  cardNumberMasked: "•••• 8492",
  defaultCardTab: "my" as "my" | "physical",
  showMetrics: true,
};

export default function CryptoWalletHeroDemo(props: Partial<typeof settings>) {
  const s = { ...settings, ...props };
  const [cardTab, setCardTab] = useState<"my" | "physical">(s.defaultCardTab);
  const [actionId, setActionId] = useState<string>("send");
  const [activeNav, setActiveNav] = useState<string>(
    s.defaultCardTab === "physical" ? "Crypto Cards" : "Services"
  );

  useEffect(() => {
    setCardTab(s.defaultCardTab);
    setActiveNav(s.defaultCardTab === "physical" ? "Crypto Cards" : "Services");
  }, [s.defaultCardTab]);

  useEffect(() => {
    if (typeof window === "undefined") return;
    const themeParam = new URLSearchParams(window.location.search).get("theme");
    if (themeParam === "dark") {
      document.documentElement.classList.add("dark");
    } else if (themeParam === "light") {
      document.documentElement.classList.remove("dark");
    }
  }, []);

  const handleCardTabChange = (nextTab: "my" | "physical") => {
    setCardTab(nextTab);
    setActiveNav(nextTab === "physical" ? "Crypto Cards" : "Services");
  };

  const handleActionClick = (nextActionId: string) => {
    setActionId(nextActionId);
    if (nextActionId === "more") {
      setActiveNav("Staking");
    } else if (nextActionId === "topup") {
      setActiveNav("Virtual IBAN");
    } else if (nextActionId === "send") {
      setActiveNav("Services");
    }
  };

  return (
    <div className="min-h-screen w-full bg-background text-foreground">
      <CryptoWalletHero
        referralUrl={PROFILE_REFERRAL_URL}
        defaultCardTab={s.defaultCardTab}
        cardTab={cardTab}
        onCardTabChange={handleCardTabChange}
        defaultActionId="send"
        actionId={actionId}
        onActionClick={handleActionClick}
        showMetrics={s.showMetrics}
        navigation={{
          brandName: s.brandName,
          logoHref: PROFILE_REFERRAL_URL,
          links: [
            {
              label: "Services",
              href: "#wallet-showcase",
              active: activeNav === "Services",
              onClick: () => {
                setActiveNav("Services");
                setCardTab("my");
                setActionId("send");
              },
            },
            {
              label: "Crypto Cards",
              href: "#wallet-showcase",
              active: activeNav === "Crypto Cards",
              onClick: () => {
                setActiveNav("Crypto Cards");
                setCardTab("physical");
              },
            },
            {
              label: "Virtual IBAN",
              href: "#wallet-showcase",
              active: activeNav === "Virtual IBAN",
              onClick: () => {
                setActiveNav("Virtual IBAN");
                setCardTab("my");
                setActionId("topup");
              },
            },
            {
              label: "Staking",
              href: "#wallet-showcase",
              active: activeNav === "Staking",
              onClick: () => {
                setActiveNav("Staking");
                setActionId("more");
              },
            },
            {
              label: "Blog",
              href: PROFILE_REFERRAL_URL,
            },
          ],
          actions: [
            {
              label: "Refer & Earn",
              variant: "ghost",
              href: PROFILE_REFERRAL_URL,
            },
            {
              label: "Open Free Account",
              variant: "primary",
              href: PROFILE_REFERRAL_URL,
            },
          ],
        }}
        headline={s.headline}
        subheadline="Buy, swap, stake, and spend across 40+ chains from one non-custodial wallet."
        primaryAction={{
          label: "Open Free Account",
          href: PROFILE_REFERRAL_URL,
        }}
        secondaryAction={{
          label:
            cardTab === "my" ? "Preview Titanium Card" : "Preview Virtual Card",
          href: "#wallet-showcase",
          onClick: () =>
            handleCardTabChange(cardTab === "my" ? "physical" : "my"),
        }}
        walletData={{
          cardType: "My Card",
          secondaryCardType: "Physical Card",
          balance: s.balance,
          balanceLabel: "Total balance",
          cardNumberMasked: s.cardNumberMasked,
          cardHolder: s.cardHolder,
          expiryDate: "09/29",
        }}
        quickActions={[
          { id: "send", label: "Send to", icon: "send" },
          { id: "request", label: "Request", icon: "request" },
          { id: "topup", label: "Top up", icon: "topup" },
          { id: "more", label: "More", icon: "more" },
        ]}
        transferUsers={defaultTransferUsers}
      />
    </div>
  );
}

Dependencies

More by WRAPCODERS

View all
  • Product Hover Showcase

    Product Hover Showcase

    121
  • Real Estate 3D Hero

    Real Estate 3D Hero

    89
  • Creator Community Arc

    Creator Community Arc

    69
  • LoopAI CRM

    LoopAI CRM

    68
  • Isometric Card Stack

    Isometric Card Stack

    55
  • Flash Technologies Crypto Wallet Hero

    Flash Technologies Crypto Wallet Hero

    54
  • Client Management CRM Hub

    Client Management CRM Hub

    48
  • Admin Dashboard Cards

    Admin Dashboard Cards

    44

More in Heroes

View all
  • Agency Hero Section

    Agency Hero Section

    1.1K
  • Responsive Hero Banner

    Responsive Hero Banner

    2.2K
  • SaaS Template

    SaaS Template

    2.8K
  • AI SaaS Workflow Hero

    AI SaaS Workflow Hero

    36
  • App Integration Celestial Hero

    App Integration Celestial Hero

    17
  • Chroma Sense Hero

    Chroma Sense Hero

    23
  • Hero

    Hero

    1.4K
  • Modren and Stunning Hero section

    Modren and Stunning Hero section

    200

Explore more

Part of Components — browse the full library on 21st.dev.