@trackunit/i18n-library-translation 1.3.51 → 1.3.53

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/index.cjs.js CHANGED
@@ -138,9 +138,9 @@ const useNamespaceTranslation = (namespace, options) => {
138
138
  }, [i18NextInstance, namespace, captureException, t]);
139
139
  // Replace t function with customT
140
140
  const updatedUseTranslation = react.useMemo(() => {
141
- customUseTranslation[0] = customT;
142
- customUseTranslation.t = customT;
143
- return customUseTranslation;
141
+ const result = [customT, customUseTranslation[1], customUseTranslation[2]];
142
+ Object.assign(result, { t: customT, i18n: customUseTranslation.i18n, ready: customUseTranslation.ready });
143
+ return result;
144
144
  }, [customUseTranslation, customT]);
145
145
  return updatedUseTranslation;
146
146
  };
package/index.esm.js CHANGED
@@ -136,9 +136,9 @@ const useNamespaceTranslation = (namespace, options) => {
136
136
  }, [i18NextInstance, namespace, captureException, t]);
137
137
  // Replace t function with customT
138
138
  const updatedUseTranslation = useMemo(() => {
139
- customUseTranslation[0] = customT;
140
- customUseTranslation.t = customT;
141
- return customUseTranslation;
139
+ const result = [customT, customUseTranslation[1], customUseTranslation[2]];
140
+ Object.assign(result, { t: customT, i18n: customUseTranslation.i18n, ready: customUseTranslation.ready });
141
+ return result;
142
142
  }, [customUseTranslation, customT]);
143
143
  return updatedUseTranslation;
144
144
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trackunit/i18n-library-translation",
3
- "version": "1.3.51",
3
+ "version": "1.3.53",
4
4
  "repository": "https://github.com/Trackunit/manager",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "engines": {
@@ -13,8 +13,8 @@
13
13
  "i18next": "21.10.0",
14
14
  "i18next-browser-languagedetector": "6.1.8",
15
15
  "i18next-resources-to-backend": "^1.1.4",
16
- "@trackunit/iris-app-api": "1.3.48",
17
- "@trackunit/react-core-hooks": "1.3.49"
16
+ "@trackunit/iris-app-api": "1.3.50",
17
+ "@trackunit/react-core-hooks": "1.3.51"
18
18
  },
19
19
  "module": "./index.esm.js",
20
20
  "main": "./index.cjs.js",