blob: d8083d89437f9701a2002e0c780a28cde7d308f7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
import React from 'react'
import { Button } from 'reactstrap'
import { useAuth } from '../../auth'
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
import { faSignInAlt } from '@fortawesome/free-solid-svg-icons'
function Login({ visible, className }) {
const { loginWithRedirect } = useAuth()
if (!visible) {
return <span />
}
return (
<Button color="primary" onClick={() => loginWithRedirect()} className={className}>
<FontAwesomeIcon icon={faSignInAlt} /> Sign In
</Button>
)
}
export default Login
|