@tolgee/react 4.10.0-rc.a50bdc6.0 → 4.10.0-rc.acdda60.0
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/dist/T.d.ts +3 -2
- package/dist/TolgeeProvider.d.ts +1 -0
- package/dist/__integration/mockTranslations.d.ts +3 -0
- package/dist/tagsTools.d.ts +2 -1
- package/dist/tolgee-react.cjs.js +84 -26975
- package/dist/tolgee-react.cjs.js.map +1 -1
- package/dist/tolgee-react.cjs.min.js +1 -142
- package/dist/tolgee-react.cjs.min.js.map +1 -1
- package/dist/tolgee-react.esm.js +244 -0
- package/dist/tolgee-react.esm.js.map +1 -0
- package/dist/tolgee-react.esm.min.mjs +1 -142
- package/dist/tolgee-react.esm.min.mjs.map +1 -1
- package/dist/tolgee-react.umd.js +86 -26978
- package/dist/tolgee-react.umd.js.map +1 -1
- package/dist/tolgee-react.umd.min.js +1 -142
- package/dist/tolgee-react.umd.min.js.map +1 -1
- package/dist/useTranslateInternal.d.ts +2 -2
- package/lib/T.d.ts +3 -2
- package/lib/TolgeeProvider.d.ts +1 -0
- package/lib/tagsTools.d.ts +2 -1
- package/lib/useTranslateInternal.d.ts +2 -2
- package/package.json +7 -6
- package/dist/tolgee-react.esm.mjs +0 -27121
- package/dist/tolgee-react.esm.mjs.map +0 -1
- package/index.js +0 -7
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { TranslateProps,
|
|
1
|
+
import { TranslateProps, FallbackNsTranslation } from '@tolgee/web';
|
|
2
2
|
import { ReactOptions } from './types';
|
|
3
|
-
export declare const useTranslateInternal: (ns?:
|
|
3
|
+
export declare const useTranslateInternal: (ns?: FallbackNsTranslation, options?: ReactOptions) => {
|
|
4
4
|
t: (props: TranslateProps<any>) => any;
|
|
5
5
|
isLoading: boolean;
|
|
6
6
|
};
|
package/lib/T.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { NsType, TranslateParams } from '@tolgee/web';
|
|
2
2
|
import { FunctionComponent } from 'react';
|
|
3
3
|
import { ParamsTags } from './types';
|
|
4
4
|
declare type TProps = {
|
|
@@ -6,7 +6,8 @@ declare type TProps = {
|
|
|
6
6
|
children?: string;
|
|
7
7
|
noWrap?: boolean;
|
|
8
8
|
keyName?: string;
|
|
9
|
-
ns?:
|
|
9
|
+
ns?: NsType;
|
|
10
|
+
defaultValue?: string;
|
|
10
11
|
};
|
|
11
12
|
export declare const T: FunctionComponent<TProps>;
|
|
12
13
|
export {};
|
package/lib/TolgeeProvider.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ import { ReactOptions, TolgeeReactContext } from './types';
|
|
|
4
4
|
export declare const DEFAULT_REACT_OPTIONS: ReactOptions;
|
|
5
5
|
export declare const TolgeeProviderContext: React.Context<TolgeeReactContext | undefined>;
|
|
6
6
|
declare type Props = {
|
|
7
|
+
children?: React.ReactNode;
|
|
7
8
|
tolgee: TolgeeInstance;
|
|
8
9
|
options?: ReactOptions;
|
|
9
10
|
fallback?: React.ReactNode;
|
package/lib/tagsTools.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
+
import { TranslateParams } from '@tolgee/web';
|
|
1
2
|
import React from 'react';
|
|
2
3
|
import { ParamsTags } from './types';
|
|
3
|
-
export declare const wrapTagHandlers: (params: ParamsTags) => any;
|
|
4
|
+
export declare const wrapTagHandlers: (params: TranslateParams<ParamsTags> | undefined) => any;
|
|
4
5
|
export declare const addReactKeys: (val: React.ReactNode | React.ReactNode[] | undefined) => React.ReactNode;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { TranslateProps,
|
|
1
|
+
import { TranslateProps, FallbackNsTranslation } from '@tolgee/web';
|
|
2
2
|
import { ReactOptions } from './types';
|
|
3
|
-
export declare const useTranslateInternal: (ns?:
|
|
3
|
+
export declare const useTranslateInternal: (ns?: FallbackNsTranslation, options?: ReactOptions) => {
|
|
4
4
|
t: (props: TranslateProps<any>) => any;
|
|
5
5
|
isLoading: boolean;
|
|
6
6
|
};
|
package/package.json
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tolgee/react",
|
|
3
|
-
"version": "4.10.0-rc.
|
|
3
|
+
"version": "4.10.0-rc.acdda60.0",
|
|
4
4
|
"description": "React implementation for tolgee localization framework",
|
|
5
|
-
"main": "
|
|
5
|
+
"main": "./dist/tolgee-react.cjs.js",
|
|
6
|
+
"module": "./dist/tolgee-react.esm.js",
|
|
6
7
|
"types": "lib/index.d.ts",
|
|
7
8
|
"repository": "https://github.com/tolgee/tolgee-js",
|
|
8
9
|
"homepage": "https://tolgee.io",
|
|
@@ -36,7 +37,7 @@
|
|
|
36
37
|
"react": "^16.14.0 || ^17.0.1 || ^18.1.0"
|
|
37
38
|
},
|
|
38
39
|
"dependencies": {
|
|
39
|
-
"@tolgee/web": "
|
|
40
|
+
"@tolgee/web": "4.10.0-rc.acdda60.0"
|
|
40
41
|
},
|
|
41
42
|
"devDependencies": {
|
|
42
43
|
"@rollup/plugin-node-resolve": "^14.1.0",
|
|
@@ -44,7 +45,7 @@
|
|
|
44
45
|
"@testing-library/dom": "^8.7.2",
|
|
45
46
|
"@testing-library/jest-dom": "^5.11.4",
|
|
46
47
|
"@testing-library/react": "^12.1.2",
|
|
47
|
-
"@tolgee/format-icu": "
|
|
48
|
+
"@tolgee/format-icu": "4.10.0-rc.acdda60.0",
|
|
48
49
|
"@types/jest": "^27.0.2",
|
|
49
50
|
"@types/node": "^17.0.8",
|
|
50
51
|
"@types/react": "^17.0.1",
|
|
@@ -68,10 +69,10 @@
|
|
|
68
69
|
},
|
|
69
70
|
"exports": {
|
|
70
71
|
"require": "./dist/tolgee-react.cjs.js",
|
|
71
|
-
"import": "./dist/tolgee-react.esm.
|
|
72
|
+
"import": "./dist/tolgee-react.esm.js"
|
|
72
73
|
},
|
|
73
74
|
"publishConfig": {
|
|
74
75
|
"access": "public"
|
|
75
76
|
},
|
|
76
|
-
"gitHead": "
|
|
77
|
+
"gitHead": "8ea31e193640689a05bd60e6034d642fc238210f"
|
|
77
78
|
}
|