Skip to content

Add registrations page for public-next#95

Open
finleysg wants to merge 25 commits intomainfrom
public-next-2
Open

Add registrations page for public-next#95
finleysg wants to merge 25 commits intomainfrom
public-next-2

Conversation

@finleysg
Copy link
Owner

Summary

  • Add /event/.../registrations page with two views: tee-time grid (choosable events) and searchable/sortable player list (non-choosable events)
  • Add RegistrationSlotPlayer type and populate player data in reserve slots from Django API
  • Lighten secondary color by 15%, use primary for event headings
  • Responsive mobile layout: vertical stacked groups for grid view, card-style rows for list view

Test plan

  • Compare choosable event grid at /event/2025-07-30/individual-lg-ln/registrations with legacy
  • Compare non-choosable event list at /event/2025-07-12/red-white-and-blue/registrations with legacy
  • Verify mobile layouts for both views
  • Verify course tab switching on grid view
  • Verify search, sort, and pagination on list view
  • Run pnpm build and pnpm test

🤖 Generated with Claude Code

finleysg and others added 25 commits February 13, 2026 18:11
Scaffold the Next.js public-next app with auth, sidebar navigation,
and theme toggling. Establish visual identity with deep navy primary
(#21326b), Montserrat headings + Open Sans body fonts, and primary-blue
header/footer chrome. Clean up old plan files and skill configs.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Port Home, About, Policies, Contact, and Membership pages from the
legacy React SPA to Next.js server components with Django API data
fetching, markdown rendering, and shadcn/ui styling. Includes shared
infrastructure (fetchers, types, utilities), typography plugin with
theme-aware prose colors, and dark green secondary color scheme.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Port Home, About, Policies, Contact, and Membership pages from the
legacy React SPA to Next.js server components with Django API data
fetching, markdown rendering, and shadcn/ui styling. Includes shared
infrastructure (fetchers, types, utilities), typography plugin with
theme-aware prose colors, and dark green secondary color scheme.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
- Use next/image with S3 remotePatterns instead of plain img tags
- Add aria-label to logo link and account menu trigger
- Replace hardcoded localhost admin URL with env var
- Add autoComplete attributes to sign-in form inputs
- Add parseApiDate utility to fix UTC timezone shift on date-only strings
- Narrow PlayerSummary.is_member to boolean only
- Add generateStaticParams for policy routes
- Simplify CSS class names to use Tailwind theme tokens directly

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Calendar, champions, dam cup, event detail, gallery, match play,
member directory, and season points pages. Includes API routes,
shared components, utility functions, and UI primitives.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
- Add 86 tests across 5 test files (slugify, date-utils, event-utils, calendar, photo-utils)
- Extract computeOpenSpots to lib/event-utils.ts for testability
- Consolidate 4 API routes to use shared api-proxy.ts helpers
- Optimize event detail page fetch: use year/month filters instead of full season query

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Sign-up with email confirmation, account activation, password reset
(request/confirm/complete), maintenance mode, and navigation updates.
Fix Djoser email templates for django-render-block 0.11 compatibility.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Set up @playwright/test with 25 tests across 8 spec files covering auth flows,
navigation, home page, calendar, and member directory. Three projects separate
guest, authenticated, and auth setup concerns.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Adds member hub, account, friends, results, and scores pages with
API routes, hooks, and tests. Scores use traditional scorecard shape
notation (circles for under par, squares for over par) instead of
color coding.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Port registration flow types and pure utility functions from legacy public app
as plain interfaces and functions. Includes reserve table building (tee times
and shotgun), payment amount calculation with Stripe fees, fee override
evaluation, and SSE correlation ID generation.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Registration reducer with immer (17 actions on plain objects), context with
useRegistration hook, and provider orchestrating TanStack Query mutations
for registration CRUD, payments, and slot updates through local API routes.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
…ic-next (Phase 4.3)

- Enhanced fetchWithAuth with forwardHeaders option for X-Correlation-ID
- Added 7 registration API routes (create, get, cancel, add-players, drop, move, slot update)
- Added 5 payment API routes (create, update, payment-intent, stripe-amount, customer-session)
- Added SSE proxy route with ReadableStream for live registration updates
- Added client hooks: useRegistrationSSE (EventSource + exponential backoff),
  usePlayerRegistration, useRegistrationSlots

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Install shadcn/ui components (checkbox, alert, alert-dialog, command, tooltip)
and sonner for toast notifications. Create 13 registration flow components:
registration actions, countdown, cancel button, step header, slot line items,
slot group, review items, amount due, player/friend pickers, and reserve grid
with row/cell components. Add Toaster to providers.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Implements the /event/.../registrations page with two views:
- Choosable events: tee-time grid with course tabs, responsive mobile layout
- Non-choosable events: searchable, sortable, paginated player list

Also adds RegistrationSlotPlayer type, populates player data in reserve
slots, lightens secondary color, and uses primary for headings.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Simplify registration-actions component, add open spots display to
fees-and-points card, fix API registration route path from [eventId]
to [id], add shouldShowSignUpButton tests, and add accent-cta button
variant.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Add color column to Course and Tee models in Django with migrations and
expose via serializers and API mappers. Use course color for scorecard
headers and tee color for round date labels on the member/scores page.
Apply tee colors to registration grid badges.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Refactor reserve/registration components into tee-sheet-tabs, tee-sheet-body,
and slot-cell. Add reserve page with course tab navigation. Update wave
calculator with improved logic and tests. Fix member-account e2e test
timeouts by adding waitFor() before assertions on async content.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Add Django endpoint to create/update 16 test users (members, returning,
non-members) with stale-state detection, Playwright global setup that
authenticates as admin and seeds users before tests, and test account
fixture helpers. Update public-next UI components and registration API
routes.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
- New unit tests for SSE hook, grid selection, reserve utils, and reducer
- Add e2e test event fixture for creating/cleaning up test events
- Fix gitignore patterns for playwright artifacts under e2e/
- Simplify reserve-grid selection logic with extracted utility functions
- Add reserve page testing plan

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
When SSE connection fails after retries, the reserve grid now falls back
to computing waves client-side using getWaveUnlockTimes and polls for
slot data every 15s. A subtle banner indicates degraded state.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
- Fix root cause of flaky registration tests: use dedicated getMember()
  accounts instead of testUser to avoid unique_player_registration
  constraint violations across serial tests
- Add public-next-self-auth Playwright project for tests that manage
  their own authentication (reserve, registration-guard)
- Add warmCacheAndVerify() shared helper that throws on failure
- Add aria-labels to calendar nav buttons and score filter selects
  for stable test selectors
- Add registration navigation guard with confirmation dialog
- Update e2e testing skill doc with new conventions

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
When a member abandons a registration (browser crash, navigation away),
their old PENDING slots block re-registration due to the UNIQUE(event_id,
player_id) constraint. This adds cleanupStaleRegistration() to fully
remove stale payments, slots, and registration rows before creating a
fresh registration for both choosable and non-choosable events.

Also guards deletePaymentsForRegistration() against accidentally deleting
confirmed or in-progress Stripe payments.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.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.

1 participant