[READY] Add Ramp History#658
Merged
Merged
Conversation
✅ Deploy Preview for pendulum-pay ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This pull request adds new functionality to support viewing ramp transaction history, including backend API endpoints and frontend UI components.
- Introduces Ramp History API endpoints and response types in the shared endpoints.
- Adds a new service method and controller endpoint to fetch transaction history from the backend.
- Implements frontend components, a Zustand store, and hooks to display and manage the ramp history panel.
Reviewed Changes
Copilot reviewed 15 out of 15 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| shared/src/endpoints/ramp.endpoints.ts | Added new interfaces for GetRampHistoryRequest/Response and cleaned up PresignedTx definition. |
| frontend/src/stores/rampHistoryStore.ts | Introduced a new Zustand store to handle the ramp history panel's state. |
| frontend/src/services/api/ramp.service.ts | Added a new API method to fetch ramp history data. |
| frontend/src/pages/ramp-form/index.tsx | Integrated the ramp history panel and toggle button into the ramp form. |
| frontend/src/hooks/useRampHistory.ts | Created a hook for fetching and processing ramp history data. |
| frontend/src/components/StatusBadge/index.tsx | Added a badge component to display the status of transactions. |
| frontend/src/components/RampHistory/types.ts | Defined transaction types and groupings for ramp history. |
| frontend/src/components/RampHistory/index.tsx | Developed the UI panel for displaying grouped transaction history. |
| frontend/src/components/RampHistory/helpers.ts | Added a helper to group transactions by month. |
| frontend/src/components/RampHistory/TransactionItem/index.tsx | Implemented UI components for individual transaction items. |
| frontend/src/components/RampHistory/RampHistoryButton/index.tsx | Created a button component to toggle the ramp history panel. |
| frontend/App.css | Added styling for custom scrollbar utilities and button styles. |
| api/src/api/services/ramp/ramp.service.ts | Implemented the getTransactionHistory method to retrieve history from the database. |
| api/src/api/routes/v1/ramp.route.ts | Configured a new route to expose the ramp history endpoint. |
| api/src/api/controllers/ramp.controller.ts | Added a controller function to handle ramp history requests. |
| /** | ||
| * Get transaction history for a wallet address | ||
| */ | ||
| public async getTransactionHistory(walletAddress: string): Promise<RampEndpoints.GetTransactionHistoryResponse> { |
There was a problem hiding this comment.
The method name 'getTransactionHistory' does not match the naming used in endpoints (which is GetRampHistoryResponse). Consider renaming the method to 'getRampHistory' for consistency with the API definitions.
ebma
approved these changes
May 21, 2025
Member
ebma
left a comment
There was a problem hiding this comment.
Tested locally and it works. I love it, great job @Sharqiewicz 🚀 ready for merge IMO
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The implementation adds a new API endpoint to fetch transaction history for a specific wallet address stored in the
ramp_statestable.Backend Changes:
shared/src/endpoints/ramp.endpoints.tsgetTransactionHistorymethod inramp.service.tsto query transactions bywalletAddressramp.controller.tswith proper validation/v1/ramp/history/:walletAddressFrontend Changes:
ramp.service.tsuseTransactionHistory) for efficient data fetching with cachingtransactionService.ts