Fix pageChange emission to use history length
Modified the `ngOnChanges` method to emit the length of the history instead of the current page. This ensures accurate data is provided to parent components during changes.
This commit is contained in:
@@ -36,7 +36,7 @@ export class HistoryComponent implements OnInit, OnChanges {
|
|||||||
|
|
||||||
ngOnChanges(): void {
|
ngOnChanges(): void {
|
||||||
this.reloadHistory();
|
this.reloadHistory();
|
||||||
this.pageChange.emit(this.page);
|
this.pageChange.emit(this.history.length);
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
|
|||||||
Reference in New Issue
Block a user