Skip to content

Commit 3f04fbb

Browse files
authored
minor fixes (#475)
* fix: delete /dashboard * fix: implement extend deadline and remove dummy /dashboard
1 parent 560a0cb commit 3f04fbb

10 files changed

Lines changed: 19 additions & 233 deletions

File tree

app/(landing)/hackathons/[slug]/HackathonPageClient.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -403,6 +403,7 @@ export default function HackathonPageClient() {
403403
// Shared props for banner and sticky card
404404
const sharedActionProps = {
405405
deadline: currentHackathon.submissionDeadline,
406+
submissionDeadlineExtendedAt: currentHackathon.submissionDeadlineExtendedAt,
406407
startDate: currentHackathon.startDate,
407408
totalPrizePool: currentHackathon.prizeTiers
408409
.reduce((acc, prize) => acc + Number(prize.prizeAmount || 0), 0)

app/(landing)/hackathons/[slug]/hackathon-detail-design.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ https://www.figma.com/design/EMNGAQl1SGObXcsoa24krt/Boundless_Project-Details?no
77
This design proposes a cleaner and more professional UI/UX for the hackathon detail page.
88

99
Included in the Figma file:
10+
1011
- Desktop layout
1112
- Mobile layout
1213
- Banner / hero placement proposal
@@ -23,6 +24,7 @@ The hackathon banner is placed as a full-width hero image at the top of the page
2324
The sidebar becomes a compact summary card with key information and actions.
2425

2526
Design Goals
27+
2628
- Simpler UI and improved visual hierarchy
2729
- Clear primary actions (Join, Submit, View Submission)
2830
- Consistent spacing and typography

app/dashboard/page copy.tsx

Lines changed: 0 additions & 225 deletions
This file was deleted.

app/dashboard/page.tsx

Lines changed: 0 additions & 6 deletions
This file was deleted.

components/dashboard-content.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { SectionCards } from '@/components/section-cards';
77
import { SiteHeader } from '@/components/site-header';
88
import { SidebarInset, SidebarProvider } from '@/components/ui/sidebar';
99
import { useAuthStatus } from '@/hooks/use-auth';
10-
import data from '../app/dashboard/data.json';
10+
import data from '../data/data.json';
1111
import React, { useState } from 'react';
1212
import { FamilyWalletButton } from '@/components/wallet/FamilyWalletButton';
1313
import {

components/hackathons/hackathonBanner.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ interface HackathonBannerProps {
3030
onLeaveClick?: () => void;
3131
isLeaving?: boolean;
3232
participantType?: 'INDIVIDUAL' | 'TEAM' | 'TEAM_OR_INDIVIDUAL';
33+
submissionDeadlineExtendedAt?: string | null;
3334
}
3435

3536
export function HackathonBanner({
@@ -46,6 +47,7 @@ export function HackathonBanner({
4647
registrationDeadline,
4748
isLeaving,
4849
participantType,
50+
submissionDeadlineExtendedAt,
4951
onJoinClick,
5052
onSubmitClick,
5153
onViewSubmissionClick,
@@ -252,6 +254,11 @@ export function HackathonBanner({
252254
<span className='text-xs tracking-wide text-gray-400 uppercase'>
253255
{status === 'ongoing' ? 'Ends In' : 'Starts In'}
254256
</span>
257+
{status === 'ongoing' && submissionDeadlineExtendedAt && (
258+
<span className='ml-1.5 rounded-full bg-[#a7f950]/20 px-1.5 py-0.5 text-[10px] font-bold text-[#a7f950] uppercase'>
259+
Extended
260+
</span>
261+
)}
255262
</div>
256263
<CountdownTimer
257264
targetDate={status === 'ongoing' ? deadline : startDate}

components/hackathons/hackathonStickyCard.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ interface HackathonStickyCardProps {
3434
onFindTeamClick?: () => void;
3535
onLeaveClick?: () => void;
3636
participantType?: 'INDIVIDUAL' | 'TEAM' | 'TEAM_OR_INDIVIDUAL';
37+
submissionDeadlineExtendedAt?: string | null;
3738
}
3839

3940
export function HackathonStickyCard(props: HackathonStickyCardProps) {
@@ -54,6 +55,7 @@ export function HackathonStickyCard(props: HackathonStickyCardProps) {
5455
onLeaveClick,
5556
isLeaving,
5657
participantType,
58+
submissionDeadlineExtendedAt,
5759
} = props;
5860

5961
const { status } = useHackathonStatus(startDate, deadline);
@@ -162,6 +164,11 @@ export function HackathonStickyCard(props: HackathonStickyCardProps) {
162164
<span className='text-xs text-gray-400'>Deadline</span>
163165
<span className='text-xs text-white'>
164166
{formatDateWithFallback(deadline)}
167+
{submissionDeadlineExtendedAt && (
168+
<span className='ml-1.5 rounded-full bg-[#a7f950]/20 px-1.5 py-0.5 text-[10px] font-bold text-[#a7f950] uppercase'>
169+
Extended
170+
</span>
171+
)}
165172
</span>
166173
</div>
167174
)}
File renamed without changes.

lib/api/hackathon.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ export const getHackathon = async (
5555
slug: string
5656
): Promise<GetHackathonResponse> => {
5757
const res = await api.get(`/hackathons/s/${slug}`);
58-
5958
return res.data as GetHackathonResponse;
6059
};
6160

lib/api/hackathons.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,7 @@ export type Hackathon = {
347347

348348
startDate: string; // ISO date
349349
submissionDeadline: string; // ISO date
350+
submissionDeadlineExtendedAt?: string | null;
350351
registrationDeadline: string; // ISO date
351352
judgingDeadline?: string; // ISO date
352353

0 commit comments

Comments
 (0)