web: migrate checkbox to switch (#4409)
* start migrating to switch Signed-off-by: Jens Langhammer <jens@goauthentik.io> * general cleanup Signed-off-by: Jens Langhammer <jens@goauthentik.io> * remove broken Create provider Signed-off-by: Jens Langhammer <jens@goauthentik.io> * migrate all Signed-off-by: Jens Langhammer <jens@goauthentik.io> * migrate table selectors, fix dark theme Signed-off-by: Jens Langhammer <jens@goauthentik.io> Signed-off-by: Jens Langhammer <jens@goauthentik.io>
This commit is contained in:
		@ -55,14 +55,19 @@ export class PasswordExpiryPolicyForm extends ModelForm<PasswordExpiryPolicy, st
 | 
			
		||||
                />
 | 
			
		||||
            </ak-form-element-horizontal>
 | 
			
		||||
            <ak-form-element-horizontal name="executionLogging">
 | 
			
		||||
                <div class="pf-c-check">
 | 
			
		||||
                <label class="pf-c-switch">
 | 
			
		||||
                    <input
 | 
			
		||||
                        class="pf-c-switch__input"
 | 
			
		||||
                        type="checkbox"
 | 
			
		||||
                        class="pf-c-check__input"
 | 
			
		||||
                        ?checked=${first(this.instance?.executionLogging, false)}
 | 
			
		||||
                        ?checked=${first(this.instance?.executionLogging, true)}
 | 
			
		||||
                    />
 | 
			
		||||
                    <label class="pf-c-check__label"> ${t`Execution logging`} </label>
 | 
			
		||||
                </div>
 | 
			
		||||
                    <span class="pf-c-switch__toggle">
 | 
			
		||||
                        <span class="pf-c-switch__toggle-icon">
 | 
			
		||||
                            <i class="fas fa-check" aria-hidden="true"></i>
 | 
			
		||||
                        </span>
 | 
			
		||||
                    </span>
 | 
			
		||||
                    <span class="pf-c-switch__label">${t`Execution logging`}</span>
 | 
			
		||||
                </label>
 | 
			
		||||
                <p class="pf-c-form__helper-text">
 | 
			
		||||
                    ${t`When this option is enabled, all executions of this policy will be logged. By default, only execution errors are logged.`}
 | 
			
		||||
                </p>
 | 
			
		||||
@ -83,16 +88,21 @@ export class PasswordExpiryPolicyForm extends ModelForm<PasswordExpiryPolicy, st
 | 
			
		||||
                        />
 | 
			
		||||
                    </ak-form-element-horizontal>
 | 
			
		||||
                    <ak-form-element-horizontal name="denyOnly">
 | 
			
		||||
                        <div class="pf-c-check">
 | 
			
		||||
                        <label class="pf-c-switch">
 | 
			
		||||
                            <input
 | 
			
		||||
                                class="pf-c-switch__input"
 | 
			
		||||
                                type="checkbox"
 | 
			
		||||
                                class="pf-c-check__input"
 | 
			
		||||
                                ?checked=${first(this.instance?.denyOnly, false)}
 | 
			
		||||
                            />
 | 
			
		||||
                            <label class="pf-c-check__label">
 | 
			
		||||
                                ${t`Only fail the policy, don't invalidate user's password.`}
 | 
			
		||||
                            </label>
 | 
			
		||||
                        </div>
 | 
			
		||||
                            <span class="pf-c-switch__toggle">
 | 
			
		||||
                                <span class="pf-c-switch__toggle-icon">
 | 
			
		||||
                                    <i class="fas fa-check" aria-hidden="true"></i>
 | 
			
		||||
                                </span>
 | 
			
		||||
                            </span>
 | 
			
		||||
                            <span class="pf-c-switch__label"
 | 
			
		||||
                                >${t`Only fail the policy, don't invalidate user's password`}</span
 | 
			
		||||
                            >
 | 
			
		||||
                        </label>
 | 
			
		||||
                    </ak-form-element-horizontal>
 | 
			
		||||
                </div>
 | 
			
		||||
            </ak-form-group>
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user