nicroto / viktor

Synthesizer built on the WebAudio API.
http://nicroto.github.io/viktor/
MIT License
509 stars 93 forks source link

Implemented Issue 18 Text Inputs #29

Closed taylorstutts closed 7 years ago

taylorstutts commented 7 years ago

Added text inputs to webaudio knobs and sliders. This is implemented in the embedded CSS and JS in the webaudio knob and slider HTML files, the template files for the various components, and their respective style files. Currently live demo at https://taylorstutts.github.io/viktor/ .

nicroto commented 7 years ago

Hi,

Sorry for the late response. And thanks for working on this. But I'm afraid I can't merge the pull request. Mainly because I don't agree with at least couple of things about it.

That being said, I think we can fix those issues and merge the bulk of your work.

For future contributions, that you might be doing on the NV-1, please remember to always trigger a discussion with me before writing any code. As I've said in the README: "Always submit an issue (and wait for response from an owner), before you start coding, except in obvious situations like non-breaking fixes;"

You should've commented on the issue (since there is one already), so we can decide on what exactly needs to be done there.

Now on the problems at hand.

Too much text.

My main problem is that all of these fields, visible at all times... that doesn't look good to me. It's too much text. If you open the official version, right beside it - you'll see it even stretches the background.

When you think about it, when do you even need such finer control of a parameter - you would only need it on params with huge amount of potential values, where precision of hand movement, just doesn't cut it. So:

Still, those are quite a lot:

The best thing that I can think of is showing the text field only if you start tweaking the parameter. Maybe not even on hover, but when you have made a full click (like selecting the control). Then you see a textbox which you can change. And clicking somewhere else hides it and so does a timeout after you last used it (it will autohide unless you do something with it within certain time). And it shouldn't push any content either (absolute container on top of it).

Implementation.

You've implemented it directly into my unofficial version of the webaudio-controls, which is inside of the repo. It may not be the best idea to change the project and make it diverge any further from the official one (I think they even merged my changes since, just haven't had the time to do maintenance on this), but I am kind of OK of doing it this way, since if anything else, at some point I want to remove that dependency all together and use something else.

Here the blame is partially mine - I've included the code of webaudio-controls, because I needed to make some fixes which I wasn't sure when (if at all) are going to land in the official project's repo. But I do have a fork in my account.

So, the procedure would be to fork my fork of webaudio-controls, add your changes there (diff the implementation in the NV-1 with each branch to see which one was holding the current state, if it isn't master), submit a pull request. I would look at that and merge the changes in my fork of webaudio-controls and update the NV-1 repo with the new version.

Otherwise I like the non-invasive style of your changes as footprint in the NV-1's repository (haven't had the time to revise the actual changes to webaudio-controls).

What can we do to preserve your work?

Here are the steps that I see:

That's the only way I see to get this done right and not to lose your changes.

Please note - I am only willing to even just discuss this complex fix, because it's the first time that someone has decided to contribute to the project. But now you know - first we discuss what needs to be done, than we work on it, not the other way around. This is the only way any future contributions will get in.

Let me know, if you want to do this in the github issue for the task.

Happy Holidays!

taylorstutts commented 7 years ago

Hi,

I hope your holidays went well. Thanks for getting back to me and reviewing my changes. I appreciate your detailed explanation of how to proceed.

I'm not sure if I can still send a reply for this closed request. If this message doesn't make it to you I will try a different avenue.

I wanted to explain that I had originally started working on this to help myself learn Angular. I searched for an interesting open-source project that uses Angular, and I picked what seemed like a simple item off the open issues list as a starting point. I should have communicated with you before sending the merge request but the code was something I was working on for myself anyway, so that is why I started coding before I contacted you, and you don't have to go out of your way just to include my work.

I will review your plan for implementation and post to the github issue to discuss continuing development. I think the project looks great so far and I would be happy to contribute if I can.

On Thu, Dec 22, 2016 at 6:50 AM, Nikolay Tsenkov notifications@github.com wrote:

Closed #29 https://github.com/nicroto/viktor/pull/29.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/nicroto/viktor/pull/29#event-902935566, or mute the thread https://github.com/notifications/unsubscribe-auth/ASYgT6oxfEwZl0J4FjWSUoy17MAXGKo_ks5rKnIDgaJpZM4LFAgX .