Conversation
- Introduced `workByChain` to `PaymentFeePicker` and `CancelDelegationModal` for improved multichain fee quoting. - Updated `DelegationService` and `TransactionService` to support multichain fee quotes and payments. - Refactored related interfaces and types to streamline payment handling across multiple chains. - Simplified the cancellation process by consolidating payment logic into a single fee structure for batch operations.
…tion - Added `cancelDelegationInsufficientBalanceError` to `IStyleFormState` and relevant presets for user feedback on insufficient funds during cancellation. - Updated `CancelDelegationModal` to display an error message when the user's balance is insufficient to cover network fees. - Enhanced `PaymentFeePicker` and `TransactionUtils` to support improved payment token selection and error handling across multiple chains. - Refactored related components to ensure consistent handling of payment options and user notifications.
Enhance multichain payment handling in delegation cancellation
- Simplified the selection of payment tokens by removing the preferred token matching logic, ensuring that the selection is based solely on the payment chain ID and token address. - Enhanced comments for clarity on the payment resolution process, emphasizing the importance of matching both chain and token to avoid incorrect selections across different chains. - Maintained error handling for cases where no valid payment token is found with a positive balance.
- Updated types across multiple components to replace EVMAccountAddress with EVMContractAddress for improved clarity and consistency in handling contract addresses. - Refactored AssetIcon, AssetIdentityMark, and PaymentFeePicker components to align with the new address type. - Enhanced OnrampView and AddAssetView to ensure proper address validation and error handling. - Streamlined the BridgeService and DelegationService to utilize EVMContractAddress in relevant methods, improving type safety in contract interactions.
Refactor payment token selection logic in TransactionUtils
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.
Fixes batch delegation cancelation, and cross chain fee quoting.