Skip to content

Commit

Permalink
Transfer notification
Browse files Browse the repository at this point in the history
  • Loading branch information
MIDAV0 committed Sep 5, 2023
1 parent c3e7d49 commit 8b85d1f
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/renderer/components/Wallet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ import { useAccount, useConnect, useDisconnect, useContractWrite, useWaitForTran
import { web3AuthInstance } from '../Web3AuthInstance';
import { getPublicCompressed } from "@toruslabs/eccrypto";
import { FLOCK_ABI, FLOCK_ADDRESS } from 'renderer/contracts/flock';
import { ToastContainer, toast } from 'react-toastify';
import 'react-toastify/dist/ReactToastify.css';

function Wallet() {
const { address } = useAccount();
Expand Down Expand Up @@ -95,6 +97,7 @@ function Wallet() {

useEffect(() => {
if (isSuccessTransfer) {
toast.success(`Transferred ${transferAmount} FLC successfully`);
setIsTransferLoading(false);
}
}, [isSuccessTransfer]);
Expand Down Expand Up @@ -177,6 +180,18 @@ function Wallet() {
/>
</Box>
</Box>
<ToastContainer
position="bottom-left"
autoClose={5000}
hideProgressBar={false}
newestOnTop
closeOnClick
rtl={false}
pauseOnFocusLoss
draggable
pauseOnHover
theme="light"
/>
</Layer>
);
}
Expand Down

0 comments on commit 8b85d1f

Please sign in to comment.