Skip to content

Commit

Permalink
remove countdown (#223)
Browse files Browse the repository at this point in the history
  • Loading branch information
wraeth-eth authored Nov 20, 2023
1 parent 5921d63 commit 4b88bab
Showing 1 changed file with 1 addition and 23 deletions.
24 changes: 1 addition & 23 deletions src/components/Landing/components/JuicecrowdCTA.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,24 +17,6 @@ export type JuicecrowdCTAProps = {

export const JuicecrowdCTA: React.FC<JuicecrowdCTAProps> = ({ className }) => {
const submissionsAreLocked = JC01SubmissionsClosed()
const [countdownString, setCountdownString] = useState<string | undefined>(
undefined,
)

useEffect(() => {
if (!submissionsAreLocked) return

const getAndSetCountdownString = () => {
const countdown = dateToCountdownString(
new Date(JC01_DATES.PROJECTS_LAUNCH),
)
setCountdownString(countdown)
}

getAndSetCountdownString()

const interval = setInterval(getAndSetCountdownString, 1000)
}, [submissionsAreLocked])

return (
<div
Expand Down Expand Up @@ -101,12 +83,8 @@ export const JuicecrowdCTA: React.FC<JuicecrowdCTAProps> = ({ className }) => {
className="w-full min-w-[200px] gap-2 whitespace-nowrap bg-gray-800 opacity-100 disabled:bg-gray-800 disabled:opacity-100"
disabled
>
<span>🚀</span>
{countdownString ? countdownString : null}
<span>🚀 Launching soon</span>
</Button>
<div className="whitespace-nowrap text-center text-xs text-gray-400">
Until launch
</div>
</>
)}
</div>
Expand Down

1 comment on commit 4b88bab

@vercel
Copy link

@vercel vercel bot commented on 4b88bab Nov 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.