Skip to content

Conversation

@MananTank
Copy link
Member

@MananTank MananTank commented Sep 3, 2025


PR-Codex overview

This PR focuses on removing the specifiedWallets property from various components related to wallet selection, simplifying the filtering logic in the AllWalletsUI component.

Detailed summary

  • Removed specifiedWallets prop from WalletAuth.tsx.
  • Removed specifiedWallets prop from ConnectModalContent.tsx.
  • Removed specifiedWallets type declaration from AllWalletsUI.tsx.
  • Simplified wallet filtering logic in AllWalletsUI to exclude certain wallet IDs.

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

Summary by CodeRabbit

  • Refactor
    • Standardized the wallet selection list across the Connect modal and in-app authentication to ensure a consistent user experience.
    • Removed custom list filtering so parent-supplied wallet subsets no longer change the displayed options.
    • The “All Wallets” view now consistently excludes in-app, embedded, and smart wallet types, simplifying selection and reducing unexpected variations.

@vercel
Copy link

vercel bot commented Sep 3, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
docs-v2 Ready Ready Preview Comment Sep 3, 2025 5:52pm
nebula Ready Ready Preview Comment Sep 3, 2025 5:52pm
thirdweb_playground Ready Ready Preview Comment Sep 3, 2025 5:52pm
thirdweb-www Ready Ready Preview Comment Sep 3, 2025 5:52pm
wallet-ui Ready Ready Preview Comment Sep 3, 2025 5:52pm

@linear
Copy link

linear bot commented Sep 3, 2025

@changeset-bot
Copy link

changeset-bot bot commented Sep 3, 2025

⚠️ No Changeset found

Latest commit: dbb2614

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

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 3, 2025

Walkthrough

Removed specifiedWallets from AllWalletsUI's public API and from its call sites. AllWalletsUI now builds a static wallet list on mount by filtering walletInfos to exclude ids "inApp", "embedded", and "smart". ConnectModalContent and WalletAuth no longer pass specifiedWallets.

Changes

Cohort / File(s) Summary of Changes
AllWalletsUI API and filtering
packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx
Removed specifiedWallets prop from function signature and public API; walletList now derived from walletInfos excluding ids "inApp", "embedded", "smart"; memoized with an empty dependency array.
Connect modal integrations
packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectModalContent.tsx, packages/thirdweb/src/react/web/wallets/in-app/WalletAuth.tsx
Removed specifiedWallets={...} when rendering AllWalletsUI; no other control-flow changes.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor User
  participant ConnectModal as ConnectModalContent / WalletAuth
  participant AllWalletsUI
  participant WalletData as walletInfos

  User->>ConnectModal: Open "All wallets"
  ConnectModal->>AllWalletsUI: Render (without specifiedWallets)
  AllWalletsUI->>WalletData: Load walletInfos
  Note over AllWalletsUI,WalletData #EFE8D8: Filter out ids: "inApp", "embedded", "smart"
  WalletData-->>AllWalletsUI: walletList (static, memoized on mount)
  AllWalletsUI-->>User: Display list and handle search
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Assessment against linked issues

Objective Addressed Explanation
BLD-228: Fix search in All wallets to include wallets also listed as popular (BLD-228)

Assessment against linked issues: Out-of-scope changes

Code Change Explanation
Changed walletList memoization to use an empty dependency array (packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx) This makes the wallet list static on mount and may prevent updates when props change; not specified as an objective in BLD-228.

Warning

Review ran into problems

🔥 Problems

Errors were encountered while retrieving linked issues.

Errors (1)
  • TEAM-0000: Entity not found: Issue - Could not find referenced Issue.

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between cf8f80b and dbb2614.

📒 Files selected for processing (3)
  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx (1 hunks)
  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectModalContent.tsx (0 hunks)
  • packages/thirdweb/src/react/web/wallets/in-app/WalletAuth.tsx (0 hunks)
💤 Files with no reviewable changes (2)
  • packages/thirdweb/src/react/web/wallets/in-app/WalletAuth.tsx
  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectModalContent.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: E2E Tests (pnpm, webpack)
  • GitHub Check: E2E Tests (pnpm, vite)
  • GitHub Check: Unit Tests
  • GitHub Check: E2E Tests (pnpm, esbuild)
  • GitHub Check: Size
  • GitHub Check: Build Packages
  • GitHub Check: Lint Packages
  • GitHub Check: Analyze (javascript)
✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch 09-03-_bld-228_sdk_react_do_not_exclude_specified_wallets_from_all_wallets_list_in_connect_ui

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore or @coderabbit ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@github-actions github-actions bot added packages SDK Involves changes to the thirdweb SDK labels Sep 3, 2025
Copy link
Member Author


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.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (2)
packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx (2)

41-45: Centralize excluded wallet ids; current change fixes the bug but hard-codes ids inline

Good call removing specifiedWallets so “All wallets” truly includes wallets also shown in recommended. Replace the inline id checks with a shared Set for readability and easier maintenance.

Manual QA: In the playground, ensure searching for a wallet that appears in “Popular/Recommended” now also returns it under “All wallets”.

Apply this diff locally:

-  return walletInfos.filter(
-    (info) =>
-      info.id !== "inApp" && info.id !== "embedded" && info.id !== "smart",
-  );
+  return walletInfos.filter((info) => !EXCLUDED_WALLET_IDS.has(info.id));

Add this near the top of the file (or in a shared constants module if one exists):

const EXCLUDED_WALLET_IDS = new Set(["inApp", "embedded", "smart"]);

63-69: Preserve Fuse ranking when searching; sort only for the non-search case

Re-sorting after Fuse can surface “recommended” above best matches and subtly regress search quality. Gate sort by search presence.

-const walletInfosToShow = useMemo(() => {
-  return sortWallets(searchResults.slice(0, itemsToShow));
-}, [searchResults, itemsToShow]);
+const walletInfosToShow = useMemo(() => {
+  const sliced = searchResults.slice(0, itemsToShow);
+  return deferredSearchTerm ? sliced : sortWallets(sliced);
+}, [searchResults, itemsToShow, deferredSearchTerm]);
📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between b8f4966 and cf8f80b.

📒 Files selected for processing (3)
  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx (1 hunks)
  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectModalContent.tsx (0 hunks)
  • packages/thirdweb/src/react/web/wallets/in-app/WalletAuth.tsx (0 hunks)
💤 Files with no reviewable changes (2)
  • packages/thirdweb/src/react/web/wallets/in-app/WalletAuth.tsx
  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/ConnectModalContent.tsx
🧰 Additional context used
📓 Path-based instructions (3)
**/*.{ts,tsx}

📄 CodeRabbit inference engine (CLAUDE.md)

**/*.{ts,tsx}: Write idiomatic TypeScript with explicit function declarations and return types
Limit each file to one stateless, single-responsibility function for clarity
Re-use shared types from @/types or local types.ts barrels
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Choose composition over inheritance; leverage utility types (Partial, Pick, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose

**/*.{ts,tsx}: Use explicit function declarations and explicit return types in TypeScript
Limit each file to one stateless, single‑responsibility function
Re‑use shared types from @/types where applicable
Prefer type aliases over interface except for nominal shapes
Avoid any and unknown unless unavoidable; narrow generics when possible
Prefer composition over inheritance; use utility types (Partial, Pick, etc.)
Lazy‑import optional features and avoid top‑level side‑effects to reduce bundle size

Files:

  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx
**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (CLAUDE.md)

Load heavy dependencies inside async paths to keep initial bundle lean (lazy loading)

Files:

  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx
packages/thirdweb/**/*.{ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

packages/thirdweb/**/*.{ts,tsx}: Every public symbol must have comprehensive TSDoc with at least one compiling @example and a custom tag (@beta, @internal, @experimental, etc.)
Comment only ambiguous logic; avoid restating TypeScript in prose
Lazy‑load heavy dependencies inside async paths (e.g., const { jsPDF } = await import("jspdf"))

Files:

  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx
🧠 Learnings (2)
📓 Common learnings
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T19:19:55.613Z
Learning: Applies to packages/thirdweb/src/wallets/** : Unified `Wallet` and `Account` interfaces in wallet architecture
Learnt from: CR
PR: thirdweb-dev/js#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T19:19:55.613Z
Learning: Applies to packages/thirdweb/src/wallets/** : Support for in-app wallets (social/email login)
📚 Learning: 2025-07-18T19:20:32.530Z
Learnt from: CR
PR: thirdweb-dev/js#0
File: .cursor/rules/dashboard.mdc:0-0
Timestamp: 2025-07-18T19:20:32.530Z
Learning: Applies to dashboard/**/*client.tsx : Interactive UI that relies on hooks (`useState`, `useEffect`, React Query, wallet hooks).

Applied to files:

  • packages/thirdweb/src/react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: Size
  • GitHub Check: Unit Tests
  • GitHub Check: Lint Packages
  • GitHub Check: Analyze (javascript)

@github-actions
Copy link
Contributor

github-actions bot commented Sep 3, 2025

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 64.01 KB (0%) 1.3 s (0%) 231 ms (+187.22% 🔺) 1.6 s
thirdweb (cjs) 357.32 KB (0%) 7.2 s (0%) 716 ms (+17.67% 🔺) 7.9 s
thirdweb (minimal + tree-shaking) 5.73 KB (0%) 115 ms (0%) 88 ms (+1708.29% 🔺) 202 ms
thirdweb/chains (tree-shaking) 526 B (0%) 11 ms (0%) 80 ms (+5508.46% 🔺) 90 ms
thirdweb/react (minimal + tree-shaking) 19.15 KB (0%) 383 ms (0%) 81 ms (+604.45% 🔺) 464 ms

@codecov
Copy link

codecov bot commented Sep 3, 2025

Codecov Report

❌ Patch coverage is 0% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 56.54%. Comparing base (b8f4966) to head (dbb2614).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
.../react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx 0.00% 5 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7974      +/-   ##
==========================================
+ Coverage   56.52%   56.54%   +0.01%     
==========================================
  Files         904      904              
  Lines       58633    58626       -7     
  Branches     4147     4148       +1     
==========================================
+ Hits        33144    33149       +5     
+ Misses      25383    25371      -12     
  Partials      106      106              
Flag Coverage Δ
packages 56.54% <0.00%> (+0.01%) ⬆️
Files with missing lines Coverage Δ
...web/ui/ConnectWallet/Modal/ConnectModalContent.tsx 9.37% <ø> (+0.04%) ⬆️
...irdweb/src/react/web/wallets/in-app/WalletAuth.tsx 10.06% <ø> (+0.06%) ⬆️
.../react/web/ui/ConnectWallet/Modal/AllWalletsUI.tsx 14.28% <0.00%> (+0.44%) ⬆️

... and 2 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@graphite-app
Copy link
Contributor

graphite-app bot commented Sep 3, 2025

Merge activity

…s list in Connect UI (#7974)

<!--

## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes"

If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000):

## Notes for the reviewer

Anything important to call out? Be sure to also clarify these in your comments.

## How to test

Unit tests, playground, etc.

-->

<!-- start pr-codex -->

---

## PR-Codex overview
This PR focuses on removing the `specifiedWallets` prop from various components related to wallet selection in the `thirdweb` package, streamlining the wallet filtering logic.

### Detailed summary
- Removed `specifiedWallets` prop from the `WalletAuth` component.
- Updated `ConnectModalContent` to remove `specifiedWallets` and utilize `recommendedWallets`.
- Modified `AllWalletsUI` to eliminate `specifiedWallets` and simplify wallet filtering logic.

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

<!-- end pr-codex -->

<!-- This is an auto-generated comment: release notes by coderabbit.ai -->

## Summary by CodeRabbit

- Refactor
  - Simplified the wallet selection list to a standardized set across the Connect modal and in-app auth.
  - Removed custom list filtering, ensuring a consistent experience regardless of entry point.
  - The list now excludes in-app, embedded, and smart wallets from the “All Wallets” view.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
@graphite-app graphite-app bot force-pushed the 09-03-_bld-228_sdk_react_do_not_exclude_specified_wallets_from_all_wallets_list_in_connect_ui branch from cf8f80b to dbb2614 Compare September 3, 2025 17:44
@graphite-app graphite-app bot merged commit dbb2614 into main Sep 3, 2025
23 of 24 checks passed
@graphite-app graphite-app bot deleted the 09-03-_bld-228_sdk_react_do_not_exclude_specified_wallets_from_all_wallets_list_in_connect_ui branch September 3, 2025 17:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

packages SDK Involves changes to the thirdweb SDK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants