From 99be97206bb42f4d35ece6356961ba4d228694fb Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Sun, 16 May 2021 15:31:13 +0200 Subject: [PATCH] web: fix enums Signed-off-by: Jens Langhammer --- web/src/api/Flows.ts | 4 +-- web/src/flows/FlowExecutor.ts | 10 +++--- web/src/pages/applications/ApplicationForm.ts | 12 +++---- web/src/pages/events/RuleForm.ts | 8 ++--- web/src/pages/flows/FlowForm.ts | 6 ++-- web/src/pages/flows/StageBindingForm.ts | 6 ++-- .../providers/oauth2/OAuth2ProviderForm.ts | 26 +++++++------- .../pages/providers/saml/SAMLProviderForm.ts | 24 ++++++------- .../pages/sources/ldap/LDAPSourceViewPage.ts | 6 ++-- .../pages/sources/oauth/OAuthSourceForm.ts | 12 +++---- web/src/pages/sources/plex/PlexSourceForm.ts | 12 +++---- web/src/pages/sources/saml/SAMLSourceForm.ts | 36 +++++++++---------- .../AuthenticatorValidateStageForm.ts | 20 +++++------ .../identification/IdentificationStageForm.ts | 8 ++--- .../stages/password/PasswordStageForm.ts | 8 ++--- .../pages/system-tasks/SystemTaskListPage.ts | 8 ++--- 16 files changed, 103 insertions(+), 103 deletions(-) diff --git a/web/src/api/Flows.ts b/web/src/api/Flows.ts index 10f7c40f9..367ded8e1 100644 --- a/web/src/api/Flows.ts +++ b/web/src/api/Flows.ts @@ -1,4 +1,4 @@ -import { ChallengeTypeEnum } from "authentik-api"; +import { ChallengeChoices } from "authentik-api"; export interface Error { code: string; @@ -10,7 +10,7 @@ export interface ErrorDict { } export interface Challenge { - type: ChallengeTypeEnum; + type: ChallengeChoices; component?: string; title?: string; response_errors?: ErrorDict; diff --git a/web/src/flows/FlowExecutor.ts b/web/src/flows/FlowExecutor.ts index 6338450ba..b190d328b 100644 --- a/web/src/flows/FlowExecutor.ts +++ b/web/src/flows/FlowExecutor.ts @@ -37,7 +37,7 @@ import { AuthenticatorValidateStageChallenge } from "./stages/authenticator_vali import { WebAuthnAuthenticatorRegisterChallenge } from "./stages/authenticator_webauthn/WebAuthnAuthenticatorRegisterStage"; import { CaptchaChallenge } from "./stages/captcha/CaptchaStage"; import { StageHost } from "./stages/base"; -import { Challenge, ChallengeTypeEnum, Config, FlowsApi } from "authentik-api"; +import { Challenge, ChallengeChoices, Config, FlowsApi } from "authentik-api"; import { config, DEFAULT_CONFIG } from "../api/Config"; import { ifDefined } from "lit-html/directives/if-defined"; import { until } from "lit-html/directives/until"; @@ -155,7 +155,7 @@ export class FlowExecutor extends LitElement implements StageHost { errorMessage(error: string): void { this.challenge = { - type: ChallengeTypeEnum.Shell, + type: ChallengeChoices.Shell, body: `