mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Remove entity description mixin in VeSync (#112965)
This commit is contained in:
parent
105fca2212
commit
90769b460d
@ -36,19 +36,12 @@ from .const import DEV_TYPE_TO_HA, DOMAIN, SKU_TO_BASE_DEVICE, VS_DISCOVERY, VS_
|
|||||||
_LOGGER = logging.getLogger(__name__)
|
_LOGGER = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
|
||||||
@dataclass(frozen=True)
|
@dataclass(frozen=True, kw_only=True)
|
||||||
class VeSyncSensorEntityDescriptionMixin:
|
class VeSyncSensorEntityDescription(SensorEntityDescription):
|
||||||
"""Mixin for required keys."""
|
"""Describe VeSync sensor entity."""
|
||||||
|
|
||||||
value_fn: Callable[[VeSyncAirBypass | VeSyncOutlet | VeSyncSwitch], StateType]
|
value_fn: Callable[[VeSyncAirBypass | VeSyncOutlet | VeSyncSwitch], StateType]
|
||||||
|
|
||||||
|
|
||||||
@dataclass(frozen=True)
|
|
||||||
class VeSyncSensorEntityDescription(
|
|
||||||
SensorEntityDescription, VeSyncSensorEntityDescriptionMixin
|
|
||||||
):
|
|
||||||
"""Describe VeSync sensor entity."""
|
|
||||||
|
|
||||||
exists_fn: Callable[[VeSyncAirBypass | VeSyncOutlet | VeSyncSwitch], bool] = (
|
exists_fn: Callable[[VeSyncAirBypass | VeSyncOutlet | VeSyncSwitch], bool] = (
|
||||||
lambda _: True
|
lambda _: True
|
||||||
)
|
)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user