Skip to content

Commit 21fe3ba

Browse files
committed
fix(chat): only show copy btn after response has been fully streamed
Port of nuxt-ui-templates/chat-vue#6
1 parent d8c86cd commit 21fe3ba

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/pages/chat/[id].vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ onMounted(() => {
9191
<UChatMessages
9292
:messages="chat.messages"
9393
:status="chat.status"
94-
:assistant="{ actions: [{ label: 'Copy', icon: copied ? 'i-lucide-copy-check' : 'i-lucide-copy', onClick: copy }] }"
94+
:assistant="chat.status !== 'streaming' ? { actions: [{ label: 'Copy', icon: copied ? 'i-lucide-copy-check' : 'i-lucide-copy', onClick: copy }] } : { actions: [] }"
9595
class="lg:pt-(--ui-header-height) pb-4 sm:pb-6"
9696
:spacing-offset="160"
9797
>

0 commit comments

Comments
 (0)