web: Jens requested that the default subscription state for contexts be , and it's the right call.
This commit is contained in:
parent
f669222529
commit
03fde51313
|
@ -31,7 +31,7 @@ import {
|
|||
} from "./LDAPOptionsAndHelp";
|
||||
|
||||
@customElement("ak-application-wizard-authentication-by-ldap")
|
||||
export class ApplicationWizardApplicationDetails extends WithTenantConfig(BaseProviderPanel, true) {
|
||||
export class ApplicationWizardApplicationDetails extends WithTenantConfig(BaseProviderPanel) {
|
||||
render() {
|
||||
const provider = this.wizard.provider as LDAPProvider | undefined;
|
||||
|
||||
|
|
|
@ -16,10 +16,7 @@ import { FlowsInstancesListDesignationEnum, RadiusProvider } from "@goauthentik/
|
|||
import BaseProviderPanel from "../BaseProviderPanel";
|
||||
|
||||
@customElement("ak-application-wizard-authentication-by-radius")
|
||||
export class ApplicationWizardAuthenticationByRadius extends WithTenantConfig(
|
||||
BaseProviderPanel,
|
||||
true,
|
||||
) {
|
||||
export class ApplicationWizardAuthenticationByRadius extends WithTenantConfig(BaseProviderPanel) {
|
||||
render() {
|
||||
const provider = this.wizard.provider as RadiusProvider | undefined;
|
||||
|
||||
|
|
|
@ -111,9 +111,7 @@ export class RelatedUserAdd extends Form<{ users: number[] }> {
|
|||
|
||||
@customElement("ak-user-related-list")
|
||||
export class RelatedUserList extends WithTenantConfig(
|
||||
WithCapabilitiesConfig(Table<User>, true),
|
||||
true,
|
||||
) {
|
||||
WithCapabilitiesConfig(Table<User>)) {
|
||||
expandable = true;
|
||||
checkbox = true;
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@ import {
|
|||
} from "@goauthentik/api";
|
||||
|
||||
@customElement("ak-provider-ldap-form")
|
||||
export class LDAPProviderFormPage extends WithTenantConfig(ModelForm<LDAPProvider, number>, true) {
|
||||
export class LDAPProviderFormPage extends WithTenantConfig(ModelForm<LDAPProvider, number>) {
|
||||
async loadInstance(pk: number): Promise<LDAPProvider> {
|
||||
return new ProvidersApi(DEFAULT_CONFIG).providersLdapRetrieve({
|
||||
id: pk,
|
||||
|
|
|
@ -14,10 +14,7 @@ import { customElement } from "lit/decorators.js";
|
|||
import { FlowsInstancesListDesignationEnum, ProvidersApi, RadiusProvider } from "@goauthentik/api";
|
||||
|
||||
@customElement("ak-provider-radius-form")
|
||||
export class RadiusProviderFormPage extends WithTenantConfig(
|
||||
ModelForm<RadiusProvider, number>,
|
||||
true,
|
||||
) {
|
||||
export class RadiusProviderFormPage extends WithTenantConfig(ModelForm<RadiusProvider, number>) {
|
||||
loadInstance(pk: number): Promise<RadiusProvider> {
|
||||
return new ProvidersApi(DEFAULT_CONFIG).providersRadiusRetrieve({
|
||||
id: pk,
|
||||
|
@ -89,7 +86,7 @@ export class RadiusProviderFormPage extends WithTenantConfig(
|
|||
</label>
|
||||
<p class="pf-c-form__helper-text">
|
||||
${msg(
|
||||
"When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon.",
|
||||
"When enabled, code-based multi-factor authentication can be used by appending a semicolon and the TOTP code to the password. This should only be enabled if all users that will bind to this provider have a TOTP device configured, as otherwise a password may incorrectly be rejected if it contains a semicolon."
|
||||
)}
|
||||
</p>
|
||||
</ak-form-element-horizontal>
|
||||
|
@ -106,7 +103,7 @@ export class RadiusProviderFormPage extends WithTenantConfig(
|
|||
type="text"
|
||||
value="${first(
|
||||
this.instance?.sharedSecret,
|
||||
randomString(128, ascii_letters + digits),
|
||||
randomString(128, ascii_letters + digits)
|
||||
)}"
|
||||
class="pf-c-form-control"
|
||||
required
|
||||
|
|
|
@ -91,10 +91,7 @@ const recoveryButtonStyles = css`
|
|||
`;
|
||||
|
||||
@customElement("ak-user-list")
|
||||
export class UserListPage extends WithTenantConfig(
|
||||
WithCapabilitiesConfig(TablePage<User>, true),
|
||||
true,
|
||||
) {
|
||||
export class UserListPage extends WithTenantConfig(WithCapabilitiesConfig(TablePage<User>)) {
|
||||
expandable = true;
|
||||
checkbox = true;
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ type Constructor<T = object> = abstract new (...args: any[]) => T;
|
|||
|
||||
export function WithTenantConfig<T extends Constructor<LitElement>>(
|
||||
superclass: T,
|
||||
subscribe = false,
|
||||
subscribe = true,
|
||||
) {
|
||||
abstract class WithTenantProvider extends superclass {
|
||||
@consume({ context: authentikTenantContext, subscribe })
|
||||
|
|
|
@ -24,7 +24,7 @@ import PFBase from "@patternfly/patternfly/patternfly-base.css";
|
|||
import { EventsApi } from "@goauthentik/api";
|
||||
|
||||
@customElement("ak-page-header")
|
||||
export class PageHeader extends WithTenantConfig(AKElement, true) {
|
||||
export class PageHeader extends WithTenantConfig(AKElement) {
|
||||
@property()
|
||||
icon?: string;
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ export const DefaultTenant: CurrentTenant = {
|
|||
};
|
||||
|
||||
@customElement("ak-sidebar-brand")
|
||||
export class SidebarBrand extends WithTenantConfig(AKElement, true) {
|
||||
export class SidebarBrand extends WithTenantConfig(AKElement) {
|
||||
static get styles(): CSSResult[] {
|
||||
return [
|
||||
PFBase,
|
||||
|
|
Reference in New Issue