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/beige-candles-happen.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"thirdweb": patch
---

Added Epic Games Authentication
3 changes: 2 additions & 1 deletion apps/dashboard/src/@/api/team/ecosystems.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ export type AuthOption =
| "steam"
| "apple"
| "coinbase"
| "line";
| "line"
| "epic";

export type Ecosystem = {
name: string;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ const authOptions = [
"apple",
"coinbase",
"line",
"epic",
] as const satisfies AuthOption[];

type AuthOptionsFormData = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ const authMethodsToPickFrom: InAppWalletAuth[] = [
"line",
"x",
"tiktok",
"epic",
"coinbase",
"farcaster",
"telegram",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ const allInAppWalletLoginMethods: InAppWalletAuth[] = [
"line",
"x",
"tiktok",
"epic",
"facebook",
"apple",
"coinbase",
Expand Down
1 change: 1 addition & 0 deletions apps/portal/src/components/Document/AuthList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ const authOptions: InAppWalletAuth[] = [
"facebook",
"x",
"tiktok",
"epic",
"discord",
"telegram",
"twitch",
Expand Down
4 changes: 4 additions & 0 deletions packages/thirdweb/src/react/core/utils/walletIcon.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ describe("walletIcon", () => {
expect(getSocialIcon("tiktok")).toBe(socialIcons.tiktok);
});

it("should return epic icon", () => {
expect(getSocialIcon("epic")).toBe(socialIcons.epic);
});

it("should return farcaster icon", () => {
expect(getSocialIcon("farcaster")).toBe(socialIcons.farcaster);
});
Expand Down
5 changes: 5 additions & 0 deletions packages/thirdweb/src/react/core/utils/walletIcon.ts

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import {
APPLE_ICON,
DISCORD_ICON,
EMAIL_ICON,
EPIC_ICON,
FACEBOOK_ICON,
FARCASTER_ICON,
GITHUB_ICON,
Expand Down Expand Up @@ -106,6 +107,8 @@ export function getAuthProviderImage(authProvider: string | null): string {
return X_ICON;
case "tiktok":
return TIKTOK_ICON;
case "epic":
return EPIC_ICON;
case "farcaster":
return FARCASTER_ICON;
case "telegram":
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ import {
APPLE_ICON,
COINBASE_ICON,
DISCORD_ICON,
EPIC_ICON,
FACEBOOK_ICON,
FARCASTER_ICON,
GITHUB_ICON,
Expand Down Expand Up @@ -69,6 +70,7 @@ const socialIcons = {
twitch: TWITCH_ICON,
x: X_ICON,
tiktok: TIKTOK_ICON,
epic: EPIC_ICON,
};

type InAppWalletFormUIProps = {
Expand Down
5 changes: 5 additions & 0 deletions packages/thirdweb/src/react/native/ui/icons/svgs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,11 @@ export const TIKTOK_ICON = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0
</svg>
`;

export const EPIC_ICON = `<svg width="800px" height="800px" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg">
<circle cx="512" cy="512" r="512" style="fill:#313131"/>
<path d="M331.4 276c-29.3 0-40.1 10.8-40.1 40.1v353.4c0 3.3.1 6.4.4 9.2.7 6.4.8 12.7 6.8 19.7.6.8 6.6 5.2 6.6 5.2 3.2 1.6 5.5 2.7 9.2 4.3l177.8 74.5c9.2 4.2 13.1 5.9 19.8 5.7h.1c6.8.2 10.6-1.5 19.8-5.7l177.8-74.5c3.7-1.5 5.9-2.6 9.2-4.3 0 0 6.1-4.5 6.6-5.2 6-7 6-13.2 6.8-19.7.3-2.8.4-5.9.4-9.2V316c0-29.3-10.8-40-40.1-40H331.4zm285 66.3h14.5c24.2 0 36 11.8 36 36.2v40.1h-29.3v-38.5c0-7.8-3.6-11.5-11.2-11.5h-5c-7.8 0-11.5 3.6-11.5 11.5v124c0 7.8 3.6 11.4 11.5 11.4h5.5c7.5 0 11.1-3.6 11.1-11.4v-44.4h29.4v45.7c0 24.4-12 36.4-36.3 36.4h-14.8c-24.3 0-36.3-12.1-36.3-36.4V378.8c.1-24.4 12.1-36.5 36.4-36.5zm-260 1.6h66.4v27.2h-36.6v55.6h35.2v27.2h-35.2v59.2h37.1v27.2h-66.9V343.9zm81.4 0h46.9c24.3 0 36.3 12.1 36.3 36.5v52.2c0 24.4-12 36.5-36.3 36.5h-16.9v71.2h-29.9l-.1-196.4zm96.6 0h29.8v196.4h-29.8V343.9zm-66.8 26.5v72.3H480c7.5 0 11.1-3.6 11.1-11.5v-49.3c0-7.9-3.6-11.5-11.1-11.5h-12.4zM385.4 587h4.4l1 .1h1.6l.8.3h.8l.8.2.8.2.7.1.7.2.7.1.8.3.6.1.6.3.8.2.6.3.8.3.7.3.6.4.8.3.6.4.8.4.6.4.7.4.6.5.6.4.6.5.7.5.6.6.6.5-.5.6-.6.6-.5.6-.6.6-.5.6-.5.6-.6.6-.5.6-.5.6-.6.6-.5.6-.6.6-.5.6-.5.6-.6.6-.5.7-.6.6-.5.6-.6-.5-.6-.6-.6-.4-.7-.5-.6-.4-.7-.4-.6-.4-.7-.4-.6-.3-.6-.3-.6-.2-.7-.3-.8-.2-.6-.2-.8-.2-.8-.2-.8-.1h-.9l-1-.2h-1.6l-.8.1h-.8l-.8.2-.7.2-.7.2-.8.2-.6.3-.8.3-.6.4-.6.4-.6.4-.6.5-.6.5-.6.5-.5.6-.6.6-.4.6-.4.6-.5.6-.3.7-.4.6-.4.7-.2.7-.3.7-.2.8-.1.8-.2.7-.2.9v.8l-.1.8v1.9l.1.8.1.7.1.8.2.8.2.6.1.8.2.6.3.6.3.8.4.8.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.6-.5-.7-.4-.6-.5-.7-.4-.6-.5-.7-.4-.6-.5-.7-.4-.6-.6-.7-.3-.6-.5-.7-.5-.6-.4-.7-.5-.6-.4-.8-.5-.6-.4-.7-.5-.6-.4-.7-.5-.6-.4-.7-.5-.6-.4-.7-.5-.6-.4-.7-.5-.6-.4-.7-.5-.6-.4-.7-.6-.6-.3-.7-.5-.6v35.1H491v-58.9l-.1-.2zm74 0h46.9v13.4h-31.4v9.5h28.2v12.7h-28.2V634h31.8v13.5H565v-58.9l-.1-.4zm-113.5 18.2-.3.8-.3.6-.3.8-.3.8-.2.7-.3.7-.3.8-.3.8-.2.6-.3.8-.3.6-.3.8-.3.8-.3.6-.2.8-.3.6-.3.8-.6 1.2-.2.6-.3.8-.3.8-.2.6-.3.8h13.7l-.3-.8-.3-.7-.3-.8-.3-.7-.2-.7-.3-.7-.3-.8-.3-.7-.3-.7-.3-.7-.2-.7-.3-.8-.3-.7-.3-.7-.3-.7-.2-.7-.3-.8-.3-.8-.3-.6-.3-.8-.3-.8-.2-.7-.8-1.1zm-24.5 111.4h171l-87.3 28.8-83.7-28.8z" style="fill:#fff"/>
</svg>`;

export const GUEST_ICON = `<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-user"><path d="M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2"/><circle cx="12" cy="7" r="4"/></svg>`;

export const WALLET_ICON = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ export const ConnectWalletSocialOptions = (
twitch: "Twitch",
x: "X",
tiktok: "TikTok",
epic: "Epic",
};

const { data: ecosystemAuthOptions, isLoading } = useQuery({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ function getOauthLoginPath(
case "line":
case "x":
case "tiktok":
case "epic":
case "guest":
case "coinbase":
case "discord":
Expand Down
1 change: 1 addition & 0 deletions packages/thirdweb/src/stories/ConnectEmbed.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ export function AllInAppWalletAuthMethods() {
"discord",
"x",
"tiktok",
"epic",
"coinbase",
"farcaster",
"telegram",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ export type AuthProvider =
| "Coinbase"
| "X"
| "TikTok"
| "Epic"
| "Line"
| "Twitch"
| "Steam"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ export class InAppNativeConnector implements InAppConnector {
case "line":
case "x":
case "tiktok":
case "epic":
case "apple": {
const { socialAuth } = await import("./auth/native-auth.js");
const ExpoLinking = require("expo-linking");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,7 @@ export class InAppWebConnector implements InAppConnector {
case "line":
case "x":
case "tiktok":
case "epic":
case "steam":
case "coinbase":
case "discord": {
Expand Down Expand Up @@ -411,6 +412,7 @@ export class InAppWebConnector implements InAppConnector {
case "line":
case "x":
case "tiktok":
case "epic":
case "guest":
case "coinbase":
case "twitch":
Expand Down
1 change: 1 addition & 0 deletions packages/thirdweb/src/wallets/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export const socialAuthOptions = [
"line",
"x",
"tiktok",
"epic",
"coinbase",
"farcaster",
"telegram",
Expand Down
Loading