@trackunit/react-core-hooks 0.2.156 → 0.2.157

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
@@ -586,6 +586,8 @@ const useCurrentUserLanguage = () => {
586
586
  throw new Error("useCurrentUserLanguage must be used within the CurrentUserPreferenceProvider");
587
587
  }
588
588
  return React.useMemo(() => {
589
+ // This is there to make sure that the language is set on the global object so Graphql can use it.
590
+ global.language = context.language;
589
591
  return {
590
592
  language: context.language,
591
593
  setLanguage: context.setLanguage,
package/index.esm.js CHANGED
@@ -560,6 +560,8 @@ const useCurrentUserLanguage = () => {
560
560
  throw new Error("useCurrentUserLanguage must be used within the CurrentUserPreferenceProvider");
561
561
  }
562
562
  return useMemo(() => {
563
+ // This is there to make sure that the language is set on the global object so Graphql can use it.
564
+ global.language = context.language;
563
565
  return {
564
566
  language: context.language,
565
567
  setLanguage: context.setLanguage,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trackunit/react-core-hooks",
3
- "version": "0.2.156",
3
+ "version": "0.2.157",
4
4
  "repository": "https://github.com/Trackunit/manager",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "engines": {