Skip to content

refactor: replace staff API loader with static data#231

Open
rileychh wants to merge 1 commit into
static-venue-geometryfrom
static-staff-data
Open

refactor: replace staff API loader with static data#231
rileychh wants to merge 1 commit into
static-venue-geometryfrom
static-staff-data

Conversation

@rileychh
Copy link
Copy Markdown
Member

@rileychh rileychh commented May 4, 2026

Stacked on top of #228 — review/merge that one first. Diff against main will look bigger than it is until #228 lands.

Summary

  • volunteer.coscup.org has been shut down (every URL on that host returns 404), so the staff loader's runtime fetch to https://volunteer.coscup.org/api/members?pid=... returns an HTML error page and pnpm build blows up parsing it as JSON. Captures the rendered staff list from coscup.org/2025/staff and coscup.org/2025/en/staff into a new data/staff.json and rewrites loaders/staff.data.ts to import it.
  • Drops the now-unnecessary chiefs dedup and ' - ' group-name split (both are pre-baked into the JSON), and narrows StaffGroup to the fields the templates actually consume (tid, group.{zh_tw,en}, members[]).
  • 12 groups, 164 members — same group order and member order as the deployed page, so visible output is unchanged.

Out of scope

The participate .md files still reference dead volunteer.coscup.org image and doc URLs (6 broken images, 6 dead doc/CTA links), and the staff welcome section's "register as volunteer" CTA is left as-is. Recovery isn't possible without human input — Wayback has no snapshots for that host, no alt host carries the assets, and Vite doesn't bundle raw-HTML <img src="https://..."> tags in markdown so there are no local copies in dist either. Filing as a follow-up.

Test plan

  • pnpm type-check clean (loader keeps a compatible StaffData shape)
  • jq sanity: {groups: 12, totalMembers: 164, allHaveTids: true, allHaveGroups: true}
  • CI green
  • Visual check of /staff and /en/staff against today's deployed site — group order, member order, and avatars should match

The volunteer.coscup.org host has been shut down, so the loader's call to
volunteer.coscup.org/api/members fails CI's pnpm build with HTML-where-JSON
errors. Capture the rendered staff list from coscup.org/2025/staff (12
groups, 164 members) into data/staff.json and import it from the loader.

Drop the chiefs dedup, the ' - ' name split, and the unused
data/conference import — group.zh_tw / group.en are pre-baked into the
JSON, and tid is synthesized as a sequential string (only used as Vue
:key, never displayed). StaffGroup narrows to the fields the templates
actually read (tid, group, members), so StaffZh.vue / StaffEn.vue need
no change.

Out of scope: the participate/*.md files still reference dead
volunteer.coscup.org image and doc URLs, and the staff welcome section's
"register as volunteer" CTA is left as-is. Recovery is impossible
without human input (no Wayback snapshots, no alt host, no bundled
copies anywhere).
@vercel
Copy link
Copy Markdown

vercel Bot commented May 4, 2026

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

Project Deployment Actions Updated (UTC)
2025 Ready Ready Preview, Comment May 4, 2026 4:45pm

@rileychh rileychh requested a review from mirumodapon May 4, 2026 17:18
Comment thread data/staff.json
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.

3 participants