mirror of
https://github.com/ant-design/ant-design.git
synced 2025-08-16 05:58:26 +02:00
fix: successPercent should decide the progress status when it exists, close #9382
This commit is contained in:
parent
fe4d294c64
commit
e361df0774
1 changed files with 2 additions and 2 deletions
|
@ -60,8 +60,8 @@ export default class Progress extends React.Component<ProgressProps, {}> {
|
|||
prefixCls, className, percent = 0, status, format, trailColor, size, successPercent,
|
||||
type, strokeWidth, width, showInfo, gapDegree = 0, gapPosition, ...restProps,
|
||||
} = props;
|
||||
const progressStatus = parseInt(percent.toString(), 10) >= 100 && !('status' in props) ?
|
||||
'success' : (status || 'normal');
|
||||
const progressStatus = parseInt((successPercent ? successPercent.toString() : percent.toString()), 10) >= 100 &&
|
||||
!('status' in props) ? 'success' : (status || 'normal');
|
||||
let progressInfo;
|
||||
let progress;
|
||||
const textFormatter = format || (percentNumber => `${percentNumber}%`);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue