mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-05-19 17:14:57 +00:00
[ADF-2457] Comment component - Hide the table header (#3053)
* Added showHeader input property in adf-datatable to hide header in comment-list component.
This commit is contained in:
parent
487147ca22
commit
16a8fa8cd8
@ -1,5 +1,6 @@
|
|||||||
<adf-datatable
|
<adf-datatable
|
||||||
[rows]="comments"
|
[rows]="comments"
|
||||||
|
[showHeader]="false"
|
||||||
(rowClick)="selectComment($event)" *ngIf="hasComments()">
|
(rowClick)="selectComment($event)" *ngIf="hasComments()">
|
||||||
|
|
||||||
<data-columns>
|
<data-columns>
|
||||||
|
@ -133,4 +133,13 @@ describe('CommentListComponent', () => {
|
|||||||
expect(elements[0].innerText).toContain(commentList.getUserShortName(testComment.createdBy));
|
expect(elements[0].innerText).toContain(commentList.getUserShortName(testComment.createdBy));
|
||||||
expect(fixture.nativeElement.querySelector('#comment-user-icon:empty')).toBeNull();
|
expect(fixture.nativeElement.querySelector('#comment-user-icon:empty')).toBeNull();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('should hide the datatable header in comment-list as showHeader is false', (done) => {
|
||||||
|
fixture.detectChanges();
|
||||||
|
fixture.whenStable().then(() => {
|
||||||
|
fixture.detectChanges();
|
||||||
|
expect(element.querySelector('.adf-datatable-header')).toBe(null);
|
||||||
|
done();
|
||||||
|
});
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user