| Index: go-back-with-backspace/is_editable.js
|
| diff --git a/go-back-with-backspace/is_editable.js b/go-back-with-backspace/is_editable.js
|
| index 585aa4fa856968be03aff0afcf704fd936eccf04..d0e4114ebee40f58b60fb4a8a973e24391118a08 100644
|
| --- a/go-back-with-backspace/is_editable.js
|
| +++ b/go-back-with-backspace/is_editable.js
|
| @@ -6,16 +6,24 @@ function isEditable(path) {
|
| if (target.isContentEditable)
|
| return true;
|
|
|
| - // Several types of input fields are editable, but not all (e.g., checkboxes).
|
| - var nodeName = target.nodeName;
|
| - var nodeType = target.type;
|
| + // Many types of input fields are editable, but not all (e.g., checkboxes).
|
| + var nodeName = target.nodeName.toUpperCase();
|
| + var nodeType = target.type || '';
|
| + nodeType = nodeType.toLowerCase();
|
| if (nodeName === 'TEXTAREA' ||
|
| (nodeName === 'INPUT' && (nodeType === 'text' ||
|
| - nodeType === 'email' ||
|
| - nodeType === 'number' ||
|
| nodeType === 'password' ||
|
| nodeType === 'search' ||
|
| - nodeType === 'tel'))) {
|
| + nodeType === 'date' ||
|
| + nodeType === 'datetime' ||
|
| + nodeType === 'datetime-local' ||
|
| + nodeType === 'email' ||
|
| + nodeType === 'month' ||
|
| + nodeType === 'number' ||
|
| + nodeType === 'tel' ||
|
| + nodeType === 'time' ||
|
| + nodeType === 'url' ||
|
| + nodeType === 'week'))) {
|
| return true;
|
| }
|
|
|
|
|