fix: show actual connected wallet network instead of hardcoded Stella… - #158
Merged
JamesVictor-O merged 1 commit intoAug 22, 2026
Merged
Conversation
|
@YerimahOfTimes is attempting to deploy a commit to the victorjames408gmailcom's projects Team on Vercel. A member of the Team first needs to authorize it. |
…r Mainnet Closes Ads-Bazaar#143 - Replace hardcoded 'Stellar Mainnet' label with wallet.network from useWallet() - Add formatNetworkLabel() to map Freighter's PUBLIC/TESTNET/FUTURENET to readable labels - Fall back to 'Unknown network' when no wallet/network is available - Show a visible warning when the connected network isn't mainnet, before funding
Yerimahjr
force-pushed
the
fix/network-label-review-screen-143
branch
from
August 21, 2026 12:47
9400606 to
12ff721
Compare
JamesVictor-O
approved these changes
Aug 22, 2026
JamesVictor-O
left a comment
Contributor
There was a problem hiding this comment.
✅ Approve
Reviewed with a full local checkout:
- Build:
next buildpasses clean. - Type check:
tsc --noEmitclean. - Mergeable: no conflicts with
main. - Code: Verified
networkis populated from Freighter'sgetNetworkDetails().networkinwallet-provider.tsx, which does return the rawPUBLIC/TESTNET/FUTURENETidentifiers this PR'sformatNetworkLabel()maps — the mapping is correct. The mismatch warning is a nice safety addition before funds are locked. Ungraceful fallback (raw string for unmapped values likeSTANDALONE) is a minor cosmetic edge case, not worth blocking on.
Noted the author's disclosure that next lint fails repo-wide for unrelated pre-existing reasons — confirmed that's fixed separately in #155 (eslint config migration), not a gap in this PR.
No issues found. Merging.
3 tasks
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.
Closes #143
Replaces the hardcoded "Stellar Mainnet" label on the Review & Fund screen with the actual connected wallet's network.
Changes:
formatNetworkLabel()to map Freighter's raw network values (PUBLIC,TESTNET,FUTURENET) to readable labelswallet.network, falling back to "Unknown network" when unavailableTesting: Verified via build (
next buildpasses clean) and manual browser walkthrough of the campaign wizard, confirming the Testnet label and mismatch warning render correctly.Note:
next lintfails in this repo regardless of this change (pre-existingpnpm --filter/ monorepo tooling issue, not related to this fix).