-
Notifications
You must be signed in to change notification settings - Fork 428
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
updated to use contractInfo name (#5536)
https://linear.app/thirdweb/issue/DASH-489/modules-ui-bug-with-erc20-modules-showing-tokenid <!-- start pr-codex --> --- ## PR-Codex overview This PR focuses on refactoring the handling of different ERC token types in various components of a dashboard application. It replaces boolean flags with string identifiers for token types, enhancing clarity and maintainability. ### Detailed summary - Replaced boolean flags (`isErc721`, `isErc20`) with string identifiers (`name`) for token types in multiple components. - Updated metadata upload logic to use `props.contractInfo.name` for conditional checks. - Refactored the `uploadMetadata`, `setTransferable`, and `mint` functions to use the new string identifiers. - Modified UI components to use `Select` for token type selection instead of checkboxes. - Adjusted condition checks for enabling transfer and minting based on the updated token type handling. - Updated the `ClaimableModule` to handle ERC20 and ERC721 claims with the new string-based approach. - Ensured consistent handling of token decimals and claim conditions based on token type. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
- Loading branch information
Showing
6 changed files
with
200 additions
and
103 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Oops, something went wrong.