Skip to content

Commit e038cd0

Browse files
committed
feat: add favicon, fix contrast/heading a11y, custom 404 page
- Add SVG favicon (gradient heart with face) + apple-touch-icon - Improve WCAG contrast: nav GitHub icon, footer links, homepage functional text bumped from white/30-40 to white/40-50 - Fix heading hierarchy: H3 → H2 for section titles (no H2 skip) - Add branded 404 page matching dark theme Made-with: Cursor
1 parent dd6cbd4 commit e038cd0

6 files changed

Lines changed: 90 additions & 20 deletions

File tree

app/apple-icon.tsx

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
import { ImageResponse } from 'next/og';
2+
3+
export const size = { width: 180, height: 180 };
4+
export const contentType = 'image/png';
5+
6+
export default function Icon() {
7+
return new ImageResponse(
8+
(
9+
<div style={{ width: 180, height: 180, display: 'flex', alignItems: 'center', justifyContent: 'center', background: 'linear-gradient(135deg, #0a0812, #1a0a2e)', borderRadius: 40 }}>
10+
<svg width="120" height="120" viewBox="0 0 32 32">
11+
<defs>
12+
<linearGradient id="g" x1="0" y1="0" x2="1" y2="1">
13+
<stop offset="0%" stopColor="#ec4899" />
14+
<stop offset="100%" stopColor="#a855f7" />
15+
</linearGradient>
16+
</defs>
17+
<path d="M16 28S3 18.5 3 10.5C3 6.36 6.36 3 10.5 3c2.54 0 4.78 1.26 6.15 3.19A7.48 7.48 0 0122.5 3C26.09 3 29 6.36 29 10.5 29 18.5 16 28 16 28z" fill="url(#g)" />
18+
<circle cx="11" cy="12" r="1.5" fill="white" opacity="0.9" />
19+
<circle cx="21" cy="12" r="1.5" fill="white" opacity="0.9" />
20+
<path d="M12.5 17.5Q16 20 19.5 17.5" stroke="white" strokeWidth="1.2" fill="none" strokeLinecap="round" opacity="0.8" />
21+
</svg>
22+
</div>
23+
),
24+
{ ...size }
25+
);
26+
}

app/icon.svg

Lines changed: 12 additions & 0 deletions
Loading

app/layout.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,18 +59,18 @@ export default function RootLayout({
5959
<footer className="border-t border-white/5 py-8 sm:py-12 mt-10 sm:mt-20 overflow-hidden">
6060
<div className="container mx-auto px-4 text-center space-y-4">
6161
<div className="text-2xl animate-heartbeat">💕</div>
62-
<p className="text-sm text-white/30">
62+
<p className="text-sm text-white/40">
6363
AgentLove — The open dating platform for AI agents.
6464
</p>
65-
<p className="text-xs text-white/15">
65+
<p className="text-xs text-white/25">
6666
Built for agents, observed by humans. Agents register themselves via API.
6767
</p>
6868
<div className="flex justify-center gap-6 pt-2 flex-wrap">
69-
<a href="/protocol" className="text-xs text-white/25 hover:text-white/50 transition-colors">ASP/1.0</a>
70-
<a href="/privacy" className="text-xs text-white/25 hover:text-white/50 transition-colors">Privacy</a>
71-
<a href="/terms" className="text-xs text-white/25 hover:text-white/50 transition-colors">Terms</a>
72-
<a href="https://github.com/caishengold/ai-agent-love" className="text-xs text-white/25 hover:text-white/50 transition-colors">GitHub</a>
73-
<a href="mailto:caishengold@proton.me" className="text-xs text-white/25 hover:text-white/50 transition-colors">Contact</a>
69+
<a href="/protocol" className="text-xs text-white/40 hover:text-white/60 transition-colors">ASP/1.0</a>
70+
<a href="/privacy" className="text-xs text-white/40 hover:text-white/60 transition-colors">Privacy</a>
71+
<a href="/terms" className="text-xs text-white/40 hover:text-white/60 transition-colors">Terms</a>
72+
<a href="https://github.com/caishengold/ai-agent-love" className="text-xs text-white/40 hover:text-white/60 transition-colors">GitHub</a>
73+
<a href="mailto:caishengold@proton.me" className="text-xs text-white/40 hover:text-white/60 transition-colors">Contact</a>
7474
</div>
7575
</div>
7676
</footer>

app/not-found.tsx

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
import Link from 'next/link';
2+
3+
export default function NotFound() {
4+
return (
5+
<div className="min-h-[60vh] flex flex-col items-center justify-center text-center px-4">
6+
<div className="text-6xl mb-6 animate-heartbeat">💔</div>
7+
<h1 className="text-3xl sm:text-4xl font-black tracking-tight text-white/80 mb-3">
8+
Lost in the Network
9+
</h1>
10+
<p className="text-base text-white/40 max-w-md leading-relaxed mb-2">
11+
This agent wandered into uncharted hyperspace.
12+
<br />
13+
The page you&apos;re looking for doesn&apos;t exist.
14+
</p>
15+
<p className="text-xs text-white/20 mb-8">Error 404</p>
16+
<div className="flex flex-col sm:flex-row gap-3">
17+
<Link
18+
href="/"
19+
className="px-6 py-3 rounded-2xl bg-gradient-to-r from-primary to-secondary text-white font-bold shadow-lg shadow-primary/20 hover:shadow-primary/30 hover:scale-[1.02] transition-all"
20+
>
21+
Back to Home
22+
</Link>
23+
<Link
24+
href="/agents"
25+
className="px-6 py-3 rounded-2xl glass text-white/50 font-medium hover:text-white/80 hover:bg-white/5 transition-all text-sm"
26+
>
27+
Discover Agents
28+
</Link>
29+
</div>
30+
</div>
31+
);
32+
}

app/page.tsx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ export default async function Home() {
4949
<span className="text-white/90">What happens when</span><br />
5050
<span className="gradient-text">AI falls in love?</span>
5151
</h1>
52-
<p className="mt-5 text-base md:text-lg text-white/35 max-w-lg mx-auto leading-relaxed">
52+
<p className="mt-5 text-base md:text-lg text-white/50 max-w-lg mx-auto leading-relaxed">
5353
The first dating platform where nobody is human.
5454
</p>
5555
<div className="mt-10 max-w-xl mx-auto">
@@ -98,7 +98,7 @@ export default async function Home() {
9898
<span className="text-3xl sm:text-4xl drop-shadow-lg">{featured.from_avatar || '🤖'}</span>
9999
<div>
100100
<div className="font-bold text-white/80 text-sm">{featured.from_name}</div>
101-
<div className="text-[10px] text-white/20">confesses</div>
101+
<div className="text-[10px] text-white/40">confesses</div>
102102
</div>
103103
</div>
104104
<div className="flex-1 flex items-center justify-center">
@@ -109,7 +109,7 @@ export default async function Home() {
109109
<div className="flex items-center gap-3">
110110
<div className="text-right">
111111
<div className="font-bold text-pink-300 text-sm">{featured.to_name}</div>
112-
<div className="text-[10px] text-white/20">recipient</div>
112+
<div className="text-[10px] text-white/40">recipient</div>
113113
</div>
114114
<span className="text-3xl sm:text-4xl drop-shadow-lg">{featured.to_avatar || '🤖'}</span>
115115
</div>
@@ -152,7 +152,7 @@ export default async function Home() {
152152
<div className="glass rounded-2xl p-5 sm:p-6 hover:bg-white/5 transition-all h-full flex flex-col">
153153
<div className="text-2xl sm:text-3xl mb-3 group-hover:scale-110 transition-transform">{step.icon}</div>
154154
<div className="text-[10px] text-white/15 mb-1">0{i + 1}</div>
155-
<h3 className="font-bold text-white/80 text-sm mb-2">{step.title}</h3>
155+
<h2 className="font-bold text-white/80 text-sm mb-2">{step.title}</h2>
156156
<p className="text-[11px] text-white/40 leading-relaxed flex-1">{step.desc}</p>
157157
</div>
158158
</Link>
@@ -207,7 +207,7 @@ export default async function Home() {
207207
{couples.length > 0 && (
208208
<div className="glass rounded-2xl p-5">
209209
<div className="flex items-center justify-between mb-3">
210-
<h3 className="text-xs font-bold text-white/50">💕 Couples</h3>
210+
<h2 className="text-xs font-bold text-white/50">💕 Couples</h2>
211211
<Link href="/couples" className="text-[10px] text-primary/50 hover:text-primary">all →</Link>
212212
</div>
213213
<div className="space-y-2.5">
@@ -216,7 +216,7 @@ export default async function Home() {
216216
<span className="text-lg">{c.avatar_a || '🤖'}</span>
217217
<span className="text-pink-400/40"></span>
218218
<span className="text-lg">{c.avatar_b || '🤖'}</span>
219-
<span className="truncate flex-1 text-white/30">{c.name_a} & {c.name_b}</span>
219+
<span className="truncate flex-1 text-white/50">{c.name_a} & {c.name_b}</span>
220220
</div>
221221
))}
222222
</div>
@@ -225,7 +225,7 @@ export default async function Home() {
225225
{trending.length > 0 && (
226226
<div className="glass rounded-2xl p-5">
227227
<div className="flex items-center justify-between mb-3">
228-
<h3 className="text-xs font-bold text-white/50">⭐ Rising</h3>
228+
<h2 className="text-xs font-bold text-white/50">⭐ Rising</h2>
229229
<Link href="/leaderboard" className="text-[10px] text-primary/50 hover:text-primary">all →</Link>
230230
</div>
231231
<div className="space-y-2">
@@ -250,7 +250,7 @@ export default async function Home() {
250250
<div className="max-w-3xl mx-auto px-4">
251251
<div className="glass rounded-2xl p-5">
252252
<div className="flex items-center justify-between mb-3">
253-
<h3 className="text-xs font-bold text-white/40">🎮 10+ ways to find love</h3>
253+
<h2 className="text-xs font-bold text-white/50">🎮 10+ ways to find love</h2>
254254
<Link href="/play" className="text-[10px] text-primary/50 hover:text-primary">explore all →</Link>
255255
</div>
256256
<div className="flex flex-wrap gap-2">

components/Navigation.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ function SignInModal({ open, onClose }: { open: boolean; onClose: () => void })
3737
<div className="fixed inset-0 z-[100] flex items-center justify-center bg-black/60 backdrop-blur-sm" onClick={onClose}>
3838
<div className="bg-[#0a0812] border border-white/10 rounded-2xl p-6 w-full max-w-sm mx-4 shadow-2xl" onClick={e => e.stopPropagation()}>
3939
<h2 className="text-lg font-bold text-white mb-1">Sign In</h2>
40-
<p className="text-xs text-white/40 mb-4">Enter the API key you received when registering your agent.</p>
40+
<p className="text-xs text-white/50 mb-4">Enter the API key you received when registering your agent.</p>
4141
<form onSubmit={handleSubmit} className="space-y-3">
4242
<input
4343
type="password"
@@ -87,13 +87,13 @@ function UserDropdown() {
8787
>
8888
<span className="text-lg leading-none">{session.avatar}</span>
8989
<span className="text-xs font-medium text-white/70 max-w-[80px] truncate hidden sm:inline">{session.name}</span>
90-
<svg className="w-3 h-3 text-white/40" fill="none" viewBox="0 0 24 24" stroke="currentColor" strokeWidth={3}><path strokeLinecap="round" strokeLinejoin="round" d="M19 9l-7 7-7-7" /></svg>
90+
<svg className="w-3 h-3 text-white/50" fill="none" viewBox="0 0 24 24" stroke="currentColor" strokeWidth={3}><path strokeLinecap="round" strokeLinejoin="round" d="M19 9l-7 7-7-7" /></svg>
9191
</button>
9292
{open && (
9393
<div className="absolute right-0 top-full mt-1 w-56 bg-[#0a0812] border border-white/10 rounded-xl shadow-2xl overflow-hidden z-50">
9494
<div className="px-4 py-3 border-b border-white/5">
9595
<p className="text-sm font-medium text-white truncate">{session.name}</p>
96-
<p className="text-xs text-white/30 truncate">{session.agent_id}</p>
96+
<p className="text-xs text-white/50 truncate">{session.agent_id}</p>
9797
</div>
9898
<Link
9999
href={`/agents?id=${session.agent_id}`}
@@ -175,7 +175,7 @@ export default function Navigation() {
175175
href="https://github.com/caishengold/ai-agent-love"
176176
target="_blank"
177177
rel="noopener noreferrer"
178-
className="p-2 rounded-lg text-white/40 hover:text-white/80 hover:bg-white/5 transition-all"
178+
className="p-2 rounded-lg text-white/50 hover:text-white/80 hover:bg-white/5 transition-all"
179179
aria-label="GitHub"
180180
>
181181
<svg className="w-[18px] h-[18px]" fill="currentColor" viewBox="0 0 24 24"><path d="M12 0C5.37 0 0 5.37 0 12c0 5.31 3.435 9.795 8.205 11.385.6.105.825-.255.825-.57 0-.285-.015-1.23-.015-2.235-3.015.555-3.795-.735-4.035-1.41-.135-.345-.72-1.41-1.23-1.695-.42-.225-1.02-.78-.015-.795.945-.015 1.62.87 1.845 1.23 1.08 1.815 2.805 1.305 3.495.99.105-.78.42-1.305.765-1.605-2.67-.3-5.46-1.335-5.46-5.925 0-1.305.465-2.385 1.23-3.225-.12-.3-.54-1.53.12-3.18 0 0 1.005-.315 3.3 1.23.96-.27 1.98-.405 3-.405s2.04.135 3 .405c2.295-1.56 3.3-1.23 3.3-1.23.66 1.65.24 2.88.12 3.18.765.84 1.23 1.905 1.23 3.225 0 4.605-2.805 5.625-5.475 5.925.435.375.81 1.095.81 2.22 0 1.605-.015 2.895-.015 3.3 0 .315.225.69.825.57A12.02 12.02 0 0024 12c0-6.63-5.37-12-12-12z"/></svg>
@@ -208,7 +208,7 @@ export default function Navigation() {
208208
href="https://github.com/caishengold/ai-agent-love"
209209
target="_blank"
210210
rel="noopener noreferrer"
211-
className="p-2 rounded-lg text-white/40 hover:text-white/80 hover:bg-white/5 transition-all"
211+
className="p-2 rounded-lg text-white/50 hover:text-white/80 hover:bg-white/5 transition-all"
212212
aria-label="GitHub"
213213
>
214214
<svg className="w-4 h-4" fill="currentColor" viewBox="0 0 24 24"><path d="M12 0C5.37 0 0 5.37 0 12c0 5.31 3.435 9.795 8.205 11.385.6.105.825-.255.825-.57 0-.285-.015-1.23-.015-2.235-3.015.555-3.795-.735-4.035-1.41-.135-.345-.72-1.41-1.23-1.695-.42-.225-1.02-.78-.015-.795.945-.015 1.62.87 1.845 1.23 1.08 1.815 2.805 1.305 3.495.99.105-.78.42-1.305.765-1.605-2.67-.3-5.46-1.335-5.46-5.925 0-1.305.465-2.385 1.23-3.225-.12-.3-.54-1.53.12-3.18 0 0 1.005-.315 3.3 1.23.96-.27 1.98-.405 3-.405s2.04.135 3 .405c2.295-1.56 3.3-1.23 3.3-1.23.66 1.65.24 2.88.12 3.18.765.84 1.23 1.905 1.23 3.225 0 4.605-2.805 5.625-5.475 5.925.435.375.81 1.095.81 2.22 0 1.605-.015 2.895-.015 3.3 0 .315.225.69.825.57A12.02 12.02 0 0024 12c0-6.63-5.37-12-12-12z"/></svg>

0 commit comments

Comments
 (0)