fixed unnecessary code at Button
This commit is contained in:
parent
9e6f3a064d
commit
42d22ae86e
1 changed files with 2 additions and 4 deletions
|
|
@ -80,10 +80,8 @@ const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
|
|||
{...props}
|
||||
>
|
||||
{loading ? (
|
||||
<span className={cn("relative")}>
|
||||
<span className={loading ? "invisible" : "hidden"}>
|
||||
{newChildren}
|
||||
</span>
|
||||
<span className="relative">
|
||||
<span className="hidden">{newChildren}</span>
|
||||
<span className="absolute inset-0 flex items-center justify-center">
|
||||
<ForwardedIconComponent
|
||||
name={"Loader2"}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue