From 16a8fa8cd81c7a8b2086d9c5fe8db9364066c498 Mon Sep 17 00:00:00 2001 From: camorra-skk Date: Fri, 9 Mar 2018 19:19:20 +0530 Subject: [PATCH] [ADF-2457] Comment component - Hide the table header (#3053) * Added showHeader input property in adf-datatable to hide header in comment-list component. --- .../comments/comment-list.component.html | 1 + .../comments/comment-list.component.spec.ts | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/lib/process-services/comments/comment-list.component.html b/lib/process-services/comments/comment-list.component.html index 8416624b3f..bbc4b5aff5 100644 --- a/lib/process-services/comments/comment-list.component.html +++ b/lib/process-services/comments/comment-list.component.html @@ -1,5 +1,6 @@ diff --git a/lib/process-services/comments/comment-list.component.spec.ts b/lib/process-services/comments/comment-list.component.spec.ts index 87c4e4162d..81c029ad3b 100644 --- a/lib/process-services/comments/comment-list.component.spec.ts +++ b/lib/process-services/comments/comment-list.component.spec.ts @@ -133,4 +133,13 @@ describe('CommentListComponent', () => { expect(elements[0].innerText).toContain(commentList.getUserShortName(testComment.createdBy)); 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(); + }); + }); });