mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Remove entity description mixin in iBeacon (#112779)
This commit is contained in:
parent
bfd9199ad9
commit
cf5b11576b
@ -24,18 +24,13 @@ from .coordinator import IBeaconCoordinator
|
||||
from .entity import IBeaconEntity
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class IBeaconRequiredKeysMixin:
|
||||
"""Mixin for required keys."""
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class IBeaconSensorEntityDescription(SensorEntityDescription):
|
||||
"""Describes iBeacon sensor entity."""
|
||||
|
||||
value_fn: Callable[[iBeaconAdvertisement], str | int | None]
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class IBeaconSensorEntityDescription(SensorEntityDescription, IBeaconRequiredKeysMixin):
|
||||
"""Describes iBeacon sensor entity."""
|
||||
|
||||
|
||||
SENSOR_DESCRIPTIONS = (
|
||||
IBeaconSensorEntityDescription(
|
||||
key="rssi",
|
||||
|
Loading…
x
Reference in New Issue
Block a user