@tramvai/react 1.95.1 → 1.95.2

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/lib/react.es.js CHANGED
@@ -12,11 +12,11 @@ const useDiContainer = () => {
12
12
  const di = useContext(DIContext);
13
13
  if (!di) {
14
14
  if (process.env.NODE_ENV !== 'production') {
15
- throw new Error(`DI-контейнер не найден, убедитесь что в приложении используется 'DIContext.Provider' из '@tramvai/react'
16
- (в tramvai-приложении это обычно делает '@tramvai/module-render', иначе где-то явно должен определяться 'DIContext.Provider' из '@tramvai/react')
17
- Если выше верно, убедитесь, что модуль '@tramvai/react' не дублируется в зависимостях приложения, т.к. в этом случае версии di будут несовместимы`);
15
+ throw new Error(`DI container not found, make sure that the application uses 'DIContext.Provider' from '@tramvai/react'
16
+ (in a tramvai application this is usually done by '@tramvai/module-render', otherwise 'DIContext.Provider' from '@tramvai/react' must be explicitly defined somewhere)
17
+ If the above is correct, make sure that the '@tramvai/react' module is not duplicated in the application dependencies, because then the di versions would be incompatible`);
18
18
  }
19
- throw new Error('DI-контейнер не найден');
19
+ throw new Error('DI container not found');
20
20
  }
21
21
  return di;
22
22
  };
@@ -53,14 +53,14 @@ const FallbackError = () => {
53
53
  fontSize: 30,
54
54
  lineHeight: '36px',
55
55
  fontWeight: 200,
56
- } }, { children: "\u0412\u043E\u0437\u043D\u0438\u043A\u043B\u0430 \u043E\u0448\u0438\u0431\u043A\u0430 :(" }), void 0),
56
+ } }, { children: "An error occurred :(" }), void 0),
57
57
  jsxs("div", Object.assign({ style: {
58
58
  textAlign: 'center',
59
59
  marginBottom: 17,
60
60
  color: '#9299a2',
61
61
  fontSize: 20,
62
62
  lineHeight: '24px',
63
- } }, { children: ["\u041F\u043E\u043F\u0440\u043E\u0431\u0443\u0439\u0442\u0435", ' ', jsx("a", Object.assign({ href: "", onClick: () => window.location.reload() }, { children: "\u043F\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0443" }), void 0)] }), void 0)] }, void 0));
63
+ } }, { children: ["Try", ' ', jsx("a", Object.assign({ href: "", onClick: () => window.location.reload() }, { children: "reloading the page" }), void 0)] }), void 0)] }, void 0));
64
64
  };
65
65
  FallbackError.displayName = 'FallbackError';
66
66
 
package/lib/react.js CHANGED
@@ -22,11 +22,11 @@ const useDiContainer = () => {
22
22
  const di = react.useContext(DIContext);
23
23
  if (!di) {
24
24
  if (process.env.NODE_ENV !== 'production') {
25
- throw new Error(`DI-контейнер не найден, убедитесь что в приложении используется 'DIContext.Provider' из '@tramvai/react'
26
- (в tramvai-приложении это обычно делает '@tramvai/module-render', иначе где-то явно должен определяться 'DIContext.Provider' из '@tramvai/react')
27
- Если выше верно, убедитесь, что модуль '@tramvai/react' не дублируется в зависимостях приложения, т.к. в этом случае версии di будут несовместимы`);
25
+ throw new Error(`DI container not found, make sure that the application uses 'DIContext.Provider' from '@tramvai/react'
26
+ (in a tramvai application this is usually done by '@tramvai/module-render', otherwise 'DIContext.Provider' from '@tramvai/react' must be explicitly defined somewhere)
27
+ If the above is correct, make sure that the '@tramvai/react' module is not duplicated in the application dependencies, because then the di versions would be incompatible`);
28
28
  }
29
- throw new Error('DI-контейнер не найден');
29
+ throw new Error('DI container not found');
30
30
  }
31
31
  return di;
32
32
  };
@@ -63,14 +63,14 @@ const FallbackError = () => {
63
63
  fontSize: 30,
64
64
  lineHeight: '36px',
65
65
  fontWeight: 200,
66
- } }, { children: "\u0412\u043E\u0437\u043D\u0438\u043A\u043B\u0430 \u043E\u0448\u0438\u0431\u043A\u0430 :(" }), void 0),
66
+ } }, { children: "An error occurred :(" }), void 0),
67
67
  jsxRuntime.jsxs("div", Object.assign({ style: {
68
68
  textAlign: 'center',
69
69
  marginBottom: 17,
70
70
  color: '#9299a2',
71
71
  fontSize: 20,
72
72
  lineHeight: '24px',
73
- } }, { children: ["\u041F\u043E\u043F\u0440\u043E\u0431\u0443\u0439\u0442\u0435", ' ', jsxRuntime.jsx("a", Object.assign({ href: "", onClick: () => window.location.reload() }, { children: "\u043F\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044C \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0443" }), void 0)] }), void 0)] }, void 0));
73
+ } }, { children: ["Try", ' ', jsxRuntime.jsx("a", Object.assign({ href: "", onClick: () => window.location.reload() }, { children: "reloading the page" }), void 0)] }), void 0)] }, void 0));
74
74
  };
75
75
  FallbackError.displayName = 'FallbackError';
76
76
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tramvai/react",
3
- "version": "1.95.1",
3
+ "version": "1.95.2",
4
4
  "description": "",
5
5
  "main": "lib/react.js",
6
6
  "typings": "lib/react.d.ts",
@@ -26,7 +26,7 @@
26
26
  "@tinkoff/dippy": "0.7.39",
27
27
  "@tinkoff/utils": "^2.1.2",
28
28
  "@tinkoff/url": "0.7.37",
29
- "@tramvai/core": "1.95.1",
29
+ "@tramvai/core": "1.95.2",
30
30
  "react": ">=16.8.0",
31
31
  "react-dom": ">=16.8.0",
32
32
  "tslib": "^2.0.3"