Skip to content

feat: bulk dictionary import via paste or file upload#461

Open
NathanSkene wants to merge 1 commit intoOpenWhispr:mainfrom
NathanSkene:feature/bulk-dictionary-import
Open

feat: bulk dictionary import via paste or file upload#461
NathanSkene wants to merge 1 commit intoOpenWhispr:mainfrom
NathanSkene:feature/bulk-dictionary-import

Conversation

@NathanSkene
Copy link

Summary

  • Adds "Import" button to the Custom Dictionary view (both empty and populated states)
  • Opens a dialog with a textarea for pasting words and a file upload button (.txt, .csv, .json)
  • Live preview shows new word count and duplicate count before confirming
  • Parses input by splitting on newlines, commas, and tabs to handle all common list formats
  • Adds i18n translation keys for all new UI strings (English; other locales use fallback defaults)

Closes #460

Test plan

  • Open Settings → Custom Dictionary (empty state) → verify "Import" link appears below example tags
  • Click Import → paste multi-line words → verify preview shows correct counts → confirm adds words
  • Click Import → upload a .txt file with one word per line → verify words are parsed and added
  • Click Import → upload a .json file with a string array → verify words are parsed and added
  • Verify duplicate words are skipped (add some words first, then import a list containing some of them)
  • Verify words persist after closing and reopening the app (localStorage + SQLite sync)
  • Verify Import button also appears in the populated state (next to "Clear all")
  • Verify Cancel button closes dialog without adding words

🤖 Generated with Claude Code

Adds an "Import" button to the Custom Dictionary view that opens a dialog
where users can paste words (one per line, comma, or tab separated) or
upload a .txt/.csv/.json file. Shows a live preview of new vs duplicate
word counts before confirming. Useful for domain-specific vocabularies
(scientific terms, medical jargon, etc.) where adding words one at a time
is impractical.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature request: Bulk dictionary import (paste/file upload)

1 participant