fix: 语言切换全面修复 —— 品牌层/主题首页/详情区块/404 全量 i18n(zh 矩阵 13/13)
- 站点品牌双语:每站 brandZh(品牌名/标语/hero/导航/页脚/搜索占位)由生成器写入 站点 messages 的 zh 覆盖;SiteChrome 改为 async getTranslations 按语言渲染 - 五套主题首页接线 siteHome/hero 命名空间(新增 wire-theme-i18n.py 一次性接线脚本, 仅处理组件函数体、hook 自动插入、hero 用 th 命名空间) - 详情页 Use cases/Good for/FAQ/reviewCta、用例与合集索引与详情、提交页、 对比页、Alternatives 表头与 FAQ 全部走 next-intl - 404 双语言:locale 内走 next-intl,根级按 Accept-Language - 修复 zh.json 中 84 处 zhXxx 旁挂键归位 + en.json 残留清理(i18n 694 键一致) - 回归:/zh 下 13 页全中文无英文残留、无横向溢出;五站 /zh lang=zh 全部正确
This commit is contained in:
@@ -53,12 +53,30 @@
|
||||
"linkedin": "LinkedIn",
|
||||
"github": "GitHub"
|
||||
}
|
||||
},
|
||||
"site": {
|
||||
"items": [
|
||||
"Discover",
|
||||
"Use Cases",
|
||||
"Best Lists",
|
||||
"Rankings",
|
||||
"Blog",
|
||||
"Submit"
|
||||
],
|
||||
"hrefs": [
|
||||
"/tools",
|
||||
"/ai-tools-for",
|
||||
"/best",
|
||||
"/rankings",
|
||||
"/blog",
|
||||
"/submit"
|
||||
]
|
||||
}
|
||||
},
|
||||
"hero": {
|
||||
"badge": "Discover the Best AI Tools",
|
||||
"title": "AI Stack — Find the Best AI Tools, Ranked by Real Users",
|
||||
"description": "The professional AI tools directory. 1,000+ AI tools across 14 categories ranked by community votes, reviews and engagement.",
|
||||
"title": "Find the best AI tools, ranked by real users",
|
||||
"description": "1,000+ AI tools across 14 categories. Compare votes, reviews and pricing to pick the right one.",
|
||||
"cta": {
|
||||
"primary": "Explore Tools",
|
||||
"secondary": "Read Blog"
|
||||
@@ -649,7 +667,9 @@
|
||||
"latest": "Latest",
|
||||
"trending": "Trending"
|
||||
},
|
||||
"clearFilters": "Clear search & filters"
|
||||
"clearFilters": "Clear search & filters",
|
||||
"useCasesTitle": "Use cases",
|
||||
"goodForTitle": "Good for"
|
||||
},
|
||||
"seo": {
|
||||
"home": {
|
||||
@@ -796,5 +816,284 @@
|
||||
"new": "New",
|
||||
"editorsChoice": "Editor's Choice",
|
||||
"empty": "No tools on this board yet."
|
||||
},
|
||||
"siteHome": {
|
||||
"trending": {
|
||||
"title": "Trending this week",
|
||||
"subtitle": "Ranked by votes, reviews and engagement over the last 7 days"
|
||||
},
|
||||
"categories": {
|
||||
"title": "Browse by category",
|
||||
"viewAll": "All tools"
|
||||
},
|
||||
"new": {
|
||||
"title": "New AI tools"
|
||||
},
|
||||
"editors": {
|
||||
"title": "Editor's Choice"
|
||||
},
|
||||
"useCases": {
|
||||
"title": "Tools by use case",
|
||||
"subtitle": "What do you want to get done?",
|
||||
"viewAll": "All use cases"
|
||||
},
|
||||
"bestLists": {
|
||||
"title": "Best AI tool lists",
|
||||
"subtitle": "Curated rankings by our editors",
|
||||
"viewAll": "All lists"
|
||||
},
|
||||
"reviews": {
|
||||
"title": "Latest community reviews"
|
||||
},
|
||||
"cta": {
|
||||
"title": "Built an AI tool?",
|
||||
"body": "Submit it to {brand} and get discovered by thousands of users looking for tools like yours.",
|
||||
"button": "Submit your tool"
|
||||
},
|
||||
"popular": {
|
||||
"label": "Popular:"
|
||||
},
|
||||
"toolsCount": "{count} tools",
|
||||
"feed": {
|
||||
"title": "Today's feed",
|
||||
"browse": "Browse all products"
|
||||
},
|
||||
"leaderboard": {
|
||||
"title": "Leaderboard",
|
||||
"full": "Full leaderboard"
|
||||
},
|
||||
"picks": {
|
||||
"title": "Editor's picks"
|
||||
},
|
||||
"collections": {
|
||||
"title": "Collections"
|
||||
},
|
||||
"launch": {
|
||||
"button": "Launch your product"
|
||||
},
|
||||
"featured": {
|
||||
"label": "Featured story",
|
||||
"read": "Read the story"
|
||||
},
|
||||
"picksEditorial": {
|
||||
"label": "Editor's picks"
|
||||
},
|
||||
"guides": {
|
||||
"title": "Buying guides",
|
||||
"subtitle": "Deep dives that help you choose",
|
||||
"viewAll": "All guides"
|
||||
},
|
||||
"stories": {
|
||||
"title": "Latest stories",
|
||||
"viewAll": "All stories"
|
||||
},
|
||||
"community": {
|
||||
"title": "From the community",
|
||||
"viewAll": "Browse directory"
|
||||
},
|
||||
"ship": {
|
||||
"title": "Ship faster with AI",
|
||||
"subtitle": "Pick your workflow — we ranked the tools for it",
|
||||
"viewAll": "All use cases"
|
||||
},
|
||||
"upvoted": {
|
||||
"title": "Most upvoted this week",
|
||||
"viewAll": "View all"
|
||||
},
|
||||
"workflows": {
|
||||
"title": "Workflows & stacks",
|
||||
"subtitle": "Batteries-included tool stacks for common dev tasks",
|
||||
"viewAll": "All workflows"
|
||||
},
|
||||
"browseCategory": {
|
||||
"title": "Browse by category"
|
||||
},
|
||||
"trendingNow": {
|
||||
"title": "Trending now"
|
||||
},
|
||||
"seeRankings": "See full rankings",
|
||||
"browse": "Browse tools",
|
||||
"noLaunches": "No launches yet — be the first to submit.",
|
||||
"searchPlaceholder": "Search AI tools...",
|
||||
"reviewsCount": "{count} reviews",
|
||||
"mastheadLabel": "INDEPENDENT AI COVERAGE",
|
||||
"minimalTagline": "AI TOOL SEARCH",
|
||||
"minimalPlaceholder": "I need to create marketing videos...",
|
||||
"useCasesBlockTitle": "Use cases",
|
||||
"goodForBlockTitle": "Good for",
|
||||
"searchButton": "Search",
|
||||
"trendingTitle": "Trending this week",
|
||||
"trendingSubtitle": "Ranked by votes, reviews and engagement over the last 7 days",
|
||||
"allRankings": "All rankings",
|
||||
"categoriesTitle": "Browse by category",
|
||||
"categoriesViewAll": "All tools",
|
||||
"newTitle": "New AI tools",
|
||||
"editorsTitle": "Editor's Choice",
|
||||
"useCasesTitle": "Tools by use case",
|
||||
"useCasesSubtitle": "What do you want to get done?",
|
||||
"useCasesViewAll": "All use cases",
|
||||
"bestListsTitle": "Best AI tool lists",
|
||||
"bestListsSubtitle": "Curated rankings by our editors",
|
||||
"bestListsViewAll": "All lists",
|
||||
"reviewsTitle": "Latest community reviews",
|
||||
"ctaTitle": "Built an AI tool?",
|
||||
"ctaBody": "Submit it to {brand} and get discovered by thousands of users looking for tools like yours.",
|
||||
"ctaButton": "Submit your tool",
|
||||
"popularLabel": "Popular:",
|
||||
"feedTitle": "Today's feed",
|
||||
"feedBrowse": "Browse all products",
|
||||
"leaderboardTitle": "Leaderboard",
|
||||
"leaderboardFull": "Full leaderboard",
|
||||
"picksTitle": "Editor's picks",
|
||||
"collectionsTitle": "Collections",
|
||||
"launchButton": "Launch your product",
|
||||
"featuredLabel": "Featured story",
|
||||
"featuredRead": "Read the story",
|
||||
"picksEditorialLabel": "EDITOR'S PICKS",
|
||||
"guidesTitle": "Buying guides",
|
||||
"guidesSubtitle": "Deep dives that help you choose",
|
||||
"guidesViewAll": "All guides",
|
||||
"storiesTitle": "Latest stories",
|
||||
"storiesViewAll": "All stories",
|
||||
"communityTitle": "From the community",
|
||||
"communityViewAll": "Browse directory",
|
||||
"shipTitle": "Ship faster with AI",
|
||||
"shipSubtitle": "Pick your workflow — we ranked the tools for it",
|
||||
"upvotedTitle": "Most upvoted this week",
|
||||
"upvotedViewAll": "View all",
|
||||
"workflowsTitle": "Workflows & stacks",
|
||||
"workflowsSubtitle": "Batteries-included tool stacks for common dev tasks",
|
||||
"workflowsViewAll": "All workflows",
|
||||
"browseCategoryTitle": "Browse by category",
|
||||
"trendingNowTitle": "Trending now",
|
||||
"browseButton": "Browse tools",
|
||||
"toolsCompared": "{count} tools compared",
|
||||
"popularSearches": [
|
||||
"writing",
|
||||
"video",
|
||||
"coding",
|
||||
"image"
|
||||
]
|
||||
},
|
||||
"best": {
|
||||
"indexTitle": "Best AI Tools — Curated Lists",
|
||||
"indexSubtitle": "Hand-picked rankings, updated with community signal. Every list is labeled and never sold.",
|
||||
"empty": "No collections published yet.",
|
||||
"curated": "Curated list",
|
||||
"faq": "Frequently asked questions",
|
||||
"more": "More best lists",
|
||||
"toolsCompared": "{count} tools"
|
||||
},
|
||||
"aiToolsFor": {
|
||||
"indexTitle": "AI tools for what you do",
|
||||
"indexSubtitle": "Skip the categories. Start from your task or your role — every page ranks tools by real community votes and reviews.",
|
||||
"byTask": "By task",
|
||||
"byAudience": "By audience",
|
||||
"noData": "No use cases yet.",
|
||||
"noAud": "No audiences yet.",
|
||||
"noTools": "No tools tagged yet."
|
||||
},
|
||||
"submitPage": {
|
||||
"title": "Submit your AI tool",
|
||||
"subtitle": "Get a free listing with community votes, user reviews and analytics. Submissions are reviewed by our editors, usually within 48 hours."
|
||||
},
|
||||
"faq": {
|
||||
"title": "Frequently asked questions"
|
||||
},
|
||||
"compare": {
|
||||
"intro": "A side-by-side comparison based on community votes, ratings and reviews — not sponsored placement.",
|
||||
"leaning": "Right now the community leans toward {name}.",
|
||||
"label": "Compare",
|
||||
"noReviews": "—",
|
||||
"latest": "Latest review"
|
||||
},
|
||||
"alternatives": {
|
||||
"noAlt": "No alternatives found yet.",
|
||||
"thisTool": "{name} (this tool)",
|
||||
"table": {
|
||||
"tool": "Tool",
|
||||
"rating": "Rating",
|
||||
"votes": "Votes",
|
||||
"pricing": "Pricing"
|
||||
},
|
||||
"zhTable": {
|
||||
"tool": "Tool",
|
||||
"rating": "Rating",
|
||||
"votes": "Votes",
|
||||
"pricing": "Pricing"
|
||||
}
|
||||
},
|
||||
"notFound": {
|
||||
"code": "404",
|
||||
"title": "Page not found",
|
||||
"body": "The page you are looking for doesn't exist or may have moved.",
|
||||
"home": "Back to home",
|
||||
"tools": "Browse tools"
|
||||
},
|
||||
"search": {
|
||||
"placeholder": "Search 1,000+ AI tools...",
|
||||
"button": "Search"
|
||||
},
|
||||
"siteFooter": {
|
||||
"groups": [
|
||||
{
|
||||
"title": "Discover",
|
||||
"links": [
|
||||
{
|
||||
"label": "All Tools",
|
||||
"href": "/tools"
|
||||
},
|
||||
{
|
||||
"label": "Use Cases",
|
||||
"href": "/ai-tools-for"
|
||||
},
|
||||
{
|
||||
"label": "Best Lists",
|
||||
"href": "/best"
|
||||
},
|
||||
{
|
||||
"label": "Rankings",
|
||||
"href": "/rankings"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"title": "Community",
|
||||
"links": [
|
||||
{
|
||||
"label": "Submit a Tool",
|
||||
"href": "/submit"
|
||||
},
|
||||
{
|
||||
"label": "Blog",
|
||||
"href": "/blog"
|
||||
},
|
||||
{
|
||||
"label": "Dashboard",
|
||||
"href": "/dashboard"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"title": "Legal",
|
||||
"links": [
|
||||
{
|
||||
"label": "Terms",
|
||||
"href": "/terms"
|
||||
},
|
||||
{
|
||||
"label": "Privacy",
|
||||
"href": "/privacy"
|
||||
},
|
||||
{
|
||||
"label": "Contact",
|
||||
"href": "/contact"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"siteHeader": {
|
||||
"searchPlaceholder": "Search AI tools..."
|
||||
}
|
||||
}
|
||||
|
||||
@@ -53,12 +53,29 @@
|
||||
"linkedin": "领英",
|
||||
"github": "GitHub"
|
||||
}
|
||||
},
|
||||
"site": {
|
||||
"items": [
|
||||
"发现",
|
||||
"用例",
|
||||
"最佳清单",
|
||||
"排行榜",
|
||||
"博客",
|
||||
"提交工具"
|
||||
],
|
||||
"hrefs": [
|
||||
"/tools",
|
||||
"/ai-tools-for",
|
||||
"/best",
|
||||
"/rankings",
|
||||
"/blog",
|
||||
"/submit"
|
||||
]
|
||||
}
|
||||
},
|
||||
"hero": {
|
||||
"badge": "发现最好的 AI 工具",
|
||||
"title": "AI Stack — 由真实用户排名的 AI 工具目录",
|
||||
"description": "专业 AI 工具导航:14 个分类、1000+ 工具,由社区投票、评论与互动数据实时排名。",
|
||||
"title": "找到最好的 AI 工具,由真实用户排名",
|
||||
"description": "14 个分类、1000+ AI 工具。对比投票、评论与定价,选出最适合你的。",
|
||||
"cta": {
|
||||
"primary": "探索工具",
|
||||
"secondary": "阅读博客"
|
||||
@@ -657,7 +674,9 @@
|
||||
"latest": "最新",
|
||||
"trending": "最热"
|
||||
},
|
||||
"clearFilters": "清除搜索与筛选"
|
||||
"clearFilters": "清除搜索与筛选",
|
||||
"useCasesTitle": "使用场景",
|
||||
"goodForTitle": "适合人群"
|
||||
},
|
||||
"seo": {
|
||||
"home": {
|
||||
@@ -804,5 +823,284 @@
|
||||
"new": "最新收录",
|
||||
"editorsChoice": "编辑精选",
|
||||
"empty": "该榜单暂无工具。"
|
||||
},
|
||||
"siteHome": {
|
||||
"trending": {
|
||||
"title": "本周趋势",
|
||||
"subtitle": "按最近 7 天投票、评论与互动排名"
|
||||
},
|
||||
"categories": {
|
||||
"title": "按分类浏览",
|
||||
"viewAll": "全部工具"
|
||||
},
|
||||
"new": {
|
||||
"title": "最新收录"
|
||||
},
|
||||
"editors": {
|
||||
"title": "编辑精选"
|
||||
},
|
||||
"useCases": {
|
||||
"title": "按用例找工具",
|
||||
"subtitle": "你想完成什么?",
|
||||
"viewAll": "全部用例"
|
||||
},
|
||||
"bestLists": {
|
||||
"title": "最佳 AI 工具清单",
|
||||
"subtitle": "编辑精选排名",
|
||||
"viewAll": "全部清单"
|
||||
},
|
||||
"reviews": {
|
||||
"title": "最新社区评论"
|
||||
},
|
||||
"cta": {
|
||||
"title": "做了 AI 工具?",
|
||||
"body": "提交到 {brand},让成千上万寻找工具的用户发现你。",
|
||||
"button": "提交你的工具"
|
||||
},
|
||||
"popular": {
|
||||
"label": "热门:"
|
||||
},
|
||||
"toolsCount": "{count} 个工具",
|
||||
"feed": {
|
||||
"title": "今日发布流",
|
||||
"browse": "浏览全部产品"
|
||||
},
|
||||
"leaderboard": {
|
||||
"title": "排行榜",
|
||||
"full": "完整榜单"
|
||||
},
|
||||
"picks": {
|
||||
"title": "编辑推荐"
|
||||
},
|
||||
"collections": {
|
||||
"title": "合集"
|
||||
},
|
||||
"launch": {
|
||||
"button": "发布你的产品"
|
||||
},
|
||||
"featured": {
|
||||
"label": "头条文章",
|
||||
"read": "阅读全文"
|
||||
},
|
||||
"picksEditorial": {
|
||||
"label": "编辑推荐"
|
||||
},
|
||||
"guides": {
|
||||
"title": "选购指南",
|
||||
"subtitle": "帮你做决定的深度对比",
|
||||
"viewAll": "全部指南"
|
||||
},
|
||||
"stories": {
|
||||
"title": "最新文章",
|
||||
"viewAll": "全部文章"
|
||||
},
|
||||
"community": {
|
||||
"title": "来自社区",
|
||||
"viewAll": "浏览目录"
|
||||
},
|
||||
"ship": {
|
||||
"title": "用 AI 加速交付",
|
||||
"subtitle": "选好工作流,我们为它排好了工具",
|
||||
"viewAll": "全部用例"
|
||||
},
|
||||
"upvoted": {
|
||||
"title": "本周最多投票",
|
||||
"viewAll": "查看全部"
|
||||
},
|
||||
"workflows": {
|
||||
"title": "工作流与技术栈",
|
||||
"subtitle": "常见开发任务的完整工具组合",
|
||||
"viewAll": "全部工作流"
|
||||
},
|
||||
"browseCategory": {
|
||||
"title": "按分类浏览"
|
||||
},
|
||||
"trendingNow": {
|
||||
"title": "当前趋势"
|
||||
},
|
||||
"seeRankings": "查看完整排行",
|
||||
"browse": "浏览工具",
|
||||
"noLaunches": "还没有发布——来做第一个。",
|
||||
"searchPlaceholder": "搜索 AI 工具...",
|
||||
"reviewsCount": "{count} 条评论",
|
||||
"mastheadLabel": "独立 AI 报道",
|
||||
"minimalTagline": "AI 工具搜索",
|
||||
"minimalPlaceholder": "我需要制作营销视频……",
|
||||
"useCasesBlockTitle": "使用场景",
|
||||
"goodForBlockTitle": "适合人群",
|
||||
"searchButton": "搜索",
|
||||
"trendingTitle": "本周趋势",
|
||||
"trendingSubtitle": "按最近 7 天投票、评论与互动排名",
|
||||
"allRankings": "全部榜单",
|
||||
"categoriesTitle": "按分类浏览",
|
||||
"categoriesViewAll": "全部工具",
|
||||
"newTitle": "最新收录",
|
||||
"editorsTitle": "编辑精选",
|
||||
"useCasesTitle": "按用例找工具",
|
||||
"useCasesSubtitle": "你想完成什么?",
|
||||
"useCasesViewAll": "全部用例",
|
||||
"bestListsTitle": "最佳 AI 工具清单",
|
||||
"bestListsSubtitle": "编辑精选排名",
|
||||
"bestListsViewAll": "全部清单",
|
||||
"reviewsTitle": "最新社区评论",
|
||||
"ctaTitle": "做了 AI 工具?",
|
||||
"ctaBody": "提交到 {brand},让成千上万寻找工具的用户发现你。",
|
||||
"ctaButton": "提交你的工具",
|
||||
"popularLabel": "热门:",
|
||||
"feedTitle": "今日发布流",
|
||||
"feedBrowse": "浏览全部产品",
|
||||
"leaderboardTitle": "排行榜",
|
||||
"leaderboardFull": "完整榜单",
|
||||
"picksTitle": "编辑推荐",
|
||||
"collectionsTitle": "合集",
|
||||
"launchButton": "发布你的产品",
|
||||
"featuredLabel": "头条文章",
|
||||
"featuredRead": "阅读全文",
|
||||
"picksEditorialLabel": "编辑推荐",
|
||||
"guidesTitle": "选购指南",
|
||||
"guidesSubtitle": "帮你做决定的深度对比",
|
||||
"guidesViewAll": "全部指南",
|
||||
"storiesTitle": "最新文章",
|
||||
"storiesViewAll": "全部文章",
|
||||
"communityTitle": "来自社区",
|
||||
"communityViewAll": "浏览目录",
|
||||
"shipTitle": "用 AI 加速交付",
|
||||
"shipSubtitle": "选好工作流,我们为它排好了工具",
|
||||
"upvotedTitle": "本周最多投票",
|
||||
"upvotedViewAll": "查看全部",
|
||||
"workflowsTitle": "工作流与技术栈",
|
||||
"workflowsSubtitle": "常见开发任务的完整工具组合",
|
||||
"workflowsViewAll": "全部工作流",
|
||||
"browseCategoryTitle": "按分类浏览",
|
||||
"trendingNowTitle": "当前趋势",
|
||||
"browseButton": "浏览工具",
|
||||
"toolsCompared": "{count} 个工具",
|
||||
"popularSearches": [
|
||||
"写作",
|
||||
"视频",
|
||||
"编程",
|
||||
"图像"
|
||||
]
|
||||
},
|
||||
"best": {
|
||||
"indexTitle": "最佳 AI 工具——精选清单",
|
||||
"indexSubtitle": "人工精选排名,持续吸收社区信号。每个清单都明确标注,永不售卖。",
|
||||
"empty": "暂无合集。",
|
||||
"curated": "编辑精选",
|
||||
"faq": "常见问题",
|
||||
"more": "更多最佳清单",
|
||||
"toolsCompared": "{count} 个工具"
|
||||
},
|
||||
"aiToolsFor": {
|
||||
"indexTitle": "按任务找 AI 工具",
|
||||
"indexSubtitle": "别再翻分类。从你的任务或角色出发——每页都按真实社区投票与评论排名。",
|
||||
"byTask": "按任务",
|
||||
"byAudience": "按人群",
|
||||
"noData": "暂无用例。",
|
||||
"noAud": "暂无人群。",
|
||||
"noTools": "暂无关联工具。"
|
||||
},
|
||||
"submitPage": {
|
||||
"title": "提交你的 AI 工具",
|
||||
"subtitle": "免费收录,获得社区投票、用户评论与数据分析。编辑通常在 48 小时内完成审核。"
|
||||
},
|
||||
"faq": {
|
||||
"title": "常见问题"
|
||||
},
|
||||
"compare": {
|
||||
"intro": "基于社区投票、评分与评论的并排对比——非赞助排名。",
|
||||
"leaning": "当前社区更倾向 {name}。",
|
||||
"label": "对比",
|
||||
"noReviews": "—",
|
||||
"latest": "最新评论"
|
||||
},
|
||||
"alternatives": {
|
||||
"noAlt": "暂无替代品。",
|
||||
"thisTool": "{name}(本工具)",
|
||||
"table": {
|
||||
"tool": "工具",
|
||||
"rating": "评分",
|
||||
"votes": "票数",
|
||||
"pricing": "定价"
|
||||
},
|
||||
"zhTable": {
|
||||
"tool": "工具",
|
||||
"rating": "评分",
|
||||
"votes": "票数",
|
||||
"pricing": "定价"
|
||||
}
|
||||
},
|
||||
"notFound": {
|
||||
"code": "404",
|
||||
"title": "页面不存在",
|
||||
"body": "你访问的页面不存在或已被移动。",
|
||||
"home": "返回首页",
|
||||
"tools": "浏览工具"
|
||||
},
|
||||
"search": {
|
||||
"placeholder": "搜索 1000+ AI 工具...",
|
||||
"button": "搜索"
|
||||
},
|
||||
"siteFooter": {
|
||||
"groups": [
|
||||
{
|
||||
"title": "发现",
|
||||
"links": [
|
||||
{
|
||||
"label": "All Tools",
|
||||
"href": "/tools"
|
||||
},
|
||||
{
|
||||
"label": "Use Cases",
|
||||
"href": "/ai-tools-for"
|
||||
},
|
||||
{
|
||||
"label": "Best Lists",
|
||||
"href": "/best"
|
||||
},
|
||||
{
|
||||
"label": "Rankings",
|
||||
"href": "/rankings"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"title": "社区",
|
||||
"links": [
|
||||
{
|
||||
"label": "Submit a Tool",
|
||||
"href": "/submit"
|
||||
},
|
||||
{
|
||||
"label": "Blog",
|
||||
"href": "/blog"
|
||||
},
|
||||
{
|
||||
"label": "Dashboard",
|
||||
"href": "/dashboard"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"title": "法律",
|
||||
"links": [
|
||||
{
|
||||
"label": "Terms",
|
||||
"href": "/terms"
|
||||
},
|
||||
{
|
||||
"label": "Privacy",
|
||||
"href": "/privacy"
|
||||
},
|
||||
{
|
||||
"label": "Contact",
|
||||
"href": "/contact"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"siteHeader": {
|
||||
"searchPlaceholder": "搜索 1000+ AI 工具..."
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
// 自动生成:[locale]/not-found.tsx 的薄路由
|
||||
export { default } from "@aidir/core/pages/[locale]/not-found";
|
||||
@@ -6,13 +6,25 @@ import { locales, defaultLocale, type Locale } from "@aidir/core/i18n.config";
|
||||
const brandMessages = {
|
||||
en: {
|
||||
seo: { home: {"title":"AI Stack — Find the Best AI Tools, Ranked by Real Users","description":"The professional AI tools directory. 1,000+ AI tools across 14 categories ranked by community votes, reviews and engagement.","ogImage":"/og-image.png"} },
|
||||
hero: { title: "AI Stack — Find the Best AI Tools, Ranked by Real Users", description: "The professional AI tools directory. 1,000+ AI tools across 14 categories ranked by community votes, reviews and engagement." },
|
||||
hero: { title: "Find the best AI tools, ranked by real users", description: "1,000+ AI tools across 14 categories. Compare votes, reviews and pricing to pick the right one." },
|
||||
common: { brand: { name: "AI Stack", tagline: "The professional AI tools directory — ranked by the community." } },
|
||||
navigation: {
|
||||
main: { tools: "Discover", blog: "Blog" },
|
||||
site: { items: ["Discover","Use Cases","Best Lists","Rankings","Blog","Submit"], hrefs: ["/tools","/ai-tools-for","/best","/rankings","/blog","/submit"] },
|
||||
},
|
||||
siteFooter: { groups: [{"title":"Discover","links":[{"label":"All Tools","href":"/tools"},{"label":"Use Cases","href":"/ai-tools-for"},{"label":"Best Lists","href":"/best"},{"label":"Rankings","href":"/rankings"}]},{"title":"Community","links":[{"label":"Submit a Tool","href":"/submit"},{"label":"Blog","href":"/blog"},{"label":"Dashboard","href":"/dashboard"}]},{"title":"Legal","links":[{"label":"Terms","href":"/terms"},{"label":"Privacy","href":"/privacy"},{"label":"Contact","href":"/contact"}]}] },
|
||||
siteHeader: { searchPlaceholder: "Search AI tools..." },
|
||||
},
|
||||
zh: {
|
||||
seo: { home: {"title":"AI Stack — 由真实用户排名的 AI 工具目录","description":"专业 AI 工具导航:14 个分类、1000+ 工具,由社区投票、评论与互动数据实时排名。","ogImage":"/og-image.png"} },
|
||||
hero: { title: "AI Stack — 由真实用户排名的 AI 工具目录", description: "专业 AI 工具导航:14 个分类、1000+ 工具,由社区投票、评论与互动数据实时排名。" },
|
||||
common: { brand: { name: "AI Stack", tagline: "The professional AI tools directory — ranked by the community." } },
|
||||
hero: { title: "找到最好的 AI 工具,由真实用户排名", description: "14 个分类、1000+ AI 工具。对比投票、评论与定价,选出最适合你的。" },
|
||||
common: { brand: { name: "AI Stack", tagline: "由真实用户排名的专业 AI 工具目录。" } },
|
||||
navigation: {
|
||||
main: { tools: "发现", blog: "博客" },
|
||||
site: { items: ["发现","用例","最佳清单","排行榜","博客","提交工具"], hrefs: ["/tools","/ai-tools-for","/best","/rankings","/blog","/submit"] },
|
||||
},
|
||||
siteFooter: { groups: [{"title":"发现","links":[{"label":"All Tools","href":"/tools"},{"label":"Use Cases","href":"/ai-tools-for"},{"label":"Best Lists","href":"/best"},{"label":"Rankings","href":"/rankings"}]},{"title":"社区","links":[{"label":"Submit a Tool","href":"/submit"},{"label":"Blog","href":"/blog"},{"label":"Dashboard","href":"/dashboard"}]},{"title":"法律","links":[{"label":"Terms","href":"/terms"},{"label":"Privacy","href":"/privacy"},{"label":"Contact","href":"/contact"}]}] },
|
||||
siteHeader: { searchPlaceholder: "搜索 1000+ AI 工具..." },
|
||||
},
|
||||
} as const;
|
||||
|
||||
|
||||
@@ -2,6 +2,26 @@ import type { SiteConfig } from "@/kit/types";
|
||||
|
||||
// AI Stack —— 独立站点的全部品牌/导航/页脚配置
|
||||
export const siteConfig: SiteConfig = {
|
||||
"brandZh": {
|
||||
"name": "AI Stack",
|
||||
"tagline": "由真实用户排名的专业 AI 工具目录。",
|
||||
"headline": "找到最好的 AI 工具,由真实用户排名",
|
||||
"subheadline": "14 个分类、1000+ AI 工具。对比投票、评论与定价,选出最适合你的。",
|
||||
"nav": [
|
||||
"发现",
|
||||
"用例",
|
||||
"最佳清单",
|
||||
"排行榜",
|
||||
"博客",
|
||||
"提交工具"
|
||||
],
|
||||
"footer": [
|
||||
"发现",
|
||||
"社区",
|
||||
"法律"
|
||||
],
|
||||
"searchPlaceholder": "搜索 1000+ AI 工具..."
|
||||
},
|
||||
"accent": "222 47% 11%",
|
||||
"port": 3001,
|
||||
"brand": {
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
// 自动生成:站点首页组件(源自底座 classic 形态,品牌来自 @/site/brand)
|
||||
import { siteConfig } from "@/site/brand";
|
||||
import { Search, TrendingUp, Sparkles, Clock, Award, LayoutGrid, MessageSquareQuote } from "lucide-react";
|
||||
import { getTranslations } from "next-intl/server";
|
||||
import { ToolCard, ToolCardGrid } from "@/components/tool-card";
|
||||
import { LocaleLink } from "@/components/locale-link";
|
||||
import { SectionHeader } from "@/kit/section";
|
||||
@@ -50,6 +51,8 @@ const footerGroups = [
|
||||
];
|
||||
|
||||
async function SiteHome({ locale }: { locale: string }) {
|
||||
const t = await getTranslations("siteHome");
|
||||
const th = await getTranslations("hero");
|
||||
const data = await getHomeDataSafe(8);
|
||||
|
||||
return (
|
||||
@@ -58,17 +61,17 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
<section className="border-b border-border bg-gradient-to-b from-secondary/40 to-background">
|
||||
<div className="mx-auto max-w-7xl px-4 py-16 text-center sm:px-6 md:py-24">
|
||||
<h1 className="mx-auto max-w-3xl text-3xl font-bold tracking-tight text-foreground sm:text-4xl md:text-5xl">
|
||||
{siteConfig.brand.headline}
|
||||
{th("title")}
|
||||
</h1>
|
||||
<p className="mx-auto mt-4 max-w-2xl text-sm text-muted-foreground sm:text-base">
|
||||
{siteConfig.brand.subheadline}
|
||||
{th("description")}
|
||||
</p>
|
||||
<form action={`/${locale}/tools`} className="mx-auto mt-8 max-w-xl">
|
||||
<div className="relative">
|
||||
<Search className="absolute left-4 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground" />
|
||||
<input
|
||||
name="search"
|
||||
placeholder="Search 1,000+ AI tools..."
|
||||
placeholder={t("searchPlaceholder")}
|
||||
className="h-12 w-full rounded-full border border-border bg-background pl-11 pr-28 text-sm text-foreground shadow-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-primary/30"
|
||||
aria-label="Search AI tools"
|
||||
/>
|
||||
@@ -76,13 +79,13 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
type="submit"
|
||||
className="absolute right-1.5 top-1.5 h-9 rounded-full bg-primary px-5 text-xs font-semibold text-primary-foreground transition-opacity hover:opacity-90"
|
||||
>
|
||||
Search
|
||||
{t("searchButton")}
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
<div className="mt-4 flex flex-wrap items-center justify-center gap-2 text-xs text-muted-foreground">
|
||||
<span>Popular:</span>
|
||||
{["writing", "video", "coding", "image"].map((q) => (
|
||||
<span>{t("popularLabel")}</span>
|
||||
{t.raw("popularSearches").map((q: string) => (
|
||||
<LocaleLink
|
||||
key={q}
|
||||
href={`/tools?search=${q}`}
|
||||
@@ -100,10 +103,10 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
{data.trending.length > 0 && (
|
||||
<section>
|
||||
<SectionHeader
|
||||
title="Trending this week"
|
||||
subtitle="Ranked by votes, reviews and engagement over the last 7 days"
|
||||
title={t("trendingTitle")}
|
||||
subtitle={t("trendingSubtitle")}
|
||||
viewAllHref="/rankings?board=trending"
|
||||
viewAllLabel="All rankings"
|
||||
viewAllLabel={t("allRankings")}
|
||||
/>
|
||||
<ToolCardGrid tools={data.trending} locale={locale} ranked />
|
||||
</section>
|
||||
@@ -113,9 +116,9 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
{data.categories.length > 0 && (
|
||||
<section>
|
||||
<SectionHeader
|
||||
title="Browse by category"
|
||||
title={t("categoriesTitle")}
|
||||
viewAllHref="/tools"
|
||||
viewAllLabel="All tools"
|
||||
viewAllLabel={t("categoriesViewAll")}
|
||||
/>
|
||||
<div className="grid grid-cols-2 gap-3 sm:grid-cols-3 lg:grid-cols-5">
|
||||
{data.categories.slice(0, 10).map((category) => (
|
||||
@@ -144,7 +147,7 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
{data.newest.length > 0 && (
|
||||
<section>
|
||||
<SectionHeader
|
||||
title="New AI tools"
|
||||
title={t("newTitle")}
|
||||
viewAllHref="/rankings?board=new"
|
||||
/>
|
||||
<ToolCardGrid tools={data.newest.slice(0, 4)} locale={locale} />
|
||||
@@ -153,7 +156,7 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
{data.editorsChoice.length > 0 && (
|
||||
<section>
|
||||
<SectionHeader
|
||||
title="Editor's Choice"
|
||||
title={t("editorsTitle")}
|
||||
viewAllHref="/rankings?board=editors-choice"
|
||||
/>
|
||||
<ToolCardGrid tools={data.editorsChoice.slice(0, 4)} locale={locale} />
|
||||
@@ -165,10 +168,10 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
{data.useCases.length > 0 && (
|
||||
<section>
|
||||
<SectionHeader
|
||||
title="Tools by use case"
|
||||
subtitle="What do you want to get done?"
|
||||
title={t("useCasesTitle")}
|
||||
subtitle={t("useCasesSubtitle")}
|
||||
viewAllHref="/ai-tools-for"
|
||||
viewAllLabel="All use cases"
|
||||
viewAllLabel={t("useCasesViewAll")}
|
||||
/>
|
||||
<div className="flex flex-wrap gap-2">
|
||||
{data.useCases.slice(0, 12).map((uc) => (
|
||||
@@ -191,10 +194,10 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
{data.collections.length > 0 && (
|
||||
<section>
|
||||
<SectionHeader
|
||||
title="Best AI tool lists"
|
||||
subtitle="Curated rankings by our editors"
|
||||
title={t("bestListsTitle")}
|
||||
subtitle={t("bestListsSubtitle")}
|
||||
viewAllHref="/best"
|
||||
viewAllLabel="All lists"
|
||||
viewAllLabel={t("bestListsViewAll")}
|
||||
/>
|
||||
<div className="grid gap-3 sm:grid-cols-2 lg:grid-cols-3">
|
||||
{data.collections.slice(0, 3).map((col) => (
|
||||
@@ -222,7 +225,7 @@ async function SiteHome({ locale }: { locale: string }) {
|
||||
{/* Latest Reviews */}
|
||||
{data.latestReviews.length > 0 && (
|
||||
<section>
|
||||
<SectionHeader title="Latest community reviews" />
|
||||
<SectionHeader title={t("reviewsTitle")} />
|
||||
<div className="grid gap-3 md:grid-cols-2">
|
||||
{data.latestReviews.map((review, i) => (
|
||||
<LocaleLink
|
||||
|
||||
Reference in New Issue
Block a user