From 2db3cf962f5d4919f2f0f51318f4b69f4a967bbb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B1=9F=E6=9E=97=E9=93=96?= Date: Tue, 15 Sep 2026 11:27:31 +0800 Subject: [PATCH] ui: simplify brand knowledge header --- .../BrandKnowledgeDashboard.test.tsx | 4 +- .../BrandKnowledgeDashboard.tsx | 46 ++++++------------- 2 files changed, 17 insertions(+), 33 deletions(-) diff --git a/components/department-dashboard/BrandKnowledgeDashboard.test.tsx b/components/department-dashboard/BrandKnowledgeDashboard.test.tsx index 429d36f..4b205b4 100644 --- a/components/department-dashboard/BrandKnowledgeDashboard.test.tsx +++ b/components/department-dashboard/BrandKnowledgeDashboard.test.tsx @@ -24,7 +24,9 @@ describe('BrandKnowledgeDashboard', () => { it('shows the real upload entry and empty state', async () => { render() - expect(screen.getByRole('heading', { level: 1, name: '品牌知识库' })).toBeInTheDocument() + const main = screen.getByRole('main') + expect(within(main).queryByRole('heading', { level: 1, name: '品牌知识库' })).not.toBeInTheDocument() + expect(within(main).queryByText('可上传')).not.toBeInTheDocument() expect(screen.getByRole('searchbox', { name: '搜索品牌知识' })).toBeInTheDocument() expect(screen.getByRole('navigation', { name: '知识类型' })).toBeInTheDocument() expect(screen.getAllByRole('button').map((button) => button.textContent)).toEqual(expect.arrayContaining([...BRAND_KNOWLEDGE_TYPE_OPTIONS])) diff --git a/components/department-dashboard/BrandKnowledgeDashboard.tsx b/components/department-dashboard/BrandKnowledgeDashboard.tsx index 8b23c2a..4e73997 100644 --- a/components/department-dashboard/BrandKnowledgeDashboard.tsx +++ b/components/department-dashboard/BrandKnowledgeDashboard.tsx @@ -225,36 +225,18 @@ export default function BrandKnowledgeDashboard() {
-
-
-
- - -
-

品牌知识库

-

品牌中心部门工作台

-
-
- - -
- -
-

{notice}

- -
-
+
+

{notice}

+ +
-
+

知识内容

人员上传的知识文件将按类型保存,并可在此下载

@@ -297,7 +279,7 @@ export default function BrandKnowledgeDashboard() {