aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--README.md1
-rw-r--r--src/TimePicker.jsx5
2 files changed, 5 insertions, 1 deletions
diff --git a/README.md b/README.md
index 3baa0ce..c0ce889 100644
--- a/README.md
+++ b/README.md
@@ -60,6 +60,7 @@ API
60| value | moment | null | current value | 60| value | moment | null | current value |
61| placeholder | String | '' | time input's placeholder | 61| placeholder | String | '' | time input's placeholder |
62| className | String | '' | time picker className | 62| className | String | '' | time picker className |
63| id | String | '' | time picker id |
63| popupClassName | String | '' | time panel className | 64| popupClassName | String | '' | time panel className |
64| showHour | Boolean | true | whether show hour | | 65| showHour | Boolean | true | whether show hour | |
65| showMinute | Boolean | true | whether show minute | 66| showMinute | Boolean | true | whether show minute |
diff --git a/src/TimePicker.jsx b/src/TimePicker.jsx
index a37fec2..26166f4 100644
--- a/src/TimePicker.jsx
+++ b/src/TimePicker.jsx
@@ -55,6 +55,7 @@ export default class Picker extends Component {
55 focusOnOpen: PropTypes.bool, 55 focusOnOpen: PropTypes.bool,
56 onKeyDown: PropTypes.func, 56 onKeyDown: PropTypes.func,
57 autoFocus: PropTypes.bool, 57 autoFocus: PropTypes.bool,
58 id: PropTypes.string,
58 }; 59 };
59 60
60 static defaultProps = { 61 static defaultProps = {
@@ -65,6 +66,7 @@ export default class Picker extends Component {
65 style: {}, 66 style: {},
66 className: '', 67 className: '',
67 popupClassName: '', 68 popupClassName: '',
69 id: '',
68 align: {}, 70 align: {},
69 defaultOpenValue: moment(), 71 defaultOpenValue: moment(),
70 allowEmpty: true, 72 allowEmpty: true,
@@ -253,7 +255,7 @@ export default class Picker extends Component {
253 255
254 render() { 256 render() {
255 const { 257 const {
256 prefixCls, placeholder, placement, align, 258 prefixCls, placeholder, placement, align, id,
257 disabled, transitionName, style, className, getPopupContainer, name, autoComplete, 259 disabled, transitionName, style, className, getPopupContainer, name, autoComplete,
258 onFocus, onBlur, autoFocus, inputReadOnly, 260 onFocus, onBlur, autoFocus, inputReadOnly,
259 } = this.props; 261 } = this.props;
@@ -290,6 +292,7 @@ export default class Picker extends Component {
290 autoFocus={autoFocus} 292 autoFocus={autoFocus}
291 onChange={noop} 293 onChange={noop}
292 readOnly={!!inputReadOnly} 294 readOnly={!!inputReadOnly}
295 id={id}
293 /> 296 />
294 <span className={`${prefixCls}-icon`}/> 297 <span className={`${prefixCls}-icon`}/>
295 </span> 298 </span>