@iobroker/json-config 8.4.1 → 8.4.4

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 (30) hide show
  1. package/README.md +6 -0
  2. package/build/JsonConfigComponent/ConfigCertCollection.js +1 -1
  3. package/build/JsonConfigComponent/ConfigCertCollection.js.map +1 -1
  4. package/build/JsonConfigComponent/ConfigCertificates.js +1 -1
  5. package/build/JsonConfigComponent/ConfigCertificates.js.map +1 -1
  6. package/build/JsonConfigComponent/ConfigCheckLicense.js +5 -5
  7. package/build/JsonConfigComponent/ConfigCheckLicense.js.map +1 -1
  8. package/build/JsonConfigComponent/ConfigCoordinates.js +1 -1
  9. package/build/JsonConfigComponent/ConfigCoordinates.js.map +1 -1
  10. package/build/JsonConfigComponent/ConfigGeneric.d.ts +1 -0
  11. package/build/JsonConfigComponent/ConfigGeneric.js +7 -0
  12. package/build/JsonConfigComponent/ConfigGeneric.js.map +1 -1
  13. package/build/JsonConfigComponent/ConfigObjectId.js +1 -1
  14. package/build/JsonConfigComponent/ConfigObjectId.js.map +1 -1
  15. package/build/JsonConfigComponent/ConfigPort.js +1 -1
  16. package/build/JsonConfigComponent/ConfigPort.js.map +1 -1
  17. package/build/JsonConfigComponent/ConfigSelect.js +4 -4
  18. package/build/JsonConfigComponent/ConfigSelect.js.map +1 -1
  19. package/build/JsonConfigComponent/ConfigSendto.js +2 -2
  20. package/build/JsonConfigComponent/ConfigSendto.js.map +1 -1
  21. package/build/JsonConfigComponent/ConfigSetState.js +1 -1
  22. package/build/JsonConfigComponent/ConfigSetState.js.map +1 -1
  23. package/build/JsonConfigComponent/ConfigState.js +1 -1
  24. package/build/JsonConfigComponent/ConfigState.js.map +1 -1
  25. package/build/JsonConfigComponent/ConfigTable.js +1 -1
  26. package/build/JsonConfigComponent/ConfigTable.js.map +1 -1
  27. package/build/JsonConfigComponent/ConfigUUID.js +1 -1
  28. package/build/JsonConfigComponent/ConfigUUID.js.map +1 -1
  29. package/build/types.d.ts +1 -1
  30. package/package.json +1 -1
@@ -6,7 +6,7 @@ import ConfigGeneric from './ConfigGeneric';
6
6
  export default class ConfigUUID extends ConfigGeneric {
7
7
  async componentDidMount() {
8
8
  await super.componentDidMount();
9
- const uuidObj = await this.props.oContext.getCachedObject('system.meta.uuid');
9
+ const uuidObj = await this.getCachedObject('system.meta.uuid');
10
10
  this.setState({ uuid: uuidObj?.native?.uuid || 'unknown' });
11
11
  }
12
12
  renderItem(error, disabled) {
@@ -1 +1 @@
1
- {"version":3,"file":"ConfigUUID.js","sourceRoot":"./src/","sources":["JsonConfigComponent/ConfigUUID.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAExC,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAEtD,OAAO,EAAE,WAAW,IAAI,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAE9D,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,4BAA4B,CAAC;AAGzD,OAAO,aAAmE,MAAM,iBAAiB,CAAC;AAUlG,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,aAA+C;IACnF,KAAK,CAAC,iBAAiB;QACnB,MAAM,KAAK,CAAC,iBAAiB,EAAE,CAAC;QAEhC,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,eAAe,CAAC,kBAAkB,CAAC,CAAC;QAC9E,IAAI,CAAC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,IAAI,IAAI,SAAS,EAAE,CAAC,CAAC;IAChE,CAAC;IAED,UAAU,CAAC,KAAc,EAAE,QAAiB;QACxC,OAAO,CACH,oBAAC,SAAS,IACN,OAAO,EAAC,UAAU,EAClB,SAAS,QACT,KAAK,EAAE,CAAC,CAAC,KAAK,EACd,QAAQ,EAAE,CAAC,CAAC,QAAQ,EACpB,SAAS,EAAE;gBACP,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;gBAC7B,KAAK,EAAE;oBACH,YAAY,EAAE,CACV,oBAAC,UAAU,IACP,QAAQ,EAAE,CAAC,CAAC,EACZ,OAAO,EAAE,GAAG,EAAE;4BACV,KAAK,CAAC,eAAe,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;4BACvC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,cAAc,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC;wBAC1D,CAAC;wBAED,oBAAC,QAAQ,OAAG,CACH,CAChB;iBACJ;aACJ,EACD,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,EAAE,EAC5B,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC,yBAAyB,CAAC,EACjF,UAAU,EAAE,IAAI,CAAC,UAAU,CACvB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI,EACtB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,QAAQ,EAC1B,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,aAAa,CAClC,GACH,CACL,CAAC;IACN,CAAC;CACJ","sourcesContent":["import React, { type JSX } from 'react';\n\nimport { TextField, IconButton } from '@mui/material';\n\nimport { ContentCopy as IconCopy } from '@mui/icons-material';\n\nimport { Utils, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemUUID } from '../types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigUUIDProps extends ConfigGenericProps {\n schema: ConfigItemUUID;\n}\n\ninterface ConfigUUIDState extends ConfigGenericState {\n uuid?: string;\n}\n\nexport default class ConfigUUID extends ConfigGeneric<ConfigUUIDProps, ConfigUUIDState> {\n async componentDidMount(): Promise<void> {\n await super.componentDidMount();\n\n const uuidObj = await this.props.oContext.getCachedObject('system.meta.uuid');\n this.setState({ uuid: uuidObj?.native?.uuid || 'unknown' });\n }\n\n renderItem(error: unknown, disabled: boolean): JSX.Element {\n return (\n <TextField\n variant=\"standard\"\n fullWidth\n error={!!error}\n disabled={!!disabled}\n slotProps={{\n htmlInput: { readOnly: true },\n input: {\n endAdornment: (\n <IconButton\n tabIndex={-1}\n onClick={() => {\n Utils.copyToClipboard(this.state.uuid);\n window.alert(I18n.t('ra_Copied %s', this.state.uuid));\n }}\n >\n <IconCopy />\n </IconButton>\n ),\n },\n }}\n value={this.state.uuid || ''}\n label={this.getText(this.props.schema.label) || I18n.t('ra_Serial number (UUID)')}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n );\n }\n}\n"]}
1
+ {"version":3,"file":"ConfigUUID.js","sourceRoot":"./src/","sources":["JsonConfigComponent/ConfigUUID.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAExC,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAEtD,OAAO,EAAE,WAAW,IAAI,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAE9D,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,4BAA4B,CAAC;AAGzD,OAAO,aAAmE,MAAM,iBAAiB,CAAC;AAUlG,MAAM,CAAC,OAAO,OAAO,UAAW,SAAQ,aAA+C;IACnF,KAAK,CAAC,iBAAiB;QACnB,MAAM,KAAK,CAAC,iBAAiB,EAAE,CAAC;QAEhC,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,eAAe,CAAC,kBAAkB,CAAC,CAAC;QAC/D,IAAI,CAAC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,IAAI,IAAI,SAAS,EAAE,CAAC,CAAC;IAChE,CAAC;IAED,UAAU,CAAC,KAAc,EAAE,QAAiB;QACxC,OAAO,CACH,oBAAC,SAAS,IACN,OAAO,EAAC,UAAU,EAClB,SAAS,QACT,KAAK,EAAE,CAAC,CAAC,KAAK,EACd,QAAQ,EAAE,CAAC,CAAC,QAAQ,EACpB,SAAS,EAAE;gBACP,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;gBAC7B,KAAK,EAAE;oBACH,YAAY,EAAE,CACV,oBAAC,UAAU,IACP,QAAQ,EAAE,CAAC,CAAC,EACZ,OAAO,EAAE,GAAG,EAAE;4BACV,KAAK,CAAC,eAAe,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;4BACvC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,cAAc,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC;wBAC1D,CAAC;wBAED,oBAAC,QAAQ,OAAG,CACH,CAChB;iBACJ;aACJ,EACD,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,EAAE,EAC5B,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC,yBAAyB,CAAC,EACjF,UAAU,EAAE,IAAI,CAAC,UAAU,CACvB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI,EACtB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,QAAQ,EAC1B,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,aAAa,CAClC,GACH,CACL,CAAC;IACN,CAAC;CACJ","sourcesContent":["import React, { type JSX } from 'react';\n\nimport { TextField, IconButton } from '@mui/material';\n\nimport { ContentCopy as IconCopy } from '@mui/icons-material';\n\nimport { Utils, I18n } from '@iobroker/adapter-react-v5';\n\nimport type { ConfigItemUUID } from '../types';\nimport ConfigGeneric, { type ConfigGenericProps, type ConfigGenericState } from './ConfigGeneric';\n\ninterface ConfigUUIDProps extends ConfigGenericProps {\n schema: ConfigItemUUID;\n}\n\ninterface ConfigUUIDState extends ConfigGenericState {\n uuid?: string;\n}\n\nexport default class ConfigUUID extends ConfigGeneric<ConfigUUIDProps, ConfigUUIDState> {\n async componentDidMount(): Promise<void> {\n await super.componentDidMount();\n\n const uuidObj = await this.getCachedObject('system.meta.uuid');\n this.setState({ uuid: uuidObj?.native?.uuid || 'unknown' });\n }\n\n renderItem(error: unknown, disabled: boolean): JSX.Element {\n return (\n <TextField\n variant=\"standard\"\n fullWidth\n error={!!error}\n disabled={!!disabled}\n slotProps={{\n htmlInput: { readOnly: true },\n input: {\n endAdornment: (\n <IconButton\n tabIndex={-1}\n onClick={() => {\n Utils.copyToClipboard(this.state.uuid);\n window.alert(I18n.t('ra_Copied %s', this.state.uuid));\n }}\n >\n <IconCopy />\n </IconButton>\n ),\n },\n }}\n value={this.state.uuid || ''}\n label={this.getText(this.props.schema.label) || I18n.t('ra_Serial number (UUID)')}\n helperText={this.renderHelp(\n this.props.schema.help,\n this.props.schema.helpLink,\n this.props.schema.noTranslation,\n )}\n />\n );\n }\n}\n"]}
package/build/types.d.ts CHANGED
@@ -1234,7 +1234,7 @@ export type JsonConfigContext = {
1234
1234
  onCommandRunning: (commandRunning: boolean) => void;
1235
1235
  onValueChange?: (attr: string, value: any, saveConfig: boolean) => void;
1236
1236
  registerOnForceUpdate?: (attr: string, cb?: (data: any) => void) => void;
1237
- getCachedObject: (id: string) => Promise<ioBroker.Object | null>;
1237
+ getCachedObject?: (id: string) => Promise<ioBroker.Object | null>;
1238
1238
  };
1239
1239
 
1240
1240
  // Notification GUI
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@iobroker/json-config",
3
3
  "description": "This package contains the ioBroker JSON config UI components",
4
- "version": "8.4.1",
4
+ "version": "8.4.4",
5
5
  "author": {
6
6
  "name": "bluefox",
7
7
  "email": "dogafox@gmail.com"