mirror of
https://github.com/home-assistant/frontend.git
synced 2025-04-27 14:57:20 +00:00
Show moisture/flood alerts in the Area card (#12978)
This commit is contained in:
parent
9fa8a96d09
commit
8bd7370a02
@ -6,6 +6,7 @@ import {
|
|||||||
mdiThermometer,
|
mdiThermometer,
|
||||||
mdiToggleSwitch,
|
mdiToggleSwitch,
|
||||||
mdiToggleSwitchOff,
|
mdiToggleSwitchOff,
|
||||||
|
mdiWaterAlert,
|
||||||
mdiWaterPercent,
|
mdiWaterPercent,
|
||||||
} from "@mdi/js";
|
} from "@mdi/js";
|
||||||
import type { HassEntity, UnsubscribeFunc } from "home-assistant-js-websocket";
|
import type { HassEntity, UnsubscribeFunc } from "home-assistant-js-websocket";
|
||||||
@ -63,7 +64,7 @@ const OTHER_DOMAINS = ["camera"];
|
|||||||
|
|
||||||
const DEVICE_CLASSES = {
|
const DEVICE_CLASSES = {
|
||||||
sensor: ["temperature", "humidity"],
|
sensor: ["temperature", "humidity"],
|
||||||
binary_sensor: ["motion"],
|
binary_sensor: ["motion", "moisture"],
|
||||||
};
|
};
|
||||||
|
|
||||||
const DOMAIN_ICONS = {
|
const DOMAIN_ICONS = {
|
||||||
@ -76,6 +77,7 @@ const DOMAIN_ICONS = {
|
|||||||
},
|
},
|
||||||
binary_sensor: {
|
binary_sensor: {
|
||||||
motion: mdiRun,
|
motion: mdiRun,
|
||||||
|
moisture: mdiWaterAlert,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user