mirror of
https://github.com/massbug/judge4c.git
synced 2025-05-17 23:12:23 +00:00
refactor(loading): change to named export and arrow function
- Switch from default export to named export - Convert component to arrow function - Remove unused props parameter
This commit is contained in:
parent
7e45010487
commit
baf377b722
@ -6,14 +6,14 @@ interface LoadingProps {
|
|||||||
skeletonClassName?: string;
|
skeletonClassName?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export function Loading({
|
const Loading = ({ className, skeletonClassName }: LoadingProps) => {
|
||||||
className,
|
|
||||||
skeletonClassName,
|
|
||||||
...props
|
|
||||||
}: LoadingProps) {
|
|
||||||
return (
|
return (
|
||||||
<div className={cn("h-full w-full p-2 bg-background", className)} {...props}>
|
<div className={cn("h-full w-full p-2 bg-background", className)}>
|
||||||
<Skeleton className={cn("h-full w-full rounded-3xl", skeletonClassName)} />
|
<Skeleton
|
||||||
|
className={cn("h-full w-full rounded-3xl", skeletonClassName)}
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
};
|
||||||
|
|
||||||
|
export { Loading };
|
||||||
|
Loading…
Reference in New Issue
Block a user