-
Notifications
You must be signed in to change notification settings - Fork 538
[SDK] Fix: Add custom title & icon to wagmi connectors #6858
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
Conversation
🦋 Changeset detectedLatest commit: 9a0199f The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
@mmahdigh is attempting to deploy a commit to the thirdweb Team on Vercel. A member of the Team first needs to authorize it. |
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
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. |
Codecov ReportAttention: Patch coverage is
❌ Your patch status has failed because the patch coverage (4.34%) is below the target coverage (80.00%). You can increase the patch coverage or adjust the target coverage.
Additional details and impacted files@@ Coverage Diff @@
## main #6858 +/- ##
===========================================
- Coverage 55.31% 35.51% -19.80%
===========================================
Files 896 893 -3
Lines 57023 56907 -116
Branches 3971 2222 -1749
===========================================
- Hits 31541 20213 -11328
- Misses 25385 36623 +11238
+ Partials 97 71 -26
🚀 New features to boost your workflow:
|
@@ -69,6 +69,7 @@ export type InAppWalletCreationOptions = | |||
* Metadata to display in the Connect Modal | |||
*/ | |||
metadata?: { | |||
name?: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
This is actually useful for our own connect modal too.
Could replace the "social login" default name that we show in the wide modal.
As for the icon, can you actually add a separate prop for it instead of overloading image?
So name / icon / image.
That way we can also use it in the connect modal to let you replace the icon separately to the image that shows above the sign in options.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
did it for you :) merging shortly
@@ -69,6 +69,7 @@ export type InAppWalletCreationOptions = | |||
* Metadata to display in the Connect Modal | |||
*/ | |||
metadata?: { | |||
name?: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
did it for you :) merging shortly
Thank you very much buddy! Lightning-fast reviews and merges 🚀 |
Hi!
I've been trying to use thirdweb's wagmi-adaptor with ConnectKit, but I'm having trouble setting an icon or title for my connectors. So they end up looking like this:
This is my code:
The problem is, ConnectKit looks for the
icon
andname
properties in a connector, but these properties are not set in theinAppWalletConnector
function, so as a result, there's no icon to show, and the wallet's name is always "In-App wallet".PR-Codex overview
This PR focuses on enhancing the
inAppWallet
metadata by adding customizablename
andicon
properties. This allows for better personalization of in-app wallets within the connect modal.Detailed summary
name
andicon
properties toinAppWallet
metadata intypes.ts
.InAppWalletSelectionUI.tsx
to usewallet
object instead ofwalletId
.connector.ts
to retrievename
andicon
from metadata.WalletEntryButton.tsx
to usewallet
object and display custom metadata.AllWalletsUI.tsx
to createwallet
fromwalletInfo.id
.