mirror of
https://github.com/DayuanJiang/next-ai-draw-io.git
synced 2026-01-02 22:32:27 +08:00
chore: remove About link from header and language switcher from about pages
- Remove About link and sponsor notice icon from chat panel header - Remove language switcher (English | 中文 | 日本語) from all about pages - Fix About link in settings dialog to use current language - Remove unused sponsorTooltip translation key from all dictionaries
This commit is contained in:
@@ -72,28 +72,6 @@ export default function AboutCN() {
|
|||||||
<p className="text-xl text-gray-600 font-medium">
|
<p className="text-xl text-gray-600 font-medium">
|
||||||
AI驱动的图表创建工具 - 对话、绘制、可视化
|
AI驱动的图表创建工具 - 对话、绘制、可视化
|
||||||
</p>
|
</p>
|
||||||
<div className="flex justify-center gap-4 mt-4 text-sm">
|
|
||||||
<Link
|
|
||||||
href="/about"
|
|
||||||
className="text-gray-600 hover:text-blue-600"
|
|
||||||
>
|
|
||||||
English
|
|
||||||
</Link>
|
|
||||||
<span className="text-gray-400">|</span>
|
|
||||||
<Link
|
|
||||||
href="/about/cn"
|
|
||||||
className="text-blue-600 font-semibold"
|
|
||||||
>
|
|
||||||
中文
|
|
||||||
</Link>
|
|
||||||
<span className="text-gray-400">|</span>
|
|
||||||
<Link
|
|
||||||
href="/about/ja"
|
|
||||||
className="text-gray-600 hover:text-blue-600"
|
|
||||||
>
|
|
||||||
日本語
|
|
||||||
</Link>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className="relative mb-8 rounded-2xl bg-gradient-to-br from-amber-50 via-orange-50 to-yellow-50 p-[1px] shadow-lg">
|
<div className="relative mb-8 rounded-2xl bg-gradient-to-br from-amber-50 via-orange-50 to-yellow-50 p-[1px] shadow-lg">
|
||||||
|
|||||||
@@ -80,28 +80,6 @@ export default function AboutJA() {
|
|||||||
AI搭載のダイアグラム作成ツール -
|
AI搭載のダイアグラム作成ツール -
|
||||||
チャット、描画、可視化
|
チャット、描画、可視化
|
||||||
</p>
|
</p>
|
||||||
<div className="flex justify-center gap-4 mt-4 text-sm">
|
|
||||||
<Link
|
|
||||||
href="/about"
|
|
||||||
className="text-gray-600 hover:text-blue-600"
|
|
||||||
>
|
|
||||||
English
|
|
||||||
</Link>
|
|
||||||
<span className="text-gray-400">|</span>
|
|
||||||
<Link
|
|
||||||
href="/about/cn"
|
|
||||||
className="text-gray-600 hover:text-blue-600"
|
|
||||||
>
|
|
||||||
中文
|
|
||||||
</Link>
|
|
||||||
<span className="text-gray-400">|</span>
|
|
||||||
<Link
|
|
||||||
href="/about/ja"
|
|
||||||
className="text-blue-600 font-semibold"
|
|
||||||
>
|
|
||||||
日本語
|
|
||||||
</Link>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className="relative mb-8 rounded-2xl bg-gradient-to-br from-amber-50 via-orange-50 to-yellow-50 p-[1px] shadow-lg">
|
<div className="relative mb-8 rounded-2xl bg-gradient-to-br from-amber-50 via-orange-50 to-yellow-50 p-[1px] shadow-lg">
|
||||||
|
|||||||
@@ -80,28 +80,6 @@ export default function About() {
|
|||||||
AI-Powered Diagram Creation Tool - Chat, Draw,
|
AI-Powered Diagram Creation Tool - Chat, Draw,
|
||||||
Visualize
|
Visualize
|
||||||
</p>
|
</p>
|
||||||
<div className="flex justify-center gap-4 mt-4 text-sm">
|
|
||||||
<Link
|
|
||||||
href="/about"
|
|
||||||
className="text-blue-600 font-semibold"
|
|
||||||
>
|
|
||||||
English
|
|
||||||
</Link>
|
|
||||||
<span className="text-gray-400">|</span>
|
|
||||||
<Link
|
|
||||||
href="/about/cn"
|
|
||||||
className="text-gray-600 hover:text-blue-600"
|
|
||||||
>
|
|
||||||
中文
|
|
||||||
</Link>
|
|
||||||
<span className="text-gray-400">|</span>
|
|
||||||
<Link
|
|
||||||
href="/about/ja"
|
|
||||||
className="text-gray-600 hover:text-blue-600"
|
|
||||||
>
|
|
||||||
日本語
|
|
||||||
</Link>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className="relative mb-8 rounded-2xl bg-gradient-to-br from-amber-50 via-orange-50 to-yellow-50 p-[1px] shadow-lg">
|
<div className="relative mb-8 rounded-2xl bg-gradient-to-br from-amber-50 via-orange-50 to-yellow-50 p-[1px] shadow-lg">
|
||||||
|
|||||||
@@ -3,14 +3,12 @@
|
|||||||
import { useChat } from "@ai-sdk/react"
|
import { useChat } from "@ai-sdk/react"
|
||||||
import { DefaultChatTransport } from "ai"
|
import { DefaultChatTransport } from "ai"
|
||||||
import {
|
import {
|
||||||
AlertTriangle,
|
|
||||||
MessageSquarePlus,
|
MessageSquarePlus,
|
||||||
PanelRightClose,
|
PanelRightClose,
|
||||||
PanelRightOpen,
|
PanelRightOpen,
|
||||||
Settings,
|
Settings,
|
||||||
} from "lucide-react"
|
} from "lucide-react"
|
||||||
import Image from "next/image"
|
import Image from "next/image"
|
||||||
import Link from "next/link"
|
|
||||||
import type React from "react"
|
import type React from "react"
|
||||||
import { useCallback, useEffect, useRef, useState } from "react"
|
import { useCallback, useEffect, useRef, useState } from "react"
|
||||||
import { flushSync } from "react-dom"
|
import { flushSync } from "react-dom"
|
||||||
@@ -952,32 +950,6 @@ export default function ChatPanel({
|
|||||||
Next AI Drawio
|
Next AI Drawio
|
||||||
</h1>
|
</h1>
|
||||||
</div>
|
</div>
|
||||||
{!isMobile && (
|
|
||||||
<Link
|
|
||||||
href="/about"
|
|
||||||
target="_blank"
|
|
||||||
rel="noopener noreferrer"
|
|
||||||
className="text-sm text-muted-foreground hover:text-foreground transition-colors ml-2"
|
|
||||||
>
|
|
||||||
{dict.nav.about}
|
|
||||||
</Link>
|
|
||||||
)}
|
|
||||||
{!isMobile && (
|
|
||||||
<Link
|
|
||||||
href="/about"
|
|
||||||
target="_blank"
|
|
||||||
rel="noopener noreferrer"
|
|
||||||
>
|
|
||||||
<ButtonWithTooltip
|
|
||||||
tooltipContent={dict.nav.sponsorTooltip}
|
|
||||||
variant="ghost"
|
|
||||||
size="icon"
|
|
||||||
className="h-6 w-6 text-amber-500 hover:text-amber-600"
|
|
||||||
>
|
|
||||||
<AlertTriangle className="h-4 w-4" />
|
|
||||||
</ButtonWithTooltip>
|
|
||||||
</Link>
|
|
||||||
)}
|
|
||||||
</div>
|
</div>
|
||||||
<div className="flex items-center gap-1 justify-end overflow-visible">
|
<div className="flex items-center gap-1 justify-end overflow-visible">
|
||||||
<ButtonWithTooltip
|
<ButtonWithTooltip
|
||||||
|
|||||||
@@ -395,13 +395,13 @@ function SettingsContent({
|
|||||||
<>
|
<>
|
||||||
<span className="text-muted-foreground">·</span>
|
<span className="text-muted-foreground">·</span>
|
||||||
<a
|
<a
|
||||||
href="/about"
|
href={`/${currentLang}/about${currentLang === "zh" ? "/cn" : currentLang === "ja" ? "/ja" : ""}`}
|
||||||
target="_blank"
|
target="_blank"
|
||||||
rel="noopener noreferrer"
|
rel="noopener noreferrer"
|
||||||
className="text-xs text-muted-foreground hover:text-foreground transition-colors flex items-center gap-1"
|
className="text-xs text-muted-foreground hover:text-foreground transition-colors flex items-center gap-1"
|
||||||
>
|
>
|
||||||
<Info className="h-3 w-3" />
|
<Info className="h-3 w-3" />
|
||||||
About
|
{dict.nav.about}
|
||||||
</a>
|
</a>
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
|
|||||||
@@ -18,8 +18,7 @@
|
|||||||
"settings": "Settings",
|
"settings": "Settings",
|
||||||
"hidePanel": "Hide chat panel (Ctrl+B)",
|
"hidePanel": "Hide chat panel (Ctrl+B)",
|
||||||
"showPanel": "Show chat panel (Ctrl+B)",
|
"showPanel": "Show chat panel (Ctrl+B)",
|
||||||
"aiChat": "AI Chat",
|
"aiChat": "AI Chat"
|
||||||
"sponsorTooltip": "Sponsored by ByteDance Doubao K2-thinking. See About page for details."
|
|
||||||
},
|
},
|
||||||
"providers": {
|
"providers": {
|
||||||
"useServerDefault": "Use Server Default",
|
"useServerDefault": "Use Server Default",
|
||||||
|
|||||||
@@ -18,8 +18,7 @@
|
|||||||
"settings": "設定",
|
"settings": "設定",
|
||||||
"hidePanel": "チャットパネルを非表示 (Ctrl+B)",
|
"hidePanel": "チャットパネルを非表示 (Ctrl+B)",
|
||||||
"showPanel": "チャットパネルを表示 (Ctrl+B)",
|
"showPanel": "チャットパネルを表示 (Ctrl+B)",
|
||||||
"aiChat": "AI チャット",
|
"aiChat": "AI チャット"
|
||||||
"sponsorTooltip": "ByteDance Doubao K2-thinking によるスポンサー。詳細は概要ページをご覧ください。"
|
|
||||||
},
|
},
|
||||||
"providers": {
|
"providers": {
|
||||||
"useServerDefault": "サーバーデフォルトを使用",
|
"useServerDefault": "サーバーデフォルトを使用",
|
||||||
|
|||||||
@@ -18,8 +18,7 @@
|
|||||||
"settings": "设置",
|
"settings": "设置",
|
||||||
"hidePanel": "隐藏聊天面板 (Ctrl+B)",
|
"hidePanel": "隐藏聊天面板 (Ctrl+B)",
|
||||||
"showPanel": "显示聊天面板 (Ctrl+B)",
|
"showPanel": "显示聊天面板 (Ctrl+B)",
|
||||||
"aiChat": "AI 聊天",
|
"aiChat": "AI 聊天"
|
||||||
"sponsorTooltip": "由字节跳动豆包 K2-thinking 赞助。详情请参阅关于页面。"
|
|
||||||
},
|
},
|
||||||
"providers": {
|
"providers": {
|
||||||
"useServerDefault": "使用服务器默认值",
|
"useServerDefault": "使用服务器默认值",
|
||||||
|
|||||||
Reference in New Issue
Block a user