feat: Sentry source maps, login lockout UI, Stellar address validation, Storybook - #617
Open
WebDeveloper-Jose wants to merge 1 commit into
Open
Conversation
…n, storybook - next.config.mjs: withSentryConfig's sourcemaps.deleteSourcemapsAfterUpload is set explicitly (the v8+ SDK's replacement for the old hideSourceMaps option) — source maps are still uploaded to Sentry for stack-trace symbolication, then removed from the production build output so they aren't fetchable from the browser. (kellymusk#481) - lib/api.ts / app/api/auth/login/route.ts: ApiError now carries retryAfterSeconds parsed from a 429's Retry-After header, forwarded through the login proxy route (which previously dropped every header on an error response). app/login/page.tsx shows a live cooldown countdown and disables the submit button — using the header's value when present, falling back to a default, and also triggering after 5 failed attempts even without an explicit 429 from the backend. (kellymusk#482) - lib/stellar-address.ts: client-side Stellar (classic) address validation — a full base32 + CRC16/XMODEM checksum check, not just a length/charset regex — used in the one manual address-entry point across onramp, offramp, and wallet flows (components/send/send-page-client.tsx, which previously only checked recipientInput.trim().length > 5). onramp's address is filled from session and offramp has no address field, so there was nothing to change in either. (kellymusk#483) - Storybook installed for Next.js + Tailwind v4 (@storybook/nextjs-vite), with stories for Button, Badge, Alert, Input, Select, Card, LoadingSpinner, and EmptyStateIllustration, plus a build-only CI job. Trimmed storybook init's default scaffold down to what was asked for, dropping the Vitest/Playwright/Chromatic/MCP addons it adds by default. (kellymusk#484) Also fixes components/session-provider.tsx, which had two competing session-restore implementations (cookie-based and an older localStorage one) concatenated instead of merged: duplicate declarations, a signOut defined twice, and a call to an undefined persist(). Reconstructed from the two commits that diverged (6ce830f, 650f096), keeping the newer httpOnly-cookie design and re-adding signInWithFreighter on top of it. It sits directly in the path of kellymusk#482's signIn error handling and had to compile for anything else here to build or test. Ran: tsc --noEmit, eslint, prettier --check, jest on the new/changed test files, and npm run build-storybook — all pass. Closes kellymusk#481, closes kellymusk#482, closes kellymusk#483, closes kellymusk#484
|
@WebDeveloper-Jose is attempting to deploy a commit to the kelly musk's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
@WebDeveloper-Jose 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
Four small, independent fixes/additions bundled together.
Closes #481, closes #482, closes #483, closes #484
Type of Change
Changes Made
next.config.mjs—withSentryConfig'ssourcemaps.deleteSourcemapsAfterUpload: trueset explicitly (the v8+ SDK's replacement for the oldhideSourceMapsoption, which no longer exists in the installed@sentry/nextjs@^10). Source maps are still uploaded to Sentry for stack-trace symbolication, then removed from the production build output so they aren't fetchable from the browser.lib/api.ts/app/api/auth/login/route.ts—ApiErrornow carriesretryAfterSecondsparsed from a 429'sRetry-Afterheader, forwarded through the login proxy route (which previously dropped every header on an error response).app/login/page.tsxshows a live cooldown countdown and disables the submit button — using the header's value when present, falling back to a 30s default, and also triggering after 5 failed attempts even without an explicit 429 from the backend.lib/stellar-address.ts(new) — client-side Stellar (classic) address validation: a full base32 + CRC16/XMODEM checksum check, not just a length/charset regex. Wired into the one manual address-entry point across onramp, offramp, and wallet flows (components/send/send-page-client.tsx, which previously only checkedrecipientInput.trim().length > 5). Checked onramp and offramp: onramp's address comes from the session (auto-filled, never typed), and offramp has no Stellar-address field at all (it's fiat bank details) — so there was nothing to change in either.@storybook/nextjs-vite), with stories for Button, Badge, Alert, Input, Select, Card, LoadingSpinner, and EmptyStateIllustration, plus a build-onlystorybook-buildCI job. Trimmedstorybook init's default scaffold down to just what the issue asked for — dropped the Vitest/Playwright/Chromatic/MCP addons it adds by default, none of which were requested.Review Notes
components/session-provider.tsxhad two competing session-restore implementations (cookie-based and an older localStorage one) concatenated instead of merged at some point — duplicate declarations,signOutdefined twice, and a call to an undefinedpersist()— which failed to compile. Reconstructed it from the two commits that diverged (6ce830f,650f0965), keeping the newer httpOnly-cookie design and re-addingsignInWithFreighteron top of it. This file is in the direct path of #482'ssignInerror handling, so it had to compile for anything else in this PR to build or test — not part of any of the four issues on its own, but unavoidable.Testing
npm test)npm test)npm run dev)Commands run:
All pass. The pre-push hook additionally ran the full suite (51/51 passing across 8 test files, including the 3 new/updated ones here).