feat(frontend): make quote freshness and currency validation explicit in send flow - #296
Open
woahwhattheheck wants to merge 3 commits into
Open
woahwhattheheck wants to merge 3 commits into
woahwhattheheck wants to merge 3 commits into
Conversation
Show quote source, timestamps, expiry, and currency metadata on the card. Invalidate pending quotes on field or network changes, refuse to confirm expired or mismatched prices, and bind the quote id into the transfer payload so displayed and serialized amounts stay reconciled. Closes RemitFlow#279
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 #279
Summary
Quotes in the send flow now carry an id, source, timestamps, and currency metadata. Confirmation is blocked when a quote is expired or no longer matches the live form inputs, and the bound quote id is written into the transfer payload so displayed and serialized amounts stay reconciled.
What changed
quoteBindinghelpers validate the currency matrix, fingerprint priced inputs, assert a quote is still signable, and compare canonical amounts.buildQuotemints a content-addressed quote id +fx.tablesource + input fingerprint.QuoteCardsurfaces source, quote id, priced-at / expires, currency precision, and a refresh affordance when expired.SendMoneyinvalidates a pending confirmation on field or network changes, disables confirm while expired, and passesquoteIdthroughcreateTransfer.id/sourceon the Quote contract andquoteIdon Transfer (forward-compatible).Tradeoffs
Compatibility
id/quoteIdstill parse.Test evidence
Coverage includes expiry, currency matrix, changed-input binding, amount reconcile, and quote-id payload binding.
Out of scope
Ready for review