feat: 用户收藏、定价筛选、分类落地页、ISR 与 Newsletter/Docker 完善

- 收藏功能:favorite server actions + FavoritesProvider/FavoriteButton(乐观更新、未登录引导登录),列表卡片/详情页收藏按钮,仪表盘"我的收藏"
- 前台定价筛选(免费/免费增值/付费)与卡片定价徽标;首页"精选"改为查询 featured=true,不足时按最新补齐
- /category/[slug] 从 redirect 壳子改为真实落地页:分类双语描述 + 工具网格 + 完整 metadata + JSON-LD
- ISR:首页/工具详情/分类页 revalidate 3600 + generateStaticParams,[locale] layout 补 generateStaticParams;verify-email 与 reset-password 的 useSearchParams 包 Suspense
- 新增共享 ToolLogo 组件(next/image 优化 + data URL 降级 + 首字母占位),核心页面裸 img 全部替换;next.config 补 remotePatterns(R2 域名/Google favicon/https 通配)
- getCategoriesWithCount 只统计 published 工具;featured-tools 文案迁移至 next-intl
- Newsletter:footer 订阅表单 + 落库 + 可选同步 Resend Audience + 退订路由
- Docker:多阶段 Dockerfile(standalone)+ docker-compose(含 Postgres)+ 构建期数据库不可用的容错回退
- i18n:新增 pnpm i18n:check 一致性检查并补齐双语缺失键

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
CoolChange.AI
2026-07-31 20:35:17 -07:00
co-authored by Claude Fable 5
parent 89a9e318c2
commit 845503ad2f
31 changed files with 1228 additions and 201 deletions
+49 -5
View File
@@ -22,7 +22,9 @@
"update": "Update",
"continue": "Continue",
"back": "Back",
"next": "Next"
"next": "Next",
"contactSales": "Contact Sales",
"startTrial": "Start Free Trial"
},
"status": {
"loading": "Loading...",
@@ -442,6 +444,11 @@
"accountSettings": "Account Settings",
"securitySettings": "Security Settings"
}
},
"favorites": {
"title": "My Favorites",
"empty": "No favorite tools yet.",
"browseTools": "Browse tools and save your favorites"
}
},
"profile": {
@@ -459,8 +466,20 @@
},
"accountSettings": {
"title": "Account Settings",
"memberSince": "Member Since"
"memberSince": "Member Since",
"lastLogin": "Last Login",
"accountType": "Account Type"
}
},
"form": {
"nameLabel": "Name",
"namePlaceholder": "Enter your name",
"emailLabel": "Email",
"emailPlaceholder": "Enter your email",
"updateButton": "Update Profile",
"updating": "Updating...",
"updateSuccess": "Profile updated successfully!",
"updateError": "Failed to update profile. Please try again."
}
},
"contact": {
@@ -539,7 +558,8 @@
"company": {
"title": "Company",
"about": "About",
"blog": "Blog"
"blog": "Blog",
"careers": "Careers"
},
"legal": {
"title": "Legal",
@@ -557,7 +577,10 @@
"title": "Subscribe to Newsletter",
"description": "Get the latest updates and news directly in your inbox.",
"placeholder": "Enter your email",
"subscribe": "Subscribe"
"subscribe": "Subscribe",
"success": "Subscribed! Thanks for joining.",
"invalidEmail": "Please enter a valid email address.",
"error": "Subscription failed. Please try again."
}
},
"tools": {
@@ -576,7 +599,21 @@
"toolInfo": "Tool Info",
"domain": "Domain",
"added": "Added",
"notFound": "Tool Not Found"
"notFound": "Tool Not Found",
"favorites": {
"add": "Save to Favorites",
"remove": "Remove from Favorites",
"loginRequired": "Please sign in to save favorites",
"error": "Action failed. Please try again."
},
"pricing": {
"free": "Free",
"freemium": "Freemium",
"paid": "Paid"
},
"categoryPage": {
"viewAll": "View all {count} tools"
}
},
"seo": {
"home": {
@@ -623,5 +660,12 @@
"title": "AI Tools Directory - Discover the Best AI Tools",
"description": "Explore our curated collection of AI tools. Find the best AI tools for productivity, creativity, and more."
}
},
"featuredTools": {
"title": "Featured Tools",
"subtitle": "Curated collection of AI tools to boost your productivity",
"visitWebsite": "Visit website",
"empty": "No tools yet. Add some in the admin panel.",
"viewAll": "View All Tools"
}
}
+33 -3
View File
@@ -421,7 +421,8 @@
"previous": "上一页",
"next": "下一页",
"page": "第 {current} / {total} 页"
}
},
"cancel": "取消"
}
},
"dashboard": {
@@ -443,6 +444,11 @@
"accountSettings": "账户设置",
"securitySettings": "安全设置"
}
},
"favorites": {
"title": "我的收藏",
"empty": "还没有收藏的工具。",
"browseTools": "去浏览工具并收藏"
}
},
"profile": {
@@ -579,7 +585,10 @@
"title": "订阅邮件",
"description": "获取最新动态和资讯,直接发送到您的邮箱。",
"placeholder": "输入您的邮箱",
"subscribe": "订阅"
"subscribe": "订阅",
"success": "订阅成功!感谢加入。",
"invalidEmail": "请输入有效的邮箱地址。",
"error": "订阅失败,请重试。"
}
},
"tools": {
@@ -598,7 +607,21 @@
"toolInfo": "工具信息",
"domain": "域名",
"added": "添加时间",
"notFound": "工具未找到"
"notFound": "工具未找到",
"favorites": {
"add": "收藏",
"remove": "取消收藏",
"loginRequired": "请先登录后再收藏",
"error": "操作失败,请重试。"
},
"pricing": {
"free": "免费",
"freemium": "免费增值",
"paid": "付费"
},
"categoryPage": {
"viewAll": "查看该分类全部 {count} 个工具"
}
},
"seo": {
"home": {
@@ -645,5 +668,12 @@
"title": "AI 工具库 - 发现最好的 AI 工具",
"description": "浏览精选的 AI 工具集合。找到提升效率、激发创意的最佳 AI 工具。"
}
},
"featuredTools": {
"title": "精选工具",
"subtitle": "精选优质 AI 工具,助力提升工作效率",
"visitWebsite": "访问网站",
"empty": "暂无工具,请先在后台添加",
"viewAll": "查看全部工具"
}
}