Skip to content

Commit d7b94c7

Browse files
committed
feat: add M.A.E.S.T.R.O. homepage event banner
1 parent 32e63e7 commit d7b94c7

File tree

4 files changed

+64
-0
lines changed

4 files changed

+64
-0
lines changed
3.07 MB
Loading
13.3 KB
Loading
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
import { faExclamationCircle } from '@fortawesome/free-solid-svg-icons';
2+
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
3+
import Image from 'next/image';
4+
import Link from 'next/link';
5+
6+
export const EventBanner = () => {
7+
return (
8+
<div className='flex flex-row mx-auto w-fit justify-between items-center text-pretty gap-6 py-4 px-2 sm:px-8 text-sm rounded-xl mb-10 bg-top backdrop-filter backdrop-blur-lg bg-opacity-50 bg-gradient-to-br from-15% from-pink-800 via-rose-900 to-85% to-red-900 relative'>
9+
<div
10+
className='absolute h-full w-full top-0 left-0 z-[-1] rounded-xl opacity-50 brightness-[0.3]'
11+
style={{
12+
backgroundImage: "url('/img/event/maestro-banner.png')",
13+
backgroundSize: 'contain',
14+
backgroundAttachment: 'fixed',
15+
}}
16+
></div>
17+
<Image src='/img/event/maestro-icon.png' alt='' width={64} height={64} />
18+
19+
<div className='flex-1 leading-tight max-w-screen-md w-fit'>
20+
<p className='uppercase text-sm font-bold tracking-wider text-yellow-300 mb-1 w-fit'>
21+
<FontAwesomeIcon icon={faExclamationCircle} /> ends in{' '}
22+
{Math.max(
23+
0,
24+
Math.ceil(
25+
(Date.UTC(2025, 9, 26, 22, 0, 0) - Date.now()) /
26+
(1000 * 60 * 60 * 24),
27+
),
28+
)}{' '}
29+
days
30+
</p>
31+
<p>
32+
<span className='font-bold'>An event is underway!</span> Submit a song
33+
to be played in the{' '}
34+
<Link
35+
href='https://www.youtube.com/watch?v=G78AnHpIw5w'
36+
className='text-blue-300 hover:text-blue-200'
37+
>
38+
M.A.E.S.T.R.O. machine
39+
</Link>{' '}
40+
in the{' '}
41+
<span className='font-bold'>
42+
Students&nbsp;of&nbsp;Maestro&nbsp;Jam
43+
</span>
44+
, hosted in collaboration with{' '}
45+
<Link href='https://www.youtube.com/@jazziiRed'>jazziiRed</Link>,{' '}
46+
<Link href='https://www.youtube.com/@mr_mooncatcher'>
47+
mooncatcher
48+
</Link>
49+
, <Link href='https://www.youtube.com/@vladde'>vladde</Link> and{' '}
50+
<Link href='https://www.youtube.com/@Xoliks97'>Xolixs</Link>! Read our{' '}
51+
<Link
52+
href='/blog/maestro'
53+
className='text-blue-300 hover:text-blue-200'
54+
>
55+
blog post
56+
</Link>{' '}
57+
to participate.
58+
</p>
59+
</div>
60+
</div>
61+
);
62+
};

web/src/modules/browse/components/HomePageComponent.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ import {
2323
CarouselPrevious,
2424
} from '../../shared/components/client/Carousel';
2525
import { WelcomeBanner } from '../WelcomeBanner';
26+
import { EventBanner } from '../EventBanner';
2627

2728
export const HomePageComponent = () => {
2829
const { featuredSongsPage } = useFeaturedSongsProvider();
@@ -33,6 +34,7 @@ export const HomePageComponent = () => {
3334
<>
3435
{/* Welcome banner/Hero */}
3536
<WelcomeBanner />
37+
<EventBanner />
3638

3739
{/* FEATURED SONGS */}
3840
{featuredSongsPage.length > 0 && (

0 commit comments

Comments
 (0)