Skip to content

Commit 1c26166

Browse files
authoredApr 12, 2022
fix(Breadcrumb/Progress/Radio): 修改部分组件导出方式 (#764)
1 parent d11d652 commit 1c26166

File tree

6 files changed

+9
-3
lines changed

6 files changed

+9
-3
lines changed
 

‎packages/react-breadcrumb/src/Breadcrumb.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,4 @@ type Breadcrumb = typeof Breadcrumb & {
2828
(Breadcrumb as Breadcrumb).Item = Item;
2929

3030
export default Breadcrumb as Breadcrumb;
31+
export { Breadcrumb };

‎packages/react-progress/src/Circle.tsx

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import './style/index.less';
66
import './style/circle.less';
77

88
export type Status = 'success' | 'active' | 'exception';
9+
910
export interface ProgressCircleProps<T> extends IProps, HTMLDivProps {
1011
type?: IconProps<T>['type'];
1112
status?: Status;
@@ -95,3 +96,4 @@ export default class Circle<T> extends React.Component<ProgressCircleProps<T>> {
9596
);
9697
}
9798
}
99+
export { Circle };

‎packages/react-progress/src/Line.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -56,3 +56,4 @@ export default class Line<T> extends React.Component<ProgressLineProp<T>> {
5656
);
5757
}
5858
}
59+
export { Line };

‎packages/react-radio/src/Radio.tsx

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import './style/index.less';
44

55
export interface RadioProps extends RadioAbstractProps {}
66

7-
export default React.forwardRef<HTMLInputElement, RadioProps>((props, ref) => {
7+
export const Radio = React.forwardRef<HTMLInputElement, RadioProps>((props, ref) => {
88
return <RadioAbstract ref={ref} {...props} />;
99
});
10+
export default Radio;

‎packages/react-radio/src/RadioButton.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export interface RadioButtonProps extends IProps, Omit<HTMLButtonProps, 'size'>
1313
onChange?: (even: any) => void;
1414
}
1515

16-
const RadioButton = React.forwardRef<any, RadioButtonProps>((props, ref) => {
16+
export const RadioButton = React.forwardRef<any, RadioButtonProps>((props, ref) => {
1717
const {
1818
prefixCls = 'w-radio',
1919
type = 'button',

‎packages/react-radio/src/RadioGroup.tsx

+2-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export interface RadioGroupProps extends IProps, HTMLDivProps {
1010
onChange?: RadioProps['onChange'];
1111
}
1212

13-
export default React.forwardRef<HTMLDivElement, RadioGroupProps>((props, ref) => {
13+
export const RadioGroup = React.forwardRef<HTMLDivElement, RadioGroupProps>((props, ref) => {
1414
const { prefixCls = 'w-radio-group', className, name, value, onChange, children, ...other } = props;
1515
return (
1616
<div {...other} ref={ref} className={[prefixCls, className].filter(Boolean).join(' ').trim()}>
@@ -31,3 +31,4 @@ export default React.forwardRef<HTMLDivElement, RadioGroupProps>((props, ref) =>
3131
</div>
3232
);
3333
});
34+
export default RadioGroup;

0 commit comments

Comments
 (0)
Please sign in to comment.