Skip to content

Commit ada2e63

Browse files
committed
move propTypes
1 parent 34d80fc commit ada2e63

File tree

1 file changed

+24
-25
lines changed

1 file changed

+24
-25
lines changed

src/Step.jsx

Lines changed: 24 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,30 @@ function isString(str) {
77
}
88

99
export default class Step extends React.Component {
10+
static propTypes = {
11+
className: PropTypes.string,
12+
prefixCls: PropTypes.string,
13+
style: PropTypes.object,
14+
wrapperStyle: PropTypes.object,
15+
itemWidth: PropTypes.oneOfType([
16+
PropTypes.number,
17+
PropTypes.string,
18+
]),
19+
status: PropTypes.string,
20+
iconPrefix: PropTypes.string,
21+
icon: PropTypes.node,
22+
adjustMarginRight: PropTypes.oneOfType([
23+
PropTypes.number,
24+
PropTypes.string,
25+
]),
26+
stepNumber: PropTypes.string,
27+
description: PropTypes.any,
28+
title: PropTypes.any,
29+
progressDot: PropTypes.oneOfType([
30+
PropTypes.bool,
31+
PropTypes.func,
32+
]),
33+
};
1034
renderIconNode() {
1135
const {
1236
prefixCls, progressDot, stepNumber, status, title, description, icon,
@@ -80,28 +104,3 @@ export default class Step extends React.Component {
80104
);
81105
}
82106
}
83-
84-
Step.propTypes = {
85-
className: PropTypes.string,
86-
prefixCls: PropTypes.string,
87-
style: PropTypes.object,
88-
wrapperStyle: PropTypes.object,
89-
itemWidth: PropTypes.oneOfType([
90-
PropTypes.number,
91-
PropTypes.string,
92-
]),
93-
status: PropTypes.string,
94-
iconPrefix: PropTypes.string,
95-
icon: PropTypes.node,
96-
adjustMarginRight: PropTypes.oneOfType([
97-
PropTypes.number,
98-
PropTypes.string,
99-
]),
100-
stepNumber: PropTypes.string,
101-
description: PropTypes.any,
102-
title: PropTypes.any,
103-
progressDot: PropTypes.oneOfType([
104-
PropTypes.bool,
105-
PropTypes.func,
106-
]),
107-
};

0 commit comments

Comments
 (0)