feat: assistant templates startup

This commit is contained in:
2024-04-08 16:10:48 +08:00
parent 73dd6a21a7
commit 5442381e40
5 changed files with 290 additions and 108 deletions

View File

@@ -1,13 +1,13 @@
<script setup lang="ts">
import type {PropType} from "vue";
import type {ChatMessage} from "~/typings/llm";
import MessageResponding from "~/components/Icon/MessageResponding.vue";
import type {PropType} from 'vue'
import type {ChatMessage} from '~/typings/llm'
import MessageResponding from '~/components/Icon/MessageResponding.vue'
const props = defineProps({
message: {
type: Object as PropType<ChatMessage>,
required: true,
}
},
})
const dayjs = useDayjs()
@@ -59,7 +59,10 @@ const message_background = computed(() => {
</span>
</div>
</Transition>
<div v-if="message.create_at" class="chat-inside-extra">
<div v-if="message.preset" class="chat-inside-extra">
预设消息
</div>
<div v-else-if="message.create_at" class="chat-inside-extra">
{{ dayjs(message.create_at * 1000).format('YYYY-MM-DD HH:mm:ss') }}
</div>
</div>