mirror of
https://github.com/ant-design/ant-design.git
synced 2025-01-18 06:03:38 +08:00
update code style
This commit is contained in:
parent
2ec38b1072
commit
c1bd0098d2
@ -50,9 +50,7 @@ export default React.createClass({
|
||||
},
|
||||
handleChange(value) {
|
||||
if (!('value' in this.props)) {
|
||||
this.setState({
|
||||
value
|
||||
});
|
||||
this.setState({ value });
|
||||
}
|
||||
const startTime = value[0] ? new Date(value[0].getTime()) : null;
|
||||
const endTime = value[1] ? new Date(value[1].getTime()) : null;
|
||||
@ -107,7 +105,6 @@ export default React.createClass({
|
||||
locale={locale.lang}
|
||||
onOk={onOk}
|
||||
defaultValue={[defaultCalendarValue, defaultCalendarValue]}
|
||||
showClear
|
||||
{...calendarHandler}
|
||||
/>
|
||||
);
|
||||
|
@ -24,7 +24,7 @@ function createPicker(TheCalendar, defaultFormat) {
|
||||
align: {
|
||||
offset: [0, -9],
|
||||
},
|
||||
open: false
|
||||
open: false,
|
||||
};
|
||||
},
|
||||
getInitialState() {
|
||||
@ -42,9 +42,7 @@ function createPicker(TheCalendar, defaultFormat) {
|
||||
},
|
||||
handleChange(value) {
|
||||
if (!('value' in this.props)) {
|
||||
this.setState({
|
||||
value,
|
||||
});
|
||||
this.setState({ value });
|
||||
}
|
||||
const timeValue = value ? new Date(value.getTime()) : null;
|
||||
this.props.onChange(timeValue);
|
||||
@ -97,8 +95,7 @@ function createPicker(TheCalendar, defaultFormat) {
|
||||
dateInputPlaceholder={placeholder}
|
||||
prefixCls="ant-calendar"
|
||||
className={calendarClassName}
|
||||
{...calendarHandler}
|
||||
showClear/>
|
||||
{...calendarHandler} />
|
||||
);
|
||||
|
||||
let sizeClass = '';
|
||||
|
Loading…
Reference in New Issue
Block a user