mirror of
https://github.com/home-assistant/core.git
synced 2025-07-26 22:57:17 +00:00
Use ColorMode enum in avion (#70423)
This commit is contained in:
parent
44c1dc7f5a
commit
e806020bc3
@ -8,8 +8,8 @@ import voluptuous as vol
|
|||||||
|
|
||||||
from homeassistant.components.light import (
|
from homeassistant.components.light import (
|
||||||
ATTR_BRIGHTNESS,
|
ATTR_BRIGHTNESS,
|
||||||
COLOR_MODE_BRIGHTNESS,
|
|
||||||
PLATFORM_SCHEMA,
|
PLATFORM_SCHEMA,
|
||||||
|
ColorMode,
|
||||||
LightEntity,
|
LightEntity,
|
||||||
)
|
)
|
||||||
from homeassistant.const import (
|
from homeassistant.const import (
|
||||||
@ -73,8 +73,8 @@ def setup_platform(
|
|||||||
class AvionLight(LightEntity):
|
class AvionLight(LightEntity):
|
||||||
"""Representation of an Avion light."""
|
"""Representation of an Avion light."""
|
||||||
|
|
||||||
_attr_support_color_mode = COLOR_MODE_BRIGHTNESS
|
_attr_support_color_mode = ColorMode.BRIGHTNESS
|
||||||
_attr_support_color_modes = {COLOR_MODE_BRIGHTNESS}
|
_attr_support_color_modes = {ColorMode.BRIGHTNESS}
|
||||||
_attr_should_poll = False
|
_attr_should_poll = False
|
||||||
_attr_assumed_state = True
|
_attr_assumed_state = True
|
||||||
_attr_is_on = True
|
_attr_is_on = True
|
||||||
|
Loading…
x
Reference in New Issue
Block a user