forked from FlowwStar/FlowStar
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhero.tsx
More file actions
138 lines (130 loc) · 4.67 KB
/
Copy pathhero.tsx
File metadata and controls
138 lines (130 loc) · 4.67 KB
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
'use client'
import { useState } from 'react'
import Link from 'next/link'
import { ArrowRight, Menu, X } from 'lucide-react'
import { Brand } from '@/components/brand'
import { Button } from '@/components/ui/button'
import {
DropdownMenu,
DropdownMenuContent,
DropdownMenuItem,
DropdownMenuTrigger,
} from '@/components/ui/dropdown-menu'
import { LiveStreamPreview } from '@/components/landing/live-stream-preview'
const NAV_LINKS = [
{ href: '#features', label: 'Features' },
{ href: '#how', label: 'How it works' },
{ href: '#use-cases', label: 'Use cases' },
]
export function LandingHeader() {
const [mobileNavOpen, setMobileNavOpen] = useState(false)
return (
<header className="absolute inset-x-0 top-0 z-30">
<div className="mx-auto flex h-16 max-w-6xl items-center gap-3 px-4 sm:px-6">
<Brand />
<nav className="hidden items-center gap-8 text-sm text-muted-foreground md:flex">
{NAV_LINKS.map((link) => (
<a
key={link.href}
href={link.href}
className="transition-colors hover:text-foreground"
>
{link.label}
</a>
))}
</nav>
<div className="ml-auto flex items-center gap-2">
<DropdownMenu open={mobileNavOpen} onOpenChange={setMobileNavOpen}>
<DropdownMenuTrigger asChild>
<Button
variant="ghost"
size="icon"
className="md:hidden"
aria-label="Open navigation menu"
>
{mobileNavOpen ? (
<X className="size-5" />
) : (
<Menu className="size-5" />
)}
</Button>
</DropdownMenuTrigger>
<DropdownMenuContent
align="end"
sideOffset={12}
className="min-w-56 rounded-xl border border-border bg-background/95 p-2 shadow-xl backdrop-blur-md"
>
<div className="mb-1 px-2 py-1 text-xs font-medium uppercase tracking-wide text-muted-foreground">
Navigate
</div>
{NAV_LINKS.map((link) => (
<DropdownMenuItem
key={link.href}
render={
<a
href={link.href}
onClick={() => setMobileNavOpen(false)}
className="w-full"
>
{link.label}
</a>
}
/>
))}
</DropdownMenuContent>
</DropdownMenu>
<Button asChild size="sm">
<Link href="/app">
Open app
<ArrowRight className="size-4" />
</Link>
</Button>
</div>
</div>
</header>
)
}
export function Hero() {
return (
<section className="relative overflow-hidden pt-28 pb-16 sm:pt-36 sm:pb-24">
{/* subtle radial accent */}
<div
aria-hidden
className="pointer-events-none absolute -top-40 left-1/2 size-[640px] -translate-x-1/2 rounded-full bg-primary/10 blur-3xl"
/>
<div className="relative mx-auto grid max-w-6xl items-center gap-12 px-4 sm:px-6 lg:grid-cols-2">
<div>
<span className="inline-flex items-center gap-2 rounded-full border border-border bg-card px-3 py-1 text-xs text-muted-foreground">
<span className="size-1.5 rounded-full bg-primary" />
Built on Stellar & Soroban
</span>
<h1 className="mt-5 text-balance text-4xl font-semibold leading-[1.05] tracking-tight sm:text-6xl">
Stream money by the second
</h1>
<p className="mt-5 max-w-md text-pretty text-lg leading-relaxed text-muted-foreground">
FlowStar turns one-time transfers into continuous streams. Perfect
for payroll, token vesting, and grants that unlock in real time —
withdraw anytime, cancel anytime.
</p>
<div className="mt-8 flex flex-wrap items-center gap-3">
<Button asChild size="lg">
<Link href="/app/create">
Create a stream
<ArrowRight className="size-4" />
</Link>
</Button>
<Button asChild size="lg" variant="secondary">
<Link href="/app">Open dashboard</Link>
</Button>
</div>
<p className="mt-6 font-mono text-xs text-muted-foreground">
No code · Non-custodial · Testnet ready
</p>
</div>
<div className="relative">
<LiveStreamPreview />
</div>
</div>
</section>
)
}