mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-29 12:16:39 +00:00
Merge pull request #4152 from home-assistant/haptics
Only do haptic on entity interactions
This commit is contained in:
commit
c6fb896fe4
@ -72,6 +72,7 @@ export const handleClick = (
|
|||||||
case "toggle":
|
case "toggle":
|
||||||
if (config.entity) {
|
if (config.entity) {
|
||||||
toggleEntity(hass, config.entity!);
|
toggleEntity(hass, config.entity!);
|
||||||
|
forwardHaptic("light");
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case "call-service": {
|
case "call-service": {
|
||||||
@ -81,7 +82,7 @@ export const handleClick = (
|
|||||||
}
|
}
|
||||||
const [domain, service] = actionConfig.service.split(".", 2);
|
const [domain, service] = actionConfig.service.split(".", 2);
|
||||||
hass.callService(domain, service, actionConfig.service_data);
|
hass.callService(domain, service, actionConfig.service_data);
|
||||||
|
forwardHaptic("light");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
forwardHaptic("light");
|
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user