mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-10-29 14:54:30 +00:00
feat(social-login): social login with Google is working (#7218)
Co-authored-by: Víctor Fernández Poyatos <victor@prowler.com>
This commit is contained in:
1 parent
3cd4e4cbbf
commit
412697c418
7 files changed
+221
-5
No files matched your search
@@ -1,7 +1,8 @@
|
||||
"use client";
|
||||
|
||||
import { zodResolver } from "@hookform/resolvers/zod";
|
||||
import { Checkbox, Link } from "@nextui-org/react";
|
||||
import { Icon } from "@iconify/react";
|
||||
import { Button, Checkbox, Divider, Link } from "@nextui-org/react";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useForm } from "react-hook-form";
|
||||
import { z } from "zod";
|
||||
@@ -17,6 +18,7 @@ import {
|
||||
FormField,
|
||||
FormMessage,
|
||||
} from "@/components/ui/form";
|
||||
import { getAuthUrl } from "@/lib/helper";
|
||||
import { ApiError, authFormSchema } from "@/types";
|
||||
|
||||
export const AuthForm = ({
|
||||
@@ -285,7 +287,7 @@ export const AuthForm = ({
|
||||
</form>
|
||||
</Form>
|
||||
|
||||
{/* {type === "sign-in" && (
|
||||
{type === "sign-in" && (
|
||||
<>
|
||||
<div className="flex items-center gap-4 py-2">
|
||||
<Divider className="flex-1" />
|
||||
@@ -298,6 +300,8 @@ export const AuthForm = ({
|
||||
<Icon icon="flat-color-icons:google" width={24} />
|
||||
}
|
||||
variant="bordered"
|
||||
as="a"
|
||||
href={getAuthUrl("google")}
|
||||
>
|
||||
Continue with Google
|
||||
</Button>
|
||||
@@ -310,12 +314,14 @@ export const AuthForm = ({
|
||||
/>
|
||||
}
|
||||
variant="bordered"
|
||||
as="a"
|
||||
href={getAuthUrl("github")}
|
||||
>
|
||||
Continue with Github
|
||||
</Button>
|
||||
</div>
|
||||
</>
|
||||
)} */}
|
||||
)}
|
||||
{type === "sign-in" ? (
|
||||
<p className="text-center text-small">
|
||||
Need to create an account?
|
||||
|
||||
Reference in new issue
Block a user