"use client"; import { IconBrandGoogleFilled } from "@tabler/icons-react"; import { motion } from "motion/react"; import { useTranslations } from "next-intl"; import { Logo } from "@/components/Logo"; import { AmbientBackground } from "./AmbientBackground"; export function GoogleLoginButton() { const t = useTranslations('auth'); const handleGoogleLogin = () => { // Redirect to Google OAuth authorization URL fetch(`${process.env.NEXT_PUBLIC_FASTAPI_BACKEND_URL}/auth/google/authorize`) .then((response) => { if (!response.ok) { throw new Error("Failed to get authorization URL"); } return response.json(); }) .then((data) => { if (data.authorization_url) { window.location.href = data.authorization_url; } else { console.error("No authorization URL received"); } }) .catch((error) => { console.error("Error during Google login:", error); }); }; return (
{t('cloud_dev_notice')}{" "} {t('docs')} {" "} {t('cloud_dev_self_hosted')}