fix aside

This commit is contained in:
ccmjga
2025-06-01 17:17:55 +08:00
parent 65c96abf9d
commit f030be9c92
4 changed files with 24 additions and 13 deletions

View File

@@ -1,8 +1,7 @@
<template>
<div
class="flex flex-col box-border px-3 scroll-auto overflow-auto fixed top-0 right-0 w-64 border-gray-200 border-l min-h-screen"
<div class="h-[calc(100vh-3.5rem)] flex flex-col box-border p-3 overflow-y-auto w-72 border-gray-200 border-l"
ref="chatContainer">
<div class="flex flex-col gap-y-5 flex-1">
<div class="flex flex-col gap-y-5 flex-1 pb-2">
<li v-for="chatElement in messages" :key="chatElement.content"
:class="['flex items-start gap-2.5', chatElement.isUser ? 'flex-row-reverse' : 'flex-row']">
<img class="w-8 h-8 rounded-full" :src="chatElement.isUser ? '/java.svg' : '/trump.jpg'" alt="avatar">
@@ -143,10 +142,6 @@ const commandContentMap: Record<string, string> = {
DELETE_DEPARTMENT: "删除部门",
};
const toggleMode = () => {
isCommandMode.value = !isCommandMode.value;
};
marked.setOptions({
gfm: true,
breaks: true,

View File

@@ -9,8 +9,13 @@ import Assistant from "./Assistant.vue";
<Headbar></Headbar>
<Sidebar>
</Sidebar>
<article class="flex flex-row ml-44 mr-64 scroll-auto overflow-auto mt-14">
<RouterView></RouterView>
</article>
<Assistant></Assistant>
<!-- 主内容区域 -->
<div class="flex flex-row h-[calc(100vh-3.5rem)] mt-14"> <!-- 减去Headbar高度 -->
<!-- 文章内容区域 -->
<article class="flex-1 ml-44 overflow-y-auto">
<RouterView></RouterView>
</article>
<Assistant></Assistant>
</div>
</template>