Events

Event Frontend Implementation

A comprehensive map of every frontend file involved in the event system. Use this page to find where event features live in the bt-web-v2 codebase.


Page Files

Public Pages

URLFilePurpose
/eventssrc/pages/events.tsxPublic event listing using EventDashboard
/event/{id}/{year}/registersrc/pages/event/[eventId]/[year]/register/index.tsxAttendee registration
/event/{id}/{year}/register/successsrc/pages/event/[eventId]/[year]/register/success.tsxRegistration success page
/event/{id}/{year}/register/partnersrc/pages/event/[eventId]/[year]/register/partner/index.tsxPartner registration
/event/{id}/{year}/feedbacksrc/pages/event/[eventId]/[year]/feedback/index.tsxFeedback hub (attendee/partner selection)
/event/{id}/{year}/feedback/{formType}src/pages/event/[eventId]/[year]/feedback/[formType].tsxFeedback form

Admin Pages

URLFilePurpose
/admin/event/newsrc/pages/admin/event/new.tsxCreate new event form
/admin/event/{id}/{year}src/pages/admin/event/[eventId]/[year]/index.tsxEvent dashboard (Data Table, Feedback, Teams, Analytics tabs)
/admin/event/{id}/{year}/editsrc/pages/admin/event/[eventId]/[year]/edit.tsxEdit existing event
/admin/event/productx/2025src/pages/admin/event/productx/2025.tsxCustom ProductX 2025 admin page

Companion Pages

URLFilePurpose
/companion/{event}/{year}src/pages/companion/[event]/[year]/index.tsxCompanion app entry (schedule, quests, connections)

Event Management Components

These components handle event CRUD, registration, and feedback forms.

FilePurpose
EventForm.tsxAdmin event create/edit form — all sections (settings, cover photo, info, dates, location, pricing, questions)
EventFormSchema.tsZod validation schema for the event form
EventPreview.tsxPreview of event card before publishing
PreviewForm.tsxPreview of the registration form
EventThumbnailUploader.tsxImage upload with client-side compression, dual upload (optimized + original), presigned URL flow
AttendeeEventRegistrationForm.tsxAttendee-facing registration form with dynamic questions
PartnerEventRegistrationForm.tsxPartner-facing registration form
EventFeedbackForm.tsxPublic feedback form — renders questions by type, validates, submits
CustomQuestions.tsxBuilder for custom registration questions (admin)
CustomQuestionItem.tsxIndividual custom question component within the builder
FeedbackQuestionsBuilder.tsxBuilder for feedback questions — supports all 5 feedback types

FormComponents/ Reusable form primitives

ComponentUsed for
FormInputText inputs
FormTextareaMulti-line text
FormSelectDropdown select
FormCheckboxCheckbox inputs
FormDatePickerDate/time picker
FormOptionsOption list editing
MultiSelectCheckboxMulti-select checkbox groups

Event Dashboard Components

These components make up the public event listing and the admin event dashboard.

FilePurpose
EventDashboard.tsxMain public event listing layout
EventCard.tsxIndividual event card in the listing
EventOverviewGraphic.tsxVisual overview/stats graphic for an event
SearchBar.tsxEvent search input
FilterTab.tsxFilter events by criteria
Tabs.tsxTab navigation for dashboard views
GuestBanner.tsxBanner shown to non-authenticated users
AnalyticsTab.tsxAdmin analytics view for an event
FeedbackTab.tsxAdmin feedback builder + responses viewer
TeamsTab.tsxAdmin teams management view

Query Hooks

HookQuery KeyPurpose
useEvents()["events"]Published events only (excludes alumni-night), sorted newest-first. 60s stale time.
useAllEvents()["events", "all"]All events unfiltered — used by admin pages. 60s stale time.

Both call getEvents() / getAll() which hit GET /events/.

Related hooks in src/queries/registrations.ts:

HookPurpose
useUserRegistrations(email)User's registrations across all events

Event Form Schema

The admin event form validates through eventFormSchema:

Required Fields

FieldTypeNotes
eventNamestringMin 1 character
eventSlugstringUsed as event id
descriptionstring
capacitynumberMin 1
startDateDateConverted to ISO 8601 before API call
endDateDate
deadlineDateRegistration deadline
locationstring
imageUrlstringS3 URL from thumbnail uploader
partnerDescriptionstring

Optional Fields

FieldTypeDefault
pricenumber0
nonMemberPricenumber
isApplicationBasedbooleanfalse
nonBizTechAllowedbooleanfalse
isPublishedbooleanfalse
isCompletedbooleanfalse

Custom Questions

customQuestions: z.array(
  z.object({
    id: z.string(),
    type: z.enum([
      'TEXT',
      'SELECT',
      'CHECKBOX',
      'UPLOAD',
      'WORKSHOP_SELECTION',
      'SKILLS',
    ]),
    question: z.string(),
    required: z.boolean(),
    options: z.array(z.string()),
    charLimit: z.number().optional(),
    questionImageUrl: z.string().optional(),
    participantCap: z.number().optional(),
    isSkillsQuestion: z.boolean().optional(),
  }),
).default([])

TypeScript Types

BiztechEvent

Core event type with 30+ fields:

  • Identity: id, year, ename
  • Display: description, partnerDescription, imageUrl
  • Scheduling: startDate, endDate, deadline (all ISO 8601 strings)
  • Config: capac, isPublished, isCompleted, isApplicationBased, nonBizTechAllowed
  • Pricing: pricing: { members: number, nonMembers: number }
  • Questions: registrationQuestions, partnerRegistrationQuestions
  • Feedback: attendeeFeedbackQuestions, partnerFeedbackQuestions, attendeeFeedbackEnabled, partnerFeedbackEnabled
  • Runtime: counts (populated by ?count=true query)

RegistrationQuestion

{
  label: string;
  questionId: string;
  type: string;        // TEXT | SELECT | CHECKBOX | UPLOAD | WORKSHOP_SELECTION | SKILLS
  required: boolean;
  choices?: string[];
  charLimit?: number;
  questionImageUrl?: string;
  participantCap?: number;
  isSkillsQuestion?: boolean;
}

FeedbackQuestion

{
  label: string;
  questionId: string;
  type: "SHORT_TEXT" | "LONG_TEXT" | "MULTIPLE_CHOICE" | "CHECKBOXES" | "LINEAR_SCALE";
  required: boolean;
  choices?: string[];
  scaleMin?: number;
  scaleMax?: number;
  scaleMinLabel?: string;
  scaleMaxLabel?: string;
}

DBRegistrationStatus

enum DBRegistrationStatus {
  WAITLISTED,
  REGISTERED,
  CHECKED_IN,
  CANCELLED,
  INCOMPLETE,
  ACCEPTED,
  ACCEPTED_PENDING,
  ACCEPTED_COMPLETE,
}

Constants

src/constants/questionTypes.ts

Registration question types:

enum QuestionTypes {
  TEXT,
  CHECKBOX,
  SELECT,
  UPLOAD,
  WORKSHOP_SELECTION,
  SKILLS,
}

src/constants/feedbackQuestionTypes.ts

Feedback question types and defaults:

enum FeedbackQuestionTypes {
  SHORT_TEXT,
  LONG_TEXT,
  MULTIPLE_CHOICE,
  CHECKBOXES,
  LINEAR_SCALE,
}
FEEDBACK_FORM_TYPES = { attendee, partner }
DEFAULT_OVERALL_RATING_QUESTION // Linear scale 1–10

src/constants/registrations.ts

Registration status labels, QR scan stages, table types:

REGISTRATION_STATUS = {
  REGISTERED,
  CHECKED_IN,
  WAITLISTED,
  CANCELLED,
  INCOMPLETE,
  ACCEPTEDCOMPLETE,
}
QR_SCAN_STAGE = { SCANNING, FAILED, SUCCESS }
SCAN_CYCLE_DELAY = 5000 // ms
ATTENDEE_TABLE_TYPE, PARTNER_TABLE_TYPE, APPLICATION_TABLE_TYPE

src/constants/companion-events.ts

Companion app event definitions (4 events configured):

  • Blueprint 2025 — basic companion
  • ProductX 2025 — basic companion
  • Kickstart 2025 — with team and invest sub-pages
  • Blueprint 2026 — full companion with profile, partner-database, quests, companies, MBTI, discover, connections sub-pages

Each entry specifies eventID, year, ChildComponent, optional pages (sub-routes), and options (theming, headers, schedule config).


Data Flow Patterns

Event Listing

events.tsxuseEvents()GET /events/EventDashboardEventCard[]

Event Creation

new.tsxEventForm → eventFormSchema.parse()POST /events/ → redirect to dashboard

Event Edit

edit.tsxuseAllEvents()EventForm (prefilled) → eventFormSchema.parse()PATCH /events/{id}/{year}

Registration

register/index.tsxGET /events/{id}/{year}AttendeeEventRegistrationFormPOST /registrations/

Feedback

feedback/[formType].tsxGET /events/{id}/{year}/feedback/{formType}EventFeedbackFormPOST .../feedback/{formType}

Previous
Pricing & Payments