mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-06 07:49:52 +03:00
improve layout
This commit is contained in:
@@ -436,7 +436,9 @@ const DashboardDevices: FC = () => {
|
||||
}
|
||||
|
||||
const sendCommand = (dv: DeviceValue) => {
|
||||
setSelectedDeviceValueWriteable(dv.c && me.admin && !hasMask(dv.id, DeviceEntityMask.DV_READONLY));
|
||||
if (dv.c !== undefined) {
|
||||
setSelectedDeviceValueWriteable(me.admin && !hasMask(dv.id, DeviceEntityMask.DV_READONLY));
|
||||
}
|
||||
setSelectedDeviceValue(dv);
|
||||
setDeviceValueDialogOpen(true);
|
||||
};
|
||||
|
||||
@@ -109,7 +109,15 @@ const DashboarDevicesDialog = ({
|
||||
};
|
||||
|
||||
return (
|
||||
<Dialog open={open} onClose={close}>
|
||||
<Dialog
|
||||
open={open}
|
||||
onClose={close}
|
||||
sx={{
|
||||
'& .MuiDialog-paper': {
|
||||
borderRadius: '16px'
|
||||
}
|
||||
}}
|
||||
>
|
||||
<DialogTitle>
|
||||
{selectedItem.v === '' && selectedItem.c ? LL.RUN_COMMAND() : writeable ? LL.CHANGE_VALUE() : LL.VALUE(1)}
|
||||
</DialogTitle>
|
||||
|
||||
Reference in New Issue
Block a user