using button loading props vs Loader component (#1677)

pull/1676/head
Peer Richelsen 2022-02-01 21:52:54 +00:00 committed by GitHub
parent 1d10874890
commit aa28cf0641
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 4 deletions

View File

@ -610,12 +610,9 @@ function Web3ConnectBtn() {
utils.invalidateQueries("viewer.web3Integration");
};
if (mutation.isLoading) {
return <Loader />;
}
return (
<Button
loading={mutation.isLoading}
color={connectionBtn ? "warn" : "secondary"}
disabled={result.isLoading || mutation.isLoading}
onClick={async () => await enableOrDisableWeb3(mutation)}