From 87a215102ac85ceae6f3f9fb969f4b49d29c1445 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 1 Dec 2023 04:39:47 +0000 Subject: [PATCH 1/2] Update dependency i18next to v23.7.7 --- yarn.lock | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/yarn.lock b/yarn.lock index a47a4b68..55da04cf 100644 --- a/yarn.lock +++ b/yarn.lock @@ -6042,11 +6042,11 @@ i18next-parser@^8.0.0: vue-template-compiler "^2.6.11" i18next@^23.0.0, i18next@^23.5.1: - version "23.6.0" - resolved "https://registry.yarnpkg.com/i18next/-/i18next-23.6.0.tgz#c6e996cfd3fef0bf60be3b7c581c35338dba5a71" - integrity sha512-z0Cxr0MGkt+kli306WS4nNNM++9cgt2b2VCMprY92j+AIab/oclgPxdwtTZVLP1zn5t5uo8M6uLsZmYrcjr3HA== + version "23.7.7" + resolved "https://registry.yarnpkg.com/i18next/-/i18next-23.7.7.tgz#e650ee962417186c5ba78bdaea3979abd31d3bfc" + integrity sha512-peTvdT+Lma+o0LfLFD7IC2M37N9DJ04dH0IJYOyOHRhDfLo6nK36v7LkrQH35C2l8NHiiXZqGirhKESlEb/5PA== dependencies: - "@babel/runtime" "^7.22.5" + "@babel/runtime" "^7.23.2" iconv-lite@0.6.3, iconv-lite@^0.6.3: version "0.6.3" From 97488a4787a7ab4569727b46a7fa161585e27fde Mon Sep 17 00:00:00 2001 From: Robin Date: Thu, 30 Nov 2023 23:47:26 -0500 Subject: [PATCH 2/2] Fix types --- src/TranslatedError.ts | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/TranslatedError.ts b/src/TranslatedError.ts index a9bd2e1d..b92880fc 100644 --- a/src/TranslatedError.ts +++ b/src/TranslatedError.ts @@ -14,10 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -import i18n from "i18next"; - -import type { ParseKeys, TFunction } from "i18next/typescript/t"; -import type { DefaultNamespace, TOptions } from "i18next/typescript/options"; +import type { DefaultNamespace, ParseKeys, TFunction, TOptions } from "i18next"; /** * An error with messages in both English and the user's preferred language. @@ -45,5 +42,5 @@ class TranslatedErrorImpl extends TranslatedError {} // function instead export const translatedError = ( messageKey: ParseKeys, - t: typeof i18n.t, + t: TFunction<"app", undefined>, ): TranslatedError => new TranslatedErrorImpl(messageKey, t);