Merge branch 'web/config-provider-2-tenant' into web/config-provider-2a-branded
* web/config-provider-2-tenant: web: prettier having opinions after merging with dependent branch web: Jens requested that the default subscription state for contexts be , and it's the right call. web: Jens requested that subscription be by default, and it's the right call. web: prettier had opinions about the README
This commit is contained in:
commit
8c6f83b88e
|
@ -110,9 +110,7 @@ export class RelatedUserAdd extends Form<{ users: number[] }> {
|
|||
}
|
||||
|
||||
@customElement("ak-user-related-list")
|
||||
export class RelatedUserList extends WithBrandConfig(
|
||||
WithCapabilitiesConfig(Table<User>, true),
|
||||
) {
|
||||
export class RelatedUserList extends WithBrandConfig(WithCapabilitiesConfig(Table<User>)) {
|
||||
expandable = true;
|
||||
checkbox = true;
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@ import {
|
|||
} from "@goauthentik/api";
|
||||
|
||||
@customElement("ak-provider-ldap-form")
|
||||
export class LDAPProviderFormPage extends WithBrandConfig(ModelForm<LDAPProvider, number>, true) {
|
||||
export class LDAPProviderFormPage extends WithBrandConfig(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 WithBrandConfig(
|
||||
ModelForm<RadiusProvider, number>,
|
||||
true,
|
||||
) {
|
||||
export class RadiusProviderFormPage extends WithBrandConfig(ModelForm<RadiusProvider, number>) {
|
||||
loadInstance(pk: number): Promise<RadiusProvider> {
|
||||
return new ProvidersApi(DEFAULT_CONFIG).providersRadiusRetrieve({
|
||||
id: pk,
|
||||
|
|
|
@ -91,8 +91,7 @@ const recoveryButtonStyles = css`
|
|||
`;
|
||||
|
||||
@customElement("ak-user-list")
|
||||
export class UserListPage extends WithBrandConfig(
|
||||
WithCapabilitiesConfig(TablePage<User>, true)) {
|
||||
export class UserListPage extends WithBrandConfig(WithCapabilitiesConfig(TablePage<User>)) {
|
||||
expandable = true;
|
||||
checkbox = true;
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ type Constructor<T = object> = new (...args: any[]) => T;
|
|||
|
||||
export function WithAuthentikConfig<T extends Constructor<LitElement>>(
|
||||
superclass: T,
|
||||
subscribe = false,
|
||||
subscribe = true,
|
||||
) {
|
||||
abstract class WithAkConfigProvider extends superclass {
|
||||
@consume({ context: authentikConfigContext, subscribe })
|
||||
|
|
|
@ -47,7 +47,7 @@ class WCC {
|
|||
|
||||
export function WithCapabilitiesConfig<T extends Constructor<LitElement>>(
|
||||
superclass: T,
|
||||
subscribe = false,
|
||||
subscribe = true,
|
||||
) {
|
||||
abstract class CapabilitiesContext extends superclass {
|
||||
@consume({ context: authentikConfigContext, subscribe })
|
||||
|
|
|
@ -31,10 +31,7 @@ import {
|
|||
} from "@goauthentik/api";
|
||||
|
||||
@customElement("ak-user-settings-flow-executor")
|
||||
export class UserSettingsFlowExecutor
|
||||
extends WithBrandConfig(AKElement)
|
||||
implements StageHost
|
||||
{
|
||||
export class UserSettingsFlowExecutor extends WithBrandConfig(AKElement) implements StageHost {
|
||||
@property()
|
||||
flowSlug?: string;
|
||||
|
||||
|
|
Reference in a new issue