-
Notifications
You must be signed in to change notification settings - Fork 95
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
Support editable input types from HTML5 #1502
Conversation
common.blocks/dom/dom.js
Outdated
@@ -86,7 +86,9 @@ provide(/** @exports */{ | |||
switch(domNode.tagName.toLowerCase()) { | |||
case 'input': | |||
var type = domNode.type; | |||
return (type === 'text' || type === 'password') && !domNode.disabled && !domNode.readOnly; | |||
var editableInputTypes = ['date', 'datetime-local', 'month', 'number', 'password', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
codestyle requires to join var declarations
common.blocks/dom/dom.js
Outdated
return (type === 'text' || type === 'password') && !domNode.disabled && !domNode.readOnly; | ||
var editableInputTypes = ['date', 'datetime-local', 'month', 'number', 'password', | ||
'search', 'tel', 'text', 'time', 'url', 'week']; | ||
return (editableInputTypes.indexOf(type) >= 0) && !domNode.disabled && !domNode.readOnly; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need in brackets
/up |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Suggestion for #1501
cc @tadatuta