This commit is contained in:
2025-02-24 18:56:32 +08:00
parent 370752d8e2
commit d616c55c44

View File

@@ -7,7 +7,7 @@
:id="`${num}title`"
>
<div class="title-box">
<p>{{ generateTitle('问题设定') }}:</p>
<p>{{ generateTitle("问题设定") }}:</p>
<span>{{ key.title }}</span>
</div>
<div
@@ -18,26 +18,27 @@
>
<div class="title">
<img src="../../assets/logo.png" alt="" />
<span v-if="item.source === 'Planner'"
<!-- <span v-if="item.source === 'Planner'"
>{{ generateTitle('角色') }}{{ item.source }}</span
>
<span v-else
>{{ generateTitle('模型名称') }}{{ `${item.source}` }}</span
>
> -->
<span> {{ `${item.source}` }} </span>
<!-- <span v-else>{{generateTitle('模型名称')}}{{ `${item.source}: ${item.agent_name}` }}</span> -->
<p
class="active_item"
v-if="key.children.length - 1 === index && reasonStatus.show"
>
<img src="../../assets/layout/vector.png" alt="" />
{{ generateTitle('推理中') }}...
{{ generateTitle("推理中") }}...
</p>
</div>
<div class="reasoning-content">
<div
class="reasoning-text"
:class="{
active: key.children.length - 1 === index && reasonStatus.show
active: key.children.length - 1 === index && reasonStatus.show,
}"
>
<div
@@ -71,7 +72,7 @@
>
{{
generateTitle(
'推理完成,如果希望了解更多可继续在下面框中提问或新建对话。'
"推理完成,如果希望了解更多可继续在下面框中提问或新建对话。"
)
}}
</div>
@@ -79,35 +80,35 @@
</div>
</template>
<script setup lang="ts">
import { ref, defineExpose, defineEmits, defineProps } from 'vue'
import { Plus, Minus } from '@element-plus/icons-vue'
import { MdPreview } from 'md-editor-v3'
import { generateTitle } from '../../utils/i18n'
import 'md-editor-v3/lib/style.css'
import { ref, defineExpose, defineEmits, defineProps } from "vue";
import { Plus, Minus } from "@element-plus/icons-vue";
import { MdPreview } from "md-editor-v3";
import { generateTitle } from "../../utils/i18n";
import "md-editor-v3/lib/style.css";
const props: any = defineProps({
reasoningList: {
type: Array,
default: []
}
})
const id = 'preview-only'
const emits = defineEmits(['completeFun'])
const current = ref<Array<any>>([])
default: [],
},
});
const id = "preview-only";
const emits = defineEmits(["completeFun"]);
const current = ref<Array<any>>([]);
const reasonStatus = ref({
index: 0,
show: false
})
const completeList = ref<Array<any>>([])
show: false,
});
const completeList = ref<Array<any>>([]);
const getIcon = (index: number) => {
return current.value[index] ? Plus : Minus
}
return current.value[index] ? Plus : Minus;
};
const changeShow = (index: number) => {
current.value[index] = !current.value[index]
}
current.value[index] = !current.value[index];
};
// const reasoningList = ref<Array<any>>([])
const getAnswer = async () => {
emits('completeFun')
}
emits("completeFun");
};
// function extractSynthesisProcess() {
// talkList.value
// .split(">>>>>>>> USING AUTO REPLY...")
@@ -166,9 +167,9 @@ const getAnswer = async () => {
defineExpose({
getAnswer,
reasonStatus,
completeList
})
completeList,
});
</script>
<style scoped>
@import './index.less';
@import "./index.less";
</style>