-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add CollectCondition to token gated pubs (#4309)
- Loading branch information
Showing
2 changed files
with
35 additions
and
0 deletions.
There are no files selected for viewing
31 changes: 31 additions & 0 deletions
31
apps/web/src/components/Publication/EncryptedPublication/Criteria/CollectCondition.tsx
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,31 @@ | ||
import type { FC } from 'react'; | ||
|
||
import { CollectCondition } from '@hey/lens'; | ||
import Link from 'next/link'; | ||
|
||
interface CollectConditionProps { | ||
condition: CollectCondition; | ||
} | ||
|
||
const CollectCondition: FC<CollectConditionProps> = ({ condition }) => { | ||
const { publicationId, thisPublication } = condition; | ||
|
||
return ( | ||
<div className="flex items-center space-x-2"> | ||
<div> | ||
{thisPublication | ||
? 'Must collect this publication' | ||
: 'Must collect the publication:'} | ||
</div> | ||
{!thisPublication ? ( | ||
<div className="linkify"> | ||
<Link className="underline" href={`/posts/${publicationId}`}> | ||
{publicationId} | ||
</Link> | ||
</div> | ||
) : null} | ||
</div> | ||
); | ||
}; | ||
|
||
export default CollectCondition; |
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
9131bec
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
web – ./
web-heyxyz.vercel.app
web-git-main-heyxyz.vercel.app
hey.xyz
heyxyz.vercel.app