()
| 1 | import {Button} from "@heroui/button"; |
| 2 | |
| 3 | export default function RegisterButton() { |
| 4 | const clientId = 'nextjs'; |
| 5 | const issuer = process.env.AUTH_KEYCLOAK_ISSUER; |
| 6 | const redirectUrl = process.env.AUTH_URL!; |
| 7 | |
| 8 | const registerUrl = `${issuer}/protocol/openid-connect/registrations` + |
| 9 | `?client_id=${clientId}&redirect_uri=` + |
| 10 | `${encodeURIComponent(redirectUrl)}&response_type=code&scope=openid`; |
| 11 | |
| 12 | return ( |
| 13 | <Button |
| 14 | as='a' |
| 15 | href={registerUrl} |
| 16 | color='secondary'>Register</Button> |
| 17 | ) |
| 18 | } |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…