From cdc73cedab7816f161f936236793adc1174d7477 Mon Sep 17 00:00:00 2001 From: Anmol Singh Bhatia <121005188+anmolsinghbhatia@users.noreply.github.com> Date: Wed, 17 Apr 2024 19:46:35 +0530 Subject: [PATCH] chore: sign in page improvement (#4224) --- web/components/account/index.ts | 1 + web/components/account/sign-in-forms/root.tsx | 2 ++ web/components/account/sign-up-forms/root.tsx | 2 ++ .../account/terms-and-conditions.tsx | 25 +++++++++++++++++++ 4 files changed, 30 insertions(+) create mode 100644 web/components/account/terms-and-conditions.tsx diff --git a/web/components/account/index.ts b/web/components/account/index.ts index 0d1cffbc6..18b021cb9 100644 --- a/web/components/account/index.ts +++ b/web/components/account/index.ts @@ -2,3 +2,4 @@ export * from "./o-auth"; export * from "./sign-in-forms"; export * from "./sign-up-forms"; export * from "./deactivate-account-modal"; +export * from "./terms-and-conditions"; diff --git a/web/components/account/sign-in-forms/root.tsx b/web/components/account/sign-in-forms/root.tsx index fad37efaf..a03bd379e 100644 --- a/web/components/account/sign-in-forms/root.tsx +++ b/web/components/account/sign-in-forms/root.tsx @@ -8,6 +8,7 @@ import { SignInPasswordForm, OAuthOptions, SignInOptionalSetPasswordForm, + TermsAndConditions, } from "@/components/account"; import { LatestFeatureBlock } from "@/components/common"; import { NAVIGATE_TO_SIGNUP } from "@/constants/event-tracker"; @@ -121,6 +122,7 @@ export const SignInRoot = observer(() => { Sign up

+ )} diff --git a/web/components/account/sign-up-forms/root.tsx b/web/components/account/sign-up-forms/root.tsx index 4fab3abcd..bf5f37fe1 100644 --- a/web/components/account/sign-up-forms/root.tsx +++ b/web/components/account/sign-up-forms/root.tsx @@ -8,6 +8,7 @@ import { SignUpOptionalSetPasswordForm, SignUpPasswordForm, SignUpUniqueCodeForm, + TermsAndConditions, } from "@/components/account"; import { NAVIGATE_TO_SIGNIN } from "@/constants/event-tracker"; import { useApplication, useEventTracker } from "@/hooks/store"; @@ -97,6 +98,7 @@ export const SignUpRoot = observer(() => { Sign in

+ )} diff --git a/web/components/account/terms-and-conditions.tsx b/web/components/account/terms-and-conditions.tsx new file mode 100644 index 000000000..60467ebb1 --- /dev/null +++ b/web/components/account/terms-and-conditions.tsx @@ -0,0 +1,25 @@ +import React, { FC } from "react"; +import Link from "next/link"; + +type Props = { + isSignUp?: boolean; +}; + +export const TermsAndConditions: FC = (props) => { + const { isSignUp = false } = props; + return ( + +

+ {isSignUp ? "By creating an account" : "By signing in"}, you agree to our{" \n"} + + Terms of Service + {" "} + and{" "} + + Privacy Policy + + {"."} +

+
+ ); +};