mirror of
https://github.com/home-assistant/core.git
synced 2025-04-23 16:57:53 +00:00
Use enum instead of string for button entities key in Overkiz (#133472)
This commit is contained in:
parent
fa0e54e658
commit
05b0c56191
@ -28,41 +28,47 @@ class OverkizButtonDescription(ButtonEntityDescription):
|
||||
BUTTON_DESCRIPTIONS: list[OverkizButtonDescription] = [
|
||||
# My Position (cover, light)
|
||||
OverkizButtonDescription(
|
||||
key="my",
|
||||
key=OverkizCommand.MY,
|
||||
name="My position",
|
||||
icon="mdi:star",
|
||||
),
|
||||
# Identify
|
||||
OverkizButtonDescription(
|
||||
key="identify", # startIdentify and identify are reversed... Swap this when fixed in API.
|
||||
key=OverkizCommand.IDENTIFY, # startIdentify and identify are reversed... Swap this when fixed in API.
|
||||
name="Start identify",
|
||||
icon="mdi:human-greeting-variant",
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
entity_registry_enabled_default=False,
|
||||
),
|
||||
OverkizButtonDescription(
|
||||
key="stopIdentify",
|
||||
key=OverkizCommand.STOP_IDENTIFY,
|
||||
name="Stop identify",
|
||||
icon="mdi:human-greeting-variant",
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
entity_registry_enabled_default=False,
|
||||
),
|
||||
OverkizButtonDescription(
|
||||
key="startIdentify", # startIdentify and identify are reversed... Swap this when fixed in API.
|
||||
key=OverkizCommand.START_IDENTIFY, # startIdentify and identify are reversed... Swap this when fixed in API.
|
||||
name="Identify",
|
||||
icon="mdi:human-greeting-variant",
|
||||
entity_category=EntityCategory.DIAGNOSTIC,
|
||||
),
|
||||
# RTDIndoorSiren / RTDOutdoorSiren
|
||||
OverkizButtonDescription(key="dingDong", name="Ding dong", icon="mdi:bell-ring"),
|
||||
OverkizButtonDescription(key="bip", name="Bip", icon="mdi:bell-ring"),
|
||||
OverkizButtonDescription(
|
||||
key="fastBipSequence", name="Fast bip sequence", icon="mdi:bell-ring"
|
||||
key=OverkizCommand.DING_DONG, name="Ding dong", icon="mdi:bell-ring"
|
||||
),
|
||||
OverkizButtonDescription(key=OverkizCommand.BIP, name="Bip", icon="mdi:bell-ring"),
|
||||
OverkizButtonDescription(
|
||||
key=OverkizCommand.FAST_BIP_SEQUENCE,
|
||||
name="Fast bip sequence",
|
||||
icon="mdi:bell-ring",
|
||||
),
|
||||
OverkizButtonDescription(
|
||||
key=OverkizCommand.RING, name="Ring", icon="mdi:bell-ring"
|
||||
),
|
||||
OverkizButtonDescription(key="ring", name="Ring", icon="mdi:bell-ring"),
|
||||
# DynamicScreen (ogp:blind) uses goToAlias (id 1: favorite1) instead of 'my'
|
||||
OverkizButtonDescription(
|
||||
key="goToAlias",
|
||||
key=OverkizCommand.GO_TO_ALIAS,
|
||||
press_args="1",
|
||||
name="My position",
|
||||
icon="mdi:star",
|
||||
|
Loading…
x
Reference in New Issue
Block a user