mirror of
https://github.com/home-assistant/core.git
synced 2026-09-24 07:25:52 -05:00
Remove entity description mixin in Pi-hole (#112919)
This commit is contained in:
@@ -22,19 +22,11 @@ from . import PiHoleEntity
|
||||
from .const import DATA_KEY_API, DATA_KEY_COORDINATOR, DOMAIN as PIHOLE_DOMAIN
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class RequiredPiHoleBinaryDescription:
|
||||
"""Represent the required attributes of the PiHole binary description."""
|
||||
|
||||
state_value: Callable[[Hole], bool]
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class PiHoleBinarySensorEntityDescription(
|
||||
BinarySensorEntityDescription, RequiredPiHoleBinaryDescription
|
||||
):
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class PiHoleBinarySensorEntityDescription(BinarySensorEntityDescription):
|
||||
"""Describes PiHole binary sensor entity."""
|
||||
|
||||
state_value: Callable[[Hole], bool]
|
||||
extra_value: Callable[[Hole], dict[str, Any] | None] = lambda api: None
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user