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

[Dashboard] Add a form to let user manually input data for Marketplace listings #5654

Merged
merged 1 commit into from
Dec 16, 2024

Conversation

kien-ngo
Copy link
Contributor

@kien-ngo kien-ngo commented Dec 9, 2024

Problem solved

Short description of the bug fixed or feature added


PR-Codex overview

This PR enhances the CreateListingButton and CreateListingsForm components to support different listing modes for NFTs. It introduces manual input for NFT contract addresses and token IDs, and integrates checks for supported chains and NFT types.

Detailed summary

  • Added TabButtons for listing modes: "Select NFT" and "Manual".
  • Implemented state management for listingMode in CreateListingButton.
  • Conditional rendering of CreateListingsForm based on listingMode.
  • Enhanced CreateListingsForm to handle manual NFT entry.
  • Included checks for NFT type (ERC721 or ERC1155) in manual mode.
  • Updated approval logic for NFTs based on selected contract and token ID.
  • Adjusted error handling and user feedback messages.

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Copy link

changeset-bot bot commented Dec 9, 2024

⚠️ No Changeset found

Latest commit: d8f9575

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

vercel bot commented Dec 9, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
thirdweb-www ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 16, 2024 4:49pm
3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
docs-v2 ⬜️ Skipped (Inspect) Dec 16, 2024 4:49pm
thirdweb_playground ⬜️ Skipped (Inspect) Dec 16, 2024 4:49pm
wallet-ui ⬜️ Skipped (Inspect) Dec 16, 2024 4:49pm

@vercel vercel bot temporarily deployed to Preview – docs-v2 December 9, 2024 04:16 Inactive
Copy link

graphite-app bot commented Dec 9, 2024

Your org has enabled the Graphite merge queue for merging into main

Add the label “merge-queue” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix.

You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link.

@vercel vercel bot temporarily deployed to Preview – thirdweb_playground December 9, 2024 04:16 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui December 9, 2024 04:16 Inactive
@github-actions github-actions bot added the Dashboard Involves changes to the Dashboard. label Dec 9, 2024
Copy link
Contributor Author

kien-ngo commented Dec 9, 2024


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • merge-queue - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@vercel vercel bot temporarily deployed to Preview – wallet-ui December 9, 2024 04:17 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground December 9, 2024 04:17 Inactive
@vercel vercel bot temporarily deployed to Preview – docs-v2 December 9, 2024 04:17 Inactive
@kien-ngo kien-ngo marked this pull request as ready for review December 9, 2024 04:17
Copy link

codecov bot commented Dec 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 53.01%. Comparing base (6994310) to head (7819e1e).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5654   +/-   ##
=======================================
  Coverage   53.01%   53.01%           
=======================================
  Files        1101     1101           
  Lines       59079    59079           
  Branches     4806     4806           
=======================================
  Hits        31318    31318           
  Misses      27043    27043           
  Partials      718      718           
Flag Coverage Δ *Carryforward flag
legacy_packages 65.68% <ø> (ø) Carriedforward from 6994310
packages 50.14% <ø> (ø)

*This pull request uses carry forward flags. Click here to find out more.

@vercel vercel bot temporarily deployed to Preview – docs-v2 December 9, 2024 04:20 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui December 9, 2024 04:20 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground December 9, 2024 04:20 Inactive
Copy link
Contributor

github-actions bot commented Dec 9, 2024

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 44.94 KB (0%) 899 ms (0%) 3.6 s (+21.51% 🔺) 4.5 s
thirdweb (cjs) 110.78 KB (0%) 2.3 s (0%) 5.6 s (-10.73% 🔽) 7.9 s
thirdweb (minimal + tree-shaking) 5.58 KB (0%) 112 ms (0%) 319 ms (+85.22% 🔺) 430 ms
thirdweb/chains (tree-shaking) 506 B (0%) 10 ms (0%) 73 ms (-29.02% 🔽) 83 ms
thirdweb/react (minimal + tree-shaking) 19.03 KB (0%) 381 ms (0%) 961 ms (+48.39% 🔺) 1.4 s

Copy link

graphite-app bot commented Dec 16, 2024

Merge activity

…e listings (#5654)

## Problem solved

Short description of the bug fixed or feature added

<!-- start pr-codex -->

---

## PR-Codex overview
This PR enhances the `CreateListingButton` and `CreateListingsForm` components by adding support for multiple listing modes (automatic and manual) and improving NFT validation logic, ensuring users can list NFTs more effectively based on the selected mode.

### Detailed summary
- Introduced `LISTING_MODES` for "Select NFT" and "Manual" modes.
- Added logic to toggle between automatic and manual listing modes.
- Enhanced NFT validation for manual mode, including contract address and token ID checks.
- Updated NFT approval checks based on listing mode.
- Modified form controls and error handling for improved user experience.

> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}`

<!-- end pr-codex -->
@vercel vercel bot temporarily deployed to Preview – wallet-ui December 16, 2024 16:47 Inactive
@vercel vercel bot temporarily deployed to Preview – docs-v2 December 16, 2024 16:47 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground December 16, 2024 16:47 Inactive
@graphite-app graphite-app bot merged commit 7819e1e into main Dec 16, 2024
31 checks passed
@graphite-app graphite-app bot deleted the kien/dash-350 branch December 16, 2024 16:50
@vercel vercel bot temporarily deployed to Production – wallet-ui December 16, 2024 16:50 Inactive
@vercel vercel bot temporarily deployed to Production – docs-v2 December 16, 2024 16:50 Inactive
@vercel vercel bot temporarily deployed to Production – thirdweb_playground December 16, 2024 16:50 Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Dashboard Involves changes to the Dashboard.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants