Skip to content

Payment Confirmation Animation #423

Description

@Kingsman-99

Description

After a payment is signed and confirmed on-chain, the UI transitions abruptly from the signing spinner to a status update with no celebratory or reassuring feedback, which creates uncertainty about whether the action succeeded. This issue implements a full-screen payment confirmation animation (a Lottie or CSS-keyframe sequence showing a success state with the transaction amount, recipient, and hash) that plays automatically after on-chain confirmation is detected, then smoothly transitions to the updated invoice view.

Technical Context

Create components/invoice/PaymentConfirmationOverlay.tsx triggered by a paymentConfirmed state emitted from hooks/usePaymentSubmission.ts. The overlay renders as a fixed full-screen layer (z-index: 9999) using a Framer Motion entrance animation or a raw CSS keyframe sequence defined in globals.css. The animation sequence: (1) checkmark draw animation (SVG stroke-dashoffset), (2) amount and recipient label fade-in, (3) transaction hash appear with a copy button, (4) auto-dismiss after 4 seconds or on user click, fading back to the invoice view with the updated status. The overlay must be accessible: add role="status" and aria-live="polite" and announce the confirmation text to screen readers. Provide a prefers-reduced-motion media query fallback that skips the animation and shows a static success card instead.

Acceptance Criteria

  • The overlay renders immediately after usePaymentSubmission sets status === 'confirmed' and displays the correct amount, recipient address (truncated), and transaction hash
  • The SVG checkmark draw animation completes within 800 ms and the transaction details fade in sequentially after
  • The overlay auto-dismisses after exactly 4 seconds and transitions to the invoice view with the new Fully Paid or Partially Paid status
  • Users with prefers-reduced-motion: reduce see a static success card instead of the animation; all information is still present
  • aria-live="polite" causes screen readers to announce "Payment confirmed: [amount] [asset] sent to [address]" after the overlay appears
  • All CI checks (npm test, npm run build, ESLint/TypeScript) pass and the branch has no merge conflicts

Activity

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

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave programcomplexity: highuiUI styling and visual changes

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions