fix: use tabular variant first to prevent canvas edit jitter

This commit is contained in:
John Jin authored and GitHub committed 2026-06-16 11:13:52 +08:00
1 parent 90c46d5450
commit 13108eb9bb
2 files changed
+15 -2

No files matched your search

@@ -21,8 +21,20 @@ export function useExportTracker() {
const hasActive = computed(() => activeCount.value > 0);
function generateUUID() {
if (typeof crypto !== "undefined" && crypto.randomUUID) {
return crypto.randomUUID();
}
let buffer = new Uint8Array(16);
crypto.getRandomValues(buffer);
buffer[6] = (buffer[6] & 0x0f) | 0x40;
return Array.from(buffer, (b) => b.toString(16).padStart(2, "0"))
.join("")
.replace(/^(.{8})(.{4})(.{4})(.{4})(.{12})$/, "$1-$2-$3-$4-$5");
}
function addTask(tableName: string, format: "csv" | "xlsx", filePath: string): ExportTask {
const exportId = crypto.randomUUID();
const exportId = generateUUID();
const task = reactive<ExportTask>({
exportId,
tableName,