Browse Source

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

zhouna 6 years ago
parent
commit
f78ecc6489
1 changed files with 2 additions and 1 deletions
  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}