This commit is contained in:
MichaelDvP
2023-05-25 10:17:41 +02:00
20 changed files with 397 additions and 408 deletions

View File

@@ -25,6 +25,8 @@
"regex": "cpp", "regex": "cpp",
"tuple": "cpp", "tuple": "cpp",
"type_traits": "cpp", "type_traits": "cpp",
"utility": "cpp" "utility": "cpp",
"string": "cpp",
"string_view": "cpp"
} }
} }

View File

@@ -22,11 +22,11 @@
"@emotion/react": "^11.11.0", "@emotion/react": "^11.11.0",
"@emotion/styled": "^11.11.0", "@emotion/styled": "^11.11.0",
"@mui/icons-material": "^5.11.16", "@mui/icons-material": "^5.11.16",
"@mui/material": "^5.13.0", "@mui/material": "^5.13.2",
"@table-library/react-table-library": "4.1.4", "@table-library/react-table-library": "4.1.4",
"@types/lodash-es": "^4.17.7", "@types/lodash-es": "^4.17.7",
"@types/node": "^20.1.2", "@types/node": "^20.2.3",
"@types/react": "^18.2.6", "@types/react": "^18.2.7",
"@types/react-dom": "^18.2.4", "@types/react-dom": "^18.2.4",
"@types/react-router-dom": "^5.3.3", "@types/react-router-dom": "^5.3.3",
"async-validator": "^4.2.5", "async-validator": "^4.2.5",
@@ -38,17 +38,17 @@
"react-dom": "latest", "react-dom": "latest",
"react-dropzone": "^14.2.3", "react-dropzone": "^14.2.3",
"react-icons": "^4.8.0", "react-icons": "^4.8.0",
"react-router-dom": "^6.11.1", "react-router-dom": "^6.11.2",
"react-toastify": "^9.1.2", "react-toastify": "^9.1.3",
"sockette": "^2.0.6", "sockette": "^2.0.6",
"typesafe-i18n": "^5.24.3", "typesafe-i18n": "^5.24.3",
"typescript": "^5.0.4" "typescript": "^5.0.4"
}, },
"devDependencies": { "devDependencies": {
"@typescript-eslint/eslint-plugin": "^5.59.5", "@typescript-eslint/eslint-plugin": "^5.59.7",
"@typescript-eslint/parser": "^5.59.5", "@typescript-eslint/parser": "^5.59.7",
"@vitejs/plugin-react-swc": "^3.3.1", "@vitejs/plugin-react-swc": "^3.3.1",
"eslint": "^8.40.0", "eslint": "^8.41.0",
"eslint-config-airbnb": "^19.0.4", "eslint-config-airbnb": "^19.0.4",
"eslint-config-airbnb-typescript": "^17.0.0", "eslint-config-airbnb-typescript": "^17.0.0",
"eslint-config-prettier": "^8.8.0", "eslint-config-prettier": "^8.8.0",
@@ -63,8 +63,8 @@
"npm-run-all": "^4.1.5", "npm-run-all": "^4.1.5",
"prettier": "^2.8.8", "prettier": "^2.8.8",
"rollup-plugin-visualizer": "^5.9.0", "rollup-plugin-visualizer": "^5.9.0",
"terser": "^5.17.3", "terser": "^5.17.6",
"vite": "^4.3.5", "vite": "^4.3.8",
"vite-plugin-svgr": "^3.2.0", "vite-plugin-svgr": "^3.2.0",
"vite-tsconfig-paths": "^4.2.0" "vite-tsconfig-paths": "^4.2.0"
}, },

View File

@@ -18,19 +18,6 @@ import { useRest, updateValueDirty, extractErrorMessage } from 'utils';
export const LOG_EVENTSOURCE_URL = EVENT_SOURCE_ROOT + 'log'; export const LOG_EVENTSOURCE_URL = EVENT_SOURCE_ROOT + 'log';
// const useWindowSize = () => {
// const [size, setSize] = useState([0, 0]);
// useLayoutEffect(() => {
// function updateSize() {
// setSize([window.innerWidth, window.innerHeight]);
// }
// window.addEventListener('resize', updateSize);
// updateSize();
// return () => window.removeEventListener('resize', updateSize);
// }, []);
// return size;
// };
const LogEntryLine = styled('div')(() => ({ const LogEntryLine = styled('div')(() => ({
color: '#bbbbbb', color: '#bbbbbb',
fontFamily: 'monospace', fontFamily: 'monospace',
@@ -62,8 +49,6 @@ const levelLabel = (level: LogLevel) => {
}; };
const SystemLog: FC = () => { const SystemLog: FC = () => {
// useWindowSize();
const { LL } = useI18nContext(); const { LL } = useI18nContext();
const { loadData, data, setData, origData, dirtyFlags, blocker, setDirtyFlags, setOrigData } = useRest<LogSettings>({ const { loadData, data, setData, origData, dirtyFlags, blocker, setDirtyFlags, setOrigData } = useRest<LogSettings>({

View File

@@ -37,7 +37,6 @@ const de: Translation = {
BRAND: 'Marke', BRAND: 'Marke',
ENTITY_NAME: 'Entitätsname', ENTITY_NAME: 'Entitätsname',
VALUE: '{{Wert|wert}}', VALUE: '{{Wert|wert}}',
SHOW_FAV: 'nur Favoriten anzeigen',
DEVICE_DATA: 'Gerätedaten', DEVICE_DATA: 'Gerätedaten',
SENSOR_DATA: 'Sensordaten', SENSOR_DATA: 'Sensordaten',
DEVICES: 'Geräte', DEVICES: 'Geräte',

View File

@@ -37,7 +37,6 @@ const en: Translation = {
BRAND: 'Brand', BRAND: 'Brand',
ENTITY_NAME: 'Entity Name', ENTITY_NAME: 'Entity Name',
VALUE: '{{Value|value}}', VALUE: '{{Value|value}}',
SHOW_FAV: 'only show favorites',
DEVICE_DATA: 'Device Data', DEVICE_DATA: 'Device Data',
SENSOR_DATA: 'Sensor Data', SENSOR_DATA: 'Sensor Data',
DEVICES: 'Devices', DEVICES: 'Devices',

View File

@@ -37,7 +37,6 @@ const fr: Translation = {
BRAND: 'Marque', BRAND: 'Marque',
ENTITY_NAME: 'Nom de l\'entité', ENTITY_NAME: 'Nom de l\'entité',
VALUE: 'Valeur', VALUE: 'Valeur',
SHOW_FAV: 'ne montrer que les favoris',
DEVICE_DATA: 'Données des appareils', DEVICE_DATA: 'Données des appareils',
SENSOR_DATA: 'Données des capteurs', SENSOR_DATA: 'Données des capteurs',
DEVICES: 'Appareils', DEVICES: 'Appareils',

View File

@@ -37,7 +37,6 @@ const nl: Translation = {
BRAND: 'Merk', BRAND: 'Merk',
ENTITY_NAME: 'Entiteit', ENTITY_NAME: 'Entiteit',
VALUE: '{{Waarde|waarde}}', VALUE: '{{Waarde|waarde}}',
SHOW_FAV: 'alleen favorieten weergeven',
SENSOR_DATA: 'Sensor data', SENSOR_DATA: 'Sensor data',
DEVICE_DATA: 'Apparaat data', DEVICE_DATA: 'Apparaat data',
DEVICES: 'Apparaten', DEVICES: 'Apparaten',

View File

@@ -37,7 +37,6 @@ const no: Translation = {
BRAND: 'Fabrikat', BRAND: 'Fabrikat',
ENTITY_NAME: 'Objektsnavn', ENTITY_NAME: 'Objektsnavn',
VALUE: '{{Verdi|verdi}}', VALUE: '{{Verdi|verdi}}',
SHOW_FAV: ' Vis kun favoritter',
DEVICE_DATA: 'Enheterdata', DEVICE_DATA: 'Enheterdata',
SENSOR_DATA: 'Sensordata', SENSOR_DATA: 'Sensordata',
DEVICES: 'Enheter', DEVICES: 'Enheter',

View File

@@ -37,7 +37,6 @@ const pl: BaseTranslation = {
VERSION: 'Wersja', VERSION: 'Wersja',
ENTITY_NAME: 'Nazwa encji', ENTITY_NAME: 'Nazwa encji',
VALUE: '{{W|w|}}artość', VALUE: '{{W|w|}}artość',
SHOW_FAV: 'Pokaż tylko "ulubione"',
DEVICE_DATA: 'Dane z urządzeń', DEVICE_DATA: 'Dane z urządzeń',
SENSOR_DATA: 'Dane z czujników', SENSOR_DATA: 'Dane z czujników',
DEVICES: 'Urządzenia', DEVICES: 'Urządzenia',

View File

@@ -37,7 +37,6 @@ const sv: Translation = {
BRAND: 'Fabrikat', BRAND: 'Fabrikat',
ENTITY_NAME: 'Entitetsnamn', ENTITY_NAME: 'Entitetsnamn',
VALUE: '{{Värde|värde}}', VALUE: '{{Värde|värde}}',
SHOW_FAV: 'Visa enbart favoriter',
DEVICE_DATA: 'Enhets data', DEVICE_DATA: 'Enhets data',
SENSOR_DATA: 'Sensor data', SENSOR_DATA: 'Sensor data',
DEVICES: 'Enheter', DEVICES: 'Enheter',

View File

@@ -37,7 +37,6 @@ const tr: Translation = {
BRAND: 'Marka', BRAND: 'Marka',
ENTITY_NAME: 'Valık Adı', ENTITY_NAME: 'Valık Adı',
VALUE: '{{Değer|değer}}', VALUE: '{{Değer|değer}}',
SHOW_FAV: 'sadece favorileri göster',
DEVICE_DATA: 'Cihaz Bilgisi', DEVICE_DATA: 'Cihaz Bilgisi',
SENSOR_DATA: 'Sensör Bilgisi', SENSOR_DATA: 'Sensör Bilgisi',
DEVICES: 'Cihazlar', DEVICES: 'Cihazlar',

View File

@@ -1,3 +1,4 @@
import CancelIcon from '@mui/icons-material/Cancel';
import CommentsDisabledOutlinedIcon from '@mui/icons-material/CommentsDisabledOutlined'; import CommentsDisabledOutlinedIcon from '@mui/icons-material/CommentsDisabledOutlined';
import EditIcon from '@mui/icons-material/Edit'; import EditIcon from '@mui/icons-material/Edit';
import EditOffOutlinedIcon from '@mui/icons-material/EditOffOutlined'; import EditOffOutlinedIcon from '@mui/icons-material/EditOffOutlined';
@@ -7,9 +8,10 @@ import KeyboardArrowDownOutlinedIcon from '@mui/icons-material/KeyboardArrowDown
import KeyboardArrowUpOutlinedIcon from '@mui/icons-material/KeyboardArrowUpOutlined'; import KeyboardArrowUpOutlinedIcon from '@mui/icons-material/KeyboardArrowUpOutlined';
import PlayArrowIcon from '@mui/icons-material/PlayArrow'; import PlayArrowIcon from '@mui/icons-material/PlayArrow';
import RefreshIcon from '@mui/icons-material/Refresh'; import RefreshIcon from '@mui/icons-material/Refresh';
import SettingsBackupRestoreIcon from '@mui/icons-material/SettingsBackupRestore';
import StarIcon from '@mui/icons-material/Star'; import StarIcon from '@mui/icons-material/Star';
import StarBorderOutlinedIcon from '@mui/icons-material/StarBorderOutlined';
import UnfoldMoreOutlinedIcon from '@mui/icons-material/UnfoldMoreOutlined'; import UnfoldMoreOutlinedIcon from '@mui/icons-material/UnfoldMoreOutlined';
import { import {
Button, Button,
Dialog, Dialog,
@@ -20,15 +22,15 @@ import {
List, List,
ListItem, ListItem,
ListItemText, ListItemText,
FormControlLabel, Box,
Checkbox, Grid,
Box Typography
} from '@mui/material'; } from '@mui/material';
import { useRowSelect } from '@table-library/react-table-library/select'; import { useRowSelect } from '@table-library/react-table-library/select';
import { useSort, SortToggleType } from '@table-library/react-table-library/sort'; import { useSort, SortToggleType } from '@table-library/react-table-library/sort';
import { Table, Header, HeaderRow, HeaderCell, Body, Row, Cell } from '@table-library/react-table-library/table'; import { Table, Header, HeaderRow, HeaderCell, Body, Row, Cell } from '@table-library/react-table-library/table';
import { useTheme } from '@table-library/react-table-library/theme'; import { useTheme } from '@table-library/react-table-library/theme';
import { useState, useContext, useEffect, useCallback } from 'react'; import { useState, useContext, useEffect, useCallback, useLayoutEffect } from 'react';
import { IconContext } from 'react-icons'; import { IconContext } from 'react-icons';
import { toast } from 'react-toastify'; import { toast } from 'react-toastify';
@@ -48,24 +50,41 @@ import { AuthenticatedContext } from 'contexts/authentication';
import { useI18nContext } from 'i18n/i18n-react'; import { useI18nContext } from 'i18n/i18n-react';
import { extractErrorMessage } from 'utils'; import { extractErrorMessage } from 'utils';
const topOffset = () => document.getElementById('devices-window')?.getBoundingClientRect().bottom || 0;
const leftOffset = () => document.getElementById('devices-window')?.getBoundingClientRect().left || 0;
const DashboardDevices: FC = () => { const DashboardDevices: FC = () => {
const [size, setSize] = useState([0, 0]);
const { me } = useContext(AuthenticatedContext); const { me } = useContext(AuthenticatedContext);
const { LL } = useI18nContext(); const { LL } = useI18nContext();
const [deviceData, setDeviceData] = useState<DeviceData>({ label: '', data: [] }); const [deviceData, setDeviceData] = useState<DeviceData>({ data: [] });
const [selectedDeviceValue, setSelectedDeviceValue] = useState<DeviceValue>(); const [selectedDeviceValue, setSelectedDeviceValue] = useState<DeviceValue>();
const [deviceDetails, setDeviceDetails] = useState<number>(-1);
const [onlyFav, setOnlyFav] = useState(false); const [onlyFav, setOnlyFav] = useState(false);
const [selectedDevice, setSelectedDevice] = useState<number>();
const [deviceValueDialogOpen, setDeviceValueDialogOpen] = useState(false); const [deviceValueDialogOpen, setDeviceValueDialogOpen] = useState(false);
const [showDeviceInfo, setShowDeviceInfo] = useState<boolean>(false);
const [selectedDevice, setSelectedDevice] = useState<number>();
const [coreData, setCoreData] = useState<CoreData>({ const [coreData, setCoreData] = useState<CoreData>({
connected: true, connected: true,
devices: [] devices: []
}); });
useLayoutEffect(() => {
function updateSize() {
setSize([window.innerWidth, window.innerHeight]);
}
window.addEventListener('resize', updateSize);
updateSize();
return () => window.removeEventListener('resize', updateSize);
}, []);
const leftOffset = () => {
const left = document.getElementById('devices-window')?.getBoundingClientRect().left;
const right = document.getElementById('devices-window')?.getBoundingClientRect().right;
if (!left || !right) {
return 0;
}
return left + (right - left < 400 ? 0 : 200);
};
const common_theme = useTheme({ const common_theme = useTheme({
BaseRow: ` BaseRow: `
font-size: 14px; font-size: 14px;
@@ -79,7 +98,7 @@ const DashboardDevices: FC = () => {
} }
`, `,
Row: ` Row: `
background-color: #1e1e1e; background-color: #1E1E1E;
position: relative; position: relative;
cursor: pointer; cursor: pointer;
.td { .td {
@@ -95,11 +114,6 @@ const DashboardDevices: FC = () => {
border-top: 1px solid #177ac9; border-top: 1px solid #177ac9;
border-bottom: 1px solid #177ac9; border-bottom: 1px solid #177ac9;
} }
`,
Cell: `
&:last-of-type {
text-align: right;
},
` `
}); });
@@ -107,7 +121,7 @@ const DashboardDevices: FC = () => {
common_theme, common_theme,
{ {
Table: ` Table: `
--data-table-library_grid-template-columns: 40px 160px repeat(1, minmax(0, 1fr)) 100px 40px; --data-table-library_grid-template-columns: 40px repeat(1, minmax(0, 1fr)) 130px;
`, `,
BaseRow: ` BaseRow: `
.td { .td {
@@ -134,21 +148,28 @@ const DashboardDevices: FC = () => {
common_theme, common_theme,
{ {
Table: ` Table: `
--data-table-library_grid-template-columns: minmax(0, 1fr) 30% 40px; --data-table-library_grid-template-columns: minmax(0, 1fr) 150px 40px;
`, height: auto;
BaseRow: ` max-height: 100%;
.td { overflow-y: scroll;
height: 32px; ::-webkit-scrollbar {
display:none;
} }
`, `,
BaseCell: ` BaseCell: `
&:nth-of-type(1) {
border-left: 1px solid #177ac9;
},
&:nth-of-type(2) { &:nth-of-type(2) {
text-align: right; text-align: right;
}, },
&:nth-of-type(3) {
border-right: 1px solid #177ac9;
}
`, `,
HeaderRow: ` HeaderRow: `
.th { .th {
height: 36px; border-top: 1px solid #565656;
} }
`, `,
Row: ` Row: `
@@ -195,6 +216,7 @@ const DashboardDevices: FC = () => {
}; };
function onSelectChange(action: any, state: any) { function onSelectChange(action: any, state: any) {
setDeviceData({ data: [] });
setSelectedDevice(state.id); setSelectedDevice(state.id);
if (action.type === 'ADD_BY_ID_EXCLUSIVELY') { if (action.type === 'ADD_BY_ID_EXCLUSIVELY') {
void fetchDeviceData(state.id); void fetchDeviceData(state.id);
@@ -208,6 +230,28 @@ const DashboardDevices: FC = () => {
} }
); );
const resetDeviceSelect = () => {
device_select.fns.onRemoveAll();
};
const escFunction = useCallback(
(event: any) => {
if (event.keyCode === 27) {
if (device_select) {
device_select.fns.onRemoveAll();
}
}
},
[device_select]
);
useEffect(() => {
document.addEventListener('keydown', escFunction);
return () => {
document.removeEventListener('keydown', escFunction);
};
}, [escFunction]);
const fetchCoreData = useCallback(async () => { const fetchCoreData = useCallback(async () => {
try { try {
setSelectedDevice(undefined); setSelectedDevice(undefined);
@@ -276,10 +320,17 @@ const DashboardDevices: FC = () => {
}, },
{ accessor: (dv: any) => DeviceValueUOM_s[dv.u], name: 'UoM' } { accessor: (dv: any) => DeviceValueUOM_s[dv.u], name: 'UoM' }
]; ];
const deviceIndex = coreData.devices.findIndex((d) => d.id === device_select.state.id);
if (deviceIndex === -1) {
return;
}
const filename = coreData.devices[deviceIndex].tn + '_' + coreData.devices[deviceIndex].n;
downloadAsCsv( downloadAsCsv(
columns, columns,
onlyFav ? deviceData.data.filter((dv) => hasMask(dv.id, DeviceEntityMask.DV_FAVORITE)) : deviceData.data, onlyFav ? deviceData.data.filter((dv) => hasMask(dv.id, DeviceEntityMask.DV_FAVORITE)) : deviceData.data,
'device_entities' filename
); );
}; };
@@ -314,42 +365,46 @@ const DashboardDevices: FC = () => {
}; };
const renderDeviceDetails = () => { const renderDeviceDetails = () => {
if (coreData && coreData.devices.length > 0 && deviceDetails !== -1) { if (showDeviceInfo) {
const device = coreData.devices[deviceDetails]; const deviceIndex = coreData.devices.findIndex((d) => d.id === device_select.state.id);
if (deviceIndex === -1) {
return;
}
return ( return (
<Dialog open={deviceDetails !== -1} onClose={() => setDeviceDetails(-1)}> <Dialog open={showDeviceInfo} onClose={() => setShowDeviceInfo(false)}>
<DialogTitle>{LL.DEVICE_DETAILS()}</DialogTitle> <DialogTitle>{LL.DEVICE_DETAILS()}</DialogTitle>
<DialogContent dividers> <DialogContent dividers>
<List dense={true}> <List dense={true}>
<ListItem> <ListItem>
<ListItemText primary={LL.TYPE(0)} secondary={device.tn} /> <ListItemText primary={LL.TYPE(0)} secondary={coreData.devices[deviceIndex].tn} />
</ListItem> </ListItem>
<ListItem> <ListItem>
<ListItemText primary={LL.NAME(0)} secondary={device.n} /> <ListItemText primary={LL.NAME(0)} secondary={coreData.devices[deviceIndex].n} />
</ListItem> </ListItem>
{device.t !== DeviceType.CUSTOM && ( {coreData.devices[deviceIndex].t !== DeviceType.CUSTOM && (
<> <>
<ListItem> <ListItem>
<ListItemText primary={LL.BRAND()} secondary={device.b} /> <ListItemText primary={LL.BRAND()} secondary={coreData.devices[deviceIndex].b} />
</ListItem> </ListItem>
<ListItem> <ListItem>
<ListItemText <ListItemText
primary={LL.ID_OF(LL.DEVICE())} primary={LL.ID_OF(LL.DEVICE())}
secondary={'0x' + ('00' + device.d.toString(16).toUpperCase()).slice(-2)} secondary={'0x' + ('00' + coreData.devices[deviceIndex].d.toString(16).toUpperCase()).slice(-2)}
/> />
</ListItem> </ListItem>
<ListItem> <ListItem>
<ListItemText primary={LL.ID_OF(LL.PRODUCT())} secondary={device.p} /> <ListItemText primary={LL.ID_OF(LL.PRODUCT())} secondary={coreData.devices[deviceIndex].p} />
</ListItem> </ListItem>
<ListItem> <ListItem>
<ListItemText primary={LL.VERSION()} secondary={device.v} /> <ListItemText primary={LL.VERSION()} secondary={coreData.devices[deviceIndex].v} />
</ListItem> </ListItem>
</> </>
)} )}
</List> </List>
</DialogContent> </DialogContent>
<DialogActions> <DialogActions>
<Button variant="outlined" onClick={() => setDeviceDetails(-1)} color="secondary"> <Button variant="outlined" onClick={() => setShowDeviceInfo(false)} color="secondary">
{LL.CLOSE()} {LL.CLOSE()}
</Button> </Button>
</DialogActions> </DialogActions>
@@ -365,37 +420,24 @@ const DashboardDevices: FC = () => {
<MessageBox my={2} level="warning" message={LL.EMS_BUS_SCANNING()} /> <MessageBox my={2} level="warning" message={LL.EMS_BUS_SCANNING()} />
)} )}
<Table <Table data={{ nodes: coreData.devices }} select={device_select} theme={device_theme} layout={{ custom: true }}>
data={{ nodes: selectedDevice ? coreData.devices.filter((dv) => dv.id === selectedDevice) : coreData.devices }}
select={device_select}
theme={device_theme}
layout={{ custom: true }}
>
{(tableList: any) => ( {(tableList: any) => (
<> <>
<Header> <Header>
<HeaderRow> <HeaderRow>
<HeaderCell stiff /> <HeaderCell stiff />
<HeaderCell stiff>{LL.TYPE(0)}</HeaderCell>
<HeaderCell resize>{LL.DESCRIPTION()}</HeaderCell> <HeaderCell resize>{LL.DESCRIPTION()}</HeaderCell>
<HeaderCell stiff>{LL.ENTITIES()}</HeaderCell> <HeaderCell stiff>{LL.TYPE(0)}</HeaderCell>
<HeaderCell stiff />
</HeaderRow> </HeaderRow>
</Header> </Header>
<Body> <Body>
{tableList.map((device: Device, index: number) => ( {tableList.map((device: Device) => (
<Row key={device.id} item={device}> <Row key={device.id} item={device}>
<Cell stiff> <Cell stiff>
<DeviceIcon type_id={device.t} /> <DeviceIcon type_id={device.t} />
</Cell> </Cell>
<Cell stiff>{device.tn}</Cell>
<Cell>{device.n}</Cell> <Cell>{device.n}</Cell>
<Cell stiff>{device.e}</Cell> <Cell stiff>{device.tn}</Cell>
<Cell stiff>
<IconButton size="small" onClick={() => setDeviceDetails(index)}>
<InfoOutlinedIcon color="info" sx={{ fontSize: 16, verticalAlign: 'middle' }} />
</IconButton>
</Cell>
</Row> </Row>
))} ))}
</Body> </Body>
@@ -414,11 +456,9 @@ const DashboardDevices: FC = () => {
return; return;
} }
const sendCommand = (dv: DeviceValue) => { const showDeviceValue = (dv: DeviceValue) => {
if (dv.c && me.admin && !hasMask(dv.id, DeviceEntityMask.DV_READONLY)) { setSelectedDeviceValue(dv);
setSelectedDeviceValue(dv); setDeviceValueDialogOpen(true);
setDeviceValueDialogOpen(true);
}
}; };
const renderNameCell = (dv: DeviceValue) => ( const renderNameCell = (dv: DeviceValue) => (
@@ -432,37 +472,68 @@ const DashboardDevices: FC = () => {
</> </>
); );
const shown_data = onlyFav
? deviceData.data.filter((dv) => hasMask(dv.id, DeviceEntityMask.DV_FAVORITE))
: deviceData.data;
const deviceIndex = coreData.devices.findIndex((d) => d.id === device_select.state.id);
if (deviceIndex === -1) {
return;
}
return ( return (
<Box <Box
sx={{ sx={{
backgroundColor: 'black', backgroundColor: 'black',
overflowY: 'scroll',
position: 'absolute', position: 'absolute',
right: 18,
bottom: 18,
left: () => leftOffset(), left: () => leftOffset(),
top: () => topOffset() right: 16,
bottom: 0,
top: 128,
maxHeight: () => size[1] - 210,
zIndex: 'modal'
}} }}
> >
<FormControlLabel <Box sx={{ border: '1px solid #177ac9' }}>
control={<Checkbox size="small" name="onlyFav" checked={onlyFav} onChange={() => setOnlyFav(!onlyFav)} />} <Grid container justifyContent="space-between">
label={ <Box color="warning.main" ml={1}>
<span style={{ fontSize: '12px' }}> <Typography noWrap variant="h6">
{LL.SHOW_FAV()}&nbsp;( {coreData.devices[deviceIndex].n}
<StarIcon color="primary" sx={{ fontSize: 12 }} />) &nbsp;({shown_data.length})
</span> </Typography>
} </Box>
labelPlacement="start" <Grid item zeroMinWidth justifyContent="flex-end">
/> <IconButton onClick={resetDeviceSelect}>
<CancelIcon color="info" sx={{ fontSize: 18, verticalAlign: 'middle' }} />
</IconButton>
</Grid>
</Grid>
<Grid item xs>
<IconButton onClick={() => setShowDeviceInfo(true)}>
<InfoOutlinedIcon color="primary" sx={{ fontSize: 18, verticalAlign: 'middle' }} />
</IconButton>
<IconButton onClick={handleDownloadCsv}>
<DownloadIcon color="primary" sx={{ fontSize: 18, verticalAlign: 'middle' }} />
</IconButton>
<IconButton onClick={() => setOnlyFav(!onlyFav)}>
{onlyFav ? (
<StarIcon color="primary" sx={{ fontSize: 18, verticalAlign: 'middle' }} />
) : (
<StarBorderOutlinedIcon color="primary" sx={{ fontSize: 18, verticalAlign: 'middle' }} />
)}
</IconButton>
<IconButton onClick={refreshData}>
<RefreshIcon color="primary" sx={{ fontSize: 18, verticalAlign: 'middle' }} />
</IconButton>
</Grid>
</Box>
<Table <Table
data={{ data={{ nodes: shown_data }}
nodes: onlyFav
? deviceData.data.filter((dv) => hasMask(dv.id, DeviceEntityMask.DV_FAVORITE))
: deviceData.data
}}
theme={data_theme} theme={data_theme}
sort={dv_sort} sort={dv_sort}
layout={{ custom: true }} layout={{ custom: true, fixedHeader: true }}
> >
{(tableList: any) => ( {(tableList: any) => (
<> <>
@@ -493,12 +564,12 @@ const DashboardDevices: FC = () => {
</Header> </Header>
<Body> <Body>
{tableList.map((dv: DeviceValue) => ( {tableList.map((dv: DeviceValue) => (
<Row key={dv.id} item={dv} onClick={() => sendCommand(dv)}> <Row key={dv.id} item={dv} onClick={() => showDeviceValue(dv)}>
<Cell>{renderNameCell(dv)}</Cell> <Cell>{renderNameCell(dv)}</Cell>
<Cell>{formatValue(LL, dv.v, dv.u)}</Cell> <Cell>{formatValue(LL, dv.v, dv.u)}</Cell>
<Cell stiff> <Cell stiff>
{dv.c && me.admin && !hasMask(dv.id, DeviceEntityMask.DV_READONLY) && ( {dv.c && me.admin && !hasMask(dv.id, DeviceEntityMask.DV_READONLY) && (
<IconButton size="small" onClick={() => sendCommand(dv)}> <IconButton size="small" onClick={() => showDeviceValue(dv)}>
{dv.v === '' && dv.c ? ( {dv.v === '' && dv.c ? (
<PlayArrowIcon color="primary" sx={{ fontSize: 16 }} /> <PlayArrowIcon color="primary" sx={{ fontSize: 16 }} />
) : ( ) : (
@@ -522,43 +593,25 @@ const DashboardDevices: FC = () => {
{renderCoreData()} {renderCoreData()}
{renderDeviceData()} {renderDeviceData()}
{renderDeviceDetails()} {renderDeviceDetails()}
{selectedDeviceValue && ( {selectedDeviceValue && (
<DashboarDevicesDialog <DashboarDevicesDialog
open={deviceValueDialogOpen} open={deviceValueDialogOpen}
onClose={deviceValueDialogClose} onClose={deviceValueDialogClose}
onSave={deviceValueDialogSave} onSave={deviceValueDialogSave}
selectedItem={selectedDeviceValue} selectedItem={selectedDeviceValue}
writeable={
me.admin &&
selectedDeviceValue.c !== undefined &&
!hasMask(selectedDeviceValue.id, DeviceEntityMask.DV_READONLY)
}
validator={deviceValueItemValidation(selectedDeviceValue)} validator={deviceValueItemValidation(selectedDeviceValue)}
/> />
)} )}
<ButtonRow>
<Box display="flex" flexWrap="wrap"> <Button startIcon={<RefreshIcon />} variant="outlined" color="secondary" onClick={refreshData}>
<Box flexGrow={1}> {LL.REFRESH()}
<ButtonRow> </Button>
<Button startIcon={<RefreshIcon />} variant="outlined" color="secondary" onClick={refreshData}> </ButtonRow>
{LL.REFRESH()}
</Button>
{device_select.state.id && device_select.state.id !== 'sensor' && (
<Button startIcon={<DownloadIcon />} variant="outlined" onClick={handleDownloadCsv}>
{LL.EXPORT()}
</Button>
)}
</ButtonRow>
</Box>
<Box flexWrap="nowrap" whiteSpace="nowrap">
<ButtonRow>
<Button
startIcon={<SettingsBackupRestoreIcon />}
variant="outlined"
onClick={() => device_select.fns.onRemoveAll()}
color="warning"
>
{LL.RESET(0)}
</Button>
</ButtonRow>
</Box>
</Box>
</SectionContent> </SectionContent>
); );
}; };

View File

@@ -33,10 +33,18 @@ type DashboardDevicesDialogProps = {
onClose: () => void; onClose: () => void;
onSave: (as: DeviceValue) => void; onSave: (as: DeviceValue) => void;
selectedItem: DeviceValue; selectedItem: DeviceValue;
writeable: boolean;
validator: Schema; validator: Schema;
}; };
const DashboarDevicesDialog = ({ open, onClose, onSave, selectedItem, validator }: DashboardDevicesDialogProps) => { const DashboarDevicesDialog = ({
open,
onClose,
onSave,
selectedItem,
writeable,
validator
}: DashboardDevicesDialogProps) => {
const { LL } = useI18nContext(); const { LL } = useI18nContext();
const [editItem, setEditItem] = useState<DeviceValue>(selectedItem); const [editItem, setEditItem] = useState<DeviceValue>(selectedItem);
const [fieldErrors, setFieldErrors] = useState<ValidateFieldsError>(); const [fieldErrors, setFieldErrors] = useState<ValidateFieldsError>();
@@ -101,8 +109,18 @@ const DashboarDevicesDialog = ({ open, onClose, onSave, selectedItem, validator
}; };
return ( return (
<Dialog open={open} onClose={close}> <Dialog
<DialogTitle>{selectedItem.v === '' && selectedItem.c ? LL.RUN_COMMAND() : LL.CHANGE_VALUE()}</DialogTitle> open={open}
onClose={close}
sx={{
'& .MuiDialog-paper': {
borderRadius: '12px'
}
}}
>
<DialogTitle>
{selectedItem.v === '' && selectedItem.c ? LL.RUN_COMMAND() : writeable ? LL.CHANGE_VALUE() : LL.VALUE(1)}
</DialogTitle>
<DialogContent dividers> <DialogContent dividers>
<Box color="warning.main" p={0} pl={0} pr={0} mt={0} mb={2}> <Box color="warning.main" p={0} pl={0} pr={0} mt={0} mb={2}>
<Typography variant="body2">{editItem.id.slice(2)}</Typography> <Typography variant="body2">{editItem.id.slice(2)}</Typography>
@@ -114,6 +132,7 @@ const DashboarDevicesDialog = ({ open, onClose, onSave, selectedItem, validator
name="v" name="v"
label={LL.VALUE(1)} label={LL.VALUE(1)}
value={editItem.v} value={editItem.v}
disabled={!writeable}
autoFocus autoFocus
sx={{ width: '30ch' }} sx={{ width: '30ch' }}
select select
@@ -132,6 +151,7 @@ const DashboarDevicesDialog = ({ open, onClose, onSave, selectedItem, validator
label={LL.VALUE(1)} label={LL.VALUE(1)}
value={Math.round(editItem.v * 10) / 10} value={Math.round(editItem.v * 10) / 10}
autoFocus autoFocus
disabled={!writeable}
type="number" type="number"
sx={{ width: '30ch' }} sx={{ width: '30ch' }}
onChange={updateFormValue} onChange={updateFormValue}
@@ -146,6 +166,7 @@ const DashboarDevicesDialog = ({ open, onClose, onSave, selectedItem, validator
name="v" name="v"
label={LL.VALUE(1)} label={LL.VALUE(1)}
value={editItem.v} value={editItem.v}
disabled={!writeable}
autoFocus autoFocus
sx={{ width: '30ch' }} sx={{ width: '30ch' }}
multiline={editItem.u ? false : true} multiline={editItem.u ? false : true}
@@ -153,19 +174,29 @@ const DashboarDevicesDialog = ({ open, onClose, onSave, selectedItem, validator
/> />
)} )}
</Grid> </Grid>
<Grid item> {writeable && (
<FormHelperText>format:&nbsp;{showHelperText(editItem)}</FormHelperText> <Grid item>
</Grid> <FormHelperText>format:&nbsp;{showHelperText(editItem)}</FormHelperText>
</Grid>
)}
</Grid> </Grid>
</DialogContent> </DialogContent>
<DialogActions> <DialogActions>
<Button startIcon={<CancelIcon />} variant="outlined" onClick={close} color="secondary"> {writeable ? (
{LL.CANCEL()} <>
</Button> <Button startIcon={<CancelIcon />} variant="outlined" onClick={close} color="secondary">
<Button startIcon={<WarningIcon color="warning" />} variant="contained" onClick={save} color="info"> {LL.CANCEL()}
{LL.UPDATE()} </Button>
</Button> <Button startIcon={<WarningIcon color="warning" />} variant="contained" onClick={save} color="info">
{LL.UPDATE()}
</Button>
</>
) : (
<Button variant="outlined" onClick={close} color="secondary">
{LL.CLOSE()}
</Button>
)}
</DialogActions> </DialogActions>
</Dialog> </Dialog>
); );

View File

@@ -68,7 +68,6 @@ export interface Device {
d: number; // deviceid d: number; // deviceid
p: number; // productid p: number; // productid
v: string; // version v: string; // version
e: number; // number of entries
} }
export interface TemperatureSensor { export interface TemperatureSensor {
@@ -134,7 +133,6 @@ export interface DeviceValue {
} }
export interface DeviceData { export interface DeviceData {
label: string;
data: DeviceValue[]; data: DeviceValue[];
} }

View File

@@ -297,19 +297,6 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@emotion/cache@npm:^11.10.8":
version: 11.10.8
resolution: "@emotion/cache@npm:11.10.8"
dependencies:
"@emotion/memoize": ^0.8.0
"@emotion/sheet": ^1.2.1
"@emotion/utils": ^1.2.0
"@emotion/weak-memoize": ^0.3.0
stylis: 4.1.4
checksum: 6369883921b3c7d4598dfd584001922e8ef80aa7c373db6e5fb430b4ae9ecf3de1a2c2bcdbfef078821ea70a9413572f1263ce11b47082e2f532028d9e50ab9d
languageName: node
linkType: hard
"@emotion/cache@npm:^11.11.0": "@emotion/cache@npm:^11.11.0":
version: 11.11.0 version: 11.11.0
resolution: "@emotion/cache@npm:11.11.0" resolution: "@emotion/cache@npm:11.11.0"
@@ -330,15 +317,6 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@emotion/is-prop-valid@npm:^1.2.0":
version: 1.2.0
resolution: "@emotion/is-prop-valid@npm:1.2.0"
dependencies:
"@emotion/memoize": ^0.8.0
checksum: 098bfde166ddbc3ad635157dff8dd8b90ceb5ee2804b3dbc9ffbffcac33955390d6c6e94dc36b1fde8c90f49dc1e1359dfdcd967906b006a3966382dbe8cc90b
languageName: node
linkType: hard
"@emotion/is-prop-valid@npm:^1.2.1": "@emotion/is-prop-valid@npm:^1.2.1":
version: 1.2.1 version: 1.2.1
resolution: "@emotion/is-prop-valid@npm:1.2.1" resolution: "@emotion/is-prop-valid@npm:1.2.1"
@@ -348,13 +326,6 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@emotion/memoize@npm:^0.8.0":
version: 0.8.0
resolution: "@emotion/memoize@npm:0.8.0"
checksum: 246087ec09b32b295af67a094253831f398aabd953d03d14f186acb8607ed2a755e944f5e20b5ccebb461f15c2e5ccbf8fe977bcf3be951cf10961c504e1e65b
languageName: node
linkType: hard
"@emotion/memoize@npm:^0.8.1": "@emotion/memoize@npm:^0.8.1":
version: 0.8.1 version: 0.8.1
resolution: "@emotion/memoize@npm:0.8.1" resolution: "@emotion/memoize@npm:0.8.1"
@@ -396,13 +367,6 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@emotion/sheet@npm:^1.2.1":
version: 1.2.1
resolution: "@emotion/sheet@npm:1.2.1"
checksum: 88268c00005d310df3ebb249b839ad0b234943da5a0cc614b232b9bd4ae600292dca9b0f61c45cde3a592c77459e880d77a2aa73af20ec3c0d579afccc3f71af
languageName: node
linkType: hard
"@emotion/sheet@npm:^1.2.2": "@emotion/sheet@npm:^1.2.2":
version: 1.2.2 version: 1.2.2
resolution: "@emotion/sheet@npm:1.2.2" resolution: "@emotion/sheet@npm:1.2.2"
@@ -446,13 +410,6 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@emotion/utils@npm:^1.2.0":
version: 1.2.0
resolution: "@emotion/utils@npm:1.2.0"
checksum: 7051cec83bb49688549667484058d3a19a30001fa3692c23f7a2e727c05121f952854e1196feb9ece4fa36914705ebf474edba833a2178bdc133c654b5e3ca7d
languageName: node
linkType: hard
"@emotion/utils@npm:^1.2.1": "@emotion/utils@npm:^1.2.1":
version: 1.2.1 version: 1.2.1
resolution: "@emotion/utils@npm:1.2.1" resolution: "@emotion/utils@npm:1.2.1"
@@ -460,13 +417,6 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@emotion/weak-memoize@npm:^0.3.0":
version: 0.3.0
resolution: "@emotion/weak-memoize@npm:0.3.0"
checksum: 1771687cc3b3280371de12698f1b78756c64654fc7d15ce76e1fb5d4adf9fd49d4411e41276bbfd5b521ef9cef647196aa9dca26f936c466fb80bf48491fa844
languageName: node
linkType: hard
"@emotion/weak-memoize@npm:^0.3.1": "@emotion/weak-memoize@npm:^0.3.1":
version: 0.3.1 version: 0.3.1
resolution: "@emotion/weak-memoize@npm:0.3.1" resolution: "@emotion/weak-memoize@npm:0.3.1"
@@ -663,10 +613,10 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@eslint/js@npm:8.40.0": "@eslint/js@npm:8.41.0":
version: 8.40.0 version: 8.41.0
resolution: "@eslint/js@npm:8.40.0" resolution: "@eslint/js@npm:8.41.0"
checksum: 0a7253c6aa5d14bda570cde5aff627fc338ca3b6e6226e2cbe7008a095ff244109f7edd1c340465d0aab3cea695ea7eb10bff96e6e9cab60cdd3226ac010041b checksum: 41cf403ccebbc90315c7190bd901fa17975327022146b2db8c846ec5b11d04c56b33ccf9064b9da7349068e96bef8f322423fbcce700d815b4097fd808aaa4c6
languageName: node languageName: node
linkType: hard linkType: hard
@@ -764,14 +714,14 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@mui/base@npm:5.0.0-beta.0": "@mui/base@npm:5.0.0-beta.2":
version: 5.0.0-beta.0 version: 5.0.0-beta.2
resolution: "@mui/base@npm:5.0.0-beta.0" resolution: "@mui/base@npm:5.0.0-beta.2"
dependencies: dependencies:
"@babel/runtime": ^7.21.0 "@babel/runtime": ^7.21.0
"@emotion/is-prop-valid": ^1.2.0 "@emotion/is-prop-valid": ^1.2.1
"@mui/types": ^7.2.4 "@mui/types": ^7.2.4
"@mui/utils": ^5.12.3 "@mui/utils": ^5.13.1
"@popperjs/core": ^2.11.7 "@popperjs/core": ^2.11.7
clsx: ^1.2.1 clsx: ^1.2.1
prop-types: ^15.8.1 prop-types: ^15.8.1
@@ -783,14 +733,14 @@ __metadata:
peerDependenciesMeta: peerDependenciesMeta:
"@types/react": "@types/react":
optional: true optional: true
checksum: 22334cddd4bc31fb9dfd065723e1d0f13178157093abd55182016759d9301429f73be8d73f3dc795cf154bf48545a4fc451976d43a940cae864c882c338bfa0d checksum: 56d8aa39709ef28bd9d39ec7202f925babbf1dce019ebe1c689b6deebd7049f93ba92af6d1bbc3aeef78a052cb8557ad9ea56c0f6294f71b6f5269e805e27e19
languageName: node languageName: node
linkType: hard linkType: hard
"@mui/core-downloads-tracker@npm:^5.13.0": "@mui/core-downloads-tracker@npm:^5.13.2":
version: 5.13.0 version: 5.13.2
resolution: "@mui/core-downloads-tracker@npm:5.13.0" resolution: "@mui/core-downloads-tracker@npm:5.13.2"
checksum: 89e3c7eed256c8f507ba61fda7d00f559d3ac13196ca35e248bcc0ac12e26c5e125b630e7ca6444bbe3669ac453b1d63f2e9f3f817ca1f47ce4d1205a634005f checksum: 6c6aef994400c96aaca3a23be4df5e0606d38f16bac241fd4dc953ef2254ac727b4a699c030ca36c14604f7294b39246d9c048b7a1356642dbb6b8e931597497
languageName: node languageName: node
linkType: hard linkType: hard
@@ -810,16 +760,16 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@mui/material@npm:^5.13.0": "@mui/material@npm:^5.13.2":
version: 5.13.0 version: 5.13.2
resolution: "@mui/material@npm:5.13.0" resolution: "@mui/material@npm:5.13.2"
dependencies: dependencies:
"@babel/runtime": ^7.21.0 "@babel/runtime": ^7.21.0
"@mui/base": 5.0.0-beta.0 "@mui/base": 5.0.0-beta.2
"@mui/core-downloads-tracker": ^5.13.0 "@mui/core-downloads-tracker": ^5.13.2
"@mui/system": ^5.12.3 "@mui/system": ^5.13.2
"@mui/types": ^7.2.4 "@mui/types": ^7.2.4
"@mui/utils": ^5.12.3 "@mui/utils": ^5.13.1
"@types/react-transition-group": ^4.4.6 "@types/react-transition-group": ^4.4.6
clsx: ^1.2.1 clsx: ^1.2.1
csstype: ^3.1.2 csstype: ^3.1.2
@@ -839,16 +789,16 @@ __metadata:
optional: true optional: true
"@types/react": "@types/react":
optional: true optional: true
checksum: aa30e1d06d86a911db5422b2232fb6a17cbb5596b82c8f2253870e07476c0dd4142bf6c64e1c58570b960cb9c8d152c23f9c26705e7ed35d683d22050c6313df checksum: 7e5ca978258ac04af2399ddf251705aa0a06b97653fc76b3363d6eecdfac56800005faaf8797da6074e7087e970282571fb980e403c0faa569843735f969408d
languageName: node languageName: node
linkType: hard linkType: hard
"@mui/private-theming@npm:^5.12.3": "@mui/private-theming@npm:^5.13.1":
version: 5.12.3 version: 5.13.1
resolution: "@mui/private-theming@npm:5.12.3" resolution: "@mui/private-theming@npm:5.13.1"
dependencies: dependencies:
"@babel/runtime": ^7.21.0 "@babel/runtime": ^7.21.0
"@mui/utils": ^5.12.3 "@mui/utils": ^5.13.1
prop-types: ^15.8.1 prop-types: ^15.8.1
peerDependencies: peerDependencies:
"@types/react": ^17.0.0 || ^18.0.0 "@types/react": ^17.0.0 || ^18.0.0
@@ -856,16 +806,16 @@ __metadata:
peerDependenciesMeta: peerDependenciesMeta:
"@types/react": "@types/react":
optional: true optional: true
checksum: 7a1cfda9fe9e7b5dc4b2bd48521ec5087db3a7d13986a7a5fc51f6ab62ec14f64db19cb7a2f6b2d13184fbcbb626228be3008def0236c191e77b29a9b1842a1c checksum: 1242f90642ee68792b9e72e7bcae8a2dd00c2c0bdd9cd825d9f154263755a4c4e213daa752e7fe64062a082cd6f60875f06eb122181c06e6b73f4d9caf68b949
languageName: node languageName: node
linkType: hard linkType: hard
"@mui/styled-engine@npm:^5.12.3": "@mui/styled-engine@npm:^5.13.2":
version: 5.12.3 version: 5.13.2
resolution: "@mui/styled-engine@npm:5.12.3" resolution: "@mui/styled-engine@npm:5.13.2"
dependencies: dependencies:
"@babel/runtime": ^7.21.0 "@babel/runtime": ^7.21.0
"@emotion/cache": ^11.10.8 "@emotion/cache": ^11.11.0
csstype: ^3.1.2 csstype: ^3.1.2
prop-types: ^15.8.1 prop-types: ^15.8.1
peerDependencies: peerDependencies:
@@ -877,19 +827,19 @@ __metadata:
optional: true optional: true
"@emotion/styled": "@emotion/styled":
optional: true optional: true
checksum: 65d31cbb7f27a3340de12737820fd266cab21eb369bf0d8fa9eed2f28a7314f6ed43d6a5684c56397dbb2acddbc32970b964755fd7c9c349cdd19657cb742b0a checksum: ed53dbe0151067c6843989fc41245f98a56c48e7c341ce61656b71de2cb334bdf1cea8bbf625ddbc4ce600d6005717c2cd1f34473b3b41e154662353cf2c108e
languageName: node languageName: node
linkType: hard linkType: hard
"@mui/system@npm:^5.12.3": "@mui/system@npm:^5.13.2":
version: 5.12.3 version: 5.13.2
resolution: "@mui/system@npm:5.12.3" resolution: "@mui/system@npm:5.13.2"
dependencies: dependencies:
"@babel/runtime": ^7.21.0 "@babel/runtime": ^7.21.0
"@mui/private-theming": ^5.12.3 "@mui/private-theming": ^5.13.1
"@mui/styled-engine": ^5.12.3 "@mui/styled-engine": ^5.13.2
"@mui/types": ^7.2.4 "@mui/types": ^7.2.4
"@mui/utils": ^5.12.3 "@mui/utils": ^5.13.1
clsx: ^1.2.1 clsx: ^1.2.1
csstype: ^3.1.2 csstype: ^3.1.2
prop-types: ^15.8.1 prop-types: ^15.8.1
@@ -905,7 +855,7 @@ __metadata:
optional: true optional: true
"@types/react": "@types/react":
optional: true optional: true
checksum: 72c312b56ad142d9d0df0ab834d496e4107df33f148a26e065178566fd4678a17f8d1310aa33dced6e5c4660b7de7beca8b7d4205cd26b957a89b9e198c2db0f checksum: 34ebb580e5dd83123cc397c3fd54c3430f66ab715eb1538cf2510821d88249814294f79ea046081b61249643383fd9c23552d9791322855fa2099bf8f1c4e51b
languageName: node languageName: node
linkType: hard linkType: hard
@@ -921,18 +871,18 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@mui/utils@npm:^5.12.3": "@mui/utils@npm:^5.13.1":
version: 5.12.3 version: 5.13.1
resolution: "@mui/utils@npm:5.12.3" resolution: "@mui/utils@npm:5.13.1"
dependencies: dependencies:
"@babel/runtime": ^7.21.0 "@babel/runtime": ^7.21.0
"@types/prop-types": ^15.7.5 "@types/prop-types": ^15.7.5
"@types/react-is": ^16.7.1 || ^17.0.0 "@types/react-is": ^18.2.0
prop-types: ^15.8.1 prop-types: ^15.8.1
react-is: ^18.2.0 react-is: ^18.2.0
peerDependencies: peerDependencies:
react: ^17.0.0 || ^18.0.0 react: ^17.0.0 || ^18.0.0
checksum: b2bfae7116f031c16e8a22a9187de979c06081308ddb75f5450eaaea2738fe11650a7e377e9ac4933cc6f90d4f8d55ac94b4f90e45251dea082a96091c129d47 checksum: 05f28ed16c7c15deecb7d55962efa21f073f09342758e01bf6a618dd4532a8bf074d6e3c306cdf5f3c6d7b92f6729b0b157e828a13aff9d2445b1da997e1a7eb
languageName: node languageName: node
linkType: hard linkType: hard
@@ -1004,10 +954,10 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@remix-run/router@npm:1.6.1": "@remix-run/router@npm:1.6.2":
version: 1.6.1 version: 1.6.2
resolution: "@remix-run/router@npm:1.6.1" resolution: "@remix-run/router@npm:1.6.2"
checksum: 6d6dad1b6a06171d5d8549eca7cd7ef332a40987b732829e48993d55b3c7a7ca661c7d891be938055a42a4b18f07b5f2b66295c89cb221464eda2678ac41621e checksum: 73da6884e53873e4290abb3978373cafc3f351994273b0663eda5e12c81cb427fc6fe4df1924569d9a214f701d0106cf37122455951e0239d7e6fa35071df558
languageName: node languageName: node
linkType: hard linkType: hard
@@ -1331,10 +1281,10 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@types/node@npm:^20.1.2": "@types/node@npm:^20.2.3":
version: 20.1.2 version: 20.2.3
resolution: "@types/node@npm:20.1.2" resolution: "@types/node@npm:20.2.3"
checksum: d34f1968876814fac23e9c4daf9fd52344009411b86fb809da7a545e0488436b59be2174d4cf907758502f2eddade247ca0c3abe88e96c217b82ecb6c9c18c32 checksum: de79ce435f28354dd80f1203db2a5a0606543964400738007fe653d6248a75a9bbec7e7d9b350c475f3b0de514f4d2adbd642abe14f4a6dd40de92c0b8533b5e
languageName: node languageName: node
linkType: hard linkType: hard
@@ -1361,12 +1311,12 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@types/react-is@npm:^16.7.1 || ^17.0.0": "@types/react-is@npm:^18.2.0":
version: 17.0.3 version: 18.2.0
resolution: "@types/react-is@npm:17.0.3" resolution: "@types/react-is@npm:18.2.0"
dependencies: dependencies:
"@types/react": "*" "@types/react": "*"
checksum: 839382b66b2b2e3023647f5ba0c382ddc6aa01c1bc9f64608f82bbc871a905ba9b988838619914d8348c2a511717c6bd3701cb866bb9e4abfabdbe544efb695b checksum: 7bbc931874da3f41917416b9e44f2e0749c99d7c94a3803b96342890579aad2abca473bf7505fd2202cd61c84d6ed9da41f951eb19ccee860554682327087c96
languageName: node languageName: node
linkType: hard linkType: hard
@@ -1411,14 +1361,14 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@types/react@npm:^18.2.6": "@types/react@npm:^18.2.7":
version: 18.2.6 version: 18.2.7
resolution: "@types/react@npm:18.2.6" resolution: "@types/react@npm:18.2.7"
dependencies: dependencies:
"@types/prop-types": "*" "@types/prop-types": "*"
"@types/scheduler": "*" "@types/scheduler": "*"
csstype: ^3.0.2 csstype: ^3.0.2
checksum: 7740541afde84a50c557e576dd564a861b45ad436d1c3ed33496d70046a6eb734bfe7f7f18995f88bdc50be0d295c2b878f705a6b9573cc0781e11ea58470139 checksum: 5ec33ea64f3abc1da2a676809a16db2914465457154ecafc4f2db486e35d9e93fdfd661763396580eb489d7e131eaa86d8e58326719048bbcc2935f8ef0825fb
languageName: node languageName: node
linkType: hard linkType: hard
@@ -1436,14 +1386,14 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"@typescript-eslint/eslint-plugin@npm:^5.59.5": "@typescript-eslint/eslint-plugin@npm:^5.59.7":
version: 5.59.5 version: 5.59.7
resolution: "@typescript-eslint/eslint-plugin@npm:5.59.5" resolution: "@typescript-eslint/eslint-plugin@npm:5.59.7"
dependencies: dependencies:
"@eslint-community/regexpp": ^4.4.0 "@eslint-community/regexpp": ^4.4.0
"@typescript-eslint/scope-manager": 5.59.5 "@typescript-eslint/scope-manager": 5.59.7
"@typescript-eslint/type-utils": 5.59.5 "@typescript-eslint/type-utils": 5.59.7
"@typescript-eslint/utils": 5.59.5 "@typescript-eslint/utils": 5.59.7
debug: ^4.3.4 debug: ^4.3.4
grapheme-splitter: ^1.0.4 grapheme-splitter: ^1.0.4
ignore: ^5.2.0 ignore: ^5.2.0
@@ -1456,43 +1406,43 @@ __metadata:
peerDependenciesMeta: peerDependenciesMeta:
typescript: typescript:
optional: true optional: true
checksum: 6d2e7397c9111bb538d20b2fdc301a318415a499c53eb064707a480bd15ef6dfa86f7047cda51fd9cf812e2f8cb489accf74fb074372f08b8b5ab1d9cfc72b6a checksum: 78b583230a7a20e6a06bc9cd1c10ef6d334bdf8d0179a66b2f3d6ebb2b1ac5685ea5266443f8c833719ea62c2768f28a625fd64c5e83b9408a6d41aaffe35db0
languageName: node languageName: node
linkType: hard linkType: hard
"@typescript-eslint/parser@npm:^5.59.5": "@typescript-eslint/parser@npm:^5.59.7":
version: 5.59.5 version: 5.59.7
resolution: "@typescript-eslint/parser@npm:5.59.5" resolution: "@typescript-eslint/parser@npm:5.59.7"
dependencies: dependencies:
"@typescript-eslint/scope-manager": 5.59.5 "@typescript-eslint/scope-manager": 5.59.7
"@typescript-eslint/types": 5.59.5 "@typescript-eslint/types": 5.59.7
"@typescript-eslint/typescript-estree": 5.59.5 "@typescript-eslint/typescript-estree": 5.59.7
debug: ^4.3.4 debug: ^4.3.4
peerDependencies: peerDependencies:
eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 eslint: ^6.0.0 || ^7.0.0 || ^8.0.0
peerDependenciesMeta: peerDependenciesMeta:
typescript: typescript:
optional: true optional: true
checksum: 77669ac187ba253d1a65411afbeddebd1f462037c4524e70479db73c8b772b2cc82203c0ad1378dd246025b3fd22b989e8aaa86174097d47cc2502c99f38775a checksum: c6248149be43fbea69f93cc1c56c17265c58639aa520b8afe242e7dac43712d1dd2bbc93fedd6a017b8799d68b1a51c8d802bc402184e9d2813bfc92a08bc204
languageName: node languageName: node
linkType: hard linkType: hard
"@typescript-eslint/scope-manager@npm:5.59.5": "@typescript-eslint/scope-manager@npm:5.59.7":
version: 5.59.5 version: 5.59.7
resolution: "@typescript-eslint/scope-manager@npm:5.59.5" resolution: "@typescript-eslint/scope-manager@npm:5.59.7"
dependencies: dependencies:
"@typescript-eslint/types": 5.59.5 "@typescript-eslint/types": 5.59.7
"@typescript-eslint/visitor-keys": 5.59.5 "@typescript-eslint/visitor-keys": 5.59.7
checksum: dccb4d495827f4375c4e80ee8a40b4e9ecc41022786eb760afc4725d36d09de30bbc578d6bb93ee8546a7e9ee8c732f5b057a13ffd2ac763d28eb7e876aaa9f2 checksum: e1cc89cf4a9b5fe3cc1b7921fb64cffe7e7179347a19c42e67c4b1ebbae88d7c997d1c3b6f24d11ef184ed35853115ec1d1c249da8b15c5dbffc5606e662b23a
languageName: node languageName: node
linkType: hard linkType: hard
"@typescript-eslint/type-utils@npm:5.59.5": "@typescript-eslint/type-utils@npm:5.59.7":
version: 5.59.5 version: 5.59.7
resolution: "@typescript-eslint/type-utils@npm:5.59.5" resolution: "@typescript-eslint/type-utils@npm:5.59.7"
dependencies: dependencies:
"@typescript-eslint/typescript-estree": 5.59.5 "@typescript-eslint/typescript-estree": 5.59.7
"@typescript-eslint/utils": 5.59.5 "@typescript-eslint/utils": 5.59.7
debug: ^4.3.4 debug: ^4.3.4
tsutils: ^3.21.0 tsutils: ^3.21.0
peerDependencies: peerDependencies:
@@ -1500,23 +1450,23 @@ __metadata:
peerDependenciesMeta: peerDependenciesMeta:
typescript: typescript:
optional: true optional: true
checksum: 7720e306ae71f91ef31aad7a30ceb183bb38aad1f3f44be0df7d04dc1af697b77ac80e104c7375d234bfd77f70afa16bec2f087763cc1ff389cb02a31ea3cf9f checksum: 882cb0ea0c2d660b64d0c05ff28baf2504c04ad9a4e12ceb70f9679025397ac0709455f489662a1f92ae7fa5be535447c3d26979598ef1e23ceed4cdf8078ca5
languageName: node languageName: node
linkType: hard linkType: hard
"@typescript-eslint/types@npm:5.59.5": "@typescript-eslint/types@npm:5.59.7":
version: 5.59.5 version: 5.59.7
resolution: "@typescript-eslint/types@npm:5.59.5" resolution: "@typescript-eslint/types@npm:5.59.7"
checksum: a019981b270fdfd800fb240db9256ee39e3b41380f0b979a7fa5a14980852b3237b6c728860adfe1992a1b8d47b99d584e1d5251ebc5ba9ca437b76d957df0f2 checksum: 3bb11afe5eff16bde59fc7b0f479787fdc1764b9d836d4d32a587b058bb868057080b3ead7ef4d73feb17ac15765f2fbd74bad311263eea0ac3f29198a00b645
languageName: node languageName: node
linkType: hard linkType: hard
"@typescript-eslint/typescript-estree@npm:5.59.5": "@typescript-eslint/typescript-estree@npm:5.59.7":
version: 5.59.5 version: 5.59.7
resolution: "@typescript-eslint/typescript-estree@npm:5.59.5" resolution: "@typescript-eslint/typescript-estree@npm:5.59.7"
dependencies: dependencies:
"@typescript-eslint/types": 5.59.5 "@typescript-eslint/types": 5.59.7
"@typescript-eslint/visitor-keys": 5.59.5 "@typescript-eslint/visitor-keys": 5.59.7
debug: ^4.3.4 debug: ^4.3.4
globby: ^11.1.0 globby: ^11.1.0
is-glob: ^4.0.3 is-glob: ^4.0.3
@@ -1525,35 +1475,35 @@ __metadata:
peerDependenciesMeta: peerDependenciesMeta:
typescript: typescript:
optional: true optional: true
checksum: 6e7cab3bc6659689a6e7f72e9db5738e8cdab43c38621bc625125e88879f9af33a81fbd696acf6bb3c8a32586f2af9779e0df1555a8630309879b8ea6370545b checksum: 6b16d6fbe0e2111c9cb37c5bcd8834747f8ea2db0350df54e1aa13c1b09919efad8329b9a40c7bf7f4c8426fab50ce6ddf8e9f1731b8c93678e3af51c21102b5
languageName: node languageName: node
linkType: hard linkType: hard
"@typescript-eslint/utils@npm:5.59.5": "@typescript-eslint/utils@npm:5.59.7":
version: 5.59.5 version: 5.59.7
resolution: "@typescript-eslint/utils@npm:5.59.5" resolution: "@typescript-eslint/utils@npm:5.59.7"
dependencies: dependencies:
"@eslint-community/eslint-utils": ^4.2.0 "@eslint-community/eslint-utils": ^4.2.0
"@types/json-schema": ^7.0.9 "@types/json-schema": ^7.0.9
"@types/semver": ^7.3.12 "@types/semver": ^7.3.12
"@typescript-eslint/scope-manager": 5.59.5 "@typescript-eslint/scope-manager": 5.59.7
"@typescript-eslint/types": 5.59.5 "@typescript-eslint/types": 5.59.7
"@typescript-eslint/typescript-estree": 5.59.5 "@typescript-eslint/typescript-estree": 5.59.7
eslint-scope: ^5.1.1 eslint-scope: ^5.1.1
semver: ^7.3.7 semver: ^7.3.7
peerDependencies: peerDependencies:
eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 eslint: ^6.0.0 || ^7.0.0 || ^8.0.0
checksum: af0f3c6f314cbb2e8fb646ffb28ac78ee2b2c7951c3df4458d01a182c903e65f455e72db0525b5c4ff05c89c59696717c97dd87f906fa648bb7313079fa88385 checksum: d7d0c5a12ddefb5c9aaed100a8dfab181b74b04562f46e047904979fd4dfb9c76944cf88ffba5799a57c1af67e6906a3a1e1444f1fe119dda41f9cf233e995c4
languageName: node languageName: node
linkType: hard linkType: hard
"@typescript-eslint/visitor-keys@npm:5.59.5": "@typescript-eslint/visitor-keys@npm:5.59.7":
version: 5.59.5 version: 5.59.7
resolution: "@typescript-eslint/visitor-keys@npm:5.59.5" resolution: "@typescript-eslint/visitor-keys@npm:5.59.7"
dependencies: dependencies:
"@typescript-eslint/types": 5.59.5 "@typescript-eslint/types": 5.59.7
eslint-visitor-keys: ^3.3.0 eslint-visitor-keys: ^3.3.0
checksum: b3be652ffc4476ab5fbe8833b758d9e3e75c7c4880d7ccc607bdc2815d642f7eddcc31a033a6bbf8dcf4902c0d6c015b4383b9b0fc989ec5cf03c7c06d6dd34e checksum: 5cc1d7ddd8a1715de3398651d0ae183a9beafc2e49630cf5a40fc53afac60fae9b61631ee418686c211c8cc395d8d84dc182945659700fb846f06de106f5c114
languageName: node languageName: node
linkType: hard linkType: hard
@@ -1575,19 +1525,19 @@ __metadata:
"@emotion/react": ^11.11.0 "@emotion/react": ^11.11.0
"@emotion/styled": ^11.11.0 "@emotion/styled": ^11.11.0
"@mui/icons-material": ^5.11.16 "@mui/icons-material": ^5.11.16
"@mui/material": ^5.13.0 "@mui/material": ^5.13.2
"@table-library/react-table-library": 4.1.4 "@table-library/react-table-library": 4.1.4
"@types/lodash-es": ^4.17.7 "@types/lodash-es": ^4.17.7
"@types/node": ^20.1.2 "@types/node": ^20.2.3
"@types/react": ^18.2.6 "@types/react": ^18.2.7
"@types/react-dom": ^18.2.4 "@types/react-dom": ^18.2.4
"@types/react-router-dom": ^5.3.3 "@types/react-router-dom": ^5.3.3
"@typescript-eslint/eslint-plugin": ^5.59.5 "@typescript-eslint/eslint-plugin": ^5.59.7
"@typescript-eslint/parser": ^5.59.5 "@typescript-eslint/parser": ^5.59.7
"@vitejs/plugin-react-swc": ^3.3.1 "@vitejs/plugin-react-swc": ^3.3.1
async-validator: ^4.2.5 async-validator: ^4.2.5
axios: ^1.4.0 axios: ^1.4.0
eslint: ^8.40.0 eslint: ^8.41.0
eslint-config-airbnb: ^19.0.4 eslint-config-airbnb: ^19.0.4
eslint-config-airbnb-typescript: ^17.0.0 eslint-config-airbnb-typescript: ^17.0.0
eslint-config-prettier: ^8.8.0 eslint-config-prettier: ^8.8.0
@@ -1608,14 +1558,14 @@ __metadata:
react-dom: latest react-dom: latest
react-dropzone: ^14.2.3 react-dropzone: ^14.2.3
react-icons: ^4.8.0 react-icons: ^4.8.0
react-router-dom: ^6.11.1 react-router-dom: ^6.11.2
react-toastify: ^9.1.2 react-toastify: ^9.1.3
rollup-plugin-visualizer: ^5.9.0 rollup-plugin-visualizer: ^5.9.0
sockette: ^2.0.6 sockette: ^2.0.6
terser: ^5.17.3 terser: ^5.17.6
typesafe-i18n: ^5.24.3 typesafe-i18n: ^5.24.3
typescript: ^5.0.4 typescript: ^5.0.4
vite: ^4.3.5 vite: ^4.3.8
vite-plugin-svgr: ^3.2.0 vite-plugin-svgr: ^3.2.0
vite-tsconfig-paths: ^4.2.0 vite-tsconfig-paths: ^4.2.0
languageName: unknown languageName: unknown
@@ -2884,14 +2834,14 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"eslint@npm:^8.40.0": "eslint@npm:^8.41.0":
version: 8.40.0 version: 8.41.0
resolution: "eslint@npm:8.40.0" resolution: "eslint@npm:8.41.0"
dependencies: dependencies:
"@eslint-community/eslint-utils": ^4.2.0 "@eslint-community/eslint-utils": ^4.2.0
"@eslint-community/regexpp": ^4.4.0 "@eslint-community/regexpp": ^4.4.0
"@eslint/eslintrc": ^2.0.3 "@eslint/eslintrc": ^2.0.3
"@eslint/js": 8.40.0 "@eslint/js": 8.41.0
"@humanwhocodes/config-array": ^0.11.8 "@humanwhocodes/config-array": ^0.11.8
"@humanwhocodes/module-importer": ^1.0.1 "@humanwhocodes/module-importer": ^1.0.1
"@nodelib/fs.walk": ^1.2.8 "@nodelib/fs.walk": ^1.2.8
@@ -2911,13 +2861,12 @@ __metadata:
find-up: ^5.0.0 find-up: ^5.0.0
glob-parent: ^6.0.2 glob-parent: ^6.0.2
globals: ^13.19.0 globals: ^13.19.0
grapheme-splitter: ^1.0.4 graphemer: ^1.4.0
ignore: ^5.2.0 ignore: ^5.2.0
import-fresh: ^3.0.0 import-fresh: ^3.0.0
imurmurhash: ^0.1.4 imurmurhash: ^0.1.4
is-glob: ^4.0.0 is-glob: ^4.0.0
is-path-inside: ^3.0.3 is-path-inside: ^3.0.3
js-sdsl: ^4.1.4
js-yaml: ^4.1.0 js-yaml: ^4.1.0
json-stable-stringify-without-jsonify: ^1.0.1 json-stable-stringify-without-jsonify: ^1.0.1
levn: ^0.4.1 levn: ^0.4.1
@@ -2930,7 +2879,7 @@ __metadata:
text-table: ^0.2.0 text-table: ^0.2.0
bin: bin:
eslint: bin/eslint.js eslint: bin/eslint.js
checksum: dfd4dbb5e2771d7c81852f29cec658fd9d29a0f252b6e962505ee8cd8b9c2c50707ebd7379333836b04514375268e7c09927372601d08354a151fe5db7d760a8 checksum: d71832b235bebaa67c09019dee32bf8393c5e12155e91131c4606670eb9836fbff31e11364408258cb75e2bde8a4dfa0c042aa6145bb23cd800a42e63ca4a035
languageName: node languageName: node
linkType: hard linkType: hard
@@ -3396,6 +3345,13 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"graphemer@npm:^1.4.0":
version: 1.4.0
resolution: "graphemer@npm:1.4.0"
checksum: e951259d8cd2e0d196c72ec711add7115d42eb9a8146c8eeda5b8d3ac91e5dd816b9cd68920726d9fd4490368e7ed86e9c423f40db87e2d8dfafa00fa17c3a31
languageName: node
linkType: hard
"has-bigints@npm:^1.0.1, has-bigints@npm:^1.0.2": "has-bigints@npm:^1.0.1, has-bigints@npm:^1.0.2":
version: 1.0.2 version: 1.0.2
resolution: "has-bigints@npm:1.0.2" resolution: "has-bigints@npm:1.0.2"
@@ -3879,13 +3835,6 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"js-sdsl@npm:^4.1.4":
version: 4.4.0
resolution: "js-sdsl@npm:4.4.0"
checksum: 1eabe718867d293771074b5a14a82a115727b3d4abc9524fb9b0cb74293f447b90fe27bb74eb712b6400aeb7b869631c0a67d3347670cf22d067e77caeeb2f33
languageName: node
linkType: hard
"js-tokens@npm:^3.0.0 || ^4.0.0, js-tokens@npm:^4.0.0": "js-tokens@npm:^3.0.0 || ^4.0.0, js-tokens@npm:^4.0.0":
version: 4.0.0 version: 4.0.0
resolution: "js-tokens@npm:4.0.0" resolution: "js-tokens@npm:4.0.0"
@@ -4842,39 +4791,39 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"react-router-dom@npm:^6.11.1": "react-router-dom@npm:^6.11.2":
version: 6.11.1 version: 6.11.2
resolution: "react-router-dom@npm:6.11.1" resolution: "react-router-dom@npm:6.11.2"
dependencies: dependencies:
"@remix-run/router": 1.6.1 "@remix-run/router": 1.6.2
react-router: 6.11.1 react-router: 6.11.2
peerDependencies: peerDependencies:
react: ">=16.8" react: ">=16.8"
react-dom: ">=16.8" react-dom: ">=16.8"
checksum: 17f1f9c3d71604fb9e270b672a97accbee0bedf5b8cb03518fd20068aa4d653fcbb46c2dfd5cd04a41864bed21cc23c275d7af39e4be2224435529779bf7e7e4 checksum: be7433bc290e56c0dd3e1008d53a76cc9866bf460980658501880876420086f11810ec3355a3abcd79ac537d6a1351eda009fade841c266456d0e8df60967b76
languageName: node languageName: node
linkType: hard linkType: hard
"react-router@npm:6.11.1": "react-router@npm:6.11.2":
version: 6.11.1 version: 6.11.2
resolution: "react-router@npm:6.11.1" resolution: "react-router@npm:6.11.2"
dependencies: dependencies:
"@remix-run/router": 1.6.1 "@remix-run/router": 1.6.2
peerDependencies: peerDependencies:
react: ">=16.8" react: ">=16.8"
checksum: 3b49692947ef2ddae134a15462e4fa47022d82c358cc90085b471989e4bc3c4e1637aa3a81389166b69db557ac420c289f64d64309f4d0bd87a6099e49aee6e1 checksum: a437606078d6096a6dfa322adf80d00ce153f20cd470ad888088c8da99f44477b963425c53f5461a540b909fc274154292ed80d636482dcdc58a423915ca1433
languageName: node languageName: node
linkType: hard linkType: hard
"react-toastify@npm:^9.1.2": "react-toastify@npm:^9.1.3":
version: 9.1.2 version: 9.1.3
resolution: "react-toastify@npm:9.1.2" resolution: "react-toastify@npm:9.1.3"
dependencies: dependencies:
clsx: ^1.1.1 clsx: ^1.1.1
peerDependencies: peerDependencies:
react: ">=16" react: ">=16"
react-dom: ">=16" react-dom: ">=16"
checksum: 904ba15171d3b45751fdec077ca19e9b4010005c75161ddaa805b4c0abd0342fbcd25976b8871de01a2867600dcd902f6b80cf1bfda470ca83d8a514c0d67530 checksum: 51de1e51e9357a24773fbcd45a4db18bf74b8ec40d86a2bfb4a4fee23ca4f9fffdac5dfb7a3c21baea39971f72f72dfcdc79403a6de006f74d69e7bc12f8b3e0
languageName: node languageName: node
linkType: hard linkType: hard
@@ -5501,13 +5450,6 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"stylis@npm:4.1.4":
version: 4.1.4
resolution: "stylis@npm:4.1.4"
checksum: 4f7f1ce3a13230315bdecbfbcfbc243c6e1b774f94b147005e396aa5e337fda668da78b0d666a5be51b3fcc096a3af3fc34cbdfd55b1bf92a66be654a5fe3fd8
languageName: node
linkType: hard
"stylis@npm:4.2.0": "stylis@npm:4.2.0":
version: 4.2.0 version: 4.2.0
resolution: "stylis@npm:4.2.0" resolution: "stylis@npm:4.2.0"
@@ -5578,9 +5520,9 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"terser@npm:^5.17.3": "terser@npm:^5.17.6":
version: 5.17.3 version: 5.17.6
resolution: "terser@npm:5.17.3" resolution: "terser@npm:5.17.6"
dependencies: dependencies:
"@jridgewell/source-map": ^0.3.2 "@jridgewell/source-map": ^0.3.2
acorn: ^8.5.0 acorn: ^8.5.0
@@ -5588,7 +5530,7 @@ __metadata:
source-map-support: ~0.5.20 source-map-support: ~0.5.20
bin: bin:
terser: bin/terser terser: bin/terser
checksum: d7e54fc47ecfaeb2855e55f4f4a29faf9ae98a27267d0531e24fdc6ced6e9271e25601d2856dbae04f813c2a367c33e6aceb91b26360a52968b3ea4da95f059a checksum: 4c175f35af332320189db20e2b37b0671c51164d55a3fc44ed5b74b023858fd670cb987de7b2e8e3704b0d863f95ea9a0ecff37c8c01a48906fb7f81b512a5c8
languageName: node languageName: node
linkType: hard linkType: hard
@@ -5851,9 +5793,9 @@ __metadata:
languageName: node languageName: node
linkType: hard linkType: hard
"vite@npm:^4.3.5": "vite@npm:^4.3.8":
version: 4.3.5 version: 4.3.8
resolution: "vite@npm:4.3.5" resolution: "vite@npm:4.3.8"
dependencies: dependencies:
esbuild: ^0.17.5 esbuild: ^0.17.5
fsevents: ~2.3.2 fsevents: ~2.3.2
@@ -5884,7 +5826,7 @@ __metadata:
optional: true optional: true
bin: bin:
vite: bin/vite.js vite: bin/vite.js
checksum: 56c5de4c6a4cb383492302173372be71c4e55a9eabc7268b6036152880800b7a85ee19be3d4c9f2cdd7af33df53c0153c58e6db402b08e8f6299a7b15fd53b88 checksum: 7eb7e28b8485ee30ceb2a758ad816d741d21a0e377ca7cc98d1db0a8686076e6bf3e620767afe4d9c497fc4d5fa1fe5f95a422c24c61fd92ac5368a78af43b31
languageName: node languageName: node
linkType: hard linkType: hard

View File

@@ -395,8 +395,7 @@ const emsesp_coredata = {
n: 'GBx72/Trendline/Cerapur/Greenstar Si/27i', n: 'GBx72/Trendline/Cerapur/Greenstar Si/27i',
d: 8, d: 8,
p: 123, p: 123,
v: '06.01', v: '06.01'
e: 68
}, },
{ {
id: 3, id: 3,
@@ -406,8 +405,7 @@ const emsesp_coredata = {
n: 'GB125/GB135/MC10', n: 'GB125/GB135/MC10',
d: 8, d: 8,
p: 123, p: 123,
v: '06.01', v: '06.01'
e: 56
}, },
{ {
id: 1, id: 1,
@@ -417,8 +415,7 @@ const emsesp_coredata = {
n: 'RC35', n: 'RC35',
d: 24, d: 24,
p: 86, p: 86,
v: '04.01', v: '04.01'
e: 58
}, },
{ {
id: 2, id: 2,
@@ -428,8 +425,7 @@ const emsesp_coredata = {
n: 'RC20/Moduline 300', n: 'RC20/Moduline 300',
d: 23, d: 23,
p: 77, p: 77,
v: '03.03', v: '03.03'
e: 6
}, },
{ {
id: 4, id: 4,
@@ -439,8 +435,7 @@ const emsesp_coredata = {
n: 'RC100/Moduline 1000/1010', n: 'RC100/Moduline 1000/1010',
d: 16, d: 16,
p: 165, p: 165,
v: '04.01', v: '04.01'
e: 3
}, },
{ {
id: 5, id: 5,
@@ -450,8 +445,7 @@ const emsesp_coredata = {
n: 'MM10', n: 'MM10',
d: 32, d: 32,
p: 69, p: 69,
v: '01.01', v: '01.01'
e: 6
}, },
{ {
id: 6, id: 6,
@@ -461,8 +455,7 @@ const emsesp_coredata = {
n: 'SM10', n: 'SM10',
d: 48, d: 48,
p: 73, p: 73,
v: '01.02', v: '01.02'
e: 16
}, },
{ {
id: 99, id: 99,
@@ -472,8 +465,7 @@ const emsesp_coredata = {
n: 'User defined entities', n: 'User defined entities',
d: 1, d: 1,
p: 1, p: 1,
v: '', v: ''
e: 1
} }
] ]
}; };
@@ -526,7 +518,6 @@ const status = {
// 99 - Custom // 99 - Custom
const emsesp_devicedata_7 = { const emsesp_devicedata_7 = {
label: 'Boiler: Nefit GBx72/Trendline/Cerapur/Greenstar Si/27i',
data: [ data: [
{ v: '', u: 0, id: '08reset', c: 'reset', l: ['-', 'maintenance', 'error'] }, { v: '', u: 0, id: '08reset', c: 'reset', l: ['-', 'maintenance', 'error'] },
{ v: 'off', u: 0, id: '08heating active' }, { v: 'off', u: 0, id: '08heating active' },
@@ -607,7 +598,6 @@ const emsesp_devicedata_7 = {
}; };
const emsesp_devicedata_1 = { const emsesp_devicedata_1 = {
label: 'Thermostat: RC35',
data: [ data: [
{ {
v: '22(816) 01.05.2023 13:07 (1 min)', v: '22(816) 01.05.2023 13:07 (1 min)',
@@ -1040,7 +1030,6 @@ const emsesp_devicedata_1 = {
}; };
const emsesp_devicedata_2 = { const emsesp_devicedata_2 = {
label: 'Thermostat: RC20/Moduline 300',
data: [ data: [
{ {
v: '(0)', v: '(0)',
@@ -1084,7 +1073,6 @@ const emsesp_devicedata_2 = {
}; };
const emsesp_devicedata_3 = { const emsesp_devicedata_3 = {
label: 'Boiler: GB125/GB135/MC10',
data: [ data: [
{ {
v: '', v: '',
@@ -1557,7 +1545,6 @@ const emsesp_devicedata_3 = {
}; };
const emsesp_devicedata_4 = { const emsesp_devicedata_4 = {
label: 'Thermostat: RC100/Moduline 1000/1010',
data: [ data: [
{ {
v: 16, v: 16,
@@ -1582,7 +1569,6 @@ const emsesp_devicedata_4 = {
}; };
const emsesp_devicedata_5 = { const emsesp_devicedata_5 = {
label: 'Mixer Module: MM10',
data: [ data: [
{ {
v: 30, v: 30,
@@ -1630,7 +1616,6 @@ const emsesp_devicedata_5 = {
}; };
const emsesp_devicedata_6 = { const emsesp_devicedata_6 = {
label: 'Solar Module: SM10',
data: [ data: [
{ {
v: 43.9, v: 43.9,
@@ -1780,7 +1765,6 @@ const emsesp_devicedata_6 = {
}; };
const emsesp_devicedata_99 = { const emsesp_devicedata_99 = {
label: 'User defined entities',
data: [ data: [
{ {
v: 5, v: 5,

View File

@@ -32,7 +32,7 @@
{115, DeviceType::BOILER, "Topline/GB162", DeviceFlags::EMS_DEVICE_FLAG_NONE}, {115, DeviceType::BOILER, "Topline/GB162", DeviceFlags::EMS_DEVICE_FLAG_NONE},
{121, DeviceType::BOILER, "Cascade MCM10", DeviceFlags::EMS_DEVICE_FLAG_NONE}, {121, DeviceType::BOILER, "Cascade MCM10", DeviceFlags::EMS_DEVICE_FLAG_NONE},
{122, DeviceType::BOILER, "Proline", DeviceFlags::EMS_DEVICE_FLAG_NONE}, {122, DeviceType::BOILER, "Proline", DeviceFlags::EMS_DEVICE_FLAG_NONE},
{123, DeviceType::BOILER, "GBx72/Trendline/Cerapur/Greenstar Si/27i-30i", DeviceFlags::EMS_DEVICE_FLAG_NONE}, {123, DeviceType::BOILER, "GBx72/Trendline/Cerapur/Greenstar Si", DeviceFlags::EMS_DEVICE_FLAG_NONE},
{131, DeviceType::BOILER, "GB212", DeviceFlags::EMS_DEVICE_FLAG_NONE}, {131, DeviceType::BOILER, "GB212", DeviceFlags::EMS_DEVICE_FLAG_NONE},
{132, DeviceType::BOILER, "GC7000F", DeviceFlags::EMS_DEVICE_FLAG_NONE}, {132, DeviceType::BOILER, "GC7000F", DeviceFlags::EMS_DEVICE_FLAG_NONE},
{133, DeviceType::BOILER, "Logano GB125/KB195i/Logamatic MC110", DeviceFlags::EMS_DEVICE_FLAG_NONE}, {133, DeviceType::BOILER, "Logano GB125/KB195i/Logamatic MC110", DeviceFlags::EMS_DEVICE_FLAG_NONE},

View File

@@ -831,8 +831,9 @@ std::string EMSdevice::get_value_uom(const char * key) const {
// except additional data is stored in the JSON document needed for the Web UI like the UOM and command // except additional data is stored in the JSON document needed for the Web UI like the UOM and command
// v=value, u=uom, n=name, c=cmd, h=help string, s=step, m=min, x=max // v=value, u=uom, n=name, c=cmd, h=help string, s=step, m=min, x=max
void EMSdevice::generate_values_web(JsonObject & output) { void EMSdevice::generate_values_web(JsonObject & output) {
output["label"] = to_string_short(); // output["label"] = to_string_short();
JsonArray data = output.createNestedArray("data"); // output["label"] = name_;
JsonArray data = output.createNestedArray("data");
for (auto & dv : devicevalues_) { for (auto & dv : devicevalues_) {
auto fullname = dv.get_fullname(); auto fullname = dv.get_fullname();

View File

@@ -340,7 +340,7 @@ void EMSESP::dump_all_values(uuid::console::Shell & shell) {
if (device.product_id == 160) { // MM100 if (device.product_id == 160) { // MM100
device_id = 0x28; // wwc device_id = 0x28; // wwc
} else { } else {
device_id = 0x20; // hc device_id = 0x20; // hc
} }
} else { } else {
device_id = 0x20; // should cover all the other device types device_id = 0x20; // should cover all the other device types
@@ -906,7 +906,7 @@ bool EMSESP::process_telegram(std::shared_ptr<const Telegram> telegram) {
if (telegram->type_id == publish_id_) { if (telegram->type_id == publish_id_) {
publish_id_ = 0; publish_id_ = 0;
} }
emsdevice->has_update(false); // reset flag emsdevice->has_update(false); // reset flag
if (!Mqtt::publish_single()) { if (!Mqtt::publish_single()) {
publish_device_values(emsdevice->device_type()); // publish to MQTT if we explicitly have too publish_device_values(emsdevice->device_type()); // publish to MQTT if we explicitly have too
} }
@@ -1098,7 +1098,7 @@ bool EMSESP::add_device(const uint8_t device_id, const uint8_t product_id, const
name = "Modem"; name = "Modem";
device_type = DeviceType::CONNECT; device_type = DeviceType::CONNECT;
} else if (device_id == EMSdevice::EMS_DEVICE_ID_CONVERTER) { } else if (device_id == EMSdevice::EMS_DEVICE_ID_CONVERTER) {
name = "Converter"; // generic name = "Converter"; // generic
} else if (device_id == EMSdevice::EMS_DEVICE_ID_CLOCK) { } else if (device_id == EMSdevice::EMS_DEVICE_ID_CLOCK) {
name = "Clock"; // generic name = "Clock"; // generic
device_type = DeviceType::CONTROLLER; device_type = DeviceType::CONTROLLER;
@@ -1124,6 +1124,7 @@ bool EMSESP::add_device(const uint8_t device_id, const uint8_t product_id, const
emsdevices.push_back(EMSFactory::add(device_type, device_id, product_id, version, name, flags, brand)); emsdevices.push_back(EMSFactory::add(device_type, device_id, product_id, version, name, flags, brand));
// assign a unique ID. Note that this is not actual unique after a restart as it's dependent on the order that devices are found // assign a unique ID. Note that this is not actual unique after a restart as it's dependent on the order that devices are found
// can't be 0 otherwise web won't work
emsdevices.back()->unique_id(++unique_id_count_); emsdevices.back()->unique_id(++unique_id_count_);
// sort devices based on type // sort devices based on type
@@ -1365,7 +1366,7 @@ void EMSESP::incoming_telegram(uint8_t * data, const uint8_t length) {
#endif #endif
Roomctrl::check((data[1] ^ 0x80 ^ rxservice_.ems_mask()), data); // check if there is a message for the roomcontroller Roomctrl::check((data[1] ^ 0x80 ^ rxservice_.ems_mask()), data); // check if there is a message for the roomcontroller
rxservice_.add(data, length); // add to RxQueue rxservice_.add(data, length); // add to RxQueue
} }
} }
@@ -1465,7 +1466,7 @@ void EMSESP::start() {
system_.system_restart(); system_.system_restart();
}; };
system_.reload_settings(); // ... and store some of the settings locally system_.reload_settings(); // ... and store some of the settings locally
webCustomizationService.begin(); // load the customizations webCustomizationService.begin(); // load the customizations
webSchedulerService.begin(); // load the scheduler events webSchedulerService.begin(); // load the scheduler events
@@ -1483,16 +1484,16 @@ void EMSESP::start() {
} }
// start all the EMS-ESP services // start all the EMS-ESP services
mqtt_.start(); // mqtt init mqtt_.start(); // mqtt init
system_.start(); // starts commands, led, adc, button, network, syslog & uart system_.start(); // starts commands, led, adc, button, network, syslog & uart
LOG_INFO(("Starting EMS-ESP version %s (hostname: %s)"), EMSESP_APP_VERSION, system_.hostname().c_str()); // welcome message LOG_INFO(("Starting EMS-ESP version %s (hostname: %s)"), EMSESP_APP_VERSION, system_.hostname().c_str()); // welcome message
shower_.start(); // initialize shower timer and shower alert shower_.start(); // initialize shower timer and shower alert
temperaturesensor_.start(); // Temperature external sensors temperaturesensor_.start(); // Temperature external sensors
analogsensor_.start(); // Analog external sensors analogsensor_.start(); // Analog external sensors
webLogService.start(); // apply settings to weblog service webLogService.start(); // apply settings to weblog service
// Load our library of known devices into stack mem. Names are stored in Flash memory // Load our library of known devices into stack mem. Names are stored in Flash memory
device_library_ = { device_library_ = {

View File

@@ -88,7 +88,7 @@ void WebDataService::core_data(AsyncWebServerRequest * request) {
obj["d"] = emsdevice->device_id(); // deviceid obj["d"] = emsdevice->device_id(); // deviceid
obj["p"] = emsdevice->product_id(); // productid obj["p"] = emsdevice->product_id(); // productid
obj["v"] = emsdevice->version(); // version obj["v"] = emsdevice->version(); // version
obj["e"] = emsdevice->count_entities(); // number of entities (device values) // obj["e"] = emsdevice->count_entities(); // number of entities (device values)
} }
} }
@@ -103,7 +103,7 @@ void WebDataService::core_data(AsyncWebServerRequest * request) {
obj["d"] = 0; // deviceid obj["d"] = 0; // deviceid
obj["p"] = 0; // productid obj["p"] = 0; // productid
obj["v"] = 0; // version obj["v"] = 0; // version
obj["e"] = EMSESP::webEntityService.count_entities(); // number of entities (device values) // obj["e"] = EMSESP::webEntityService.count_entities(); // number of entities (device values)
} }
root["connected"] = EMSESP::bus_status() != 2; root["connected"] = EMSESP::bus_status() != 2;