mirror of
https://github.com/home-assistant/core.git
synced 2025-12-26 14:08:21 +00:00
Move DeviceInfo from entity to device registry (#98149)
* Move DeviceInfo from entity to device registry * Update integrations
This commit is contained in:
@@ -28,7 +28,6 @@ if TYPE_CHECKING:
|
||||
from homeassistant.config_entries import ConfigEntry
|
||||
|
||||
from . import entity_registry
|
||||
from .entity import DeviceInfo
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
@@ -65,6 +64,26 @@ DISABLED_CONFIG_ENTRY = DeviceEntryDisabler.CONFIG_ENTRY.value
|
||||
DISABLED_INTEGRATION = DeviceEntryDisabler.INTEGRATION.value
|
||||
DISABLED_USER = DeviceEntryDisabler.USER.value
|
||||
|
||||
|
||||
class DeviceInfo(TypedDict, total=False):
|
||||
"""Entity device information for device registry."""
|
||||
|
||||
configuration_url: str | URL | None
|
||||
connections: set[tuple[str, str]]
|
||||
default_manufacturer: str
|
||||
default_model: str
|
||||
default_name: str
|
||||
entry_type: DeviceEntryType | None
|
||||
identifiers: set[tuple[str, str]]
|
||||
manufacturer: str | None
|
||||
model: str | None
|
||||
name: str | None
|
||||
suggested_area: str | None
|
||||
sw_version: str | None
|
||||
hw_version: str | None
|
||||
via_device: tuple[str, str]
|
||||
|
||||
|
||||
DEVICE_INFO_TYPES = {
|
||||
# Device info is categorized by finding the first device info type which has all
|
||||
# the keys of the device info. The link device info type must be kept first
|
||||
|
||||
Reference in New Issue
Block a user