From 03f0effcf208fba622e72222b363381aae3b32f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=BB=9D=E5=B0=98?= <237809796@qq.com> Date: Fri, 19 Jun 2026 12:00:26 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E6=9E=84:=20=E6=8B=86Dashboard.vue?= =?UTF-8?q?=E4=BB=AA=E8=A1=A8=E7=9B=98(strategy=E5=89=8D=E7=AB=AF=C2=B7Das?= =?UTF-8?q?hboard<500=E8=BE=BE=E6=A0=87)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 新建 components/dashboard/(StatCardRow 126 + ActiveProjectsPanel 174 + IdeasPanel 82): 统计卡+活跃项目+灵感池 - Dashboard.vue 563→238(<500达标): 头部+refresh+loadAll编排+共享样式 - store共享(useProjectStore单例, 子组件纯读, 无props/emit) strategy: 前端views, 子组件三拆; Dashboard<500达标(第四个继Ideas/Knowledge); scoped .df-panel父子各存(隔离必需) --- .../dashboard/ActiveProjectsPanel.vue | 174 +++++++++ src/components/dashboard/IdeasPanel.vue | 82 ++++ src/components/dashboard/StatCardRow.vue | 126 +++++++ src/views/Dashboard.vue | 350 +----------------- 4 files changed, 395 insertions(+), 337 deletions(-) create mode 100644 src/components/dashboard/ActiveProjectsPanel.vue create mode 100644 src/components/dashboard/IdeasPanel.vue create mode 100644 src/components/dashboard/StatCardRow.vue diff --git a/src/components/dashboard/ActiveProjectsPanel.vue b/src/components/dashboard/ActiveProjectsPanel.vue new file mode 100644 index 0000000..b7013b6 --- /dev/null +++ b/src/components/dashboard/ActiveProjectsPanel.vue @@ -0,0 +1,174 @@ + + + + + diff --git a/src/components/dashboard/IdeasPanel.vue b/src/components/dashboard/IdeasPanel.vue new file mode 100644 index 0000000..2707108 --- /dev/null +++ b/src/components/dashboard/IdeasPanel.vue @@ -0,0 +1,82 @@ + + + + + diff --git a/src/components/dashboard/StatCardRow.vue b/src/components/dashboard/StatCardRow.vue new file mode 100644 index 0000000..9367f0a --- /dev/null +++ b/src/components/dashboard/StatCardRow.vue @@ -0,0 +1,126 @@ + + + + + diff --git a/src/views/Dashboard.vue b/src/views/Dashboard.vue index 7c9843a..8143e8c 100644 --- a/src/views/Dashboard.vue +++ b/src/views/Dashboard.vue @@ -24,97 +24,32 @@ -
-
-
-
-
-
- {{ stat.icon }} -
- - - - {{ stat.trend > 0 ? '+' : '' }}{{ stat.trend }} - -
-
{{ stat.value }}
-
{{ stat.label }}
-
-
-
+
-
-
-

{{ $t('dashboard.activeProjects') }}

- {{ $t('dashboard.viewAll') }} -
-
-
-
-
- - {{ p.name }} -
- {{ $t('dashboard.stage.' + p.stageLabelKey) }} -
-
-
-
-
- {{ p.progress }}% -
-
- - - {{ $t('dashboard.taskUnit', { n: p.activeTasks }) }} - - {{ p.lastActivity }} -
-
-
{{ t('dashboard.empty.noProjects') }} {{ t('dashboard.empty.noProjectsLink') }}
-
-
+
-
-
-

{{ $t('dashboard.ideaPool') }}

- {{ $t('dashboard.viewAll') }} -
-
-
-
- {{ idea.score }} -
-
- {{ idea.title }} - {{ ideaStatusLabel(idea.statusLabel) }} -
-
-
{{ $t('dashboard.empty.noIdeas') }}
-
-
+