Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
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
5 changes: 5 additions & 0 deletions .changeset/apple-profile-name-picture.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"thirdweb": minor
---

Add optional `name` and `picture` fields to `Profile` type to support additional OAuth provider data (Google, Apple, etc.). The UI now displays the user's name when available from OAuth providers, improving Apple Sign In compliance.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ import { MenuButton } from "../MenuButton.js";
import type { WalletDetailsModalScreen } from "./types.js";

function getProfileDisplayName(profile: Profile) {
// Prefer name if available (from OAuth providers like Google/Apple)
if (profile.details.name) {
return profile.details.name;
}
Comment on lines +27 to +30
Copy link

Copilot AI Feb 21, 2026

Choose a reason for hiding this comment

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

The new name field handling in getProfileDisplayName looks good and will correctly prioritize the user's full name from OAuth providers. However, there are no test cases added to verify this new behavior. Consider adding a test case that verifies when a profile has both name and email (e.g., for a Google profile), the name is displayed rather than the email address.

Copilot uses AI. Check for mistakes.

switch (true) {
case profile.type === "email" && profile.details.email !== undefined:
return profile.details.email;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@ export type Profile = {
email?: string;
phone?: string;
address?: Address;
name?: string;
picture?: string;
};
};

Expand Down
Loading