feat(transcript): Clear button + actually delete persisted transcript#7
Merged
Conversation
Removing the video left the transcript behind: setDoc(null) only clears the in-memory doc and never deletes the persisted copy, so a refresh reloaded it — and with a doc present the model picker (EmptyState) stays hidden, so there was no way to re-pick a model and re-transcribe. - TranscriptStore.clearDoc(): nulls the doc AND deletes the persisted transcript for the active project (setDoc(null) is left untouched — undo/redo rides it) - transcript panel: a 'Clear' button in the toolbar resets status to idle and clears selection/search, returning to the model picker + Generate - tests: clearDoc nulls+notifies, and deletes the persisted transcript
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes: removing the video left the transcript behind, and there was no way to re-pick a model.
Cause:
setDoc(null)only clears the in-memory doc — it never deletes the persisted copy (deliberately, since undo/redo round-trips throughsetDoc). So on refresh the stored transcript reloaded, and while a doc exists the model picker (EmptyState) stays hidden — no way to re-transcribe.Fix:
TranscriptStore.clearDoc()— nulls the doc and deletes the persisted transcript for the active project (deleteTranscript({ projectId })).idle, clears selection/search → returns to the model picker + Generate.clearDocnulls+notifies, and deletes the persisted transcript (4 store tests, mocked storage).Verification:
tscclean; 42 tests pass.