mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 04:46:40 +07:00
telegram: added telegram attach functionality
This commit is contained in:
parent
3e9f5dedec
commit
e994176bff
10 changed files with 131 additions and 9 deletions
25
src/components/auth/oauth/TelegramLoginForm/index.tsx
Normal file
25
src/components/auth/oauth/TelegramLoginForm/index.tsx
Normal file
|
@ -0,0 +1,25 @@
|
|||
import React, { FC, useEffect } from 'react';
|
||||
|
||||
import TelegramLoginButton, {
|
||||
TelegramUser,
|
||||
} from '@v9v/ts-react-telegram-login';
|
||||
|
||||
interface TelegramLoginFormProps {
|
||||
botName: string;
|
||||
onSuccess?: (token: TelegramUser) => void;
|
||||
}
|
||||
|
||||
const TelegramLoginForm: FC<TelegramLoginFormProps> = ({
|
||||
botName,
|
||||
onSuccess,
|
||||
}) => {
|
||||
return (
|
||||
<TelegramLoginButton
|
||||
dataOnAuth={onSuccess}
|
||||
botName={botName}
|
||||
requestAccess
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
||||
export { TelegramLoginForm };
|
Loading…
Add table
Add a link
Reference in a new issue