@iobroker/adapter-react-v5 4.6.3 → 4.6.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.
- package/Components/Router.d.ts +2 -2
- package/Components/Router.js +1 -1
- package/Components/Router.js.map +1 -1
- package/README.md +3 -0
- package/package.json +4 -4
package/Components/Router.d.ts
CHANGED
|
@@ -17,12 +17,12 @@ declare class Router<P, S> extends React.Component<P, S, any> {
|
|
|
17
17
|
};
|
|
18
18
|
/**
|
|
19
19
|
* Navigate to a new location. Any parameters that are not set will be taken from the current location.
|
|
20
|
-
* @param {string | undefined} [tab]
|
|
20
|
+
* @param {string | undefined | null} [tab]
|
|
21
21
|
* @param {string | undefined} [dialog]
|
|
22
22
|
* @param {string | undefined} [id]
|
|
23
23
|
* @param {string | undefined} [arg]
|
|
24
24
|
*/
|
|
25
|
-
static doNavigate(tab?: string | undefined, dialog?: string | undefined, id?: string | undefined, arg?: string | undefined): void;
|
|
25
|
+
static doNavigate(tab?: string | undefined | null, dialog?: string | undefined, id?: string | undefined, arg?: string | undefined): void;
|
|
26
26
|
/**
|
|
27
27
|
* @param {P} props The React properties of this component.
|
|
28
28
|
*/
|
package/Components/Router.js
CHANGED
|
@@ -76,7 +76,7 @@ var Router = /*#__PURE__*/function (_React$Component) {
|
|
|
76
76
|
|
|
77
77
|
/**
|
|
78
78
|
* Navigate to a new location. Any parameters that are not set will be taken from the current location.
|
|
79
|
-
* @param {string | undefined} [tab]
|
|
79
|
+
* @param {string | undefined | null} [tab]
|
|
80
80
|
* @param {string | undefined} [dialog]
|
|
81
81
|
* @param {string | undefined} [id]
|
|
82
82
|
* @param {string | undefined} [arg]
|
package/Components/Router.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Router.js","names":["_react","_interopRequireDefault","require","_createSuper","Derived","hasNativeReflectConstruct","_isNativeReflectConstruct","_createSuperInternal","Super","_getPrototypeOf2","result","NewTarget","constructor","Reflect","construct","arguments","apply","_possibleConstructorReturn2","sham","Proxy","Boolean","prototype","valueOf","call","e","Router","_React$Component","_inherits2","_super","props","_this","_classCallCheck2","onHashChangedBound","onHashChanged","bind","_assertThisInitialized2","_createClass2","key","value","componentDidMount","window","addEventListener","componentWillUnmount","removeEventListener","getLocation","hash","location","replace","parts","split","map","item","decodeURIComponent","console","error","concat","tab","dialog","id","arg","doNavigate","undefined","React","Component","_default","exports"],"sources":["Router.js"],"sourcesContent":["// please do not delete React, as without it other projects could not be compiled: ReferenceError: React is not defined\nimport React from 'react';\n\n/**\n * @template P Type of the properties' object.\n * @template S Type of the internal state object.\n * @extends {React.Component<P, S>}\n */\nclass Router extends React.Component {\n /**\n * @param {P} props The React properties of this component.\n */\n constructor(props) {\n super(props);\n this.onHashChangedBound = this.onHashChanged.bind(this);\n }\n\n componentDidMount() {\n window.addEventListener('hashchange', this.onHashChangedBound);\n }\n\n componentWillUnmount() {\n window.removeEventListener('hashchange', this.onHashChangedBound);\n }\n\n onHashChanged() {\n // override this function\n }\n\n /**\n * Gets the location object.\n * @returns {{ tab: string; dialog: string; id: string; arg: string; }}\n */\n static getLocation() {\n let hash = window.location.hash;\n hash = hash.replace(/^#/, '');\n const parts = hash.split('/').map(item => {\n try {\n return item ? decodeURIComponent(item) : '';\n } catch (e) {\n console.error(`Router: Cannot decode ${item}`);\n return item || '';\n }\n });\n // #tabName/dialogName/deviceId\n return {\n tab: parts[0] || '',\n dialog: parts[1] || '',\n id: parts[2] || '',\n arg: parts[3] || '',\n };\n }\n\n /**\n * Navigate to a new location. Any parameters that are not set will be taken from the current location.\n * @param {string | undefined} [tab]\n * @param {string | undefined} [dialog]\n * @param {string | undefined} [id]\n * @param {string | undefined} [arg]\n */\n static doNavigate(tab, dialog, id, arg) {\n let hash = '';\n const location = Router.getLocation();\n if (arg !== undefined && !id) {\n id = location.id;\n }\n if (id && !dialog) {\n dialog = location.dialog;\n }\n if (dialog && !tab) {\n tab = location.tab;\n } else if (tab === null) {\n tab = location.tab;\n }\n\n if (tab) {\n hash = `#${tab}`;\n if (dialog) {\n hash += `/${dialog}`;\n\n if (id) {\n hash += `/${id}`;\n if (arg !== undefined) {\n hash += `/${arg}`;\n }\n }\n }\n }\n if (window.location.hash !== hash) {\n window.location.hash = hash;\n }\n }\n}\n\nexport default Router;\n"],"mappings":";;;;;;;;;;;;;AACA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA0B,SAAAC,aAAAC,OAAA,QAAAC,yBAAA,GAAAC,yBAAA,oBAAAC,qBAAA,QAAAC,KAAA,OAAAC,gBAAA,aAAAL,OAAA,GAAAM,MAAA,MAAAL,yBAAA,QAAAM,SAAA,OAAAF,gBAAA,mBAAAG,WAAA,EAAAF,MAAA,GAAAG,OAAA,CAAAC,SAAA,CAAAN,KAAA,EAAAO,SAAA,EAAAJ,SAAA,YAAAD,MAAA,GAAAF,KAAA,CAAAQ,KAAA,OAAAD,SAAA,gBAAAE,2BAAA,mBAAAP,MAAA;AAAA,SAAAJ,0BAAA,eAAAO,OAAA,qBAAAA,OAAA,CAAAC,SAAA,oBAAAD,OAAA,CAAAC,SAAA,CAAAI,IAAA,2BAAAC,KAAA,oCAAAC,OAAA,CAAAC,SAAA,CAAAC,OAAA,CAAAC,IAAA,CAAAV,OAAA,CAAAC,SAAA,CAAAM,OAAA,8CAAAI,CAAA,sBAD1B;AAGA;AACA;AACA;AACA;AACA;AAJA,IAKMC,MAAM,0BAAAC,gBAAA;EAAA,IAAAC,UAAA,aAAAF,MAAA,EAAAC,gBAAA;EAAA,IAAAE,MAAA,GAAAzB,YAAA,CAAAsB,MAAA;EACR;AACJ;AACA;EACI,SAAAA,OAAYI,KAAK,EAAE;IAAA,IAAAC,KAAA;IAAA,IAAAC,gBAAA,mBAAAN,MAAA;IACfK,KAAA,GAAAF,MAAA,CAAAL,IAAA,OAAMM,KAAK;IACXC,KAAA,CAAKE,kBAAkB,GAAGF,KAAA,CAAKG,aAAa,CAACC,IAAI,KAAAC,uB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EA;AACJ;AACA;AACA;AACA;AACA;AACA;EANI;IAAAX,GAAA;IAAAC,KAAA,EAOA,SAAAsB,WAAkBJ,GAAG,EAAEC,MAAM,EAAEC,EAAE,EAAEC,GAAG,EAAE;MACpC,IAAId,IAAI,GAAG,EAAE;MACb,IAAMC,QAAQ,GAAGrB,MAAM,CAACmB,WAAW,CAAC,CAAC;MACrC,IAAIe,GAAG,KAAKE,SAAS,IAAI,CAACH,EAAE,EAAE;QAC1BA,EAAE,GAAGZ,QAAQ,CAACY,EAAE;MACpB;MACA,IAAIA,EAAE,IAAI,CAACD,MAAM,EAAE;QACfA,MAAM,GAAGX,QAAQ,CAACW,MAAM;MAC5B;MACA,IAAIA,MAAM,IAAI,CAACD,GAAG,EAAE;QAChBA,GAAG,GAAGV,QAAQ,CAACU,GAAG;MACtB,CAAC,MAAM,IAAIA,GAAG,KAAK,IAAI,EAAE;QACrBA,GAAG,GAAGV,QAAQ,CAACU,GAAG;MACtB;MAEA,IAAIA,GAAG,EAAE;QACLX,IAAI,OAAAU,MAAA,CAAOC,GAAG,CAAE;QAChB,IAAIC,MAAM,EAAE;UACRZ,IAAI,QAAAU,MAAA,CAAQE,MAAM,CAAE;UAEpB,IAAIC,EAAE,EAAE;YACJb,IAAI,QAAAU,MAAA,CAAQG,EAAE,CAAE;YAChB,IAAIC,GAAG,KAAKE,SAAS,EAAE;cACnBhB,IAAI,QAAAU,MAAA,CAAQI,GAAG,CAAE;YACrB;UACJ;QACJ;MACJ;MACA,IAAInB,MAAM,CAACM,QAAQ,CAACD,IAAI,KAAKA,IAAI,EAAE;QAC/BL,MAAM,CAACM,QAAQ,CAACD,IAAI,GAAGA,IAAI;MAC/B;IACJ;EAAC;EAAA,OAAApB,MAAA;AAAA,EAnFgBqC,iBAAK,CAACC,SAAS;AAAA,IAAAC,QAAA,GAAAC,OAAA,cAsFrBxC,MAAM"}
|
|
1
|
+
{"version":3,"file":"Router.js","names":["_react","_interopRequireDefault","require","_createSuper","Derived","hasNativeReflectConstruct","_isNativeReflectConstruct","_createSuperInternal","Super","_getPrototypeOf2","result","NewTarget","constructor","Reflect","construct","arguments","apply","_possibleConstructorReturn2","sham","Proxy","Boolean","prototype","valueOf","call","e","Router","_React$Component","_inherits2","_super","props","_this","_classCallCheck2","onHashChangedBound","onHashChanged","bind","_assertThisInitialized2","_createClass2","key","value","componentDidMount","window","addEventListener","componentWillUnmount","removeEventListener","getLocation","hash","location","replace","parts","split","map","item","decodeURIComponent","console","error","concat","tab","dialog","id","arg","doNavigate","undefined","React","Component","_default","exports"],"sources":["Router.js"],"sourcesContent":["// please do not delete React, as without it other projects could not be compiled: ReferenceError: React is not defined\nimport React from 'react';\n\n/**\n * @template P Type of the properties' object.\n * @template S Type of the internal state object.\n * @extends {React.Component<P, S>}\n */\nclass Router extends React.Component {\n /**\n * @param {P} props The React properties of this component.\n */\n constructor(props) {\n super(props);\n this.onHashChangedBound = this.onHashChanged.bind(this);\n }\n\n componentDidMount() {\n window.addEventListener('hashchange', this.onHashChangedBound);\n }\n\n componentWillUnmount() {\n window.removeEventListener('hashchange', this.onHashChangedBound);\n }\n\n onHashChanged() {\n // override this function\n }\n\n /**\n * Gets the location object.\n * @returns {{ tab: string; dialog: string; id: string; arg: string; }}\n */\n static getLocation() {\n let hash = window.location.hash;\n hash = hash.replace(/^#/, '');\n const parts = hash.split('/').map(item => {\n try {\n return item ? decodeURIComponent(item) : '';\n } catch (e) {\n console.error(`Router: Cannot decode ${item}`);\n return item || '';\n }\n });\n // #tabName/dialogName/deviceId\n return {\n tab: parts[0] || '',\n dialog: parts[1] || '',\n id: parts[2] || '',\n arg: parts[3] || '',\n };\n }\n\n /**\n * Navigate to a new location. Any parameters that are not set will be taken from the current location.\n * @param {string | undefined | null} [tab]\n * @param {string | undefined} [dialog]\n * @param {string | undefined} [id]\n * @param {string | undefined} [arg]\n */\n static doNavigate(tab, dialog, id, arg) {\n let hash = '';\n const location = Router.getLocation();\n if (arg !== undefined && !id) {\n id = location.id;\n }\n if (id && !dialog) {\n dialog = location.dialog;\n }\n if (dialog && !tab) {\n tab = location.tab;\n } else if (tab === null) {\n tab = location.tab;\n }\n\n if (tab) {\n hash = `#${tab}`;\n if (dialog) {\n hash += `/${dialog}`;\n\n if (id) {\n hash += `/${id}`;\n if (arg !== undefined) {\n hash += `/${arg}`;\n }\n }\n }\n }\n if (window.location.hash !== hash) {\n window.location.hash = hash;\n }\n }\n}\n\nexport default Router;\n"],"mappings":";;;;;;;;;;;;;AACA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA0B,SAAAC,aAAAC,OAAA,QAAAC,yBAAA,GAAAC,yBAAA,oBAAAC,qBAAA,QAAAC,KAAA,OAAAC,gBAAA,aAAAL,OAAA,GAAAM,MAAA,MAAAL,yBAAA,QAAAM,SAAA,OAAAF,gBAAA,mBAAAG,WAAA,EAAAF,MAAA,GAAAG,OAAA,CAAAC,SAAA,CAAAN,KAAA,EAAAO,SAAA,EAAAJ,SAAA,YAAAD,MAAA,GAAAF,KAAA,CAAAQ,KAAA,OAAAD,SAAA,gBAAAE,2BAAA,mBAAAP,MAAA;AAAA,SAAAJ,0BAAA,eAAAO,OAAA,qBAAAA,OAAA,CAAAC,SAAA,oBAAAD,OAAA,CAAAC,SAAA,CAAAI,IAAA,2BAAAC,KAAA,oCAAAC,OAAA,CAAAC,SAAA,CAAAC,OAAA,CAAAC,IAAA,CAAAV,OAAA,CAAAC,SAAA,CAAAM,OAAA,8CAAAI,CAAA,sBAD1B;AAGA;AACA;AACA;AACA;AACA;AAJA,IAKMC,MAAM,0BAAAC,gBAAA;EAAA,IAAAC,UAAA,aAAAF,MAAA,EAAAC,gBAAA;EAAA,IAAAE,MAAA,GAAAzB,YAAA,CAAAsB,MAAA;EACR;AACJ;AACA;EACI,SAAAA,OAAYI,KAAK,EAAE;IAAA,IAAAC,KAAA;IAAA,IAAAC,gBAAA,mBAAAN,MAAA;IACfK,KAAA,GAAAF,MAAA,CAAAL,IAAA,OAAMM,KAAK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AAM"}
|
package/README.md
CHANGED
|
@@ -670,6 +670,9 @@ socket.getObjectViewCustom('custom', 'state', 'startKey', 'endKey')
|
|
|
670
670
|
-->
|
|
671
671
|
|
|
672
672
|
## Changelog
|
|
673
|
+
### 4.6.4 (2023-10-11)
|
|
674
|
+
* (bluefox) Updated the packages
|
|
675
|
+
|
|
673
676
|
### 4.6.3 (2023-10-09)
|
|
674
677
|
* (bluefox) Just updated the packages
|
|
675
678
|
* (bluefox) Synced with admin
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@iobroker/adapter-react-v5",
|
|
3
|
-
"version": "4.6.
|
|
3
|
+
"version": "4.6.4",
|
|
4
4
|
"description": "React classes to develop admin interfaces for ioBroker with react.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Denis Haev (bluefox)",
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
"@emotion/react": "^11.11.1",
|
|
31
31
|
"@emotion/styled": "^11.11.0",
|
|
32
32
|
"@iobroker/socket-client": "^2.3.9",
|
|
33
|
-
"@mui/icons-material": "^5.14.
|
|
34
|
-
"@mui/material": "^5.14.
|
|
35
|
-
"@mui/styles": "^5.14.
|
|
33
|
+
"@mui/icons-material": "^5.14.13",
|
|
34
|
+
"@mui/material": "^5.14.13",
|
|
35
|
+
"@mui/styles": "^5.14.13",
|
|
36
36
|
"@mui/x-date-pickers": "6.16.1",
|
|
37
37
|
"@sentry/browser": "^7.73.0",
|
|
38
38
|
"@sentry/integrations": "^7.73.0",
|