master
lza_menace 2 years ago
parent 04b7ff7749
commit 35c36ccde2

@ -350,7 +350,7 @@ function Section3(props) {
abi: MainABI, abi: MainABI,
enabled: isConnected && options.bombBalance > 0, enabled: isConnected && options.bombBalance > 0,
functionName: 'sendBombs', functionName: 'sendBombs',
cacheTime: 1000, cacheTime: 200,
args: [options.sendBombAmount] args: [options.sendBombAmount]
}); });
const sendBombsWrite = useContractWrite({ const sendBombsWrite = useContractWrite({
@ -453,13 +453,7 @@ function Section3(props) {
{options.unaboomersMinted < options.unaboomerMaxMintPerWallet && options.unaboomersKilled + options.unaboomersRadicalized < options.unaboomerMaxSupply && ( {options.unaboomersMinted < options.unaboomerMaxMintPerWallet && options.unaboomersKilled + options.unaboomersRadicalized < options.unaboomerMaxSupply && (
<> <>
<p> <p>
<AwesomeButton type="secondary" ripple={true} disabled={radicalizeBoomersPrepare.status == 'error'} onPress={() => { <AwesomeButton type="secondary" ripple={true} disabled={radicalizeBoomersPrepare.status == 'error'} onPress={() => radicalizeBoomersWrite.write?.()}>
radicalizeBoomersWrite.write?.();
handleStateChange({
unaboomerAmount: 1,
unaboomerPreviewAmount: 1
})
}}>
{radicalizeBoomersWrite.isLoading && <>minting {options.unaboomerAmount}</>} {radicalizeBoomersWrite.isLoading && <>minting {options.unaboomerAmount}</>}
{radicalizeBoomersWrite.isIdle && <>mint {options.unaboomerPreviewAmount} ({ethers.utils.formatEther((options.unaboomerPrice * options.unaboomerPreviewAmount).toString())} Ξ)</>} {radicalizeBoomersWrite.isIdle && <>mint {options.unaboomerPreviewAmount} ({ethers.utils.formatEther((options.unaboomerPrice * options.unaboomerPreviewAmount).toString())} Ξ)</>}
{radicalizeBoomersWrite.isSuccess && <>sent</>} {radicalizeBoomersWrite.isSuccess && <>sent</>}
@ -502,13 +496,7 @@ function Section3(props) {
<img src={Explosion} alt="" width="120px" /> <img src={Explosion} alt="" width="120px" />
{options.bombBalance > 0 && (<> {options.bombBalance > 0 && (<>
<p> <p>
<AwesomeButton type="secondary" ripple={true} disabled={sendBombsPrepare.status == 'error'} onPress={() => { <AwesomeButton type="secondary" ripple={true} disabled={sendBombsPrepare.status == 'error'} onPress={() => sendBombsWrite.write?.()}>
sendBombsWrite.write?.();
handleStateChange({
sendBombAmount: 1,
sendBombPreviewAmount: 1
});
}}>
{sendBombsWrite.isLoading && <>sending {options.sendBombAmount}</>} {sendBombsWrite.isLoading && <>sending {options.sendBombAmount}</>}
{sendBombsWrite.isIdle && <>send {options.sendBombPreviewAmount} (~0 Ξ)</>} {sendBombsWrite.isIdle && <>send {options.sendBombPreviewAmount} (~0 Ξ)</>}
{sendBombsWrite.isSuccess && <>sent</>} {sendBombsWrite.isSuccess && <>sent</>}

Loading…
Cancel
Save