mirror of
https://github.com/home-assistant/core.git
synced 2025-07-15 17:27:10 +00:00
Remove entity description mixin in Tado (#112947)
This commit is contained in:
parent
d0f53c2c99
commit
a0d50ecdf5
@ -34,19 +34,12 @@ from .entity import TadoDeviceEntity, TadoZoneEntity
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class TadoBinarySensorEntityDescriptionMixin:
|
||||
"""Mixin for required keys."""
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class TadoBinarySensorEntityDescription(BinarySensorEntityDescription):
|
||||
"""Describes Tado binary sensor entity."""
|
||||
|
||||
state_fn: Callable[[Any], bool]
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class TadoBinarySensorEntityDescription(
|
||||
BinarySensorEntityDescription, TadoBinarySensorEntityDescriptionMixin
|
||||
):
|
||||
"""Describes Tado binary sensor entity."""
|
||||
|
||||
attributes_fn: Callable[[Any], dict[Any, StateType]] | None = None
|
||||
|
||||
|
||||
|
@ -37,19 +37,12 @@ from .entity import TadoHomeEntity, TadoZoneEntity
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class TadoSensorEntityDescriptionMixin:
|
||||
"""Mixin for required keys."""
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class TadoSensorEntityDescription(SensorEntityDescription):
|
||||
"""Describes Tado sensor entity."""
|
||||
|
||||
state_fn: Callable[[Any], StateType]
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class TadoSensorEntityDescription(
|
||||
SensorEntityDescription, TadoSensorEntityDescriptionMixin
|
||||
):
|
||||
"""Describes Tado sensor entity."""
|
||||
|
||||
attributes_fn: Callable[[Any], dict[Any, StateType]] | None = None
|
||||
data_category: str | None = None
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user