mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ACS-3552] Fix accessibility issues from CSV file (#7887)
This commit is contained in:
@@ -21,10 +21,12 @@
|
|||||||
<mat-expansion-panel-header>
|
<mat-expansion-panel-header>
|
||||||
<mat-panel-title>
|
<mat-panel-title>
|
||||||
<mat-icon>assignment</mat-icon>
|
<mat-icon>assignment</mat-icon>
|
||||||
<div class="app-accordion-title-padding">Tasks</div>
|
<div id="tasks-accordion-title" class="app-accordion-title-padding">Tasks</div>
|
||||||
</mat-panel-title>
|
</mat-panel-title>
|
||||||
</mat-expansion-panel-header>
|
</mat-expansion-panel-header>
|
||||||
<adf-task-filters [filterParam]="filterSelected"
|
<adf-task-filters [filterParam]="filterSelected"
|
||||||
|
role="group"
|
||||||
|
aria-labelledby="tasks-accordion-title"
|
||||||
[appId]="appId"
|
[appId]="appId"
|
||||||
[showIcon]="showTaskFilterIcon"
|
[showIcon]="showTaskFilterIcon"
|
||||||
(filterClicked)="onTaskFilterClick($event)"
|
(filterClicked)="onTaskFilterClick($event)"
|
||||||
@@ -138,11 +140,13 @@
|
|||||||
<mat-expansion-panel-header>
|
<mat-expansion-panel-header>
|
||||||
<mat-panel-title>
|
<mat-panel-title>
|
||||||
<mat-icon>assessment</mat-icon>
|
<mat-icon>assessment</mat-icon>
|
||||||
<div class="app-accordion-title-padding">Processes</div>
|
<div id="process-accordion-title" class="app-accordion-title-padding">Processes</div>
|
||||||
</mat-panel-title>
|
</mat-panel-title>
|
||||||
</mat-expansion-panel-header>
|
</mat-expansion-panel-header>
|
||||||
<adf-process-instance-filters
|
<adf-process-instance-filters
|
||||||
#activitiProcessFilter
|
#activitiProcessFilter
|
||||||
|
role="group"
|
||||||
|
aria-labelledby="process-accordion-title"
|
||||||
[appId]="appId"
|
[appId]="appId"
|
||||||
[filterParam]="filterSelected"
|
[filterParam]="filterSelected"
|
||||||
[showIcon]="showProcessFilterIcon"
|
[showIcon]="showProcessFilterIcon"
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
<div class="adf-share-link__dialog-content">
|
<div class="adf-share-link__dialog-content">
|
||||||
<div data-automation-id="adf-share-dialog-title" class="adf-share-link__title">
|
<div data-automation-id="adf-share-dialog-title" class="adf-share-link__title" role="heading" aria-level="1">
|
||||||
{{ 'SHARE.DIALOG-TITLE' | translate }} {{ fileName }}
|
{{ 'SHARE.DIALOG-TITLE' | translate }} {{ fileName }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -28,12 +28,15 @@
|
|||||||
matInput
|
matInput
|
||||||
cdkFocusInitial
|
cdkFocusInitial
|
||||||
placeholder="{{ 'SHARE.PUBLIC-LINK' | translate }}"
|
placeholder="{{ 'SHARE.PUBLIC-LINK' | translate }}"
|
||||||
|
[attr.aria-label]="'SHARE.PUBLIC-LINK' | translate"
|
||||||
formControlName="sharedUrl"
|
formControlName="sharedUrl"
|
||||||
readonly="readonly">
|
readonly="readonly">
|
||||||
<mat-icon
|
<mat-icon
|
||||||
class="adf-input-action"
|
class="adf-input-action"
|
||||||
|
role="button"
|
||||||
matSuffix
|
matSuffix
|
||||||
[clipboard-notification]="'SHARE.CLIPBOARD-MESSAGE' | translate" [adf-clipboard]
|
[clipboard-notification]="'SHARE.CLIPBOARD-MESSAGE' | translate" [adf-clipboard]
|
||||||
|
[attr.aria-label]="'SHARE.COPY_BUTTON_LABEL' | translate"
|
||||||
[target]="sharedLinkInput">
|
[target]="sharedLinkInput">
|
||||||
content_copy
|
content_copy
|
||||||
</mat-icon>
|
</mat-icon>
|
||||||
@@ -69,6 +72,7 @@
|
|||||||
#dateTimePickerInput
|
#dateTimePickerInput
|
||||||
matInput
|
matInput
|
||||||
placeholder="{{ 'SHARE.EXPIRATION-LABEL' | translate }}"
|
placeholder="{{ 'SHARE.EXPIRATION-LABEL' | translate }}"
|
||||||
|
[attr.aria-label]="'SHARE.EXPIRATION-LABEL' | translate"
|
||||||
[min]="minDate"
|
[min]="minDate"
|
||||||
formControlName="time"
|
formControlName="time"
|
||||||
[matDatetimepicker]="datetimePicker" />
|
[matDatetimepicker]="datetimePicker" />
|
||||||
|
@@ -384,6 +384,7 @@
|
|||||||
"EXPIRATION-LABEL" : "Expiration Date",
|
"EXPIRATION-LABEL" : "Expiration Date",
|
||||||
"CLIPBOARD-MESSAGE": "Link copied to the clipboard",
|
"CLIPBOARD-MESSAGE": "Link copied to the clipboard",
|
||||||
"CLOSE": "Close",
|
"CLOSE": "Close",
|
||||||
|
"COPY_BUTTON_LABEL": "Copy link",
|
||||||
"CONFIRMATION": {
|
"CONFIRMATION": {
|
||||||
"DIALOG-TITLE": "Remove this shared link",
|
"DIALOG-TITLE": "Remove this shared link",
|
||||||
"MESSAGE": "This link will be deleted and a new link will be created next time this file is shared",
|
"MESSAGE": "This link will be deleted and a new link will be created next time this file is shared",
|
||||||
|
@@ -4,6 +4,7 @@
|
|||||||
[checked]="option.checked"
|
[checked]="option.checked"
|
||||||
(keydown.enter)="option.checked = !option.checked"
|
(keydown.enter)="option.checked = !option.checked"
|
||||||
[attr.data-automation-id]="'checkbox-' + (option.name)"
|
[attr.data-automation-id]="'checkbox-' + (option.name)"
|
||||||
|
[attr.aria-label]="option.name | translate"
|
||||||
(change)="changeHandler($event, option)"
|
(change)="changeHandler($event, option)"
|
||||||
class="adf-facet-filter">
|
class="adf-facet-filter">
|
||||||
<div matTooltip="{{ option.name | translate }}"
|
<div matTooltip="{{ option.name | translate }}"
|
||||||
|
@@ -5,6 +5,7 @@
|
|||||||
[formControl]="from"
|
[formControl]="from"
|
||||||
[errorStateMatcher]="matcher"
|
[errorStateMatcher]="matcher"
|
||||||
placeholder="{{ 'SEARCH.FILTER.RANGE.FROM-DATE' | translate }}"
|
placeholder="{{ 'SEARCH.FILTER.RANGE.FROM-DATE' | translate }}"
|
||||||
|
[attr.aria-label]="'SEARCH.FILTER.RANGE.FROM-DATE' | translate"
|
||||||
[matDatepicker]="fromDatepicker"
|
[matDatepicker]="fromDatepicker"
|
||||||
[max]="fromMaxDate"
|
[max]="fromMaxDate"
|
||||||
(dateChange)="onChangedHandler($event, from)"
|
(dateChange)="onChangedHandler($event, from)"
|
||||||
@@ -22,6 +23,7 @@
|
|||||||
[formControl]="to"
|
[formControl]="to"
|
||||||
[errorStateMatcher]="matcher"
|
[errorStateMatcher]="matcher"
|
||||||
placeholder="{{ 'SEARCH.FILTER.RANGE.TO-DATE' | translate }}"
|
placeholder="{{ 'SEARCH.FILTER.RANGE.TO-DATE' | translate }}"
|
||||||
|
[attr.aria-label]="'SEARCH.FILTER.RANGE.TO-DATE' | translate"
|
||||||
[matDatepicker]="toDatepicker"
|
[matDatepicker]="toDatepicker"
|
||||||
[min]="from.value"
|
[min]="from.value"
|
||||||
[max]="maxDate"
|
[max]="maxDate"
|
||||||
|
@@ -9,7 +9,7 @@
|
|||||||
[attr.data-automation-id]="'facet-result-filter-'+field.label" [(ngModel)]="field.buckets.filterText">
|
[attr.data-automation-id]="'facet-result-filter-'+field.label" [(ngModel)]="field.buckets.filterText">
|
||||||
<button *ngIf="field.buckets.filterText" mat-button matSuffix mat-icon-button
|
<button *ngIf="field.buckets.filterText" mat-button matSuffix mat-icon-button
|
||||||
(click)="field.buckets.filterText = ''">
|
(click)="field.buckets.filterText = ''">
|
||||||
<mat-icon>close</mat-icon>
|
<mat-icon role="button" [attr.aria-label]="'SEARCH.FILTER.BUTTONS.CLOSE' | translate">close</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
|
@@ -2,8 +2,10 @@
|
|||||||
disableRipple
|
disableRipple
|
||||||
class="adf-search-filter-chip"
|
class="adf-search-filter-chip"
|
||||||
[class.adf-search-toggle-chip]="(facetField.displayValue$ | async) || menuTrigger.menuOpen"
|
[class.adf-search-toggle-chip]="(facetField.displayValue$ | async) || menuTrigger.menuOpen"
|
||||||
|
tabIndex="0"
|
||||||
[matMenuTriggerFor]="menu"
|
[matMenuTriggerFor]="menu"
|
||||||
(onMenuOpen)="onMenuOpen()"
|
(onMenuOpen)="onMenuOpen()"
|
||||||
|
(keydown.enter)="onEnterKeydown()"
|
||||||
[attr.title]="facetField.displayValue$ | async"
|
[attr.title]="facetField.displayValue$ | async"
|
||||||
#menuTrigger="matMenuTrigger">
|
#menuTrigger="matMenuTrigger">
|
||||||
|
|
||||||
|
@@ -64,4 +64,8 @@ export class SearchFacetChipComponent {
|
|||||||
this.facetFieldComponent.submitValues();
|
this.facetFieldComponent.submitValues();
|
||||||
this.menuTrigger.closeMenu();
|
this.menuTrigger.closeMenu();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
onEnterKeydown(): void {
|
||||||
|
this.menuTrigger.openMenu();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
<mat-chip-list aria-orientation="horizontal">
|
<mat-chip-list aria-orientation="horizontal" role="listbox">
|
||||||
<ng-container *ngFor="let category of queryBuilder.categories">
|
<ng-container *ngFor="let category of queryBuilder.categories">
|
||||||
<adf-search-widget-chip [category]="category"></adf-search-widget-chip>
|
<adf-search-widget-chip [category]="category"></adf-search-widget-chip>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
@@ -2,6 +2,9 @@
|
|||||||
<div class="adf-search-filter-title">
|
<div class="adf-search-filter-title">
|
||||||
<ng-content select="filter-title"></ng-content>
|
<ng-content select="filter-title"></ng-content>
|
||||||
<mat-icon class="adf-search-filter-title-action"
|
<mat-icon class="adf-search-filter-title-action"
|
||||||
|
role="button"
|
||||||
|
aria-hidden="false"
|
||||||
|
[attr.aria-label]="'SEARCH.FILTER.BUTTONS.CLOSE' | translate"
|
||||||
(click)="onClose()"
|
(click)="onClose()"
|
||||||
[matTooltip]="'SEARCH.FILTER.BUTTONS.CLOSE' | translate">
|
[matTooltip]="'SEARCH.FILTER.BUTTONS.CLOSE' | translate">
|
||||||
close
|
close
|
||||||
|
@@ -2,8 +2,10 @@
|
|||||||
disableRipple
|
disableRipple
|
||||||
class="adf-search-filter-chip"
|
class="adf-search-filter-chip"
|
||||||
[class.adf-search-toggle-chip]="(widget.getDisplayValue() | async) || menuTrigger.menuOpen"
|
[class.adf-search-toggle-chip]="(widget.getDisplayValue() | async) || menuTrigger.menuOpen"
|
||||||
|
tabIndex="0"
|
||||||
[matMenuTriggerFor]="menu"
|
[matMenuTriggerFor]="menu"
|
||||||
(onMenuOpen)="onMenuOpen()"
|
(onMenuOpen)="onMenuOpen()"
|
||||||
|
(keydown.enter)="onEnterKeydown()"
|
||||||
[attr.title]="widget.getDisplayValue() | async"
|
[attr.title]="widget.getDisplayValue() | async"
|
||||||
#menuTrigger="matMenuTrigger">
|
#menuTrigger="matMenuTrigger">
|
||||||
<span class="adf-search-filter-placeholder">
|
<span class="adf-search-filter-placeholder">
|
||||||
|
@@ -65,4 +65,8 @@ export class SearchWidgetChipComponent {
|
|||||||
this.widgetContainerComponent.applyInnerWidget();
|
this.widgetContainerComponent.applyInnerWidget();
|
||||||
this.menuTrigger.closeMenu();
|
this.menuTrigger.closeMenu();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
onEnterKeydown(): void {
|
||||||
|
this.menuTrigger.openMenu();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -37,12 +37,14 @@
|
|||||||
<mat-dialog-actions class="adf-filter-actions">
|
<mat-dialog-actions class="adf-filter-actions">
|
||||||
<button mat-button
|
<button mat-button
|
||||||
id="clear-filter-button"
|
id="clear-filter-button"
|
||||||
|
[attr.aria-label]="'SEARCH.SEARCH_HEADER.CLEAR' | translate"
|
||||||
(click)="onClearButtonClick($event)">{{ 'SEARCH.SEARCH_HEADER.CLEAR' | translate | uppercase }}
|
(click)="onClearButtonClick($event)">{{ 'SEARCH.SEARCH_HEADER.CLEAR' | translate | uppercase }}
|
||||||
</button>
|
</button>
|
||||||
<button mat-button
|
<button mat-button
|
||||||
color="primary"
|
color="primary"
|
||||||
id="apply-filter-button"
|
id="apply-filter-button"
|
||||||
class="adf-filter-apply-button"
|
class="adf-filter-apply-button"
|
||||||
|
[attr.aria-label]="'SEARCH.SEARCH_HEADER.APPLY' | translate"
|
||||||
(click)="onApply()">{{ 'SEARCH.SEARCH_HEADER.APPLY' | translate | uppercase }}
|
(click)="onApply()">{{ 'SEARCH.SEARCH_HEADER.APPLY' | translate | uppercase }}
|
||||||
</button>
|
</button>
|
||||||
</mat-dialog-actions>
|
</mat-dialog-actions>
|
||||||
|
@@ -1,7 +1,10 @@
|
|||||||
<ng-container *ngIf="queryBuilder.searchForms | async as forms">
|
<ng-container *ngIf="queryBuilder.searchForms | async as forms">
|
||||||
|
|
||||||
<ng-container *ngIf="forms.length === 1">
|
<ng-container *ngIf="forms.length === 1">
|
||||||
<button class="adf-search-form" disableRipple mat-button [title]="getSelected(forms) | translate">
|
<button class="adf-search-form"
|
||||||
|
disableRipple mat-button
|
||||||
|
[title]="getSelected(forms) | translate"
|
||||||
|
[attr.aria-label]="getSelected(forms) | translate">
|
||||||
<span class="adf-search-form-title">
|
<span class="adf-search-form-title">
|
||||||
{{ getSelected(forms) | translate }}
|
{{ getSelected(forms) | translate }}
|
||||||
</span>
|
</span>
|
||||||
@@ -15,6 +18,7 @@
|
|||||||
disableRipple
|
disableRipple
|
||||||
mat-button
|
mat-button
|
||||||
[title]="getSelected(forms) | translate"
|
[title]="getSelected(forms) | translate"
|
||||||
|
[attr.aria-label]="getSelected(forms) | translate"
|
||||||
[matMenuTriggerRestoreFocus]="true">
|
[matMenuTriggerRestoreFocus]="true">
|
||||||
|
|
||||||
<span class="adf-search-form-title" >
|
<span class="adf-search-form-title" >
|
||||||
@@ -25,7 +29,11 @@
|
|||||||
</button>
|
</button>
|
||||||
|
|
||||||
<mat-menu #menu="matMenu" backdropClass="adf-search-form-menu">
|
<mat-menu #menu="matMenu" backdropClass="adf-search-form-menu">
|
||||||
<button mat-menu-item *ngFor="let form of forms" (click)="onSelectionChange(form)">
|
<button *ngFor="let form of forms"
|
||||||
|
mat-menu-item
|
||||||
|
tabindex="0"
|
||||||
|
[attr.aria-label]="form.name | translate"
|
||||||
|
(click)="onSelectionChange(form)">
|
||||||
{{form.name | translate}}
|
{{form.name | translate}}
|
||||||
</button>
|
</button>
|
||||||
</mat-menu>
|
</mat-menu>
|
||||||
|
@@ -13,6 +13,7 @@
|
|||||||
*ngIf="!property.multiline"
|
*ngIf="!property.multiline"
|
||||||
class="adf-property-value"
|
class="adf-property-value"
|
||||||
[placeholder]="property.default"
|
[placeholder]="property.default"
|
||||||
|
[attr.aria-label]="property.label | translate"
|
||||||
[formControl]="textInput"
|
[formControl]="textInput"
|
||||||
(dblclick)="copyToClipboard(property.displayValue)"
|
(dblclick)="copyToClipboard(property.displayValue)"
|
||||||
matTooltipShowDelay="1000"
|
matTooltipShowDelay="1000"
|
||||||
@@ -26,6 +27,7 @@
|
|||||||
[cdkAutosizeMaxRows]="5"
|
[cdkAutosizeMaxRows]="5"
|
||||||
class="adf-property-value"
|
class="adf-property-value"
|
||||||
[placeholder]="property.default"
|
[placeholder]="property.default"
|
||||||
|
[attr.aria-label]="property.label | translate"
|
||||||
[formControl]="textInput"
|
[formControl]="textInput"
|
||||||
[attr.data-automation-id]="'card-textitem-value-' + property.key"></textarea>
|
[attr.data-automation-id]="'card-textitem-value-' + property.key"></textarea>
|
||||||
<button mat-button
|
<button mat-button
|
||||||
@@ -73,6 +75,7 @@
|
|||||||
<input matInput
|
<input matInput
|
||||||
class="adf-property-value"
|
class="adf-property-value"
|
||||||
[placeholder]="editedValue ? '' : property.default | translate"
|
[placeholder]="editedValue ? '' : property.default | translate"
|
||||||
|
[attr.aria-label]="property.label | translate"
|
||||||
[matChipInputFor]="chipList"
|
[matChipInputFor]="chipList"
|
||||||
[matChipInputAddOnBlur]="true"
|
[matChipInputAddOnBlur]="true"
|
||||||
(matChipInputTokenEnd)="addValueToList($event)"
|
(matChipInputTokenEnd)="addValueToList($event)"
|
||||||
@@ -97,6 +100,7 @@
|
|||||||
class="adf-property-value"
|
class="adf-property-value"
|
||||||
[ngClass]="{ 'adf-textitem-clickable-value': !isEditable }"
|
[ngClass]="{ 'adf-textitem-clickable-value': !isEditable }"
|
||||||
[placeholder]="property.default"
|
[placeholder]="property.default"
|
||||||
|
[attr.aria-label]="property.label | translate"
|
||||||
[(ngModel)]="editedValue"
|
[(ngModel)]="editedValue"
|
||||||
(blur)="update()"
|
(blur)="update()"
|
||||||
(keydown.enter)="update()"
|
(keydown.enter)="update()"
|
||||||
|
@@ -4,7 +4,12 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="adf-comments-input-container" *ngIf="!isReadOnly()">
|
<div class="adf-comments-input-container" *ngIf="!isReadOnly()">
|
||||||
<mat-form-field class="adf-full-width">
|
<mat-form-field class="adf-full-width">
|
||||||
<textarea (keydown.escape)="clear($event)" matInput id="comment-input" placeholder="{{'COMMENTS.ADD' | translate}}" [(ngModel)]="message"></textarea>
|
<textarea id="comment-input"
|
||||||
|
matInput
|
||||||
|
[attr.aria-label]="'COMMENTS.ADD' | translate"
|
||||||
|
placeholder="{{'COMMENTS.ADD' | translate}}"
|
||||||
|
[(ngModel)]="message"
|
||||||
|
(keydown.escape)="clear($event)"></textarea>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<div class="adf-comments-input-actions">
|
<div class="adf-comments-input-actions">
|
||||||
@@ -23,4 +28,4 @@
|
|||||||
<adf-comment-list [comments]="comments">
|
<adf-comment-list [comments]="comments">
|
||||||
</adf-comment-list>
|
</adf-comment-list>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@@ -405,7 +405,8 @@
|
|||||||
},
|
},
|
||||||
"PAGE_LABEL": {
|
"PAGE_LABEL": {
|
||||||
"SHOWING": "Showing",
|
"SHOWING": "Showing",
|
||||||
"OF": "of"
|
"OF": "of",
|
||||||
|
"PAGE_SELECTOR_LABEL": "Page selector"
|
||||||
},
|
},
|
||||||
"LOADING": "Loading",
|
"LOADING": "Loading",
|
||||||
"UNKNOWN_FORMAT": "Couldn't load preview. Unknown format.",
|
"UNKNOWN_FORMAT": "Couldn't load preview. Unknown format.",
|
||||||
|
@@ -26,6 +26,7 @@ import { LanguageItem } from '../services/language-item.interface';
|
|||||||
<button
|
<button
|
||||||
mat-menu-item
|
mat-menu-item
|
||||||
*ngFor="let language of languages$ | async"
|
*ngFor="let language of languages$ | async"
|
||||||
|
[attr.lang]="language.key"
|
||||||
(click)="changeLanguage(language)">{{language.label}}</button>
|
(click)="changeLanguage(language)">{{language.label}}</button>
|
||||||
`
|
`
|
||||||
})
|
})
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
<ng-container *ngIf="hasItems">
|
<ng-container *ngIf="hasItems">
|
||||||
<div class="adf-pagination__block adf-pagination__range-block">
|
<div class="adf-pagination__block adf-pagination__range-block" aria-live="polite">
|
||||||
<span class="adf-pagination__range">
|
<span class="adf-pagination__range">
|
||||||
{{ itemRangeText }}
|
{{ itemRangeText }}
|
||||||
</span>
|
</span>
|
||||||
|
@@ -1,5 +1,6 @@
|
|||||||
<ng-container *ngIf="image$ | async as image">
|
<ng-container *ngIf="image$ | async as image">
|
||||||
<img [src]="image" [alt]="'ADF_VIEWER.SIDEBAR.THUMBNAILS.PAGE' | translate: { pageNum: page.id }"
|
<img [src]="image" role="button"
|
||||||
|
[alt]="'ADF_VIEWER.SIDEBAR.THUMBNAILS.PAGE' | translate: { pageNum: page.id }"
|
||||||
title="{{ 'ADF_VIEWER.SIDEBAR.THUMBNAILS.PAGE' | translate: { pageNum: page.id } }}"
|
title="{{ 'ADF_VIEWER.SIDEBAR.THUMBNAILS.PAGE' | translate: { pageNum: page.id } }}"
|
||||||
[attr.aria-label]="'ADF_VIEWER.SIDEBAR.THUMBNAILS.PAGE' | translate: { pageNum: page.id }">
|
[attr.aria-label]="'ADF_VIEWER.SIDEBAR.THUMBNAILS.PAGE' | translate: { pageNum: page.id }">
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
@@ -19,7 +19,7 @@ import {
|
|||||||
Component, Input, ContentChild, TemplateRef, HostListener, OnInit,
|
Component, Input, ContentChild, TemplateRef, HostListener, OnInit,
|
||||||
AfterViewInit, ElementRef, OnDestroy, ViewEncapsulation, EventEmitter, Output, Inject, ViewChildren, QueryList
|
AfterViewInit, ElementRef, OnDestroy, ViewEncapsulation, EventEmitter, Output, Inject, ViewChildren, QueryList
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import { ESCAPE, UP_ARROW, DOWN_ARROW } from '@angular/cdk/keycodes';
|
import { ESCAPE, UP_ARROW, DOWN_ARROW, TAB } from '@angular/cdk/keycodes';
|
||||||
import { DOCUMENT } from '@angular/common';
|
import { DOCUMENT } from '@angular/common';
|
||||||
import { FocusKeyManager } from '@angular/cdk/a11y';
|
import { FocusKeyManager } from '@angular/cdk/a11y';
|
||||||
import { PdfThumbComponent } from './pdf-viewer-thumb.component';
|
import { PdfThumbComponent } from './pdf-viewer-thumb.component';
|
||||||
@@ -68,6 +68,14 @@ export class PdfThumbListComponent implements OnInit, AfterViewInit, OnDestroy {
|
|||||||
this.pdfViewer.currentPageNumber += 1;
|
this.pdfViewer.currentPageNumber += 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (keyCode === TAB) {
|
||||||
|
if (this.canSelectNextItem()) {
|
||||||
|
this.pdfViewer.currentPageNumber += 1;
|
||||||
|
} else {
|
||||||
|
this.close.emit();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (keyCode === ESCAPE) {
|
if (keyCode === ESCAPE) {
|
||||||
this.close.emit();
|
this.close.emit();
|
||||||
}
|
}
|
||||||
|
@@ -77,6 +77,7 @@
|
|||||||
data-automation-id="adf-page-selector"
|
data-automation-id="adf-page-selector"
|
||||||
pattern="-?[0-9]*(\.[0-9]+)?"
|
pattern="-?[0-9]*(\.[0-9]+)?"
|
||||||
value="{{ displayPage }}"
|
value="{{ displayPage }}"
|
||||||
|
[attr.aria-label]="'ADF_VIEWER.PAGE_LABEL.PAGE_SELECTOR_LABEL' | translate"
|
||||||
(keyup.enter)="inputPage(page.value)">
|
(keyup.enter)="inputPage(page.value)">
|
||||||
<span>{{ 'ADF_VIEWER.PAGE_LABEL.OF' | translate }} {{ totalPages }}</span>
|
<span>{{ 'ADF_VIEWER.PAGE_LABEL.OF' | translate }} {{ totalPages }}</span>
|
||||||
</div>
|
</div>
|
||||||
|
Reference in New Issue
Block a user