@iobroker/adapter-react-v5 4.9.11 → 4.10.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/i18n.d.ts CHANGED
@@ -1,46 +1,37 @@
1
- export default I18n;
2
1
  /**
3
- * Copyright 2018-2023 Denis Haev (bluefox) <dogafox@gmail.com>
2
+ * Copyright 2018-2024 Denis Haev (bluefox) <dogafox@gmail.com>
4
3
  *
5
4
  * MIT License
6
5
  *
7
6
  ***/
7
+ declare global {
8
+ interface Window {
9
+ sysLang: ioBroker.Languages;
10
+ i18nShow: (filter: string | RegExp) => void;
11
+ i18nDisableWarning: (disable: boolean) => void;
12
+ }
13
+ }
14
+ type I18nWordDictionary = Record<ioBroker.Languages, string>;
15
+ type I18nWordsDictionary = Record<string, I18nWordDictionary>;
16
+ type I18nOneLanguageDictionary = Record<string, string>;
17
+ type I18nDictionary = {
18
+ [lang in ioBroker.Languages]?: I18nOneLanguageDictionary;
19
+ };
20
+ type I18nWordsWithPrefix = I18nDictionary & {
21
+ prefix?: string;
22
+ };
8
23
  /**
9
24
  * Translation string management.
10
25
  */
11
26
  declare class I18n {
12
- /**
13
- * List of all languages with their translations.
14
- * @type {{ [lang in ioBroker.Languages]?: Record<string, string>; }}
15
- */
16
- static translations: {
17
- en?: Record<string, string>;
18
- de?: Record<string, string>;
19
- ru?: Record<string, string>;
20
- pt?: Record<string, string>;
21
- nl?: Record<string, string>;
22
- fr?: Record<string, string>;
23
- it?: Record<string, string>;
24
- es?: Record<string, string>;
25
- pl?: Record<string, string>;
26
- uk?: Record<string, string>;
27
- "zh-cn"?: Record<string, string>;
28
- };
29
- /**
30
- * List of unknown translations during development.
31
- * @type {string[]}
32
- */
27
+ /** List of all languages with their translations. */
28
+ static translations: I18nDictionary;
29
+ /** List of unknown translations during development. */
33
30
  static unknownTranslations: string[];
34
- /**
35
- * The currently displayed language.
36
- * @type {ioBroker.Languages}
37
- */
31
+ /** The currently displayed language. */
38
32
  static lang: ioBroker.Languages;
39
33
  static _disableWarning: boolean;
40
- /**
41
- * Set the language to display.
42
- * @param {ioBroker.Languages} lang
43
- */
34
+ /** Set the language to display */
44
35
  static setLanguage(lang: ioBroker.Languages): void;
45
36
  /**
46
37
  * Add translations
@@ -50,45 +41,37 @@ declare class I18n {
50
41
  * @param {object} words additional words for specific language
51
42
  * @param {ioBroker.Languages} lang
52
43
  */
53
- static extendTranslations(words: object, lang: ioBroker.Languages): void;
44
+ static extendTranslations(words: I18nWordsWithPrefix | I18nOneLanguageDictionary | I18nWordsDictionary, lang?: ioBroker.Languages): void;
54
45
  /**
55
46
  * Sets all translations (in all languages).
56
47
  * @param {{ [lang in ioBroker.Languages]?: Record<string, string>; }} translations
57
48
  */
58
- static setTranslations(translations: {
59
- en?: Record<string, string>;
60
- de?: Record<string, string>;
61
- ru?: Record<string, string>;
62
- pt?: Record<string, string>;
63
- nl?: Record<string, string>;
64
- fr?: Record<string, string>;
65
- it?: Record<string, string>;
66
- es?: Record<string, string>;
67
- pl?: Record<string, string>;
68
- uk?: Record<string, string>;
69
- "zh-cn"?: Record<string, string>;
70
- }): void;
49
+ static setTranslations(translations: I18nDictionary): void;
71
50
  /**
72
51
  * Get the currently chosen language.
73
52
  * @returns {ioBroker.Languages} The current language.
74
53
  */
75
54
  static getLanguage(): ioBroker.Languages;
76
- /**
77
- * Translate the given string to the selected language.
78
- * @param {string} word The (key) word to look up the string.
79
- * @param {string[]} args Optional arguments which will replace the first (second, third, ...) occurrences of %s
80
- */
81
- static t(word: string, ...args: string[]): string;
55
+ /** Translate the given string to the selected language */
56
+ static t(
57
+ /** The (key) word to look up the string. */
58
+ word: string,
59
+ /** Optional arguments which will replace the first (second, third, ...) occurrences of %s */
60
+ ...args: any[]): string;
82
61
  /**
83
62
  * Show non-translated words
84
63
  * Required during development
85
- * @param {string | RegExp} filter filter words
86
64
  */
87
- static i18nShow(filter: string | RegExp): void;
65
+ static i18nShow(
66
+ /** The filter to apply to the list of non-translated words. */
67
+ filter?: string | RegExp): void;
88
68
  /**
89
69
  * Disable warning about non-translated words
90
70
  * Required during development
91
- * @param {boolean} disable Do the warning should be disabled
71
+ * @param {boolean} disable
92
72
  */
93
- static disableWarning(disable: boolean): void;
73
+ static disableWarning(
74
+ /** Whether to disable the warning. */
75
+ disable: boolean): void;
94
76
  }
77
+ export default I18n;
package/i18n.js CHANGED
@@ -1,40 +1,21 @@
1
1
  "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports["default"] = void 0;
8
- var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
9
- var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
10
- var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
11
- var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
12
2
  /**
13
- * Copyright 2018-2023 Denis Haev (bluefox) <dogafox@gmail.com>
3
+ * Copyright 2018-2024 Denis Haev (bluefox) <dogafox@gmail.com>
14
4
  *
15
5
  * MIT License
16
6
  *
17
7
  ***/
8
+ Object.defineProperty(exports, "__esModule", { value: true });
18
9
  /**
19
10
  * Translation string management.
20
11
  */
21
- var I18n = /*#__PURE__*/function () {
22
- function I18n() {
23
- (0, _classCallCheck2["default"])(this, I18n);
24
- }
25
- (0, _createClass2["default"])(I18n, null, [{
26
- key: "setLanguage",
27
- value:
28
- /**
29
- * Set the language to display.
30
- * @param {ioBroker.Languages} lang
31
- */
32
- function setLanguage(lang) {
33
- if (lang) {
34
- I18n.lang = lang;
35
- }
12
+ class I18n {
13
+ /** Set the language to display */
14
+ static setLanguage(lang) {
15
+ if (lang) {
16
+ I18n.lang = lang;
17
+ }
36
18
  }
37
-
38
19
  /**
39
20
  * Add translations
40
21
  * User can provide two types of structures:
@@ -43,197 +24,192 @@ var I18n = /*#__PURE__*/function () {
43
24
  * @param {object} words additional words for specific language
44
25
  * @param {ioBroker.Languages} lang
45
26
  */
46
- }, {
47
- key: "extendTranslations",
48
- value: function extendTranslations(words, lang) {
49
- // automatically extend all languages with prefix
50
- if (words.prefix) {
51
- if (typeof words.prefix === 'string') {
52
- var prefix = words.prefix;
53
- delete words.prefix;
54
- Object.keys(words).forEach(function (_lang) {
55
- var _words = {};
56
- Object.keys(words[_lang]).forEach(function (word) {
57
- if (!word) {
58
- return;
59
- }
60
- if (!word.startsWith(prefix)) {
61
- _words["".concat(prefix).concat(word)] = words[_lang][word];
62
- } else {
63
- _words[word] = words[_lang][word];
64
- }
65
- });
66
- words[_lang] = _words;
67
- });
68
- } else {
69
- console.warn('Found prefix in translations, but it is not a string');
27
+ static extendTranslations(words, lang) {
28
+ // automatically extend all languages with prefix
29
+ if (words.prefix) {
30
+ const wordsWithPrefix = words;
31
+ if (typeof wordsWithPrefix.prefix === 'string') {
32
+ const prefix = wordsWithPrefix.prefix;
33
+ delete wordsWithPrefix.prefix;
34
+ Object.keys(wordsWithPrefix).forEach(key => {
35
+ const _lang = key;
36
+ const _words = {};
37
+ const wordsOfOneLanguage = wordsWithPrefix[_lang];
38
+ Object.keys(wordsOfOneLanguage).forEach(word => {
39
+ if (!word) {
40
+ return;
41
+ }
42
+ if (wordsOfOneLanguage) {
43
+ if (!word.startsWith(prefix)) {
44
+ _words[`${prefix}${word}`] = wordsOfOneLanguage[word];
45
+ }
46
+ else {
47
+ _words[word] = wordsOfOneLanguage[word];
48
+ }
49
+ }
50
+ });
51
+ words[_lang] = _words;
52
+ });
53
+ }
54
+ else {
55
+ console.warn('Found prefix in translations, but it is not a string');
56
+ }
70
57
  }
71
- }
72
- try {
73
- if (!lang) {
74
- if (words.en && words.de && words.ru) {
75
- Object.keys(words).forEach(function (_lang) {
76
- I18n.translations[_lang] = I18n.translations[_lang] || {};
77
- Object.assign(I18n.translations[_lang], words[_lang]);
78
- });
79
- } else {
80
- Object.keys(words).forEach(function (word) {
81
- Object.keys(words[word]).forEach(function (_lang) {
82
- if (!I18n.translations[_lang]) {
83
- console.warn("Used unknown language: ".concat(_lang));
58
+ try {
59
+ if (!lang) {
60
+ // if it is a dictionary with all/many languages
61
+ if (words.en && words.de && words.ru) {
62
+ Object.keys(words).forEach(key => {
63
+ const _lang = key;
64
+ I18n.translations[_lang] = I18n.translations[_lang] || {};
65
+ const wordsOfOneLang = I18n.translations[_lang];
66
+ Object.assign(wordsOfOneLang, words[_lang]);
67
+ });
84
68
  }
85
- if (!I18n.translations[_lang][word]) {
86
- I18n.translations[_lang][word] = words[word][_lang];
87
- } else if (I18n.translations[_lang][word] !== words[word][_lang]) {
88
- console.warn("Translation for word \"".concat(word, "\" in \"").concat(_lang, "\" was ignored: existing = \"").concat(I18n.translations[_lang][word], "\", new = ").concat(words[word][_lang]));
69
+ else {
70
+ // It could be vice versa: words.word1 = {en: 'translated word1', de: 'übersetztes Wort2'}
71
+ Object.keys(words).forEach(word => {
72
+ const _word = words[word];
73
+ Object.keys(_word).forEach(key => {
74
+ const _lang = key;
75
+ const languageDictionary = I18n.translations[_lang];
76
+ if (!languageDictionary) {
77
+ console.warn(`Used unknown language: ${_lang}`);
78
+ }
79
+ else {
80
+ if (!languageDictionary[word]) {
81
+ languageDictionary[word] = _word[_lang];
82
+ }
83
+ else if (languageDictionary[word] !== _word[_lang]) {
84
+ console.warn(`Translation for word "${word}" in "${_lang}" was ignored: existing = "${languageDictionary[word]}", new = ${_word[_lang]}`);
85
+ }
86
+ }
87
+ });
88
+ });
89
89
  }
90
- });
91
- });
92
- }
93
- } else {
94
- if (!I18n.translations[lang]) {
95
- console.warn("Used unknown language: ".concat(lang));
96
- }
97
- I18n.translations[lang] = I18n.translations[lang] || {};
98
- Object.keys(words).forEach(function (word) {
99
- if (!I18n.translations[lang][word]) {
100
- I18n.translations[lang][word] = words[word];
101
- } else if (I18n.translations[lang][word] !== words[word]) {
102
- console.warn("Translation for word \"".concat(word, "\" in \"").concat(lang, "\" was ignored: existing = \"").concat(I18n.translations[lang][word], "\", new = ").concat(words[word]));
103
90
  }
104
- });
91
+ else {
92
+ // translations for one language
93
+ if (!I18n.translations[lang]) {
94
+ console.warn(`Used unknown language: ${lang}`);
95
+ }
96
+ I18n.translations[lang] = I18n.translations[lang] || {};
97
+ const languageDictionary = I18n.translations[lang];
98
+ if (languageDictionary) {
99
+ Object.keys(words)
100
+ .forEach(word => {
101
+ if (!languageDictionary[word]) {
102
+ languageDictionary[word] = words[word];
103
+ }
104
+ else if (languageDictionary[word] !== words[word]) {
105
+ console.warn(`Translation for word "${word}" in "${lang}" was ignored: existing = "${languageDictionary[word]}", new = ${words[word]}`);
106
+ }
107
+ });
108
+ }
109
+ }
110
+ }
111
+ catch (e) {
112
+ console.error(`Cannot apply translations: ${e}`);
105
113
  }
106
- } catch (e) {
107
- console.error("Cannot apply translations: ".concat(e));
108
- }
109
114
  }
110
-
111
115
  /**
112
116
  * Sets all translations (in all languages).
113
117
  * @param {{ [lang in ioBroker.Languages]?: Record<string, string>; }} translations
114
118
  */
115
- }, {
116
- key: "setTranslations",
117
- value: function setTranslations(translations) {
118
- if (translations) {
119
- I18n.translations = translations;
120
- }
119
+ static setTranslations(translations) {
120
+ if (translations) {
121
+ I18n.translations = translations;
122
+ }
121
123
  }
122
-
123
124
  /**
124
125
  * Get the currently chosen language.
125
126
  * @returns {ioBroker.Languages} The current language.
126
127
  */
127
- }, {
128
- key: "getLanguage",
129
- value: function getLanguage() {
130
- return I18n.lang;
128
+ static getLanguage() {
129
+ return I18n.lang;
131
130
  }
132
-
133
- /**
134
- * Translate the given string to the selected language.
135
- * @param {string} word The (key) word to look up the string.
136
- * @param {string[]} args Optional arguments which will replace the first (second, third, ...) occurrences of %s
137
- */
138
- }, {
139
- key: "t",
140
- value: function t(word) {
141
- var translation = I18n.translations[I18n.lang];
142
- if (translation) {
143
- var w = translation[word];
144
- if (w) {
145
- word = w;
146
- } else {
147
- if (!I18n.unknownTranslations.includes(word)) {
148
- I18n.unknownTranslations.push(word);
149
- !I18n._disableWarning && console.log("Translate: ".concat(word));
150
- }
151
- // fallback to english
152
- if (I18n.lang !== 'en' && I18n.translations.en) {
153
- var wordEn = I18n.translations.en[word];
154
- if (wordEn) {
155
- word = wordEn;
131
+ /** Translate the given string to the selected language */
132
+ static t(
133
+ /** The (key) word to look up the string. */
134
+ word,
135
+ /** Optional arguments which will replace the first (second, third, ...) occurrences of %s */
136
+ ...args) {
137
+ const translation = I18n.translations[I18n.lang];
138
+ if (translation) {
139
+ const w = translation[word];
140
+ if (w) {
141
+ word = w;
142
+ }
143
+ else {
144
+ if (!I18n.unknownTranslations.includes(word)) {
145
+ I18n.unknownTranslations.push(word);
146
+ !I18n._disableWarning && console.log(`Translate: ${word}`);
147
+ }
148
+ // fallback to english
149
+ if (I18n.lang !== 'en' && I18n.translations.en) {
150
+ const wordEn = I18n.translations.en[word];
151
+ if (wordEn) {
152
+ word = wordEn;
153
+ }
154
+ }
156
155
  }
157
- }
158
156
  }
159
- }
160
- for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
161
- args[_key - 1] = arguments[_key];
162
- }
163
- for (var _i = 0, _args = args; _i < _args.length; _i++) {
164
- var arg = _args[_i];
165
- word = word.replace('%s', arg);
166
- }
167
- return word;
157
+ for (const arg of args) {
158
+ word = word.replace('%s', arg);
159
+ }
160
+ return word;
168
161
  }
169
-
170
162
  /**
171
163
  * Show non-translated words
172
164
  * Required during development
173
- * @param {string | RegExp} filter filter words
174
165
  */
175
- }, {
176
- key: "i18nShow",
177
- value: function i18nShow(filter) {
178
- /**
179
- * List words with their translations.
180
- * @type {Record<string, string>}
181
- */
182
- var result = {};
183
- if (!filter) {
184
- I18n.unknownTranslations.forEach(function (word) {
185
- result[word] = word;
186
- });
187
- console.log(JSON.stringify(result, null, 2));
188
- } else if (typeof filter === 'string') {
189
- I18n.unknownTranslations.forEach(function (word) {
190
- if (word.startsWith(filter)) {
191
- result[word] = word.replace(filter, '');
192
- }
193
- });
194
- console.log(JSON.stringify(result, null, 2));
195
- } else if ((0, _typeof2["default"])(filter) === 'object') {
196
- I18n.unknownTranslations.forEach(function (word) {
197
- if (filter.test(word)) {
198
- result[word] = word;
199
- }
200
- });
201
- console.log(JSON.stringify(result, null, 2));
202
- }
166
+ static i18nShow(
167
+ /** The filter to apply to the list of non-translated words. */
168
+ filter) {
169
+ /** List words with their translations. */
170
+ const result = {};
171
+ if (!filter) {
172
+ I18n.unknownTranslations.forEach(word => result[word] = word);
173
+ console.log(JSON.stringify(result, null, 2));
174
+ }
175
+ else if (typeof filter === 'string') {
176
+ I18n.unknownTranslations.forEach(word => {
177
+ if (word.startsWith(filter)) {
178
+ result[word] = word.replace(filter, '');
179
+ }
180
+ });
181
+ console.log(JSON.stringify(result, null, 2));
182
+ }
183
+ else if (typeof filter === 'object') {
184
+ I18n.unknownTranslations.forEach(word => {
185
+ if (filter.test(word)) {
186
+ result[word] = word;
187
+ }
188
+ });
189
+ console.log(JSON.stringify(result, null, 2));
190
+ }
203
191
  }
204
-
205
192
  /**
206
193
  * Disable warning about non-translated words
207
194
  * Required during development
208
- * @param {boolean} disable Do the warning should be disabled
195
+ * @param {boolean} disable
209
196
  */
210
- }, {
211
- key: "disableWarning",
212
- value: function disableWarning(disable) {
213
- I18n._disableWarning = !!disable;
197
+ static disableWarning(
198
+ /** Whether to disable the warning. */
199
+ disable) {
200
+ I18n._disableWarning = !!disable;
214
201
  }
215
- }]);
216
- return I18n;
217
- }(); // install global handlers
218
- /**
219
- * List of all languages with their translations.
220
- * @type {{ [lang in ioBroker.Languages]?: Record<string, string>; }}
221
- */
222
- (0, _defineProperty2["default"])(I18n, "translations", {});
223
- /**
224
- * List of unknown translations during development.
225
- * @type {string[]}
226
- */
227
- (0, _defineProperty2["default"])(I18n, "unknownTranslations", []);
228
- /**
229
- * The currently displayed language.
230
- * @type {ioBroker.Languages}
231
- */
232
- (0, _defineProperty2["default"])(I18n, "lang", window.sysLang || 'en');
233
- (0, _defineProperty2["default"])(I18n, "_disableWarning", false);
202
+ }
203
+ /** List of all languages with their translations. */
204
+ I18n.translations = {};
205
+ /** List of unknown translations during development. */
206
+ I18n.unknownTranslations = [];
207
+ /** The currently displayed language. */
208
+ I18n.lang = window.sysLang || 'en';
209
+ I18n._disableWarning = false;
210
+ // install global handlers
234
211
  window.i18nShow = I18n.i18nShow;
235
212
  window.i18nDisableWarning = I18n.disableWarning;
236
-
237
213
  /*
238
214
  I18n.translations = {
239
215
  'en': require('./i18n/en'),
@@ -243,5 +219,4 @@ I18n.translations = {
243
219
  I18n.fallbacks = true;
244
220
  I18n.t = function () {};
245
221
  */
246
- var _default = exports["default"] = I18n;
247
- //# sourceMappingURL=i18n.js.map
222
+ exports.default = I18n;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iobroker/adapter-react-v5",
3
- "version": "4.9.11",
3
+ "version": "4.10.0",
4
4
  "description": "React classes to develop admin interfaces for ioBroker with react.",
5
5
  "author": {
6
6
  "name": "Denis Haev (bluefox)",
package/types.d.ts CHANGED
@@ -83,8 +83,10 @@ export interface GenericAppState {
83
83
  width: Width;
84
84
  }
85
85
 
86
- export type Width = ('xs' | 'sm' | 'md' | 'lg' | 'xl');
86
+ export type Width = 'xs' | 'sm' | 'md' | 'lg' | 'xl';
87
+
88
+ export type ThemeName = 'dark' | 'light' | 'colored' | 'blue' | 'PT' | 'DX';
87
89
 
88
90
  export interface Theme extends MuiTheme {
89
- name: string;
91
+ name: ThemeName;
90
92
  }
@@ -1 +0,0 @@
1
- {"version":3,"file":"404.js","names":["_react","_interopRequireWildcard","require","_styles","_i18n","_interopRequireDefault","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","_typeof","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","prototype","hasOwnProperty","call","i","set","_callSuper","o","_getPrototypeOf2","_possibleConstructorReturn2","_isNativeReflectConstruct","Reflect","construct","constructor","apply","Boolean","valueOf","ownKeys","keys","getOwnPropertySymbols","filter","enumerable","push","_objectSpread","arguments","length","forEach","_defineProperty2","getOwnPropertyDescriptors","defineProperties","styles","theme","content","background","position","top","bottom","left","right","root","boxSizing","height","width","backgroundColor","backgroundImage","fontFamily","fontSize","color","textShadow","overlay","pointerEvents","backgroundSize","zIndex","display","backgroundRepeat","animation","terminal","maxWidth","padding","textTransform","output","errorCode","Page404","_Component","_inherits2","_classCallCheck2","_createClass2","key","value","render","createElement","className","props","classes","I18n","Component","propTypes","_default","exports","withStyles"],"sources":["404.js"],"sourcesContent":["import React, { Component } from 'react';\nimport { withStyles } from '@mui/styles';\n\n/*\nCopyright 2019 Robin Selmer\nhttps://codepen.io/robinselmer/pen/vJjbOZ\n*/\n\nimport I18n from '../i18n';\n\nconst styles = theme => ({\n content: {\n background: 'black',\n position: 'absolute',\n top: 0,\n bottom: 0,\n left: 0,\n right: 0,\n ...theme.content,\n },\n root: {\n boxSizing: 'border-box',\n height: '100%',\n width: '100%',\n backgroundColor: '#000000',\n backgroundImage: 'radial-gradient(#104254 , #05181c)',\n fontFamily: \"'Inconsolata', Helvetica, sans-serif\",\n fontSize: '1.5rem',\n color: 'rgba(128, 175, 255, 0.8)',\n textShadow:\n `0 0 1ex rgba(51, 70, 255, 1),\n 0 0 2px rgba(255, 255, 255, 0.8)`,\n },\n overlay: {\n pointerEvents: 'none',\n width: '100%',\n height: '100%',\n background:\n `repeating-linear-gradient(\n 180deg,\n rgba(0, 0, 0, 0) 0,\n rgba(0, 0, 0, 0.3) 50%,\n rgba(0, 0, 0, 0) 100%)`,\n backgroundSize: 'auto 4px',\n zIndex: 99,\n '&::before': {\n content: '\"\"',\n pointerEvents: 'none',\n position: 'absolute',\n display: 'block',\n top: 0,\n left: 0,\n right: 0,\n bottom: 0,\n width: '100%',\n height: '100%',\n backgroundImage: `linear-gradient(\n 0deg,\n transparent 0%,\n rgba(32, 50, 128, 0.2) 2%,\n rgba(32, 50, 128, 0.8) 3%,\n rgba(32, 50, 128, 0.2) 3%,\n transparent 100%)`,\n backgroundRepeat: 'no-repeat',\n animation: 'scan 7.5s linear 0s infinite',\n },\n },\n\n terminal: {\n boxSizing: 'inherit',\n position: 'absolute',\n height: '100%',\n width: 'calc(100% - 8rem)',\n maxWidth: '100%',\n padding: '4rem',\n textTransform: 'uppercase',\n },\n output: {\n color: 'rgba(128, 175, 255, 0.8)',\n textShadow: `\n 0 0 1px rgba(51, 70, 255, 0.4),\n 0 0 2px rgba(255, 255, 255, 0.8)`,\n '&::before': {\n content: '\"> \"',\n },\n },\n errorCode: {\n color: 'white',\n },\n});\n\nclass Page404 extends Component {\n render() {\n return <div className={this.props.classes.content}>\n <div className={this.props.classes.root}>\n <div className={this.props.classes.overlay}>\n <div className={this.props.classes.terminal}>\n <h1>\n {I18n.t('ra_Error')}\n <span className={this.props.classes.errorCode}>404</span>\n </h1>\n <p className={this.props.classes.output}>\n {I18n.t('ra_The page you are looking for was not found')}\n </p>\n <p className={this.props.classes.output}>\n {I18n.t('ra_Good luck')}\n </p>\n </div>\n </div>\n </div>\n </div>;\n }\n}\n\nPage404.propTypes = {\n};\n\nexport default withStyles(styles)(Page404);\n"],"mappings":";;;;;;;;;;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,OAAA,GAAAD,OAAA;AAOA,IAAAE,KAAA,GAAAC,sBAAA,CAAAH,OAAA;AAA2B,SAAAI,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,yBAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAN,wBAAAM,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,IAAAA,CAAA,CAAAI,UAAA,SAAAJ,CAAA,eAAAA,CAAA,gBAAAK,OAAA,CAAAL,CAAA,0BAAAA,CAAA,sBAAAA,CAAA,QAAAG,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pB,CAAC;AAAC,IAAAC,QAAA,GAAAC,OAAA,cAEa,IAAAC,kBAAU,EAACjD,MAAM,CAAC,CAACgC,OAAO,CAAC","ignoreList":[]}
@@ -1 +0,0 @@
1
- {"version":3,"file":"Icon.js","names":["_react","_interopRequireDefault","require","_propTypes","_reactInlinesvg","_iconsMaterial","_IconAlias","_Utils","ownKeys","e","r","t","Object","keys","getOwnPropertySymbols","o","filter","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","arguments","length","forEach","_defineProperty2","getOwnPropertyDescriptors","defineProperties","defineProperty","_callSuper","_getPrototypeOf2","_possibleConstructorReturn2","_isNativeReflectConstruct","Reflect","construct","constructor","Boolean","prototype","valueOf","call","getSystemIcon","obj","icon","id","_id","startsWith","createElement","SettingsApplications","className","Photo","SupervisedUserCircle","PersonOutlined","Router","endsWith","Wifi","Info","type","Description","getSelectIdIcon","imagePrefix","src","common","cIcon","includes","instance","concat","name","split","Icon","_React$Component","_inherits2","_classCallCheck2","_createClass2","key","value","render","props","title","undefined","style","height","marginTop","styleUTF8","Utils","clsx","_this$props$style","_this$props$style2","_this$props$style3","width","alt","React","Component","propTypes","PropTypes","string","oneOfType","object","isRequired","_default","exports"],"sources":["Icon.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport SVG from 'react-inlinesvg';\n\nimport {\n SettingsApplications as IconSystem,\n Photo as IconPhoto,\n SupervisedUserCircle as IconGroup,\n PersonOutlined as IconUser,\n Router as IconHost,\n Wifi as IconConnection,\n Info as IconInfo,\n Description as IconMeta,\n} from '@mui/icons-material';\nimport IconAlias from '../icons/IconAlias';\n\nimport Utils from './Utils';\n\nexport function getSystemIcon(obj) {\n let icon;\n const id = obj?._id;\n\n if (!id) {\n return null;\n }\n\n // system or design has special icons\n if (id.startsWith('_design/') || (id === 'system')) {\n icon = <IconSystem className=\"iconOwn\" />;\n } else if (id === '0_userdata' || id === '0_userdata.0') {\n icon = <IconPhoto className=\"iconOwn\" />;\n } else if (id === 'alias' || id === 'alias.0') {\n icon = <IconAlias className=\"iconOwn\" />;\n } else if (id === 'system.adapter') {\n icon = <IconSystem className=\"iconOwn\" />;\n } else if (id === 'system.group') {\n icon = <IconGroup className=\"iconOwn\" />;\n } else if (id === 'system.user') {\n icon = <IconUser className=\"iconOwn\" />;\n } else if (id === 'system.host') {\n icon = <IconHost className=\"iconOwn\" />;\n } else if (id.endsWith('.connection') || id.endsWith('.connected')) {\n icon = <IconConnection className=\"iconOwn\" />;\n } else if (id.endsWith('.info')) {\n icon = <IconInfo className=\"iconOwn\" />;\n } else if (obj?.type === 'meta') {\n icon = <IconMeta className=\"iconOwn\" />;\n }\n\n return icon || null;\n}\n\nexport function getSelectIdIcon(obj, imagePrefix) {\n imagePrefix = imagePrefix || '.'; // http://localhost:8081';\n let src = '';\n const common = obj?.common;\n\n if (common) {\n const cIcon = common.icon;\n if (cIcon) {\n if (!cIcon.startsWith('data:image/')) {\n if (cIcon.includes('.')) {\n let instance;\n if (obj.type === 'instance' || obj.type === 'adapter') {\n src = `${imagePrefix}/adapter/${common.name}/${cIcon}`;\n } else if (obj._id && obj._id.startsWith('system.adapter.')) {\n instance = obj._id.split('.', 3);\n if (cIcon[0] === '/') {\n instance[2] += cIcon;\n } else {\n instance[2] += `/${cIcon}`;\n }\n src = `${imagePrefix}/adapter/${instance[2]}`;\n } else {\n instance = obj._id.split('.', 2);\n if (cIcon[0] === '/') {\n instance[0] += cIcon;\n } else {\n instance[0] += `/${cIcon}`;\n }\n src = `${imagePrefix}/adapter/${instance[0]}`;\n }\n } else {\n return null;\n }\n } else {\n // base 64 image\n src = cIcon;\n }\n }\n }\n\n return src || null;\n}\n\nclass Icon extends React.Component {\n render() {\n if (this.props.src) {\n if (typeof this.props.src === 'string') {\n if (this.props.src.length < 3) {\n // utf-8 char\n return <span\n title={this.props.title || undefined}\n style={{ height: 27, marginTop: -8, ...(this.props.styleUTF8 || this.props.style) }}\n className={Utils.clsx(this.props.className, 'iconOwn')}\n >\n {this.props.src}\n </span>;\n }\n if (this.props.src.startsWith('data:image/svg')) {\n return <SVG\n title={this.props.title || undefined}\n src={this.props.src}\n className={Utils.clsx(this.props.className, 'iconOwn')}\n width={this.props.style?.width || 28}\n height={this.props.style?.height || this.props.style?.width || 28}\n style={this.props.style || {}}\n />;\n }\n return <img\n title={this.props.title || undefined}\n style={this.props.style || {}}\n className={Utils.clsx(this.props.className, 'iconOwn')}\n src={this.props.src}\n alt=\"\"\n />;\n }\n return this.props.src;\n }\n return null;\n }\n}\n\nIcon.propTypes = {\n title: PropTypes.string,\n src: PropTypes.oneOfType([PropTypes.string, PropTypes.object]).isRequired,\n className: PropTypes.string,\n style: PropTypes.object,\n styleUTF8: PropTypes.object,\n};\n\nexport default Icon;\n"],"mappings":";;;;;;;;;;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,UAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,eAAA,GAAAH,sBAAA,CAAAC,OAAA;AAEA,IAAAG,cAAA,GAAAH,OAAA;AAUA,IAAAI,UAAA,GAAAL,sBAAA,CAAAC,OAAA;AAEA,IAAAK,MAAA,GAAAN,sBAAA,CAAAC,OAAA;AAA4B,SAAAM,QAAAC,CAAA,EAAAC,CAAA,QAAAC,CAAA,GAAAC,MAAA,CAAAC,IAAA,CAAAJ,CAAA,OAAAG,MAAA,CAAAE,qBAAA,QAAAC,CAAA,GAAAH,MAAA,CAAAE,qBAAA,CAAAL,CAAA,GAAAC,CAAA,KAAAK,CAAA,GAAAA,CAAA,CAAAC,MAAA,WAAAN,CAAA,WAAAE,MAAA,CAAAK,wBAAA,CAAAR,CAAA,EAAAC,CAAA,EAAAQ,UAAA,OAAAP,CAAA,CAAAQ,IAAA,CAAAC,KAAA,CAAAT,CAAA,EAAAI,CAAA,YAAAJ,CAAA;AAAA,SAAAU,cAAAZ,CAAA,aAAAC,CAAA,MAAAA,CAAA,GAAAY,SAAA,CAAAC,MAAA,EA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