Skip to content

Commit

Permalink
feat: telegram login (#3830)
Browse files Browse the repository at this point in the history
## TL;DR

This PR introduces support for Telegram OAuth across various components of the thirdweb packages.

## What changed?

- Added 'Telegram' as an OAuth option in `WALLETS` array within the `constants.ts` file.
- Introduced `telegramIconUri` constant and its usage across the application.
- Updated `socialIcons` object and methods to handle new Telegram icon.
- Enhanced `WalletImage` components to recognize and display the Telegram icon.
- Included Telegram in OAuth login path determination within `oauthSignIn.ts`.
- Updated enumerations and type definitions to include Telegram.
- Modified `InAppNativeConnector` and `InAppWebConnector` to handle Telegram OAuth redirection.

## How to test?

1. Navigate to the authentication section in the application.
2. Check for the new 'Sign in with Telegram' option.
3. Attempt to sign in using a Telegram account and verify the successful login flow.

## Why make this change?

To expand the authentication options available to users, providing more flexibility and convenience. Telegram is a popular messaging app, and integrating it as an OAuth option can enhance user experience.

---

<!-- start pr-codex -->

---

## PR-Codex overview
The focus of this PR is to add `Telegram` as a supported authentication option across various parts of the application.

### Detailed summary
- Added `Telegram` as an authentication option in various files
- Included `TELEGRAM_ICON` in multiple components
- Updated social icons with `telegramIconUri`

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

<!-- end pr-codex -->
  • Loading branch information
gregfromstl committed Aug 5, 2024
1 parent 9640b18 commit ae28e27
Show file tree
Hide file tree
Showing 12 changed files with 32 additions and 1 deletion.
2 changes: 1 addition & 1 deletion apps/playground-web/src/lib/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export const WALLETS = [
options: [
"google",
"discord",
"apple",
"telegram",
"email",
"passkey",
"phone",
Expand Down
3 changes: 3 additions & 0 deletions packages/thirdweb/src/react/core/utils/socialIcons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ export const discordIconUri =
"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDEwMCAxM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NjMwOSBDMTkwLjI2MDI4Nyw1MTMuMzQyNTg5IDIwMi42NTkyNDQsNTA0LjEzNDUwOSAyMjYuMzI4NDE5LDQ5NC43MjIwNjkgWiIgaWQ9IlBhdGgtMyIgZmlsbD0iI0ZGRkZGRiI+PC9wYXRoPgogICAgPC9nPgo8L3N2Zz4=";
export const microsoftIconUri =
"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciICB2aWV3Qm94PSIwIDAgNDggNDgiIHdpZHRoPSI0OHB4IiBoZWlnaHQ9IjQ4cHgiPjxwYXRoIGZpbGw9IiNmZjU3MjIiIGQ9Ik02IDZIMjJWMjJINnoiIHRyYW5zZm9ybT0icm90YXRlKC0xODAgMTQgMTQpIi8+PHBhdGggZmlsbD0iIzRjYWY1MCIgZD0iTTI2IDZINDJWMjJIMjZ6IiB0cmFuc2Zvcm09InJvdGF0ZSgtMTgwIDM0IDE0KSIvPjxwYXRoIGZpbGw9IiNmZmMxMDciIGQ9Ik0yNiAyNkg0MlY0MkgyNnoiIHRyYW5zZm9ybT0icm90YXRlKC0xODAgMzQgMzQpIi8+PHBhdGggZmlsbD0iIzAzYTlmNCIgZD0iTTYgMjZIMjJWNDJINnoiIHRyYW5zZm9ybT0icm90YXRlKC0xODAgMTQgMzQpIi8+PC9zdmc+";

Expand Down Expand Up @@ -51,4 +53,5 @@ export const socialIcons = {
facebook: facebookIconUri,
discord: discordIconUri,
farcaster: farcasterIconUri,
telegram: telegramIconUri,
};
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import {
FARCASTER_ICON,
GOOGLE_ICON,
PHONE_ICON,
TELEGRAM_ICON,
WALLET_ICON,
} from "../icons/svgs.js";
import { RNImage } from "./RNImage.js";
Expand Down Expand Up @@ -79,6 +80,8 @@ export function getAuthProviderImage(lastAuthProvider: string | null): string {
return DISCORD_ICON;
case "farcaster":
return FARCASTER_ICON;
case "telegram":
return TELEGRAM_ICON;
default:
return WALLET_ICON;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
FARCASTER_ICON,
GOOGLE_ICON,
PHONE_ICON,
TELEGRAM_ICON,
} from "../icons/svgs.js";
import type { ModalState } from "./ConnectModal.js";

Expand All @@ -50,6 +51,7 @@ const socialIcons = {
apple: APPLE_ICON,
discord: DISCORD_ICON,
farcaster: FARCASTER_ICON,
telegram: TELEGRAM_ICON,
};

type InAppWalletFormUIProps = {
Expand Down
13 changes: 13 additions & 0 deletions packages/thirdweb/src/react/native/ui/icons/svgs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,19 @@ export const FARCASTER_ICON = `<svg width={width} height={height} viewBox="0 0 1
<path d="M675.556 746.667C663.283 746.667 653.333 756.616 653.333 768.889V795.556H648.889C636.616 795.556 626.667 805.505 626.667 817.778V844.444H875.556V817.778C875.556 805.505 865.606 795.556 853.333 795.556H848.889V768.889C848.889 756.616 838.94 746.667 826.667 746.667V351.111H851.111L880 253.333H702.222V746.667H675.556Z" fill="white"/>
</svg>`;

export const TELEGRAM_ICON = `<svg width={width} height={height} viewBox="0 0 1000 1000" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<defs>
<linearGradient x1="50%" y1="0%" x2="50%" y2="99.2583404%" id="linearGradient-1">
<stop stop-color="#2AABEE" offset="0%"></stop>
<stop stop-color="#229ED9" offset="100%"></stop>
</linearGradient>
</defs>
<g id="Artboard" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
<circle id="Oval" fill="url(#linearGradient-1)" cx="500" cy="500" r="500"></circle>
<path d="M226.328419,494.722069 C372.088573,431.216685 469.284839,389.350049 517.917216,369.122161 C656.772535,311.36743 685.625481,301.334815 704.431427,301.003532 C708.567621,300.93067 717.815839,301.955743 723.806446,306.816707 C728.864797,310.92121 730.256552,316.46581 730.922551,320.357329 C731.588551,324.248848 732.417879,333.113828 731.758626,340.040666 C724.234007,419.102486 691.675104,610.964674 675.110982,699.515267 C668.10208,736.984342 654.301336,749.547532 640.940618,750.777006 C611.904684,753.448938 589.856115,731.588035 561.733393,713.153237 C517.726886,684.306416 492.866009,666.349181 450.150074,638.200013 C400.78442,605.66878 432.786119,587.789048 460.919462,558.568563 C468.282091,550.921423 596.21508,434.556479 598.691227,424.000355 C599.00091,422.680135 599.288312,417.758981 596.36474,415.160431 C593.441168,412.561881 589.126229,413.450484 586.012448,414.157198 C581.598758,415.158943 511.297793,461.625274 375.109553,553.556189 C355.154858,567.258623 337.080515,573.934908 320.886524,573.585046 C303.033948,573.199351 268.692754,563.490928 243.163606,555.192408 C211.851067,545.013936 186.964484,539.632504 189.131547,522.346309 C190.260287,513.342589 202.659244,504.134509 226.328419,494.722069 Z" id="Path-3" fill="#FFFFFF"></path>
</g>
</svg>`;

export const EMAIL_ICON = `<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M13.3335 2.6665H2.66683C1.93045 2.6665 1.3335 3.26346 1.3335 3.99984V11.9998C1.3335 12.7362 1.93045 13.3332 2.66683 13.3332H13.3335C14.0699 13.3332 14.6668 12.7362 14.6668 11.9998V3.99984C14.6668 3.26346 14.0699 2.6665 13.3335 2.6665Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M14.6668 4.6665L8.68683 8.4665C8.48101 8.59545 8.24304 8.66384 8.00016 8.66384C7.75728 8.66384 7.51931 8.59545 7.3135 8.4665L1.3335 4.6665" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
Expand Down
4 changes: 4 additions & 0 deletions packages/thirdweb/src/react/web/ui/components/WalletImage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import {
googleIconUri,
passkeyIcon,
phoneIcon,
telegramIconUri,
} from "../../../core/utils/socialIcons.js";
import { getLastAuthProvider } from "../../../core/utils/storage.js";
import { useWalletImage } from "../../../core/utils/wallet.js";
Expand Down Expand Up @@ -81,6 +82,9 @@ export function WalletImage(props: {
case "farcaster":
image = farcasterIconUri;
break;
case "telegram":
image = telegramIconUri;
break;

Check warning on line 87 in packages/thirdweb/src/react/web/ui/components/WalletImage.tsx

View check run for this annotation

Codecov / codecov/patch

packages/thirdweb/src/react/web/ui/components/WalletImage.tsx#L85-L87

Added lines #L85 - L87 were not covered by tests
}
} else {
const mipdImage = getInstalledWalletProviders().find(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ export const ConnectWalletSocialOptions = (
apple: locale.signInWithApple,
discord: locale.signInWithDiscord,
farcaster: "Farcaster",
telegram: "Telegram",

Check warning on line 95 in packages/thirdweb/src/react/web/wallets/shared/ConnectWalletSocialOptions.tsx

View check run for this annotation

Codecov / codecov/patch

packages/thirdweb/src/react/web/wallets/shared/ConnectWalletSocialOptions.tsx#L95

Added line #L95 was not covered by tests
};

const { data: ecosystemAuthOptions, isLoading } = useQuery({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ function getOauthLoginPath(
case "facebook":
case "google":
case "farcaster":
case "telegram":

Check warning on line 37 in packages/thirdweb/src/react/web/wallets/shared/oauthSignIn.ts

View check run for this annotation

Codecov / codecov/patch

packages/thirdweb/src/react/web/wallets/shared/oauthSignIn.ts#L37

Added line #L37 was not covered by tests
case "discord":
return getSocialAuthLoginPath({ authOption, client, ecosystem });
default:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ export enum AuthProvider {
PASSKEY = "Passkey",
DISCORD = "Discord",
FARCASTER = "Farcaster",
TELEGRAM = "Telegram",
}

export type OauthOption = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ export class InAppNativeConnector implements InAppConnector {
case "facebook":
case "discord":
case "farcaster":
case "telegram":
case "apple": {
const ExpoLinking = require("expo-linking");
const redirectUrl =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,7 @@ export class InAppWebConnector implements InAppConnector {
case "facebook":
case "google":
case "farcaster":
case "telegram":

Check warning on line 226 in packages/thirdweb/src/wallets/in-app/web/lib/web-connector.ts

View check run for this annotation

Codecov / codecov/patch

packages/thirdweb/src/wallets/in-app/web/lib/web-connector.ts#L226

Added line #L226 was not covered by tests
case "discord": {
const authToken = await loginWithOauth({
authOption: strategy,
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 @@ -25,6 +25,7 @@ export const socialAuthOptions = [
"facebook",
"discord",
"farcaster",
"telegram",
] as const;
export type SocialAuthOption = (typeof socialAuthOptions)[number];

Expand Down

0 comments on commit ae28e27

Please sign in to comment.