From 1bff6c560643db60fcd3521524c70c5529b218e1 Mon Sep 17 00:00:00 2001 From: Diogo Bastos Date: Mon, 15 Apr 2024 15:02:13 +0100 Subject: [PATCH] AAE-21703 Fix group form widget style --- .../widgets/group/group-cloud.widget.html | 34 ++++++++++--------- .../components/group-cloud.component.html | 4 +-- .../components/group-cloud.component.spec.ts | 14 ++++++-- 3 files changed, 31 insertions(+), 21 deletions(-) diff --git a/lib/process-services-cloud/src/lib/form/components/widgets/group/group-cloud.widget.html b/lib/process-services-cloud/src/lib/form/components/widgets/group/group-cloud.widget.html index 76c2a0426a..4514720a5d 100644 --- a/lib/process-services-cloud/src/lib/form/components/widgets/group/group-cloud.widget.html +++ b/lib/process-services-cloud/src/lib/form/components/widgets/group/group-cloud.widget.html @@ -1,23 +1,25 @@
-
- +
+
- + + - {{ (title || 'ADF_CLOUD_GROUPS.SEARCH-GROUP') | translate }} + { it('should populate placeholder when title is present', () => { component.title = 'TITLE_KEY'; - fixture.detectChanges(); - const matLabel = element.querySelector('#adf-group-cloud-title-id'); - expect(matLabel.textContent).toEqual('TITLE_KEY'); + const inputElement = element.querySelector('[data-automation-id="adf-cloud-group-search-input"]'); + + expect(inputElement.placeholder).toEqual('TITLE_KEY'); + }); + + it('should not populate placeholder when title is not present', () => { + fixture.detectChanges(); + + const inputElement = element.querySelector('[data-automation-id="adf-cloud-group-search-input"]'); + + expect(inputElement.placeholder).toEqual(''); }); describe('Search group', () => {