mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-3331] Create automated tests for Viewer component - Content Services (#3600)
* Automation tests for Viewer Component - Content Services * Create remaining automation tests for Viewer Component - Content Services * Deleting alfresco-ng2-components.iml * Correcting Viewer Page for failing tests * Updating Viewer Page for failing tests * Improving the PR quality
This commit is contained in:
committed by
Eugenio Romano
parent
69d8ff147e
commit
ab9f1c8385
@@ -5,13 +5,14 @@
|
||||
<mat-dialog-content>
|
||||
<form (submit)="submit()">
|
||||
<mat-input-container class="adf-full-width">
|
||||
<input matInput
|
||||
type="password"
|
||||
placeholder="{{ 'ADF_VIEWER.PDF_DIALOG.PLACEHOLDER' | translate }}"
|
||||
[formControl]="passwordFormControl" />
|
||||
<input matInput
|
||||
data-automation-id='adf-password-dialog-input'
|
||||
type="password"
|
||||
placeholder="{{ 'ADF_VIEWER.PDF_DIALOG.PLACEHOLDER' | translate }}"
|
||||
[formControl]="passwordFormControl" />
|
||||
</mat-input-container>
|
||||
|
||||
<mat-error *ngIf="isError()">{{ 'ADF_VIEWER.PDF_DIALOG.ERROR' | translate }}</mat-error>
|
||||
<mat-error *ngIf="isError()" data-automation-id='adf-password-dialog-error'>{{ 'ADF_VIEWER.PDF_DIALOG.ERROR' | translate }}</mat-error>
|
||||
</form>
|
||||
</mat-dialog-content>
|
||||
|
||||
@@ -21,9 +22,10 @@
|
||||
<button mat-button mat-dialog-close>{{ 'ADF_VIEWER.PDF_DIALOG.CLOSE' | translate }}</button>
|
||||
|
||||
<button mat-button
|
||||
class="adf-dialog-action-button"
|
||||
[disabled]="!isValid()"
|
||||
(click)="submit()">
|
||||
data-automation-id='adf-password-dialog-submit'
|
||||
class="adf-dialog-action-button"
|
||||
[disabled]="!isValid()"
|
||||
(click)="submit()">
|
||||
{{ 'ADF_VIEWER.PDF_DIALOG.SUBMIT' | translate }}
|
||||
</button>
|
||||
</mat-dialog-actions>
|
||||
</mat-dialog-actions>
|
||||
|
@@ -1,4 +1,5 @@
|
||||
<div class="pdf-thumbnails__content"
|
||||
data-automation-id='adf-thumbnails-content'
|
||||
[style.height.px]="virtualHeight"
|
||||
[style.transform]="'translate(-50%, ' + translateY + 'px)'">
|
||||
<adf-pdf-thumb *ngFor="let page of renderItems; trackBy: trackByFn"
|
||||
|
@@ -3,8 +3,8 @@
|
||||
<div class="adf-pdf-viewer__thumbnails">
|
||||
<div class="thumbnails-template__container">
|
||||
<div class="thumbnails-template__buttons">
|
||||
<button mat-icon-button (click)="toggleThumbnails()">
|
||||
<mat-icon>close</mat-icon>
|
||||
<button mat-icon-button data-automation-id='adf-thumbnails-close' (click)="toggleThumbnails()">
|
||||
<mat-icon>close</mat-icon>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -37,8 +37,9 @@
|
||||
|
||||
<ng-container *ngIf="allowThumbnails">
|
||||
<button mat-icon-button
|
||||
[disabled]="isPanelDisabled"
|
||||
(click)="toggleThumbnails()">
|
||||
data-automation-id='adf-thumbnails-button'
|
||||
[disabled]="isPanelDisabled"
|
||||
(click)="toggleThumbnails()">
|
||||
<mat-icon>dashboard</mat-icon>
|
||||
</button>
|
||||
<adf-toolbar-divider></adf-toolbar-divider>
|
||||
@@ -65,11 +66,11 @@
|
||||
<div class="adf-pdf-viewer__toolbar-page-selector">
|
||||
<span>{{ 'ADF_VIEWER.PAGE_LABEL.SHOWING' | translate }}</span>
|
||||
<input #page
|
||||
type="text"
|
||||
type="text"
|
||||
data-automation-id="adf-page-selector"
|
||||
pattern="-?[0-9]*(\.[0-9]+)?"
|
||||
value="{{ displayPage }}"
|
||||
(keyup.enter)="inputPage(page.value)">
|
||||
pattern="-?[0-9]*(\.[0-9]+)?"
|
||||
value="{{ displayPage }}"
|
||||
(keyup.enter)="inputPage(page.value)">
|
||||
<span>{{ 'ADF_VIEWER.PAGE_LABEL.OF' | translate }} {{ totalPages }}</span>
|
||||
</div>
|
||||
|
||||
|
Reference in New Issue
Block a user