Skip to content
Open
Show file tree
Hide file tree
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
12 changes: 4 additions & 8 deletions components/landing/footer.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,10 @@
import { Logo } from "@/components/landing/logo";
import { SocialButtons } from "@/components/landing/social-buttons";
import { getDappUrl, siteConfig } from "@/lib/site";
import { footerLandingLinks } from "@/lib/landing-nav";

const FOOTER_LINKS = {
links: [
{ label: "Problem", href: "#problem" },
{ label: "Solution", href: "#solution" },
{ label: "FAQ", href: "#faq" },
{ label: "Contact", href: siteConfig.issues },
],
links: footerLandingLinks,
resources: [
{ label: "GitHub", href: siteConfig.github, external: true },
{ label: "API", href: siteConfig.backendRepo, external: true },
Expand Down Expand Up @@ -36,7 +32,7 @@ export function Footer() {
</p>
<ul className="space-y-2">
{FOOTER_LINKS.links.map(({ label, href }) => (
<li key={label}>
<li key={href}>
<a
href={href}
className="text-xs text-white/50 hover:text-white transition-colors tracking-wide"
Expand Down Expand Up @@ -100,4 +96,4 @@ export function Footer() {
</div>
</footer>
);
}
}
16 changes: 5 additions & 11 deletions components/landing/landing-nav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@ import { Button } from "@/components/ui/button";
import { Logo } from "@/components/landing/logo";
import { cn } from "@/lib/utils";
import { getDappUrl } from "@/lib/site";

const NAV_LINKS = [
{ href: "#problem", label: "Problem" },
{ href: "#solution", label: "Solution" },
{ href: "#score", label: "Score" },
{ href: "#faq", label: "FAQ" },
];
import { headerLandingLinks } from "@/lib/landing-nav";

export function LandingNav() {
const [open, setOpen] = useState(false);
Expand Down Expand Up @@ -45,8 +39,8 @@ export function LandingNav() {
<div className="max-w-6xl mx-auto px-4 sm:px-6 h-16 flex items-center justify-between">
<Logo size="sm" href="/" onClick={closeMenu} className="group" />

<div className="hidden md:flex items-center gap-8 text-xs text-white/40 uppercase tracking-zk">
{NAV_LINKS.map(({ href, label }) => (
<div className="hidden md:flex items-center gap-5 text-xs text-white/40 uppercase tracking-zk">
{headerLandingLinks.map(({ href, label }) => (
<a
key={href}
href={href}
Expand Down Expand Up @@ -89,7 +83,7 @@ export function LandingNav() {
)}
>
<div className="px-4 py-4 space-y-1">
{NAV_LINKS.map(({ href, label }) => (
{headerLandingLinks.map(({ href, label }) => (
<a
key={href}
href={href}
Expand All @@ -116,4 +110,4 @@ export function LandingNav() {
</div>
</nav>
);
}
}
26 changes: 26 additions & 0 deletions lib/landing-nav.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
export type LandingNavLink = {
href: string;
label: string;
header?: boolean;
footer?: boolean;
};

export const landingNavLinks = [
{ href: "#problem", label: "Problem", header: true, footer: true },
{ href: "#solution", label: "Solution", header: true, footer: true },
{ href: "#how-it-works", label: "Process", header: true, footer: true },
{ href: "#partners", label: "Partners", header: true, footer: true },
{ href: "#score", label: "Score", header: true, footer: true },
{ href: "#tiers", label: "Tiers", footer: true },
{ href: "#faq", label: "FAQ", header: true, footer: true },
{ href: "#community", label: "Community", footer: true },
{ href: "#launch", label: "Launch", footer: true },
] as const satisfies readonly LandingNavLink[];

export const headerLandingLinks = landingNavLinks.filter(
(link) => link.header
);

export const footerLandingLinks = landingNavLinks.filter(
(link) => link.footer
);