Skip to content

feat(ui): surface anchor errors as unavailable rows (#474 B041)#600

Open
spiffamani wants to merge 1 commit into
ezedike-evan:mainfrom
spiffamani:main
Open

feat(ui): surface anchor errors as unavailable rows (#474 B041)#600
spiffamani wants to merge 1 commit into
ezedike-evan:mainfrom
spiffamani:main

Conversation

@spiffamani

Copy link
Copy Markdown

What

Closes #474 B041

Failed anchors returned in errors[] by fetchCorridorRates were
silently dropped — the UI only rendered rates[]. This PR surfaces
them as greyed-out "Unavailable" rows so users know an anchor failed
and why.

Changes

  • types/index.ts — add AnchorRateError interface and errors? field to RateComparison
  • hooks/useAnchorRates.ts — expose anchorErrors: AnchorRateError[] on UseAnchorRatesResult
  • components/offramp/RateTable.tsx — render failed anchors as unavailable rows with title tooltip showing the reason; disabled Execute button
  • app/offramp/page.tsx — destructure anchorErrors and pass to <RateTable>
  • tests/components/RateTable.test.tsx — 3 new test cases covering unavailable row rendering

Testing

  • TypeScript: tsc --noEmit clean
  • Unit tests: 9/9 passing (6 existing + 3 new)

…B041)

- Add AnchorRateError type and errors? field to RateComparison in types/index.ts
- Thread anchorErrors through useAnchorRates hook return value
- Render failed anchors as greyed-out unavailable rows in RateTable
  with tooltip reason via title attribute; never blocks the page
- Pass anchorErrors from useAnchorRates into RateTable in offramp page
- Add 3 new test cases covering unavailable row rendering
@vercel

vercel Bot commented Jun 27, 2026

Copy link
Copy Markdown

Someone is attempting to deploy a commit to the ezedikeevan's projects Team on Vercel.

A member of the Team first needs to authorize it.

@drips-wave

drips-wave Bot commented Jun 27, 2026

Copy link
Copy Markdown

@spiffamani 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! 🚀

Learn more about application limits

@determined-001 determined-001 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The check (node 20) and check (node 22) CI jobs are failing. Please run npm run lint and npm run test locally, fix any errors, and push so CI goes green before this can merge.

@ezedike-evan ezedike-evan left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The check (node 20) and check (node 22) CI jobs are failing. Please run npm run lint && npm run test locally, fix any errors, and push so checks go green before this can merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

B041: [FEAT] [UI] Surface server-rates errors[] as "unavailable" rows

3 participants