From 45032d54e3297b60b7b829c6a5fa4f26de9b37d8 Mon Sep 17 00:00:00 2001 From: Daniel Jones Date: Wed, 2 Aug 2023 11:05:25 +0200 Subject: [PATCH] fix: add Italian (it), Dutch (nl), Polish (pl), Portuguese (pt), Russian (ru) and Chinese (zh) to possible glossary language codes --- CHANGELOG.md | 6 ++++++ src/types.ts | 13 ++++++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 83885dd..01a164c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 * CI: silence npm audit warnings in non-production dependencies due to currently-unresolvable [vulnerability in semver <7.5.2](https://github.com/npm/node-semver/pull/564). * Increase axios dependency to >=1.2.2, due to [bug in axios v1.2.1](https://github.com/axios/axios/issues/5346). +* Added supported glossary languages: Italian (it), Dutch (nl), Polish (pl), + Portuguese (pt), Russian (ru) and Chinese (zh). The corresponding glossary + language code TypeScript types are extended. + + Note: older library versions also support the new glossary language pairs, + this update only adds new types. ## [1.10.2] - 2023-06-02 diff --git a/src/types.ts b/src/types.ts index 79260e2..abc1425 100644 --- a/src/types.ts +++ b/src/types.ts @@ -220,7 +220,18 @@ export type NonRegionalLanguageCode = CommonLanguageCode | 'en' | 'pt'; * Note: although the language code type definitions are case-sensitive, this package and the DeepL * API accept case-insensitive language codes. */ -export type SourceGlossaryLanguageCode = 'de' | 'en' | 'es' | 'fr' | 'ja'; +export type SourceGlossaryLanguageCode = + | 'de' + | 'en' + | 'es' + | 'fr' + | 'it' + | 'ja' + | 'nl' + | 'pl' + | 'pt' + | 'ru' + | 'zh'; /** * Language codes that may be used as a target language for glossaries.