Skip to content

[FE-31] Build Invoice List component with download action and loading state #1010

@devwums

Description

@devwums

Problem

After completing a booking, members have no UI to view and download their invoices. The invoice list is inaccessible from the main navigation.

Proposed Solution

Create frontend/cntr/InvoiceList/InvoiceList.tsx. Props: invoices: { id: string, invoiceNumber: string, amountKobo: number, status: string, createdAt: string, bookingId: string }[], onDownload: (invoiceId: string) => void, isLoading?: boolean. Renders a paginated table. Shows skeleton rows when loading, an empty state when empty, amounts formatted as ₦, and a download icon button per row. All implementation must live inside frontend/cntr/.

Acceptance Criteria

  • File at frontend/cntr/InvoiceList/InvoiceList.tsx
  • Shows skeleton placeholder rows when isLoading is true
  • Shows empty state message when invoices.length === 0
  • Amount formatted as ₦ using (amountKobo / 100).toLocaleString('en-NG')
  • Download button calls onDownload(invoice.id)
  • Test in frontend/cntr/InvoiceList/InvoiceList.test.tsx

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    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