From df42bd602945053ca8c4e07092c1241622893ff6 Mon Sep 17 00:00:00 2001 From: Varad Jagtap Date: Sat, 17 Oct 2026 13:35:39 +0530 Subject: [PATCH 1/6] Some UI changes --- frontend/index.html | 10 +++--- frontend/public/assets/images/laptop.png | Bin 0 -> 306614 bytes frontend/public/wlug-logo.png | Bin 0 -> 81287 bytes frontend/src/styles/sections/curriculum.css | 34 ++++++++++++++------ frontend/src/styles/sections/schedule.css | 4 +-- 5 files changed, 32 insertions(+), 16 deletions(-) create mode 100644 frontend/public/assets/images/laptop.png create mode 100644 frontend/public/wlug-logo.png diff --git a/frontend/index.html b/frontend/index.html index 214381c..b868bd0 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -56,7 +56,7 @@ @@ -105,7 +106,7 @@

Open Source Day

- Register now See the schedule @@ -726,8 +727,9 @@

- -
+ +
+
-
diff --git a/frontend/register.html b/frontend/register.html index f1373dd..0a81270 100644 --- a/frontend/register.html +++ b/frontend/register.html @@ -3,384 +3,72 @@ - Register | Open Source Day 2026 | WLUG + Registration | Open Source Day 2026 | WLUG - - - - - - - - + - - - + + + - - - - - - - - - - - - - - -
- - - Back to Home - -
- - -
-
- - - - -
- Claim Your Spot -

Enter the Haunted Realm

-

- Your journey into the world of Open Source begins here. -

-
- - -
- -
- -
- -
- -
- - -
- -
- -
- -
- - -
- -
- -
- -
- - -
- -
- -
- -
- -
- -
- - -
- -
- - -
- -
- - -
- -
- - - - - - -
- - -
- -

Spell Cast Successfully!

-

- You have crossed into the realm of Open Source Day 2026. Keep this admission badge safe! -

- - - - -
-
- WLUG OSD '26 Pass - OSD26-PASS -
-
-
- Attendee - — -
-
- Email - — -
-
- Mobile - — -
-
- Year & Dept - — -
-
- College - — -
-
- -
- -
- Back to Home - -
-
+ +
+
+

Entering the Realm...

+

The registration form has moved directly to the Open Source Day 2026 home page.

+ Go to Registration
-
- - - + diff --git a/frontend/src/config/event.js b/frontend/src/config/event.js index 824976f..4343d8b 100644 --- a/frontend/src/config/event.js +++ b/frontend/src/config/event.js @@ -6,8 +6,8 @@ export const EVENT = { /** Countdown target, ISO 8601 with IST offset. Keep in sync with the date shown in index.html. */ startsAt: '2026-10-25T09:00:00+05:30', - /** Where every "Register" button points. Replace with the form URL once it exists. */ - registerUrl: '/register.html', + /** Where every "Register" button points. Points to the inline registration section on the home page. */ + registerUrl: '#registration', /** Footer links. Empty string = link stays hidden-safe ("#"). */ socials: { diff --git a/frontend/src/scripts/main.js b/frontend/src/scripts/main.js index 2e26f98..97bd417 100644 --- a/frontend/src/scripts/main.js +++ b/frontend/src/scripts/main.js @@ -11,11 +11,43 @@ import { initHeroParallax } from './hero-parallax.js'; import { initOffscreenPause } from './motion.js'; import { initFog } from './fog/fog.js'; import { prefersReducedMotion, isLowPowerDevice } from './device.js'; +import { initRegistration } from './register.js'; + +function scrollToRegistration(e) { + const target = document.getElementById('registration') || document.getElementById('register'); + if (target) { + if (e && typeof e.preventDefault === 'function') { + e.preventDefault(); + if (window.history && window.history.pushState) { + window.history.pushState(null, '', '#registration'); + } else { + window.location.hash = 'registration'; + } + } + target.scrollIntoView({ behavior: 'smooth', block: 'start' }); + // Keep keyboard accessibility and focus the first form input smoothly + setTimeout(() => { + const firstInput = target.querySelector('input:not([disabled]), select:not([disabled])'); + if (firstInput) { + firstInput.focus({ preventScroll: true }); + } + }, 600); + } +} function applyLinks() { document.querySelectorAll('[data-register-link]').forEach((link) => { link.setAttribute('href', EVENT.registerUrl); + link.addEventListener('click', scrollToRegistration); + }); + + // Also bind any in-page anchor links pointing to #registration or #register + document.querySelectorAll('a[href="#registration"], a[href="#register"]').forEach((link) => { + if (!link.hasAttribute('data-register-link')) { + link.addEventListener('click', scrollToRegistration); + } }); + document.querySelectorAll('[data-social]').forEach((link) => { const url = EVENT.socials[link.dataset.social]; if (url) { @@ -32,8 +64,16 @@ function init() { initFaq(document.querySelector('[data-faq]')); initSessions(document.querySelector('[data-sessions]')); initEventCards(); + initRegistration(); initOffscreenPause(document.querySelectorAll('main > section')); + // If page is loaded with #registration or #register hash, scroll smoothly to section + if (window.location.hash === '#registration' || window.location.hash === '#register') { + setTimeout(() => { + scrollToRegistration(); + }, 150); + } + const hero = document.querySelector('[data-hero]'); const reduced = prefersReducedMotion(); if (!reduced) initHeroParallax(hero); diff --git a/frontend/src/scripts/register.js b/frontend/src/scripts/register.js index 1b3438b..9740c84 100644 --- a/frontend/src/scripts/register.js +++ b/frontend/src/scripts/register.js @@ -175,10 +175,13 @@ export async function submitRegistration(data) { }; } +let isInitialized = false; + /** * Initializes the registration form interface. */ export function initRegistration() { + if (isInitialized) return; const form = document.getElementById('register-form'); const successCard = document.getElementById('register-success'); const submitBtn = document.getElementById('submit-btn'); @@ -188,6 +191,7 @@ export function initRegistration() { const emailStatusBanner = document.getElementById('email-status-banner'); if (!form) return; + isInitialized = true; const fields = ['name', 'email', 'mobile_number', 'year', 'department', 'college_name']; const touched = {}; diff --git a/frontend/src/styles/main.css b/frontend/src/styles/main.css index 4750c34..88554a6 100644 --- a/frontend/src/styles/main.css +++ b/frontend/src/styles/main.css @@ -11,5 +11,6 @@ @import './sections/faq.css'; @import './sections/sponsor.css'; @import './sections/events.css'; +@import './sections/register-page.css'; @import './sections/register.css'; @import './sections/footer.css'; diff --git a/frontend/src/styles/sections/register.css b/frontend/src/styles/sections/register.css index 199ec9d..8bdbc79 100644 --- a/frontend/src/styles/sections/register.css +++ b/frontend/src/styles/sections/register.css @@ -1,10 +1,21 @@ .register { position: relative; overflow: hidden; - padding: 110px var(--gutter) 48px; + padding: 110px var(--gutter) 80px; text-align: center; background: var(--c-night); } + +.register-anchor { + position: absolute; + top: 0; + left: 0; + width: 1px; + height: 1px; + pointer-events: none; + visibility: hidden; +} + .register__spotlight { position: absolute; left: 50%; @@ -17,6 +28,7 @@ background: radial-gradient(ellipse, rgb(138 77 255 / 0.28), transparent 65%); pointer-events: none; } + .register__inner { position: relative; z-index: 3; @@ -27,46 +39,12 @@ align-items: center; } -/* Floating ghost over a still base */ -.haunt { - position: relative; - width: 240px; - display: flex; - flex-direction: column; - align-items: center; -} -.haunt__ghost { - position: relative; - z-index: 2; - width: 180px; - filter: drop-shadow(0 0 30px rgb(201 168 255 / 0.35)); -} -.haunt__base { - position: relative; - width: 230px; - margin-top: 18px; -} -.haunt__base img { - filter: drop-shadow(0 14px 16px rgb(0 0 0 / 0.45)); -} -.haunt__shadow { - position: absolute; - left: 50%; - top: 30%; - width: 120px; - height: 18px; - margin-left: -60px; - border-radius: 50%; - background: radial-gradient(ellipse, rgb(10 20 5 / 0.6), transparent 70%); - animation: shadow-breathe 5s ease-in-out infinite; -} - .register__title { - margin-top: 24px; + margin-top: 20px; font-family: var(--font-display); font-weight: 400; - font-size: clamp(2.75rem, 6vw, 5rem); - line-height: 1.02; + font-size: clamp(2.75rem, 6vw, 4.5rem); + line-height: 1.05; color: var(--c-text-warm); text-shadow: 0 1px 0 #9c6bf5, @@ -77,13 +55,27 @@ 0 6px 0 #3b1b73, 0 16px 26px rgb(5 0 15 / 0.55); } + .register__text { - max-width: 40ch; - margin-top: 20px; - font-size: 1.25rem; + max-width: 48ch; + margin-top: 16px; + font-size: 1.1875rem; line-height: 1.55; color: var(--c-text-muted); } -.register .btn { - margin-top: 34px; + +/* Inline registration form card adjustments inside the section */ +.register .register-card { + margin-top: 64px; + text-align: left; +} + +@media (max-width: 600px) { + .register { + padding: 80px var(--gutter) 60px; + } + + .register .register-card { + margin-top: 48px; + } } diff --git a/frontend/vite.config.js b/frontend/vite.config.js index 76b9745..080e7b3 100644 --- a/frontend/vite.config.js +++ b/frontend/vite.config.js @@ -8,17 +8,21 @@ function multiPageRewritePlugin() { return { name: 'multi-page-rewrite', configureServer(server) { - server.middlewares.use((req, _res, next) => { + server.middlewares.use((req, res, next) => { if (req.url === '/register' || req.url === '/register/') { - req.url = '/register.html'; + res.writeHead(302, { Location: '/#registration' }); + res.end(); + return; } next(); }); }, configurePreviewServer(server) { - server.middlewares.use((req, _res, next) => { + server.middlewares.use((req, res, next) => { if (req.url === '/register' || req.url === '/register/') { - req.url = '/register.html'; + res.writeHead(302, { Location: '/#registration' }); + res.end(); + return; } next(); });