Skip to content

Conversation

@MananTank
Copy link
Member

@MananTank MananTank commented Jan 22, 2025

PR-Codex overview

This PR focuses on improving the functionality and user experience of the TeamProjectsPage component by adding total connections to projects, updating the CopyTextButton, and refining project sorting and filtering.

Detailed summary

  • Updated tooltip type in CopyTextButton to string | undefined.
  • Changed API fetch limit from 10 to 7 in getChangelog.
  • Replaced cookie-based token retrieval with getAuthToken in getProjects.
  • Added getProjectsWithTotalWallets to calculate total connections for projects.
  • Updated TeamProjectsPage to use ProjectWithTotalConnections type.
  • Enhanced sorting functionality to include totalConnections.
  • Adjusted project display to show total users instead of publishable key.
  • Replaced CopyButton with CopyTextButton in ProjectCard.

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

@linear
Copy link

linear bot commented Jan 22, 2025

@vercel
Copy link

vercel bot commented Jan 22, 2025

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 Jan 22, 2025 11:38pm
3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
docs-v2 ⬜️ Skipped (Inspect) Jan 22, 2025 11:38pm
thirdweb_playground ⬜️ Skipped (Inspect) Jan 22, 2025 11:38pm
wallet-ui ⬜️ Skipped (Inspect) Jan 22, 2025 11:38pm

@vercel vercel bot temporarily deployed to Preview – wallet-ui January 22, 2025 17:47 Inactive
@vercel vercel bot temporarily deployed to Preview – docs-v2 January 22, 2025 17:47 Inactive
@changeset-bot
Copy link

changeset-bot bot commented Jan 22, 2025

⚠️ No Changeset found

Latest commit: feb4fd0

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 vercel bot temporarily deployed to Preview – thirdweb_playground January 22, 2025 17:47 Inactive
@github-actions github-actions bot added the Dashboard Involves changes to the Dashboard. label Jan 22, 2025
@MananTank MananTank marked this pull request as ready for review January 22, 2025 17:47
@MananTank MananTank requested review from a team as code owners January 22, 2025 17:47
Copy link
Member Author

MananTank commented Jan 22, 2025


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.

@codecov
Copy link

codecov bot commented Jan 22, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 54.89%. Comparing base (1d8695e) to head (feb4fd0).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #6026   +/-   ##
=======================================
  Coverage   54.89%   54.89%           
=======================================
  Files        1151     1151           
  Lines       61210    61210           
  Branches     5167     5167           
=======================================
  Hits        33600    33600           
  Misses      26882    26882           
  Partials      728      728           
Flag Coverage Δ *Carryforward flag
legacy_packages 65.68% <ø> (ø) Carriedforward from 1d8695e
packages 52.56% <ø> (ø)

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

@github-actions
Copy link
Contributor

github-actions bot commented Jan 22, 2025

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 46.71 KB (0%) 935 ms (0%) 3.1 s (+43.83% 🔺) 4.1 s
thirdweb (cjs) 116.78 KB (0%) 2.4 s (0%) 6.4 s (+15.39% 🔺) 8.8 s
thirdweb (minimal + tree-shaking) 5.59 KB (0%) 112 ms (0%) 432 ms (+0.29% 🔺) 544 ms
thirdweb/chains (tree-shaking) 506 B (0%) 10 ms (0%) 68 ms (-32.33% 🔽) 78 ms
thirdweb/react (minimal + tree-shaking) 19.22 KB (0%) 385 ms (0%) 930 ms (+49.82% 🔺) 1.4 s

);
}

async function getProjectsWithTotalWallets(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isn't this going to slow down the page load quite significantly?

Copy link
Member Author

@MananTank MananTank Jan 22, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That was my concern as well - but it seems to be pretty quick ( tested with ~15 projects )

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what about with projects that have 100k+ wallets in them?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The total wallets query is aggregated by walletType - returned response array only includes one object per unique wallet type - so the response size won't be huge

Let me check with @gregfromstl If it that scenario involves significantly more processing time in analytics server ( afaik - its already preprocessed )

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's preprocessed up to the day. So you'll be aggregating as many rows as there are days in the time period.

{truncate(project.publishableKey, 32)}
<p className="flex items-center gap-1 text-muted-foreground text-sm">
<span>{project.totalConnections}</span>
Total wallet connections
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Total Users

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated

@graphite-app
Copy link
Contributor

graphite-app bot commented Jan 22, 2025

Merge activity

<!-- start pr-codex -->

## PR-Codex overview
This PR focuses on enhancing the `CopyTextButton` component, optimizing the project fetching logic, and improving project display features by integrating total wallet connections in the dashboard.

### Detailed summary
- Changed `tooltip` type in `CopyTextButton` to `string | undefined`.
- Updated the API call in `getChangelog` to limit results to 7.
- Replaced cookie-based token retrieval with `getAuthToken` in `getProjects`.
- Added `getProjectsWithTotalWallets` to calculate total wallet connections.
- Updated `TeamProjectsPage` to display projects with total connections.
- Modified sorting logic in `TeamProjectsPage` to include total connections.
- Replaced `CopyButton` with `CopyTextButton` in `ProjectCard`.
- Enhanced project display to show total users.

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

<!-- end pr-codex -->
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground January 22, 2025 23:30 Inactive
@vercel vercel bot temporarily deployed to Preview – docs-v2 January 22, 2025 23:30 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui January 22, 2025 23:30 Inactive
@graphite-app graphite-app bot merged commit feb4fd0 into main Jan 22, 2025
32 checks passed
@graphite-app graphite-app bot deleted the TOOL-3123 branch January 22, 2025 23:38
@vercel vercel bot temporarily deployed to Production – docs-v2 January 22, 2025 23:38 Inactive
@vercel vercel bot temporarily deployed to Production – wallet-ui January 22, 2025 23:38 Inactive
@vercel vercel bot temporarily deployed to Production – thirdweb_playground January 22, 2025 23:38 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.

5 participants