Skip to content

Commit 5b40a17

Browse files
authored
Merge branch '9.0.x' into dmdimitrov/issue6845-9.0.x
2 parents 0880070 + 6962133 commit 5b40a17

File tree

4 files changed

+18
-1
lines changed

4 files changed

+18
-1
lines changed

projects/igniteui-angular/src/lib/core/styles/components/navbar/_navbar-theme.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,5 +155,6 @@
155155

156156
%igx-navbar-title {
157157
@include igx-type-style($type-scale, $title);
158+
margin-bottom: 0;
158159
}
159160
}

projects/igniteui-angular/src/lib/core/styles/themes/schemas/light/_time-picker.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ $_fluent-time-picker: extend(
9999
/// @requires {function} extend
100100
/// @requires $_light-time-picker
101101
$_bootstrap-time-picker: extend(
102-
$_light-time-picker,§
102+
$_light-time-picker,
103103
$_bootstrap-shape-time-picker,
104104
(
105105
variant: 'bootstrap',

projects/igniteui-angular/src/lib/paginator/paginator.component.spec.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,19 @@ describe('IgxPaginator with default settings', () => {
3232
expect(totalPages).toBe(5);
3333
});
3434

35+
it('should change current page to equal last page, after changing perPage', () => {
36+
const fix = TestBed.createComponent(DefaultPaginatorComponent);
37+
fix.detectChanges();
38+
const paginator = fix.componentInstance.paginator;
39+
40+
paginator.paginate(paginator.totalPages - 1);
41+
paginator.perPage = paginator.totalRecords / 2;
42+
43+
fix.detectChanges();
44+
const page = paginator.page;
45+
expect(page).toBe(1);
46+
});
47+
3548
it('should disable go to first page when paginator is on first page', () => {
3649
const fix = TestBed.createComponent(DefaultPaginatorComponent);
3750
fix.detectChanges();

projects/igniteui-angular/src/lib/paginator/paginator.component.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,9 @@ export class IgxPaginatorComponent extends DisplayDensityBase {
7979
this.perPageChange.emit(this._perPage);
8080
this._selectOptions = this.sortUniqueOptions(this.defaultSelectValues, this._perPage);
8181
this.totalPages = Math.ceil(this.totalRecords / this._perPage);
82+
if (this._page >= this.totalPages) {
83+
this._page = this.totalPages - 1;
84+
}
8285
}
8386

8487
/**

0 commit comments

Comments
 (0)