import { t } from "@lingui/macro"; import { CSSResult, TemplateResult, html } from "lit"; import { customElement } from "lit/decorators.js"; import AKGlobal from "../../authentik.css"; import PFForm from "@patternfly/patternfly/components/Form/form.css"; import PFFormControl from "@patternfly/patternfly/components/FormControl/form-control.css"; import PFList from "@patternfly/patternfly/components/List/list.css"; import PFLogin from "@patternfly/patternfly/components/Login/login.css"; import PFTitle from "@patternfly/patternfly/components/Title/title.css"; import PFBase from "@patternfly/patternfly/patternfly-base.css"; import { AccessDeniedChallenge, FlowChallengeResponseRequest } from "@goauthentik/api"; import "../../elements/EmptyState"; import { BaseStage } from "../stages/base"; @customElement("ak-stage-access-denied") export class FlowAccessDenied extends BaseStage< AccessDeniedChallenge, FlowChallengeResponseRequest > { static get styles(): CSSResult[] { return [PFBase, PFLogin, PFForm, PFList, PFFormControl, PFTitle, AKGlobal]; } render(): TemplateResult { if (!this.challenge) { return html` `; } return html`

${this.challenge.flowInfo?.title}

${t`Request has been denied.`}

${this.challenge?.errorMessage && html`

${this.challenge.errorMessage}

`}
`; } }