import { DEFAULT_CONFIG } from "@goauthentik/common/api/config";
import { first } from "@goauthentik/common/utils";
import "@goauthentik/components/ak-number-input";
import "@goauthentik/components/ak-switch-input";
import "@goauthentik/components/ak-text-input";
import "@goauthentik/elements/CodeMirror";
import { CodeMirrorMode } from "@goauthentik/elements/CodeMirror";
import { Form } from "@goauthentik/elements/forms/Form";
import "@goauthentik/elements/forms/FormGroup";
import "@goauthentik/elements/forms/HorizontalFormElement";
import "@goauthentik/elements/forms/Radio";
import "@goauthentik/elements/forms/SearchSelect";
import "@goauthentik/elements/utils/TimeDeltaHelp";
import { msg } from "@lit/localize";
import { CSSResult, TemplateResult, html } from "lit";
import { customElement, property } from "lit/decorators.js";
import { ifDefined } from "lit/directives/if-defined.js";
import PFList from "@patternfly/patternfly/components/List/list.css";
import { AdminApi, Settings, SettingsRequest } from "@goauthentik/api";
@customElement("ak-admin-settings-form")
export class AdminSettingsForm extends Form
none
:
${msg(
"Disables per-user avatars and just shows a 1x1 pixel transparent picture",
)}
gravatar
:
${msg("Uses gravatar with the user's email address")}
initials
:
${msg("Generated avatars based on the user's name")}
%(username)s
: ${msg("The user's username")}
%(mail_hash)s
:
${msg("The email address, md5 hashed")}
%(upn)s
:
${msg("The user's UPN, if set (otherwise an empty string)")}
attributes.something.avatar
, which can be used in
combination with the file field to allow users to upload custom
avatars for themselves.`,
)}
${msg(
"Multiple values can be set, comma-separated, and authentik will fallback to the next mode when no avatar could be found.",
)}
${msg(
html`For example, setting this to gravatar,initials
will
attempt to get an avatar from Gravatar, and if the user has not
configured on there, it will fallback to a generated avatar.`,
)}
${msg( 'When using an external logging solution for archiving, this can be set to "minutes=5".', )}
${msg( "This setting only affects new Events, as the expiration is saved per-event.", )}
${msg(
"This option configures the footer links on the flow executor pages. It must be a valid YAML or JSON list and can be used as follows:",
)}
[{"name": "Link Name","href":"https://goauthentik.io"}]