Skip to content

Commit

Permalink
UI changes (#1512)
Browse files Browse the repository at this point in the history
* UI changes

* Fix subject

* Bump version
  • Loading branch information
DavidJayakumar authored Jul 12, 2023
1 parent 1dc8bfb commit bfc94cb
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 9 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@hmcts/ccd-case-ui-toolkit",
"version": "6.16.0-query-management-response-UI-changes-v2",
"version": "6.16.0-QM-respond-CYA-UI-changes-v2",
"engines": {
"yarn": "^3.5.0",
"npm": "^8.10.0"
Expand Down
2 changes: 1 addition & 1 deletion projects/ccd-case-ui-toolkit/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@hmcts/ccd-case-ui-toolkit",
"version": "6.16.0-query-management-response-UI-changes-v2",
"version": "6.16.0-QM-respond-CYA-UI-changes-v2",
"engines": {
"yarn": "^3.5.0",
"npm": "^8.10.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,17 @@ <h1 class="govuk-heading-l">
<ccd-query-case-details-header></ccd-query-case-details-header>
</div>

<dl *ngIf="queryCreateContext === queryCreateContextEnum.NEW_QUERY" class="govuk-summary-list govuk-!-margin-bottom-0">
<dl *ngIf="queryCreateContext !== queryCreateContextEnum.FOLLOWUP" class="govuk-summary-list govuk-!-margin-bottom-0">
<div class="govuk-summary-list__row">
<dt class="govuk-summary-list__key">
{{ 'Query subject' | rpxTranslate }}
{{ queryCreateContext === queryCreateContextEnum.RESPOND ? 'Submitted query' : 'Query subject' | rpxTranslate }}
</dt>
<dd class="govuk-summary-list__value">
{{ formGroup.get('subject')?.value }}
{{ queryCreateContext === queryCreateContextEnum.RESPOND ? queryItem.subject : formGroup.get('subject')?.value }}
</dd>
<dd class="govuk-summary-list__actions">
<a href="javascript:void(0)" class="govuk-link" (click)="goBack()">
<a *ngIf="queryCreateContext === queryCreateContextEnum.NEW_QUERY"
href="javascript:void(0)" class="govuk-link" (click)="goBack()">
{{ 'Change' | rpxTranslate }}
</a>
</dd>
Expand All @@ -36,7 +37,7 @@ <h1 class="govuk-heading-l">
<dl class="govuk-summary-list govuk-!-margin-bottom-0">
<div class="govuk-summary-list__row">
<dt class="govuk-summary-list__key">
{{ queryCreateContext === queryCreateContextEnum.RESPOND ? 'Response message' : 'Query detail' | rpxTranslate }}
{{ queryCreateContext === queryCreateContextEnum.RESPOND ? 'Response detail' : 'Query detail' | rpxTranslate }}
</dt>
<dd class="govuk-summary-list__value">
{{ formGroup.get('body')?.value }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,9 @@ describe('QueryCheckYourAnswersComponent', () => {
const heading = nativeElement.querySelector('.govuk-heading-l');
expect(heading.textContent.trim()).toEqual('Review query response details');
const columnHeadings = fixture.debugElement.queryAll(By.css('.govuk-summary-list__key'));
expect(columnHeadings[0].nativeElement.textContent.trim()).toEqual('Response message');
expect(columnHeadings[1].nativeElement.textContent.trim()).toEqual('Document attached');
expect(columnHeadings[0].nativeElement.textContent.trim()).toEqual('Submitted query');
expect(columnHeadings[1].nativeElement.textContent.trim()).toEqual('Response detail');
expect(columnHeadings[2].nativeElement.textContent.trim()).toEqual('Document attached');
});

it('should display correct columns for following up a query', () => {
Expand Down

0 comments on commit bfc94cb

Please sign in to comment.