feat(web): tier progress display, error boundary, toast system, modal focus trap#353
Open
Xueen-code wants to merge 1 commit into
Open
Conversation
… with focus trap - apps/web/src/features/referrals/components/shared/tier-progress.tsx — extracted TierProgress from affiliates-tab; renders zero/partial/maxed-out fixtures with ARIA progressbar and tier labels; 12 unit tests - apps/web/src/shared/components/ErrorBoundary.tsx — class-based boundary with reset() callback and optional fallback prop; 7 unit tests including retry flow - apps/web/src/shared/components/toast/ — useToast hook + ToastProvider; supports success/error/info variants, auto-dismiss with fake timers, manual dismiss, queue; 8 unit tests - apps/web/src/shared/components/Modal.tsx — dialog with focus trap, Escape-to-close, trigger-ref focus-return, backdrop click dismiss; 8 unit tests using user-event closes SO4-Markets#312 closes SO4-Markets#313 closes SO4-Markets#314 closes SO4-Markets#315
|
@Xueen-code is attempting to deploy a commit to the Ijai's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
@Xueen-code Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
TierProgresstoapps/web/src/features/referrals/components/shared/tier-progress.tsx; renders zero, partial, and maxed-out tier fixtures with tier label, ARIA progressbar, and next-tier threshold copy; 12 unit tests stable in jsdom.apps/web/src/shared/components/ErrorBoundary.tsx— class-based error boundary withreset()via "Try again" button and optionalfallbackprop;console.erroris mocked in tests to contain noise; 7 unit tests including retry re-render flow.apps/web/src/shared/components/toast/—useToasthook +ToastProvider; supportssuccess,error,infovariants; auto-dismiss withvi.useFakeTimers()(no real sleeps); manual dismiss; toast queuing; 8 unit tests.apps/web/src/shared/components/Modal.tsx—role="dialog"with focus trap (Tab/Shift+Tab),Escape-to-close, trigger-ref focus-return on close, backdrop click dismiss; tests use@testing-library/user-eventkeyboard navigation; 8 unit tests.Test plan
bun run --cwd apps/web testpasses for all new test files.vi.spyOn.closes #312
closes #313
closes #314
closes #315