Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
f4dcdc0
fix: modify api.ts
Benjtalkshow Oct 14, 2025
b90d4ed
Merge branch 'main' of https://github.com/Benjtalkshow/boundless into…
Benjtalkshow Oct 16, 2025
9ea81a5
Merge branch 'main' of https://github.com/Benjtalkshow/boundless into…
Benjtalkshow Oct 16, 2025
5be269f
fix: remove google auth buttom
Benjtalkshow Oct 16, 2025
490dcb2
Merge branch 'main' of https://github.com/Benjtalkshow/boundless into…
Benjtalkshow Oct 20, 2025
842fd48
fix: fixes responsive fixes on organization
Benjtalkshow Oct 20, 2025
596a7f8
fix: minor fixes
Benjtalkshow Nov 6, 2025
96fee24
fix: minor fixes
Benjtalkshow Nov 6, 2025
9dfb149
fix: modify create organization
Benjtalkshow Nov 7, 2025
a194d90
fix: modify create organization
Benjtalkshow Nov 7, 2025
b2ceee0
fix: fix organization permission
Benjtalkshow Nov 8, 2025
9ea97d1
fix: merge into main
Benjtalkshow Nov 8, 2025
adb4629
Merge branch 'main' of https://github.com/Benjtalkshow/boundless into…
Benjtalkshow Nov 8, 2025
0c11420
fix: merge into main
Benjtalkshow Nov 8, 2025
1f5ec24
feat: hackathon overview page
Benjtalkshow Nov 11, 2025
bca1ef6
feat: hackathon overview page
Benjtalkshow Nov 11, 2025
9202b4f
feat: implement participant overview
Benjtalkshow Nov 12, 2025
096f265
feat: implement participant overview
Benjtalkshow Nov 12, 2025
b3478d0
feat: implement resources tab
Benjtalkshow Nov 12, 2025
e83a0be
feat: implement the submission tab
Benjtalkshow Nov 12, 2025
398be9b
feat: implement comment tab
Benjtalkshow Nov 12, 2025
de546b1
fix: implement provider for hackathon
Benjtalkshow Nov 14, 2025
0fd2690
fix: implement provider for hackathon
Benjtalkshow Nov 14, 2025
0d7417f
fix: minor fixes
Benjtalkshow Nov 15, 2025
4d3efee
fix: merge branch 'main' of https://github.com/Benjtalkshow/boundless…
Benjtalkshow Nov 15, 2025
83893e4
fix: hackathon banner
Benjtalkshow Nov 15, 2025
8013d62
fix: hackathon banner
Benjtalkshow Nov 15, 2025
3fb1323
fix: fix hackthon conflict
Benjtalkshow Nov 15, 2025
b7fc94f
Merge branch 'main' of https://github.com/Benjtalkshow/boundless into…
Benjtalkshow Nov 15, 2025
0594ac8
Merge branch 'main' of https://github.com/Benjtalkshow/boundless into…
Benjtalkshow Nov 15, 2025
7e08bc1
fix: fix organization page
Benjtalkshow Nov 15, 2025
22c12c1
fix: fix organization page
Benjtalkshow Nov 16, 2025
08e5be5
fix: fix organization page
Benjtalkshow Nov 16, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 12 additions & 5 deletions components/hackathons/hackathonBanner.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ import { Card } from '@/components/ui/card';
import { Badge } from '@/components/ui/badge';
import { formatDate } from '@/lib/utils';
import { useEffect, useState } from 'react';
import { sanitizeHtml } from '@/lib/utils/renderHtml';

interface HackathonBannerProps {
title: string;
subtitle?: string;
subtitle?: string | React.ReactNode;
imageUrl?: string;
deadline?: string;
startDate?: string;
Expand Down Expand Up @@ -244,11 +245,17 @@ export function HackathonBanner({
<h1 className='text-left text-3xl leading-tight font-bold text-white drop-shadow-lg md:text-4xl lg:text-5xl'>
{title}
</h1>
{subtitle && (
<p className='max-w-2xl text-left text-base text-gray-200 drop-shadow-md md:text-lg'>
{subtitle.slice(3)}
</p>
{subtitle && typeof subtitle === 'string' ? (
<div
className='max-w-2xl text-left text-base text-gray-200 drop-shadow-md md:text-lg'
dangerouslySetInnerHTML={sanitizeHtml(subtitle)}
/>
) : (
<div className='max-w-2xl text-left text-base text-gray-200 drop-shadow-md md:text-lg'>
{subtitle}
</div>
)}

{subtitle && (
<div className='h-1 w-20 rounded-full bg-[#a7f950] md:w-24' />
)}
Expand Down
2 changes: 1 addition & 1 deletion components/wallet/WalletButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ export const WalletButton = () => {
return (
<Button
onClick={handleConnect}
className='flex items-center gap-2 bg-blue-500 text-white hover:bg-blue-600 dark:bg-blue-600 dark:hover:bg-blue-700'
className='bg-primary hover:bg-primary/60 flex items-center gap-2 text-black dark:bg-blue-600 dark:hover:bg-blue-700'
>
<Wallet className='h-4 w-4' />
Connect Wallet
Expand Down
50 changes: 50 additions & 0 deletions lib/utils/renderHtml.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
import DOMPurify from 'dompurify';

export function sanitizeHtml(html: string | undefined | null) {
const dirty = html ?? '';

try {
const clean = DOMPurify.sanitize(dirty, {
ALLOWED_TAGS: [
'b',
'i',
'em',
'strong',
'a',
'p',
'ul',
'ol',
'li',
'br',
'span',
'div',
'h1',
'h2',
'h3',
'h4',
'h5',
'img',
'code',
'pre',
'blockquote',
'small',
'sup',
'sub',
],
ALLOWED_ATTR: [
'href',
'target',
'rel',
'class',
'id',
'title',
'alt',
'src',
],
});
return { __html: clean };
} catch (err) {
console.error(err);

Check warning on line 47 in lib/utils/renderHtml.ts

View workflow job for this annotation

GitHub Actions / Code Quality & Linting

Unexpected console statement
return { __html: dirty };
}
}
10 changes: 10 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@
"clsx": "^2.1.1",
"cmdk": "^1.1.1",
"date-fns": "^4.1.0",
"dompurify": "^3.3.0",
"embla-carousel-autoplay": "^8.6.0",
"embla-carousel-react": "^8.6.0",
"framer-motion": "^12.23.12",
Expand Down
Loading