feat: add loyalty token redemption drawer - #47
Conversation
|
@charlesbarleyman is attempting to deploy a commit to the Meshack Yaro's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
meshackyaro
left a comment
There was a problem hiding this comment.
Nice work on this one — the scope here goes well beyond the ticket in the right ways. The accessibility details (focus restoration, tab containment, Escape/backdrop close, scroll locking) are easy to skip on a drawer component and you didn't. Gating redemption on both wallet connection and the correct Stellar network is the right defensive check for anything touching token balances. And isolating the preview adapter behind src/lib/loyalty.ts with a clear label is exactly the right way to land UI ahead of a backend — makes the eventual swap-over a contained change instead of a hunt through the codebase. Appreciate the reducer coverage for the failure-recovery path too, since that's the branch people usually forget to test. Thanks for flagging the pre-existing localStorage/lint issues explicitly rather than folding them in quietly.
Good job!
Summary
Implements #29, Loyalty Token Balance & Redemption Drawer.
src/lib/loyalty.ts; it is clearly labelled because no loyalty balance/redemption backend endpoint exists yet.Verification
npm test -- src/lib/test/loyalty.test.tsnpm run typechecknpm run lint(passes with 9 pre-existing warnings outside this change)npm run buildnpm testcurrently has pre-existing storage-dependent failures in this local Node/jsdom environment (window.localStorageis unavailable); the new loyalty test passes.Closes #29