Add pagination logic to AppealComponent and update layout structure.

This commit is contained in:
2025-08-05 20:59:22 +02:00
parent fcb64db137
commit 5013b9a204
3 changed files with 134 additions and 11 deletions
@@ -126,6 +126,30 @@ export class AppealComponent implements OnInit, AfterViewInit {
this.appealApi.submitMinecraftAppeal(appeal).subscribe()
}
public currentPageIndex: number = 0;
public totalPages: number[] = [0, 1, 2];
public goToPage(pageIndex: number): void {
if (pageIndex >= 0 && pageIndex < this.totalPages.length) {
this.currentPageIndex = pageIndex;
}
}
public previousPage() {
this.goToPage(this.currentPageIndex - 1);
}
public nextPage() {
this.goToPage(this.currentPageIndex + 1);
}
public isFirstPage(): boolean {
return this.currentPageIndex === 0;
}
public isLastPage(): boolean {
return this.currentPageIndex === this.totalPages.length - 1;
}
}
interface Appeal {