]> git.immae.eu Git - github/fretlink/time-picker.git/commitdiff
Merge branch 'master' into feat-focus
author偏右 <afc163@gmail.com>
Mon, 20 Feb 2017 08:03:41 +0000 (16:03 +0800)
committerGitHub <noreply@github.com>
Mon, 20 Feb 2017 08:03:41 +0000 (16:03 +0800)
package.json
src/TimePicker.jsx

index 1a4d8280cc5547a0643fe36fcc9c6d1e6997a646..1f8b474abb9099213fea9e6c11e916328f6cf9fa 100644 (file)
@@ -49,7 +49,7 @@
     "jquery": "1.x",
     "pre-commit": "1.x",
     "rc-tools": "5.x",
-    "rc-util": "^3.1.2",
+    "rc-util": "^4.0.0",
     "react": "15.x",
     "react-addons-test-utils": "15.x",
     "react-dom": "15.x"
index da47ac4d9c211192c985f6dbc0d9c88ae60feb8a..aa3e0da726f009c6e54b69696945b8b382048765 100644 (file)
@@ -106,7 +106,7 @@ const Picker = React.createClass({
 
   onEsc() {
     this.setOpen(false);
-    this.picker.focus();
+    this.focus();
   },
 
   onKeyDown(e) {
@@ -185,6 +185,10 @@ const Picker = React.createClass({
     }
   },
 
+  focus() {
+    this.picker.focus();
+  },
+
   render() {
     const {
       prefixCls, placeholder, placement, align,