@@ -11,7 +11,6 @@ import {
1111import { useColorMode } from "@chakra-ui/react" ;
1212import { Discord , Google } from "@icons-pack/react-simple-icons" ;
1313import { TurnstileInstance } from "@marsidev/react-turnstile" ;
14- import { boolean } from "boolean" ;
1514import { Bug , Mail } from "lucide-react" ;
1615import { GetServerSideProps } from "next" ;
1716import Head from "next/head" ;
@@ -64,11 +63,8 @@ interface SigninProps {
6463
6564function Signin ( { providers } : SigninProps ) {
6665 const router = useRouter ( ) ;
67- const {
68- ENABLE_EMAIL_SIGNIN : enableEmailSignin ,
69- ENABLE_EMAIL_SIGNIN_CAPTCHA : enableEmailSigninCaptcha ,
70- CLOUDFLARE_CAPTCHA_SITE_KEY : cloudflareCaptchaSiteKey ,
71- } = useBrowserConfig ( ) ;
66+ const { ENABLE_EMAIL_SIGNIN : enableEmailSignin , ENABLE_EMAIL_SIGNIN_CAPTCHA : enableEmailSigninCaptcha } =
67+ useBrowserConfig ( ) ;
7268 const { discord, email, google, credentials } = providers ;
7369 const [ error , setError ] = useState ( "" ) ;
7470
@@ -96,11 +92,7 @@ function Signin({ providers }: SigninProps) {
9692 < Stack spacing = "2" >
9793 { credentials && < DebugSigninForm providerId = { credentials . id } /> }
9894 { email && enableEmailSignin && (
99- < EmailSignInForm
100- providerId = { email . id }
101- enableEmailSigninCaptcha = { enableEmailSigninCaptcha }
102- cloudflareCaptchaSiteKey = { cloudflareCaptchaSiteKey }
103- />
95+ < EmailSignInForm providerId = { email . id } enableEmailSigninCaptcha = { enableEmailSigninCaptcha } />
10496 ) }
10597 { discord && (
10698 < Button
@@ -156,11 +148,9 @@ export default Signin;
156148const EmailSignInForm = ( {
157149 providerId,
158150 enableEmailSigninCaptcha,
159- cloudflareCaptchaSiteKey,
160151} : {
161152 providerId : string ;
162153 enableEmailSigninCaptcha : boolean ;
163- cloudflareCaptchaSiteKey : string ;
164154} ) => {
165155 const {
166156 register,
@@ -196,7 +186,6 @@ const EmailSignInForm = ({
196186 </ FormControl >
197187 { enableEmailSigninCaptcha && (
198188 < CloudFlareCaptcha
199- siteKey = { cloudflareCaptchaSiteKey }
200189 options = { { size : "invisible" } }
201190 ref = { captcha }
202191 onSuccess = { ( ) => setCaptchaSuccess ( true ) }
0 commit comments