Skip to content

Conversation

@kumaryash90
Copy link
Member

@kumaryash90 kumaryash90 commented Dec 20, 2024

TOOL-2814

Problem solved

Short description of the bug fixed or feature added


PR-Codex overview

This PR refactors the useCustomFactoryAbi function in the hooks.ts file to improve contract retrieval logic and enhance type imports.

Detailed summary

  • Changed import of ThirdwebContract to a type-only import.
  • Moved getContract and resolveContractAbi to a single import statement.
  • Updated useMemo logic to directly handle contract retrieval within the useQuery.
  • Changed query key to include contractAddress and chainId.
  • Modified enabled condition to check for both contractAddress and chainId.

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

@kumaryash90 kumaryash90 requested review from a team and jakubkrehel as code owners December 20, 2024 10:38
@changeset-bot
Copy link

changeset-bot bot commented Dec 20, 2024

⚠️ No Changeset found

Latest commit: 5f8e570

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

@vercel
Copy link

vercel bot commented Dec 20, 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 20, 2024 7:12pm
3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
docs-v2 ⬜️ Skipped (Inspect) Dec 20, 2024 7:12pm
thirdweb_playground ⬜️ Skipped (Inspect) Dec 20, 2024 7:12pm
wallet-ui ⬜️ Skipped (Inspect) Dec 20, 2024 7:12pm

@graphite-app
Copy link
Contributor

graphite-app bot commented Dec 20, 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.

@github-actions github-actions bot added the Dashboard Involves changes to the Dashboard. label Dec 20, 2024
@kumaryash90 kumaryash90 changed the title Fix custom factory publish form [Dashboard] Fix custom factory publish form Dec 20, 2024
@codecov
Copy link

codecov bot commented Dec 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 53.34%. Comparing base (cb66be4) to head (5f8e570).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5819   +/-   ##
=======================================
  Coverage   53.34%   53.34%           
=======================================
  Files        1101     1101           
  Lines       59124    59124           
  Branches     4825     4825           
=======================================
  Hits        31541    31541           
  Misses      26864    26864           
  Partials      719      719           
Flag Coverage Δ *Carryforward flag
legacy_packages 65.68% <ø> (ø) Carriedforward from cb66be4
packages 50.56% <ø> (ø)

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

@github-actions
Copy link
Contributor

github-actions bot commented Dec 20, 2024

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 45.02 KB (0%) 901 ms (0%) 736 ms (+96.88% 🔺) 1.7 s
thirdweb (cjs) 110.76 KB (0%) 2.3 s (0%) 965 ms (+0.39% 🔺) 3.2 s
thirdweb (minimal + tree-shaking) 5.58 KB (0%) 112 ms (0%) 138 ms (+314.58% 🔺) 250 ms
thirdweb/chains (tree-shaking) 506 B (0%) 10 ms (0%) 11 ms (-57.38% 🔽) 21 ms
thirdweb/react (minimal + tree-shaking) 19.1 KB (0%) 383 ms (0%) 111 ms (+18.05% 🔺) 493 ms

@kumaryash90 kumaryash90 requested a review from jnsdls December 20, 2024 10:48
@MananTank MananTank changed the title [Dashboard] Fix custom factory publish form [TOOL-2814] Fix custom factory publish form Dec 20, 2024
@linear
Copy link

linear bot commented Dec 20, 2024

@graphite-app
Copy link
Contributor

graphite-app bot commented Dec 20, 2024

Merge activity

TOOL-2814

## Problem solved

Short description of the bug fixed or feature added

<!-- start pr-codex -->

---

## PR-Codex overview
This PR refactors the `useCustomFactoryAbi` function in `hooks.ts` to improve contract handling and query logic. It changes how the contract is retrieved and updates the query's enabled condition.

### Detailed summary
- Changed import statements for `ThirdwebContract` and `getContract`.
- Refactored the `contract` retrieval logic to be more concise.
- Updated `queryKey` to include `contractAddress` and `chainId`.
- Modified the `enabled` condition to check for `contractAddress` and `chainId`.

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

<!-- end pr-codex -->
@jnsdls jnsdls force-pushed the yash/fix-custom-factory-publish-form branch from b767f93 to 5f8e570 Compare December 20, 2024 19:09
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground December 20, 2024 19:09 Inactive
@vercel vercel bot temporarily deployed to Preview – docs-v2 December 20, 2024 19:09 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui December 20, 2024 19:09 Inactive
@graphite-app graphite-app bot merged commit 5f8e570 into main Dec 20, 2024
32 checks passed
@graphite-app graphite-app bot deleted the yash/fix-custom-factory-publish-form branch December 20, 2024 19:13
@vercel vercel bot temporarily deployed to Production – wallet-ui December 20, 2024 19:13 Inactive
@vercel vercel bot temporarily deployed to Production – docs-v2 December 20, 2024 19:13 Inactive
@vercel vercel bot temporarily deployed to Production – thirdweb_playground December 20, 2024 19:13 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.

3 participants