diff --git a/src/components/DatePicker.tsx b/src/components/DatePicker.tsx index ac3b1f863..d273b94f4 100644 --- a/src/components/DatePicker.tsx +++ b/src/components/DatePicker.tsx @@ -755,7 +755,7 @@ export class DatePicker extends React.Component { {placeholder} )} - {clearable && value ? ( + {clearable && !disabled && value ? ( {closeIcon} diff --git a/src/components/DateRangePicker.tsx b/src/components/DateRangePicker.tsx index bad8a31a7..7f8ad9641 100644 --- a/src/components/DateRangePicker.tsx +++ b/src/components/DateRangePicker.tsx @@ -438,7 +438,7 @@ export class DateRangePicker extends React.Component{placeholder} )} - {clearable && value ? ( + {clearable && !disabled && value ? ( {closeIcon} diff --git a/src/renderers/Form/Range.tsx b/src/renderers/Form/Range.tsx index 539187e74..75cc13e83 100644 --- a/src/renderers/Form/Range.tsx +++ b/src/renderers/Form/Range.tsx @@ -368,7 +368,7 @@ export default class RangeControl extends React.PureComponent this.clearValue()} className={cx("InputRange-clear", { 'is-active': (multiple ? isEqual(this.state.value, {min: min, max: max}) : this.state.value !== min) })}>{closeIcon} diff --git a/src/renderers/Form/Tag.tsx b/src/renderers/Form/Tag.tsx index a27c2964a..f21da0435 100644 --- a/src/renderers/Form/Tag.tsx +++ b/src/renderers/Form/Tag.tsx @@ -266,7 +266,7 @@ export default class TagControl extends React.PureComponent /> - {clearable && value ? ({closeIcon}) : null} + {clearable && !disabled && value ? ({closeIcon}) : null} {loading ? : null} diff --git a/src/renderers/Form/Text.tsx b/src/renderers/Form/Text.tsx index 7c763c312..2d706deed 100644 --- a/src/renderers/Form/Text.tsx +++ b/src/renderers/Form/Text.tsx @@ -434,7 +434,7 @@ export default class TextControl extends React.PureComponent - {clearable && value ? ({closeIcon}) : null} + {clearable && !disabled && value ? ({closeIcon}) : null} {loading ? : null} {isOpen && filtedOptions.length ? (
@@ -498,7 +498,7 @@ export default class TextControl extends React.PureComponent - {clearable && value ? ({closeIcon}) : null} + {clearable && !disabled && value ? ({closeIcon}) : null}
); }