mirror of
https://github.com/Electric-Special/ha-core.git
synced 2026-03-21 08:06:00 +01:00
Remove entity description mixin in Venstar (#112964)
This commit is contained in:
committed by
GitHub
parent
90769b460d
commit
39bfb2b5ba
@@ -66,20 +66,15 @@ SCHEDULE_PARTS: dict[int, str] = {
|
||||
}
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class VenstarSensorTypeMixin:
|
||||
"""Mixin for sensor required keys."""
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class VenstarSensorEntityDescription(SensorEntityDescription):
|
||||
"""Base description of a Sensor entity."""
|
||||
|
||||
value_fn: Callable[[VenstarDataUpdateCoordinator, str], Any]
|
||||
name_fn: Callable[[str], str]
|
||||
uom_fn: Callable[[Any], str | None]
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class VenstarSensorEntityDescription(SensorEntityDescription, VenstarSensorTypeMixin):
|
||||
"""Base description of a Sensor entity."""
|
||||
|
||||
|
||||
async def async_setup_entry(
|
||||
hass: HomeAssistant,
|
||||
config_entry: ConfigEntry,
|
||||
|
||||
Reference in New Issue
Block a user