8
This commit is contained in:
@@ -2,6 +2,7 @@ import { ref, onMounted } from 'vue';
|
||||
import { useRoute } from 'vue-router';
|
||||
import { ElMessage, ElMessageBox } from 'element-plus';
|
||||
import apiClient from '@/api/client';
|
||||
import { copyToClipboard } from '@/utils/clipboard';
|
||||
const route = useRoute();
|
||||
const kbId = route.params.id;
|
||||
const isMobile = ref(window.innerWidth <= 768);
|
||||
@@ -162,11 +163,13 @@ async function handleReprocess(doc) {
|
||||
catch { /* ignore */ }
|
||||
}
|
||||
async function handleCopyLink() {
|
||||
try {
|
||||
await navigator.clipboard.writeText(aiUrl.value);
|
||||
const success = await copyToClipboard(aiUrl.value);
|
||||
if (success) {
|
||||
ElMessage.success('AI 链接已复制!');
|
||||
}
|
||||
catch { /* ignore */ }
|
||||
else {
|
||||
ElMessage.error('复制失败,请手动长按复制。');
|
||||
}
|
||||
}
|
||||
// 重新生成 AI 链接
|
||||
async function handleRegenerateLink() {
|
||||
|
||||
Reference in New Issue
Block a user