aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Panel.jsx
diff options
context:
space:
mode:
authorAntony Shaleynikov <shaleynikov@gmail.com>2017-03-01 23:58:06 +0300
committerAntony Shaleynikov <shaleynikov@gmail.com>2017-03-01 23:58:06 +0300
commit95699887ac75de5dff6bd25278289e31e4745482 (patch)
tree1d3ba6855fa867e90e380be4312578777736ff73 /src/Panel.jsx
parent19b96283c09e678b8b7ea5c60569996a0bab5935 (diff)
downloadtime-picker-95699887ac75de5dff6bd25278289e31e4745482.tar.gz
time-picker-95699887ac75de5dff6bd25278289e31e4745482.tar.zst
time-picker-95699887ac75de5dff6bd25278289e31e4745482.zip
Added 12hours display support
Diffstat (limited to 'src/Panel.jsx')
-rw-r--r--src/Panel.jsx5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Panel.jsx b/src/Panel.jsx
index fddea1c..d02bd01 100644
--- a/src/Panel.jsx
+++ b/src/Panel.jsx
@@ -37,6 +37,7 @@ const Panel = React.createClass({
37 showMinute: PropTypes.bool, 37 showMinute: PropTypes.bool,
38 showSecond: PropTypes.bool, 38 showSecond: PropTypes.bool,
39 onClear: PropTypes.func, 39 onClear: PropTypes.func,
40 show12Hours: PropTypes.bool,
40 addon: PropTypes.func, 41 addon: PropTypes.func,
41 }, 42 },
42 43
@@ -49,6 +50,7 @@ const Panel = React.createClass({
49 disabledMinutes: noop, 50 disabledMinutes: noop,
50 disabledSeconds: noop, 51 disabledSeconds: noop,
51 defaultOpenValue: moment(), 52 defaultOpenValue: moment(),
53 show12Hours: false,
52 addon: noop, 54 addon: noop,
53 }; 55 };
54 }, 56 },
@@ -90,7 +92,7 @@ const Panel = React.createClass({
90 const { 92 const {
91 prefixCls, className, placeholder, disabledHours, disabledMinutes, 93 prefixCls, className, placeholder, disabledHours, disabledMinutes,
92 disabledSeconds, hideDisabledOptions, allowEmpty, showHour, showMinute, showSecond, 94 disabledSeconds, hideDisabledOptions, allowEmpty, showHour, showMinute, showSecond,
93 format, defaultOpenValue, clearText, onEsc, addon, 95 format, defaultOpenValue, clearText, onEsc, addon, show12Hours,
94 } = this.props; 96 } = this.props;
95 const { 97 const {
96 value, currentSelectPanel, 98 value, currentSelectPanel,
@@ -140,6 +142,7 @@ const Panel = React.createClass({
140 disabledMinutes={disabledMinutes} 142 disabledMinutes={disabledMinutes}
141 disabledSeconds={disabledSeconds} 143 disabledSeconds={disabledSeconds}
142 onCurrentSelectPanelChange={this.onCurrentSelectPanelChange} 144 onCurrentSelectPanelChange={this.onCurrentSelectPanelChange}
145 show12Hours={show12Hours}
143 /> 146 />
144 {addon(this)} 147 {addon(this)}
145 </div> 148 </div>