Skip to content

[Frontend] StreamDetailsModal: progress NaN on zero deposit + close button missing aria-label #570

Description

@ogazboiz

Telegram: https://t.me/+DOylgFv1jyJlNzM0

Why this matters

frontend/src/components/dashboard/StreamDetailsModal.tsx:

  1. const progress = (stream.withdrawn / stream.deposited) * 100; — when deposited === 0, this is NaN/Infinity, producing an invalid progress-bar width.
  2. The close (X) button has no aria-label, so screen readers announce it as an unlabeled button (other modals in the app label theirs aria-label="Close").

Acceptance criteria

  • Guard the progress calc: deposited > 0 ? (withdrawn / deposited) * 100 : 0, clamped to 0–100
  • Add aria-label="Close" to the X button
  • (Optional) add role="dialog"/aria-modal consistent with the modal-a11y issue

Files to touch

  • frontend/src/components/dashboard/StreamDetailsModal.tsx

Out of scope

  • Stream-detail page progress bar (separate issue).

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programfrontendFrontend related tasksgood first issueGood for newcomersuiUser interface refinement

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions