Skip to content

Conversation

@gregfromstl
Copy link
Contributor

@gregfromstl gregfromstl commented Dec 1, 2024

PR-Codex overview

This PR focuses on updating the thirdweb and @thirdweb-dev/service-utils packages, introducing new functionalities for converting fiat to crypto and vice versa, while also improving transaction handling and UI components.

Detailed summary

  • Bump thirdweb version to 5.72.0 and @thirdweb-dev/service-utils to 0.4.51.
  • Add convertFiatToCrypto and convertCryptoToFiat functions.
  • Handle 0 value for maxPriorityFeePerGas in transactions.
  • Update various UI components to improve consistency.
  • Introduce promptTokens and completionTokens fields in usage tracking.
  • Update changelogs for both packages.

The following files were skipped due to too many changes: packages/thirdweb/src/adapters/ethers5.test.ts, packages/thirdweb/src/pay/convert/fiatToCrypto.ts, packages/thirdweb/src/pay/convert/cryptoToFiat.ts, apps/dashboard/src/app/(dashboard)/(chain)/[chain_id]/[contractAddress]/_components/claim-conditions/snapshot-upload.tsx, packages/thirdweb/src/transaction/serialize-transaction.ts, apps/portal/src/app/engine/features/backend-wallets/page.mdx, packages/thirdweb/src/transaction/serialize-transaction.test.ts

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

MananTank and others added 2 commits December 1, 2024 18:15
Fixes: DASH-487

<!-- start pr-codex -->

---

## PR-Codex overview
This PR focuses on updating references to smart contract interaction links throughout the application, simplifying the URLs to point directly to `/contracts` instead of specific interaction overview pages.

### Detailed summary
- Updated `href` in `page.tsx` from `/contracts/interact/overview` to `/contracts`.
- Changed references in `interact-blockchain/page.mdx` to point to `/contracts`.
- Modified links in `contracts/page.mdx` to `/contracts`.
- Adjusted links in `sdk.tsx` to `https://portal.thirdweb.com/contracts`.
- Updated SDK documentation links in `ipfs/page.mdx` to `/contracts`.
- Changed SDK references in `gas/page.mdx` to `/contracts`.
- Updated redirects in `redirects.mjs` for `/sdk`, `/sdk/how-it-works`, and `/sdk/getting-started` to `/contracts`.

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

<!-- end pr-codex -->
@linear
Copy link

linear bot commented Dec 1, 2024

@changeset-bot
Copy link

changeset-bot bot commented Dec 1, 2024

⚠️ No Changeset found

Latest commit: f200de3

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

@gregfromstl gregfromstl self-assigned this Dec 1, 2024
@vercel
Copy link

vercel bot commented Dec 1, 2024

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

Name Status Preview Comments Updated (UTC)
docs-v2 ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 2, 2024 5:43pm
thirdweb_playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 2, 2024 5:43pm
thirdweb-www ❌ Failed (Inspect) Dec 2, 2024 5:43pm
wallet-ui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 2, 2024 5:43pm

@graphite-app
Copy link
Contributor

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

@gregfromstl gregfromstl marked this pull request as draft December 1, 2024 23:21
@github-actions
Copy link
Contributor

github-actions bot commented Dec 1, 2024

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 47.17 KB (-2.01% 🔽) 944 ms (-2.01% 🔽) 4 s (+64.57% 🔺) 4.9 s
thirdweb (cjs) 111.8 KB (+2.92% 🔺) 2.3 s (+2.92% 🔺) 6.8 s (-0.79% 🔽) 9 s
thirdweb (minimal + tree-shaking) 5.58 KB (0%) 112 ms (0%) 195 ms (-9.99% 🔽) 307 ms
thirdweb/chains (tree-shaking) 506 B (0%) 10 ms (0%) 53 ms (+40.98% 🔺) 63 ms
thirdweb/react (minimal + tree-shaking) 18.47 KB (0%) 370 ms (0%) 367 ms (-47.23% 🔽) 736 ms

kien-ngo and others added 3 commits December 2, 2024 11:45
part of DASH-388

<!-- start pr-codex -->

---

## PR-Codex overview
This PR focuses on updating the return types in the `convertFiatToCrypto` and `convertCryptoToFiat` functions to return objects instead of plain numbers. Additionally, it modifies the `SnapshotUpload` component to replace `Link` elements with `a` tags and adjusts the layout for better styling.

### Detailed summary
- Changed return type of `convertFiatToCrypto` to `{ result: 0.0000057 }`.
- Changed return type of `convertCryptoToFiat` to `{ result: 3404.11 }`.
- Replaced `Link` components with `a` tags in `SnapshotUpload`.
- Adjusted layout and styling in `SnapshotUpload` for improved design.

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

<!-- end pr-codex -->
@codecov
Copy link

codecov bot commented Dec 2, 2024

Codecov Report

Attention: Patch coverage is 81.81818% with 50 lines in your changes missing coverage. Please review.

Please upload report for BASE (5-dot-ox@bfb53cb). Learn more about missing BASE report.

Files with missing lines Patch % Lines
packages/thirdweb/src/transaction/utils.ts 8.33% 22 Missing ⚠️
.../thirdweb/src/transaction/serialize-transaction.ts 88.63% 10 Missing ⚠️
...nsaction/actions/zksync/send-eip712-transaction.ts 0.00% 5 Missing ⚠️
packages/thirdweb/src/pay/convert/cryptoToFiat.ts 92.30% 4 Missing ⚠️
packages/thirdweb/src/pay/convert/fiatToCrypto.ts 92.00% 4 Missing ⚠️
.../thirdweb/src/utils/any-evm/keyless-transaction.ts 90.90% 3 Missing ⚠️
packages/thirdweb/src/adapters/ethers6.ts 0.00% 1 Missing ⚠️
...react/core/hooks/transaction/useSendTransaction.ts 50.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             5-dot-ox    #5546   +/-   ##
===========================================
  Coverage            ?   46.77%           
===========================================
  Files               ?     1083           
  Lines               ?    58888           
  Branches            ?     4019           
===========================================
  Hits                ?    27544           
  Misses              ?    30659           
  Partials            ?      685           
Flag Coverage Δ *Carryforward flag
legacy_packages 65.68% <ø> (?) Carriedforward from 4ae50f5
packages 42.48% <81.81%> (?)

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

Files with missing lines Coverage Δ
packages/thirdweb/src/adapters/ethers5.ts 53.84% <100.00%> (ø)
packages/thirdweb/src/pay/utils/definitions.ts 61.29% <100.00%> (ø)
...i/ConnectWallet/screens/Buy/main/useBuyTxStates.ts 9.40% <100.00%> (ø)
.../transaction/actions/gasless/providers/biconomy.ts 57.94% <100.00%> (ø)
...rc/transaction/actions/gasless/providers/engine.ts 36.99% <ø> (ø)
...nsaction/actions/gasless/providers/openzeppelin.ts 49.61% <ø> (ø)
...irdweb/src/transaction/actions/sign-transaction.ts 100.00% <100.00%> (ø)
...transaction/actions/to-serializable-transaction.ts 78.26% <100.00%> (ø)
.../src/transaction/actions/zksync/getEip721Domain.ts 6.15% <ø> (ø)
packages/thirdweb/src/wallets/private-key.ts 100.00% <100.00%> (ø)
... and 9 more

@github-actions github-actions bot added Dashboard Involves changes to the Dashboard. Portal Involves changes to the Portal (docs) codebase. labels Dec 2, 2024
@gregfromstl gregfromstl marked this pull request as ready for review December 2, 2024 17:44
@gregfromstl gregfromstl merged commit 93f0941 into 5-dot-ox Dec 2, 2024
27 of 29 checks passed
@gregfromstl gregfromstl deleted the greg/cnct-2303-viem-ox-transaction-envelopes branch December 2, 2024 17:44
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. packages Portal Involves changes to the Portal (docs) codebase. SDK Involves changes to the thirdweb SDK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants