generated from public-assembly/assemble-package
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adds changelog, adds settle auction component
- Loading branch information
1 parent
904e001
commit f0f15c3
Showing
8 changed files
with
36 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@public-assembly/builder-utils': patch | ||
--- | ||
|
||
Reintroduces wagmi and alongside it, two write hooks, useCreateBid and useSettle. useTokenExplorer now expects a token id object as an argument. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
export default function Loading() { | ||
return <>Loading...</> | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { useSettle, useAuctionState } from '@public-assembly/builder-utils' | ||
import { useRouter } from 'next/navigation' | ||
import { useEffect } from 'react' | ||
|
||
export function SettleAuction() { | ||
const { settle, settleLoading, settleSuccess } = useSettle() | ||
const { auctionState } = useAuctionState() | ||
const router = useRouter() | ||
|
||
useEffect(() => { | ||
if (settleSuccess) { | ||
router.push(`/${auctionState.tokenId + 1}`) | ||
} | ||
}, [settleSuccess]) | ||
|
||
return ( | ||
<button disabled={settleLoading} onClick={() => settle?.()}> | ||
Settle auction | ||
</button> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters