Skip to content

Close registration flow across the Register section UI#2

Draft
Copilot wants to merge 4 commits intomainfrom
copilot/close-registration-feature
Draft

Close registration flow across the Register section UI#2
Copilot wants to merge 4 commits intomainfrom
copilot/close-registration-feature

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 8, 2026

Registration needed to be closed immediately, but the page still presented an active registration form and submit path. This change hard-disables the registration flow in the UI and submit handler so users cannot register while closure messaging is explicit.

  • Global registration gate

    • Introduced a single closure flag in RegisterSection (IS_REGISTRATION_CLOSED) and used it as the source of truth for registration availability.
    • Wired the flag into both UI state and submit behavior to avoid partial closure states.
  • Submission path hard stop

    • Added an early return in handleRegister when registration is closed.
    • Preserved existing college-specific blocking logic, now layered under the global closure gate.
  • Closed-state UX updates

    • Updated section copy from active registration messaging to closed messaging.
    • Disabled all form inputs when closed.
    • Disabled submit interactions and changed CTA label from Register Now → to Registration Closed.
const IS_REGISTRATION_CLOSED = true;

const isRegistrationDisabled = IS_REGISTRATION_CLOSED || isBlockedCollege;

const handleRegister = async (e: React.FormEvent) => {
  e.preventDefault();
  if (IS_REGISTRATION_CLOSED) {
    setErrorMessage("Registration is closed.");
    return;
  }
  // existing flow...
};

Copilot AI and others added 3 commits April 8, 2026 09:55
Agent-Logs-Url: https://github.com/Khy9/QuantumSecure/sessions/c9f0a124-a774-40e7-b6ee-33da67be2a23

Co-authored-by: Vasanthadithya-mundrathi <137519188+Vasanthadithya-mundrathi@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Khy9/QuantumSecure/sessions/c9f0a124-a774-40e7-b6ee-33da67be2a23

Co-authored-by: Vasanthadithya-mundrathi <137519188+Vasanthadithya-mundrathi@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Khy9/QuantumSecure/sessions/c9f0a124-a774-40e7-b6ee-33da67be2a23

Co-authored-by: Vasanthadithya-mundrathi <137519188+Vasanthadithya-mundrathi@users.noreply.github.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 8, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
quantum-secure Ready Ready Preview, Comment Apr 8, 2026 10:04am
quantum-secure-dwxl Ready Ready Preview, Comment Apr 8, 2026 10:04am

@Vasanthadithya-mundrathi
Copy link
Copy Markdown
Collaborator

@copilot we have conflicts check it and resolve them

Co-authored-by: Vasanthadithya-mundrathi <137519188+Vasanthadithya-mundrathi@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants