Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ export type InAppWalletCreationOptions =
* Metadata to display in the Connect Modal
*/
metadata?: {
name?: string;
Copy link
Member

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.

Copy link
Member

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

image?: {
src: string;
width?: number;
Expand Down
3 changes: 2 additions & 1 deletion packages/wagmi-adapter/src/connector.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,9 @@ export function inAppWalletConnector(
const client = args.client;
return createConnector<Provider, Properties, StorageItem>((config) => ({
id: "in-app-wallet",
name: "In-App wallet",
name: args.metadata?.name || "In-App wallet",
type: "in-app",
icon: args.metadata?.image?.src,
connect: async (params) => {
const rawStorage =
typeof window !== "undefined" && window.localStorage
Expand Down
Loading