Add one-click login if possible (#1043)

This commit is contained in:
Erik Michelson 2021-03-09 23:00:14 +01:00 committed by GitHub
parent a6c80ac1f0
commit 6d2dde477c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
26 changed files with 216 additions and 53 deletions

View file

@ -7,6 +7,8 @@
import { RegisterError } from '../../components/register-page/register-page'
import { defaultFetchConfig, expectResponseCode, getApiUrl } from '../utils'
export const INTERACTIVE_LOGIN_METHODS = ['internal', 'ldap', 'openid']
export const doInternalLogin = async (username: string, password: string): Promise<void> => {
const response = await fetch(getApiUrl() + '/auth/internal', {
...defaultFetchConfig,