@iobroker/json-config 1.0.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.
Files changed (221) hide show
  1. package/LICENSE +21 -0
  2. package/build/JsonConfig.d.ts +22 -0
  3. package/build/JsonConfig.js +535 -0
  4. package/build/JsonConfig.js.map +1 -0
  5. package/build/JsonConfigComponent/ChipInput.d.ts +12 -0
  6. package/build/JsonConfigComponent/ChipInput.js +595 -0
  7. package/build/JsonConfigComponent/ChipInput.js.map +1 -0
  8. package/build/JsonConfigComponent/ConfigAccordion.d.ts +15 -0
  9. package/build/JsonConfigComponent/ConfigAccordion.js +185 -0
  10. package/build/JsonConfigComponent/ConfigAccordion.js.map +1 -0
  11. package/build/JsonConfigComponent/ConfigAlive.d.ts +10 -0
  12. package/build/JsonConfigComponent/ConfigAlive.js +63 -0
  13. package/build/JsonConfigComponent/ConfigAlive.js.map +1 -0
  14. package/build/JsonConfigComponent/ConfigAutocomplete.d.ts +37 -0
  15. package/build/JsonConfigComponent/ConfigAutocomplete.js +69 -0
  16. package/build/JsonConfigComponent/ConfigAutocomplete.js.map +1 -0
  17. package/build/JsonConfigComponent/ConfigAutocompleteSendTo.d.ts +17 -0
  18. package/build/JsonConfigComponent/ConfigAutocompleteSendTo.js +127 -0
  19. package/build/JsonConfigComponent/ConfigAutocompleteSendTo.js.map +1 -0
  20. package/build/JsonConfigComponent/ConfigCRON.d.ts +15 -0
  21. package/build/JsonConfigComponent/ConfigCRON.js +55 -0
  22. package/build/JsonConfigComponent/ConfigCRON.js.map +1 -0
  23. package/build/JsonConfigComponent/ConfigCertCollection.d.ts +14 -0
  24. package/build/JsonConfigComponent/ConfigCertCollection.js +50 -0
  25. package/build/JsonConfigComponent/ConfigCertCollection.js.map +1 -0
  26. package/build/JsonConfigComponent/ConfigCertificateSelect.d.ts +14 -0
  27. package/build/JsonConfigComponent/ConfigCertificateSelect.js +59 -0
  28. package/build/JsonConfigComponent/ConfigCertificateSelect.js.map +1 -0
  29. package/build/JsonConfigComponent/ConfigCertificates.d.ts +14 -0
  30. package/build/JsonConfigComponent/ConfigCertificates.js +104 -0
  31. package/build/JsonConfigComponent/ConfigCertificates.js.map +1 -0
  32. package/build/JsonConfigComponent/ConfigCheckLicense.d.ts +3 -0
  33. package/build/JsonConfigComponent/ConfigCheckLicense.js +546 -0
  34. package/build/JsonConfigComponent/ConfigCheckLicense.js.map +1 -0
  35. package/build/JsonConfigComponent/ConfigCheckbox.d.ts +15 -0
  36. package/build/JsonConfigComponent/ConfigCheckbox.js +36 -0
  37. package/build/JsonConfigComponent/ConfigCheckbox.js.map +1 -0
  38. package/build/JsonConfigComponent/ConfigChip.d.ts +14 -0
  39. package/build/JsonConfigComponent/ConfigChip.js +67 -0
  40. package/build/JsonConfigComponent/ConfigChip.js.map +1 -0
  41. package/build/JsonConfigComponent/ConfigColor.d.ts +22 -0
  42. package/build/JsonConfigComponent/ConfigColor.js +57 -0
  43. package/build/JsonConfigComponent/ConfigColor.js.map +1 -0
  44. package/build/JsonConfigComponent/ConfigCoordinates.d.ts +14 -0
  45. package/build/JsonConfigComponent/ConfigCoordinates.js +146 -0
  46. package/build/JsonConfigComponent/ConfigCoordinates.js.map +1 -0
  47. package/build/JsonConfigComponent/ConfigCustom.d.ts +26 -0
  48. package/build/JsonConfigComponent/ConfigCustom.js +195 -0
  49. package/build/JsonConfigComponent/ConfigCustom.js.map +1 -0
  50. package/build/JsonConfigComponent/ConfigDatePicker.d.ts +14 -0
  51. package/build/JsonConfigComponent/ConfigDatePicker.js +39 -0
  52. package/build/JsonConfigComponent/ConfigDatePicker.js.map +1 -0
  53. package/build/JsonConfigComponent/ConfigDeviceManager.d.ts +6 -0
  54. package/build/JsonConfigComponent/ConfigDeviceManager.js +14 -0
  55. package/build/JsonConfigComponent/ConfigDeviceManager.js.map +1 -0
  56. package/build/JsonConfigComponent/ConfigFile.d.ts +15 -0
  57. package/build/JsonConfigComponent/ConfigFile.js +131 -0
  58. package/build/JsonConfigComponent/ConfigFile.js.map +1 -0
  59. package/build/JsonConfigComponent/ConfigFileSelector.d.ts +3 -0
  60. package/build/JsonConfigComponent/ConfigFileSelector.js +434 -0
  61. package/build/JsonConfigComponent/ConfigFileSelector.js.map +1 -0
  62. package/build/JsonConfigComponent/ConfigFunc.d.ts +14 -0
  63. package/build/JsonConfigComponent/ConfigFunc.js +56 -0
  64. package/build/JsonConfigComponent/ConfigFunc.js.map +1 -0
  65. package/build/JsonConfigComponent/ConfigGeneric.d.ts +95 -0
  66. package/build/JsonConfigComponent/ConfigGeneric.js +632 -0
  67. package/build/JsonConfigComponent/ConfigGeneric.js.map +1 -0
  68. package/build/JsonConfigComponent/ConfigIP.d.ts +14 -0
  69. package/build/JsonConfigComponent/ConfigIP.js +64 -0
  70. package/build/JsonConfigComponent/ConfigIP.js.map +1 -0
  71. package/build/JsonConfigComponent/ConfigImageSendTo.d.ts +10 -0
  72. package/build/JsonConfigComponent/ConfigImageSendTo.js +62 -0
  73. package/build/JsonConfigComponent/ConfigImageSendTo.js.map +1 -0
  74. package/build/JsonConfigComponent/ConfigImageUpload.d.ts +14 -0
  75. package/build/JsonConfigComponent/ConfigImageUpload.js +91 -0
  76. package/build/JsonConfigComponent/ConfigImageUpload.js.map +1 -0
  77. package/build/JsonConfigComponent/ConfigInstanceSelect.d.ts +14 -0
  78. package/build/JsonConfigComponent/ConfigInstanceSelect.js +133 -0
  79. package/build/JsonConfigComponent/ConfigInstanceSelect.js.map +1 -0
  80. package/build/JsonConfigComponent/ConfigInterface.d.ts +14 -0
  81. package/build/JsonConfigComponent/ConfigInterface.js +74 -0
  82. package/build/JsonConfigComponent/ConfigInterface.js.map +1 -0
  83. package/build/JsonConfigComponent/ConfigJsonEditor.d.ts +13 -0
  84. package/build/JsonConfigComponent/ConfigJsonEditor.js +59 -0
  85. package/build/JsonConfigComponent/ConfigJsonEditor.js.map +1 -0
  86. package/build/JsonConfigComponent/ConfigLanguage.d.ts +7 -0
  87. package/build/JsonConfigComponent/ConfigLanguage.js +105 -0
  88. package/build/JsonConfigComponent/ConfigLanguage.js.map +1 -0
  89. package/build/JsonConfigComponent/ConfigLicense.d.ts +24 -0
  90. package/build/JsonConfigComponent/ConfigLicense.js +95 -0
  91. package/build/JsonConfigComponent/ConfigLicense.js.map +1 -0
  92. package/build/JsonConfigComponent/ConfigNumber.d.ts +17 -0
  93. package/build/JsonConfigComponent/ConfigNumber.js +114 -0
  94. package/build/JsonConfigComponent/ConfigNumber.js.map +1 -0
  95. package/build/JsonConfigComponent/ConfigObjectId.d.ts +17 -0
  96. package/build/JsonConfigComponent/ConfigObjectId.js +59 -0
  97. package/build/JsonConfigComponent/ConfigObjectId.js.map +1 -0
  98. package/build/JsonConfigComponent/ConfigPanel.d.ts +3 -0
  99. package/build/JsonConfigComponent/ConfigPanel.js +271 -0
  100. package/build/JsonConfigComponent/ConfigPanel.js.map +1 -0
  101. package/build/JsonConfigComponent/ConfigPassword.d.ts +14 -0
  102. package/build/JsonConfigComponent/ConfigPassword.js +105 -0
  103. package/build/JsonConfigComponent/ConfigPassword.js.map +1 -0
  104. package/build/JsonConfigComponent/ConfigPattern.d.ts +21 -0
  105. package/build/JsonConfigComponent/ConfigPattern.js +32 -0
  106. package/build/JsonConfigComponent/ConfigPattern.js.map +1 -0
  107. package/build/JsonConfigComponent/ConfigPort.d.ts +3 -0
  108. package/build/JsonConfigComponent/ConfigPort.js +174 -0
  109. package/build/JsonConfigComponent/ConfigPort.js.map +1 -0
  110. package/build/JsonConfigComponent/ConfigRoom.d.ts +14 -0
  111. package/build/JsonConfigComponent/ConfigRoom.js +56 -0
  112. package/build/JsonConfigComponent/ConfigRoom.js.map +1 -0
  113. package/build/JsonConfigComponent/ConfigSelect.d.ts +14 -0
  114. package/build/JsonConfigComponent/ConfigSelect.js +90 -0
  115. package/build/JsonConfigComponent/ConfigSelect.js.map +1 -0
  116. package/build/JsonConfigComponent/ConfigSelectSendTo.d.ts +17 -0
  117. package/build/JsonConfigComponent/ConfigSelectSendTo.js +175 -0
  118. package/build/JsonConfigComponent/ConfigSelectSendTo.js.map +1 -0
  119. package/build/JsonConfigComponent/ConfigSendto.d.ts +24 -0
  120. package/build/JsonConfigComponent/ConfigSendto.js +290 -0
  121. package/build/JsonConfigComponent/ConfigSendto.js.map +1 -0
  122. package/build/JsonConfigComponent/ConfigSetState.d.ts +18 -0
  123. package/build/JsonConfigComponent/ConfigSetState.js +93 -0
  124. package/build/JsonConfigComponent/ConfigSetState.js.map +1 -0
  125. package/build/JsonConfigComponent/ConfigSlider.d.ts +14 -0
  126. package/build/JsonConfigComponent/ConfigSlider.js +62 -0
  127. package/build/JsonConfigComponent/ConfigSlider.js.map +1 -0
  128. package/build/JsonConfigComponent/ConfigStaticDivider.d.ts +14 -0
  129. package/build/JsonConfigComponent/ConfigStaticDivider.js +39 -0
  130. package/build/JsonConfigComponent/ConfigStaticDivider.js.map +1 -0
  131. package/build/JsonConfigComponent/ConfigStaticHeader.d.ts +14 -0
  132. package/build/JsonConfigComponent/ConfigStaticHeader.js +45 -0
  133. package/build/JsonConfigComponent/ConfigStaticHeader.js.map +1 -0
  134. package/build/JsonConfigComponent/ConfigStaticImage.d.ts +14 -0
  135. package/build/JsonConfigComponent/ConfigStaticImage.js +36 -0
  136. package/build/JsonConfigComponent/ConfigStaticImage.js.map +1 -0
  137. package/build/JsonConfigComponent/ConfigStaticText.d.ts +14 -0
  138. package/build/JsonConfigComponent/ConfigStaticText.js +51 -0
  139. package/build/JsonConfigComponent/ConfigStaticText.js.map +1 -0
  140. package/build/JsonConfigComponent/ConfigTable.d.ts +3 -0
  141. package/build/JsonConfigComponent/ConfigTable.js +670 -0
  142. package/build/JsonConfigComponent/ConfigTable.js.map +1 -0
  143. package/build/JsonConfigComponent/ConfigTabs.d.ts +34 -0
  144. package/build/JsonConfigComponent/ConfigTabs.js +90 -0
  145. package/build/JsonConfigComponent/ConfigTabs.js.map +1 -0
  146. package/build/JsonConfigComponent/ConfigText.d.ts +14 -0
  147. package/build/JsonConfigComponent/ConfigText.js +105 -0
  148. package/build/JsonConfigComponent/ConfigText.js.map +1 -0
  149. package/build/JsonConfigComponent/ConfigTextSendTo.d.ts +10 -0
  150. package/build/JsonConfigComponent/ConfigTextSendTo.js +76 -0
  151. package/build/JsonConfigComponent/ConfigTextSendTo.js.map +1 -0
  152. package/build/JsonConfigComponent/ConfigTimePicker.d.ts +14 -0
  153. package/build/JsonConfigComponent/ConfigTimePicker.js +37 -0
  154. package/build/JsonConfigComponent/ConfigTimePicker.js.map +1 -0
  155. package/build/JsonConfigComponent/ConfigTopic.d.ts +17 -0
  156. package/build/JsonConfigComponent/ConfigTopic.js +61 -0
  157. package/build/JsonConfigComponent/ConfigTopic.js.map +1 -0
  158. package/build/JsonConfigComponent/ConfigUUID.d.ts +15 -0
  159. package/build/JsonConfigComponent/ConfigUUID.js +31 -0
  160. package/build/JsonConfigComponent/ConfigUUID.js.map +1 -0
  161. package/build/JsonConfigComponent/ConfigUser.d.ts +14 -0
  162. package/build/JsonConfigComponent/ConfigUser.js +70 -0
  163. package/build/JsonConfigComponent/ConfigUser.js.map +1 -0
  164. package/build/JsonConfigComponent/index.d.ts +26 -0
  165. package/build/JsonConfigComponent/index.js +312 -0
  166. package/build/JsonConfigComponent/index.js.map +1 -0
  167. package/build/JsonConfigComponent/wrapper/AdminConnection.d.ts +2 -0
  168. package/build/JsonConfigComponent/wrapper/AdminConnection.js +3 -0
  169. package/build/JsonConfigComponent/wrapper/AdminConnection.js.map +1 -0
  170. package/build/JsonConfigComponent/wrapper/Components/ColorPicker.d.ts +2 -0
  171. package/build/JsonConfigComponent/wrapper/Components/ColorPicker.js +3 -0
  172. package/build/JsonConfigComponent/wrapper/Components/ColorPicker.js.map +1 -0
  173. package/build/JsonConfigComponent/wrapper/Components/CustomModal.d.ts +3 -0
  174. package/build/JsonConfigComponent/wrapper/Components/CustomModal.js +87 -0
  175. package/build/JsonConfigComponent/wrapper/Components/CustomModal.js.map +1 -0
  176. package/build/JsonConfigComponent/wrapper/Components/Editor.d.ts +14 -0
  177. package/build/JsonConfigComponent/wrapper/Components/Editor.js +43 -0
  178. package/build/JsonConfigComponent/wrapper/Components/Editor.js.map +1 -0
  179. package/build/JsonConfigComponent/wrapper/Components/Icon.d.ts +2 -0
  180. package/build/JsonConfigComponent/wrapper/Components/Icon.js +3 -0
  181. package/build/JsonConfigComponent/wrapper/Components/Icon.js.map +1 -0
  182. package/build/JsonConfigComponent/wrapper/Components/TextWithIcon.d.ts +2 -0
  183. package/build/JsonConfigComponent/wrapper/Components/TextWithIcon.js +3 -0
  184. package/build/JsonConfigComponent/wrapper/Components/TextWithIcon.js.map +1 -0
  185. package/build/JsonConfigComponent/wrapper/Components/UploadImage.d.ts +2 -0
  186. package/build/JsonConfigComponent/wrapper/Components/UploadImage.js +3 -0
  187. package/build/JsonConfigComponent/wrapper/Components/UploadImage.js.map +1 -0
  188. package/build/JsonConfigComponent/wrapper/Components/Utils.d.ts +2 -0
  189. package/build/JsonConfigComponent/wrapper/Components/Utils.js +3 -0
  190. package/build/JsonConfigComponent/wrapper/Components/Utils.js.map +1 -0
  191. package/build/JsonConfigComponent/wrapper/Dialogs/Confirm.d.ts +2 -0
  192. package/build/JsonConfigComponent/wrapper/Dialogs/Confirm.js +3 -0
  193. package/build/JsonConfigComponent/wrapper/Dialogs/Confirm.js.map +1 -0
  194. package/build/JsonConfigComponent/wrapper/Dialogs/Cron.d.ts +2 -0
  195. package/build/JsonConfigComponent/wrapper/Dialogs/Cron.js +3 -0
  196. package/build/JsonConfigComponent/wrapper/Dialogs/Cron.js.map +1 -0
  197. package/build/JsonConfigComponent/wrapper/Dialogs/Error.d.ts +2 -0
  198. package/build/JsonConfigComponent/wrapper/Dialogs/Error.js +3 -0
  199. package/build/JsonConfigComponent/wrapper/Dialogs/Error.js.map +1 -0
  200. package/build/JsonConfigComponent/wrapper/Dialogs/Message.d.ts +2 -0
  201. package/build/JsonConfigComponent/wrapper/Dialogs/Message.js +3 -0
  202. package/build/JsonConfigComponent/wrapper/Dialogs/Message.js.map +1 -0
  203. package/build/JsonConfigComponent/wrapper/Dialogs/SelectFile.d.ts +2 -0
  204. package/build/JsonConfigComponent/wrapper/Dialogs/SelectFile.js +3 -0
  205. package/build/JsonConfigComponent/wrapper/Dialogs/SelectFile.js.map +1 -0
  206. package/build/JsonConfigComponent/wrapper/Dialogs/SelectID.d.ts +2 -0
  207. package/build/JsonConfigComponent/wrapper/Dialogs/SelectID.js +3 -0
  208. package/build/JsonConfigComponent/wrapper/Dialogs/SelectID.js.map +1 -0
  209. package/build/JsonConfigComponent/wrapper/i18n.d.ts +2 -0
  210. package/build/JsonConfigComponent/wrapper/i18n.js +3 -0
  211. package/build/JsonConfigComponent/wrapper/i18n.js.map +1 -0
  212. package/build/JsonConfigComponent/wrapper/icons/IconCopy.d.ts +2 -0
  213. package/build/JsonConfigComponent/wrapper/icons/IconCopy.js +3 -0
  214. package/build/JsonConfigComponent/wrapper/icons/IconCopy.js.map +1 -0
  215. package/build/Utils.d.ts +376 -0
  216. package/build/Utils.js +1595 -0
  217. package/build/Utils.js.map +1 -0
  218. package/build/index.d.ts +5 -0
  219. package/build/index.js +6 -0
  220. package/build/index.js.map +1 -0
  221. package/package.json +17 -0
@@ -0,0 +1,45 @@
1
+ import React from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import { withStyles } from '@mui/styles';
4
+ import ConfigGeneric from './ConfigGeneric';
5
+ const styles = theme => ({
6
+ header: {
7
+ width: '100%',
8
+ background: theme.palette.primary.main,
9
+ color: theme.palette.primary.contrastText,
10
+ padding: '4px !important',
11
+ borderRadius: 3,
12
+ marginBlockEnd: 0,
13
+ marginBlockStart: 0,
14
+ },
15
+ });
16
+ class ConfigStaticHeader extends ConfigGeneric {
17
+ renderItem() {
18
+ switch ((this.props.schema.size || 5).toString()) {
19
+ case '1':
20
+ return React.createElement("h1", { className: this.props.classes.header }, this.getText(this.props.schema.text, this.props.schema.noTranslation));
21
+ case '2':
22
+ return React.createElement("h2", { className: this.props.classes.header }, this.getText(this.props.schema.text, this.props.schema.noTranslation));
23
+ case '3':
24
+ return React.createElement("h3", { className: this.props.classes.header }, this.getText(this.props.schema.text, this.props.schema.noTranslation));
25
+ case '4':
26
+ return React.createElement("h4", { className: this.props.classes.header }, this.getText(this.props.schema.text, this.props.schema.noTranslation));
27
+ case '5':
28
+ default:
29
+ return React.createElement("h5", { className: this.props.classes.header }, this.getText(this.props.schema.text, this.props.schema.noTranslation));
30
+ }
31
+ }
32
+ }
33
+ ConfigStaticHeader.propTypes = {
34
+ socket: PropTypes.object.isRequired,
35
+ themeType: PropTypes.string,
36
+ themeName: PropTypes.string,
37
+ style: PropTypes.object,
38
+ className: PropTypes.string,
39
+ data: PropTypes.object.isRequired,
40
+ schema: PropTypes.object,
41
+ onError: PropTypes.func,
42
+ onChange: PropTypes.func,
43
+ };
44
+ export default withStyles(styles)(ConfigStaticHeader);
45
+ //# sourceMappingURL=ConfigStaticHeader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ConfigStaticHeader.js","sourceRoot":"./src/","sources":["JsonConfigComponent/ConfigStaticHeader.jsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,SAAS,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,OAAO,aAAa,MAAM,iBAAiB,CAAC;AAE5C,MAAM,MAAM,GAAG,KAAK,CAAC,EAAE,CAAC,CAAC;IACrB,MAAM,EAAE;QACJ,KAAK,EAAE,MAAM;QACb,UAAU,EAAE,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI;QACtC,KAAK,EAAE,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,YAAY;QACzC,OAAO,EAAE,gBAAgB;QACzB,YAAY,EAAE,CAAC;QACf,cAAc,EAAE,CAAC;QACjB,gBAAgB,EAAE,CAAC;KACtB;CACJ,CAAC,CAAC;AAEH,MAAM,kBAAmB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AAI,EAAE,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,aAAa,CAAC,CACrE,CAAC;SACb;IACL,CAAC;CACJ;AAED,kBAAkB,CAAC,SAAS,GAAG;IAC3B,MAAM,EAAE,SAAS,CAAC,MAAM,CAAC,UAAU;IACnC,SAAS,EAAE,SAAS,CAAC,MAAM;IAC3B,SAAS,EAAE,SAAS,CAAC,MAAM;IAC3B,KAAK,EAAE,SAAS,CAAC,MAAM;IACvB,SAAS,EAAE,SAAS,CAAC,MAAM;IAC3B,IAAI,EAAE,SAAS,CAAC,MAAM,CAAC,UAAU;IACjC,MAAM,EAAE,SAAS,CAAC,MAAM;IACxB,OAAO,EAAE,SAAS,CAAC,IAAI;IACvB,QAAQ,EAAE,SAAS,CAAC,IAAI;CAC3B,CAAC;AAEF,eAAe,UAAU,CAAC,MAAM,CAAC,CAAC,kBAAkB,CAAC,CAAC"}
@@ -0,0 +1,14 @@
1
+ declare const _default: React.JSXElementConstructor<Omit<Pick<import("./ConfigGeneric").ConfigGenericProps, "data" | "originalData" | "instanceObj" | "customObj" | "schema" | "attr" | "onChange" | "custom" | "forceUpdate" | "alive" | "systemConfig" | "socket" | "changed" | "adapterName" | "instance" | "common" | "onError" | "themeType" | "disabled" | "classes"> & Pick<PropTypes.InferProps<{
2
+ socket: PropTypes.Validator<object>;
3
+ themeType: PropTypes.Requireable<string>;
4
+ themeName: PropTypes.Requireable<string>;
5
+ style: PropTypes.Requireable<object>;
6
+ className: PropTypes.Requireable<string>;
7
+ data: PropTypes.Validator<object>;
8
+ schema: PropTypes.Requireable<object>;
9
+ onError: PropTypes.Requireable<(...args: any[]) => any>;
10
+ onChange: PropTypes.Requireable<(...args: any[]) => any>;
11
+ }>, "className" | "style" | "themeName"> & Pick<import("./ConfigGeneric").ConfigGenericProps, "originalData" | "instanceObj" | "customObj" | "arrayIndex" | "globalData" | "registerOnForceUpdate" | "attr" | "custom" | "forceUpdate" | "alive" | "systemConfig" | "changed" | "adapterName" | "instance" | "common" | "commandRunning" | "disabled" | "classes">, "classes"> & import("@mui/styles").StyledComponentProps<"fullWidth"> & object>;
12
+ export default _default;
13
+ import PropTypes from 'prop-types';
14
+ import React from 'react';
@@ -0,0 +1,36 @@
1
+ import React from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import { withStyles } from '@mui/styles';
4
+ import ConfigGeneric from './ConfigGeneric';
5
+ const styles = () => ({
6
+ fullWidth: {
7
+ height: '100%',
8
+ width: '100%',
9
+ },
10
+ });
11
+ class ConfigStaticImage extends ConfigGeneric {
12
+ renderItem() {
13
+ let src = this.props.schema.src;
14
+ if (src && !src.startsWith('.') &&
15
+ !src.startsWith('http') &&
16
+ !src.startsWith(`adapter/${this.props.adapterName}/`) &&
17
+ !src.startsWith(`./adapter/${this.props.adapterName}/`)) {
18
+ src = `adapter/${this.props.adapterName}/${src}`;
19
+ }
20
+ // eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions
21
+ return React.createElement("img", { className: this.props.classes.fullWidth, src: src, style: this.props.schema.href ? { cursor: 'pointer' } : {}, onClick: this.props.schema.href ? () => this.props.schema.href && window.open(this.props.schema.href, '_blank') : null, alt: "" });
22
+ }
23
+ }
24
+ ConfigStaticImage.propTypes = {
25
+ socket: PropTypes.object.isRequired,
26
+ themeType: PropTypes.string,
27
+ themeName: PropTypes.string,
28
+ style: PropTypes.object,
29
+ className: PropTypes.string,
30
+ data: PropTypes.object.isRequired,
31
+ schema: PropTypes.object,
32
+ onError: PropTypes.func,
33
+ onChange: PropTypes.func,
34
+ };
35
+ export default withStyles(styles)(ConfigStaticImage);
36
+ //# sourceMappingURL=ConfigStaticImage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ConfigStaticImage.js","sourceRoot":"./src/","sources":["JsonConfigComponent/ConfigStaticImage.jsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,SAAS,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,UAAU,EAAE,MA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AED,iBAAiB,CAAC,SAAS,GAAG;IAC1B,MAAM,EAAE,SAAS,CAAC,MAAM,CAAC,UAAU;IACnC,SAAS,EAAE,SAAS,CAAC,MAAM;IAC3B,SAAS,EAAE,SAAS,CAAC,MAAM;IAC3B,KAAK,EAAE,SAAS,CAAC,MAAM;IACvB,SAAS,EAAE,SAAS,CAAC,MAAM;IAC3B,IAAI,EAAE,SAAS,CAAC,MAAM,CAAC,UAAU;IACjC,MAAM,EAAE,SAAS,CAAC,MAAM;IACxB,OAAO,EAAE,SAAS,CAAC,IAAI;IACvB,QAAQ,EAAE,SAAS,CAAC,IAAI;CAC3B,CAAC;AAEF,eAAe,UAAU,CAAC,MAAM,CAAC,CAAC,iBAAiB,CAAC,CAAC"}
@@ -0,0 +1,14 @@
1
+ declare const _default: React.JSXElementConstructor<Omit<Pick<import("./ConfigGeneric").ConfigGenericProps, "data" | "originalData" | "instanceObj" | "customObj" | "schema" | "attr" | "onChange" | "custom" | "forceUpdate" | "alive" | "systemConfig" | "socket" | "changed" | "adapterName" | "instance" | "common" | "onError" | "themeType" | "disabled" | "classes"> & Pick<PropTypes.InferProps<{
2
+ socket: PropTypes.Validator<object>;
3
+ themeType: PropTypes.Requireable<string>;
4
+ themeName: PropTypes.Requireable<string>;
5
+ style: PropTypes.Requireable<object>;
6
+ className: PropTypes.Requireable<string>;
7
+ data: PropTypes.Validator<object>;
8
+ schema: PropTypes.Requireable<object>;
9
+ onError: PropTypes.Requireable<(...args: any[]) => any>;
10
+ onChange: PropTypes.Requireable<(...args: any[]) => any>;
11
+ }>, "className" | "style" | "themeName"> & Pick<import("./ConfigGeneric").ConfigGenericProps, "originalData" | "instanceObj" | "customObj" | "arrayIndex" | "globalData" | "registerOnForceUpdate" | "attr" | "custom" | "forceUpdate" | "alive" | "systemConfig" | "changed" | "adapterName" | "instance" | "common" | "commandRunning" | "disabled" | "classes">, "classes"> & import("@mui/styles").StyledComponentProps<"fullWidth" | "link"> & object>;
12
+ export default _default;
13
+ import PropTypes from 'prop-types';
14
+ import React from 'react';
@@ -0,0 +1,51 @@
1
+ import React from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import { withStyles } from '@mui/styles';
4
+ import { Button } from '@mui/material';
5
+ import Utils from './wrapper/Components/Utils';
6
+ import ConfigGeneric from './ConfigGeneric';
7
+ const styles = theme => ({
8
+ fullWidth: {
9
+ height: '100%',
10
+ width: '100%',
11
+ },
12
+ link: {
13
+ textDecoration: 'underline',
14
+ color: theme.palette.mode === 'dark' ? '#4dabf5' : '#254e72',
15
+ cursor: 'pointer',
16
+ },
17
+ });
18
+ class ConfigStaticText extends ConfigGeneric {
19
+ renderItem(error, disabled) {
20
+ if (this.props.schema.button) {
21
+ const icon = this.getIcon();
22
+ return React.createElement(Button, { variant: this.props.schema.variant || undefined, color: this.props.schema.color || 'grey', className: this.props.classes.fullWidth, disabled: disabled, startIcon: icon, onClick: this.props.schema.href ? () => {
23
+ // calculate one more time just before call
24
+ const href = this.props.schema.href ? this.getText(this.props.schema.href, true) : null;
25
+ href && window.open(href, '_blank');
26
+ } : null }, this.getText(this.props.schema.text || this.props.schema.label, this.props.schema.noTranslation));
27
+ }
28
+ let text = this.getText(this.props.schema.text || this.props.schema.label, this.props.schema.noTranslation);
29
+ if (text && (text.includes('<a ') || text.includes('<br') || text.includes('<b>') || text.includes('<i>'))) {
30
+ text = Utils.renderTextWithA(text);
31
+ }
32
+ return React.createElement("span", { className: this.props.schema.href ? this.props.classes.link : '', onClick: this.props.schema.href ? () => {
33
+ // calculate one more time just before call
34
+ const href = this.props.schema.href ? this.getText(this.props.schema.href, true) : null;
35
+ href && window.open(href, '_blank');
36
+ } : null }, text);
37
+ }
38
+ }
39
+ ConfigStaticText.propTypes = {
40
+ socket: PropTypes.object.isRequired,
41
+ themeType: PropTypes.string,
42
+ themeName: PropTypes.string,
43
+ style: PropTypes.object,
44
+ className: PropTypes.string,
45
+ data: PropTypes.object.isRequired,
46
+ schema: PropTypes.object,
47
+ onError: PropTypes.func,
48
+ onChange: PropTypes.func,
49
+ };
50
+ export default withStyles(styles)(ConfigStaticText);
51
+ //# sourceMappingURL=ConfigStaticText.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ConfigStaticText.js","sourceRoot":"./src/","sources":["JsonConfigComponent/ConfigStaticText.jsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,SAAS,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAEvC,OAAO,KAAK,MAAM,4BAA4B,CAAC;AAE/C,OAAO,aAAa,MAAM,iBAAiB,CAAC;AAE5C,MAAM,MAAM,GAAG,KAAK,CAAC,EAAE,CAAC,CAAC;IACrB,SAAS,EAAE;QACP,MAAM,EAAE,MAAM;QACd,KAAK,EAAE,MAAM;KAChB;IACD,IAAI,EAAE;QACF,cAAc,EAAE,WAAW;QAC3B,KAAK,EAAE,KAAK,CAAC,OAAO,CAAC,IAAI,KAAK,MAAM,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,SAAS;QAC5D,MAAM,EAAE,SAAS;KACpB;CACJ,CAAC,CAAC;AAEH,MAAM,gBAAiB,SAAQ,aAAa;IACxC,UAAU,CAAC,KAAK,EAAE,QAAQ;QACtB,IAAI,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,EAAE;YAC1B,MAAM,IAAI,GAAG,IAAI,CAAC,OAAO,EAAE,CAAC;YAC5B,OAAO,oBAAC,MAAM,IACV,OAAO,EAAE,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,OAAO,IAAI,SAAS,EAC/C,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,IAAI,MAAM,EACxC,SAAS,EAAE,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,SAAS,EACvC,QAAQ,EAAE,QAAQ,EAClB,SAAS,E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