Skip to content

Replace prompt()/alert() in handleTopUp with proper TopUpModal #355

@ogazboiz

Description

@ogazboiz

Join our community: https://t.me/+DOylgFv1jyJlNzM0

Description

handleTopUp in both Dashboard.tsx and dashboard-view.tsx still uses a native prompt() dialog and alert() instead of calling sorobanTopUp. The TopUpModal component exists and sorobanTopUp is already imported — this TODO has been open across three releases.

What Needs to Happen

  • Remove prompt() and alert() from handleTopUp in both files
  • Open the existing TopUpModal with the selected stream ID
  • On modal confirm: validate amount precision, call sorobanTopUp(session, { streamId, amount }) via Freighter
  • Show TransactionTracker states (signing → submitted → confirmed)
  • On success: refresh stream card balance, close modal

Files

  • frontend/src/components/Dashboard.tsx (line 64)
  • frontend/src/components/dashboard/dashboard-view.tsx (line 466)
  • frontend/src/components/stream-creation/TopUpModal.tsx

Acceptance Criteria

  • No prompt() or alert() anywhere in the top-up flow
  • Real Soroban transaction submitted via Freighter
  • Stream balance updates after successful top-up

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programfrontendFrontend related tasks

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions