Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[EPIC]: Search Bar Redesign #547

Closed
pmjanus opened this issue Feb 23, 2024 · 0 comments
Closed

[EPIC]: Search Bar Redesign #547

pmjanus opened this issue Feb 23, 2024 · 0 comments
Assignees
Labels
🎨 Needs Design A design solution is needed for part or all of the issue. 🔬 Needs Refinement Further information is required

Comments

@pmjanus
Copy link
Contributor

pmjanus commented Feb 23, 2024

Main Task: Teloscan Search Functionality UI Enhancements

Description

The Teloscan search API has been updated to provide more organized and relevant results for tokens, NFTs, addresses, block numbers, and transaction hashes. We need to implement the corresponding UI changes to display the search results effectively. This task will be broken down into subtasks to be implemented in a specific order.

Main Tasks

  1. Search Result Sections

    • Create separate sections in the search results component for:
      • Tokens (ERC-20s)
      • NFTs (ERC721 & ERC1155)
      • Addresses
      • Contracts
    • Add clickable navigation tabs above the search results to allow users to switch between the Token and NFT sections.
  2. Result Display

    • For each search result, display the following elements (if available):
      • Icon
      • Contract name
      • Price
      • Contract Address
    • Ensure that the UI layout is responsive and adapts well to different screen sizes.
  3. Token Prioritization

    • When displaying token, including NFT, results, prioritize tokens in the following order:
      • Curated tokens from the frontend token list
      • Verified contracts
      • Regular contracts
    • Visually differentiate the token results based on their priority (e.g., using different background colors or labels).
  4. Search Input Handling

    • Update the search input field to handle the various search types (address, block number, name, transaction hash).
    • Implement real-time suggestions or autocomplete functionality to assist users while typing their search queries.
  5. Loading and Error States

    • Display appropriate loading indicators while the search results are being fetched from the API.
    • Handle and display error messages if the search API encounters any issues or returns error responses.

Subtasks (to be implemented in order)

Testing

  • Conduct thorough testing of the search UI to ensure it integrates correctly with the updated search API.
  • Test various search scenarios, including partial and exact matches for addresses and names.
  • Verify that the navigation tabs function correctly and switch between the Token and NFT sections.
  • Validate that the result elements (icon, contract name, price, contract address) are displayed accurately based on the API response.

Additional Notes

  • The search API endpoints have already been implemented and are ready to be integrated with the frontend UI.
  • The frontend token list and contract verification process are assumed to be in place. If not, additional tasks may be required to implement those features.

Known Issues

  • There is a bug in how the token list is handled, where the supportedInterfaces property is not set if the token comes from the token list. This bug will be addressed in a future sprint.

Token Type Differentiation

  • For contracts, the token type can be differentiated using the supportedInterfaces property, which is a comma-separated list.
    • ERC721 tokens will have supportedInterfaces=erc721,erc721_metadata.
    • ERC20 tokens will have supportedInterfaces=erc20.

Definition of Done

  • All subtasks have been completed in the specified order.
  • The search UI enhancements are implemented according to the specified requirements.
  • The search results are displayed in separate sections for Tokens, NFTs, and Addresses.
  • Clickable navigation tabs are added to switch between the Token and NFT sections.
  • Search results include the specified elements (icon, contract name, price, contract address) when available.
  • Token results are prioritized based on the curated frontend token list, verified contracts, and regular contracts.
  • The search input field handles various search types and provides real-time suggestions or autocomplete functionality.
  • Loading and error states are properly handled and displayed in the UI.
  • Thorough testing has been conducted to ensure the search UI integrates correctly with the updated search API.
@pmjanus pmjanus added 🎨 Needs Design A design solution is needed for part or all of the issue. 🔬 Needs Refinement Further information is required labels Feb 23, 2024
@Viterbo Viterbo self-assigned this Jul 9, 2024
@rozzaswap rozzaswap changed the title Search Bar Redesign [Epic] - Search Bar Redesign Jul 10, 2024
@rozzaswap rozzaswap changed the title [Epic] - Search Bar Redesign [EPIC]: Search Bar Redesign Jul 10, 2024
@pmjanus pmjanus closed this as completed Aug 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🎨 Needs Design A design solution is needed for part or all of the issue. 🔬 Needs Refinement Further information is required
Projects
None yet
Development

No branches or pull requests

2 participants