|
@@ -2,7 +2,6 @@
|
|
|
<div class="ai-assistant">
|
|
|
<div class="title">
|
|
|
<div class="name"><img src="/images/zczk/icon-ai-g.gif" /> AI智能助手</div>
|
|
|
- <div class="icon" @click="toggleZoom"><img src="/images/zczk/icon-scale.png" /></div>
|
|
|
</div>
|
|
|
<div class="question">
|
|
|
<div class="item">
|
|
@@ -23,29 +22,27 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="chat">
|
|
|
- <div class="item" v-for="(item, index) in form.chatDesc" :key="index">
|
|
|
- <div class="user-panel">
|
|
|
- <div class="name">{{ item.name }}</div>
|
|
|
- <img src="/images/zczk/user.png" />
|
|
|
- </div>
|
|
|
- <div class="ai-panel">
|
|
|
- <img src="/images/zczk/icon-ai-title.png" />
|
|
|
- <div class="desc" v-if="item.content" id="scrollArea">
|
|
|
- <vue-markdown-it
|
|
|
- :source="item.content"
|
|
|
- :options="{
|
|
|
- html: true,
|
|
|
- linkify: true
|
|
|
- }"
|
|
|
- />
|
|
|
+ <div class="item_box">
|
|
|
+ <div class="item" v-for="(item, index) in form.chatDesc" :key="index">
|
|
|
+ <div class="user-panel">
|
|
|
+ <div class="name">{{ item.name }}</div>
|
|
|
+ <img src="/images/zczk/user.png" />
|
|
|
+ </div>
|
|
|
+ <div class="ai-panel">
|
|
|
+ <img src="/images/zczk/icon-ai-title.png" />
|
|
|
+ <div class="desc" v-if="item.content" id="scrollArea">
|
|
|
+ <vue-markdown-it
|
|
|
+ :source="item.content"
|
|
|
+ :options="{
|
|
|
+ html: true,
|
|
|
+ linkify: true
|
|
|
+ }"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ <div class="desc animation" v-else>正在思考中<span class="dots"></span></div>
|
|
|
</div>
|
|
|
- <div class="desc animation" v-else>正在思考中<span class="dots"></span></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <div class="scale-panel" @click="toggleZoom" v-if="!zoom">
|
|
|
- 视窗太小,点击<span>放大</span>
|
|
|
- </div>
|
|
|
- <div class="scale-panel" @click="toggleZoom" v-else><span> 返回小视窗</span></div>
|
|
|
|
|
|
<div class="input-panel">
|
|
|
<a-textarea
|
|
@@ -266,6 +263,8 @@ const scrollToBottom = async () => {
|
|
|
width: 100%;
|
|
|
height: 100%;
|
|
|
padding: 0px;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
.title {
|
|
|
height: 60px;
|
|
|
margin-bottom: 0px;
|
|
@@ -305,9 +304,10 @@ const scrollToBottom = async () => {
|
|
|
}
|
|
|
}
|
|
|
.question {
|
|
|
- height: calc(100% - 60px);
|
|
|
- padding: 8px 20px 15px 20px;
|
|
|
+ flex: 1;
|
|
|
position: relative;
|
|
|
+ padding: 10px;
|
|
|
+ height: calc(100% - 60px);
|
|
|
.item {
|
|
|
// display: flex;
|
|
|
// width: 521px;
|
|
@@ -357,7 +357,7 @@ const scrollToBottom = async () => {
|
|
|
}
|
|
|
}
|
|
|
.chat {
|
|
|
- height: calc(100% - 400px);
|
|
|
+ height: calc(100% - 170px);
|
|
|
|
|
|
font-family: PingFang SC;
|
|
|
font-weight: 500;
|
|
@@ -366,6 +366,13 @@ const scrollToBottom = async () => {
|
|
|
line-height: 28px;
|
|
|
font-size: 16px;
|
|
|
color: #333333;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ .item_box {
|
|
|
+ flex: 1;
|
|
|
+ flex-grow: 1;
|
|
|
+ overflow-y: auto;
|
|
|
+ }
|
|
|
.item {
|
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
@@ -406,7 +413,7 @@ const scrollToBottom = async () => {
|
|
|
border-radius: 6px 6px 6px 6px;
|
|
|
padding: 10px 18px 10px 13px;
|
|
|
font-weight: 500;
|
|
|
- max-height: 200px;
|
|
|
+ max-height: 300px;
|
|
|
overflow-y: auto;
|
|
|
font-size: 14px;
|
|
|
color: #333333;
|