iobroker.javascript 8.9.2 → 9.0.1

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.
Files changed (154) hide show
  1. package/README.md +7 -3
  2. package/admin/assets/{createSvgIcon-BdRvDw53.js → createSvgIcon-BQT-7-GS.js} +1 -1
  3. package/admin/assets/{docs-6na4NFtj.js → docs-BrInh2Pn.js} +2 -2
  4. package/admin/assets/index-BzKS5vx-.js +1329 -0
  5. package/admin/assets/index-CfuHVX2B.js +193 -0
  6. package/admin/assets/index-CuCs5aLs.js +5 -0
  7. package/admin/assets/index-tExaxF69.js +930 -0
  8. package/admin/assets/inheritsLoose--KnFDOw1.js +36 -0
  9. package/admin/assets/{useTheme-Cl1QmYFL.js → useTheme-DF6qfrtI.js} +1 -1
  10. package/admin/custom/assets/{Components-ChpTW7sE.js → Components-D9kRsHNY.js} +1 -1
  11. package/admin/custom/assets/{DefaultPropsProvider-CHpMCMgA.js → DefaultPropsProvider-9qubdy-V.js} +2 -2
  12. package/admin/custom/assets/{FilledInput-CtcQVKyj.js → FilledInput-BpuM_GyB.js} +1 -1
  13. package/admin/custom/assets/Tabs-CvEv0KOT.js +138 -0
  14. package/admin/custom/assets/ThemeProvider-DZTpMR8n.js +29 -0
  15. package/admin/custom/assets/{createSvgIcon-C_vAELFU.js → createSvgIcon-BQThUM-f.js} +1 -1
  16. package/admin/custom/assets/hostInit-CrAs5YZS.js +1 -1
  17. package/admin/custom/assets/index-BXmu6lpn.js +904 -0
  18. package/admin/custom/assets/{index-DwsbskQy.js → index-DIWNdd4a.js} +1 -1
  19. package/admin/custom/assets/index-DZqbj5K4.js +55 -0
  20. package/admin/custom/assets/{index-D5apCzjJ.js → index-Dbe-II7_.js} +6 -6
  21. package/admin/custom/assets/index-sawv1cUe.js +1399 -0
  22. package/admin/custom/assets/{virtualExposes-BPncCdUy.js → virtualExposes-BMKIjWrE.js} +2 -2
  23. package/admin/custom/customComponents.js +2 -2
  24. package/admin/custom/i18n/de.json +29 -29
  25. package/admin/custom/i18n/es.json +29 -29
  26. package/admin/custom/i18n/fr.json +29 -29
  27. package/admin/custom/i18n/it.json +29 -29
  28. package/admin/custom/i18n/nl.json +29 -29
  29. package/admin/custom/i18n/pl.json +29 -29
  30. package/admin/custom/i18n/pt.json +29 -29
  31. package/admin/custom/i18n/ru.json +29 -29
  32. package/admin/custom/i18n/uk.json +29 -29
  33. package/admin/custom/i18n/zh-cn.json +29 -29
  34. package/admin/google-blockly/blockly_compressed.js +875 -887
  35. package/admin/google-blockly/blocks_compressed.js +38 -41
  36. package/admin/google-blockly/javascript_compressed.js +19 -54
  37. package/admin/google-blockly/media/delete-icon.svg +1 -0
  38. package/admin/google-blockly/media/foldout-icon.svg +1 -0
  39. package/admin/google-blockly/media/resize-handle.svg +3 -0
  40. package/admin/i18n/de.json +61 -0
  41. package/admin/i18n/en.json +61 -0
  42. package/admin/i18n/es.json +61 -0
  43. package/admin/i18n/fr.json +61 -0
  44. package/admin/i18n/it.json +61 -0
  45. package/admin/i18n/nl.json +61 -0
  46. package/admin/i18n/pl.json +61 -0
  47. package/admin/i18n/pt.json +61 -0
  48. package/admin/i18n/ru.json +61 -0
  49. package/admin/i18n/uk.json +61 -0
  50. package/admin/i18n/zh-cn.json +61 -0
  51. package/admin/jsonConfig.json +2 -0
  52. package/admin/mf-manifest.json +1 -1
  53. package/admin/remoteEntry.js +2 -2
  54. package/admin/tab.html +4 -4
  55. package/admin/vsFont/README.md +1 -1
  56. package/admin/vsFont/createJson.js +1 -1
  57. package/build-backend/lib/consts.js +346 -0
  58. package/build-backend/lib/consts.js.map +1 -0
  59. package/build-backend/lib/convert.js +120 -0
  60. package/build-backend/lib/convert.js.map +1 -0
  61. package/build-backend/lib/debug.js +163 -0
  62. package/build-backend/lib/debug.js.map +1 -0
  63. package/{lib → build-backend/lib}/debugger.js +261 -232
  64. package/build-backend/lib/debugger.js.map +1 -0
  65. package/build-backend/lib/eventObj.js +177 -0
  66. package/build-backend/lib/eventObj.js.map +1 -0
  67. package/build-backend/lib/inspect.js +728 -0
  68. package/build-backend/lib/inspect.js.map +1 -0
  69. package/build-backend/lib/javascript.d.ts +1972 -0
  70. package/{lib → build-backend/lib}/mirror.js +185 -182
  71. package/build-backend/lib/mirror.js.map +1 -0
  72. package/build-backend/lib/nodeModulesManagement.js +25 -0
  73. package/build-backend/lib/nodeModulesManagement.js.map +1 -0
  74. package/build-backend/lib/patternCompareFunctions.js +321 -0
  75. package/build-backend/lib/patternCompareFunctions.js.map +1 -0
  76. package/build-backend/lib/protectFs.js +477 -0
  77. package/build-backend/lib/protectFs.js.map +1 -0
  78. package/build-backend/lib/request.js +89 -0
  79. package/build-backend/lib/request.js.map +1 -0
  80. package/{lib → build-backend/lib}/sandbox.js +2046 -1852
  81. package/build-backend/lib/sandbox.js.map +1 -0
  82. package/build-backend/lib/scheduler.js +553 -0
  83. package/build-backend/lib/scheduler.js.map +1 -0
  84. package/build-backend/lib/tools.js +183 -0
  85. package/build-backend/lib/tools.js.map +1 -0
  86. package/build-backend/lib/typescriptSettings.js +39 -0
  87. package/build-backend/lib/typescriptSettings.js.map +1 -0
  88. package/build-backend/lib/typescriptTools.js +435 -0
  89. package/build-backend/lib/typescriptTools.js.map +1 -0
  90. package/build-backend/lib/utils.js +66 -0
  91. package/build-backend/lib/utils.js.map +1 -0
  92. package/{lib → build-backend/lib}/words.js +23 -30
  93. package/build-backend/lib/words.js.map +1 -0
  94. package/build-backend/main.js +2671 -0
  95. package/build-backend/main.js.map +1 -0
  96. package/build-backend/types.d.ts +742 -0
  97. package/docs/de/README.md +1 -1
  98. package/docs/en/README.md +1 -1
  99. package/docs/en/javascript.md +10 -6
  100. package/docs/en/upgrade-guide.md +5 -2
  101. package/docs/ru/README.md +1 -1
  102. package/install/installTypings.js +34 -47
  103. package/io-package.json +14 -14
  104. package/package.json +14 -14
  105. package/admin/assets/index-DCkkMRRa.js +0 -1335
  106. package/admin/assets/index-DJfSBoBB.js +0 -192
  107. package/admin/assets/index-DTiA4WdK.js +0 -930
  108. package/admin/assets/index-qABB1JVe.js +0 -5
  109. package/admin/assets/inheritsLoose-BW-3V39H.js +0 -36
  110. package/admin/custom/assets/Tabs-C1KOyWRi.js +0 -137
  111. package/admin/custom/assets/ThemeProvider-Buvx5nSd.js +0 -29
  112. package/admin/custom/assets/index-BGCRznKh.js +0 -904
  113. package/admin/custom/assets/index-DfBPYXqA.js +0 -55
  114. package/admin/custom/assets/index-jIr6kOLK.js +0 -1398
  115. package/admin/i18n/de/flat.txt +0 -427
  116. package/admin/i18n/de/translations.json +0 -429
  117. package/admin/i18n/en/flat.txt +0 -427
  118. package/admin/i18n/en/translations.json +0 -429
  119. package/admin/i18n/es/flat.txt +0 -427
  120. package/admin/i18n/es/translations.json +0 -429
  121. package/admin/i18n/flat.txt +0 -427
  122. package/admin/i18n/fr/flat.txt +0 -427
  123. package/admin/i18n/fr/translations.json +0 -429
  124. package/admin/i18n/it/flat.txt +0 -427
  125. package/admin/i18n/it/translations.json +0 -429
  126. package/admin/i18n/nl/flat.txt +0 -427
  127. package/admin/i18n/nl/translations.json +0 -429
  128. package/admin/i18n/pl/flat.txt +0 -427
  129. package/admin/i18n/pl/translations.json +0 -429
  130. package/admin/i18n/pt/flat.txt +0 -427
  131. package/admin/i18n/pt/translations.json +0 -429
  132. package/admin/i18n/ru/flat.txt +0 -427
  133. package/admin/i18n/ru/translations.json +0 -429
  134. package/admin/i18n/uk/flat.txt +0 -427
  135. package/admin/i18n/uk/translations.json +0 -429
  136. package/admin/i18n/zh-cn/flat.txt +0 -427
  137. package/admin/i18n/zh-cn/translations.json +0 -429
  138. package/lib/adapter-config.d.ts +0 -16
  139. package/lib/consts.js +0 -83
  140. package/lib/convert.js +0 -106
  141. package/lib/debug.js +0 -154
  142. package/lib/eventObj.js +0 -201
  143. package/lib/inspect.js +0 -688
  144. package/lib/javascript.d.ts +0 -1858
  145. package/lib/nodeModulesManagement.js +0 -26
  146. package/lib/patternCompareFunctions.js +0 -391
  147. package/lib/protectFs.js +0 -401
  148. package/lib/request.js +0 -72
  149. package/lib/scheduler.js +0 -447
  150. package/lib/tools.js +0 -192
  151. package/lib/typescriptSettings.js +0 -44
  152. package/lib/typescriptTools.js +0 -529
  153. package/lib/utils.js +0 -87
  154. package/main.js +0 -2653
package/docs/de/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ![Logo](../../admin/javascript.png)
1
+ <img src="../../admin/javascript.svg" alt="ioBroker.javascript" width="100" />
2
2
 
3
3
  # ioBroker.javascript
4
4
 
package/docs/en/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ![Logo](../../admin/javascript.png)
1
+ <img src="../../admin/javascript.svg" alt="ioBroker.javascript" width="100" />
2
2
 
3
3
  # ioBroker.javascript
4
4
 
@@ -1299,6 +1299,8 @@ formatTimeDiff(milliseconds, format);
1299
1299
  * ss, сс(cyrillic) - full seconds, e.g. "05"
1300
1300
  * s, с(cyrillic) - short seconds, e.g., "5"
1301
1301
 
1302
+ You can use escape charachter `\` to avoid the replacement. e.g. `DD \Day\s, h \hour\s, m \minute, ss \second\s`
1303
+
1302
1304
  #### Example
1303
1305
 
1304
1306
  ```js
@@ -1727,7 +1729,7 @@ Same as [wait](#wait)
1727
1729
 
1728
1730
  ### messageTo
1729
1731
  ```js
1730
- messageTo({ instance: 'instance', script: 'script.js.common.scriptName', message: 'messageName' }, data, {timeout: 1000}, result =>
1732
+ messageTo({ instance: 'instance', script: 'script.js.common.scriptName', message: 'messageName' }, data, { timeout: 1000 }, result =>
1731
1733
  log(JSON.stringify(result)));
1732
1734
  ```
1733
1735
 
@@ -1738,7 +1740,7 @@ Timeout for callback is 5 seconds by default.
1738
1740
  The target could be shorted to:
1739
1741
 
1740
1742
  ```js
1741
- messageTo('messageName', data, result => {
1743
+ messageTo('messageName', data, (result) => {
1742
1744
  log(JSON.stringify(result));
1743
1745
  });
1744
1746
  ```
@@ -1777,7 +1779,9 @@ onMessage('myTopic', async (data, callback) => {
1777
1779
  ### onMessage
1778
1780
  ```js
1779
1781
  onMessage('messageName', (data, callback) => {
1780
- log(`Received data: ${data}`); callback({ result: Date.now() });
1782
+ log(`Received data: ${data}`);
1783
+
1784
+ callback({ result: Date.now() });
1781
1785
  });
1782
1786
  ```
1783
1787
 
@@ -1808,7 +1812,7 @@ iob message javascript.0 toScript '{"script": "script.js.messagetest", "message"
1808
1812
  ```js
1809
1813
  const id = onMessage('messageName', (data, callback) => {
1810
1814
  log(data);
1811
- callback(Date.now());
1815
+ callback({ result: Date.now() });
1812
1816
  });
1813
1817
 
1814
1818
  // unsubscribe specific handler
@@ -1980,11 +1984,11 @@ httpPost(
1980
1984
  *Requires version >= 8.3.0*
1981
1985
 
1982
1986
  ```js
1983
- httpGet('https://raw.githubusercontent.com/ioBroker/ioBroker.javascript/master/admin/javascript.png', { responseType: 'arraybuffer' }, async (err, response) => {
1987
+ httpGet('https://raw.githubusercontent.com/ioBroker/ioBroker.javascript/master/admin/javascript.svg', { responseType: 'arraybuffer' }, async (err, response) => {
1984
1988
  if (err) {
1985
1989
  console.error(err);
1986
1990
  } else {
1987
- const tempFilePath = createTempFile('javascript.png', response.data);
1991
+ const tempFilePath = createTempFile('javascript.svg', response.data);
1988
1992
  console.log(`Saved to ${tempFilePath}`);
1989
1993
 
1990
1994
  // Use the new path in other scripts (e.g. sendTo)
@@ -14,12 +14,15 @@
14
14
 
15
15
  The script filesystem mirroring will store all source files of the Scripts in your file system and allows you to edit the files in your favorite script editor beside the web editor. All changes are synced in both directions.
16
16
 
17
- When enabling the script files ystem mirroring, please make sure to create a **dedicated new directory** and **do not** use an existing directory with other content. Please also make sure that no other script or process changes files in the provided directory to prevent access issues.
17
+ When enabling the script files system mirroring, please make sure to create a **dedicated new directory** and **do not** use an existing directory with other content.
18
+ Please also make sure that no other script or process changes files in the provided directory to prevent access issues.
18
19
  Any location needs to be writable by the "iobroker" user!
19
20
 
20
21
  ## request to httpGet
21
22
 
22
- **Since v8.0.0 of the JavaScript adapter** the `request` package is deprecated and the usage in your scripts will raise a warning. The JavaScript adpater needs to drop the package at some point. To make the migration as easy as possible, the sandbox provides new function to request HTTP ressources.
23
+ **Since v8.0.0 of the JavaScript adapter** the `request` package is deprecated and the usage in your scripts will raise a warning.
24
+ The JavaScript adapter needs to drop the package at some point.
25
+ To make the migration as easy as possible, the sandbox provides a new function to request HTTP resources.
23
26
 
24
27
  ### JavaScript
25
28
 
package/docs/ru/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ![Logo](../../admin/javascript.png)
1
+ <img src="../../admin/javascript.svg" alt="ioBroker.javascript" width="100" />
2
2
 
3
3
  # ioBroker.javascript
4
4
 
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- // The adapter includes typings for the lowest supported NodeJS version.
3
+ // The adapter includes typings for the lowest supported Node.js version.
4
4
  // This script updates them to the installed version
5
5
 
6
6
  const { spawn } = require('node:child_process');
@@ -16,29 +16,6 @@ function fail(reason) {
16
16
 
17
17
  // Find the latest version on npm
18
18
  console.log('Installing NodeJS typings...');
19
- npmCommand('view', ['@types/node', 'version'], {stdout: 'pipe', stderr: 'pipe'})
20
- .then(cmdResult => {
21
- if (cmdResult.exitCode !== 0) {
22
- return fail(cmdResult.stderr);
23
- }
24
- const latestVersion = semver.coerce(cmdResult.stdout).major;
25
- console.log(`latest @types: ${latestVersion}, installed node: ${installedNodeVersion}`);
26
- return semver.gt(`${installedNodeVersion}.0.0`, `${latestVersion}.0.0`)
27
- ? 'latest' // The installed version is too new, install latest
28
- : installedNodeVersion.toString()
29
- ;
30
- })
31
- .then(targetVersion => {
32
- // Install the desired version
33
- return npmCommand('i', [`@types/node@${targetVersion}`], {stdout: 'ignore', stderr: 'pipe'});
34
- })
35
- .then(cmdResult => {
36
- if (cmdResult.exitCode !== 0) {
37
- return fail(cmdResult.stderr);
38
- } else {
39
- process.exit(0);
40
- }
41
- });
42
19
 
43
20
  // TODO: the following code is copied from a js-controller fork
44
21
  // It should be moved to the core and referenced from there in a future version
@@ -60,7 +37,7 @@ npmCommand('view', ['@types/node', 'version'], {stdout: 'pipe', stderr: 'pipe'})
60
37
  */
61
38
 
62
39
  /**
63
- * Executes an npm command (e.g. install) and returns the exit code and (if requested) the stdout
40
+ * Executes a npm command (e.g., install) and returns the exit code and (if requested) the stdout
64
41
  * @param {string} command The npm command to execute
65
42
  * @param {string[]} [npmArgs] The command line arguments for the npm command
66
43
  * @param {Partial<NpmCommandOptions>} [options] (optional) Some options for the command execution
@@ -78,50 +55,39 @@ function npmCommand(command, npmArgs, options) {
78
55
  const npmBinary = /^win/.test(process.platform) ? 'npm.cmd' : 'npm';
79
56
  /** @type {import("child_process").SpawnOptions} */
80
57
  const spawnOptions = {
81
- stdio: [
82
- options.stdin || process.stdin,
83
- options.stdout || process.stdout,
84
- options.stderr || process.stderr,
85
- ],
58
+ stdio: [options.stdin || process.stdin, options.stdout || process.stdout, options.stderr || process.stderr],
86
59
  // @ts-ignore This option exists starting with NodeJS 8
87
60
  windowsHide: true,
88
61
  };
89
62
  if (options.cwd != null) spawnOptions.cwd = options.cwd;
90
63
 
91
64
  // Now execute the npm process and avoid throwing errors
92
- return new Promise((resolve) => {
65
+ return new Promise(resolve => {
93
66
  try {
94
67
  /** @type {string} */
95
68
  let bufferedStdout;
96
69
  /** @type {string} */
97
70
  let bufferedStderr;
98
- const cmd = spawn(npmBinary, [command].concat(npmArgs), spawnOptions)
99
- .on('close', (code, signal) => {
100
- resolve({
101
- exitCode: code,
102
- signal,
103
- stdout: bufferedStdout,
104
- stderr: bufferedStderr
105
- });
71
+ const cmd = spawn(npmBinary, [command].concat(npmArgs), spawnOptions).on('close', (code, signal) => {
72
+ resolve({
73
+ exitCode: code,
74
+ signal,
75
+ stdout: bufferedStdout,
76
+ stderr: bufferedStderr,
106
77
  });
78
+ });
107
79
  // Capture stdout/stderr if requested
108
80
  if (options.stdout === 'pipe') {
109
81
  bufferedStdout = '';
110
82
  cmd.stdout.on('data', chunk => {
111
- const buffer = Buffer.isBuffer(chunk)
112
- ? chunk
113
- : new Buffer(chunk, 'utf8')
114
- ;
83
+ const buffer = Buffer.isBuffer(chunk) ? chunk : new Buffer(chunk, 'utf8');
115
84
  bufferedStdout += buffer;
116
85
  });
117
86
  }
118
87
  if (options.stderr === 'pipe') {
119
88
  bufferedStderr = '';
120
89
  cmd.stderr.on('data', chunk => {
121
- const buffer = Buffer.isBuffer(chunk)
122
- ? chunk
123
- : new Buffer(chunk, 'utf8')
124
- ;
90
+ const buffer = Buffer.isBuffer(chunk) ? chunk : new Buffer(chunk, 'utf8');
125
91
  bufferedStderr += buffer;
126
92
  });
127
93
  }
@@ -130,3 +96,24 @@ function npmCommand(command, npmArgs, options) {
130
96
  }
131
97
  });
132
98
  }
99
+
100
+ npmCommand('view', ['@types/node', 'version'], { stdout: 'pipe', stderr: 'pipe' })
101
+ .then(cmdResult => {
102
+ if (cmdResult.exitCode !== 0) {
103
+ return fail(cmdResult.stderr);
104
+ }
105
+ const latestVersion = semver.coerce(cmdResult.stdout).major;
106
+ console.log(`latest @types: ${latestVersion}, installed node: ${installedNodeVersion}`);
107
+ return semver.gt(`${installedNodeVersion}.0.0`, `${latestVersion}.0.0`)
108
+ ? 'latest' // The installed version is too new, install latest
109
+ : installedNodeVersion.toString();
110
+ })
111
+ // Install the desired version
112
+ .then(targetVersion => npmCommand('i', [`@types/node@${targetVersion}`], { stdout: 'ignore', stderr: 'pipe' }))
113
+ .then(cmdResult => {
114
+ if (cmdResult.exitCode !== 0) {
115
+ fail(cmdResult.stderr);
116
+ } else {
117
+ process.exit(0);
118
+ }
119
+ });
package/io-package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "common": {
3
3
  "name": "javascript",
4
- "version": "8.9.2",
4
+ "version": "9.0.1",
5
5
  "blockedVersions": [
6
6
  "8.0.0",
7
7
  "8.0.1"
@@ -40,6 +40,19 @@
40
40
  "Matthias Kleine <info@haus-automatisierung.com>"
41
41
  ],
42
42
  "news": {
43
+ "9.0.1": {
44
+ "en": "Added possibility to escape chars in formatTimeDiff\nBack-end was migrated to TypeScript\nBreaking change: removed \"request\" module\nAdded prettier for scripts",
45
+ "de": "Zusätzliche Möglichkeit, Zeichen im Format zu entkommen TimeDiff\nBackend wurde zu TypeScript migriert\nBreaking change: entferntes Modul \"Request\"\nHinzugefügt schöner für Scripts",
46
+ "ru": "Добавлена возможность побега чаров в формате тайм-дифф\nBack-end был перенесен на TypeScript\nПереломное изменение: удален модуль «запрос»\nДобавлено красивее для сценариев",
47
+ "pt": "Adicionado possibilidade de escapar de chars em formato Ponto de vista\nO back-end foi migrado para TypeScript\nAlteração de ruptura: módulo de \"requisição\" removido\nAdicionado mais bonito para scripts",
48
+ "nl": "Toegevoegd mogelijkheid om te ontsnappen tekens in formaat TimeDiff\nBack-end is gemigreerd naar TypeScript\nBreaking change: verwijderd \"verzoek\" module\nMooier toegevoegd voor scripts",
49
+ "fr": "Ajout de la possibilité d'échapper aux caractères dans le format TimeDiff\nBack-end a été migré vers TypeScript\nChangement de rupture: supprimé module \"demande\"\nAjout de joli pour les scripts",
50
+ "it": "Aggiunta possibilità di sfuggire a chars in formato Orario\nBack-end è stato migrato a TypeScript\nCambiamento di rottura: rimosso modulo \"richiesta\"\nAggiunto più bello per gli script",
51
+ "es": "Añadido posibilidad de escapar de los charcos en formato TimeDiff\nBack-end fue migrado a TipoScript\nCambio de ruptura: módulo de \"requisición\" eliminado\nAñadido más alto para scripts",
52
+ "pl": "Dodano możliwość ucieczki znaków w formacie TimeDiff\nBack- end został przeniesiony do TypeScript\nZmiana: usunięty moduł \"request\"\nDodano ładniejsze dla skryptów",
53
+ "uk": "Додано можливість втекти chars у форматі Час\nBack-end був мігрований до TypeScript\nЗміна несправностей: видалений модуль \"запит\"\nДодано претtier для скриптів",
54
+ "zh-cn": "添加格式跳过字符的可能性 时间\n后端已迁移到类型脚本\n中断更改: 删除“ 请求” 模块\n为脚本添加更美的"
55
+ },
43
56
  "8.9.2": {
44
57
  "en": "Updated packages for GUI\nUsed TypeScript for an admin component",
45
58
  "de": "Aktualisierte Pakete für GUI\nGebrauchte TypeScript für eine Admin-Komponente",
@@ -117,19 +130,6 @@
117
130
  "pl": "zaktualizowane zależności",
118
131
  "uk": "оновлені залежності",
119
132
  "zh-cn": "更新的依赖关系"
120
- },
121
- "8.8.0": {
122
- "en": "Added option to register notifications via scripts\nFixed sendTo block with empty name list",
123
- "de": "Option hinzugefügt, um Benachrichtigungen über Skripte zu registrieren\nFester Versand Blockieren mit leerer Namensliste",
124
- "ru": "Добавлена возможность регистрации уведомлений через скрипты\nFixed send Заблокировать с пустым списком имен",
125
- "pt": "Opção adicionada para registrar notificações via scripts\nEnviar fixo Para bloquear com lista de nomes vazia",
126
- "nl": "Toegevoegd optie om meldingen te registreren via scripts\nVaste verzending Te blokkeren met lege naamlijst",
127
- "fr": "Ajout d'une option pour enregistrer les notifications via des scripts\nEnvoi fixe Pour bloquer avec la liste des noms vides",
128
- "it": "Aggiunta opzione per registrare le notifiche tramite script\nInviato fisso Per bloccare con l'elenco dei nomi vuoti",
129
- "es": "Opción agregada para registrar notificaciones a través de scripts\nEnvío fijo Para bloquear con lista de nombres vacía",
130
- "pl": "Dodano opcję rejestracji powiadomień za pomocą skryptów\nPoprawiono wysyłanie Blokowanie z pustą listą nazw",
131
- "uk": "Додано опцію для реєстрації повідомлень через скрипти\nВиправлена відправка Заблокувати список порожніх імен",
132
- "zh-cn": "添加通过脚本注册通知的选项\n固定发送 以空名称列表屏蔽"
133
133
  }
134
134
  },
135
135
  "platform": "Javascript/Node.js",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iobroker.javascript",
3
- "version": "8.9.2",
3
+ "version": "9.0.1",
4
4
  "description": "Rules Engine for ioBroker",
5
5
  "author": "bluefox <dogafox@gmail.com>",
6
6
  "contributors": [
@@ -43,18 +43,17 @@
43
43
  "dependencies": {
44
44
  "@iobroker/adapter-core": "^3.2.3",
45
45
  "@iobroker/types": "^7.0.7",
46
- "@types/node": "^22.10.10",
47
- "@types/request": "^2.48.12",
46
+ "@types/node": "^22.15.29",
48
47
  "axios": "^1.9.0",
49
48
  "jsonata": "^2.0.6",
50
49
  "jszip": "^3.10.1",
51
50
  "node-inspect": "^2.0.0",
52
51
  "node-schedule": "2.1.1",
52
+ "prettier": "^3.5.3",
53
53
  "promisify-child-process": "^4.1.2",
54
- "request": "^2.88.2",
55
- "semver": "^7.7.1",
54
+ "semver": "^7.7.2",
56
55
  "suncalc2": "^1.8.1",
57
- "typescript": "~5.7.3",
56
+ "typescript": "~5.8.3",
58
57
  "virtual-tsc": "^0.6.2",
59
58
  "wake_on_lan": "^1.0.0"
60
59
  },
@@ -64,8 +63,9 @@
64
63
  "@alcalzone/release-script-plugin-license": "^3.7.0",
65
64
  "@iobroker/adapter-dev": "^1.4.0",
66
65
  "@iobroker/build-tools": "^2.0.15",
67
- "@iobroker/eslint-config": "^2.0.1",
66
+ "@iobroker/eslint-config": "^2.0.2",
68
67
  "@iobroker/testing": "^5.0.4",
68
+ "@iobroker/plugin-sentry": "^2.0.4",
69
69
  "@iobroker/vis-2-widgets-react-dev": "^4.0.4",
70
70
  "@types/node-schedule": "^2.1.7",
71
71
  "@types/nodemailer": "^6.4.17",
@@ -77,15 +77,14 @@
77
77
  "bugs": {
78
78
  "url": "https://github.com/ioBroker/ioBroker.javascript/issues"
79
79
  },
80
- "main": "main.js",
80
+ "main": "build-backend/main.js",
81
81
  "files": [
82
82
  "admin/",
83
- "lib/",
83
+ "build-backend/",
84
84
  "docs/",
85
85
  "install/",
86
86
  "io-package.json",
87
87
  "LICENSE",
88
- "main.js",
89
88
  "admin/vsFont/codicon.json"
90
89
  ],
91
90
  "scripts": {
@@ -94,12 +93,13 @@
94
93
  "test": "npm run test:declarations && npm run test:javascript",
95
94
  "translate": "translate-adapter",
96
95
  "//postinstall": "node ./install/installTypings.js",
97
- "build": "node tasks",
96
+ "build": "npm run build-backend && node tasks",
97
+ "build-backend": "tsc -p tsconfig.build.json",
98
98
  "release": "release-script --noPush -y --all",
99
- "update-packages": "ncu --upgrade && cd src && ncu --upgrade && cd ../src-admin && ncu --upgrade",
100
- "npm": "npm i && cd src-editor && npm i -f && cd ../src-admin && npm i -f",
99
+ "update-packages": "npx -y npm-check-updates --upgrade && cd src-editor && npx -y npm-check-updates --upgrade && cd ../src-admin && npx -y npm-check-updates --upgrade",
100
+ "npm": "npm i && cd src-editor && npm i -f && cd ../src-admin && npm i",
101
101
  "lint": "eslint -c eslint.config.mjs",
102
- "lint-all": "eslint -c eslint.config.mjs && cd src && eslint -c eslint.config.mjs && cd ../src-admin && eslint -c eslint.config.mjs",
102
+ "lint-all": "eslint -c eslint.config.mjs && cd src-editor && eslint -c eslint.config.mjs && cd ../src-admin && eslint -c eslint.config.mjs",
103
103
  "admin-0-clean": "node tasks.js --admin-0-clean",
104
104
  "admin-1-npm": "node tasks.js --admin-1-npm",
105
105
  "admin-2-compile": "node tasks.js --admin-2-compile",