feat:【antd】【ai】mindmap 的代码优化
This commit is contained in:
@@ -19,12 +19,6 @@ const abortController = ref<AbortController>(); // // 写作进行中 abort 控
|
||||
|
||||
const rightRef = ref<InstanceType<typeof Right>>(); // 写作面板
|
||||
|
||||
/** 停止 stream 生成 */
|
||||
function handleStopStream() {
|
||||
abortController.value?.abort();
|
||||
isWriting.value = false;
|
||||
}
|
||||
|
||||
/** 提交写作 */
|
||||
function handleSubmit(data: Partial<AiWriteApi.Write>) {
|
||||
abortController.value = new AbortController();
|
||||
@@ -55,6 +49,12 @@ function handleSubmit(data: Partial<AiWriteApi.Write>) {
|
||||
});
|
||||
}
|
||||
|
||||
/** 停止 stream 生成 */
|
||||
function handleStopStream() {
|
||||
abortController.value?.abort();
|
||||
isWriting.value = false;
|
||||
}
|
||||
|
||||
/** 点击示例触发 */
|
||||
function handleExampleClick(type: keyof typeof WriteExample) {
|
||||
writeResult.value = WriteExample[type].data;
|
||||
|
||||
Reference in New Issue
Block a user