From fcfc2bff40cd17cc73420d2747c082236a836674 Mon Sep 17 00:00:00 2001 From: Luc Date: Sat, 27 Jan 2024 21:38:05 +0000 Subject: [PATCH] Bump --- app/[slug]/page.tsx | 2 +- components/POAPModal/POAPModal.tsx | 1 + components/POAPModal/settings.tsx | 15 +++++++++++++++ components/POAPModal/stages/AlreadyClaimed.tsx | 6 +++++- components/POAPModal/stages/MintToProfile.tsx | 5 ++++- components/POAPModal/stages/NameInput.tsx | 3 +++ 6 files changed, 29 insertions(+), 3 deletions(-) diff --git a/app/[slug]/page.tsx b/app/[slug]/page.tsx index 58f84ff..413cfac 100644 --- a/app/[slug]/page.tsx +++ b/app/[slug]/page.tsx @@ -120,7 +120,7 @@ export async function generateMetadata({ }) { const raw_name = slug; const name = ens_normalize(raw_name.toLowerCase()); - const theme_color = theme2Color[event] || '#fff'; + const theme_color = theme2Color[event] || '#F6F6F6'; if (raw_name.toLowerCase() !== name) { throw new Error('Invalid ENS name'); diff --git a/components/POAPModal/POAPModal.tsx b/components/POAPModal/POAPModal.tsx index f674729..2be13d5 100644 --- a/components/POAPModal/POAPModal.tsx +++ b/components/POAPModal/POAPModal.tsx @@ -119,6 +119,7 @@ export const POAPModal: FC<{ event_name={event_name} address={mintToProfile} iykData={data} + event_slug={event} onCallChange={() => { setMintToProfile(''); // eslint-disable-next-line no-undef diff --git a/components/POAPModal/settings.tsx b/components/POAPModal/settings.tsx index 67c7a9e..36c8049 100644 --- a/components/POAPModal/settings.tsx +++ b/components/POAPModal/settings.tsx @@ -1 +1,16 @@ export const SHOW_POAP_ANYWAYS = false; + +export const getTextFromInfo = ( + profile: string, + event_slug: string, + event: string +) => { + if (['frensday2023', 'ethdenver2024'].includes(event_slug)) + return ( + + Mint a POAP to show you met {profile} at {event}! + + ); + + return Mint a POAP!; +}; diff --git a/components/POAPModal/stages/AlreadyClaimed.tsx b/components/POAPModal/stages/AlreadyClaimed.tsx index 3e322f8..cd49cf9 100644 --- a/components/POAPModal/stages/AlreadyClaimed.tsx +++ b/components/POAPModal/stages/AlreadyClaimed.tsx @@ -7,7 +7,11 @@ export const AlreadyClaimed: FC<{ to: string }> = ({ to }) => {

You should see it in your collection

diff --git a/components/POAPModal/stages/MintToProfile.tsx b/components/POAPModal/stages/MintToProfile.tsx index c04254b..e2524c6 100644 --- a/components/POAPModal/stages/MintToProfile.tsx +++ b/components/POAPModal/stages/MintToProfile.tsx @@ -5,6 +5,7 @@ import { FiCheck, FiLoader } from 'react-icons/fi'; import { mintPOAP } from '../../../hooks/mintPOAP'; import { IYKRefResponse as IYKReferenceResponse } from '../../../hooks/useIYKRef'; +import { getTextFromInfo } from '../settings'; const eth_address_regex = /^0x[\dA-Fa-f]{40}$/; @@ -12,6 +13,7 @@ export const MintToProfile: FC<{ address: string; poap_name: string; event_name: string; + event_slug: string; onCallChange: () => void; onCallClose: () => void; iykData: IYKReferenceResponse; @@ -19,6 +21,7 @@ export const MintToProfile: FC<{ }> = ({ address, poap_name, + event_slug, event_name, iykData, onCallChange, @@ -31,7 +34,7 @@ export const MintToProfile: FC<{ return (
- Mint a POAP to show you met {poap_name} at {event_name}! + {getTextFromInfo(poap_name, event_slug, event_name)}