chore: refactor LoadingIcon.tsx (#27765)

This commit is contained in:
wf-erikslokharts 2020-11-13 16:13:48 +00:00 committed by GitHub
parent d1d215e222
commit 478f611a16
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -16,7 +16,7 @@ const getRealWidth = (node: HTMLElement) => ({
transform: 'scale(1)',
});
export default function LoadingIcon({ prefixCls, loading, existIcon }: LoadingIconProps) {
const LoadingIcon: React.FC<LoadingIconProps> = ({ prefixCls, loading, existIcon }) => {
const visible = !!loading;
if (existIcon) {
@ -50,3 +50,5 @@ export default function LoadingIcon({ prefixCls, loading, existIcon }: LoadingIc
</CSSMotion>
);
}
export default LoadingIcon;