浏览代码

Add select input after incorrect input

j8
Ilya Daynatovich 8 年前
父节点
当前提交
22b7142159
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3
    1
      modules/UI/invite/RequirePasswordDialog.js

+ 3
- 1
modules/UI/invite/RequirePasswordDialog.js 查看文件

123
      */
123
      */
124
     _showError() {
124
     _showError() {
125
         let className = this.inputErrorClass;
125
         let className = this.inputErrorClass;
126
+        let input = document.getElementById(this.inputId);
126
         document.getElementById(this.errorId).classList.remove('hide');
127
         document.getElementById(this.errorId).classList.remove('hide');
127
-        document.getElementById(this.inputId).classList.add(className);
128
+        input.classList.add(className);
129
+        input.select();
128
     }
130
     }
129
 
131
 
130
     /**
132
     /**

正在加载...
取消
保存