Closed craigmdennis closed 9 years ago
I've added the following:
body.addEventListener('keydown', function(event){
if (event.keyCode == 9) { // Tab
regularInput(event)
}
});
Ok, I see that I can probably do this with the API (coffeeScript)
# Set a custom 'typing' input
$('input').on 'input', ->
whatInput.set('typing')
Ok, that's still not as effective as only tracking the Tab keyCode
. Suggestions?
Hi Craig,
This is a good feature that I missed! You caught me while I've been traveling since last Wednesday so I haven't had time to sit down and look. I'll be back at my desk tomorrow and let you know what I figure out.
Hey Craig,
I just created this pull request that ignores typing in form fields. I'd appreciate if you'd take a look and see what you think.
I was thinking of allowing developers to set a data attribute flag on the body to ignore this behavior. Something like data-whatinput-allowformtyping
, but the default behavior would be to ignore form field typing. Thoughts?
Looks good! I agree that it should ignore inputs by default. Not sure about data-whatinput-allowformtyping
, seems a little verbose.
Not sure on the best approach but it would be nice to be able to still have 'mouse' set when typing in an input if the
:focus
was triggered by a click (or tap etc.).