Trigger text input events with HTML5 text-like fields #246

Merged
merged 1 commit into from Jan 19, 2012

Projects

None yet

2 participants

@ylg
ylg commented Jan 19, 2012

In addition to inputs with a type of email (handled already in #106,) HTML5 adds four more types represented as text controls: number, search, tel, and url.

http://www.w3.org/TR/html5/the-input-element.html#attr-input-type

This patch applies the events already setup for email, password, and text to number, search, tel, and url and cleans up those areas I touched. It doesn't apply type specific behaviors, e.g., stripping non-numeric characters from a number input when change is fired, or spinner events.

@jferris jferris merged commit 7e5e99b into thoughtbot:master Jan 19, 2012
@jferris
Member
jferris commented Jan 19, 2012

Thanks for the patch. I merged this in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment