Replace comments with docstring in ColorMode enum (#90408)

This commit is contained in:
epenet 2023-03-28 16:32:39 +02:00 committed by GitHub
parent 02e2e4d039
commit bdf29b594f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -68,16 +68,20 @@ ATTR_SUPPORTED_COLOR_MODES = "supported_color_modes"
class ColorMode(StrEnum):
"""Possible light color modes."""
UNKNOWN = "unknown" # Ambiguous color mode
ONOFF = "onoff" # Must be the only supported mode
BRIGHTNESS = "brightness" # Must be the only supported mode
UNKNOWN = "unknown"
"""Ambiguous color mode"""
ONOFF = "onoff"
"""Must be the only supported mode"""
BRIGHTNESS = "brightness"
"""Must be the only supported mode"""
COLOR_TEMP = "color_temp"
HS = "hs"
XY = "xy"
RGB = "rgb"
RGBW = "rgbw"
RGBWW = "rgbww"
WHITE = "white" # Must *NOT* be the only supported mode
WHITE = "white"
"""Must *NOT* be the only supported mode"""
# These COLOR_MODE_* constants are deprecated as of Home Assistant 2022.5.