-
Notifications
You must be signed in to change notification settings - Fork 1
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 it possible to change the angle with the mouse #8
Comments
I've implemented a drag function for this. I've added a rotate handle at one end of the gradient line. Not really happy on how it moves as the offset is off at certain angles. Maybe the handle should be added at both ends and look more like the color label. If the code looks right to you I can make a pull. |
Yes, I was about to propose: what about making the 2 end points of the gradient line draggable instead? which is the same thing. I'll take a look at the code. Thanks for helping. |
Sure will do that. As far as the code goes, I had to use few global variables. I would usually create a closure or abject for the drag. I guess that if this goes into DevTools it will be in its own window. |
Thanks! |
Dragging the gradient-line edges would be a good way to do this.
Maybe also dragging from the angle arc could work.
The text was updated successfully, but these errors were encountered: