mirror of
https://github.com/supabase/supabase.git
synced 2026-10-06 09:55:06 +03:00
### Summary This PR adds the ability to download payment receipts for paid Orb invoices from the billing invoices page. This depends on the backend PR that adds the receipt download endpoint. ### UI screenshot The receipt button only appears for invoices with `status === 'paid'`. <img width="738" height="276" alt="Screenshot 2026-01-22 at 8 53 06 PM" src="https://github.com/user-attachments/assets/e4fa3f5f-0222-4787-9c7d-96ae99346808" /> ### Testing #### Manual testing 1. Navigate to Organization Settings → Billing → Invoices 2. Find a paid invoice in the list 3. Click the receipt icon button 4. Verify receipt PDF opens in new tab 5. Try with an unpaid invoice - button should not appear 6. Try invoice that has no receipt (paid with credit balance) → error toast with "Receipt not available" ### Alternative design choices #### Alternative option 1 <img width="712" height="266" alt="Screenshot 2026-01-22 at 8 46 24 PM" src="https://github.com/user-attachments/assets/2eb7333c-cb19-4e6d-b495-72c43fb26475" /> #### Alternative option 2 <img width="723" height="264" alt="Screenshot 2026-01-22 at 8 56 30 PM" src="https://github.com/user-attachments/assets/34b917b6-fc8c-4398-b372-ff467920fe69" /> #### Alternative option 3 <img width="702" height="265" alt="Screenshot 2026-01-22 at 8 47 58 PM" src="https://github.com/user-attachments/assets/b3e15b1c-a804-4df9-981e-1ec578d7e4fe" /> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit ## Release Notes * **New Features** * Added invoice receipt viewing and download functionality. Paid invoices with outstanding amounts now include a Receipt action, enabling users to access detailed payment documentation through the billing interface. Error handling ensures a seamless experience when retrieving receipts. <!-- end of auto-generated comment: release notes by coderabbit.ai -->