Repository navigation
Conversation
This branch has not been deployed
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.
Overview
Resolves #1 by adding full support for testnet USDC (Stellar Asset Contract) alongside native XLM for per-second micro-streams, complete with token selector, trustline pre-flight validation, and multi-token Earnings/Streams filtering.
Changes
Token Metadata & Registration (
frontend/src/lib/config.ts):CBIELTK6YBZJU5UP2WWQEUCYKLPU6AUNZ2BQ4WWFEIE3USCIHMXQDAMAissued byGBBD47IF6LWK7P7MDEVSCWR7DPUWV3NY3DTQEVFL4NAT4AQH3ZLLFLA5) with 7 decimals.SUPPORTED_TOKENSwithTokenInfotypes for both XLM and USDC.tokenMetasafely handles arbitrary unregistered SAC addresses.Trustline & Horizon Balances (
frontend/src/lib/wallet.ts):hasTrustline(address, assetCode, issuer)to detect whether the recipient account can receive USDC transfers.tokenBalance(address, tokenAddress)to query balances across both native XLM and classic credit assets on Horizon.NewStreamModal Token Selector & Warning (
frontend/src/components/NewStreamModal.tsx):create_streamwith the chosen SAC contract ID.Multi-Token Streams & Earnings Pages (
frontend/src/pages/Streams.tsx,frontend/src/pages/Earnings.tsx):TopUpSheetto accept arbitrary token addresses and format amounts according to token metadata.EarningsPage, addingAll / XLM / USDCtoken filter tabs.Unit Tests & Verification (
frontend/src/lib/__tests__/tokens.test.ts):tsc -bclean, and production Vite build succeeds.Closes #1.
Bounty Payout Wallet (TRC20 USDT / TRX):
TMqmJjRgVS21NL2eFtfyHciTxvE4BqGmEv