mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-24 09:46:36 +00:00
Ensure device info categories notify, event and assist always show (#21994)
Currently we have the entity category always win. However, we have some functional categories on a device, notify, event, assist. It would be good to always show these togehter.
This commit is contained in:
parent
717443e2d6
commit
2b33c70e04
@ -189,20 +189,20 @@ export class HaConfigDevicePage extends LitElement {
|
||||
const result = groupBy(entities, (entry) => {
|
||||
const domain = computeDomain(entry.entity_id);
|
||||
|
||||
if (entry.entity_category) {
|
||||
return entry.entity_category;
|
||||
if (ASSIST_ENTITIES.includes(domain)) {
|
||||
return "assist";
|
||||
}
|
||||
|
||||
if (domain === "event" || domain === "notify") {
|
||||
return domain;
|
||||
}
|
||||
|
||||
if (SENSOR_ENTITIES.includes(domain)) {
|
||||
return "sensor";
|
||||
if (entry.entity_category) {
|
||||
return entry.entity_category;
|
||||
}
|
||||
|
||||
if (ASSIST_ENTITIES.includes(domain)) {
|
||||
return "assist";
|
||||
if (SENSOR_ENTITIES.includes(domain)) {
|
||||
return "sensor";
|
||||
}
|
||||
|
||||
return "control";
|
||||
|
Loading…
x
Reference in New Issue
Block a user