Просмотр исходного кода

🔥 (dashboard-v6): 去掉阅读页右边栏的搜索按钮

它打开的 SearchPanel 只是空占位(TODO),一并删除;搜索走主导航的搜索弹窗。

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
visuddhinanda 10 часов назад
Родитель
Сommit
0415a98462

+ 1 - 8
dashboard-v6/src/components/editor/Editor.tsx

@@ -1,9 +1,8 @@
-import { CommentOutlined, SearchOutlined } from "@ant-design/icons";
+import { CommentOutlined } from "@ant-design/icons";
 import { useEffect, useState, type ReactNode } from "react";
 import SplitLayout, { type RightToolbarTab } from "../general/SplitLayout";
 import ChannelPanel from "./panels/ChannelPanel";
 import DictPanel from "./panels/DictPanel";
-import SearchPanel from "./panels/SearchPanel";
 import {
   ChannelIcon,
   DictIcon,
@@ -112,12 +111,6 @@ export default function Editor({
   // ── 右边栏 tabs(固定业务定义)──
   // content 用独立组件而非内联 JSX,保证 articleId 等 props 变化时正常 re-render
   const rightTabs: RightToolbarTab[] = [
-    {
-      key: "search",
-      icon: <SearchOutlined />,
-      label: "搜索",
-      content: <SearchPanel articleId={articleId} anthologyId={anthologyId} />,
-    },
     {
       key: "dict",
       icon: <DictIcon />,

+ 0 - 20
dashboard-v6/src/components/editor/panels/SearchPanel.tsx

@@ -1,20 +0,0 @@
-interface SearchPanelProps {
-  articleId?: string;
-  anthologyId?: string;
-}
-
-/**
- * 搜索面板(占位,按实际业务填充)
- */
-export default function SearchPanel({
-  articleId,
-  anthologyId,
-}: SearchPanelProps) {
-  console.debug("panel render", articleId, anthologyId);
-  return (
-    <div style={{ padding: 16 }}>
-      {/* TODO: 实现搜索业务逻辑 */}
-      <div style={{ marginTop: 12 }} />
-    </div>
-  );
-}