whx 1 天之前
父节点
当前提交
a661006c68

+ 54 - 16
virgo.wzfrontend/aiChat/src/components/AIFlowChat.vue

@@ -20,7 +20,8 @@
 		Plus,
 		Check,
 		Loading,
-		Monitor
+		Monitor,
+		Close
 	} from '@element-plus/icons-vue'
 	import {
 		useUserStore
@@ -142,7 +143,7 @@
 	}
 	const returnAIoutputs = (data) => {
 		let str = '';
-		if (data.indexOf('```markdown') > -1) {
+		if (data.indexOf('markdown') > -1) {
 			str = data.replaceAll('\n', '</n>').replaceAll('```markdown', '').replaceAll('```', '');
 		} else {
 			str = data;
@@ -292,7 +293,8 @@
 			previewUrl.value = href.href;
 			return divBox.innerHTML;
 		};
-		return marked('```markdown' + markdown.replaceAll('</n>', '\n') + '```', {
+		let html = '```markdown \n' + markdown.replaceAll('</n>', '\n') + '\n```';
+		return marked(html, {
 			renderer
 		});
 	};
@@ -366,12 +368,16 @@
 									<div :class="'step-icon ' + item.status">
 										<el-icon>
 											<Check v-if="item.status === 'success'" />
-											<Loading v-else />
+											<Loading v-else-if="item.status === 'warning'" />
+											<Close v-else />
 										</el-icon>
 									</div>
 									<div class="wk-content">
-										<div class="title">{{ item.label }}</div>
-										<div class="content" v-if="item.status === 'success'">
+										<div class="title">
+											<div class="title-name">{{ item.label }}</div>
+										</div>
+										<div class="content"
+											v-if="item.status === 'success' || item.status === 'danger'">
 											<el-icon>
 												<Monitor />
 											</el-icon>
@@ -522,12 +528,20 @@
 			&.success {
 				background: var(--el-color-success);
 			}
+
+			&.danger {
+				background: var(--el-color-danger);
+			}
 		}
 
 		&.timeline-warning {
 			.step-icon {
 				animation: rotating 2s linear infinite;
 			}
+
+			.title .title-name::after {
+				display: inline;
+			}
 		}
 	}
 
@@ -541,19 +555,43 @@
 		}
 	}
 
-	.wk-timeline {
-		.el-timeline-item__icon {
-			font-size: 10px;
-		}
-
-		.el-timeline-item {
-			padding-bottom: 10px;
-		}
-	}
-
 	.wk-content {
 		.title {
 			color: #222;
+
+			.title-name::after {
+				display: none;
+				content: '';
+				animation: sequentialDots 2s infinite;
+			}
+
+			@keyframes sequentialDots {
+
+				0%,
+				20% {
+					content: '';
+				}
+
+				25%,
+				40% {
+					content: '.';
+				}
+
+				45%,
+				60% {
+					content: '..';
+				}
+
+				65%,
+				80% {
+					content: '...';
+				}
+
+				85%,
+				100% {
+					content: '';
+				}
+			}
 		}
 
 		.content {

+ 6 - 3
virgo.wzfrontend/aiChat/src/views/AIChat.vue

@@ -34,6 +34,7 @@
 	const edit = () => {
 		const iframe = iframeDom.value;
 		if (iframe.contentWindow) {
+			console.log(isEdit.value);
 			if (isEdit.value) {
 				removeEdit();
 			} else {
@@ -43,8 +44,9 @@
 					type: "devtools_enable",
 					__v0_remote__: 1
 				}, '*')
+				isEdit.value = true;
 			}
-			isEdit.value = !isEdit.value;
+
 		}
 	}
 	const removeEdit = () => {
@@ -56,6 +58,7 @@
 				type: "devtools_enable",
 				__v0_remote__: 1
 			}, '*')
+			aiFlowChatRef.value.selectItem({});
 			isEdit.value = false;
 		}
 	}
@@ -68,7 +71,7 @@
 				removeEdit();
 			}
 			if (type === 'devtools_selected_state' && e.data.key) {
-				aiFlowChatRef.value.selectItem(e.data);
+				if (isEdit.value) aiFlowChatRef.value.selectItem(e.data);
 			}
 		}
 	}
@@ -105,7 +108,7 @@
 				<div class="website-form-title">
 					<div>网页展示</div>
 					<div class="title-icon-box" v-if="websiteUrl">
-						<el-icon :class="isEdit?'active':''" @click="edit">
+						<el-icon :class="isEdit ? 'active' : ''" @click="edit">
 							<Position />
 						</el-icon>
 						<el-icon @click="linTo">

文件差异内容过多而无法显示
+ 10 - 0
virgo.wzfrontend/src/main/resources/static/ai/assets/AIChat-CYLPS6p3.css


文件差异内容过多而无法显示
+ 8 - 8
virgo.wzfrontend/src/main/resources/static/ai/assets/AIChat-D4JVlfQL.js


文件差异内容过多而无法显示
+ 0 - 10
virgo.wzfrontend/src/main/resources/static/ai/assets/AIChat-D65jsWTc.css


文件差异内容过多而无法显示
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/ai/assets/Chats-sLzqFom0.js


文件差异内容过多而无法显示
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/ai/assets/Home-Coo1DjZF.js


文件差异内容过多而无法显示
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/ai/assets/Layout-CA8ZR9-m.js


文件差异内容过多而无法显示
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/ai/assets/Reading-D0l1UBsG.js


文件差异内容过多而无法显示
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/ai/assets/Reading-Rz5_3sJB.js


文件差异内容过多而无法显示
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/ai/assets/ai-KsiqsC4h.js


文件差异内容过多而无法显示
+ 3 - 3
virgo.wzfrontend/src/main/resources/static/ai/assets/index-BRY_gmZo.js


+ 1 - 1
virgo.wzfrontend/src/main/resources/static/ai/index.html

@@ -5,7 +5,7 @@
 		<meta name="viewport" content="width=device-width, initial-scale=1.0" />
 		<link rel="icon" href="https://file-node.oss-cn-shanghai.aliyuncs.com/youji/f9617c7f80da485cb3cc72b6accc62ed">
 		<title>WorkArk AI</title>

-		<script type="module" crossorigin src="./assets/index-BRY_gmZo.js"></script>
+		<script type="module" crossorigin src="./assets/index-DnliQdtc.js"></script>
 		<link rel="stylesheet" crossorigin href="./assets/index-YZrFNSdb.css">
 	</head>
 	<body>