mirror of
https://github.com/khoj-ai/khoj.git
synced 2024-12-18 18:47:11 +00:00
Remove dead dependencies and improve the google sign in button
This commit is contained in:
parent
41bb1e60d0
commit
943065b7b3
1 changed files with 4 additions and 14 deletions
|
@ -2,19 +2,11 @@
|
||||||
|
|
||||||
import styles from "./loginPrompt.module.css";
|
import styles from "./loginPrompt.module.css";
|
||||||
import { Button } from "@/components/ui/button";
|
import { Button } from "@/components/ui/button";
|
||||||
import {
|
import { Dialog, DialogContent } from "@/components/ui/dialog";
|
||||||
Dialog,
|
|
||||||
DialogContent,
|
|
||||||
DialogDescription,
|
|
||||||
DialogFooter,
|
|
||||||
DialogHeader,
|
|
||||||
DialogTitle,
|
|
||||||
} from "@/components/ui/dialog";
|
|
||||||
import { Input } from "@/components/ui/input";
|
import { Input } from "@/components/ui/input";
|
||||||
import {
|
import {
|
||||||
ArrowLeft,
|
ArrowLeft,
|
||||||
ArrowsClockwise,
|
ArrowsClockwise,
|
||||||
GoogleLogo,
|
|
||||||
LineVertical,
|
LineVertical,
|
||||||
PaperPlaneTilt,
|
PaperPlaneTilt,
|
||||||
PencilSimple,
|
PencilSimple,
|
||||||
|
@ -70,8 +62,6 @@ export default function LoginPrompt(props: LoginPromptProps) {
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const google = (window as any).google;
|
const google = (window as any).google;
|
||||||
|
|
||||||
console.log(data, isLoading, error);
|
|
||||||
|
|
||||||
if (!google) return;
|
if (!google) return;
|
||||||
|
|
||||||
// Initialize Google Sign In after script loads
|
// Initialize Google Sign In after script loads
|
||||||
|
@ -113,8 +103,6 @@ export default function LoginPrompt(props: LoginPromptProps) {
|
||||||
const handleGoogleScriptLoad = () => {
|
const handleGoogleScriptLoad = () => {
|
||||||
const google = (window as any).google;
|
const google = (window as any).google;
|
||||||
|
|
||||||
console.log(data, isLoading, error);
|
|
||||||
|
|
||||||
if (!data?.google?.client_id || !data?.google?.redirect_uri) return;
|
if (!data?.google?.client_id || !data?.google?.redirect_uri) return;
|
||||||
|
|
||||||
// Initialize Google Sign In after script loads
|
// Initialize Google Sign In after script loads
|
||||||
|
@ -413,7 +401,9 @@ function MainSignInContext({
|
||||||
<button className={`${styles.gsiMaterialButton}`}>
|
<button className={`${styles.gsiMaterialButton}`}>
|
||||||
<div className={styles.gsiMaterialButtonState}></div>
|
<div className={styles.gsiMaterialButtonState}></div>
|
||||||
<div className={styles.gsiMaterialButtonContentWrapper}>
|
<div className={styles.gsiMaterialButtonContentWrapper}>
|
||||||
<div className={styles.gsiMaterialButtonIcon}>
|
<div
|
||||||
|
className={`${styles.gsiMaterialButtonIcon} flex items-center justify-center`}
|
||||||
|
>
|
||||||
<svg
|
<svg
|
||||||
version="1.1"
|
version="1.1"
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
|
Loading…
Reference in a new issue