@iobroker/adapter-react-v5 4.13.11 → 4.13.13
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/Components/FileBrowser.d.ts +1 -1
- package/Components/FileViewer.d.ts +1 -1
- package/Components/ObjectBrowser.d.ts +61 -734
- package/Components/ObjectBrowser.js +4895 -6706
- package/Components/Router.d.ts +3 -3
- package/Components/Router.js +2 -5
- package/Components/TabContainer.d.ts +1 -1
- package/Components/Utils.js +2 -1
- package/Components/withWidth.d.ts +2 -1
- package/Components/withWidth.js +18 -30
- package/Dialogs/TextInput.d.ts +1 -1
- package/GenericApp.d.ts +1 -1
- package/LegacyConnection.d.ts +2 -2
- package/README.md +6 -0
- package/index.d.ts +1 -0
- package/index.js +5 -4
- package/package.json +10 -10
- package/Components/ObjectBrowser.js.map +0 -1
- package/Components/withWidth.js.map +0 -1
package/Components/Router.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
interface Router<P = {}, S = {}> extends
|
|
1
|
+
import { Component } from 'react';
|
|
2
|
+
interface Router<P = {}, S = {}> extends Component<P, S> {
|
|
3
3
|
}
|
|
4
|
-
declare class Router<P, S> extends
|
|
4
|
+
declare class Router<P, S> extends Component<P, S> {
|
|
5
5
|
protected onHashChangedBound: () => void;
|
|
6
6
|
constructor(props: P);
|
|
7
7
|
componentDidMount(): void;
|
package/Components/Router.js
CHANGED
|
@@ -1,10 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const react_1 =
|
|
7
|
-
class Router extends react_1.
|
|
3
|
+
const react_1 = require("react");
|
|
4
|
+
class Router extends react_1.Component {
|
|
8
5
|
constructor(props) {
|
|
9
6
|
super(props);
|
|
10
7
|
this.onHashChangedBound = this.onHashChanged.bind(this);
|
|
@@ -13,5 +13,5 @@ interface TabContainerProps {
|
|
|
13
13
|
children: React.ReactNode;
|
|
14
14
|
}
|
|
15
15
|
/** @type {typeof TabContainer} */
|
|
16
|
-
declare const _export: React.JSXElementConstructor<Omit<TabContainerProps, "classes"> & import("@mui/styles").StyledComponentProps<"root" | "
|
|
16
|
+
declare const _export: React.JSXElementConstructor<Omit<TabContainerProps, "classes"> & import("@mui/styles").StyledComponentProps<"root" | "container" | "overflowHidden"> & object>;
|
|
17
17
|
export default _export;
|
package/Components/Utils.js
CHANGED
|
@@ -1165,7 +1165,8 @@ class Utils {
|
|
|
1165
1165
|
* Set the theme name and theme type.
|
|
1166
1166
|
*/
|
|
1167
1167
|
static setThemeName(themeName) {
|
|
1168
|
-
|
|
1168
|
+
const vendorPrefix = window.vendorPrefix;
|
|
1169
|
+
if (vendorPrefix && vendorPrefix !== '@@vendorPrefix@@' && vendorPrefix !== 'MV') {
|
|
1169
1170
|
return; // ignore
|
|
1170
1171
|
}
|
|
1171
1172
|
(window._localStorage || window.localStorage).setItem('App.themeName', themeName);
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
+
import React, { JSXElementConstructor } from 'react';
|
|
2
|
+
declare const withWidth: () => (WrappedComponent: JSXElementConstructor<any>) => (props: Record<string, any>) => React.JSX.Element;
|
|
1
3
|
export default withWidth;
|
|
2
|
-
declare function withWidth(): (WrappedComponent: any) => (props: any) => React.JSX.Element;
|
package/Components/withWidth.js
CHANGED
|
@@ -1,35 +1,23 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
|
|
10
|
-
var _react = _interopRequireDefault(require("react"));
|
|
11
|
-
var _styles = require("@mui/material/styles");
|
|
12
|
-
var _material = require("@mui/material");
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const react_1 = __importDefault(require("react"));
|
|
7
|
+
const styles_1 = require("@mui/material/styles");
|
|
8
|
+
const material_1 = require("@mui/material");
|
|
13
9
|
function useWidth() {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
10
|
+
const theme = (0, styles_1.useTheme)();
|
|
11
|
+
const keys = [...theme.breakpoints.keys].reverse();
|
|
12
|
+
return keys.reduce((output, key) => {
|
|
13
|
+
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
14
|
+
const matches = (0, material_1.useMediaQuery)(theme.breakpoints.up(key));
|
|
15
|
+
return !output && matches ? key : output;
|
|
16
|
+
}, null) || 'xs';
|
|
21
17
|
}
|
|
22
|
-
|
|
23
18
|
// FIXME checkout https://mui.com/components/use-media-query/#migrating-from-withwidth
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
return
|
|
27
|
-
var width = useWidth();
|
|
28
|
-
return /*#__PURE__*/_react["default"].createElement(WrappedComponent, (0, _extends2["default"])({}, props, {
|
|
29
|
-
width: width
|
|
30
|
-
}));
|
|
31
|
-
};
|
|
32
|
-
};
|
|
19
|
+
const withWidth = () => (WrappedComponent) => (props) => {
|
|
20
|
+
const width = useWidth();
|
|
21
|
+
return react_1.default.createElement(WrappedComponent, Object.assign({}, props, { width: width }));
|
|
33
22
|
};
|
|
34
|
-
|
|
35
|
-
//# sourceMappingURL=withWidth.js.map
|
|
23
|
+
exports.default = withWidth;
|
package/Dialogs/TextInput.d.ts
CHANGED
package/GenericApp.d.ts
CHANGED
|
@@ -146,7 +146,7 @@ declare class GenericApp<TProps extends GenericAppProps = GenericAppProps, TStat
|
|
|
146
146
|
* Gets the system configuration.
|
|
147
147
|
* @returns {Promise<ioBroker.OtherObject>}
|
|
148
148
|
*/
|
|
149
|
-
getSystemConfig(): Promise<
|
|
149
|
+
getSystemConfig(): Promise<ioBroker.SystemConfigObject>;
|
|
150
150
|
/**
|
|
151
151
|
* Get current expert mode
|
|
152
152
|
* @returns {boolean}
|
package/LegacyConnection.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
-
import { type HostInfo } from '@iobroker/js-controller-common/tools';
|
|
3
|
-
import { type FilteredNotificationInformation } from '@iobroker/js-controller-common-db/build/lib/common/notificationHandler';
|
|
2
|
+
import { type HostInfo } from '@iobroker/js-controller-common/build/esm/lib/common/tools';
|
|
3
|
+
import { type FilteredNotificationInformation } from '@iobroker/js-controller-common-db/build/esm/lib/common/notificationHandler';
|
|
4
4
|
/**
|
|
5
5
|
* Copyright 2020-2024, Denis Haev (bluefox) <dogafox@gmail.com>
|
|
6
6
|
*
|
package/README.md
CHANGED
|
@@ -670,6 +670,12 @@ socket.getObjectViewCustom('custom', 'state', 'startKey', 'endKey')
|
|
|
670
670
|
-->
|
|
671
671
|
|
|
672
672
|
## Changelog
|
|
673
|
+
### 4.13.13 (2024-05-09)
|
|
674
|
+
* (bluefox) Updated ioBroker types
|
|
675
|
+
|
|
676
|
+
### 4.13.12 (2024-05-06)
|
|
677
|
+
* (bluefox) All files are migrated to Typescript
|
|
678
|
+
|
|
673
679
|
### 4.13.11 (2024-04-23)
|
|
674
680
|
* (bluefox) Corrected the size of icons
|
|
675
681
|
|
package/index.d.ts
CHANGED
package/index.js
CHANGED
|
@@ -17,14 +17,15 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
17
17
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
18
18
|
};
|
|
19
19
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
20
|
-
exports.
|
|
21
|
-
exports.LegacyConnection = exports.AdminConnection = exports.PROGRESS = exports.Connection = exports.ConfigGeneric = exports.TextInput = exports.SimpleCronDialog = exports.SelectFile = exports.SelectID = exports.Message = exports.Error = exports.Cron = exports.Confirm = exports.ComplexCronDialog = exports.IconClearFilter = exports.IconDocumentReadOnly = exports.IconNoIcon = void 0;
|
|
20
|
+
exports.IconOpen = exports.IconLogout = exports.IconInstance = exports.IconFx = exports.IconExpert = exports.IconDocument = exports.IconDevice = exports.IconCopy = exports.IconClosed = exports.IconChannel = exports.IconAlias = exports.IconAdapter = exports.JsonConfigComponent = exports.LoaderMV = exports.LoaderPT = exports.LoaderVendor = exports.SimpleCron = exports.withWidth = exports.Utils = exports.UploadImage = exports.TreeTable = exports.ToggleThemeMenu = exports.TextWithIcon = exports.TableResize = exports.TabHeader = exports.TabContent = exports.TabContainer = exports.SelectWithIcon = exports.Schedule = exports.SaveCloseButtons = exports.Router = exports.ObjectBrowser = exports.MDUtils = exports.Logo = exports.Loader = exports.Image = exports.IconSelector = exports.IconPicker = exports.Icon = exports.FileViewer = exports.FileBrowser = exports.CustomModal = exports.copy = exports.ComplexCron = exports.ColorPicker = exports.Prompt = exports.I18n = exports.i18n = exports.GenericApp = exports.Theme = void 0;
|
|
21
|
+
exports.LegacyConnection = exports.AdminConnection = exports.PROGRESS = exports.Connection = exports.ConfigGeneric = exports.TextInput = exports.SimpleCronDialog = exports.SelectFile = exports.SelectID = exports.Message = exports.Error = exports.Cron = exports.Confirm = exports.ComplexCronDialog = exports.IconClearFilter = exports.IconDocumentReadOnly = exports.IconNoIcon = exports.IconState = void 0;
|
|
22
22
|
var Theme_1 = require("./Theme");
|
|
23
23
|
Object.defineProperty(exports, "Theme", { enumerable: true, get: function () { return __importDefault(Theme_1).default; } });
|
|
24
24
|
__exportStar(require("./Theme"), exports);
|
|
25
|
-
|
|
25
|
+
var GenericApp_1 = require("./GenericApp");
|
|
26
|
+
Object.defineProperty(exports, "GenericApp", { enumerable: true, get: function () { return __importDefault(GenericApp_1).default; } });
|
|
26
27
|
// export * from './GenericApp';
|
|
27
|
-
var i18n_1 = require("./i18n");
|
|
28
|
+
var i18n_1 = require("./i18n"); // deprecated
|
|
28
29
|
Object.defineProperty(exports, "i18n", { enumerable: true, get: function () { return __importDefault(i18n_1).default; } });
|
|
29
30
|
var i18n_2 = require("./i18n");
|
|
30
31
|
Object.defineProperty(exports, "I18n", { enumerable: true, get: function () { return __importDefault(i18n_2).default; } });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@iobroker/adapter-react-v5",
|
|
3
|
-
"version": "4.13.
|
|
3
|
+
"version": "4.13.13",
|
|
4
4
|
"description": "React classes to develop admin interfaces for ioBroker with react.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Denis Haev (bluefox)",
|
|
@@ -31,21 +31,21 @@
|
|
|
31
31
|
"@emotion/styled": "^11.11.5",
|
|
32
32
|
"@iobroker/dm-utils": "^0.1.9",
|
|
33
33
|
"@iobroker/json-config": "^6.17.6",
|
|
34
|
-
"@iobroker/socket-client": "^2.4.
|
|
35
|
-
"@iobroker/types": "^5.0.
|
|
36
|
-
"@iobroker/js-controller-common": "^5.0.
|
|
37
|
-
"@iobroker/js-controller-common-db": "^5.0.
|
|
38
|
-
"@mui/icons-material": "^5.15.
|
|
34
|
+
"@iobroker/socket-client": "^2.4.9",
|
|
35
|
+
"@iobroker/types": "^5.0.20-alpha.0-20240508-d36cddc8d",
|
|
36
|
+
"@iobroker/js-controller-common": "^5.0.20-alpha.0-20240429-12b5c7f4",
|
|
37
|
+
"@iobroker/js-controller-common-db": "^5.0.20-alpha.0-20240429-12b5c7f4",
|
|
38
|
+
"@mui/icons-material": "^5.15.17",
|
|
39
39
|
"@mui/material": "5.14.14",
|
|
40
40
|
"@mui/styles": "5.14.14",
|
|
41
|
-
"@mui/x-date-pickers": "^7.2
|
|
42
|
-
"@sentry/browser": "^7.
|
|
43
|
-
"@sentry/integrations": "^7.
|
|
41
|
+
"@mui/x-date-pickers": "^7.3.2",
|
|
42
|
+
"@sentry/browser": "^7.114.0",
|
|
43
|
+
"@sentry/integrations": "^7.114.0",
|
|
44
44
|
"react-color": "^2.19.3",
|
|
45
45
|
"react-colorful": "^5.6.1",
|
|
46
46
|
"react-cropper": "^2.3.3",
|
|
47
47
|
"react-dropzone": "^14.2.3",
|
|
48
|
-
"react-icons": "^5.1
|
|
48
|
+
"react-icons": "^5.2.1",
|
|
49
49
|
"react-inlinesvg": "4.0.3"
|
|
50
50
|
}
|
|
51
51
|
}
|