Skip to content

Commit

Permalink
chore: updated readme
Browse files Browse the repository at this point in the history
  • Loading branch information
trbutler4 committed Sep 6, 2023
1 parent df4bcb7 commit 0faa5cb
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 5 deletions.
2 changes: 1 addition & 1 deletion app/(general)/integration/unlock/[lockId]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import LockStats from '@/integrations/unlock/components/lock-stats'

export default function UnlockLockPage({ params }: { params: { lockId: string } }) {
return (
<div className="flex flex-col items-center justify-center">
<div className="flex flex-col items-center justify-center space-y-4">
<h1 className="text-4xl font-bold">Lock Stats</h1>
<LockStats lockId={params.lockId} />
<ButtonKeyCheckout lockId={params.lockId} />
Expand Down
14 changes: 11 additions & 3 deletions integrations/unlock/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,17 @@ The also includes an example of using a lock as a paywall, and will require the
- Paywall example with an already deployed example lock
- View lock statistics, and purchase keys from created locks.

## Abis
`publicLicV13Abi` and `unlockV12Abi` are abis for the unlock protocol contracts for
generating typesafe wagmi hooks

## Components

`ButtonKeyCheckout()`
Opens the checkout modal for a specified key.

'FromDeployLock()'
For to create and deploy new locks.
For creating and deploying new locks.

'KeyPreview()'
Simply a preview card for the user keys list.
Expand All @@ -38,10 +42,14 @@ Displays all keys owned by the user for the connected chain.
`UserLocks()`
Displays all locks owned by the user for the connected chain.

## Generated
Contains typesafe hooks generated by wagmi cli for unlock protocol contracts

## Hooks

`UseDeployLock()`
React hook to interact with unlock protocol smart contracts.
`UseUnlockSupportedNetworks()`
React hook to return is network is supported by unlock, and some unlock data for
that network

`UseUnlockSubgraph()`
React hook to interact with The Graph protocol, and query information
Expand Down
2 changes: 1 addition & 1 deletion integrations/unlock/components/button-key-checkout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,5 @@ export default function ButtonKeyCheckout({ lockId }: { lockId: string }) {
}
}

return <div>{<Button onClick={handleCheckout}>Checkout</Button>}</div>
return <div>{<Button onClick={handleCheckout}>Purchase Lock</Button>}</div>
}

0 comments on commit 0faa5cb

Please sign in to comment.