Skip to content

feat(light): add convenience setters for brightness, kelvin, rgb, and color#29

Merged
Faerkeren merged 1 commit into
mainfrom
feat/light-convenience-setters
Apr 26, 2026
Merged

feat(light): add convenience setters for brightness, kelvin, rgb, and color#29
Faerkeren merged 1 commit into
mainfrom
feat/light-convenience-setters

Conversation

@Faerkeren

Copy link
Copy Markdown
Contributor

Summary

  • Add set_brightness(brightness) — set brightness directly without turn_on(brightness=...)
  • Add set_kelvin(kelvin) — set color temperature in Kelvin
  • Add set_rgb(r, g, b) — set RGB color with separate component args
  • Add set_color(*, rgb=, kelvin=) — unified color setter accepting either RGB or Kelvin (exactly one required)
  • All setters accept an optional transition parameter and implicitly turn the light on
  • Full test coverage for all new methods including validation error cases

… color

Add set_brightness(), set_kelvin(), set_rgb(), and set_color() methods
to the Light domain for a more intuitive API that doesn't require
calling turn_on() with keyword arguments for simple property changes.
@Faerkeren Faerkeren merged commit 26c9345 into main Apr 26, 2026
12 checks passed
@Faerkeren Faerkeren deleted the feat/light-convenience-setters branch April 26, 2026 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant