Releases: Stichoza/google-translate-php
Releases · Stichoza/google-translate-php
v5.3.0
v5.2.0
What's Changed
- Added ability to retrieve a list of supported languages by @a-drew in #211
- New extension dependency introduced (
ext-dom)
New Contributors
Full Changelog: v5.1.4...v5.2.0
v5.1.4
v5.1.3
- Preserving Parameters Feature: Introducing the
preserveParameters()method to preserve specific parameters during translation. Users can now retain placeholders like:nameor:countwithin localization files or templating engines, preventing their translation. Usage can be found in preserving parameters section of documentation. - #199. Thanks @kylemilloy 🎉
v5.1.0
As of v5.1.0 concrete exceptions are available in \Stichoza\GoogleTranslate\Exceptions namespace:
LargeTextExceptionIf the requested text is too large to translate.RateLimitExceptionIf Google has blocked you for excessive amount requests.TranslationRequestExceptionIf any other HTTP related error occurs during translation.TranslationDecodingExceptionIf the response JSON cannot be decoded.
All concrete exceptions are backwards compatible, so if you were using older versions, you won't have to update your code.
TranslationDecodingException extends UnexpectedValueException, while LargeTextException, RateLimitException and TranslationRequestException extend ErrorException that was used in older versions (<5.1.0) of this package.
Finally a good answer to #70
v5.0.1
Updated package to require PHP 8 as PHP 7.4 reached its end of life yesterday.
setOptions()method accepts only arrays, parameter is not nullable anymore. Likelihood of impact in low.- Updated PHPUnit and GuzzleHttp dependencies.
- All properties and parameters are typed.
- Various bugfixes and improvements.