Browse Source

现病史双击编辑数字键盘阻止冒泡1234

zhouna 6 năm trước cách đây
mục cha
commit
f78ecc6489
1 tập tin đã thay đổi với 2 bổ sung1 xóa
  1. 2 1
      src/components/NumberDrop/index.jsx

+ 2 - 1
src/components/NumberDrop/index.jsx

@@ -262,7 +262,8 @@ class NumberDrop extends Component{
                 onClick={allClick?this.handleNumClick:null}
                 contentEditable={editable}
                 onBlur={this.handleBlur}
-                onkeydown={handleEnter}>
+                onkeydown={handleEnter}
+                onFocus={(e)=>{e.stopPropagation()}}>
       <span ref = {this.$pre}>&nbsp;{prefix}</span>
       <span onFocus={this.handleNumFocus}
             onClick={allClick?null:this.handleNumClick}