diff --git a/homeassistant/components/overkiz/light.py b/homeassistant/components/overkiz/light.py index b640a184f58..77b8f9bad92 100644 --- a/homeassistant/components/overkiz/light.py +++ b/homeassistant/components/overkiz/light.py @@ -8,9 +8,7 @@ from pyoverkiz.enums import OverkizCommand, OverkizCommandParam, OverkizState from homeassistant.components.light import ( ATTR_BRIGHTNESS, ATTR_RGB_COLOR, - COLOR_MODE_BRIGHTNESS, - COLOR_MODE_ONOFF, - COLOR_MODE_RGB, + ColorMode, LightEntity, ) from homeassistant.config_entries import ConfigEntry @@ -50,11 +48,11 @@ class OverkizLight(OverkizEntity, LightEntity): self._attr_supported_color_modes = set() if self.executor.has_command(OverkizCommand.SET_RGB): - self._attr_supported_color_modes.add(COLOR_MODE_RGB) + self._attr_supported_color_modes.add(ColorMode.RGB) if self.executor.has_command(OverkizCommand.SET_INTENSITY): - self._attr_supported_color_modes.add(COLOR_MODE_BRIGHTNESS) + self._attr_supported_color_modes.add(ColorMode.BRIGHTNESS) if not self.supported_color_modes: - self._attr_supported_color_modes = {COLOR_MODE_ONOFF} + self._attr_supported_color_modes = {ColorMode.ONOFF} @property def is_on(self) -> bool: