react-i18next 16.6.0 → 16.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -0
- package/TransWithoutContext.d.ts +5 -0
- package/dist/es/package.json +1 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
### 16.6.1
|
|
2
|
+
|
|
3
|
+
- feat(types): i18nKey of `<Trans i18nKey={sk} />` to accept a `SelectorKey` [2364](https://github.com/i18next/i18next/issues/2364)
|
|
4
|
+
|
|
1
5
|
### 16.6.0
|
|
2
6
|
|
|
3
7
|
- warn when `t` is called before `ready` with `useSuspense: false` [1896](https://github.com/i18next/react-i18next/issues/1896)
|
package/TransWithoutContext.d.ts
CHANGED
|
@@ -8,6 +8,7 @@ import type {
|
|
|
8
8
|
ParseKeys,
|
|
9
9
|
Namespace,
|
|
10
10
|
SelectorFn,
|
|
11
|
+
SelectorKey,
|
|
11
12
|
TFunctionReturn,
|
|
12
13
|
TypeOptions,
|
|
13
14
|
TOptions,
|
|
@@ -84,6 +85,7 @@ export interface TransSelectorProps<
|
|
|
84
85
|
}
|
|
85
86
|
|
|
86
87
|
export interface TransSelector {
|
|
88
|
+
// ── Selector function ──────────────────────────────────────────────────────
|
|
87
89
|
<
|
|
88
90
|
Target extends ConstrainTarget<TOpt>,
|
|
89
91
|
Key extends SelectorFn<GetSource<$NoInfer<Ns>, KPrefix>, ApplyTarget<Target, TOpt>, TOpt>,
|
|
@@ -95,6 +97,9 @@ export interface TransSelector {
|
|
|
95
97
|
>(
|
|
96
98
|
props: TransSelectorProps<Key, Ns, KPrefix, TContext, TOpt> & E,
|
|
97
99
|
): React.ReactElement;
|
|
100
|
+
|
|
101
|
+
// ── Pre-computed SelectorKey ────────────────────────────────────────────────
|
|
102
|
+
(props: TransSelectorProps<SelectorKey> & Record<string, any>): React.ReactElement;
|
|
98
103
|
}
|
|
99
104
|
|
|
100
105
|
export const Trans: _EnableSelector extends true | 'optimize' ? TransSelector : TransLegacy;
|
package/dist/es/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"type":"module","version":"16.6.
|
|
1
|
+
{"type":"module","version":"16.6.1"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-i18next",
|
|
3
|
-
"version": "16.6.
|
|
3
|
+
"version": "16.6.1",
|
|
4
4
|
"description": "Internationalization for react done right. Using the i18next i18n ecosystem.",
|
|
5
5
|
"main": "dist/commonjs/index.js",
|
|
6
6
|
"types": "./index.d.mts",
|
|
@@ -127,7 +127,7 @@
|
|
|
127
127
|
"eslint-plugin-testing-library": "^6.5.0",
|
|
128
128
|
"happy-dom": "^14.12.3",
|
|
129
129
|
"husky": "^9.1.7",
|
|
130
|
-
"i18next": "^25.10.
|
|
130
|
+
"i18next": "^25.10.4",
|
|
131
131
|
"lint-staged": "^16.4.0",
|
|
132
132
|
"mkdirp": "^3.0.1",
|
|
133
133
|
"prettier": "^3.8.1",
|