├── .gitignore ├── AGENTS.md ├── CLAUDE.md ├── DEVLOG.md ├── README.md ├── SETUP.md ├── assets └── react.svg ├── bun.lock ├── context ├── chrome-ai-translator.txt ├── chrome-lang-detection.txt ├── dom-element-split.txt ├── gpt-5-review-1.txt └── translator-spec.txt ├── entrypoints ├── background.ts ├── content.ts ├── popup │ ├── App.css │ ├── App.tsx │ ├── index.html │ ├── main.tsx │ └── style.css └── translator │ ├── TranslatorApp.tsx │ ├── index.html │ ├── main.tsx │ └── style.css ├── lib ├── __tests__ │ ├── dom-translator.test.ts │ ├── example-react.test.tsx │ └── text-segmenter.test.ts ├── dom-translator.ts ├── language-detector.ts ├── storage.ts └── text-segmenter.ts ├── package.json ├── public └── wxt.svg ├── test-language-detection.html ├── tests └── setup.ts ├── tsconfig.json ├── types ├── chrome-translation.d.ts └── test-globals.d.ts ├── vitest.config.ts ├── vitest.setup.ts └── wxt.config.ts /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/.gitignore -------------------------------------------------------------------------------- /AGENTS.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/AGENTS.md -------------------------------------------------------------------------------- /CLAUDE.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/CLAUDE.md -------------------------------------------------------------------------------- /DEVLOG.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/DEVLOG.md -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/README.md -------------------------------------------------------------------------------- /SETUP.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/SETUP.md -------------------------------------------------------------------------------- /assets/react.svg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/assets/react.svg -------------------------------------------------------------------------------- /bun.lock: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/bun.lock -------------------------------------------------------------------------------- /context/chrome-ai-translator.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/context/chrome-ai-translator.txt -------------------------------------------------------------------------------- /context/chrome-lang-detection.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/context/chrome-lang-detection.txt -------------------------------------------------------------------------------- /context/dom-element-split.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/context/dom-element-split.txt -------------------------------------------------------------------------------- /context/gpt-5-review-1.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/context/gpt-5-review-1.txt -------------------------------------------------------------------------------- /context/translator-spec.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/context/translator-spec.txt -------------------------------------------------------------------------------- /entrypoints/background.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/background.ts -------------------------------------------------------------------------------- /entrypoints/content.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/content.ts -------------------------------------------------------------------------------- /entrypoints/popup/App.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/popup/App.css -------------------------------------------------------------------------------- /entrypoints/popup/App.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/popup/App.tsx -------------------------------------------------------------------------------- /entrypoints/popup/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/popup/index.html -------------------------------------------------------------------------------- /entrypoints/popup/main.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/popup/main.tsx -------------------------------------------------------------------------------- /entrypoints/popup/style.css: -------------------------------------------------------------------------------- 1 | @import "tailwindcss"; -------------------------------------------------------------------------------- /entrypoints/translator/TranslatorApp.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/translator/TranslatorApp.tsx -------------------------------------------------------------------------------- /entrypoints/translator/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/translator/index.html -------------------------------------------------------------------------------- /entrypoints/translator/main.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/entrypoints/translator/main.tsx -------------------------------------------------------------------------------- /entrypoints/translator/style.css: -------------------------------------------------------------------------------- 1 | @import 'tailwindcss'; -------------------------------------------------------------------------------- /lib/__tests__/dom-translator.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/lib/__tests__/dom-translator.test.ts -------------------------------------------------------------------------------- /lib/__tests__/example-react.test.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/lib/__tests__/example-react.test.tsx -------------------------------------------------------------------------------- /lib/__tests__/text-segmenter.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/lib/__tests__/text-segmenter.test.ts -------------------------------------------------------------------------------- /lib/dom-translator.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/lib/dom-translator.ts -------------------------------------------------------------------------------- /lib/language-detector.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/lib/language-detector.ts -------------------------------------------------------------------------------- /lib/storage.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/lib/storage.ts -------------------------------------------------------------------------------- /lib/text-segmenter.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/lib/text-segmenter.ts -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/package.json -------------------------------------------------------------------------------- /public/wxt.svg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/public/wxt.svg -------------------------------------------------------------------------------- /test-language-detection.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/test-language-detection.html -------------------------------------------------------------------------------- /tests/setup.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/tests/setup.ts -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/tsconfig.json -------------------------------------------------------------------------------- /types/chrome-translation.d.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/types/chrome-translation.d.ts -------------------------------------------------------------------------------- /types/test-globals.d.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/types/test-globals.d.ts -------------------------------------------------------------------------------- /vitest.config.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/vitest.config.ts -------------------------------------------------------------------------------- /vitest.setup.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/vitest.setup.ts -------------------------------------------------------------------------------- /wxt.config.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kaichen/local-translator/HEAD/wxt.config.ts --------------------------------------------------------------------------------