mirror of
https://github.com/myfatemi04/wheelshare-frontend.git
synced 2025-04-17 17:40:16 -04:00
add gatekeeper
This commit is contained in:
parent
ed0bcc8739
commit
e2eaaa0fbb
|
@ -2,6 +2,7 @@ import {
|
||||||
googleAuthorizationEndpoint,
|
googleAuthorizationEndpoint,
|
||||||
ionAuthorizationEndpoint,
|
ionAuthorizationEndpoint,
|
||||||
} from './Authentication/authorizationEndpoint';
|
} from './Authentication/authorizationEndpoint';
|
||||||
|
import { showGoogleLogin } from './gatekeeper';
|
||||||
import UILink from './UI/UILink';
|
import UILink from './UI/UILink';
|
||||||
import UIPrimaryTitle from './UI/UIPrimaryTitle';
|
import UIPrimaryTitle from './UI/UIPrimaryTitle';
|
||||||
|
|
||||||
|
@ -11,8 +12,12 @@ export default function WheelShareLoggedOut() {
|
||||||
<UIPrimaryTitle>WheelShare</UIPrimaryTitle>
|
<UIPrimaryTitle>WheelShare</UIPrimaryTitle>
|
||||||
<p>To get started, log in with your Ion account.</p>
|
<p>To get started, log in with your Ion account.</p>
|
||||||
<UILink href={ionAuthorizationEndpoint}>Log in with Ion</UILink>
|
<UILink href={ionAuthorizationEndpoint}>Log in with Ion</UILink>
|
||||||
<br />
|
{showGoogleLogin() && (
|
||||||
<UILink href={googleAuthorizationEndpoint}>Log in with Google</UILink>
|
<>
|
||||||
|
<br />
|
||||||
|
<UILink href={googleAuthorizationEndpoint}>Log in with Google</UILink>
|
||||||
|
</>
|
||||||
|
)}
|
||||||
<br />
|
<br />
|
||||||
<p>
|
<p>
|
||||||
If you're new to Ion, follow{' '}
|
If you're new to Ion, follow{' '}
|
||||||
|
|
3
src/components/gatekeeper.ts
Normal file
3
src/components/gatekeeper.ts
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
export function showGoogleLogin() {
|
||||||
|
return process.env.NODE_ENV === 'development';
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user