From 8fb0be43988a240de3ca1569b81f61aec37fb60d Mon Sep 17 00:00:00 2001
From: Feng Jianhuai <164632497+chake111@users.noreply.github.com>
Date: Mon, 20 Apr 2026 22:08:09 +0800
Subject: [PATCH] refactor home first screen to focus on primary conversion
---
ui/app/[locale]/layout.tsx | 8 ++---
ui/app/[locale]/page.tsx | 9 +-----
ui/components/home/home-hero.tsx | 51 +++++---------------------------
3 files changed, 11 insertions(+), 57 deletions(-)
diff --git a/ui/app/[locale]/layout.tsx b/ui/app/[locale]/layout.tsx
index fd75dd3..adb83b9 100644
--- a/ui/app/[locale]/layout.tsx
+++ b/ui/app/[locale]/layout.tsx
@@ -3,7 +3,7 @@ import Link from 'next/link'
import { notFound } from 'next/navigation'
import { hasLocale } from 'next-intl'
import { getMessages, getTranslations, setRequestLocale } from 'next-intl/server'
-import { Heart, Home, Settings2, Sparkles } from 'lucide-react'
+import { Heart, Settings2, Sparkles } from 'lucide-react'
import { AuthSessionProvider } from '@/components/auth-session-provider'
import { IntlProvider } from '@/components/intl-provider'
import { Toaster } from '@/components/ui/toaster'
@@ -43,7 +43,6 @@ export default async function LocaleLayout({ children, params }: LocaleLayoutPro
const messages = await getMessages()
const navItems = [
- { href: `/${locale}`, label: locale === 'zh' ? '首页' : 'Home', icon: Home },
{ href: `/${locale}/favorites`, label: locale === 'zh' ? '收藏' : 'Favorites', icon: Heart },
{ href: `/${locale}/preferences`, label: locale === 'zh' ? '偏好' : 'Preferences', icon: Settings2 },
]
@@ -58,10 +57,7 @@ export default async function LocaleLayout({ children, params }: LocaleLayoutPro
-
-
AI Tool Picker
-
{locale === 'zh' ? '更快完成 AI 工具初选' : 'Shortlist the right AI tools faster'}
-
+ AI Tool Picker
diff --git a/ui/app/[locale]/page.tsx b/ui/app/[locale]/page.tsx
index bd36c80..22b2a50 100644
--- a/ui/app/[locale]/page.tsx
+++ b/ui/app/[locale]/page.tsx
@@ -5,7 +5,6 @@ import { useLocale, useTranslations } from "next-intl"
import { useRouter } from "next/navigation"
import { HomeHero } from "@/components/home/home-hero"
import { HomeQuickScenes } from "@/components/home/home-quick-scenes"
-import { HomeResultsPreview } from "@/components/home/home-results-preview"
import { SearchInput } from "@/components/search-input"
import { useSearchFlow } from "@/hooks/use-search-flow"
import { useHistory } from "@/hooks/use-history"
@@ -39,6 +38,7 @@ export default function HomePage() {
() =>
[...(quickScenesConfig as QuickSceneConfig[])]
.sort((a, b) => a.order - b.order)
+ .slice(0, 4)
.map((scene) => ({ ...scene, label: t(scene.languageKey) })),
[t],
)
@@ -78,17 +78,10 @@ export default function HomePage() {
/>
}
scenarioTitle={t("home.quickScenesTitle")}
- stats={[
- { label: t("home.stats.countLabel"), value: t("home.stats.countValue") },
- { label: t("home.stats.timeLabel"), value: t("home.stats.timeValue") },
- { label: t("home.stats.reasonLabel"), value: t("home.stats.reasonValue") },
- ]}
quickScenes={
}
/>
{searchFlow.error &&
{searchFlow.error}
}
-
-
)
}
diff --git a/ui/components/home/home-hero.tsx b/ui/components/home/home-hero.tsx
index e8d0f90..c34ddc3 100644
--- a/ui/components/home/home-hero.tsx
+++ b/ui/components/home/home-hero.tsx
@@ -1,10 +1,4 @@
import type { ReactNode } from "react"
-import { ShieldCheck, Sparkles, Timer } from "lucide-react"
-
-type HeroStat = {
- label: string
- value: string
-}
type HomeHeroProps = {
title: string
@@ -13,50 +7,21 @@ type HomeHeroProps = {
inputArea: ReactNode
quickScenes: ReactNode
scenarioTitle: string
- stats: HeroStat[]
}
-const iconMap = [Sparkles, Timer, ShieldCheck]
-
-export function HomeHero({ title, subtitle, trustNote, inputArea, quickScenes, scenarioTitle, stats }: HomeHeroProps) {
+export function HomeHero({ title, subtitle, trustNote, inputArea, quickScenes, scenarioTitle }: HomeHeroProps) {
return (
-
-
-
-
-
- AI Tool Decision Assistant
-
-
-
- {trustNote}
- Linear / Vercel inspired workflow
-
+
+
+
{inputArea}
-
- {stats.map((stat, index) => {
- const Icon = iconMap[index] ?? Sparkles
- return (
-
-
-
-
-
-
{stat.label}
-
{stat.value}
-
-
- )
- })}
-
-
-
+
+
{trustNote}
{scenarioTitle}
{quickScenes}