darajava / queuetube

Make YouTube a little bit smoother
71 stars 7 forks source link

autosuggest missing #8

Open darajava opened 8 years ago

darajava commented 8 years ago

not sure if this one is possible to fix..

angrybacon commented 8 years ago

Was it impossible to keep the input and add your logic on it rather than crafting a new one? This would fix #27.

darajava commented 8 years ago

No, that's not possible (well maybe it is) but when you submit their search input, it does some mad stuff as it's a single page app, and not simply requesting a form. No matter what I did, I couldn't intercept submission of that input.

angrybacon commented 8 years ago

I don't really know jQuery that well. I was thinking about something like binding RET on the input that is already present. Depending on whether YouTube itself uses jQuery (and you use your own version, not too sure what kind of sorcery this may breed), you might need to empty the list of event for RET or preventDefault. This also requires you to handle click events on search candidates (and the markup looks quite troublesome/random to find with jQuery).

Or you could just build your own suggestion dropdown?

But this is just speculative, as I don't know neither of YouTube's APi nor your code.

darajava commented 8 years ago

I will create this myself in a future update.