-
Notifications
You must be signed in to change notification settings - Fork 78
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
feat(color): allow color input nudging by using ⬆ ⬇ (+shift) keys #1295
feat(color): allow color input nudging by using ⬆ ⬇ (+shift) keys #1295
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Rad! Thanks for adding these. Looking at it, it seems like the "H" channel allows you to loop through values continuously without stopping at the top limit. Doesn't seem to happen on other HSV channels or any RGB: Edit: I understand why this might be intentional due to hue being able to cycle, but seemed a bit unexpected, if we keep it you should also be able to cycle “backwards” past 0, right now it limits to 0 when decrementing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved with comment above!
I'll create a separate issue to discuss how to approach this. The current behavior is more of a side effect. |
Related Issue: #866
Summary
This enhances
calcite-color
andcalcite-color-hex-input
to allow nudging values when using the arrow keys. Values are nudged by 1 or by 10 if the shift key is pressed alongside an arrow key.Note that for the hex input, each channel value will be nudged. This is follows how Figma's hex input works, which is referenced in the related issue.