From 6603fa9124542f2e23db7baaa1377980b81cfd67 Mon Sep 17 00:00:00 2001 From: Nitansh Shankar <167768158+BIJJUDAMA@users.noreply.github.com> Date: Fri, 15 May 2026 22:33:23 +0530 Subject: [PATCH 1/3] fix: implement dynamic scaling of hero section text --- src/components/landing/Header.tsx | 6 +-- src/components/shared/GlitchText.tsx | 78 ++++++++++------------------ 2 files changed, 30 insertions(+), 54 deletions(-) diff --git a/src/components/landing/Header.tsx b/src/components/landing/Header.tsx index 02f6740..98f2946 100644 --- a/src/components/landing/Header.tsx +++ b/src/components/landing/Header.tsx @@ -319,8 +319,8 @@ const LandingHeader = () => {
{/* Content Box with Border */} - -

+ +

{

-
+
+ - {/* Invisible spacer to reserve layout space */} - - - {/* Overlay for the actual effect */} - - {!typingComplete ? ( - - {displayText} - | - - ) : ( - - {text} - - )} - + {!typingComplete ? ( + + {displayText} + | + + ) : ( + + {text} + + )} {/* Strikethrough Lines */} {strikethrough && ( From 35b0fbc2998f162188d0bed075f7f5db8e85b96d Mon Sep 17 00:00:00 2001 From: abx Date: Fri, 12 Jun 2026 12:24:29 +0530 Subject: [PATCH 2/3] add: pop-up for quals date --- app/page.tsx | 14 ++ .../landing/RegistrationEndingPopup.tsx | 165 ++++++++++++++++++ 2 files changed, 179 insertions(+) create mode 100644 src/components/landing/RegistrationEndingPopup.tsx diff --git a/app/page.tsx b/app/page.tsx index 3788d8c..a2d6d85 100644 --- a/app/page.tsx +++ b/app/page.tsx @@ -15,7 +15,15 @@ import OperationTimeline from '../src/components/landing/OperationTimeline'; import Footer from '../src/components/shared/Footer'; import FloatingContactButton from '@/src/components/landing/FloatingContactForm'; import LandingChampionshipWorks from '../src/components/landing/HowItWorks'; +import RegistrationEndingPopup from '../src/components/landing/RegistrationEndingPopup'; export default function LandingPage() { + const [showRegPopup, setShowRegPopup] = useState(false); + + useEffect(() => { + const timer = setTimeout(() => setShowRegPopup(true), 3000); + return () => clearTimeout(timer); + }, []); + return (
{/* Blurred Satellite Background */} @@ -72,6 +80,12 @@ export default function LandingPage() { {/* Floating Contact Button */} + + {/* Registration Ending Popup */} + setShowRegPopup(false)} + />
); } \ No newline at end of file diff --git a/src/components/landing/RegistrationEndingPopup.tsx b/src/components/landing/RegistrationEndingPopup.tsx new file mode 100644 index 0000000..b5f8aa3 --- /dev/null +++ b/src/components/landing/RegistrationEndingPopup.tsx @@ -0,0 +1,165 @@ +import React, { useEffect, useRef, useState } from 'react'; +import { createPortal } from 'react-dom'; +import gsap from 'gsap'; +import { X } from 'lucide-react'; + +interface RegistrationEndingPopupProps { + isOpen: boolean; + onClose: () => void; +} + +const RegistrationEndingPopup: React.FC = ({ isOpen, onClose }) => { + const overlayRef = useRef(null); + const modalRef = useRef(null); + const progressBarRef = useRef(null); + const [mounted, setMounted] = useState(false); + + useEffect(() => { + setMounted(true); + }, []); + + useEffect(() => { + if (isOpen && mounted) { + const tl = gsap.timeline(); + + tl.to(overlayRef.current, { + opacity: 1, + duration: 0.4, + ease: 'power2.out', + }); + + tl.fromTo(modalRef.current, + { scaleY: 0, scaleX: 0.05, opacity: 0 }, + { scaleY: 1, opacity: 1, duration: 0.3, ease: 'power2.inOut' } + ) + .to(modalRef.current, { + scaleX: 1, + duration: 0.3, + ease: 'back.out(1.2)' + }); + + if (progressBarRef.current) { + gsap.fromTo(progressBarRef.current, + { width: '100%' }, + { width: '0%', duration: 25, ease: 'none', delay: 0.6 } + ); + } + + const timer = setTimeout(() => { + handleClose(); + }, 25600); + + return () => { + clearTimeout(timer); + tl.kill(); + }; + } + }, [isOpen, mounted]); + + const handleClose = () => { + const tl = gsap.timeline({ onComplete: onClose }); + tl.to(modalRef.current, { scale: 0.85, opacity: 0, y: 30, duration: 0.3, ease: 'power2.in' }) + .to(overlayRef.current, { opacity: 0, duration: 0.3 }, '<'); + }; + + if (!isOpen || !mounted) return null; + + return createPortal( +
+
+ +
+
+
+ {/* Timer bar */} +
+
+
+ + {/* Close button */} + + + {/* Content */} +
+

+ Registration Ends Soon! +

+ +

+ Last chance to join the CTF challenge. +

+ +
+ πŸ“… + Qualifiers: 20th–21st June +
+ + + Sign Up Now πŸš€ + +
+ + {/* Corner brackets */} +
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
, + document.body + ); +}; + +export default RegistrationEndingPopup; From 75bc992ec46b2c6e1d5db03555e8feb8ec78605a Mon Sep 17 00:00:00 2001 From: abx Date: Fri, 12 Jun 2026 20:00:01 +0530 Subject: [PATCH 3/3] sentence change --- src/components/landing/RegistrationEndingPopup.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/landing/RegistrationEndingPopup.tsx b/src/components/landing/RegistrationEndingPopup.tsx index b5f8aa3..05cf232 100644 --- a/src/components/landing/RegistrationEndingPopup.tsx +++ b/src/components/landing/RegistrationEndingPopup.tsx @@ -117,7 +117,7 @@ const RegistrationEndingPopup: React.FC = ({ isOpe

- Last chance to join the CTF challenge. + Last chance to secure your spot and compete in the CTF.