Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This pull request adds support for the ParityUSD extension system to enable dynamic NFT data enrichment. The extension allows loan key NFTs with empty commitments to fetch actual loan state from on-chain "sidecar" UTXOs, enabling proper display of loan details without storing the data directly in the loan key NFT commitment.
Changes:
- Implements a generic extension system with the first concrete extension for ParityUSD loan state fetching
- Adds comprehensive test coverage for the extension system, adapter, and end-to-end parsing flows
- Updates UI components to display extension-fetched data with appropriate labels in English, Spanish, and French
Reviewed changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| test/extensions.test.ts | Comprehensive test suite covering adapter conversion, extension invocation, fetchLoanState logic, and end-to-end parsing with extensions |
| src/parsing/extensions/types.ts | TypeScript interfaces defining ElectrumClient, ElectrumUtxo, ExtensionHandler, and ExtensionRegistry types |
| src/parsing/extensions/parityusd.ts | Implementation of fetchLoanState extension that retrieves loan data from sidecar UTXOs and transplants it into loan key NFTs |
| src/parsing/extensions/index.ts | Extension registry and orchestration logic for invoking configured extensions on UTXOs before parsing |
| src/parsing/electrumAdapter.ts | Adapter to bridge mainnet-js provider format to ElectrumClient interface expected by extensions |
| src/stores/store.ts | Integration of extension system into parseNftCommitment function, making it async to support extension invocation |
| src/components/tokenItems/tokenItemNFT.vue | Updated to handle async parseNftCommitment and conditionally display extension-specific labels |
| src/components/tokenItems/nftChild.vue | Updated to handle async parseNftCommitment and conditionally display extension-specific labels |
| src/i18n/locales/en.json | Added "extensionNote" translation for English |
| src/i18n/locales/es.json | Added "extensionNote" translation for Spanish |
| src/i18n/locales/fr.json | Added "extensionNote" translation for French |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
No description provided.