Skip to content

Commit

Permalink
web/admin: fix duplicate flow labels (goauthentik#11689)
Browse files Browse the repository at this point in the history
* web/admin: fix duplicate flow labels

Signed-off-by: Jens Langhammer <[email protected]>

* format

Signed-off-by: Jens Langhammer <[email protected]>

---------

Signed-off-by: Jens Langhammer <[email protected]>
  • Loading branch information
BeryJu authored Oct 16, 2024
1 parent 6cc0a66 commit c4caef4
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 55 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,22 +70,6 @@ export class ApplicationWizardAuthenticationByOauth extends BaseProviderPanel {
required
></ak-text-input>
<ak-form-element-horizontal
name="authenticationFlow"
label=${msg("Authentication flow")}
.errorMessages=${errors?.authenticationFlow ?? []}
>
<ak-flow-search
flowType=${FlowsInstancesListDesignationEnum.Authentication}
.currentFlow=${provider?.authenticationFlow}
required
></ak-flow-search>
<p class="pf-c-form__helper-text">
${msg(
"Flow used when a user access this provider and is not authenticated.",
)}
</p>
</ak-form-element-horizontal>
<ak-form-element-horizontal
name="authorizationFlow"
label=${msg("Authorization flow")}
Expand All @@ -103,7 +87,7 @@ export class ApplicationWizardAuthenticationByOauth extends BaseProviderPanel {
</ak-form-element-horizontal>
<ak-form-element-horizontal
name="invalidationFlow"
label=${msg("Authorization flow")}
label=${msg("Invalidation flow")}
.errorMessages=${errors?.invalidationFlow ?? []}
?required=${true}
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,23 +104,6 @@ export class AkTypeProxyApplicationWizardPage extends BaseProviderPanel {
label=${msg("Name")}
></ak-text-input>
<ak-form-element-horizontal
label=${msg("Authentication flow")}
?required=${false}
.errorMessages=${errors?.authenticationFlow ?? []}
name="authenticationFlow"
>
<ak-flow-search
flowType=${FlowsInstancesListDesignationEnum.Authentication}
.currentFlow=${this.instance?.authenticationFlow}
required
></ak-flow-search>
<p class="pf-c-form__helper-text">
${msg(
"Flow used when a user access this provider and is not authenticated.",
)}
</p>
</ak-form-element-horizontal>
<ak-form-element-horizontal
label=${msg("Authorization flow")}
required
Expand All @@ -138,7 +121,7 @@ export class AkTypeProxyApplicationWizardPage extends BaseProviderPanel {
</ak-form-element-horizontal>
<ak-form-element-horizontal
name="invalidationFlow"
label=${msg("Authorization flow")}
label=${msg("Invalidation flow")}
.errorMessages=${errors?.invalidationFlow ?? []}
?required=${true}
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,22 +88,6 @@ export class ApplicationWizardProviderSamlConfiguration extends BaseProviderPane
.errorMessages=${errors?.name ?? []}
></ak-text-input>
<ak-form-element-horizontal
label=${msg("Authentication flow")}
?required=${false}
name="authenticationFlow"
.errorMessages=${errors?.authenticationFlow ?? []}
>
<ak-flow-search
flowType=${FlowsInstancesListDesignationEnum.Authentication}
.currentFlow=${provider?.authenticationFlow}
></ak-flow-search>
<p class="pf-c-form__helper-text">
${msg(
"Flow used when a user access this provider and is not authenticated.",
)}
</p>
</ak-form-element-horizontal>
<ak-form-element-horizontal
label=${msg("Authorization flow")}
?required=${true}
Expand All @@ -121,7 +105,7 @@ export class ApplicationWizardProviderSamlConfiguration extends BaseProviderPane
</ak-form-element-horizontal>
<ak-form-element-horizontal
name="invalidationFlow"
label=${msg("Authorization flow")}
label=${msg("Invalidation flow")}
.errorMessages=${errors?.invalidationFlow ?? []}
?required=${true}
>
Expand Down
9 changes: 7 additions & 2 deletions web/src/admin/providers/ldap/LDAPProviderForm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ export class LDAPProviderFormPage extends WithBrandConfig(BaseProviderForm<LDAPP
<div slot="body" class="pf-c-form">
<ak-form-element-horizontal
label=${msg("Bind flow")}
?required=${true}
name="authorizationFlow"
required
>
<ak-branded-flow-search
flowType=${FlowsInstancesListDesignationEnum.Authentication}
Expand All @@ -148,10 +148,15 @@ export class LDAPProviderFormPage extends WithBrandConfig(BaseProviderForm<LDAPP
${msg("Flow used for users to authenticate.")}
</p>
</ak-form-element-horizontal>
<ak-form-element-horizontal label=${msg("Unbind flow")} name="invalidationFlow">
<ak-form-element-horizontal
label=${msg("Unbind flow")}
name="invalidationFlow"
required
>
<ak-flow-search
flowType=${FlowsInstancesListDesignationEnum.Invalidation}
.currentFlow=${this.instance?.invalidationFlow}
required
></ak-flow-search>
<p class="pf-c-form__helper-text">
${msg("Flow used for unbinding users.")}
Expand Down
2 changes: 1 addition & 1 deletion web/src/elements/AppIcon.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export class AppIcon extends AKElement implements IAppIcon {
@property({ type: String })
icon?: string;

@property()
@property({ reflect: true })
size: PFSize = PFSize.Medium;

static get styles(): CSSResult[] {
Expand Down

0 comments on commit c4caef4

Please sign in to comment.