summaryrefslogtreecommitdiff
path: root/apps/web/src/components/ui/sponsor-button.tsx
blob: 146566a6cef8b1c09bf3dc59000cfaf2ad0526d0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import { motion } from "motion/react";
import { ComponentType } from "react";

interface SponsorButtonProps {
  href: string;
  logo: ComponentType<{ className?: string }>;
  companyName: string;
  className?: string;
}

export function SponsorButton({
  href,
  logo: Logo,
  companyName,
  className = "",
}: SponsorButtonProps) {
  return (
    <motion.a
      href={href}
      target="_blank"
      rel="noopener noreferrer"
      className={`inline-flex items-center gap-2 px-3 py-2 rounded-md border border-border bg-background/5 backdrop-blur-xs hover:bg-background/10 transition-all duration-200 group shadow-lg ${className}`}
    >
      <span className="text-xs font-medium text-muted-foreground group-hover:text-foreground transition-colors">
        Sponsored by
      </span>

      <div className="flex items-center gap-1.5">
        <div className="text-foreground/90 group-hover:text-foreground transition-colors">
          <Logo className="w-4 h-4" />
        </div>

        <span className="text-xs font-medium text-foreground/90 group-hover:text-foreground transition-colors">
          {companyName}
        </span>
      </div>
    </motion.a>
  );
}