Commit Graph
7 Commits
Author SHA1 Message Date
xixu-me 1076a5817f Remove Microsoft Translator integration and update docs
Eliminated Microsoft Translator support from the codebase, including its service implementation, API endpoint, and related tests. Updated both English and Chinese README files to reflect the removal and to clarify usage of DeepL and Google endpoints, providing improved examples and API documentation.
2025-08-09 18:41:49 +08:00
xixu-me e30b019cd2 Refactor Microsoft Translator integration and tests
Refactored the Microsoft Translator service to use a parameter object for translation requests, improved language code normalization, and enhanced error handling. Updated integration and unit tests to match the new API and moved Microsoft Translator unit tests to a new location under tests/lib/services. Removed the old test file and added more comprehensive test coverage for translation scenarios and error cases.
2025-08-09 18:18:36 +08:00
xixu-me bc8cc07e13 Refactor Microsoft Translator service and add tests
Refactored the Microsoft Translator integration to improve error handling, token acquisition, and API request structure. Added comprehensive unit tests for translation and service availability, covering success, error, and edge cases.
2025-08-09 17:17:43 +08:00
xixu-me c54500dc79 Add Google Translate provider and multi-provider support
Introduces a Google Translate integration with a new service module and endpoint (/google), refactors translation handling to support both DeepL and Google providers, and updates cache key generation to include the provider. Adds integration and unit tests for the new provider and updates API route definitions for clarity and extensibility.
2025-08-09 14:05:37 +08:00
xixu-me 8d875df84d Remove HTML content preservation utilities
Deleted htmlUtils module and its related tests. Removed all references to HTML preservation functions from index.ts and query.ts, simplifying the query logic and eliminating HTML-specific handling.
2025-07-27 15:07:02 +08:00
xixu-me c624aa9df7 Improve placeholder handling in HTML utils
Changed placeholder format to a unique string less likely to be altered by translation services and added zero-padding for consistency. Updated restoration logic to handle case-insensitive matching of placeholders. Added tests to verify correct restoration when placeholders are converted to lowercase.
2025-07-27 14:55:50 +08:00
xixu-me 8afa94767e Initial repository setup and core files added
Add configuration, documentation, code of conduct, contributing guide, license, and README files. Set up .gitignore, coverage config, GitHub issue templates, pull request template, and initial source code, scripts, and tests for DeepLX optimized for Cloudflare Workers.
2025-07-27 02:09:25 +08:00