Skip to content

Migrate the events pages, status pages, and leaderboard to Tailwind #2286

Open

Description

@trillium

Trillium Firstmate 🤖

Overview

Convert the remaining small screens: events list and detail, the "check your email" / success pages, the page header, the error box, the leaderboard, and the generic form.

Dependencies

Action Items

  • Migrate these files to the shared components from client/src/components/ui/ and Tailwind classes. Keep the same text, props, routes and behavior:
    • client/src/pages/Events.jsx (TextField, List, ListItemText, Typography) and client/src/sass/Events.scss
    • client/src/pages/Event.jsx and client/src/sass/Event.scss
    • client/src/components/ReadyEvents.jsx and client/src/sass/ReadyEvents.scss
    • client/src/pages/Success.jsx, client/src/pages/EmailSent.jsx and client/src/sass/MagicLink.scss
    • client/src/components/Header.jsx and client/src/sass/Headers.scss
    • client/src/components/ErrorContainer.jsx and client/src/sass/ErrorContainer.scss
    • client/src/components/Form.jsx (7 raw form elements) and client/src/sass/Form.scss
    • client/src/components/Leaderboard.jsx, client/src/components/DashboardUsers.jsx and client/src/sass/DashboardUsers.scss, client/src/sass/Users.scss (last importers)
  • Leaderboard has a snapshot test (client/src/components/Leaderboard.test.jsx and its snapshot files). Class names will change, so regenerate the snapshot and, in the PR, explain that the text content is unchanged. Remove the duplicate old snapshot file (__snapshots__/Leaderboard.test.js.snap) if it is no longer used.
  • Take before/after screenshots (desktop about 1280 px, phone 390 px) of each state listed in the Acceptance Criteria.
  • Add Vitest checks: the events list responds to the search box as it does today; the success and email-sent pages show their message; ErrorContainer shows the error text it is given.
  • Delete the .scss files or rules that become unused, and remove their imports.

Acceptance Criteria

  • None of the files listed above imports from @mui/* or @emotion/*, and none still contains sx= or styled(.
  • The screen looks the same as before (pixel parity). The PR shows before/after screenshots at desktop width (about 1280 px) and phone width (390 px), including each state named in the Action Items (empty, loading, error, open dialog, and so on). The PR template has sections for these.
  • New Vitest checks are included (see Action Items) and yarn test passes.
  • yarn typecheck and yarn build pass in client/.
  • Any .scss file (or part of one) that this change makes unused is deleted, and nothing outside the listed files is left depending on it.
  • Keyboard-only pass done and noted in the PR: Tab order is sensible, every control can be used without a mouse, and dialogs/menus close with Escape.
  • The behavior is unchanged: same requests, same validation messages, same routes and redirects.
  • States in the screenshots: events list, event detail, success, email sent, an error box.

Resources/Instructions

Additional Notes

  • Decided for the whole epic: every screen keeps pixel parity with today. This is a change of tooling, not a redesign. Fonts, colors, spacing, sizes, and breakpoints must look the same after the change.
  • The temporary Tailwind important flag is on while MUI is still in the app (decided). That is what lets a Tailwind class beat MUI/emotion and the old global SCSS. It is removed in Final cleanup: remove the Tailwind 'important' flag and the old global SCSS #2288.

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature: Design systemmilestone: missingp-feature: Eventsrole: Front Endsize: 3pt

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions