This repository has been archived on 2026-05-07. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
Codiki/frontend/src/app/components/publication-edition/picture-selection-dialog/picture-selection-dialog.component.html
T
2024-09-21 21:34:16 +02:00

30 lines
997 B
HTML

<button type="button" class="close" (click)="closeDialog()">
<mat-icon>close</mat-icon>
</button>
<header>
<h1 i18n>Select an illustration</h1>
</header>
<div class="picture-container">
@if (isLoading) {
<h2 i18n>Pictures loading...</h2>
<mat-spinner></mat-spinner>
} @else {
@if (pictures.length) {
@for(picture of pictures; track picture) {
<img src="/api/pictures/{{picture.id}}" (click)="selectPicture(picture)" matTooltip="Choose this illustration" i18n-matTooltip/>
}
} @else {
<h2 i18n>There is no any picture.</h2>
}
}
</div>
<footer>
<button type="button" class="secondary" matRipple (click)="closeDialog()" i18n>
Cancel
</button>
<button type="button" (click)="fileUpload.click()" matRipple i18n>
<mat-icon>upload_file</mat-icon>
Add new picture
</button>
<input type="file" (change)="uploadPicture($event)" #fileUpload/>
</footer>