Add auto-scroll, file dialog, and transcript editing
- Auto-scroll transcript to active segment during playback with smart pause when user manually scrolls (resumes after 3s) - Replace prompt() with native Tauri file dialog for audio/video import with file type filters - Add inline transcript editing via double-click with Enter to save, Esc to cancel, preserving original text for change tracking - Show "edited" badge on modified segments Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
<script lang="ts">
|
||||
import { invoke } from '@tauri-apps/api/core';
|
||||
import { open } from '@tauri-apps/plugin-dialog';
|
||||
import WaveformPlayer from '$lib/components/WaveformPlayer.svelte';
|
||||
import TranscriptEditor from '$lib/components/TranscriptEditor.svelte';
|
||||
import SpeakerManager from '$lib/components/SpeakerManager.svelte';
|
||||
@@ -20,8 +21,14 @@
|
||||
}
|
||||
|
||||
async function handleFileImport() {
|
||||
// For now, use a simple prompt — will be replaced with Tauri file dialog
|
||||
const filePath = prompt('Enter path to audio/video file:');
|
||||
const filePath = await open({
|
||||
multiple: false,
|
||||
filters: [{
|
||||
name: 'Audio/Video',
|
||||
extensions: ['mp3', 'wav', 'flac', 'ogg', 'm4a', 'aac', 'wma',
|
||||
'mp4', 'mkv', 'avi', 'mov', 'webm'],
|
||||
}],
|
||||
});
|
||||
if (!filePath) return;
|
||||
|
||||
// Convert file path to URL for wavesurfer
|
||||
|
||||
Reference in New Issue
Block a user