feat: 聊天界面调整

This commit is contained in:
2026-01-21 01:46:30 +08:00
parent 8137a38060
commit 9c5afcaa04
5 changed files with 73 additions and 34 deletions

View File

@@ -0,0 +1,13 @@
<template>
<img class="w-9 h-9 rounded-full shrink-0" :src="src" />
</template>
<script setup lang="ts">
interface Props {
src?: string
}
withDefaults(defineProps<Props>(), {
src: '@assets/images/login/blue_logo.png'
})
</script>

View File

@@ -0,0 +1,43 @@
<template>
<div class="mt-4 text-gray-500 flex items-center justify-between gap-4 ">
<RiFileCopyLine size="16px" @click="copyFileClick()" />
<div class="flex items-center gap-4">
<RiShareForwardLine size="16px" @click="shareForwardClick()" />
<RiDownload2Line size="16px" @click="downloadClick()" />
<RiThumbUpLine size="16px" @click="thumbUpClick()" />
<RiThumbDownLine size="16px" @click="thumbDownClick()" />
</div>
</div>
</template>
<script setup lang="ts">
import { RiFileCopyLine, RiShareForwardLine, RiDownload2Line, RiThumbUpLine, RiThumbDownLine } from '@remixicon/vue'
import { ChatMessage } from '../model/ChatModel';
interface Props {
msg: ChatMessage
}
const { msg } = defineProps<Props>()
/// actions 实现复制、分享、下载、点赞等功能
const copyFileClick = () => {
console.log('copy file', msg)
}
const shareForwardClick = () => {
console.log('share forward', msg)
}
const downloadClick = () => {
console.log('download', msg)
}
const thumbUpClick = () => {
console.log('thumb up', msg)
}
const thumbDownClick = () => {
console.log('thumb down', msg)
}
</script>