fix input-rating allowClear bug (#2437)

This commit is contained in:
Allen 2021-08-26 11:42:44 +08:00 committed by GitHub
parent 0697a99062
commit e359017ed3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -18,6 +18,11 @@ export interface RatingControlSchema extends FormBaseControl {
*
*/
half?: boolean;
/**
*
*/
allowClear?: boolean;
}
export interface RatingProps extends FormControlProps {
@ -45,6 +50,7 @@ export default class RatingControl extends React.Component<RatingProps, any> {
disabled,
onChange,
size,
allowClear,
classnames: cx
} = this.props;
@ -56,6 +62,7 @@ export default class RatingControl extends React.Component<RatingProps, any> {
disabled={disabled}
count={count}
half={half}
allowClear={allowClear}
readOnly={readOnly}
onChange={(value: any) => onChange(value)}
/>