Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make color config publicly available #328

Merged
merged 2 commits into from
Dec 22, 2024

Conversation

WhySoBad
Copy link
Contributor

Hi,

In my application of the tapo library I need to convert the colors of the Color enum to their hue, saturation and kelvin values. I saw you already implemented a static mapping for those colors but this is only publicly accessible inside the crate. Therefore, I implemented a new get_color_config() method on the Color enum to get the color config for a specific color.

Additionally, I changed the colors from the color map to no longer be tuples of options but instead convert the values to options in the only use case of the COLOR_MAP in the library.

@mihai-dinculescu mihai-dinculescu merged commit dd1fd23 into mihai-dinculescu:main Dec 22, 2024
18 checks passed
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.

2 participants