mirror of
https://github.com/home-assistant/core.git
synced 2025-07-27 23:27:37 +00:00
Remove entity description mixin in Xiaomi Miio (#112973)
This commit is contained in:
parent
ea300623f9
commit
85b6d70b04
@ -109,17 +109,12 @@ ATTR_OSCILLATION_ANGLE = "angle"
|
||||
ATTR_VOLUME = "volume"
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class XiaomiMiioNumberMixin:
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class XiaomiMiioNumberDescription(NumberEntityDescription):
|
||||
"""A class that describes number entities."""
|
||||
|
||||
method: str
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class XiaomiMiioNumberDescription(NumberEntityDescription, XiaomiMiioNumberMixin):
|
||||
"""A class that describes number entities."""
|
||||
|
||||
available_with_device_off: bool = True
|
||||
|
||||
|
||||
|
@ -220,21 +220,14 @@ MODEL_TO_FEATURES_MAP = {
|
||||
}
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class XiaomiMiioSwitchRequiredKeyMixin:
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class XiaomiMiioSwitchDescription(SwitchEntityDescription):
|
||||
"""A class that describes switch entities."""
|
||||
|
||||
feature: int
|
||||
method_on: str
|
||||
method_off: str
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class XiaomiMiioSwitchDescription(
|
||||
SwitchEntityDescription, XiaomiMiioSwitchRequiredKeyMixin
|
||||
):
|
||||
"""A class that describes switch entities."""
|
||||
|
||||
available_with_device_off: bool = True
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user