agent: foundation — sync incremental changes from legacy codebase

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
jake
2026-03-21 10:50:32 +00:00
parent 387e7d7acc
commit 4c0fd0aeda
10 changed files with 22 additions and 15 deletions

View File

@@ -322,6 +322,7 @@
removeFillers: settings.removeFillers,
britishEnglish: settings.britishEnglish,
antiHallucination: settings.antiHallucination,
formatMode: settings.formatMode,
});
} else {
await invoke("transcribe_pcm", {

View File

@@ -124,7 +124,8 @@
if (!fileTranscript) return;
showExportMenu = false;
const content = exportTranscript(fileTranscript, segments, format);
const ext = format === "vtt" ? "vtt" : format === "srt" ? "srt" : format === "md" ? "md" : "txt";
const extMap = { vtt: "vtt", srt: "srt", md: "md", csv: "csv", html: "html" };
const ext = extMap[format] || "txt";
const blob = new Blob([content], { type: "text/plain" });
const url = URL.createObjectURL(blob);
const a = document.createElement("a");
@@ -230,7 +231,7 @@
>Export</button>
{#if showExportMenu}
<div class="absolute left-0 bottom-full mb-1 bg-bg-card border border-border rounded-lg shadow-lg py-1 z-10 animate-fade-in min-w-[120px]">
{#each [["txt", "Plain Text"], ["md", "Markdown"], ["srt", "SRT Subtitles"], ["vtt", "WebVTT"]] as [fmt, label]}
{#each [["txt", "Plain Text"], ["md", "Markdown"], ["csv", "CSV"], ["html", "HTML"], ["srt", "SRT Subtitles"], ["vtt", "WebVTT"]] as [fmt, label]}
<button
class="w-full text-left btn-md text-text-secondary hover:bg-hover hover:text-text"
onclick={() => handleExport(fmt)}

View File

@@ -35,6 +35,7 @@
);
function clearAll() {
if (!confirm("Delete all history? This can't be undone.")) return;
history.splice(0);
saveHistory();
expandedId = null;

View File

@@ -100,8 +100,9 @@
await invoke("download_model", { size });
downloadedModels = await invoke("list_models");
downloadingModel = "";
} catch {
} catch (err) {
downloadingModel = "";
engineStatus = typeof err === "string" ? err : "Download failed";
}
}
@@ -138,9 +139,9 @@
parakeetDownloaded = true;
parakeetDownloading = false;
parakeetStatus = "Downloaded (not loaded)";
} catch {
} catch (err) {
parakeetDownloading = false;
parakeetStatus = "Download failed";
parakeetStatus = typeof err === "string" ? err : "Download failed";
}
}

View File

@@ -454,7 +454,7 @@
<!-- Delete -->
<button
aria-label="Delete task"
class="mt-0.5 text-text-tertiary hover:text-danger opacity-0 group-hover:opacity-100 transition-opacity"
class="mt-0.5 text-text-tertiary hover:text-danger opacity-0 group-hover:opacity-100 focus:opacity-100 transition-opacity"
onclick={() => deleteTask(task.id)}
>
<svg class="w-4 h-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
@@ -499,7 +499,7 @@
</div>
<button
aria-label="Delete completed task"
class="mt-0.5 text-text-tertiary hover:text-danger opacity-0 group-hover:opacity-100 transition-opacity"
class="mt-0.5 text-text-tertiary hover:text-danger opacity-0 group-hover:opacity-100 focus:opacity-100 transition-opacity"
onclick={() => deleteTask(task.id)}
>
<svg class="w-4 h-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">