فهرست منبع

修改 对话生成图片

XSXS 1 ماه پیش
والد
کامیت
01e87717a7

+ 19 - 0
pages/makedetail/dialogGeneration.scss

@@ -125,6 +125,11 @@ page{
     border: 2rpx solid rgba(255, 255, 255, 0.25);
     margin: 0 25rpx;
     align-items: center;
+    padding-left: 116rpx;
+    padding-right: 22rpx;
+    position: relative;
+    left: 0;
+    top: 0;
     .input-box {
       flex: 1;
       height: 60rpx;
@@ -148,6 +153,20 @@ page{
       align-items: center;
       justify-content: center;
     }
+    .stop
+    ,.keyboard
+    ,.send {
+      width: 52rpx;
+      height: 52rpx;
+    }
+    .icon-img{
+      height: 108rpx;
+      width: 112rpx;
+      position: absolute;
+      bottom: 0;
+      left: 4rpx;
+
+    }
   }
   .footer-tip {
     text-align: center;

+ 14 - 5
pages/makedetail/dialogGeneration.vue

@@ -61,13 +61,21 @@
 			<view class="bom-box" :style="{ bottom: 0 + 'px', height: `${190 + textareaHeight}rpx` }">
 				<!-- 底部输入区 -->
 				<view class="input-bar">
+					<image class="icon-img" src="../../static/makedetail/characterProfilePicture.png" mode="aspectFill"></image>
 					<textarea :autoHeight="true" class="input-box" :adjust-position="false" v-model="question"
 						:disabled="isLoading" placeholder="给我发送消息吧..." @keyup.enter="onSend" maxlength="400"
 						confirm-type="send" @input="onTextareaInput" rows="1"
 						style="overflow-y:auto;max-height:176rpx;min-height:44rpx;" />
-					<button class="send-btn" :disabled="isLoading || !question.trim()" @click="onSend">{{ isLoading ?
+					<!-- <button class="send-btn" :disabled="isLoading || !question.trim()" @click="onSend">{{ isLoading ?
 						'生成中...' :
-						'发送' }}</button>
+						'发送' }}</button> -->
+					<image v-if="isLoading" class="stop" src="../../static/makedetail/stop.png" mode=""
+						@click="stopStreamAnswer" />	
+					<image v-else-if="!isLoading && !question.trim() && keyboardHeight === 0" class="keyboard"
+						src="../../static/makedetail/keyboard.png" mode="" />
+					
+					<image v-else-if="!isLoading && question.trim() && keyboardHeight === 0" class="send" src="../../static/makedetail/send.png"
+						mode="" @click="onSend" />
 				</view>
 				<!-- 底部提示 -->
 				<view class="footer-tip">内容由AI生成,禁用相关功能请联系管理员。</view>
@@ -75,8 +83,9 @@
 		</view>
 	</view>
 </template>
-
 <script>
+// 音乐流程     是否纯音乐  是否需要歌词 歌词是否合法   选择风格等(是否手动输入
+// 图片流程     
 export default {
 	data() {
 		return {
@@ -238,7 +247,7 @@ export default {
 				}
 			}).exec();
 		},
-		retrieveHistoricalRecords(){
+		retrieveHistoricalRecords() {
 			uni.request({
 				url: this.$apiHost + '/Work/streamAnswerLast',
 				method: 'GET',
@@ -254,7 +263,7 @@ export default {
 					console.log("获取历史记录:", res.data.list);
 					if (res.data.success === "yes") {
 						this.messages = res.data.list
-						if (res&&res.data&&res.data.list&&res.data.list.length>0) {
+						if (res && res.data && res.data.list && res.data.list.length > 0) {
 							this.showToBottomBtn = true
 						}
 					}

+ 0 - 0
static/makedetail/sy_icon_jianpan@3x.png → static/makedetail/keyboard.png


+ 0 - 0
static/makedetail/组 1535@3x.png → static/makedetail/send.png


+ 0 - 0
static/makedetail/组 1536@3x.png → static/makedetail/stop.png