Merge branch 'accessibility-settings-7.6' into accessibility-settings-main

# Conflicts:
#	src/app/accessibility/accessibility-settings.service.ts
This commit is contained in:
Andreas Awouters
2025-03-07 13:00:37 +01:00
3 changed files with 11 additions and 6 deletions

View File

@@ -1,6 +1,7 @@
import { import {
Inject, Inject,
Injectable, Injectable,
Optional,
} from '@angular/core'; } from '@angular/core';
import cloneDeep from 'lodash/cloneDeep'; import cloneDeep from 'lodash/cloneDeep';
import { import {
@@ -88,7 +89,7 @@ export class AccessibilitySettingsService {
protected cookieService: CookieService, protected cookieService: CookieService,
protected authService: AuthService, protected authService: AuthService,
protected ePersonService: EPersonDataService, protected ePersonService: EPersonDataService,
protected orejimeService: OrejimeService, @Optional() protected orejimeService: OrejimeService,
@Inject(APP_CONFIG) protected appConfig: AppConfig, @Inject(APP_CONFIG) protected appConfig: AppConfig,
) { ) {
} }
@@ -242,6 +243,10 @@ export class AccessibilitySettingsService {
* Emits 'failed' when setting in a cookie failed due to the cookie not being accepted, 'cookie' when it succeeded. * Emits 'failed' when setting in a cookie failed due to the cookie not being accepted, 'cookie' when it succeeded.
*/ */
setSettingsInCookie(settings: AccessibilitySettings): Observable<'cookie' | 'failed'> { setSettingsInCookie(settings: AccessibilitySettings): Observable<'cookie' | 'failed'> {
if (hasNoValue(this.orejimeService)) {
return of('failed');
}
return this.orejimeService.getSavedPreferences().pipe( return this.orejimeService.getSavedPreferences().pipe(
map(preferences => preferences.accessibility), map(preferences => preferences.accessibility),
map((accessibilityCookieAccepted: boolean) => { map((accessibilityCookieAccepted: boolean) => {

View File

@@ -68,6 +68,10 @@
{{ 'footer.link.cookies' | translate}} {{ 'footer.link.cookies' | translate}}
</button> </button>
</li> </li>
<li>
<a class="text-white"
routerLink="info/accessibility">{{ 'footer.link.accessibility' | translate }}</a>
</li>
<li *ngIf="showPrivacyPolicy"> <li *ngIf="showPrivacyPolicy">
<a class="btn text-white" <a class="btn text-white"
routerLink="info/privacy">{{ 'footer.link.privacy-policy' | translate}}</a> routerLink="info/privacy">{{ 'footer.link.privacy-policy' | translate}}</a>
@@ -80,10 +84,6 @@
<a class="btn text-white" <a class="btn text-white"
routerLink="info/feedback">{{ 'footer.link.feedback' | translate}}</a> routerLink="info/feedback">{{ 'footer.link.feedback' | translate}}</a>
</li> </li>
<li>
<a class="text-white"
routerLink="info/accessibility">{{ 'footer.link.accessibility' | translate }}</a>
</li>
</ul> </ul>
</div> </div>
<div *ngIf="coarLdnEnabled$ | async" class="notify-enabled text-white"> <div *ngIf="coarLdnEnabled$ | async" class="notify-enabled text-white">

View File

@@ -2146,7 +2146,7 @@
"info.accessibility-settings.liveRegionTimeOut.label": "ARIA Live region time out (in seconds)", "info.accessibility-settings.liveRegionTimeOut.label": "ARIA Live region time out (in seconds)",
"info.accessibility-settings.liveRegionTimeOut.hint": "The duration after which a message in the ARIA live region disappears. ARIA live regions are not visible on the page, but proivde announcements of notifications (or other actions) to screen readers.", "info.accessibility-settings.liveRegionTimeOut.hint": "The duration after which a message in the ARIA live region disappears. ARIA live regions are not visible on the page, but provide announcements of notifications (or other actions) to screen readers.",
"info.accessibility-settings.liveRegionTimeOut.invalid": "Live region time out must be greater than 0", "info.accessibility-settings.liveRegionTimeOut.invalid": "Live region time out must be greater than 0",