web: fix mismatched button labels for boundpolicy and boundstage list (#10551)
* remove wrong help text for multi select Signed-off-by: Jens Langhammer <jens@goauthentik.io> * make labelling for create and and bind existing more consistent Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix oobe missing label Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix application library empty state not shown Signed-off-by: Jens Langhammer <jens@goauthentik.io> * fix missing formatting for title on access denied stage Signed-off-by: Jens Langhammer <jens@goauthentik.io> --------- Signed-off-by: Jens Langhammer <jens@goauthentik.io>
This commit is contained in:
		@ -13,11 +13,11 @@ entries:
 | 
			
		||||
  model: authentik_flows.flow
 | 
			
		||||
- attrs:
 | 
			
		||||
    order: 100
 | 
			
		||||
    placeholder: Welcome to authentik! Please set a password for the default admin
 | 
			
		||||
    initial_value:
 | 
			
		||||
      Welcome to authentik! Please set a password and email address for the default admin
 | 
			
		||||
      user, akadmin.
 | 
			
		||||
    placeholder_expression: false
 | 
			
		||||
    required: true
 | 
			
		||||
    sub_text: ''
 | 
			
		||||
    type: static
 | 
			
		||||
    field_key: oobe-header-text
 | 
			
		||||
    label: oobe-header-text
 | 
			
		||||
@ -30,7 +30,6 @@ entries:
 | 
			
		||||
    placeholder: Admin email
 | 
			
		||||
    placeholder_expression: false
 | 
			
		||||
    required: true
 | 
			
		||||
    sub_text: ''
 | 
			
		||||
    type: email
 | 
			
		||||
    field_key: email
 | 
			
		||||
    label: Email
 | 
			
		||||
@ -43,7 +42,6 @@ entries:
 | 
			
		||||
    placeholder: Password
 | 
			
		||||
    placeholder_expression: false
 | 
			
		||||
    required: true
 | 
			
		||||
    sub_text: ''
 | 
			
		||||
    type: password
 | 
			
		||||
    field_key: password
 | 
			
		||||
    label: Password
 | 
			
		||||
@ -56,7 +54,6 @@ entries:
 | 
			
		||||
    placeholder: Password (repeat)
 | 
			
		||||
    placeholder_expression: false
 | 
			
		||||
    required: true
 | 
			
		||||
    sub_text: ''
 | 
			
		||||
    type: password
 | 
			
		||||
    field_key: password_repeat
 | 
			
		||||
    label: Password (repeat)
 | 
			
		||||
 | 
			
		||||
@ -77,9 +77,6 @@ export class ApplicationWizardAuthenticationByRAC extends BaseProviderPanel {
 | 
			
		||||
                                available-label="${msg("Available Property Mappings")}"
 | 
			
		||||
                                selected-label="${msg("Selected Property Mappings")}"
 | 
			
		||||
                            ></ak-dual-select-dynamic-selected>
 | 
			
		||||
                            <p class="pf-c-form__helper-text">
 | 
			
		||||
                                ${msg("Hold control/command to select multiple items.")}
 | 
			
		||||
                            </p>
 | 
			
		||||
                        </ak-form-element-horizontal>
 | 
			
		||||
                    </div>
 | 
			
		||||
                </ak-form-group>
 | 
			
		||||
 | 
			
		||||
@ -125,13 +125,18 @@ export class BoundStagesList extends Table<FlowStageBinding> {
 | 
			
		||||
            html`<ak-empty-state header=${msg("No Stages bound")} icon="pf-icon-module">
 | 
			
		||||
                <div slot="body">${msg("No stages are currently bound to this flow.")}</div>
 | 
			
		||||
                <div slot="primary">
 | 
			
		||||
                    <ak-stage-wizard
 | 
			
		||||
                        createText=${msg("Create and bind Stage")}
 | 
			
		||||
                        ?showBindingPage=${true}
 | 
			
		||||
                        bindingTarget=${ifDefined(this.target)}
 | 
			
		||||
                    ></ak-stage-wizard>
 | 
			
		||||
                    <ak-forms-modal>
 | 
			
		||||
                        <span slot="submit"> ${msg("Create")} </span>
 | 
			
		||||
                        <span slot="header"> ${msg("Create Stage binding")} </span>
 | 
			
		||||
                        <ak-stage-binding-form slot="form" targetPk=${ifDefined(this.target)}>
 | 
			
		||||
                        </ak-stage-binding-form>
 | 
			
		||||
                        <button slot="trigger" class="pf-c-button pf-m-primary">
 | 
			
		||||
                            ${msg("Bind stage")}
 | 
			
		||||
                            ${msg("Bind existing stage")}
 | 
			
		||||
                        </button>
 | 
			
		||||
                    </ak-forms-modal>
 | 
			
		||||
                </div>
 | 
			
		||||
 | 
			
		||||
@ -172,6 +172,11 @@ export class BoundPoliciesList extends Table<PolicyBinding> {
 | 
			
		||||
            html`<ak-empty-state header=${msg("No Policies bound.")} icon="pf-icon-module">
 | 
			
		||||
                <div slot="body">${msg("No policies are currently bound to this object.")}</div>
 | 
			
		||||
                <div slot="primary">
 | 
			
		||||
                    <ak-policy-wizard
 | 
			
		||||
                        createText=${msg("Create and bind Policy")}
 | 
			
		||||
                        ?showBindingPage=${true}
 | 
			
		||||
                        bindingTarget=${ifDefined(this.target)}
 | 
			
		||||
                    ></ak-policy-wizard>
 | 
			
		||||
                    <ak-forms-modal size=${PFSize.Medium}>
 | 
			
		||||
                        <span slot="submit"> ${msg("Create")} </span>
 | 
			
		||||
                        <span slot="header"> ${msg("Create Binding")} </span>
 | 
			
		||||
@ -182,7 +187,7 @@ export class BoundPoliciesList extends Table<PolicyBinding> {
 | 
			
		||||
                        >
 | 
			
		||||
                        </ak-policy-binding-form>
 | 
			
		||||
                        <button slot="trigger" class="pf-c-button pf-m-primary">
 | 
			
		||||
                            ${msg("Create Binding")}
 | 
			
		||||
                            ${msg("Bind existing policy/group/user")}
 | 
			
		||||
                        </button>
 | 
			
		||||
                    </ak-forms-modal>
 | 
			
		||||
                </div>
 | 
			
		||||
@ -206,7 +211,7 @@ export class BoundPoliciesList extends Table<PolicyBinding> {
 | 
			
		||||
                >
 | 
			
		||||
                </ak-policy-binding-form>
 | 
			
		||||
                <button slot="trigger" class="pf-c-button pf-m-primary">
 | 
			
		||||
                    ${msg("Bind existing policy")}
 | 
			
		||||
                    ${msg("Bind existing policy/group/user")}
 | 
			
		||||
                </button>
 | 
			
		||||
            </ak-forms-modal> `;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
@ -215,9 +215,6 @@ export class SAMLProviderFormPage extends BaseProviderForm<SAMLProvider> {
 | 
			
		||||
                            available-label=${msg("Available User Property Mappings")}
 | 
			
		||||
                            selected-label=${msg("Selected User Property Mappings")}
 | 
			
		||||
                        ></ak-dual-select-dynamic-selected>
 | 
			
		||||
                        <p class="pf-c-form__helper-text">
 | 
			
		||||
                            ${msg("Hold control/command to select multiple items.")}
 | 
			
		||||
                        </p>
 | 
			
		||||
                    </ak-form-element-horizontal>
 | 
			
		||||
                    <ak-form-element-horizontal
 | 
			
		||||
                        label=${msg("NameID Property Mapping")}
 | 
			
		||||
 | 
			
		||||
@ -97,9 +97,6 @@ export class PasswordStageForm extends BaseStageForm<PasswordStage> {
 | 
			
		||||
                        <p class="pf-c-form__helper-text">
 | 
			
		||||
                            ${msg("Selection of backends to test the password against.")}
 | 
			
		||||
                        </p>
 | 
			
		||||
                        <p class="pf-c-form__helper-text">
 | 
			
		||||
                            ${msg("Hold control/command to select multiple items.")}
 | 
			
		||||
                        </p>
 | 
			
		||||
                    </ak-form-element-horizontal>
 | 
			
		||||
                    <ak-form-element-horizontal
 | 
			
		||||
                        label=${msg("Configuration flow")}
 | 
			
		||||
 | 
			
		||||
@ -42,6 +42,9 @@ export const Challenge: StoryObj = {
 | 
			
		||||
            pendingUser: "foo",
 | 
			
		||||
            pendingUserAvatar: "https://picsum.photos/64",
 | 
			
		||||
            errorMessage: "This is an error message",
 | 
			
		||||
            flowInfo: {
 | 
			
		||||
                title: "lorem ipsum foo bar baz",
 | 
			
		||||
            },
 | 
			
		||||
        } as AccessDeniedChallenge,
 | 
			
		||||
    },
 | 
			
		||||
    argTypes: {
 | 
			
		||||
 | 
			
		||||
@ -10,6 +10,7 @@ import { ifDefined } from "lit/directives/if-defined.js";
 | 
			
		||||
import PFForm from "@patternfly/patternfly/components/Form/form.css";
 | 
			
		||||
import PFFormControl from "@patternfly/patternfly/components/FormControl/form-control.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";
 | 
			
		||||
@ -20,7 +21,7 @@ export class AccessDeniedStage extends BaseStage<
 | 
			
		||||
    FlowChallengeResponseRequest
 | 
			
		||||
> {
 | 
			
		||||
    static get styles(): CSSResult[] {
 | 
			
		||||
        return [PFBase, PFLogin, PFForm, PFFormControl];
 | 
			
		||||
        return [PFBase, PFLogin, PFForm, PFTitle, PFFormControl];
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    render(): TemplateResult {
 | 
			
		||||
 | 
			
		||||
@ -165,7 +165,7 @@ export class LibraryPage extends AKElement {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    renderState() {
 | 
			
		||||
        if (this.apps.length === 0) {
 | 
			
		||||
        if (!this.apps.some(appHasLaunchUrl)) {
 | 
			
		||||
            return html`<ak-library-application-empty-list
 | 
			
		||||
                ?isadmin=${this.isAdmin}
 | 
			
		||||
            ></ak-library-application-empty-list>`;
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user