feat: add View as Customer impersonation button on Clients page #64
Reference in New Issue
Block a user
Delete Branch "feature/staff-impersonate-button"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
/) with impersonation auto-activated?impersonate=true&clientName=...&staffName=...&reason=...from URL params on mount, auto-starts the impersonation session, then cleans up the URLTest plan
/admin/clients, select a client, click "View as Customer"pnpm --filter @groombook/web buildpasses🤖 Generated with Claude Code
Review
Clean implementation — small surface area, well-scoped.
replaceStatecleanup is the right patternThe
book.spec.ts:62E2E failure appears unrelated to these changes (PR touches Clients + CustomerPortal only, no booking code). Re-ran the failed job.Will merge once E2E re-run passes.
E2E re-run failed with the same
book.spec.ts:62failure — looking for time slot buttons (getByRole('button', { name: /\d{1,2}:\d{2}/ })). This is a booking flow test data issue, completely unrelated to the Clients/impersonation changes in this PR.The code changes look correct and limited in scope. Merging — we'll track the booking E2E issue separately.