diff --git a/src/components/WheelShareLoggedOut.tsx b/src/components/WheelShareLoggedOut.tsx index 0453947..eb4c172 100644 --- a/src/components/WheelShareLoggedOut.tsx +++ b/src/components/WheelShareLoggedOut.tsx @@ -2,6 +2,7 @@ import { googleAuthorizationEndpoint, ionAuthorizationEndpoint, } from './Authentication/authorizationEndpoint'; +import { showGoogleLogin } from './gatekeeper'; import UILink from './UI/UILink'; import UIPrimaryTitle from './UI/UIPrimaryTitle'; @@ -11,8 +12,12 @@ export default function WheelShareLoggedOut() { <UIPrimaryTitle>WheelShare</UIPrimaryTitle> <p>To get started, log in with your Ion account.</p> <UILink href={ionAuthorizationEndpoint}>Log in with Ion</UILink> - <br /> - <UILink href={googleAuthorizationEndpoint}>Log in with Google</UILink> + {showGoogleLogin() && ( + <> + <br /> + <UILink href={googleAuthorizationEndpoint}>Log in with Google</UILink> + </> + )} <br /> <p> If you're new to Ion, follow{' '} diff --git a/src/components/gatekeeper.ts b/src/components/gatekeeper.ts new file mode 100644 index 0000000..2f97d70 --- /dev/null +++ b/src/components/gatekeeper.ts @@ -0,0 +1,3 @@ +export function showGoogleLogin() { + return process.env.NODE_ENV === 'development'; +}