improve site

master
lza_menace 2 years ago
parent 89dc272449
commit 27320f8627

@ -38,8 +38,8 @@ export function Hero(props) {
unaboomerPreviewAmount: 1, unaboomerPreviewAmount: 1,
bombPreviewAmount: 1, bombPreviewAmount: 1,
sendBombPreviewAmount: 1, sendBombPreviewAmount: 1,
unaboomerPrice: 0, unaboomerPrice: ethers.utils.parseEther('.05'),
bombPrice: ethers.utils.parseEther('.01'), bombPrice: ethers.utils.parseEther('.0025'),
unaboomersMinted: 0, unaboomersMinted: 0,
unaboomerBalance: 0, unaboomerBalance: 0,
bombBalance: 0, bombBalance: 0,
@ -280,23 +280,17 @@ export function Hero(props) {
You have minted {options.unaboomersMinted} Unaboomers. You have minted {options.unaboomersMinted} Unaboomers.
</p> </p>
)} )}
{options.unaboomersMinted < options.unaboomerMaxMintPerWallet <input type='number' step='1' defaultValue={1} min={1} max={options.unaboomerMaxMintPerWallet - options.unaboomersMinted} onChange={(v) => {
&& options.unaboomersKilled + options.unaboomersRadicalized < options.unaboomerMaxSupply throttleStateChange({unaboomerAmount: v.target.value});
&& ( radicalizeBoomersWrite.reset()
<> }}></input>
<input type='number' step='1' defaultValue={1} min={1} max={options.unaboomerMaxMintPerWallet - options.unaboomersMinted} onChange={(v) => { <button className='doThing' disabled={radicalizeBoomersPrepare.status == 'error' || !isConnected} onClick={() => radicalizeBoomersWrite.write?.()}>
throttleStateChange({unaboomerAmount: v.target.value}); {radicalizeBoomersWrite.isLoading && <>minting {options.unaboomerAmount}</>}
radicalizeBoomersWrite.reset() {radicalizeBoomersWrite.isIdle && <>Radicalize {options.unaboomerAmount == 1 ? 'a Boomer': <>{options.unaboomerAmount} Boomers</>}</>}
}}></input> {radicalizeBoomersWrite.isSuccess && <img src={Loading} width="25px"></img>}
<button className='doThing' disabled={radicalizeBoomersPrepare.status == 'error'} onClick={() => radicalizeBoomersWrite.write?.()}> {radicalizeBoomersWrite.isError && <>error</>}
{radicalizeBoomersWrite.isLoading && <>minting {options.unaboomerAmount}</>} </button>
{radicalizeBoomersWrite.isIdle && <>Radicalize {options.unaboomerAmount == 1 ? 'a Boomer': <>{options.unaboomerAmount} Boomers</>}</>} <p>({ethers.utils.formatEther((options.unaboomerPrice * options.unaboomerAmount).toString())} ETH)</p>
{radicalizeBoomersWrite.isSuccess && <img src={Loading} width="25px"></img>}
{radicalizeBoomersWrite.isError && <>error</>}
</button>
<p>({ethers.utils.formatEther((options.unaboomerPrice * options.unaboomerAmount).toString())} ETH)</p>
</>
)}
</div> </div>
<div className='heroFlexArrow'> <div className='heroFlexArrow'>
<img src={Arrow} width='100px' alt='Arrow pointing to the next step.' /> <img src={Arrow} width='100px' alt='Arrow pointing to the next step.' />
@ -304,7 +298,7 @@ export function Hero(props) {
<div className='heroFlexItem'> <div className='heroFlexItem'>
<img src={Mailbomb} width='280px' alt='Pixelated mail bomb image - handle with caution.' /> <img src={Mailbomb} width='280px' alt='Pixelated mail bomb image - handle with caution.' />
<p> <p>
Don't let the Boomers win! Assemble mail bombs and blow 'em to smithereens. <br /><br /> Don't let the Boomers win! Assemble mail bombs and blow 'em to smithereens. All minted Unaboomers will be airdropped a mail bomb.<br /><br />
(Warning: Some bombs are duds!) (Warning: Some bombs are duds!)
</p> </p>
{options.bombBalance > 0 && ( {options.bombBalance > 0 && (
@ -313,22 +307,17 @@ export function Hero(props) {
You have {options.bombBalance} Mail bombs. You have {options.bombBalance} Mail bombs.
</p> </p>
)} )}
{options.unaboomersKilled < options.unaboomerMaxSupply - options.unaboomerMaxSurvivorCount <input type='number' step='1' defaultValue={1} min={1} onChange={(v) => {
&& ( throttleStateChange({bombAmount: v.target.value});
<> assembleBombsWrite.reset()
<input type='number' step='1' defaultValue={1} min={1} onChange={(v) => { }}></input>
throttleStateChange({bombAmount: v.target.value}); <button className='doThing' disabled={assembleBombsPrepare.status == 'error' || !isConnected} onClick={() => assembleBombsWrite.write?.()}>
assembleBombsWrite.reset() {assembleBombsWrite.isLoading && <>assembling {options.bombAmount}</>}
}}></input> {assembleBombsWrite.isIdle && <>Assemble {options.bombAmount == 1 ? 'a mail bomb': <>{options.bombAmount} Mail bombs</>}</>}
<button className='doThing' disabled={assembleBombsPrepare.status == 'error'} onClick={() => assembleBombsWrite.write?.()}> {assembleBombsWrite.isSuccess && <img src={Loading} width="25px"></img>}
{assembleBombsWrite.isLoading && <>assembling {options.bombAmount}</>} {assembleBombsWrite.isError && <>error</>}
{assembleBombsWrite.isIdle && <>Assemble {options.bombAmount == 1 ? 'a mail bomb': <>{options.bombAmount} Mail bombs</>}</>} </button>
{assembleBombsWrite.isSuccess && <img src={Loading} width="25px"></img>} <p>({ethers.utils.formatEther((options.bombPrice * options.bombAmount).toString())} ETH)</p>
{assembleBombsWrite.isError && <>error</>}
</button>
<p>({ethers.utils.formatEther((options.bombPrice * options.bombAmount).toString())} ETH)</p>
</>
)}
</div> </div>
<div className='heroFlexArrow'> <div className='heroFlexArrow'>
<img src={Arrow} width='100px' alt='Arrow pointing to the next step.' /> <img src={Arrow} width='100px' alt='Arrow pointing to the next step.' />
@ -339,23 +328,17 @@ export function Hero(props) {
Ready for mayhem? Mail a bomb to blow up a random BOOMER. <br /><br /> Ready for mayhem? Mail a bomb to blow up a random BOOMER. <br /><br />
(Warning: Your Boomer might explode!) (Warning: Your Boomer might explode!)
</p> </p>
{options.unaboomersKilled < options.unaboomerMaxSupply - options.unaboomerMaxSurvivorCount <input type='number' step='1' defaultValue={1} min={1} max={options.bombBalance} onChange={(v) => {
&& options.bombBalance > 0 throttleStateChange({sendBombAmount: v.target.value});
&& ( sendBombsWrite.reset()
<> }}></input>
<input type='number' step='1' defaultValue={1} min={1} max={options.bombBalance} onChange={(v) => { <button className='doThing' disabled={sendBombsPrepare.status == 'error' || !isConnected} onClick={() => sendBombsWrite.write?.()}>
throttleStateChange({sendBombAmount: v.target.value}); {sendBombsWrite.isLoading && <>mailing {options.sendBombAmount}</>}
sendBombsWrite.reset() {sendBombsWrite.isIdle && <>Mail {options.sendBombAmount == 1 ? 'a bomb': <>{options.sendBombAmount} Mail bombs</>}</>}
}}></input> {sendBombsWrite.isSuccess && <img src={Loading} width="25px"></img>}
<button className='doThing' disabled={sendBombsPrepare.status == 'error'} onClick={() => sendBombsWrite.write?.()}> {sendBombsWrite.isError && <>error</>}
{sendBombsWrite.isLoading && <>mailing {options.sendBombAmount}</>} </button>
{sendBombsWrite.isIdle && <>Mail {options.sendBombAmount == 1 ? 'a bomb': <>{options.sendBombAmount} Mail bombs</>}</>} <p>(tx fee)</p>
{sendBombsWrite.isSuccess && <img src={Loading} width="25px"></img>}
{sendBombsWrite.isError && <>error</>}
</button>
<p>(tx fee)</p>
</>
)}
</div> </div>
</div> </div>

Loading…
Cancel
Save