From 9b750008413c052250b7a4d302a6544ad10e919e Mon Sep 17 00:00:00 2001 From: MT-Mint <798521692@qq.com> Date: Fri, 27 Mar 2026 17:34:48 +0800 Subject: [PATCH] =?UTF-8?q?feat(stacked-cards):=20=E9=87=8D=E5=81=9A=20Sta?= =?UTF-8?q?ckedCards=20=E7=BB=84=E4=BB=B6=E5=B9=B6=E5=AE=8C=E5=96=84?= =?UTF-8?q?=E9=99=84=E4=BB=B6=E4=BA=A4=E4=BA=92?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/chat/ChatMain.vue | 27 - src/components/icons/custom/PlusIcon.vue | 17 + src/components/input/AttachmentPreview.vue | 269 -------- src/components/input/ChatInput.vue | 180 +++--- src/components/input/UploadActionCards.vue | 194 ++++++ src/components/ui/StackedCards.vue | 691 +++++++++++++++++---- src/components/ui/StackedCardsDemo.vue | 157 ----- src/router/index.ts | 5 - 8 files changed, 889 insertions(+), 651 deletions(-) create mode 100644 src/components/icons/custom/PlusIcon.vue delete mode 100644 src/components/input/AttachmentPreview.vue create mode 100644 src/components/input/UploadActionCards.vue delete mode 100644 src/components/ui/StackedCardsDemo.vue diff --git a/src/components/chat/ChatMain.vue b/src/components/chat/ChatMain.vue index e9f10e2..e1a096f 100644 --- a/src/components/chat/ChatMain.vue +++ b/src/components/chat/ChatMain.vue @@ -28,13 +28,6 @@
- -
- -
{ return "输入你的问题,按 Ctrl+Enter 发送"; }); -// 附件相关 -const currentAttachments = computed(() => chatInputRef.value?.attachments || []); -const hasAttachments = computed(() => currentAttachments.value.length > 0); - -function handleRemoveAttachment(id: string) { - chatInputRef.value?.removeAttachment(id); -} - function toggleWideMode() { isWideMode.value = !isWideMode.value; } @@ -553,17 +537,6 @@ watch( } } -.attachments-preview-container { - margin-bottom: 12px; - background: #f3f4f5; - border-radius: 16px; - overflow: hidden; - - .dark & { - background: #1e1e2e; - } -} - .input-container { margin: auto; width: 55%; diff --git a/src/components/icons/custom/PlusIcon.vue b/src/components/icons/custom/PlusIcon.vue new file mode 100644 index 0000000..845f729 --- /dev/null +++ b/src/components/icons/custom/PlusIcon.vue @@ -0,0 +1,17 @@ + + + diff --git a/src/components/input/AttachmentPreview.vue b/src/components/input/AttachmentPreview.vue deleted file mode 100644 index d23f687..0000000 --- a/src/components/input/AttachmentPreview.vue +++ /dev/null @@ -1,269 +0,0 @@ - - - - - diff --git a/src/components/input/ChatInput.vue b/src/components/input/ChatInput.vue index aeeaeaa..eb6894a 100644 --- a/src/components/input/ChatInput.vue +++ b/src/components/input/ChatInput.vue @@ -4,21 +4,18 @@
- - - - - + - - +
@@ -71,11 +68,11 @@ - +
@@ -84,28 +81,27 @@ + + + + diff --git a/src/components/ui/StackedCards.vue b/src/components/ui/StackedCards.vue index 6305f4b..82cc02a 100644 --- a/src/components/ui/StackedCards.vue +++ b/src/components/ui/StackedCards.vue @@ -1,28 +1,56 @@ \ No newline at end of file + diff --git a/src/components/ui/StackedCardsDemo.vue b/src/components/ui/StackedCardsDemo.vue deleted file mode 100644 index 5dd2598..0000000 --- a/src/components/ui/StackedCardsDemo.vue +++ /dev/null @@ -1,157 +0,0 @@ - - - - - \ No newline at end of file diff --git a/src/router/index.ts b/src/router/index.ts index 2c8f84a..b3a78b8 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -15,11 +15,6 @@ const router = createRouter({ component: () => import('@/views/ShareView.vue'), alias: ['/chat-ui/share/:id'], }, - { - path: '/demo/cards', - name: 'stacked-cards-demo', - component: () => import('@/components/ui/StackedCardsDemo.vue'), - }, ], })